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

可追溯性转换:使用预训练的BERT模型生成更准确的链接

Traceability Transformed: Generating more Accurate Links with Pre-Trained BERT Models

Jinfeng Lin, Yalin Liu, Qingkai Zeng, Meng Jiang, Jane Cleland-Huang

摘要:

软件可追溯性建立并利用不同开发工件之间的关联。研究人员已经提出使用深度学习跟踪模型将自然语言工件(如需求和问题描述)链接到源代码;然而,它们的有效性受到标记数据的可用性和运行时效率的限制。在这项研究中,我们提出了一个新的框架称为跟踪BERT(T-BERT),以产生源代码和自然语言文物之间的跟踪链接。为了解决数据稀疏性问题,我们利用三步训练策略,使跟踪模型能够从一个密切相关的软件工程挑战中转移知识,该挑战具有丰富的数据集,以产生比以前更高精度的跟踪链接。然后,我们应用T-BERT框架来恢复开源项目中问题和提交之间的链接。我们比较了三个BERT架构的准确性和效率。结果表明,单BERT架构生成了最准确的链接,而Siamese-BERT架构产生了相当的结果,执行时间显着减少。此外,通过学习和传递知识,框架中的所有三个模型都优于经典的IR跟踪模型。在三个被评估的实际OSS项目中,最好的T-BERT稳定地优于VSM模型,使用平均平均精度(MAP)测量的平均改进为60.31%。由于训练数据不足,RNN在这些项目上表现严重不佳,而T-BERT通过使用预训练的语言模型和迁移学习克服了这个问题。

英文摘要:

Software traceability establishes and leverages associations between diverse development artifacts. Researchers have proposed the use of deep learning trace models to link natural language artifacts, such as requirements and issue descriptions, to source code; however, their effectiveness has been restricted by availability of labeled data and efficiency at runtime. In this study, we propose a novel framework called Trace BERT (T-BERT) to generate trace links between source code and natural language artifacts. To address data sparsity, we leverage a three-step training strategy to enable trace models to transfer knowledge from a closely related Software Engineering challenge, which has a rich dataset, to produce trace links with much higher accuracy than has previously been achieved. We then apply the T-BERT framework to recover links between issues and commits in Open Source Projects. We comparatively evaluated accuracy and efficiency of three BERT architectures. Results show that a Single-BERT architecture generated the most accurate links, while a Siamese-BERT architecture produced comparable results with significantly less execution time. Furthermore, by learning and transferring knowledge, all three models in the framework outperform classical IR trace models. On the three evaluated real-word OSS projects, the best T-BERT stably outperformed the VSM model with average improvements of 60.31% measured using Mean Average Precision (MAP). RNN severely underperformed on these projects due to insufficient training data, while T-BERT overcame this problem by using pretrained language models and transfer learning.

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

↑