anthropic
Fermat's Last Theorem gets a machine-checked proof
Promtime
anthropicClaude produced the first complete computer-checked proof of Fermat's Last Theorem in 11 days of largely autonomous work, writing 13 million lines of Lean along the way, according to Anthropic. The formalization follows a simplified version of Andrew Wiles's proof set out by Henri Darmon, Fred Diamond and Richard Taylor.
At a glance
- Dozens of Claude agents coordinated through Prove2Me, an open collaborative platform for formalizing mathematics, which tracks theorem statements as a directed acyclic graph so agents can pick their next target and work in parallel.
- The run consumed about six billion output tokens from an internal research model roughly comparable to Claude Fable 5.1, and the finished proof is over five times the size of Mathlib.
- Lean verified the result using only its three standard axioms, and a comparator confirmed the formal statement matches Mathlib's own statement of the theorem, while the community had expected the formalization to take years.
Verification, not new mathematics, is the bottleneck this addresses: Wiles's proof took months of expert reading and still turned out to contain a gap, and refereeing large results routinely runs for years. If autoformalization at this scale is repeatable, it likely shifts part of that burden onto machines at the moment when AI systems are producing more candidate proofs than human referees can absorb. The claim so far rests on a single, heavily scaffolded run.
Dozens of agents proved 30,300 theorems, and 29,500 entered the final chain
Across the run Claude proved 30,300 theorems and used 29,500 of them in the final proof, with dozens of agents defining concepts, proving intermediate statements and assembling them into harder ones. The whole campaign took a little under two weeks, Anthropic says.
Several early attempts failed, according to Anthropic: agents had some success at first, but lost track of the project's state and stopped collaborating effectively. Those runs still contributed about 7% of the non-boilerplate lines in the final proof. The dependency graph mitigated that memory degradation once the work moved to Prove2Me and a multi-agent harness built on Claude Code.
Prove2Me, designed by Anthropic researcher Tianyi Peng with collaborators at Columbia University, also separates theorem statements and proofs into different files to speed up Lean compilation and cut resource use, and it keeps a natural-language description of every statement so agents can search for and reuse earlier results.
Human input came down to occasional priority notes from Tianyi Peng
Mathematical input from humans amounted to occasional high-level instructions from Peng: he flagged the Jacobian as a scheme as high priority and pushed the agents to finish the Mazur theorem. His group at Columbia builds tools for AI formalization, and he set out to test whether Claude could make progress on the problem.
The finished proof adapts pieces from the Imperial College London FLT project and from flt-regular, and Anthropic says its own version is likely much longer than it needs to be, while Mathlib, the community library it builds on, is concise and well reviewed.
Kevin Buzzard reviewed the proof and called it an "extraordinary autoformalization achievement" that proves the theorem "with no assumptions other than the axioms of mathematics". He said the artefacts are now robust enough to be built upon, and that the techniques point toward rigorous checking of machine-generated mathematics.
Wiles's 1995 proof ran to 129 pages and required months of verification
Fermat wrote the claim around 1637 in the margin of his copy of Diophantus's Arithmetica, adding that he had a marvelous proof the margin was too narrow to contain. In 1908 a prize of 100,000 German gold marks was announced for a correct proof, and 621 incorrect attempts arrived in the first year alone.
Wiles presented his proof in June 1993 in three days of lectures. Two months into verification a reviewer exposed a critical gap, which took Wiles another year to close, working first alone and then with his former student Richard Taylor; the corrected proof was published in May 1995 and ran to 129 pages.
Formalizing that proof was proposed a decade later by the Dutch computer scientist Jan Bergstra, and in 2024 Kevin Buzzard started a multi-year community project at Imperial College London to complete it in Lean; the blueprint for its initial phase alone runs to 86 pages.
Consumer plans and research grants
A smaller experiment ran on three personal Claude Max plans: collaborating entirely through Prove2Me, the agents formalized Vinogradov's Three Primes Theorem in three days, which Anthropic offers as evidence that collaborative formalization on consumer subscriptions is achievable with the right scaffold.
The full FLT proof and a written walk-through are on GitHub. Anthropic says it and other labs have expanded support for external researchers with free and discounted subscriptions, research credits and dedicated grants for larger projects such as formalizing other major theorems or improving Lean or Mathlib.
Comments
No comments yet. Be the first.
Join the conversation
Sign in with Google to leave a comment. Your name and avatar come from your Google profile, and the comment appears after moderation.
We only use your name and avatar from Google. We never store your email address.
