Los AngelesNew YorkChicagoHoustonPhoenixPhiladelphiaSan FranciscoSeattleAtlantaBoston
Tech · AI

Anthropic and Theorem Deploy Claude to Automate Mathematical Verification of Open-Source Software

A new workflow uses AI to generate formal proofs for code, uncovering latent bugs that traditional testing methods failed to detect.

By Dmitri Sokolov ·

Anthropic, in collaboration with partner Theorem, has demonstrated a new capability for its Claude model to mathematically verify the correctness of existing software. By integrating AI with formal verification techniques, the companies aimed to address a persistent challenge in software development: ensuring that code functions without errors across all possible conditions. The initiative represents a significant shift in how software reliability is assessed, moving beyond conventional testing toward rigorous mathematical proof generation.

The scale of the operation was substantial, with Claude generating approximately 180 million lines of proof code over a period of just a few weeks. This effort covered 123 open-source libraries sourced from Google’s OSS-Fuzz security project. The model did not write new software but instead translated crash tests into mathematical problems and analyzed compiled machine code to produce extensive proofs. An independent verification program named Rocq automatically checks these proofs, a process that Anthropic states requires minimal human review, leading the researchers to describe the workflow as fully autonomous, despite the human-built foundational tools provided by Theorem.

The project involved a specialized team from Anthropic’s Frontier Red Team working alongside Theorem. Historically, formal verification has been a resource-intensive endeavor reserved for critical systems. For instance, a team of specialists previously required 20 person-years to verify the small operating system kernel seL4, and the method was largely confined to extreme cases such as Airbus avionics software. By leveraging AI, Anthropic sought to reduce the barrier to entry for this rigorous form of validation, making it more accessible for a broader range of software applications.

During the verification process, Claude identified hundreds of bugs that had eluded conventional testing methods. Many of these defects only manifested under highly specific conditions, such as unusually large input files or particular sequences of data access. In one notable instance, while verifying a widely used PDF reader, the team discovered as many security vulnerabilities in a single week as are typically reported for that software over an entire year. Additionally, Claude detected a logical error in another application that had remained undetected for more than a decade. Even when a complete proof could not be established, the attempt still surfaced real-world bugs.

Despite these successes, Anthropic notes that the term "formally verified" does not equate to absolute error-free status. The proofs are valid only under strict conditions, including a specific processor architecture, single-threaded program execution, and input sizes under 64 megabytes. In practical deployment, these libraries often operate on diverse hardware and configurations. The computational cost is also considerable, with individual proofs consuming up to hundreds of millions of tokens. Anthropic has not disclosed the total project costs, but the efficiency gains are evident in model performance; Opus 5.5 solves half the proofs using approximately 40 percent fewer tokens than its predecessor, Opus 5.

The implications of this technology extend to the broader automation of software development. If AI can both write code and prove its correctness under defined parameters, developers may place greater trust in AI-generated software, reducing the time spent on manual review. This efficiency could lower costs not only in verification but throughout the entire coding lifecycle. A smaller test run indicated that proofs are reusable, suggesting that the methodology offers long-term value as models become more efficient.

This advancement shifts the central question in AI programming from whether machines can code to whether they can guarantee the safety of that code. Anthropic anticipates that formal verification using AI will soon become as routine as standard testing. Theorem’s roadmap already targets critical infrastructure components, including glibc, OpenSSL, and cURL, indicating a clear trajectory toward securing foundational software systems with AI-driven proofs.

Source: The Decoder

Get Hot Herald Report in your inboxBig-city news, all in one place. Free, a few times a week, unsubscribe any time.

More from AI

Get Hot Herald Report in your inboxBig-city news, all in one place. Free, a few times a week, unsubscribe any time.