From Agent Behaviour to Agent-Friendly Documentation: An Empirical Study of How Coding Agents Discover, Read, and Write Technical Documentation

2026-08-21

Authors: Zhijun Gao, Jing Chen

ArXiv: 2608.20195v1

PDF: Download PDF

For decades, technical documentation — READMEs, API references, contribution guides — has been written with one reader in mind: a human developer squinting at a screen with a cup of coffee. But increasingly, the "developer" opening your repository isn't human at all. It's an autonomous coding agent (think Claude Code, Cursor, or SWE-agent) that reads files, edits code, and opens pull requests. This paper asks a surprisingly under-studied question: what do these agents actually do with documentation?

The authors mined two large public datasets: 557 coding sessions from SWE-chat (yielding nearly 95,000 development events and 3,033 documentation interactions), plus 33,097 agent-authored pull requests from AIDev. They tracked when agents opened docs, which ones they consulted, what they did afterward, and — when agents wrote docs themselves — what those docs looked like compared to human-authored ones.

A few findings stand out:

The practical implication is a call for "agent-friendly documentation" — a design discipline that treats LLM agents as a first-class audience. That means structured sections agents can locate with a single grep, examples that are self-contained rather than referring back to earlier prose, and explicit "if you're modifying X, read Y first" pointers that a machine can follow. It's not about dumbing docs down; it's about making them navigable for a reader that lands cold, reads 40 lines, and has to make a decision.

It's also a quiet warning: if agents write an increasing share of tomorrow's documentation, and agent-authored docs are thinner on rationale, we may be heading toward a corpus of technically accurate but contextually hollow docs — the software equivalent of a manual written by someone who's never actually used the product.

Why it matters: As coding agents become a dominant "reader" of technical docs, projects that adapt their documentation for machine consumption will get measurably better automated contributions than those that don't.

All newsletters