← News

Agents & MCPSources: arXiv · 4 Dec 2026

Short prompt curbs over-engineering in AI coding agents, study finds

Researchers define and measure over-engineering in coding agents, then show a minimal-change prompt instruction cuts excess code without clearly changing resolution rates.

In plain words

AI coding agents often solve a task but add extra code nobody asked for, such as tests or documentation. Researchers built a score to measure this and found a short instruction telling the agent to make only the minimal change cuts that excess substantially. Task success rates stayed roughly the same.

What was announced

A study on arXiv formalizes over-engineering in AI coding agents: correct solutions that carry far more code than needed, including unrequested tests, documentation, refactoring and error handling. The authors introduce the Over-Engineering Score (OES), a family of metrics comparing the size and location of an agent's patch against a reference solution. Analyzing 6,790 agent-task pairs from 14 public agents on SWE-bench Verified, they report over-engineering is pervasive, with median OES between 0.67 and 8.20 times the reference size depending on the agent.

The paper also identifies a "Goldilocks zone": patches 1 to 1.5 times the reference size had the highest resolution rate, 59.6 percent, versus 34.8 percent for patches above 10 times, an association that held under difficulty controls. As an intervention, a short system-prompt constraint telling the agent to make the minimal change and skip tests, documentation, type annotations, error handling or refactoring unless asked reduced mean OES by 40 percent across 14 models from 7 providers, with 13 of 14 models improving. Much of the removed code was unrequested tests; excluding test files, the reduction was 14 percent. The prompt also cut input tokens per task for 13 of 14 models, by up to 42 percent. However, resolution rates did not change significantly in aggregate on any benchmark, and per-model effects went both ways.

What it does not show

  • The findings come from the paper's abstract only, so method details and full results are not covered here.
  • Resolution rates did not change significantly in aggregate, and per-model effects went both ways, so the prompt does not reliably improve task success.

Sources

Source-support review completed 4 Dec 2026. This story was drafted with AI assistance and checked against retained source passages. Automated checking is not independent verification.

Coverage: arXiv: abstract.

Updates and corrections

No corrections so far.

First published 4 Dec 2026

New to the subject? AI from the Ground Up starts from the beginning.