For 167 years, the Riemann Hypothesis has stood as the most famous open problem in mathematics. On November 20, 2026, Levent Alpoge, a mathematician at Anthropic, released a proof of it - not as a paper, but as a Lean library comprising 17 million lines of code, produced in collaboration with Claude. By the end of the next day, the Lean and Mathlib communities had issued a joint statement, endorsed by the Lean FRO and the Mathlib Initiative, declaring full confidence in both the statement and the proof.
That speed is the real story here. A proof of this scale would traditionally take teams of specialists years of line-by-line refereeing before anyone could reasonably believe it. A machine-checked proof compresses that bottleneck into a single day - but only if the verification is done right. This article explains what was checked, why each check matters, and what the certification does and does not settle.
Why a compiling proof is not automatically a proof of anything
The core insight behind the community's approach, articulated by Kevin Buzzard on the Xena blog a week before the announcement, is that the phrase "it was checked in Lean" carries no weight by itself. It is shorthand for four separate questions, each of which can fail independently:
- Does the Lean statement actually say what mathematicians mean?
- Does the code compile?
- Does the code prove the statement as stated?
- Does the proof exploit a bug in Lean's kernel?
The first question is subtler than it sounds. Lean will happily compile a definition named FermatsLastTheorem that is trivially false, because Lean's natural numbers include zero, so setting a = b = c = 0 defeats the statement. Nothing stops a malicious or sloppy author from writing a statement that looks like the Riemann Hypothesis but quietly uses redefined objects. A proof of the wrong statement compiles perfectly.
The third question guards against a different trick. The statement of a theorem might live in a short, trustworthy file, while the proof imports millions of lines of untrusted code. Somewhere in those millions of lines, a definition could be overridden so that x^n means 37, or a new axiom could declare the theorem true. Reading every line is impossible at this scale, so the check must be mechanical.
The fourth question acknowledges that Lean's official kernel is several thousand lines of C++ and has had soundness bugs before - bugs that, in the summer of 2026, even produced illicit proofs of the Collatz conjecture and the Kepler conjecture before being repaired. A proof that exploits an undiscovered kernel bug could pass every ordinary check while proving something false.
The Alpoge verification addressed all four questions, and the details of how are worth walking through.
Check 1: The statement is Mathlib's own
The proof does not target a custom definition buried in the 17 million lines. It targets RiemannHypothesis, a definition that already lives in Mathlib, Lean's community-maintained mathematics library, and has been vetted by experts in both Lean and number theory.
In Mathlib's formulation, the statement reads: every zero of the Riemann zeta function other than the trivial zeros -2, -4, -6, and so on has real part 1/2, with an additional condition excluding s = 1, since Mathlib assigns the zeta function a conventional value at its pole. The top-level source is disarmingly short:
theorem riemannHypothesis : RiemannHypothesis := rhOfAll
Everything to the left of the assignment is the trusted target. Everything to the right - the name rhOfAll and the mountain of machinery behind it - is what had to be verified.
Check 2: The library compiles
All 175,187 modules compiled on Lean v4.33.1 with Mathlib v4.33.1, producing zero errors. Dozens of people independently reported successful compilation, reproducing the same raw proof export file. Andrew Sutherland, a mathematician at MIT, ran a rebuild inside a sandbox with no network access and read-only sources on a separate machine; it reproduced the published export byte for byte - all 61,570,595,788 bytes of it, matching the SHA-256 hash. Of the 175,187 compiled module files, 175,186 also matched exactly; the single exception was traced to a nondeterministically compiled variable name in an automatically generated lemma, a cosmetic difference with no bearing on the proof.
One detail in Sutherland's audit deserves emphasis: the Mathlib files used in the build were confirmed identical, byte for byte, to the official cache - 8,322 Mathlib files and 378 dependency files. This rules out tampering with the trusted foundation underneath the untrusted proof.
Check 3: The code proves the correct statement
This is the step that mechanical verification makes possible and human reading never could. The community created a challenge file that isolates the statement of the Riemann Hypothesis and imports only Mathlib - a tiny artifact anyone can read and trust. Then two independent tools, comparator and con-leche --compare, compared the challenge statement against the theorem actually proved in Alpoge's library. Both confirmed the theorems are exactly identical.
The axiom audit reinforces this. Running #print axioms on the five headline theorems returned only Lean's three standard axioms: propext, Classical.choice, and Quot.sound. No user-defined axioms were declared anywhere outside Lean's core - just 15 axioms in the entire environment, all in Init. The environment contains no sorryAx, which would indicate an omitted proof.
Check 4: The proof survives independent kernels
Because Lean's kernel has had soundness bugs before, the community did not stop at Lean's own checker. The exported proof - 1,468,418 declarations rendered as raw terms in a 61.6 GB file - was replayed through several independently written checkers:
- nanoda, an independent kernel written in Rust, accepted the full export in 27 minutes and 42 seconds on 80 threads.
- con-leche, a checker written in Lean itself, accepted all 1,468,418 declarations in 3 minutes and 15 seconds on 64 threads.
- con-ron, a Rust port of con-leche, accepted the full export and matched all five headline theorems against the challenge statements.
- lean4lean accepted every one of the 175,187 compiled modules; five modules needed their default computation limits raised before passing.
- Lean's official and paranoid kernels were still running single-threaded checks on the full export when the statement was published, with the statement comparison and axiom stages already passed.
The crucial property of con-leche and con-ron is that they come with a formal proof, relative to a standard set theory, that they cannot accept a proof of False. This directly addresses the concern that Lean's underlying logic itself might harbor flaws a clever proof could exploit. A false proof would have to simultaneously exploit undiscovered bugs in many independent systems - including checkers with machine-checked soundness proofs - which moves the scenario from plausible to fantastic.
There is also an architectural safeguard: all of these checks ran on an inert export of the proof, a raw term representation sitting outside the Lean source files entirely. Hypothetically malicious code in the Lean sources - code that might delete files or manipulate the checking process - has no reach into that export.
What was actually proved
The verified result is stronger than the classical statement. Five theorems were checked in the submission's Main.lean:
- The Riemann Hypothesis, in Mathlib's own formulation.
- The same statement rewritten in the submission's own words, which Lean accepts as equal by definition.
- No Dirichlet L-function vanishes to the right of the critical line: for every modulus N and every Dirichlet character chi modulo N, the L-function is nonzero whenever the real part of s exceeds 1/2, excluding the trivial character at its pole.
- Every zero of every Dirichlet L-function inside the critical strip lies on the critical line, where the real part of s equals 1/2.
- The same statement restricted to primitive characters - the form in which the Generalized Riemann Hypothesis for Dirichlet L-functions is conventionally stated.
The scope has precise limits. "GRH" here means Dirichlet L-functions: all moduli, all characters. Dedekind zeta functions, Hecke L-functions, and automorphic L-functions in general were not among the statements checked. Alpoge's note says he expects the Extended Riemann Hypothesis "with more time," presenting it as future work.
As an independent cross-check that does not rely on Mathlib's zeta definition, the proof was combined with a separate formalization of Robin's and Lagarias's criteria. The combination yields two unconditional arithmetic statements about divisor sums - the Robin inequality for all n above 5040, and the Lagarias inequality for all positive n - and those combined statements passed the same battery of checker and axiom tests.
The mathematics behind the proof
The formal verification certifies that the proof is correct; it does not explain the mathematics. For that, the community has had to rely on preliminary readings. A high-level summary circulated by Fable on the Lean Zulip sketches the architecture: the Riemann Hypothesis is deduced from the nonvanishing of Dirichlet L-functions to the right of the critical line, which in turn rests on a growth bound on certain Galois cohomology groups, a covolume bound from arithmetic geometry, and statements about theta integrals on unitary groups combined with local Langlands for GL_n.
Notably, the project derives the Galois representations it needs rather than assuming them, building them from geometric constructions for unitary groups plus chains of theta lifts between unitary groups. Alpoge's own account describes the conceptual move: in Stepanov's argument for the Riemann Hypothesis over function fields, a divisor involving multiplicity does the decisive work, and multiplicity is hard to reproduce over the integers. The proposal is to chain theta lifts - each lift mimicking multiplicity - with Claude suggesting a chain of length roughly the square root of X for a von Mangoldt sum of length X. Terence Tao's initial assessment suggests the argument draws on the Langlands program and arithmetic geometry, and that it will take time for mathematicians to understand how the pieces fit.
The scale of the human-readable version is itself an obstacle. A text rendering produced during the project ran past 250,000 pages. Alpoge chose to publish only the Lean code rather than what he called an unreadable document, and has said he intends to simplify and explain the argument properly. In the MathOverflow discussion that followed, one estimate suggested a reasonable human-readable version might come in under 1,000 pages, and contributors discussed how the community might divide the work of understanding it - different people reading different parts, writing expositions, and interrogating frontier models to navigate the code.
What the certification does not settle
The Lean and Mathlib statement is deliberately narrow: it certifies that the statement is correct and that the proof is valid. Several things remain outside its scope.
The Clay Mathematics Institute still lists the problem as unsolved. Its Millennium Prize rules require publication in a suitable outlet, a waiting period of at least two years, and general acceptance by the mathematical community. No human-readable proof exists yet, and the prize process was written long before questions of AI authorship arose.
More fundamentally, formal verification establishes truth, not understanding. A machine-checked proof demonstrates that every inference follows from the axioms; it does not produce the insight that mathematicians traditionally seek from a proof - why the theorem is true, what the mechanism is, and what new techniques it contributes to the toolbox. That work, the expositions, simplifications, and community digestion, is what the joint statement explicitly looks forward to. Alpoge himself expects the argument to be massively simplified, following the pattern of other recent breakthroughs.
There is also the standing caveat about scale. Checking a proof of this size is possible in principle for anyone but requires server-class hardware in practice; even Kevin Buzzard's own machine ran out of memory compiling an earlier 13-million-line formalization until he was given access to a machine with 96 cores and 500 GB of RAM. Verification at this scale is a community activity, not an individual one.
Why the verification methodology matters beyond this proof
The Riemann Hypothesis certification is the most prominent application of a verification playbook that the community has now exercised end to end. The four-question framework - statement fidelity, compilation, statement matching against a trusted challenge, and multi-kernel validation - turns "checked in Lean" from a slogan into a procedure. It makes correctness claims about enormous, AI-generated proofs inspectable, reproducible, and independent of any single implementation.
The deeper shift is cultural. For centuries, the bottleneck of mathematics was proving things; the referee process then made accepting proofs slow but reliable. Now that frontier systems can generate proofs of unprecedented size, the bottleneck has moved to understanding. The machinery of formal verification solves the trust problem in a day. The problem of turning 17 million lines of certified code into human knowledge - into mathematics that mathematicians can teach, extend, and love - remains open, and the joint statement's closing line is a direct invitation to that work.