MultiFix: Learning to Repair Multiple Errors by Optimal Alignment Learning

HyeonTae Seo, Yo-Sub Han, Sang-Ki Ko


Abstract
We consider the problem of learning to repair erroneous C programs by learning optimal alignments with correct programs. Since the previous approaches fix a single error in a line, it is inevitable to iterate the fixing process until no errors remain. In this work, we propose a novel sequence-to-sequence learning framework for fixing multiple program errors at a time. We introduce the edit-distance-based data labeling approach for program error correction. Instead of labeling a program repair example by pairing an erroneous program with a line fix, we label the example by paring an erroneous program with an optimal alignment to the corresponding correct program produced by the edit-distance computation. We evaluate our proposed approach on a publicly available dataset (DeepFix dataset) that consists of erroneous C programs submitted by novice programming students. On a set of 6,975 erroneous C programs from the DeepFix dataset, our approach achieves the state-of-the-art result in terms of full repair rate on the DeepFix dataset (without extra data such as compiler error message or additional source codes for pre-training).
Anthology ID:
2021.findings-emnlp.417
Volume:
Findings of the Association for Computational Linguistics: EMNLP 2021
Month:
November
Year:
2021
Address:
Punta Cana, Dominican Republic
Editors:
Marie-Francine Moens, Xuanjing Huang, Lucia Specia, Scott Wen-tau Yih
Venue:
Findings
SIG:
SIGDAT
Publisher:
Association for Computational Linguistics
Note:
Pages:
4850–4855
Language:
URL:
https://aclanthology.org/2021.findings-emnlp.417
DOI:
10.18653/v1/2021.findings-emnlp.417
Bibkey:
Cite (ACL):
HyeonTae Seo, Yo-Sub Han, and Sang-Ki Ko. 2021. MultiFix: Learning to Repair Multiple Errors by Optimal Alignment Learning. In Findings of the Association for Computational Linguistics: EMNLP 2021, pages 4850–4855, Punta Cana, Dominican Republic. Association for Computational Linguistics.
Cite (Informal):
MultiFix: Learning to Repair Multiple Errors by Optimal Alignment Learning (Seo et al., Findings 2021)
Copy Citation:
PDF:
https://aclanthology.org/2021.findings-emnlp.417.pdf
Video:
 https://aclanthology.org/2021.findings-emnlp.417.mp4
Data
DeepFix