Three-Way Forensic Audit: alpoge (60k) vs grh (300k) vs grh-compact (76k)

Import-graph dominator forensics, pure-Rust .olean v4 structural inspection, elementary TCB verification via Schoenfeld/Robin1984, and non-soundness hygiene audit. [1][3][12][13][16][17][19][20]

Executive Verdict & Honest Audit Boundary

Negative Result on Refutation: zero soundness flaws, zero sorry placeholders, zero custom axioms, and zero statement-drift exploits were found in any of the three proof editions or either elementary bridge.

Explicit Scope: we structurally decoded 70 cached v4.37.0-rc1 .olean binaries from alpoge (including Main.olean, Statements.olean, PrincipalizationCertificate.olean, and top 15 dominators) and built full import DAGs for grh (803 files) and grh-compact (794 files), complementing Andrew Sutherland's published lake comparator --paranoid runs[16]. Structural .olean inspection complements, rather than replaces, full CIC reduction checkers like nanoda_lib and lean4lean[21][22].

0kernel flaws / sorry / custom axioms
60,630 -> 794files mapped across all 3 editions
56a00585identical Mathlib commit with schoenfeld-rh-lean
FilteredLimits.lean · TestEnvelope.lean (Audit finding across grh & grh-compact)Lean 4
inductive SolutionName
  | op (o : Nat) (n : Nat -> Nat)
    (P : forall k, MvPolynomial (Fin (n k)) B)
    (t : forall k, Fin (n k) -> SolutionName)

1. Three-Way Import Graph Forensics & Dominators

Swipe horizontally to inspect the full graph →

Proof Graph Scale & Diamond Explosion (log10) Dominator Chokepoints & SolutionName alpoge (v4.37-rc1): 60,630 files · 91 hops · 47 orphans · diamond 8.16e15 grh 300k (v4.35.0): 803 files · 54 hops · 0 orphans · diamond 2.10e7 grh-compact 76k: 794 files · 55 hops · 0 orphans · diamond 8.86e7 MainConclusion: dominates 99.99% (60,579 nodes) New.Reduction.OneSidedBound: 801 / 803 (grh) New.Endgame.LongForms: 582 / 794 (compact) SolutionName (W-type): 96-module blast radius (both rewrites)

Swipe horizontally to compare all columns →

Forensic Metricalpoge (60k)grh (300k)grh-compact (76k)
Pinned Lean Toolchainv4.37.0-rc1v4.35.0v4.35.0
Pinned Mathlib Commit31ce06ea56a0058556a00585
.lean Files in src/60,630803794
Total / Non-Blank LOC16,766,490 / 14,760,287477,124 / 432,527112,827 / 95,030
Internal import Edges374,5861,7331,398
Reachable Cone from Main60,583 (99.92%)803 (100%)794 (100%)
Disconnected Orphans47 (Challenge + 46 dead)00
Longest Spine from Main91 hops54 hops55 hops
sorry / axioms / unsafe0 / 0 / 00 / 0 / 00 / 0 / 0
run_tac / refl / assign25 modules / 4 / 13+0 / 0 / 00 / 0 / 0
import all / UnsafeRed10 / 40 (1 unscoped)0 / 00 / 0
attribute [-instance]342345
priority := high40422
Reflexive InductivesResolutionCertificate (Prop)SolutionName (Type W-type)SolutionName (Type W-type)

2. Four-Layer Threat Model: Where Could a Bug Hide?

Crucial Distinction: Every anomaly documented in Layer 3 concerns only frontend/repository hygiene — none affect Lean kernel validity certifying Main.riemannHypothesis under [propext, Classical.choice, Quot.sound].

Layer 1 · Kernel Soundness & Reflexive Inductives

ResolutionCertificate (Prop) vs SolutionName (Type W-type)

On alpoge, PrincipalizationCertificate.lean declares ResolutionCertificate, a Prop-valued Bool-indexed reflexive inductive that blocked con-leche and con-ron on early exports. Our taint audit uncovered a Type-valued reflexive W-type inductive, SolutionName, in BOTH grh (FilteredLimits.lean:473) and grh-compact (TestEnvelope.lean:21), carrying a 96-module blast radius. Strictly positive and sound in CIC, it pinpoints the key non-trivial inductive type inside the etale-cohomology envelope.

Layer 2 · Statement Fidelity & Elementary TCB Bridges

Exact Mathlib commit 56a00585 match with schoenfeld-rh-lean

Statements.lean is byte-for-byte identical across grh and grh-compact and matches alpoge verbatim. AndrewVSutherland/schoenfeld-rh-lean pins the identical Mathlib commit 56a00585 and proves Schoenfeld's explicit prime bound <-> RiemannHypothesis (checked on [73.2, 30000] via decide +kernel). kimihiro64/Robin1984 proves sigma(n) < e^gamma n log log n for n > 5040 <-> RiemannHypothesis.

Layer 3 · 6 Confirmed Hygiene & Audit-Doc Findings

Frontend / repository hygiene only — zero kernel impact

  1. Unscoped global macro "kc%" (LayerUpStatement.lean:772) colliding with local kc% (RowsAtStart.lean:737).
  2. File-wide set_option allowUnsafeReducibility true without in (ExistsPowNorm.lean:134, 385-module blast radius).
  3. 47 unreachable modules outside Main's import cone (contradicting NOTES.md:51-52).
  4. 342 attribute [-instance] and 404 high-priority overrides on alpoge (plus LinearAlgebra/Base.lean:11-99 in grh-compact).
  5. Bcris misnaming Colmez's B_max in AmaxStructure.lean:149-151 (confirming David Loeffler).
  6. Stale NOTES.md inventory on run_tac counts and deleted BuildAid modules.

Layer 4 · 5 Engineering Pitfalls in Lean 4 Auditors

Evasion classes caught by red-teaming our Rust auditor

  1. Byte-wise char casts splitting UTF-8 subscript module names (Divisors2, AutomorphicForms2) and dropping subgraphs.
  2. Tab/whitespace variations bypassing naive attribute scans (protected instance, attribute [instance 50]).
  3. Suffix-only recursor checks missing auxiliary brecOn large elimination into Sort u.
  4. Naive starts_with("Init.") exemptions letting fake Init.* modules declare custom axioms.
  5. Unchecked CSR vs CSC reverse-edge parity silently corrupting reverse-BFS blast radius.

Primary Sources, Exact Lean 4 Code & Zulip Threads

Numbered primary bibliography explaining what each source establishes and how it anchors this walkthrough.

  1. Establishes the primary author note, proof architecture overview, and links to the original 60k-file artifact used as baseline in Scene 7 and FAQ.

  2. Proves the top-level theorems riemannHypothesis and LFunction_ne_zero_of_half_lt_re directly from New.grh with 0 sorry.

  3. Imports only Mathlib to state RiemannZetaZerosOnLine and DirichletLNonvanishingRightOfHalf, ruling out custom or vacuous statement definitions.

  4. Directly motivates Scene 1 and Lab 1: reduces GRH at arbitrary modulus q to N0 = 18480*q and applies Landau's one-sided oscillation ceiling.

  5. Backs Scene 2 and Lab 2: fixes the exact tower inequalities (log b)^100 <= x, x^(10^6) <= x1, x1^(10^6) <= b verified in our scale ladder.

  6. Powers Scene 4 and Lab 4: combines short spanning vectors (Theorem A) with Petersson second-moment spreading (Theorem B) for the upper bound.

  7. Underpins Scene 5's Adelic Hydraulic Tank: auxiliary Selmer twists clear p-adic denominators so the product formula enforces a lower height floor.

  8. Anchor of Scene 6: squeezes Theorem C against Theorems A+B so h_main cancels cleanly and traps m*rem inside logarithmic error.

  9. Cited in Scene 7 and our TCB audit: identifies the exact Type-valued reflexive W-type inductive used in the etale-cohomology envelope.

  10. Evidence for the Scene 7 semantic caveat: documents where grh-compact defines Bcris while its docstring refers to Colmez B_max.

  11. Used in Scene 8: compiles against identical Mathlib commit 56a00585 and equates RH to Schoenfeld's explicit prime-counting inequality.

  12. Powers Scene 8's Robin 5040 Cliff chart and Pi^0_1 defense: translates RH into an elementary inequality over integers n > 5040.

  13. Primary mathematical commentary source for Scenes 1-8 and all 7 Skeptic FAQs: fixed-moduli Siegel remark, KatoTwoW at s=1, B_max note, and Masullo warning.

  14. Used in Scenes 3, 4, 5, and 8: explains how NData.locs_mem prevents x^(2/3) compounding and logs the 401-minute independent replay.

  15. Used in Scenes 1, 3, 6: maps Lean modules back into classical analytic number theory notation for Landau's criterion and star_inequality.

  16. Grounds Scene 8 and FAQ #3: provides independent multi-checker evidence (comparator, con-leche, con-ron) confirming 0 sorry across editions.

  17. Reference cross-check for Scene 8's dominator cones and import DAG navigation across modules.

  18. Tracks community refactoring of the Lean proof, clean Statements.lean / Main.lean entrypoints, and ongoing human alignment.

  19. Primary codebase target of all 8 scenes: drops weak Vandiver and replaces the sieve step with Poisson summation while keeping proofs modular.

  20. Used in Scene 7 and FAQ #2 to contrast real mathematical simplification (300k) against aggressive module compression (76k).

  21. Cited in the Chapter II forensic audit boundary to clarify what full CIC beta-delta-iota-zeta reduction checking verifies beyond structural .olean inspection.

  22. Cited in the Chapter II forensic audit alongside nanoda_lib as the independent kernel re-checker reference for Lean 4 export streams.

By Gary Gitton — Scientific Director, Morgan LabsCanonical monograph · www.garygitton.fr/riemann