Home / Companies / Sourcegraph / Blog / Post Details
Content Deep Dive

Why coding agents fail in large codebases (and what to do about it)

Blog post from Sourcegraph

Post Details
Company
Date Published
Author
Stephanie Jarmak
Word Count
1,749
Language
English
Hacker News Points
-
Summary

Analysis of 1,281 agent runs across over 40 large open-source repositories has identified five recurring failure patterns in coding agents, highlighting the significance of context infrastructure over model intelligence. Coding agents, when tasked with navigating large codebases like Kubernetes, often fail due to inefficient search strategies that result in being lost within the codebase, selecting wrong files or symbols, completing tasks partially, excessive tool thrashing, and context overflow. These failures stem from the lack of effective search tools and context management, not from the agents' reasoning capabilities. The research emphasizes the importance of investing in code search and indexing infrastructure, structural navigation tools, and task-type-aware retrieval systems to enhance agent efficiency. By addressing these infrastructure issues, agents can achieve better performance, demonstrating that the solution lies in improving the interface between the model and the codebase, rather than solely relying on advancements in model capabilities.