Research

Paper

AI LLM February 19, 2026

What to Cut? Predicting Unnecessary Methods in Agentic Code Generation

Authors

Kan Watanabe, Tatsuya Shirai, Yutaro Kashiwa, Hajimu Iida

Abstract

Agentic Coding, powered by autonomous agents such as GitHub Copilot and Cursor, enables developers to generate code, tests, and pull requests from natural language instructions alone. While this accelerates implementation, it produces larger volumes of code per pull request, shifting the burden from implementers to reviewers. In practice, a notable portion of AI-generated code is eventually deleted during review, yet reviewers must still examine such code before deciding to remove it. No prior work has explored methods to help reviewers efficiently identify code that will be removed.In this paper, we propose a prediction model that identifies functions likely to be deleted during PR review. Our results show that functions deleted for different reasons exhibit distinct characteristics, and our model achieves an AUC of 87.1%. These findings suggest that predictive approaches can help reviewers prioritize their efforts on essential code.

Metadata

arXiv ID: 2602.17091
Provider: ARXIV
Primary Category: cs.SE
Published: 2026-02-19
Fetched: 2026-02-21 18:51

Related papers

Raw Data (Debug)
{
  "raw_xml": "<entry>\n    <id>http://arxiv.org/abs/2602.17091v1</id>\n    <title>What to Cut? Predicting Unnecessary Methods in Agentic Code Generation</title>\n    <updated>2026-02-19T05:29:32Z</updated>\n    <link href='https://arxiv.org/abs/2602.17091v1' rel='alternate' type='text/html'/>\n    <link href='https://arxiv.org/pdf/2602.17091v1' rel='related' title='pdf' type='application/pdf'/>\n    <summary>Agentic Coding, powered by autonomous agents such as GitHub Copilot and Cursor, enables developers to generate code, tests, and pull requests from natural language instructions alone. While this accelerates implementation, it produces larger volumes of code per pull request, shifting the burden from implementers to reviewers. In practice, a notable portion of AI-generated code is eventually deleted during review, yet reviewers must still examine such code before deciding to remove it. No prior work has explored methods to help reviewers efficiently identify code that will be removed.In this paper, we propose a prediction model that identifies functions likely to be deleted during PR review. Our results show that functions deleted for different reasons exhibit distinct characteristics, and our model achieves an AUC of 87.1%. These findings suggest that predictive approaches can help reviewers prioritize their efforts on essential code.</summary>\n    <category scheme='http://arxiv.org/schemas/atom' term='cs.SE'/>\n    <published>2026-02-19T05:29:32Z</published>\n    <arxiv:primary_category term='cs.SE'/>\n    <author>\n      <name>Kan Watanabe</name>\n    </author>\n    <author>\n      <name>Tatsuya Shirai</name>\n    </author>\n    <author>\n      <name>Yutaro Kashiwa</name>\n    </author>\n    <author>\n      <name>Hajimu Iida</name>\n    </author>\n  </entry>"
}