Graph-based, Self-Supervised Program Repair from Diagnostic Feedback
arXiv:2005.10636
Abstract
We consider the problem of learning to repair programs from diagnostic feedback (e.g., compiler error messages). Program repair is challenging for two reasons: First, it requires reasoning and tracking symbols across source code and diagnostic feedback. Second, labeled datasets available for program repair are relatively small. In this work, we propose novel solutions to these two challenges. First, we introduce a program-feedback graph, which connects symbols relevant to program repair in source code and diagnostic feedback, and then apply a graph neural network on top to model the reasoning process. Second, we present a self-supervised learning paradigm for program repair that leverages unlabeled programs available online to create a large amount of extra program repair examples, which we use to pre-train our models. We evaluate our proposed approach on two applications: correcting introductory programming assignments (DeepFix dataset) and correcting the outputs of program synthesis (SPoC dataset). Our final system, DrRepair, significantly outperforms prior work, achieving 68.2% full repair rate on DeepFix (+22.9% over the prior best), and 48.4% synthesis success rate on SPoC (+3.7% over the prior best).
ICML 2020. Code & data available at https://github.com/michiyasunaga/DrRepair
References in corpus (6)
- SequenceR: Sequence-to-Sequence Learning for End-to-End Program Repair
- CodeBERT: A Pre-Trained Model for Programming and Natural Languages
- Neural Program Repair by Jointly Learning to Localize and Repair
- Deep Reinforcement Learning for Programming Language Correction
- Neural Networks for Modeling Source Code Edits
- Semantic Scaffolds for Pseudocode-to-Code Generation
Cited by in corpus (15)
- On the Opportunities and Risks of Foundation Models
- Graph Self-Supervised Learning: A Survey
- WILDS: A Benchmark of in-the-Wild Distribution Shifts
- Neural Transfer Learning for Repairing Security Vulnerabilities in C Code
- Measuring Coding Challenge Competence With APPS
- QA-GNN: Reasoning with Language Models and Knowledge Graphs for Question Answering
- Program Synthesis with Large Language Models
- Styler: learning formatting conventions to repair Checkstyle violations
- Learning to Synthesize Programs as Interpretable and Generalizable Policies
- CS1QA: A Dataset for Assisting Code-based Question Answering in an Introductory Programming Course
- Leveraging Automated Unit Tests for Unsupervised Code Translation
- InferCode: Self-Supervised Learning of Code Representations by Predicting Subtrees
- Composed Fine-Tuning: Freezing Pre-Trained Denoising Autoencoders for Improved Generalization
- IGLU: Efficient GCN Training via Lazy Updates
- Learning to Extend Program Graphs to Work-in-Progress Code