The rapid adoption of AI coding agents for software development has raised important questions about the quality and maintainability of the code they produce. While prior studies have examined AI-generated source code, the impact of AI coding agents on build systems-a critical yet understudied component of the software lifecycle-remains largely unexplored. This data mining challenge focuses on AIDev, the first large-scale, openly available dataset capturing agent-authored pull requests (Agentic-PRs) from real-world GitHub repositories. Our paper leverages this dataset to investigate (RQ1) whether AI coding agents generate build code with quality issues (e.g., code smells), (RQ2) to what extent AI agents can eliminate code smells from build code, and (RQ3) to what extent Agentic-PRs are accepted by developers. We identified 364 maintainability and security-related build smells across varying severity levels, indicating that AI-generated build code can introduce quality issues-such as lack of error handling, and hardcoded paths or URLs-while also, in some cases, removing existing smells through refactorings (e.g., Pull Up Module and Externalize Properties). Notably, more than 61\% of Agentic-PRs are approved and merged with minimal human intervention. This dual impact underscores the need for future research on AI-aware build code quality assessment to systematically evaluate, guide, and govern AI-generated build systems code.
翻译:AI编程助手在软件开发中的迅速普及引发了关于其生成代码质量与可维护性的重要问题。尽管先前研究已考察过AI生成的源代码,但AI编程助手对构建系统——软件生命周期中关键却研究不足的组成部分——的影响仍很大程度上未被探索。本数据挖掘研究聚焦于AIDev,这是首个大规模、公开可用的数据集,收录了来自真实GitHub仓库中由AI助手提交的拉取请求(Agentic-PRs)。本文利用该数据集探究以下问题:(RQ1)AI编程助手是否会产生存在质量问题的构建代码(例如代码异味),(RQ2)AI助手能在多大程度上消除构建代码中的代码异味,以及(RQ3)Agentic-PRs在多大程度上被开发者接受。我们识别出364个涉及可维护性与安全性的构建异味,其严重程度各异,表明AI生成的构建代码可能引入质量问题——例如缺乏错误处理、硬编码路径或URL——同时在某些情况下也能通过重构(例如Pull Up Module和Externalize Properties)消除现有异味。值得注意的是,超过61%的Agentic-PRs在最少人工干预下获得批准并合并。这种双重影响凸显了未来需要开展面向AI的构建代码质量评估研究,以系统化评估、引导和治理AI生成的构建系统代码。