Repair-R1: Better Test Before Repair
Haichuan Hu, Xiaochen Xie, Quanjun Zhang
2025-07-31
Summary
This paper talks about Repair-R1, a new system that improves the way computers automatically fix bugs in programs by including test cases in the training process and focusing on generating good tests before trying to repair the code.
What's the problem?
The problem is that automated program repair often fails because the system doesn't have enough good tests to check if the repair actually works, leading to fixes that don't solve the problem or break other parts of the program.
What's the solution?
Repair-R1 solves this by teaching the system to generate effective test cases first and use those tests to guide the repair process. This way, it can better understand what needs fixing and verify that the repair works properly.
Why it matters?
This matters because it makes automatic bug fixing more reliable and efficient, helping programmers save time and write better software with fewer errors.
Abstract
Repair-R1 enhances automated program repair by integrating test cases into the training phase and prioritizing test generation before repair, improving repair success, test generation success, and test coverage.