arXivDaily arXiv每日学术速递 周一至周五更新
arXiv周末暂无论文更新,休息一下吧,周末愉快~~
arXiv 2610.25308cs.SE
收藏

从软件历史到可执行回归任务:一种用于评估软件智能体的系统

From Software History to Executable Regression Tasks: A System for Evaluating Software Agents

Peking University(北京大学)

Ruikai Shi, Zhengran Zeng, Rui Xie, Shikun Zhang, Wei Ye

AI总结:

本研究提出一种从软件历史构建可执行回归实例的系统,用于评估软件智能体的缺陷发现、修复与测试能力,实验显示基线组合的修复和回归测试生成成功率最高达68.7%和77.1%。

摘要:

随着软件智能体越来越多地生成和修改代码,评估其审查变更和发现缺陷的能力变得至关重要。此类评估需要用于研究的可执行项目环境以及具有可复现行为的可靠缺陷参考。现有的代码审查基准对这种组合的支持有限。我们提出一种系统,该系统从历史的引入提交-修复提交对和开发者测试中构建可执行回归实例。该系统从修复端变更中提取候选测试,然后使用受约束的智能体移植这些测试并配置特定版本的环境,同时保留生产代码和测试预期。独立重放和基于证据的审查会验证在引入版本上失败而在修复版本上通过的测试是否支持所提出的回归关系。被接受的实例会保留两个版本的重放配方、经过验证的测试和执行证据。修复支持的分析和人工审查会添加根本原因位置、经过测试的修复和因果解释。这些实例支持代码审查中的缺陷检测和定位,并能针对相同缺陷进行缺陷修复和回归测试生成。该系统从11个Python项目的522个候选实例中构建了172个经过验证的实例。我们在83个手动选择的丰富实例上,针对三项任务评估了三种软件智能体(共十种模型)以及额外的推理工作量设置。精确的行级定位仍然具有挑战性,而基线组合实现的修复和回归测试生成成功率分别高达68.7%和77.1%。不同任务的领先配置存在差异,且更高的任务性能并不一定能带来更高的API成本效率。我们的方法为研究智能体的缺陷发现、修复和测试能力提供了可重用的可执行证据。

英文摘要:

As software agents increasingly generate and modify code, evaluating their ability to review changes and discover defects becomes important. Such evaluation needs executable project environments for investigation and reliable defect references supported by reproducible behavior. Existing code review benchmarks provide limited support for this combination. We present a system that constructs executable regression instances from historical introducing--fixing commit pairs and developer tests. The system extracts candidate tests from fixing-side changes, then uses constrained agents to transplant them and configure version-specific environments while preserving production code and test expectations. Independent replay and evidence-based review verify whether tests that fail on the introducing version and pass on the fixing version support the proposed regression relationship. Accepted instances retain both versions' replay recipes, validated tests, and execution evidence. Repair-supported analysis and human review add root-cause locations, tested repairs, and causal explanations. These instances support bug detection and localization in code review, and enable bug repair and regression-test generation on the same defects. The system constructs 172 validated instances from 522 candidates across 11 Python projects. We evaluate three software agents with ten models and additional reasoning-effort settings on 83 manually selected, enriched instances across the three tasks. Precise root-line localization remains challenging, while baseline combinations achieve repair and regression-test generation success rates of up to 68.7% and 77.1%, respectively. Leading configurations differ by task, and higher task performance does not necessarily yield greater API-cost efficiency. Our approach provides reusable executable evidence for studying agents' defect discovery, repair, and testing capabilities.

机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。

↑