# Anthropic's code review approach for AI-written code, explained step by step

> Original title: 推荐阅读，Anthropic 如何做 Code Review！

- Source: Dongxi NLP
- Published: 2026-10-16T21:09:38.000Z
- Bad Influence: https://badinfluence.news/items/f6by1l2u6fvadi8ltc0df6okh
- Original: https://x.com/dongxi_nlp/status/2111202933849178210

## Summary

Dongxi NLP shares a summary of how Anthropic runs code review for Claude Code, where Claude writes about 90% of the code. The author says merged PRs more than doubled from June to September while the share of reverted PRs fell more than 40%, citing Anthropic's own post. The workflow keeps human review but routes most checks to machines, requires humans to approve by risk level (0 for low, 1 for medium, 2 for high), and relies on feature flags, staged rollout, and one-click rollback.

## Post

推荐阅读，Anthropic 如何做 Code Review！

1. 保留 code review，但大部分审核交给机器，人的时间只花在高风险判断上，同时让出错后能快速回滚。

2. 提 PR 前：Claude 自己跑测试和构建，再由一个新开的 agent 审一遍 diff。

3. 每个 PR：AI 多 agent 找 bug，投票过滤掉误报，再加一轮安全审查和 CI。每条发现都必须处理，否则不能合并。

4. 人工审批按风险分级：低风险 0 人，中风险 1 人，高风险 2 人，由分类器判定。bot 的批准不能替代人，驱动 agent 的人对改动负责。

5. 上线：合并队列、feature flag、先内部使用再灰度发布，出问题一键回滚。

6. 持续改进：历史事故整理成每日 eval，用来评估 reviewer。审查轮数设上限，避免 agent 之间无限互审。

## Quoted post @ClaudeDevs

> Claude writes about 90% of Claude Code's code.
> 
> From June to September, merged PRs more than doubled while the share reverted fell by more than 40%.
> 
> We wrote about how we changed code review to get there, and how to adopt it:
> 
> https://claude.dev/blog/solving-code-review-at-anthropic/

https://x.com/ClaudeDevs/status/2111168901723906176
