Abstain and Validate: A Dual-LLM Policy for Reducing Noise in Agentic Program Repair
Authors:
Preprint
Abstract
Agentic Automated Program Repair (APR) is increasingly tackling complex, repository-level bugs in industry, but ultimately agent-generated patches still need to be reviewed by a human before committing them to ensure they address the bug. Showing unlikely patches to developers can lead to substantial noise, wasting valuable developer time and eroding trust in automated code changes. We introduce two complementary LLM-based policies to reduce such noise: bug abstention and patch validation policies. Bug abstention excludes bugs that the agentic APR system is unlikely to fix. Patch validation rejects patches that are unlikely to be a good fix for the given bug. We evaluate both policies on three sets of bugs from Google's codebase, and their candidate patches generated by an internal agentic APR system. On a set of 174 human-reported bugs, removing bugs and patch trajectories rejected by our policies can raise success rates by up to 13 percentage points and 15 percentage points, respectively, and by up to 39 percentage points in combination. On null pointer exceptions and sanitizer-reported bugs with machine-generated bug reports, patch validation also improves average single-sample success rates. This two-policy approach provides a practical path to the reliable, industrial-scale deployment of agentic APR systems.Keywords
All Related Versions
This publication has 11 references indexed in Scilit:
- On the Effectiveness of LLM-as-a-Judge for Code Generation and SummarizationIEEE Transactions on Software Engineering, 2025
- Know Your Limits: A Survey of Abstention in Large Language ModelsTransactions of the Association for Computational Linguistics, 2025
- Demystifying LLM-Based Software Engineering AgentsProceedings of the ACM on Software Engineering, 2025
- Evaluating Agent-Based Program Repair at Google2025
- Trust enhancement issues in program repair2022
- Why Google stores billions of lines of code in a single repositoryCommunications of the ACM, 2016
- GenProg: A Generic Method for Automatic Software RepairIEEE Transactions on Software Engineering, 2011
- Classification with reject optionCanadian Journal of Statistics, 2006
- On optimum recognition error and reject tradeoffIEEE Transactions on Information Theory, 1970
- An optimum character recognition system using decision functionsIRE Transactions on Electronic Computers, 1957