Hovhannes Tamoyan, Sean Narenthiran, Erik Arakelyan, Mira Mezini, Boris Ginsburg
A framework that reduces the cost of fault localization for code repair agents and improves their performance by providing structured diagnostic context.
LLM agents solving repository-level coding tasks spend about half their budget on locating faults before editing. Existing localization frameworks are evaluated as simple file retrieval without the diagnostic context needed by repair agents.
SHERLOC is a training-free framework that pairs a reasoning LLM with compact repository tools, without fine-tuning or multi-agent orchestration. It uses structured hypothesis-driven exploration and self-recovery to locate faults and provide diagnostic information.
SHERLOC achieves state-of-the-art localization with 84.33% accuracy@1 on SWE-Bench Lite and 81.27% recall@1 on SWE-Bench Verified. Injecting its locations and diagnostic findings into repair agents yields an average +5.95 pp resolve rate improvement on SWE-Bench Verified while cutting localization and total tokens by 36.7% and 23.1% respectively.