Will It Survive? Deciphering the Fate of AI-Generated Code in Open Source
Musfiqur Rahman, Emad Shihab

TL;DR
This study analyzes the longevity and modification patterns of AI-generated code in open source projects, revealing it survives longer than human code but faces different modification dynamics, with organizational factors influencing its long-term viability.
Contribution
It provides empirical evidence that AI-generated code persists longer than human code and highlights the importance of organizational practices over generation quality for its sustainability.
Findings
AI-generated code has a 16% lower hazard of modification.
Agent-authored code shows slightly higher corrective modification rates.
Textual features can predict modification-prone code with moderate accuracy.
Abstract
The integration of AI agents as coding assistants into software development has raised questions about the long-term viability of AI agent-generated code. A prevailing hypothesis within the software engineering community suggests this code is "disposable", meaning it is merged quickly but discarded shortly thereafter. If true, organizations risk shifting maintenance burden from generation to post-deployment remediation. We investigate this hypothesis through survival analysis of 201 open-source projects, tracking over 200,000 code units authored by AI agents versus humans. Contrary to the disposable code narrative, agent-authored code survives significantly longer: at the line level, it exhibits a 15.8 percentage-point lower modification rate and 16% lower hazard of modification (HR = 0.842, p < 0.001). However, modification profiles differ. Agent-authored code shows modestly elevated…
Peer Reviews
No public reviews on file for this paper yet. If you reviewed it on a platform where reviews are public (OpenReview, ICLR, NeurIPS, ICML), you can paste yours below so the community can read it here.
Code & Models
Videos
No videos yet. Explain this paper in a talk, walkthrough, or lecture? Add one.
Taxonomy
TopicsSoftware Engineering Research · Open Source Software Innovations · Software Engineering Techniques and Practices
