Last updated:
Evaluating AGENTS.md: Are Repository-Level Context Files Helpful for Coding Agents?
Thibaud Gloaguen et al.
In collections: AI Evals Agentic approach AI for coding
A common practice in software development is to tailor coding agents to repositories with context files such as AGENTS.md, by writing them manually or generating them automatically. Although this practice is strongly recommended by agent developers, rigorous research on whether such context files are actually effective in real-world tasks is currently lacking. In this work, we investigate this question and evaluate the performance of coding agents at completing tasks in two complementary settings: established SWE-bench tasks from popular repositories, with context files generated by an LLM following agent developers' recommendations, and a new set of issues from repositories that contain developer-committed context files. Across tests covering multiple coding agents and LLMs, we found that context files tend to lower task success rates compared with providing no repository context at all, while increasing inference costs by over 20%. Behaviorally, both LLM-generated and developer-provided context files encourage broader exploration (e.g. more thorough testing and file traversal), and coding agents tend to follow their instructions. We ultimately conclude that unnecessary requirements in context files make tasks harder, and that human-written context files should describe only minimal requirements.
Strategies from the report:
Measuring the real impact of context: Instead of assuming that extra files like AGENTS.md always help the AI, you should measure their impact on specific tasks. Studies have shown that adding extensive, generated context often even lowers the problem-solving success rate by a few percent.
Focusing on surgical intervention (Surgical Intervention): Context files should resolve only those ambiguities that the code and the agent's built-in tools cannot handle on their own. The report prescribes treating these files as a collection of "expensive truths," not universal documentation.
Looking for the "workspace" (Global Workspace): Isolating the fact that the AI has a special place in its virtual brain where it keeps temporary, important information needed to solve a problem, separating it from the ordinary assembling of sentences.
Support this project by buying me a coffee ;)