paperbot · PL 论文追踪

全部论文 待读 收藏

P2 An empirical investigation into learning bug-fixing patches in the wild via neural machine translation

基于神经机器翻译的野外缺陷修复补丁学习的实证研究
ASE Proceedings of the 33rd ACM/IEEE International Conference on Automated Software Engineering2018匹配度 3/10 · 论文研究基于神经机器翻译的自动程序修复,属于 AI 辅助软件工程/程序修复,但未涉及静态分析、形式化验证、Agentic 程序或 LLM,也未触及浮点程序分析与贝叶斯程序分析等核心方向,匹配度较低。引用 141 inbox
Michele Tufano, Cody Watson, Gabriele Bavota, Massimiliano Di Penta, Martin White, Denys Poshyvanyk
crossref: 2026-09-12

AI 速览

一句话:实证研究用神经机器翻译从GitHub历史中学习真实缺陷修复补丁,能修复数百个真实bug方法,9%情况下复现开发者补丁。

该论文探索能否利用神经机器翻译(NMT)技术从开源软件开发历史中自动学习缺陷修复补丁。作者从GitHub仓库的变更历史中挖掘数百万条bug修复记录,从中抽取有意义的修复示例;随后对缺陷代码与对应修复代码进行抽象化处理,用以训练一个Encoder-Decoder模型,将缺陷代码“翻译”为修复后的代码。评估表明,该模型能够在真实场景(in the wild)中修复数百个不同的缺陷方法,并在9%的案例中预测出与开发者实际提交的修复补丁完全一致的补丁。论文以此实证性结论论证了从大规模代码变更历史中学习通用缺陷修复模式的可行性,同时揭示了当前NMT方法在该任务上的效果上限。

问题
能否利用大规模开源项目变更历史中的缺陷修复记录,通过神经机器翻译技术自动学习并生成真实缺陷的修复补丁。
方法
从GitHub仓库挖掘数百万条bug修复,抽取并抽象化缺陷代码与修复后代码,训练Encoder-Decoder模型实现从缺陷代码到修复代码的翻译。
评估
在野外真实缺陷方法上进行实证评估,统计模型能修复的独特缺陷方法数量以及预测补丁与开发者实际补丁一致的比例(9%)。
原文摘要(Abstract)

Millions of open-source projects with numerous bug fixes are available in code repositories. This proliferation of software development histories can be leveraged to learn how to fix common programming bugs. To explore such a potential, we perform an empirical study to assess the feasibility of using Neural Machine Translation techniques for learning bug-fixing patches for real defects. We mine millions of bug-fixes from the change histories of GitHub repositories to extract meaningful examples of such bug-fixes. Then, we abstract the buggy and corresponding fixed code, and use them to train an Encoder-Decoder model able to translate buggy code into its fixed version. Our model is able to fix hundreds of unique buggy methods in the wild. Overall, this model is capable of predicting fixed patches generated by developers in 9% of the cases.

链接与引用

DOI 原文 · PDF(开放获取) ·

BibTeX
@inproceedings{paperbot4763,
  title = {An empirical investigation into learning bug-fixing patches in the wild via neural machine translation},
  author = {Michele Tufano and Cody Watson and Gabriele Bavota and Massimiliano Di Penta and Martin White and Denys Poshyvanyk},
  booktitle = {ASE},
  year = {2018},
  doi = {10.1145/3238147.3240732}
}