TransRepair: Context-aware Program Repair for Compilation Errors
Xueyang Li, Shangqing Liu, Ruitao Feng, Guozhu Meng, Xiaofei Xie, Kai Chen, Yang Liu
摘要
Automatically fixing compilation errors can greatly raise the productivity of software development, by guiding the novice or AI programmers to write and debug code. Recently, learning-based program repair has gained extensive attention and became the stateof-the-art in practice. But it still leaves plenty of space for improvement. In this paper, we propose an end-to-end solution TransRepair to locate the error lines and create the correct substitute for a C program simultaneously. Superior to the counterpart, our approach takes into account the context of erroneous code and diagnostic compilation feedback. Then we devise a Transformer-based neural network to learn the ways of repair from the erroneous code as well as its context and the diagnostic feedback. To increase the effectiveness of TransRepair, we summarize 5 types and 74 fine-grained sub-types of compilations errors from two real-world program datasets and the Internet. Then a program corruption technique is developed to synthesize a large dataset with 1,821,275 erroneous C programs. Through the extensive experiments, we demonstrate that TransRepair outperforms the state-of-the-art in both single repair accuracy and full repair accuracy. Further analysis sheds light on the strengths and weaknesses in the contemporary solutions for future improvement.
问 Lune
几分钟读透这篇 Paper,不用再花一下午。
Lune 能读完全文,也能读引用它的顶会 Paper,讲清它的结论、证据和局限,每一点都注明出自哪篇 Paper。不用硬啃,也不靠猜。
已有 7 篇顶会 Paper 引用了它。别等审稿人问起,先弄清它们发现了什么。
脉络
- CoCoNuT: combining context-aware neural translation models using ensemble for program repair 引用了 DLFix: context-based code transformation learning for automated program repair
- ContraBERT: Enhancing Code Pre-trained Models via Contrastive Learning 引用了 CodeBERT: A Pre-Trained Model for Programming and Natural Languages
- ContraBERT: Enhancing Code Pre-trained Models via Contrastive Learning 引用了 GraphCodeBERT: Pre-training Code Representations with Data Flow
- CURE: Code-Aware Neural Machine Translation for Automatic Program Repair 引用了 CoCoNuT: combining context-aware neural translation models using ensemble for program repair
- CURE: Code-Aware Neural Machine Translation for Automatic Program Repair 引用了 DLFix: context-based code transformation learning for automated program repair
- OrdinalFix: Fixing Compilation Errors via Shortest-Path CFL Reachability 引用了 CoCoNuT: combining context-aware neural translation models using ensemble for program repair
- An Empirical Study on Fine-Tuning Large Language Models of Code for Automated Program Repair 引用了 CoCoNuT: combining context-aware neural translation models using ensemble for program repair
- An Empirical Study on Fine-Tuning Large Language Models of Code for Automated Program Repair 引用了 ContraBERT: Enhancing Code Pre-trained Models via Contrastive Learning
- An Empirical Study on Fine-Tuning Large Language Models of Code for Automated Program Repair 引用了 CodeBERT: A Pre-Trained Model for Programming and Natural Languages
- An Empirical Study on Fine-Tuning Large Language Models of Code for Automated Program Repair 引用了 GraphCodeBERT: Pre-training Code Representations with Data Flow
- An Empirical Study on Fine-Tuning Large Language Models of Code for Automated Program Repair 引用了 CURE: Code-Aware Neural Machine Translation for Automatic Program Repair
- An Empirical Study on Fine-Tuning Large Language Models of Code for Automated Program Repair 引用了 DLFix: context-based code transformation learning for automated program repair
引用它的顶会 Paper7
- OctoPack: Instruction Tuning Code Large Language ModelsNiklas Muennighoff, Qian Liu, Armel Randy Zebaze, Qinkai Zheng 等ICLR 2024 · 203 次引用
- An Empirical Study on Fine-Tuning Large Language Models of Code for Automated Program RepairKai Huang, Xiangxin Meng, Jian Zhang, Yang Liu 等ASE 2023 · 91 次引用
- ContraBERT: Enhancing Code Pre-trained Models via Contrastive LearningShangqing Liu, Bozhi Wu, Xiaofei Xie, Guozhu Meng 等ICSE 2023 · 56 次引用
- Rust-lancet: Automated Ownership-Rule-Violation Fixing with Behavior PreservationWenzhang Yang, Linhai Song, Yinxing XueICSE 2024 · 6 次引用
- OrdinalFix: Fixing Compilation Errors via Shortest-Path CFL ReachabilityWenjie Zhang, Guancheng Wang, Junjie Chen, Yingfei Xiong 等ASE 2023 · 4 次引用
它引用的 Paper10
- CodeBERT: A Pre-Trained Model for Programming and Natural LanguagesZhangyin Feng, Daya Guo, Duyu Tang, Nan Duan 等EMNLP Findings 2020 · 2,828 次引用
- GraphCodeBERT: Pre-training Code Representations with Data FlowDaya Guo, Shuo Ren, Shuai Lu, Zhangyin Feng 等ICLR 2021 · 1,644 次引用
- CoCoNuT: combining context-aware neural translation models using ensemble for program repairThibaud Lutellier, Hung Viet Pham, Lawrence Pang, Yitong Li 等ISSTA 2020 · 325 次引用
- CURE: Code-Aware Neural Machine Translation for Automatic Program RepairNan Jiang, Thibaud Lutellier, Lin TanICSE 2021 · 267 次引用
- DLFix: context-based code transformation learning for automated program repairYi Li, Shaohua Wang, Tien N. NguyenICSE 2020 · 201 次引用
相关 Paper
- Graph-based, Self-Supervised Program Repair from Diagnostic FeedbackMichihiro Yasunaga, Percy LiangICML 2020 · 198 次引用
- TLR: Codebase-Level C Memory Management Error Repair with Large Language ModelsXiao Cheng, Zhihao Guo, Huan Huo, Yulei SuiFSE 2026 · 1 次引用
- MultiFix: Learning to Repair Multiple Errors by Optimal Alignment LearningHyeonTae Seo, Yo-Sub Han, Sang-Ki KoEMNLP Findings 2021 · 4 次引用
- TFix: Learning to Fix Coding Errors with a Text-to-Text TransformerBerkay Berabi, Jingxuan He, Veselin Raychev, Martin T. VechevICML 2021 · 143 次引用
- Neural Program Repair with Execution-based BackpropagationHe Ye, Matias Martinez, Martin MonperrusICSE 2022 · 146 次引用
