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

深入研究提交-问题关联以增强提交信息生成模型

Delving into Commit-Issue Correlation to Enhance Commit Message Generation Models

Liran Wang, Xunzhu Tang, Yichen He, Changyu Ren, Shuhua Shi, Chaoran Yan, Zhoujun Li

AI总结:

针对提交信息生成缺乏变更原因的问题,本文构建提交-问题关联数据集,并提出 \ ool 训练范式,将问题中的理据引入多种 CMG 模型且显著提升性能。

摘要:

提交信息生成(CMG)是自动化软件工程中的一项具有挑战性的任务,旨在为提交生成代码变更的自然语言描述。以往方法都从修改后的代码片段出发,通过基于模板、基于检索或基于学习的模型输出提交信息。虽然这些方法能够从代码角度总结修改了什么,但它们难以给出提交的原因。提交与问题之间的关联可能是生成合理提交信息的关键因素,但这一关联仍未得到探索。在本工作中,我们从数据集和方法论两个角度深入研究提交与问题之间的关联。我们构建了首个以关联提交和问题相结合为锚点的数据集。该数据集包含一个无标注的提交-问题并行部分,以及一个有标注部分,其中每个样本都在问题中提供了人工标注的合理信息。此外,我们提出了 \ ool(Extraction、Grounding、Fine-tuning),这是一种新颖范式,能够将提交与问题之间的关联引入模型的训练阶段。为评估其有效性,我们使用多种最先进的 CMG 模型进行了全面实验。结果表明,与原始模型相比,经 \ ool 增强的模型性能得到显著提升。

英文摘要:

Commit message generation (CMG) is a challenging task in automated software engineering that aims to generate natural language descriptions of code changes for commits. Previous methods all start from the modified code snippets, outputting commit messages through template-based, retrieval-based, or learning-based models. While these methods can summarize what is modified from the perspective of code, they struggle to provide reasons for the commit. The correlation between commits and issues that could be a critical factor for generating rational commit messages is still unexplored. In this work, we delve into the correlation between commits and issues from the perspective of dataset and methodology. We construct the first dataset anchored on combining correlated commits and issues. The dataset consists of an unlabeled commit-issue parallel part and a labeled part in which each example is provided with human-annotated rational information in the issue. Furthermore, we propose \tool (\underline{Ex}traction, \underline{Gro}unding, \underline{Fi}ne-tuning), a novel paradigm that can introduce the correlation between commits and issues into the training phase of models. To evaluate whether it is effective, we perform comprehensive experiments with various state-of-the-art CMG models. The results show that compared with the original models, the performance of \tool-enhanced models is significantly improved.

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

↑