次回の更新記事:AIコーディングエージェントのコスト構造を読み解く(公開予定日:2026年05月26日)
AIDB Daily Papers

AI生成PythonリファクタリングPRの品質とセキュリティ:実証的研究

原題: Quality and Security Signals in AI-Generated Python Refactoring Pull Requests
著者: Mohamed Almukhtar, Anwar Ghammam, Hua Ming
公開日: 2026-05-20 | 分野: 機械学習 AI ソフトウェア ソフトウェアエンジニアリング cs.AI cs.SE

※ 日本語タイトル・ポイントはAIによる自動生成です。正確な内容は原論文をご確認ください。

ポイント

  • AIエージェントによるPythonコードのリファクタリングプルリクエスト(PR)の品質とセキュリティリスクを実証的に調査した。
  • AIエージェントは平均して22.5%の変更で品質属性を改善したが、一部のPRでは新たなコード品質やセキュリティの問題も導入された。
  • AI生成リファクタリングは高いマージ率を示したが、品質とセキュリティのゲートを強化する必要性が示唆された。

Abstract

As AI agents increasingly contribute to code development and maintenance, there is still limited empirical evidence on the quality and risk characteristics of their changes in real-world projects, particularly for refactoring-oriented contributions. It remains unclear how agent-authored refactoring edits affect maintainability, code quality, and security once merged into GitHub repositories. To address this gap, we conduct an empirical study of Python refactoring pull requests (PRs) from the AIDev dataset. We analyze agentic refactoring PRs using PyQu, an ML-based quality assessment tool for Python, to quantify changes across five quality attributes, and we complement PyQu with domain-independent static analysis (Pylint and Bandit) to measure code quality and security issues before and after each change. Our results show that, on average, agentic commits improve a quality attribute in 22.5% of the studied changes, with usability improving most frequently (36.5%). At the same time, 24.17% of modified files introduce new Pylint issues predominantly convention level violations such as long lines-while 4.7% introduce new Bandit findings. From the observed diffs, we derive a taxonomy of 24 recurring change operations and map them to the lint and security findings they most commonly affect. Despite these mixed outcomes, developer acceptance is high: 73.5% of the analyzed PRs are merged, including cases that introduce new lint or security findings, often alongside the removal of existing issues. Overall, these findings highlight both the promise and current limitations of agentic refactoring, and motivate stronger tool-in-the-loop quality and security gating for AI-driven development workflows.

Paper AI Chat

この論文のPDF全文を対象にAIに質問できます。

質問の例:

AIチャット機能を利用するには、ログインまたは会員登録(無料)が必要です。

会員登録 / ログイン

💬 ディスカッション

ディスカッションに参加するにはログインが必要です。

ログイン / アカウント作成 →

関連するAIDB記事