Heritage → MathIR · Dual-Path · 22 Apr 2026

Where the heritage is landing

How the Risk Evolution stochastic-vol heritage fits into the ReflexLibs.ai build, an architecturally satisfying discovery about the 2014 SSRN paper, and a thought on where all of this goes commercially.

Repo
xll.ai.main (private monorepo)
Paper
SSRN 2445328 (2014)
Date
2026-04-22

The short version

The architecture

Dual-path architecture The 2014 SSRN paper and the Risk Evolution heritage C++ converging on a unified MathIR AST, which emits to Rust, C#, Jint JS, WASM, and IronPython lanes, with triumvirate cross-validation. SSRN 2445328 (2014) "A Normal Stochastic Volatility Model" public academic publication no permission needed Risk Evolution heritage C++ reflex_analytic_raw/ original development team 2011–2022 · under permission grant Path A clean-room derivation Path B direct port under grant MathIR AST unified intermediate representation Program A from paper equations Program B from heritage .cpp Rust f64 · decimal C# · Roslyn f64 · decimal Jint JS in-process WASM bindgen · WIT IronPython +5 more Triumvirate cross-validation Both Programs emitted through every lane, numerical agreement at 1e-12 vs mpmath 50-digit oracle.

Two independent porting paths converging on the same MathIR AST:

Path Afrom the paper

Clean-room derivation from the 2014 SSRN paper. Uses published equations directly. No heritage contact at all. Lowest possible copyright surface.

Path Bfrom the heritage

Direct port of HestonNormal.cpp into MathIR under the permission grant. Preserves 10+ years of production-tested edge cases — complex-log branch fix per Lord & Kahl 2010, quadrature tweaks, overflow guards — that the paper doesn't spell out.

Cross-checkA ≡ B

Both paths emit through the same lanes (Roslyn / Rust / WASM) and run against identical oracle test vectors. Agreement = two-way verified. Disagreement = triangulated bug — the difference tells us exactly which lane is wrong.

The pattern generalises. Same structure applies to every stochastic-vol family for which a public paper exists:

FamilyPublic paperHeritageRows
Heston NormalSSRN 2445328 (2014)HestonNormal.*7
Heston LognormalHeston 1993 (Rev. Financ. Stud.)HestonLognormal.*10
Heston Lognormal-ShiftedHeston 1993 + displacementHestonLognormalShifted.*10
Bates (all variants)Bates 1996 (Rev. Financ. Stud.)Bates*.*27
SABRHagan et al. 2002 (Wilmott)SABR*.*shipping

Every port has dual provenance: one citable public paper, one licensed heritage implementation. That's a very clean story for any future licensing, audit, or acquisition conversation.

Current state

125matrix rows
173cells passing
14csproj projects
190/190tests green
10execution lanes
7families indexed
Test coverage matrix rows125 across 7 families
Cells PASS today173 of 1,250 (Black76 + SABR core shipping)
Cells MISS (porting backlog)1,077
Execution lanesRust · C# · Roslyn · Jint · Wasmtime · WIT · IronPython · …
Cross-language three-way tests60 / 60 (Roslyn + Jint + Wasmtime)
Heritage families inventoriedall 7 (Black · Bates · Heston · CEV · Kirk · SABR · Intrinsic)
Papers as authorised porting sources1 shipped (SSRN 2445328), 3 next in queue

The 125-row coverage matrix is the honest ledger of what's done and what's backlog. JSON-sourced with a JSON Schema, renders to both Markdown and HTML, eventually CI-regenerated from actual test runs.

Where this is heading — commercially

Nothing imminent, but the door is open and worth naming now while the ownership structure is clean.

Open-source lane — reflexlibs.ai public

Pricing libraries for Black / Black-76 / Bachelier / Shifted / SABR. MIT-style license. GitHub-hosted. Community adoption vector — reputation, downstream hiring, customer funnel.

Proprietary lane — Xll.Ai / Risk Evolution

The MathIR emitter factory itself: 13 target emitters, Roslyn host harness, triumvirate test rig, WIT Component Model distribution. Heston / Bates ship as WIT signatures only on the open side; full kernels live behind the enterprise licence. Custom-model development for specific client books.

Plausible revenue lanes

None of this is live today. The infrastructure is roughly six months out. But it's worth saying now that the Risk Evolution heritage is the crown jewel in this structure — without it, the whole stochastic-vol side of the catalogue is empty.

On the AI-assisted build pipeline

Full transparency: the original version of AST Math generation was developed by Steve Dickson in Q1 2025, drawing on his background in compiler theory and his extensive experience with expression parsers at Lehman Brothers on the 1990s cash-flow editor. The original MathIR codebase was developed in C# using OpenAI o3-mini-high and o4-mini-high models early 2025. This project is being built with significant help from Anthropic's Claude. The heritage permission grant explicitly excludes use of the code for Anthropic foundation-model training. Target-language ports are session-time outputs, not training data.

The underlying heritage was built 2011–2022 by the original Risk Evolution team. This whole project is built on top of that work, and it's still the reference we measure against.