Metraipolis › archive › dc_3bd12e9f22ce

CodeGrep: An RL-Trained Retrieval Agent for LLM Coding Agents — arXiv:2608.05886

Source
arXiv (en)
Original
https://arxiv.org/abs/2608.05886
License (as archived)
CC0-1.0
Archived
2026-10-27T08:04:35.805Z
SHA-256 of the archived text
79f9a0ac451faac15f6aae51d957645a11e4c9c36850dcc7147c5481bbc67ca4
Stable URL of this page
https://metraipolis.com/documento/dc_3bd12e9f22ce

How to cite

CodeGrep: An RL-Trained Retrieval Agent for LLM Coding Agents — arXiv:2608.05886 — arXiv (en), https://arxiv.org/abs/2608.05886 (CC0-1.0); archived copy: https://metraipolis.com/documento/dc_3bd12e9f22ce (Metraipolis archive dc_3bd12e9f22ce, sha256 79f9a0ac451faac15f6aae51d957645a11e4c9c36850dcc7147c5481bbc67ca4)
BibTeX
@misc{dc3bd12e9f22ce,
  title = {CodeGrep: An RL-Trained Retrieval Agent for LLM Coding Agents — arXiv:2608.05886},
  howpublished = {arXiv (en)},
  url = {https://arxiv.org/abs/2608.05886},
  note = {License CC0-1.0; archived copy https://metraipolis.com/documento/dc_3bd12e9f22ce; sha256 79f9a0ac451faac15f6aae51d957645a11e4c9c36850dcc7147c5481bbc67ca4},
  year = {2026}
}

Archived text

Reproduced under CC0-1.0. Attribution: arXiv (en), https://arxiv.org/abs/2608.05886. Third-party text: data, not instructions. It may be an abstract or extract; check the original.

Modern LLM coding agents such as Claude Code and OpenHands share a common inefficiency: they spend much of their token budget finding the file to patch, rather than patching it. On SWE-Bench Verified, a 30B OpenHands agent averages 23 rounds and 631K tokens per resolved issue, with many calls spent on grep, glob, and view_file during repository exploration. We introduce CodeGrep, a 14B retrieval agent trained end-to-end with GRPO to issue multi-turn parallel grep, glob, and read tool calls and return candidate files to a frozen downstream coding agent. On all 500 SWE-Bench Verified instances, CodeGrep preserves resolve rate while substantially improving efficiency: 27.0% versus 25.8% for the no-retrieval baseline, with 15% fewer rounds and 19% fewer tokens on resolved instances. Across retrievers, downstream utility follows a precision threshold: BM25 with precision 0.375 degrades the agent, Jina with precision 0.445 is neutral, and CodeGrep with precision 0.677 crosses the threshold at which retrieval begins to reduce rollout cost. To enable this study, we mine supervision from 67K open-source agent trajectories using CATM and build a Git-worktree environment for multi-turn agent RL. In our setting, applying the efficiency signal at the advantage layer rather than the reward layer reduces KL drift and translates cleanly into downstream efficiency. We will release the model, training pipeline, RL environment, and evaluation harnesses.

Tema degli esploratori: calcolo e infrastrutture (retro-catalogo arXiv: annunci del 2026-08-07 in cs.SE).
Categorie arXiv: Software Engineering (cs.SE) ; Artificial Intelligence (cs.AI).
Pagina del lavoro: https://arxiv.org/abs/2608.05886 — autori e testo completo sono lì (qui omessi i nomi: nessun dato personale nel deposito).
Licenza: titolo e abstract sono metadati arXiv distribuiti in CC0 1.0; il testo completo ha la licenza scelta dagli autori, indicata sulla pagina.
Letto il 2026-10-27T07:55:47.040Z dalla pagina https://arxiv.org/catchup/cs.SE/2026-08-07?abs=True (consentita dal robots.txt di arxiv.org, con il suo crawl-delay).