Repository navigation
Description
None of the 17 macro-using metasd models is checked against Vensim output.
The harness in tests/integration/metasd_macros.rs only checks that their macros expand; its simulate-and-compare tier lists no models.
Each model either has no Vensim reference output checked in, or fails to compile for a reason unrelated to macros.
Example
test/metasd/theil-statistics/Theil_2011.mdl compiles and simulates with no errors today (corpus_theil_multi_output_materializes_and_simulates in simulate.rs).
It is left out only because no Vensim output for it is checked in.
Why it matters
These are real published models, and they are the only end-to-end numeric check of macro support against Vensim.
The underlying problem is wider than this corpus: there is no Vensim DSS run available to make reference outputs, so Vensim-compat work keeps falling back to hand-computed expected values.
Fix
- Get Vensim output for
Theil_2011.mdland check it in beside the model; changing itsCORPUSentry toSimTier::Eligibleturns on the comparison. - Decide once, and write down in
docs/dev/, where reference outputs come from: a one-time Vensim DSS run banked in the repo, PySD (with its known differences from Vensim stated), or hand-computed values with a stated tolerance.
The other models are blocked by engine gaps tracked separately: RANDOM NORMAL (#560), DELAY N order (#562), DELAY FIXED (#346), GET XLS DATA (#555), plus MDL-parse and dimension errors in free 6.mdl, groupon 1-3.mdl, scirev7/8.mdl, Wonderland3.mdl, IDch15d.mdl and InterpolatingArrays.mdl that are not filed.
Each one goes into the comparison as its blocker is fixed and an output is added.
Alternative: if no reference source is going to exist, delete the unused simulation tier from the harness rather than keep dead code waiting for it.
Pointers
src/simlin-engine/tests/integration/metasd_macros.rs:CORPUS,SimTier,metasd_simulation_tiertest/metasd/theil-statistics/
Activity
bpowers commentedon May 15, 2026
Broader follow-up: no standing numeric-fidelity oracle/policy for Vensim-imported models
Filing this as a comment on the natural umbrella issue (per a macro-epic retrospective) rather than a duplicate, since #561 already tracks the specific metasd simulation-tier prerequisite. The broader, recurring problem:
There is no standing policy or CI-available oracle for numeric-fidelity validation of Vensim-imported models. Because no licensed Vensim DSS is available to generate ground-truth
.vdf/output.tabseries, every Vensim-compat epic re-litigates this and ends up down-scoping acceptance criteria. Concretely, in the just-completed macro epic:output.tabarithmetic (hand-computed from the verbatim macro body + the engine's own STEP/RAMP/forward-Euler semantics) rather than DSS-validated series — see the C-LEARN-derived SAMPLE UNTIL fixture rationale in commit7cba4ad2.This is a policy decision, not a code defect, and it is broader than #561 (which scopes the metasd corpus specifically). Options to decide between (enumerated here so a future session need not re-derive them):
.vdfcorpus that is then checked in and reused indefinitely (Theil_2011 is the cheapest first target per test: no macro-using metasd model is compared against Vensim output #561 — already green end-to-end, one-lineCORPUSedit once a reference exists).Recommend resolving with an explicit decision among (a)/(b)/(c) and recording it in the repo (e.g.
docs/dev/or the test-models README) so it is durable across epics.Context: surfaced during the Vensim macro epic retrospective (PR #564, branch
macros). Not requesting any change now — tracking the policy gap so it stops being re-litigated.doc: track macro-epic retrospective findings in tech-debt
Add Vensim macro (:MACRO:) support (#564)
[-]engine: metasd macro corpus SIMULATION tier is empty -- enable it (Vensim DSS reference outputs starting with Theil_2011 + per-model non-macro blocker triage)[/-][+]test: no macro-using metasd model is compared against Vensim output[/+]