How the Claude Code team does code review
- Context & Scale: With Claude writing ~90% of Claude Code's codebase and changes across Anthropic's monorepo surging from 2,500/day to >30,000/day, the team transitioned from manual line-by-line review to an automated, multi-layered pipeline, more than doubling merged PRs while reducing reverts by over 40%.
- Core Philosophy: Treats human attention as the scarce bottleneck, reframing code review from an end-of-process human gate to continuous, automated validation paired with fast rollback mechanisms; success is measured by human review hours without increases in reverts or incidents.
- The Seven Review Layers:
- 1. Pre-PR Verification: Claude must execute verifiable tests, builds, or browser runs before opening a PR; a fresh-context subagent reviews the diff against project guidelines (
CLAUDE.md,REVIEW.md). - 2. Automated AI Review: Multi-agent reviews analyze the entire repo and intent; bug-hunting agents propose findings that a voting panel of verifier agents filters (dropping nits/style) and ranks by severity (Important, Nit, Pre-existing).
- 3. Dedicated Security Review: An automated security pass runs independently; unresolved findings from either AI bug review or security review strictly block merges until fixed or dismissed with explicit rationale.
- 4. Standard CI Gates: Cross-platform builds, type checks, linting, and automated test suites must pass completely.
- 5. Risk-Based Human Approval: A classifier categorizes risk tiers to determine human oversight:
- Low Risk (docs, copy, internal-only, flag-guarded changes): Zero human approvals needed once automated checks and AI reviews pass.
- Medium Risk (standard features, caching, system prompts, auto-updater): Exactly one human approval.
- High Risk (critical paths, CI workflows, designated sensitive files): Requires two human approvals.
- 6. Merge Queue & Gradual Rollout: Validates changes against latest
mainvia merge queues to avoid integration drift, followed by employee-dogfooding behind feature flags and staggered channel releases (latest vs. stable). - 7. Rapid Detection & Fast Rollback: Emphasizes quick flag deactivation and immediate reverts over lengthy fixes, conducting post-incident reviews to identify which upstream layer failed.
- 1. Pre-PR Verification: Claude must execute verifiable tests, builds, or browser runs before opening a PR; a fresh-context subagent reviews the diff against project guidelines (
- Ownership Model ("You Land It, You Own It"): The engineer directing the agent is fully responsible for the changes and counts as an author/reviewer; AI approvals can never substitute for required human slots.








and one more:

