arXivDaily arXiv每日学术速递 周一至周五更新
arXiv周末暂无论文更新,休息一下吧,周末愉快~~
arXiv 2005.10636cs.SEcs.CLcs.LGcs.PLstat.ML
收藏

基于图的自监督程序诊断反馈修复

Graph-based, Self-Supervised Program Repair from Diagnostic Feedback

Stanford University(斯坦福大学)

Michihiro Yasunaga, Percy Liang

摘要:

我们考虑从诊断反馈中学习修复程序的问题(例如,编译器错误消息)。程序修复具有挑战性,原因有两个:首先,它需要在源代码和诊断反馈中进行推理和跟踪符号。其次,可用于程序修复的标记数据集相对较小。在这项工作中,我们提出了新的解决方案,这两个挑战。首先引入程序反馈图,将源代码中与程序修复相关的符号与诊断反馈连接起来,然后在其上应用图神经网络对推理过程进行建模。其次,我们提出了一个用于程序修复的自监督学习范例,该范例利用在线提供的未标记程序来创建大量额外的程序修复示例,我们使用这些示例来预训练我们的模型。我们在两个应用程序上评估我们提出的方法:纠正介绍性编程任务(DeepFix数据集)和纠正程序合成(Sunday数据集)的输出。我们的最终系统DrRepair的性能明显优于之前的工作,在DeepFix上实现了68.2%的完全修复率(比之前最好的系统高出22.9%),在Sonix上实现了48.4%的合成成功率(比之前最好的系统高出3.7%)。

英文摘要:

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).

机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。

↑