arXiv:2610.27381cs.SEOct 2026

Manuscript Offprint

arXiv:2610.27381

Documentation Drift in AI-Generated Pull Requests

Will De Michele, Kla Tantithamthavorn

Open access. PaperVantage converted this article to text, so layout and figures may differ from the original. This text is shared under the same licence.

Will De Michele

Monash University

Melbourne, Australia

Kla Tantithamthavorn

Monash University

Melbourne, Australia

Abstract—AI coding agents now contribute to software repositories at scale, yet their documentation practices remain uncharacterised. We analyse 29,669 AI-generated pull requests from 2,585 repositories in the AIDev dataset, measuring documentation co-change: whether code-file modifications are accompanied by a documentation-file update within the same PR. We find that 63.2% of AI PRs change code without co-updating any documentation, varying sharply by task type (feature 55.2% vs. refactor 77.5%). Drift is associated with later fixes: undocumented code files are followed by a same-file fix 8.6–11.7% more often than documented ones across 30–90 day windows. (A raw PR-level comparison shows the opposite because documented PRs are 3.9× larger and so attract more fixes; controlling for size exposure reverses it.) Documented changes also merge faster despite their larger size (median 40s vs. 184s), although merging here is largely automated. Drift also compounds: a file changed without documentation is later re-documented at roughly half the rate of one changed with documentation (24% vs. 48% within 90 days), so documentation debt tends to accumulate rather than being revisited.

Index Terms—AI coding agents, documentation maintenance, pull requests, documentation drift.

I. INTRODUCTION

Documentation is widely recognised as a basis of software maintenance [1], [2]. When code evolves without corresponding updates to its documentation, the resulting inconsistency, termed documentation drift, may increase defect rates, raise maintenance costs, and hinder developer comprehension [1], [2]. Co-changing code and documentation within a single contribution mitigates this risk, keeping knowledge artefacts aligned with the codebase.

AI coding agents (GitHub Copilot, Cursor, Devin, Claude Code, OpenAI Codex) now autonomously generate code and create pull requests (PR) at scale. While prior work has examined agentic code quality [3], security [4], and testing [5], little is known about how these agents maintain documentation alongside the code they produce.

We conduct a large-scale analysis of documentation drift in AI-authored pull requests: for each PR we measure whether code changes are accompanied by documentation updates (taking the absence of any documentation co-change as an observable proxy for drift), and how this relates to resolution time and to later fix activity in the same files. Through an empirical study of 29,669 AI-generated PRs across 2,585 repositories from the AIDev dataset [6], we answer three research questions:

RQ1) What is the prevalence of documentation drift in AI-generated pull requests?

63.2% of AI-generated PRs change code without co-updating documentation, and this rate varies sharply by task type (feature 55.2% vs. refactor 77.5%); every agent drifts in 48–73% of its PRs.

RQ2) Is drift associated with merge time or with subsequent same-file fixes?

Yes. Undocumented files are followed by a same-file fix 8.6–11.7% (relative) more often than documented ones across 30–90 day windows, and documented changes merge faster despite being larger.

RQ3) Does drift persist: is code changed without documentation later re-documented?

Drift persists: a file changed without documentation is re-documented at half the rate of one changed with documentation (24% vs. 48% within 90 days).