CFDL

Validation

CFDL's numbers are checked against references it did not produce. Every pack is gated by a parity suite: each model is diffed against an independent reference, period by period and on summary metrics, inside a tolerance the case declares. A drift outside that tolerance fails the build.

Where the references come from

Every case is checked against an external benchmark: a published model, an issuer's own schedule, a filed valuation, a course problem set with its answer printed.

What differs is whether the source can be shown. Most cannot — a workbook is licensed, a filing is copyrighted, an industry standard forbids reproduction. Two approaches follow from that.

Where the source publishes its figures, those figures are asserted directly and the case carries a NOTES.md recording the reconciliation: what was compared, what diverged, and how to repeat it.

Where it does not, or where the source cannot be redistributed, the case carries a reference_gen.py — the source's conventions implemented independently of the model, so the two are compared line by line without the source being vendored. The reference is written from the source's conventions, not from the model.

A few sources carry an explicit reuse grant. Those ship with the case, so every number can be marked against the original — the HOME Multifamily template and the MIT OpenCourseWare problem sets among them.

Each case below states what its source publishes and whether it can ship.

What a case contains

Every case is made of the same parts:

  • the model, and the run configuration it is run with
  • the period-level expectations taken from the reference — the model total, or each stream in its own column — and the per-period tolerance
  • summary metrics, each with its own tolerance
  • a write-up: what the deal is, what the reference is, what the case exercises, how closely it matched, and what any remaining difference means
  • either an independent implementation of the source's conventions, or a record of the reconciliation against the source's published figures

Every case is compiled and run on each commit, and the build fails if any period or metric drifts outside tolerance. Schedule arithmetic is held decimal-exact; IRR-class iteratives carry a basis-point tolerance.

How tolerances are set

A tolerance states how close the two are expected to be, and why. It is set by what the source can support, not by what the model happens to achieve.

A workbook that prints whole dollars cannot be matched closer than half a dollar, so those cases carry 0.5. A ratio quoted to sixteen significant figures carries 1e-4. Where a case needs both, tolerances are set per column rather than one value covering everything: a single number loose enough for the money lines would assert nothing about the ratio.

The cases

Each links to the full model, its run configuration, the series that were checked, and a write-up of the reference and the residual.

CaseWhat it is
Energy: cost-based solar feed-in tariffA distributed solar project paid a cost-based feed-in tariff, with an abating payment in lieu of property tax and a revenue-linked royalty.
Energy: merchant generator with capacity revenueA merchant generator earning both energy and capacity revenue, exposed to price rather than to a contracted offtake.
Energy: a merchant battery dispatched on the day-ahead spreadA 20 MW / 80 MWh merchant battery dispatched on the day-ahead spread, with the run/idle decision as a state machine in IEEE Std 762's vocabulary and cycling as an output rather than an assumption.
Energy: solar PPA microgridA solar microgrid selling under a long-term power purchase agreement, with production degradation and a fixed escalator on the contracted price.
Energy: a tax-equity flip, with the date derivedA tax-equity partnership whose flip date is derived from the investor's return rather than stated, reconciled against an external model.
Energy: a tax-equity flip, distributing from an accountThe twin of tax_equity_flip, with the project's cash as streams settling into an account rather than a hand-carried field.
Energy: utility-scale PV, single ownerA utility-scale photovoltaic project in a single-owner structure, carrying its own tax position rather than allocating to an investor.
Energy: wind with PTC and MACRSA wind project claiming the production tax credit over ten years and depreciating on the MACRS five-year schedule.
CRE: a stabilized acquisition and a terminal cap rateA stabilized commercial property bought on a going-in cap rate, held ten years with fully reimbursed expenses, and sold by capping the final year's net operating income.
CRE: HOME-funded affordable multifamilyA 29-year affordable multifamily underwriting from HUD's HOME Multifamily template, with restricted rents reverting to market at year 15 and a first mortgage, stated from its sizing terms, that stops paying before the hold ends.
CRE: rent-regulated plazaA five-year office acquisition and disposition from MIT's real estate finance course, valued on a levered before-tax cash flow with an exit at a stated cap rate.
CRE: a renewal option on a leaseThe two-tenant office DCF with Tenant A's expiry as a renewal option on the lease: exercised at expiry when the market rent exceeds the option rent, and a re-let at market when it does not.
CRE: two-tenant officeAn institutional two-tenant office DCF: free rent, anniversary escalations, recoveries above expense stops, tenant improvements and leasing commissions, probability-blended rollover, and a forward-NOI exit over ten years.
CRE: office development joint ventureA ground-up office development drawing on a construction facility, capitalizing interest through the build, then stabilizing and refinancing.
CRE: office development, through the pack contractThe same published construction schedule as the native case, declared as one cre.construction_loan contract — equity first, the facility behind it, interest on the drawn balance.
CRE: retail strip with expense stopsA retail strip center with base-year expense gross-ups, percentage rent over a breakpoint, and staggered tenant rollover across a ten-year hold.
Credit: auto ABS with a step-down and a turboThe note classes of a sub-prime auto ABS that builds its own overcollateralization: a 22-step waterfall where excess cash accelerates principal toward a target and principal beyond it is retained rather than paid.
Credit: auto ABS at 0.5x prepayment speedAn auto loan pool prepaying at 0.5 ABS, amortizing to schedule with prepayments taken as a constant share of the original balance.
Credit: auto ABS at 1.5x prepayment speedThe same auto loan pool at 1.5 ABS, three times the prepayment speed, showing how the collection profile shortens.
Credit: auto ABS note classesThe note classes of an auto ABS: the trust as a container, collections as accounts, and ordered waterfalls paying seven classes by seniority, reconciled against the issuer's published percent-outstanding grid at every distribution date.
Credit: auto ABS weighted average lifeAn auto loan pool measured for weighted average life, the standard summary of when principal actually comes back.
Credit: floating-rate bridge poolA floating-rate bridge loan pool priced off a forward curve, where the coupon resets each period rather than being fixed at origination.
Credit: Fannie Mae REMIC with a stripped coupon, at six prepayment speedsSecurity Group 3 of a Fannie Mae REMIC: a seasoned mortgage pool passing through to a single class, with the coupon stripped between it and an interest-only class that carries no principal.
Credit: Fannie Mae REMIC at 0% PSAGroup 3 of a Fannie Mae REMIC with the mortgage loans never prepaying — the supplement's own alternative collateral of new 7.50% thirty-year loans, amortizing on schedule for thirty years.
Credit: IO/bullet bridge loanAn interest-only loan repaying its entire principal in a single balloon at maturity.
Credit: level-pay auto poolA level-payment amortizing loan pool — the constant instalment that splits into shrinking interest and growing principal.
Credit: a mortgage pool modeled loan by loanThe same mortgage pool declared loan by loan, with the published pool schedule asserted against the aggregate the engine rolls up from its children.
Credit: mortgage pool conventionsA mortgage pool priced under standard market conventions, reconciling published factors, CPR and SMM against a fixed prepayment vector.
Credit: mortgage pool on a prepayment rampA mortgage pool on a ramping prepayment curve, where speeds build over the first thirty months before levelling off.
OpCo: banker DCF conventionsAn operating company discounted cash flow built to standard banking conventions, from revenue through unlevered free cash flow to enterprise value.
OpCo: free cash flow to firmA free cash flow to firm valuation following Damodaran's published method, with reinvestment driven by growth and return on capital.
OpCo: working capital and a terminal exit multipleAn operating company discounted cash flow with an explicit working-capital line and a terminal value struck as a multiple of trailing EBITDA.
OpCo: stable-growth dividend discountA Gordon growth valuation of a regulated utility, where a perpetual dividend growing at a constant rate collapses to a closed form.
OpCo: leveraged buyoutA leveraged buyout: entry at a stated multiple, debt paid down out of operating cash flow, and an exit that returns the sponsor's equity.
OpCo: LBO debt schedule with average-balance interestA leveraged buyout's debt schedule, where interest accrues on the average balance and every dollar of free cash flow sweeps against the term loan.
OpCo: one buyout at three capital structuresOne sponsor buyout run at three capital structures, with the published five-year multiple and return reproduced for each.
OpCo: LBO exit waterfall with an option poolA leveraged buyout's exit waterfall, splitting proceeds between an accruing preferred, rolled-over management equity and a laddered management option pool.
OpCo: SaaS DCF and the stock-compensation forkA subscription software business valued on discounted cash flow, with stock-based compensation carried as its own line so the same model states value before and after it.
Bespoke: open-pit copper mineA 41-year open-pit copper mine whose production plan is derived from its reserve statement, with the pit's strip ratio drawn from a distribution and the valuation reported as a range.
Bespoke: tolled highway PPP concessionA 125 km toll highway concession from the World Bank's highway PPP toolkit, financed with three debt tranches and topped up each year by an availability subsidy sized to hold debt service cover at 1.30x.

40 cases.

Beyond the suite

The benchmarks check CFDL against other implementations. Two other gates check it against mathematics:

  • Analytic identities — a par bond discounted at its coupon is worth par; an annuity due is worth exactly (1+i) times the ordinary annuity. These hold for any correct implementation and cannot be satisfied by copying what the engine currently does.
  • Cadence parity — one deal modeled on every calendar must produce the same annual economics.