Context: Learning-based automatic program repair techniques are showing promise to provide quality fix suggestions for detected bugs in the source code of the software. These tools mostly exploit historical data of buggy and fixed code changes and are heavily dependent on bug localizers while applying to a new piece of code. With the increasing popularity of code review, dependency on bug localizers can be reduced. Besides, the code review-based bug localization is more trustworthy since reviewers' expertise and experience are reflected in these suggestions.
Objective: The natural language instructions scripted on the review comments are enormous sources of information about the bug's nature and expected solutions. However, none of the learning-based tools has utilized the review comments to fix programming bugs to the best of our knowledge. In this study, we investigate the performance improvement of repair techniques using code review comments.
Method: We train a sequence-to-sequence model on 55,060 code reviews and associated code changes. We also introduce new tokenization and preprocessing approaches that help to achieve significant improvement over state-of-the-art learning-based repair techniques.
Results: We boost the top-1 accuracy by 20.33% and top-10 accuracy by 34.82%. We could provide a suggestion for stylistics and non-code errors unaddressed by prior techniques.
Conclusion: We believe that the automatic fix suggestions along with code review generated by our approach would help developers address the review comment quickly and correctly and thus save their time and effort.
Search-Induced Issues in Web-Augmented LLM Code Generation: Detecting and Repairing Error-Inducing Pages
Peking University(北京大学);Institute of Software, Chinese Academy of Sciences(中国科学院软件研究所);Singapore Management University(新加坡管理大学);Fuzhou University(福州大学)
From Failed Trajectories to Reliable LLM Agents: Diagnosing and Repairing Harness Flaws
State Key Laboratory of Complex System Modeling and Simulation Technology(复杂系统建模与仿真技术国家重点实验室);Institute of Software, Chinese Academy of Sciences(中国科学院软件研究所);University of Chinese Academy of Sciences(中国科学院大学);School of Computer Science and Technology, Tianjin University(天津大学计算机科学与技术学院)
Towards Large Language Model Aided Program Refinement
National University of Singapore(新加坡国立大学);Griffith University(格里菲斯大学);Peking University(北京大学);Singapore Institute of Technology(新加坡科技设计大学);Shanghai Jiaotong University(上海交通大学);Singapore Management University(新加坡管理大学)
Tea: Program Repair Using Neural Network Based on Program Information Attention Matrix
Microsoft Asia-Pacific Technology Company Ltd.(微软亚太科技有限公司);University of Chinese Academy of Sciences(中国科学院大学);Institute of Software, Chinese Academy of Sciences(中国科学院软件研究所)