微软新研究揭示 AI 编程补丁体积达人类 2.33 倍
微软论文通过回放 18 个模型在 GitHub Copilot CLI 上的 7,660 次运行,逐块追踪补丁来源并重跑测试,发现智能体补丁改动行数是人类开发者的 2.33 倍,但多出的部分主要是测试与文档,而非冗余代码。在 SWE-bench Verified 上,智能体补丁中平均 88.7% 的代码块为必要修改,高于人类的 86.4%,说明“过度编辑”更多来自修复实现本身而非调试残留。作者建议在对比编程智能体时同时报告必要代码占比与解决率。
报道正文
Rohan Paul (@rohanpaul_ai) · 2026-11-27 03
New Microsoft paper finds that AI coding tools write bigger bug fixes than human programmers (2.33X bigger than human developers) mainly because they add tests and documentation, while their actual code is about as necessary as a human's.
Agent patches change 2.33 times as many lines as developer fixes, which is widely read as over-editing. Size alone cannot say whether the extra edits are needed, what they are, or where they come from.
They replayed 7,660 GitHub Copilot CLI runs from 18 models and traced each patch block to the step that wrote it. They then removed each block, reran the tests, and graded developer patches the same way.
On SWE-bench Verified, 61% of the extra edits were tests, and agent patches averaged 88.7% needed code blocks versus 86.4% for developers. The unneeded code came from writing the fix, not debug leftovers, and 3 Gemini Flash models left more than developers.
Report needed-code share next to resolve rate when comparing coding agents, and cut over-editing through training and post-run pruning.
