{"id":"formal-vision","title":"The Open Distillation Factory — Executable Vision","subtitle":"Current status is machine-generated in the Lean theorem-count inventory, with a build-locking epistemic contract.","category":"formalization","tags":["lean","formal-spec","vision"],"source":"articles/docs/formal-vision.md","lang":"en","words":756,"readMinutes":3,"toc":[{"depth":2,"text":"Build Status","id":"build-status"},{"depth":2,"text":"What Is a Build-Locking Contract?","id":"what-is-a-build-locking-contract"},{"depth":2,"text":"Theorem Inventory","id":"theorem-inventory"},{"depth":3,"text":"Data Layer (9 theorems)","id":"data-layer-9-theorems"},{"depth":3,"text":"Analysis: Causal Inference (9 theorems)","id":"analysis-causal-inference-9-theorems"},{"depth":3,"text":"Analysis: Manifold Geometry (10 theorems)","id":"analysis-manifold-geometry-10-theorems"},{"depth":3,"text":"Theory: Parameter Bound (1 theorem)","id":"theory-parameter-bound-1-theorem"},{"depth":3,"text":"Theory: Meta-Science (5 theorems)","id":"theory-meta-science-5-theorems"},{"depth":3,"text":"Computation: LAMMPS Trace (3 theorems)","id":"computation-lammps-trace-3-theorems"},{"depth":3,"text":"Validation: Experiment (5 theorems)","id":"validation-experiment-5-theorems"},{"depth":3,"text":"Validation: Audit (5 theorems)","id":"validation-audit-5-theorems"},{"depth":2,"text":"The Epistemic Gap (5 Documented Gaps)","id":"the-epistemic-gap-5-documented-gaps"},{"depth":2,"text":"Why This Matters","id":"why-this-matters"},{"depth":2,"text":"Related","id":"related"}],"html":"<h1 id=\"the-open-distillation-factory-executable-vision\">The Open Distillation Factory — Executable Vision</h1><blockquote>\n<p><em>A formal specification is not a presentation. It is a contract that compiles.</em></p>\n</blockquote>\n<p>This project is the first attempt to treat interatomic potential validation as a <strong>theorem-driven engineering discipline</strong>. Rather than running every simulation and hoping the statistics converge, we formalize what it means to validate — and we lock that formalization into the build.</p>\n<hr>\n<h2 id=\"build-status\">Build Status</h2><blockquote>\n<p><strong>Current status (2026-06):</strong> the Projection Law proof chain now reports 77\nbuild-locked theorems, ~225 theorem/lemma declarations, seven paper theorems,\nzero <code>sorry</code>, and a 2,891-job <code>lake build</code> green. This page began as the\nearlier executable-vision snapshot; the inventory below is retained as lineage,\nwhile the counters have been updated to the current public proof surface.</p>\n</blockquote>\n<div class=\"stat-row\">\n  <div class=\"stat-card\">\n    <div class=\"stat-number\">2,891</div>\n    <div class=\"stat-label\">Build targets passed</div>\n  </div>\n  <div class=\"stat-card\">\n    <div class=\"stat-number\">77</div>\n    <div class=\"stat-label\">Build-locked theorems</div>\n  </div>\n  <div class=\"stat-card\">\n    <div class=\"stat-number\">~225</div>\n    <div class=\"stat-label\">Theorem / lemma declarations</div>\n  </div>\n  <div class=\"stat-card\">\n    <div class=\"stat-number\">7</div>\n    <div class=\"stat-label\">Projection Law paper theorems</div>\n  </div>\n</div>\n\n<hr>\n<h2 id=\"what-is-a-build-locking-contract\">What Is a Build-Locking Contract?</h2><p>In conventional materials informatics, a &quot;claim&quot; lives in a PDF. In this project, a claim lives in a Lean 4 module — and if the claim breaks, <strong>the build breaks</strong>.</p>\n<p>Our vision file (<code>Vision.lean</code>) contains <code>#guard</code> statements that are evaluated at compile time:</p>\n<pre><code class=\"language-lean\">#guard (hypothesisCount &gt;= 6)\n#guard (computationallyProvenCount &gt;= 10)\n#guard (epistemicGapCount &gt;= 1)\n</code></pre>\n<p>These are not tests. They are <strong>epistemic minimums</strong>. A future commit cannot silently drop below 6 formally stated hypotheses, remove all computationally proven theorems, or close every epistemic gap without justification.</p>\n<hr>\n<h2 id=\"theorem-inventory\">Theorem Inventory</h2><h3 id=\"data-layer-9-theorems\">Data Layer (9 theorems)</h3><ul>\n<li><code>syntheticFccCount</code> — 72 FCC entries embedded</li>\n<li><code>syntheticBccCount</code> — 42 BCC entries embedded</li>\n<li><code>nistScaffoldCount</code> — 9 NIST scaffold rows</li>\n<li><code>nistScaffoldAlMissing</code> — NIST predictions are absent</li>\n<li><code>syntheticFccIsSynthetic</code> — all FCC entries carry synthetic provenance</li>\n<li><code>syntheticBccIsSynthetic</code> — all BCC entries carry synthetic provenance</li>\n<li><code>syntheticFccNonEmpty</code> / <code>syntheticBccNonEmpty</code> — datasets are non-empty</li>\n<li><code>nistScaffoldPredictionsMissing_bool</code> — structural check on missing data</li>\n</ul>\n<h3 id=\"analysis-causal-inference-9-theorems\">Analysis: Causal Inference (9 theorems)</h3><ul>\n<li><code>noSimpsonsDetected</code> — Simpson&#39;s paradox is <strong>fabricated</strong> in synthetic BCC</li>\n<li><code>pooledRBelowMinus08</code> — pooled correlation &lt; −0.8</li>\n<li><code>pooledWithinRBelowMinus09</code> — within-group correlation &lt; −0.9</li>\n<li><code>nGroupsEqualsSeven</code> — exactly 7 metal groups</li>\n<li><code>nTotalEqualsTwentyOne</code> — exactly 21 data points</li>\n<li><code>reversalMagnitudeAbove01</code> — reversal exceeds significance threshold</li>\n<li><code>syntheticBccEamPointsNonEmpty</code> / <code>syntheticBccAllPointsNonEmpty</code></li>\n</ul>\n<h3 id=\"analysis-manifold-geometry-10-theorems\">Analysis: Manifold Geometry (10 theorems)</h3><ul>\n<li><code>fccEamPRBounded</code> — EAM PR ∈ (1.2, 1.3)</li>\n<li><code>fccLjPRBounded</code> — LJ PR ∈ (1.1, 1.2)</li>\n<li><code>fccSwPRBounded</code> — SW PR ∈ (1.1, 1.2)</li>\n<li><code>fccAllPRBounded</code> — All FCC PR ∈ (1.3, 1.4)</li>\n<li><code>paperClaimHolds</code> — hyper-ribbon claim satisfied</li>\n<li><code>fccEamPRGreaterThanLj</code> — EAM PR &gt; LJ PR</li>\n<li><code>fccAllSatisfiesHyperRibbon</code> — PR/n &lt; 0.5 for full FCC set</li>\n<li><code>fccEamVectorCount</code> / <code>fccAllVectorCount</code> — structural counts</li>\n<li><code>fccAllMoreThanEam</code> — full dataset larger than EAM subset</li>\n</ul>\n<h3 id=\"theory-parameter-bound-1-theorem\">Theory: Parameter Bound (1 theorem)</h3><ul>\n<li><code>syntheticEamSatisfiesBound</code> — EAM participation ratio ≤ min(params, observables)</li>\n</ul>\n<h3 id=\"theory-meta-science-5-theorems\">Theory: Meta-Science (5 theorems)</h3><ul>\n<li><code>hypothesisBoardLength</code> — exactly 6 hypotheses registered</li>\n<li><code>cubicIrrepSum</code> — cubic irrep dimensions sum to 4</li>\n<li><code>trueCausalGraphNoConfounder</code> — nature: element → structure → error (no bypass)</li>\n<li><code>syntheticCausalGraphHasConfounder</code> — synthetic data: element → error (confounder)</li>\n<li><code>printStatusBoardNonEmpty</code> — status board renders</li>\n</ul>\n<h3 id=\"computation-lammps-trace-3-theorems\">Computation: LAMMPS Trace (3 theorems)</h3><ul>\n<li><code>allPredictionsHaveTraces_empty</code> — empty benchmark needs no traces</li>\n<li><code>allPredictionsHaveTraces_nil_traces</code> — nil trace list behavior</li>\n<li><code>syntheticEntryNeedsNoTrace</code> — synthetic provenance needs no LAMMPS run</li>\n</ul>\n<h3 id=\"validation-experiment-5-theorems\">Validation: Experiment (5 theorems)</h3><ul>\n<li><code>actualExperimentIsNotNistBacked</code> — our experiment lacks NIST provenance</li>\n<li><code>actualExperimentUsesSyntheticData</code> — all predictions are synthetic</li>\n<li><code>actualExperimentNotPreRegistered</code> — no pre-registration record exists</li>\n<li><code>syntheticFccFailsNistIntegrity</code> — synthetic FCC fails NIST integrity check</li>\n<li><code>syntheticBccFailsNistIntegrity</code> — synthetic BCC fails NIST integrity check</li>\n</ul>\n<h3 id=\"validation-audit-5-theorems\">Validation: Audit (5 theorems)</h3><ul>\n<li><code>simpsonVerdictContainsFabricated</code> — audit string contains &quot;FABRICATED&quot;</li>\n<li><code>hyperRibbonVerdictContainsConsistent</code> — audit string contains &quot;CONSISTENT&quot;</li>\n<li><code>auditReportNonEmpty</code> — report renders</li>\n<li><code>simpsonPooledRNegative</code> — pooled correlation is negative</li>\n<li><code>nistScaffoldIncomplete</code> — NIST scaffold has no predictions</li>\n</ul>\n<hr>\n<h2 id=\"the-epistemic-gap-5-documented-gaps\">The Epistemic Gap (5 Documented Gaps)</h2><p>Every theorem in the specification is <strong>fully proven</strong> — there are no <code>sorry</code> proofs. But not every claim is grounded in NIST-backed data. Five documented gaps in <code>Validation.Experiment</code> mark the boundary between what we can compute on synthetic data and what requires ground-truth LAMMPS traces:</p>\n<ol>\n<li><strong>All predicted values are hand-typed</strong>, not computed from NIST IPR potentials via LAMMPS</li>\n<li><strong>Reference values lack DOI citations</strong></li>\n<li><strong>Experiment was not pre-registered</strong></li>\n<li><strong>No formal data provenance tracking</strong> in the original Rust code</li>\n<li><strong>Bootstrap CIs rely on non-deterministic random sampling</strong></li>\n</ol>\n<p>These gaps are not bugs. They are <strong>features of honesty</strong>. They prevent the build from pretending to know what it does not know.</p>\n<hr>\n<h2 id=\"why-this-matters\">Why This Matters</h2><p>Most interatomic potential papers publish:</p>\n<ul>\n<li>A table of RMSE values</li>\n<li>A convergence plot</li>\n<li>A claim that the potential is &quot;transferable&quot;</li>\n</ul>\n<p>This project publishes:</p>\n<ul>\n<li>A <strong>formal specification</strong> of what &quot;transferable&quot; means</li>\n<li><strong>Build-locking guards</strong> that fail if the statistics shift</li>\n<li><strong>Meta-scientific hypotheses</strong> about why validation is hard</li>\n<li>An <strong>explicit boundary</strong> between proven theorems and documented gaps</li>\n</ul>\n<blockquote>\n<p><em>Proof or reproducible trace. Everything else is marketing.</em></p>\n</blockquote>\n<hr>\n<h2 id=\"related\">Related</h2><ul>\n<li><a href=\"/#/article/formal-methodology\">In the In Between</a> — the methodology behind theorem-driven validation</li>\n<li><a href=\"/#/article/formal-audit\">Formal Audit Report</a> — split verdict with computational evidence</li>\n<li><a href=\"/#/article/formal-hypotheses\">Six Meta-Scientific Hypotheses</a> — the new research agenda</li>\n</ul>\n"}