The Spectrum Dispatch News

technology

Claude Code Team Uses Verification Loops to Scale AI-Written Code to Production

Anthropic's Claude Code team implements end-to-end, property, and differential tests to let AI agents verify their own work, enabling parallel code generation at scale.

Claude Code Team Uses Verification Loops to Scale AI-Written Code to Production

The Claude Code team at Anthropic has developed a verification-focused approach to managing code at scale, with approximately 90% of their code written and reviewed by Claude. The core insight is that verification loops enable delegation: without them, teams must check every output manually, limiting parallel work. With proper verification, dozens or hundreds of agents can run simultaneously.

Claude Code Team Uses Verification Loops to Scale AI-Written Code to Production

According to internal testing on structured file generation tasks, having a separate grader check Claude’s work against a rubric improved task success by up to 10 percentage points compared to standard prompting, with the largest gains on harder problems.

The team prioritizes three test types. End-to-end tests are considered most valuable because they describe real user flows and are difficult to fool—either a feature works or it doesn’t. E2E tests provide definitive done criteria and clearly show what’s broken, unlike unit tests which can pass while still breaking features. The team equips agents with hands-on access to running systems using tools like Chrome DevTools Protocol, simulators, or API harnesses.

Property tests address edge cases that humans typically miss and where agents often fail. Rather than testing specific scenarios, property testing uses libraries (fast-check for JavaScript/TypeScript, Hypothesis for Python, proptest for Rust) to generate thousands of inputs attempting to break a statement that shouldn’t fail.

Differential tests work well for large-scale migrations where functionality should remain unchanged. The approach runs both old and new systems with identical inputs, flagging any differences that indicate bugs or breaking changes. The team uses randomly generated inputs or production traffic samples, normalizing irrelevant factors like whitespace.

Beyond test types, the team emphasizes running the entire application end-to-end before committing changes—treating it like smoke testing. They create a “verify” skill placed in .claude/skills/ folders that Claude uses automatically. The team also maintains a reliability checklist with 39 items, each tied to specific triggers readable from code diffs. This prevents the need to memorize past outages.

For code review, the team uses check failures to determine what requires human review. If a check fails after three rounds of Claude’s attempts to fix it, a human reviewer is brought in. The team avoids stacking multiple reviewers, instead tuning primary checks and using context from earlier rounds rather than re-checking from scratch. Critically, review rules are stored on a branch the change cannot modify, preventing code from altering the checks that judge it.

Key facts

  • ~90% of Claude Code team’s code is written and reviewed by Claude
  • Verification loops enable dozens or hundreds of agents to run in parallel instead of sequential review
  • Structured file generation tasks showed up to 10-point success improvement with separate verification
  • E2E tests are prioritized as most effective because they test real user flows and are difficult to fool
  • Property tests use libraries to generate thousands of inputs to find edge cases agents miss
  • Differential tests compare old and new systems to catch bugs during large-scale migrations
  • Team maintains 39-item reliability checklist with triggers readable from code diffs
  • Human review is triggered when checks fail after three rounds of automated fixes

Sources

← All posts