arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2404.03953cs.SE
收藏

迈向理解代码修改对软件质量度量指标的影响

Towards Understanding the Impact of Code Modifications on Software Quality Metrics

Thomas Karanikiotis, Andreas L. Symeonidis

AI总结:

本研究通过聚类GitHub代码修改并借助AI语言模型描述各簇功能,揭示代码变更对软件质量度量指标的集体影响,为理解代码变更与质量关系及改进维护策略提供新方法。

摘要:

背景:在软件开发领域,维持高软件质量是一项持续存在的挑战。然而,这一挑战常常因缺乏对特定代码修改如何影响质量度量指标的全面理解而受到阻碍。目标:本研究试图通过一种旨在评估和解释代码修改影响的方法来弥合这一差距。其基本假设认为,能够在软件质量度量指标上引发相似变化的代码修改可以被划分为不同的簇,并且这些簇可以通过AI语言模型进行有效描述,从而为代码变更及其质量影响提供一种简洁的理解。方法:为验证该假设,我们基于流行的GitHub仓库构建并分析了一个数据集,并将其切分为单个代码修改。每个项目在修改应用前后均依据软件质量度量指标进行评估。研究利用机器学习技术根据这些修改在度量指标上引发的变更对其进行聚类。同时,采用AI语言模型生成每个修改功能的描述。结果:结果揭示了不同的代码修改簇,每个簇都配有简洁的描述,展示了它们对软件质量度量指标的集体影响。结论:研究结果表明,这项工作是迈向全面理解代码变更与软件质量之间复杂关系的重要一步,并有望变革软件维护策略,推动更精确的质量预测模型的开发。

英文摘要:

Context: In the realm of software development, maintaining high software quality is a persistent challenge. However, this challenge is often impeded by the lack of comprehensive understanding of how specific code modifications influence quality metrics. Objective: This study ventures to bridge this gap through an approach that aspires to assess and interpret the impact of code modifications. The underlying hypothesis posits that code modifications inducing similar changes in software quality metrics can be grouped into distinct clusters, which can be effectively described using an AI language model, thus providing a simple understanding of code changes and their quality implications. Method: To validate this hypothesis, we built and analyzed a dataset from popular GitHub repositories, segmented into individual code modifications. Each project was evaluated against software quality metrics pre and post-application. Machine learning techniques were utilized to cluster these modifications based on the induced changes in the metrics. Simultaneously, an AI language model was employed to generate descriptions of each modification's function. Results: The results reveal distinct clusters of code modifications, each accompanied by a concise description, revealing their collective impact on software quality metrics. Conclusions: The findings suggest that this research is a significant step towards a comprehensive understanding of the complex relationship between code changes and software quality, which has the potential to transform software maintenance strategies and enable the development of more accurate quality prediction models.

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

↑