A 17-Million-Line Proof in Lean: What Claude and the Riemann Hypothesis Mean for Science and AIArticle · digest for November 25
Mathematical diagram of the critical line of Riemann zeta function zeros set against endless columns of formal Lean code.
Article4 sections≈ 8 min

A 17-Million-Line Proof in Lean: What Claude and the Riemann Hypothesis Mean for Science and AI

A math problem that stumped the sharpest minds for 167 years now has a formal proof. Independent compilers have already confirmed it contains zero logical errors. Now here is the twist: not a single person on Earth can read the entire proof and explain how the ending works. That includes the mathematician who sat at the keyboard alongside the AI.

This is where science found itself on November 20, 2026. Let's cut through the hype and the panic to see what Anthropic's team actually released, why the AI didn't need "new mathematics," and what we do with an answer we can't yet understand.

What Was Actually Proved and Why Nobody Has Claimed the Million Dollars

For a quick refresher, German mathematician Bernhard Riemann formulated the Riemann Hypothesis in 1859. It deals with prime numbers, the ones divisible only by one and themselves. From the outside they look scattered at random, but Riemann proposed a strict order hiding behind the chaos: all non-trivial zeros of the zeta function lie on a single vertical line.

Positions of non-trivial zeros of the Riemann zeta function on the critical line (Source: Wikimedia Commons, CC BY-SA 3.0)

For nearly two centuries, mathematicians were 99% sure Riemann was right. They built hundreds of other theorems on top of it with the caveat "assuming the Riemann Hypothesis is true," and the Clay Mathematics Institute put it on the Millennium Prize list with a $1 million reward. In math, though, 99% doesn't count. You need an airtight deduction from axioms to the finish line.

On November 20, 2026, Anthropic mathematician Levent Alpoge published a formal proof of the Riemann Hypothesis (plus the Generalized Riemann Hypothesis for Dirichlet L-functions), built in tandem with an internal unreleased Claude model. The scale is staggering: roughly 17 million lines of Lean 4 code spread across more than 175,000 files. Printed on paper, that's a stack of around 250,000 pages.

Lean 4 is a specialized language and automated proof assistant, basically a strict compiler for mathematics. Skip a step or leave a sorry placeholder, and the build fails. Both the Lean FRO and the Mathlib Initiative have confirmed that the code compiles cleanly, relies only on standard axioms, and passed checks from Lean's native kernel as well as independent verifiers con-leche and nanoda.

So why does the Clay Institute still list the problem as open? A machine checks that B logically follows from A, but it doesn't care whether the definitions inside the code match the classical problem without subtle loopholes. Auditing 17 million lines by hand and translating them into clear human ideas could take years.

Let's also clear up a rumor spreading online that AI solved two more Millennium Problems in the same few weeks: the Navier-Stokes equations and P = NP. The Navier-Stokes breakthrough is real. After OpenAI's September paper used an external forcing term (which mathematicians saw as a workaround), Alpoge and NYU professor Tristan Buckmaster posted a 79-page paper and Lean 4 code on November 20, 2026, for the unforced 3D case. The P = NP claim, however, was a misunderstanding. In its formal-math repository, Anthropic released 73,000 lines of Lean 4 on Valiant's algebraic conjecture (VP ≠ VNP), which explicitly notes it doesn't resolve the classical Boolean P vs NP problem.

Why AI Succeeded Without "New Mathematics"

This raises an obvious question: how did this happen? Terence Tao, one of the strongest mathematicians alive, estimated that the Riemann Hypothesis wouldn't yield without fundamentally new ideas or next-generation AI until around 2050. Did a private version of Claude invent alien math over a couple of nights?

No. And that's the real story.

It didn't have to invent a new branch of science. Almost all the pieces were already sitting on the shelves of modern mathematics, but assembling them is physically brutal for a human brain. Try holding just three complex theorems from different fields in your head and aligning their conditions—you'll burn out in ten minutes. Here, the task required juggling 30 to 50 heavy tools at once and stretching an ultra-long chain of connections between them.

Human working memory isn't built for that. For a large language model, it's home turf.

For the same reason, neural networks have already overtaken humans at navigating massive codebases. A developer struggles to track a million lines and every cross-module dependency, while an algorithm calmly tests thousands of combinations of known techniques until it finds a working path.

Task DimensionHow Humans WorkHow the Claude Partnership Worked
Source of ideasInvents new concepts and intuitive leapsCombines 30–50 existing tools
Working memoryHolds a few nodes, loses long chainsTracks millions of lines and thousands of links
VerificationStep-by-step understanding of each lemmaCompilation in Lean 4 and independent checkers
Main bottleneckLimited attention and search speedBlack box: answer is verified, logic is hidden

Levent Alpoge guided the problem to the right fork in the road, and near the finish line Claude pulled ahead and carried the deduction home on its own. The mathematician openly admitted he doesn't yet fully understand how the ending of the proof works.

A Boeing 747 Without Aerodynamics and Move 37 for All of Science

Throughout history, humans built knowledge through trial and error. The Wright brothers put together a fragile flyer, stayed airborne for a few seconds, and refined the design. Decades of iteration led to the Boeing 747, capable of 18-hour nonstop flights, and at every step engineers understood the laws of aerodynamics.

Now picture the reverse: people who have never flown find a ready-made Boeing 747 dropped in the middle of a field. The plane works and can fly, but we have no clue how the turbines operate, how to repair it, or what to do if an instrument fails. Try to take off, and you'll almost certainly crash.

With 17 million lines of code, science has shifted to reverse-engineering a finished answer for the first time. Something similar happened in 2016 when AlphaGo played Move 37 against Lee Sedol. Live commentators thought the algorithm had made a rookie blunder, and only post-game analysis revealed that this alien move won the match. Now Move 37 has stretched across 175,000 files.

A year before Anthropic's release, math popularizer Grant Sanderson asked leading scientists how they would feel in this scenario. Alex Kontorovich said he wouldn't just celebrate a million-token proof and move on: he needs to understand how it worked, because understanding is why he does math. Jordan Ellenberg went even further, saying an unread Lean file billions of tokens long isn't a proof in any human sense, and he doesn't care whether such a file exists.

Why compilation does not replace understanding

Verification in Lean 4 guarantees the logical chain has no breaks. Without a clear idea inside, however, science misses the real prize of great proofs: new methods that unlock dozens of other problems.

Code, Cryptography, and the Race Against the Black Box

If this sounds like a cozy academic debate, look at software engineering. Once AI started writing code faster than people, developers split into two camps: those who love the craft itself, and those who only care about shipping a working product. Science is heading for the exact same split between manual proofs and practitioners using AI as an accelerator.

From there, the questions get much more unsettling. Programming languages evolved from zeros and ones to readable English syntax only because humans can't read binary. A computer doesn't need that wrapper. What happens if neural networks start writing software in their own ultra-efficient representation, a thousand times denser, yet unreadable to our eyes? Even without malice, that code could do the right thing 99.9% of the time and hide a critical bug in the remaining 0.1%.

Cryptography is another open risk. Modern security for payments, messaging, and privacy rests on hard number-theory problems. Nobody broke encryption yesterday, but if models learn to solve the toughest math problems faster than humans can grasp their methods, we'll have to rethink the safety margins of our crypto systems.

Back in April 2025, Anthropic CEO Dario Amodei captured this crossroads in one line in his essay on interpretability: "We are in a race between interpretability and model intelligence." Interpretability is like an MRI for a neural network, an attempt to see inside the weights to learn how the algorithm reached its answer. As long as we understand its mechanics, the risks stay manageable. The moment model intelligence outpaces our ability to look under the hood, verification gives way to blind trust in a black box.

Want a deep diveVotes help us choose what to break down in detail. This material has 0 votes.
Sources · 5