Scientific computing / R&D
From mathematical theory to a verified numerical library in 9 months
A compensated-computation library: precision loss is visible and auditable, properties machine-proved in Lean 4, every numeric claim backed by a reproducible benchmark.
- Status
- Research project
- Timeline
- 9 months
- Stack
- Python
- NumPy
- PyTorch
- Pydantic
- Lean 4 + Mathlib
- GitHub Actions
The task
Floating-point arithmetic loses information silently: summing [1e16, 1, −1e16] returns 0, meaningful differences collapse to false zeros, and division by zero throws instead of joining the data model. Pipelines patch this with scattered edge-case workarounds. We set out to build arithmetic where precision loss and singularities are explicit, structured, and auditable — with claimed properties proved and measured.
What we built
- Built a core based on Absolute Compensation Theory (ACT): every operation returns a result plus an explicit compensation term; singular cases become structured states with handling policies.
- Added compensated linear algebra (GEMM/QR/SVD), ML optimizers with a PyTorch wrapper, a finance ledger, and NumPy/pandas integrations on top of the core.
- Proved the public theorem surface in Lean 4 + Mathlib; the build certifies zero unproven statements and zero extra axioms.
- Enforced a claim-closure rule: every numeric claim in the docs is tied to a reproducible benchmark artifact regenerated in the same change set.
- Shipped a stable 1.0.0 release: 854 tests with an 85% coverage gate in CI, dual AGPL/commercial licensing, and an automated package release pipeline.
Outcome
- 1.0 instead of 0.0
- residual preserved on the [1e16, 1, −1e16] aggregation that float silently drops; reproducible benchmark artifact in the repository
- ≥10x
- stability ratio vs float64 on catastrophic cancellation; pinned baseline under regression control in CI
- 0 unproven statements
- machine-checked proofs of arithmetic properties in Lean 4 + Mathlib (zero sorry placeholders); the build certifies no extra axioms
- 9 months
- from first commit to stable 1.0.0 with 854 tests, an 85% coverage gate, and an automated package release pipeline
More cases
Manufacturing · Building materials
MVP in operationPanel specs from CAD drawings in seconds, not hours
Reads DWG/DXF layouts and builds the Excel spec: 10–30 seconds instead of 2–15 hours by hand. All 784 panels of one real project matched the manual spec line by line.
- 784/784 and 189/189
- panels on one project and wall panels on another matched the manual specs line by line, size groups included; area within 0.001 m²
- 2–15 h → 10–30 s
- to produce a project spec: manual work vs app processing, measured on real projects
Real estate · PropTech marketplace
MVP in operationLand-plot marketplace with a next-step plan: MVP in 2 months
From a mock-up to a working platform: plot → works → contractor → request. Rule-based next-step engine, three dashboards, personal-data compliance. MVP in 2 months.
- 2 months
- from approved spec to pre-release MVP on an HTTPS stand — week 9 against the plan's own 10–13 week estimate
- 7 days
- from spec to the first full-implementation commit: 168 files, 21.5k lines, then two months of hardening to pre-release
Marketplace e-commerce · Pricing
PilotRepricing without manual price control: a contract-guaranteed pilot
Competitor prices tracked per SKU on the marketplace, a price computed inside an agreed corridor, applied only after confirmation. Pilot: 10 SKUs, setup within 14 days.
- 10 SKUs · 2 scenarios
- pilot scope; the SKU cap and both scenarios are enforced in code and verified by contract tests — the cap cannot be exceeded
- up to 14 days
- contractual setup window from client inputs to launch, then a 1-month pilot; the service tracks the dates and closes access when the period ends
Estimate the impact on your own figures
AVA is a process-economics calculator. In a couple of minutes it shows whether a similar task pays off in your case — before any call and with no commitment.
Estimate the impact with AVAHave a similar task?
Describe the process and the data you have. We will tell you what can be measured in money and what cannot — before any work starts.
or email us directly: hello@xteam.pro