Claude Completes First Computer-Verified Proof of Fermat’s Last Theorem: A New Frontier for AI in Mathematics

Written by

in

In one of the most remarkable demonstrations of artificial intelligence applied to pure mathematics, Anthropic’s Claude has completed the first end-to-end, computer-verified formalization of Fermat’s Last Theorem in the Lean proof assistant language. Working largely autonomously over 11 days of wall-clock time via the open-source Prove2Me platform, Claude produced a proof that a computer system could formally check line by line, a milestone mathematicians have pursued for decades without success.

What Was Announced

Anthropic published the achievement on its research blog this week, describing how Claude ran as a system of several dozen parallel agents to tackle the formalization challenge. The theorem, originally proposed by Pierre de Fermat in 1637, states that no three positive integers can satisfy the equation a^n + b^n = c^n for any integer n greater than 2. Andrew Wiles famously completed a human-readable proof of Fermat’s Last Theorem in 1995 after more than 350 years as one of mathematics’ most celebrated open problems.

The new achievement is distinct from Wiles’ original proof. Formalization means converting an existing mathematical argument into a highly explicit, machine-checkable form in a language like Lean, where a proof assistant can verify every logical step. This is far more demanding than writing a human-readable proof, because every implicit assumption and logical shortcut must be spelled out in full for the software to accept it.

The run generated 13 million lines of Lean code, proved 30,300 individual theorems (of which 29,500 were directly used in the final proof), and consumed approximately 6 billion output tokens across the parallel agent system. The 11-day figure represents wall-clock time, not the output of a single sustained agent working sequentially.

A key turning point came mid-run, when the first formalization attempt failed and Anthropic integrated Prove2Me, an open-source tool developed at Columbia University, into the workflow. That addition made the successful completion possible.

Technical Details

The Lean proof assistant is a formal verification system developed at Microsoft Research. Unlike conventional programming languages, Lean is designed to check mathematical arguments with complete rigor: it accepts a proof only when every logical step follows from axioms and previously verified theorems. Formalizing a result as complex as Fermat’s Last Theorem requires navigating thousands of intermediate lemmas spanning algebraic geometry, modular forms, and Galois representations, the same deep mathematical territory that made Wiles’ original proof so celebrated.

Claude’s approach leveraged the substantial groundwork already built into Lean’s Mathlib library, a community-maintained collection of formalized mathematics. It also built heavily on a Lean formalization project for Fermat’s Last Theorem led by Kevin Buzzard at Imperial College London. Prove2Me, the Columbia University tool added partway through the run, provided additional scaffolding that allowed the agent system to handle the deepest parts of the proof where earlier attempts broke down.

Running dozens of parallel agents simultaneously allowed Claude to explore multiple proof strategies and subgoal decompositions at once, rather than pursuing a single linear path. When one agent’s approach reached a dead end or produced Lean code that the proof checker rejected, other agents continued along alternative routes. This branching, fault-tolerant structure is what made an 11-day wall-clock run feasible for a problem of this scale.

Industry Impact and Reactions

Kevin Buzzard of Imperial College London, one of the leading figures in mathematical formalization and the architect of the FLT Lean project that provided critical infrastructure for this run, responded with exceptional praise. He called Claude’s achievement an “extraordinary autoformalization achievement” and said it “points toward automatic formalization of modern mathematics.” Buzzard’s endorsement carries significant weight: he has spent years working on the foundations that made this project possible, and his assessment signals that the mathematical community views this as a genuine milestone rather than a publicity exercise.

The broader implications extend across both AI and mathematics. For the AI field, this demonstrates that large language models operating as coordinated multi-agent systems can tackle problems requiring sustained, precise, multi-layered reasoning over weeks, not just sessions. For mathematics, it opens the possibility of machine-assisted verification of research-grade proofs at scale, potentially catching errors in published work and accelerating the pace at which new results can be checked and built upon.

The competitive landscape also shifts with this announcement. While other AI labs have demonstrated strong mathematical reasoning benchmarks, completing a formal verification task of this depth and complexity using an agentic system is a new data point. It is likely to prompt renewed investment in formal mathematics capabilities across the industry, as the use cases for verified AI reasoning span finance, cryptography, aerospace, and pharmaceutical research.

What Comes Next

Anthropic has made the formalization artifacts publicly available, allowing the mathematics and AI research communities to examine, build on, and stress-test the work. The Lean code and the 30,300 proved theorems represent a substantial contribution to Mathlib and the broader formal mathematics ecosystem, independent of any commercial application.

The more immediate question is whether similar agentic approaches can be applied to other major open problems in formal verification, as well as to newly published research that has not yet been machine-checked. Buzzard and others in the formalization community have pointed to a long backlog of important theorems where a computer-verified proof would be valuable but has not yet been produced. If Claude’s multi-agent framework can be refined and applied more broadly, the pace of that work could accelerate substantially over the coming months and years.

Conclusion

Claude’s completion of the first computer-verified formalization of Fermat’s Last Theorem marks a meaningful boundary crossed in what AI systems can accomplish in formal, rigorous domains. Built on years of community mathematical infrastructure and enabled by a parallel multi-agent architecture running for 11 days, the achievement demonstrates that AI is no longer limited to reasoning tasks where approximate answers are acceptable. As Anthropic and others refine these systems, the intersection of artificial intelligence and formal mathematics is likely to become one of the defining technical frontiers of the next several years.

Stay updated on the latest AI news at Evolve Digital.

Comments

Leave a Reply

Your email address will not be published. Required fields are marked *