we_are_coded.by CODE · The world, decoded
БГ

Anthropic · Mathematics

Claude wrote the first complete machine-checked proof of Fermat's Last Theorem in 11 days

On 4 September Anthropic published a proof of Fermat's Last Theorem checked end to end in Lean. Claude worked largely on its own for 11 days, wrote 13 million lines and proved 29,500 intermediate theorems used in the final result. The community expected the formalisation to take years.

Source
Anthropic
Published
The event
Checked on
Responsible editor
Cvetelin Ivanov
How we work
MethodCorrections

One hundred and twenty-nine pages. That is the length of Wiles's first proof from 1995, and checking it took several mathematicians months.

The new proof is 13 million lines of code, and a machine checks it, step by step, without skipping the obvious.

Fact

The facts: on 4 September 2026 Anthropic published the first complete computer-checked proof of Fermat's Last Theorem. It was written in the Lean language by Claude, which worked largely autonomously for 11 days; along the way it wrote 13 million lines of Lean and proved 29,500 intermediate theorems used in the final proof (30,300 proved in total). The project belongs to Anthropic researcher Tianyi Peng, whose group at Columbia University builds tools for formalisation. Dozens of Claude agents worked through the Prove2Me platform, consuming about six billion output tokens from an internal research model roughly comparable to Claude Fable 5.1. The proof follows the simplified version of Wiles's proof by Darmon, Diamond and Taylor, uses only Lean's three standard axioms, and its statement matches the formulation in the Mathlib library. Per Anthropic, it is over five times the size of Mathlib itself. Kevin Buzzard of Imperial College London, who launched the community formalisation project in 2024, reviewed the proof.

It matters what exactly is new. Claude did not discover a new proof - the theorem was proved more than thirty years ago. What is new is the verification: turning a human proof into chains that a machine walks from start to finish.

Wiles's proof was checked by people, for months. Now a machine has checked it.

And one detail won me over more than the numbers. Anthropic itself writes that the proof is probably much longer than it needs to be. Mathlib is tight and reviewed; this is clumsy but correct. As a first version of something people expected to take years, clumsy and correct is enough.

For anyone who teaches or writes mathematics, the most telling is their last example: formalising Vinogradov's three primes theorem in three days, with three personal Claude Max plans. That is no longer a project only for a lab with a budget.

The visual is generated code-art, no third-party images.