aiqbench analysis
SHERLOC introduces a training-free framework that significantly improves the efficiency of LLM agents in locating and diagnosing code faults, reducing token usage by over 23% while boosting repair success rates. By shifting focus from simple file retrieval to actionable diagnostic reasoning, this method addresses a critical bottleneck where agents previously wasted half their computational budget on fault localization. The approach demonstrates that compact models paired with structured hypothesis-driven exploration can outperform larger agentic systems without requiring fine-tuning or complex orchestration.
SHERLOC: Structured Diagnostic Localization for Code Repair Agents
arXiv:2606.24820v2 Announce Type: replace Abstract: LLM agents solve repository-level coding tasks through multi-turn tool use, but utilize half their budget on locating faults before editing. Dedicated localization frameworks have emerged, yet are still evaluated as file retrieval rather than actionable diagnosis, producing locations without the diagnostic context a repair agent needs. We introduce SHERLOC (Structured Hypothesis-driven Exploration and Reasoning for Localization), a training-free framework pairing a reasoning LLM with compact repository tools and self-recovery, without fine-tuning or multi-agent orchestration. SHERLOC reaches state-of-the-art localization across model scales: 84.33% accuracy@1 on SWE-Bench Lite and 81.27% recall@1 on SWE-Bench Verified; at ~30B parameters, it matches or outperforms other agentic methods. Injecting our locations and diagnostic findings into repair agents yields an average +5.95 pp resolve-rate gain from the best SHERLOC result per setting on SWE-Bench Verified. SHERLOC cuts localization and total tokens by 36.7% and 23.1% on average.
Abstract:LLM agents solve repository-level coding tasks through multi-turn tool use, but utilize half their budget on locating faults before editing. Dedicated localization frameworks have emerged, yet are still evaluated as file retrieval rather than actionable diagnosis, producing locations without the diagnostic context a repair agent needs. We introduce SHERLOC (Structured Hypothesis-driven Exploration and Reasoning for Localization), a training-free framework pairing a reasoning LLM with compact repository tools and self-recovery, without fine-tuning or multi-agent orchestration. SHERLOC reaches state-of-the-art localization across model scales: 84.33% accuracy@1 on SWE-Bench Lite and 81.27% recall@1 on SWE-Bench Verified; at ~30B parameters, it matches or outperforms other agentic methods. Injecting our locations and diagnostic findings into repair agents yields an average +5.95 pp resolve-rate gain from the best SHERLOC result per setting on SWE-Bench Verified. SHERLOC cuts localization and total tokens by 36.7% and 23.1% on average.
Accepted to EMNLP 2026 Main Conference. Code: this https URL
Computation and Language (cs.CL)
arXiv:2606.24820 [cs.CL]
(or arXiv:2606.24820v2 [cs.CL] for this version)
https://doi.org/10.48550/arXiv.2606.24820 Focus to learn more arXiv-issued DOI via DataCite
arXivLabs is a framework that allows collaborators to develop and share new arXiv features directly on our website.
Both individuals and organizations that work with arXivLabs have embraced and accepted our values of openness, community, excellence, and user data privacy. arXiv is committed to these values and only works with partners that adhere to them.
Have an idea for a project that will add value for arXiv's community? Learn more about arXivLabs.
Full text under the publisher's open licence · 243 words
Related coverage

Vertical Advantage: Transforming Industries with Lakebase and Agentic AI
Databricks · Aug 27, 2026
SVRepair: Structured Visual Reasoning for Automated Program Repair
arXiv · Aug 5, 2026
SAAG: Structured Agent Assessment and Grounding
arXiv · Jul 23, 2026

Beyond LLMs: Why Scalable Enterprise AI Adoption Depends on Agent Logic
Hugging Face · Jun 1, 2026