微软单模型统一 Copilot 代码补全与编辑 输出 token 降 59%

原标题:New Microsoft paper shows that a single model can handle code completion, nearby edits, and far-away...
72AI 研判分

微软论文提出用单一模型统一 Copilot 的代码补全、邻近编辑与远距离编辑,所有建议以 diff patch 形式输出,多次编辑可合并进一次响应并复用缓存。线上 A/B 测试显示,首个合并模型将展示时延降低 6.77%、输出 token 减少 58.93% 且无可测质量损失;最终三合一模型单独使用时被忽略建议上升 12.24%,经客户端调整后转为下降 10.06%。

报道正文

Rohan Paul (@rohanpaul_ai) · 2026-11-30 06:59

New Microsoft paper shows that a single model can handle code completion, nearby edits, and far-away edits in Copilot by writing every suggestion as a diff patch. And cuts output tokens by 58.93% with no measurable quality loss.

Copilot used to call separate models for completing code, editing nearby lines, and editing far away, in a fixed order. That cost several model calls per suggestion.

They trained 1 model that outputs a list of diff patches, each saying where to edit and what to change. Several edits fit in 1 response, so later ones come from a cache.

In live A/B tests against the 3-model setup, the 1st merged model cut time to display by 6.77% and output tokens by 58.93%. The final 3-in-1 model alone raised dismissed suggestions by 12.24%, but client changes turned that into a 10.06% drop.

推文配图