It is widely recognized that program repair tools need to have a high precision to be useful, i.e., the generated patches need to have a high probability to be correct. However, it is fundamentally difficult to ensure the correctness of the patches, and many tools compromise other aspects of repair performance such as recall for an acceptable precision.
In this paper we ask a question: can a repair tool with a low precision be still useful? To explore this question, we propose an interactive filtering approach to patch review, which filters out incorrect patches by asking questions to the developers. Our intuition is that incorrect patches can still help understand the bug. With proper tool support, the benefit outweighs the cost even if there are many incorrect patches.
We implemented the approach as an Eclipse plugin tool, InPaFer, and evaluated it with a simulated experiment and a user study with 30 developers. The results show that our approach improve the repair performance of developers, with 62.5% more successfully repaired bugs and 25.3% less debugging time in average. In particular, even if the generated patches are all incorrect, the performance of the developers would not be significantly reduced, and could be improved when some patches provide useful information for repairing, such as the faulty location and a partial fix.
Repeton: Structured Bug Repair with ReAct-Guided Patch-and-Test Cycles
Uppsala University Sweden;Hanoi University of Science \& Technology Vietnam;Knovel Engineering Lab Singapore;The University of Alabama at Birmingham USA;Uppsala University;Hanoi University of Science \& Technology;Knovel Engineering Lab;The University of Alabama at Birmingham;Institute for Clarity in Documentation Dublin Ohio USA;Inria Paris-Rocquencourt Rocquencourt France;Rajiv Gandhi University Doimukh Arunachal Pradesh India;Tsinghua University Haidian Qu Beijing Shi China;Palmer Research Laboratories San Antonio Texas USA;Institute for Clarity in Documentation;Inria Paris-Rocquencourt;Rajiv Gandhi University;Tsinghua University;Palmer Research Laboratories
本文提出开源框架 Repeton,用 ReAct 引导的结构化补丁与测试循环替代整体修复生成,在 SWE-bench Lite 上提升补丁有效性与可解释性。