Ankit Patel
WritingPapersLabsAboutContact
Paper Reviews··2 min read·231 views

Finding Where to Change the Code

SWE-bench · Jimenez et al., ICLR 2024

The same model resolves 1.96% of tasks when it has to find the files and 4.8% when shown them

In Jimenez et al.'s SWE-bench study, Claude 2 resolved 1.96% of repository issues with BM25 search and 4.8% when handed the gold files.

Neither score was high, yet the 2.4x gap isolates an architectural split that single leaderboard numbers hide: finding the right code in a large codebase versus writing a clean patch once you are there. A stronger code generator still fails when retrieval drops it into the wrong module.

SWE-bench builds tasks from merged pull requests across 12 popular Python repositories, totaling 2,294 issues in the initial release. Each evaluation checks out the pre-fix commit, feeds the issue prompt to the candidate system, and runs the test suite against the generated diff. Tests added by the human fix must flip from failing to passing while existing regression tests stay green.

Executing real repository test suites beats static text similarity by a wide margin, as long as reviewers remember what unit tests do and do not verify.

When an issue reports that timestamps render wrong after a timezone shift, the defect might live in UI formatting, cached account settings, JSON serialization, or database storage. An engineer has to localize that behavior before writing a line of code, and so does a coding agent unless an external harness pre-selects the files. Comparing an end-to-end agent that searches a repo against a prompt given oracle file paths compares two different levels of assistance.

Benchmark graders carry defects of their own. OpenAI and the SWE-bench authors released SWE-bench Verified in August 2024, curating 500 human-vetted tasks after finding underspecified issue prompts and overly narrow unit tests that rejected valid fixes. A failed run can indict the patch or the container environment, and a passing run proves only that existing tests stayed green, not that a staff engineer on call would merge the design.

My takeaway for teams evaluating coding agents internally is to borrow SWE-bench's replay discipline on their own closed tickets, provided historical issues are scrubbed of later PR links and Slack resolutions that leak the answer. Track localization hit rate and test pass rate alongside human merge acceptance and compute cost per accepted PR. When an agent scores zero, knowing whether retrieval missed the file or generation broke the invariant tells you what to fix next.

Continue in Paper Reviews