AdvertiseDonate
Verified Forum · 1040 Monarch Street, 3rd Floor, Lexington, KY 40513
Tech · AI

Claude Generates Proofs for Existing Code

Anthropic's model produced millions of lines of verification code for open-source libraries while catching numerous bugs.

By Robert Mensah ·

Illustration for: Claude Generates Proofs for Existing Code
Illustration generated for this article, not a news photograph.

Anthropic has deployed its Claude model to mathematically verify the safety of existing software code. The company states this method generates formal proofs of correctness for programs, moving beyond standard testing. This capability could increase trust in automated software creation. Anthropic intends for formal verification to become as routine as conventional testing.

Formal verification has historically been too costly for widespread use. Specialists required 20 person-years to verify the seL4 operating system kernel. Consequently, such methods were reserved for high-stakes applications like Airbus avionics software. Anthropic's Frontier Red Team and partner Theorem utilized Claude to automate this process.

The model produced approximately 180 million lines of proof code in a few weeks. This work covered 123 open-source libraries from Google's OSS-Fuzz security project. Claude did not write new code. Instead, it analyzed existing crash tests and compiled machine code to generate proofs. An independent tool, Rocq, checks these proofs automatically. The researchers describe the generation as fully autonomous, though human teams built the necessary tools and foundations.

While generating proofs, Claude identified hundreds of bugs that conventional testing missed. Many flaws appeared only under specific conditions, such as very large input files. During one week verifying a PDF reader, the team found as many security bugs as are typically reported for that software in a year. In another instance, Claude located a logical error undetected for over a decade. Anthropic notes that even when a proof fails, the attempt can reveal real bugs.

Anthropic acknowledges limitations regarding these proofs. A status of formally verified does not mean error-free. The proofs hold only under strict conditions, such as a specific processor architecture and single-threaded programs. They also require inputs under 64 MB. In practice, these libraries operate on different hardware and configurations. The compute cost is high, with individual proofs reaching hundreds of millions of tokens. Anthropic does not report the total project costs.

If AI can verify its own code, developers can trust generated software more. This reduces time spent on reviewing code. Anthropic states this lowers costs for verification and the coding process. A smaller test run indicated proofs are reusable. Newer models are also becoming more efficient. Opus 5.5 solves half the proofs with about 40 percent fewer tokens than Opus 5.

Anthropic expects formal verification with AI to become practical soon. The company aims to make this process as routine as standard testing. Theorem's roadmap targets critical infrastructure. Planned targets include glibc, OpenSSL, and cURL.

More Tech · Report a business · Got a Story?

Get Verified Forum in your inboxYour daily read on the news. Free, a few times a week, unsubscribe any time.

Related stories

Get Verified Forum in your inboxYour daily read on the news. Free, a few times a week, unsubscribe any time.