TL;DR
Imagine acing a coding problem, only to fail the exam because your error message missed an unrequested comma. That happens constantly to AI coding agents on popular software engineering benchmarks, where hidden grading tests enforce arbitrary details never mentioned in the instructions. This paper introduces an automated LLM-judge pipeline to catch these "overspecified" tests cheaply and accurately—revealing that up to a third of our gold-standard benchmark tasks are unfairly failing valid code and scrambling leaderboard rankings.
What Problem Does This Paper Address?
When we evaluate AI coding agents on benchmarks like SWE-bench, the setup mimics real life: the agent gets a codebase and a GitHub issue (the specification), writes a code fix (a patch), and gets graded by hidden unit tests.
Here’s the catch: those grading tests are pulled directly from the human pull request that originally solved the issue. They were written to verify one specific fix, not every valid fix. If an issue asks to "prevent a crash on large date inputs," the test might check that the function returns the exact sentinel string "0-0-0". An agent that prevents the crash in another completely reasonable way fails the test.
While researchers have built automated tools to catch weak tests (which let buggy code pass), catching overspecified tests (which reject good code) has relied on grueling, expensive human audits. A failing patch proves nothing on its own—it might be genuinely broken, or it might be a great fix rejected by a picky test. The authors ask: can we detect overspecified tests automatically from the task text and test patch alone?
Methods
The authors introduce the Spec-Test Coverage Gap (STCG), a 1–4 scale measuring how far evaluation tests stray beyond what the agent was actually told. They ask a simple guiding question: If competent developers read the specification without seeing the original fix or tests, would every reasonable, correct fix pass?
To automate this, they use a two-judge LLM panel (claude-opus-5-5 and gpt-6.1-sol). Crucially, the judges only see the problem specification and the test patch—not the repository or the human reference fix. This prevents the models from anchoring on how the original developer happened to solve it. A task is flagged as overspecified only when both judges score it a 3 or 4.
To prove the flags aren't just LLM hallucinations, the authors add executable confirmation. Using claude-opus-5-5 as a "relaxer," they automatically loosen the unstated requirements in flagged tests. A relaxed test is strictly validated: it must still fail on the broken code, pass the human fix, and pass previously succeeding agent patches. Finally, they regrade thousands of previously failed patches from top AI agents—without re-running the agents themselves.
Datasets
Instead of doing new manual labeling, the authors cleverly assemble a 344-task validation dataset from existing human audits and public agent runs (split 40% dev, 60% test):
- Known-overspecified: 112 tasks excluded by OpenAI's human annotators when creating SWE-bench Verified specifically due to overly narrow tests, plus 75 unrepaired tasks from SWE-bench Pro flagged by community audits.
- Known-fine: 157 SWE-bench Verified tasks cleared by human annotators and solved by $\ge$90% of top leaderboard agents using diverse code patches.
After validation, they evaluate full benchmarks: all 500 SWE-bench Verified tasks and 731 public SWE-bench Pro tasks, alongside 2,186 failed patches from the top 30 public Verified leaderboard submissions.
Key Insights and Ideas
- Human screening misses a lot: SWE-bench Verified was explicitly curated by humans to filter out bad tasks, yet nearly a quarter of its tests still enforce unstated details.
- "Hard" tasks are often just unfair: Agents aren't just struggling with complex logic on the hardest remaining benchmark tasks—they are frequently hitting invisible walls. Flagged tasks have an average solve rate 57 percentage points lower than unflagged ones, and that penalty holds across every difficulty level.
- Unstated details warp the leaderboard: When overspecified tests are relaxed, over half of the failing agent patches suddenly pass. If counted, nearly every top-30 coding agent changes rank—meaning current leaderboards partly measure which model got lucky guessing unstated test trivia (or memorized it during training).
Key Results
- High detection accuracy: On the held-out test split, the two-judge panel catches 89% of known-overspecified tasks with only a 4% false-flag rate (requiring both judges to agree slashes GPT's solo 18% false-flag rate).
- Widespread prevalence: The panel flags 23% (117/500) of SWE-bench Verified and 35% (258/731) of public SWE-bench Pro tasks.
- Steep agent drop-off: Top-30 Verified submissions resolve 88% of unflagged tasks on average, compared to just 31% of flagged tasks.
- Massive flip rates upon relaxation: Relaxing flagged tests causes 61% (1,331 of 2,186) of candidate failed patches to pass. On unflagged control tasks, the relaxer declines to change 100% of tests when allowed; even when forced to loosen them, only 29% of patches flip. Counting flipped patches adds 33 to 60 solved tasks per submission (up to +12 percentage points), shifting 28 of the top 30 leaderboard ranks.
Limitations and Future Work
The authors are admirably candid about their boundaries:
- Flips are upper bounds, not proofs: Checks ensure relaxed tests still catch the original bug, nothing stops a relaxed test from becoming too permissive and accepting a subtly broken patch.
- No repository context: Because judges don't see the broader codebase, they might miss implicit repository conventions that would make an "unstated" requirement obvious to a human developer.
- Missing Pro baselines & judge overlap: There is no "known-fine" validation set or executable confirmation for SWE-bench Pro yet, and the test relaxer uses the same underlying model (
claude-opus-5-5) as one of the judges.
For future work, the authors suggest flipping the repair—updating the specification to tell agents what the tests expect rather than loosening the tests—and using overspecified details as a clever probe for training data contamination (since passing an unstated literal check without repo context hints that a model might remember the PR from pretraining).
Summary updated