paperbot · PL 论文追踪

全部论文 待读 收藏

P2 PSearch: Search-Based Patch Generation in the Era of LLM-Based Automated Program Repair

PSearch:LLM 驱动的自动程序修复时代的基于搜索的补丁生成
ASE Proceedings of the 41st IEEE/ACM International Conference on Automated Software Engineering2026匹配度 4/10 · 论文属于 LLM 自动程序修复与搜索式补丁生成,和用户关注的静态分析、形式化验证、浮点程序分析、贝叶斯程序分析及 Agentic 程序静态分析等核心方向不直接匹配;仅在“LLM 作为工具改进程序语言任务”的大方向上有一定邻近性。引用 4 inbox
Haichuan Hu, Ye Shang, Weifeng Sun, Quanjun Zhang
crossref: 2026-10-09

AI 速览

一句话:提出基于搜索的补丁生成框架 PSearch,通过迭代评估与精化提升 LLM 自动程序修复效果并降低成本。

现有基于 LLM 的自动程序修复(APR)多依赖试错式补丁采样,探索缺乏结构,难以评估搜索方向前景并有效分配预算。作者提出 PSearch:以迭代补丁评估与精化为中心的搜索式补丁生成框架。它维护中间补丁的结构化搜索状态,持续评估已探索路径的潜力,优先精化最有希望的路径,从而尽早放弃弱方向,并通过长时程搜索逼近正确修复;该框架可集成不同搜索算法,当前采用蒙特卡洛树搜索。在五个缺陷与漏洞基准上,PSearch 在 Defects4J 修复 201/835 个缺陷,优于 12 个先进基线;在 VUL4J 修复 27/79 个漏洞;在 SWE-Bench-Lite 解决 164/300 个问题;补丁规模为 16 时成本约为强基线的 50%,且修复效果更优。

问题
基于 LLM 的 APR 多依赖试错式补丁采样,搜索缺乏结构,难以判断不同搜索方向的前景并合理分配搜索预算。
方法
提出 PSearch,维护中间补丁的结构化搜索状态,通过迭代评估与精化优先扩展有希望的路径,可集成不同搜索算法,当前以蒙特卡洛树搜索实现。
评估
在 Defects4J、VUL4J、SWE-Bench-Lite 等五个基准上评测,与 12 个先进基线比较修复数量,并分析补丁规模为 16 时的货币成本。
原文摘要(Abstract)

Large Language Models (LLMs) have substantially advanced Automated Program Repair (APR), yet most existing LLM-based APR methods still rely on trial-and-error to generate patches. Such a strategy explores candidate patches in a weakly structured manner, making it difficult to assess the future potential of search directions and allocate search budget effectively. To address this limitation, we propose Psearch, a search-based patch generation framework for LLM-based APR centered on iterative patch evaluation and refinement. Instead of treating patch generation as repeated independent sampling, Psearch maintains a structured search state over intermediate patches, continuously evaluates the promise of explored search paths, and prioritizes the most promising ones for further refinement. This design enables Psearch to abandon weak directions early and progressively approach correct fixes through long-horizon search. Importantly, Psearch can be integrated with different search algorithms, while our current implementation adopts Monte Carlo Tree Search as one effective instantiation. We evaluate Psearch on five widely used bug and vulnerability benchmarks. Experimental results show that Psearch correctly repairs 201 out of 835 bugs in Defects4J, outperforming all 12 state-of-the-art baselines. Psearch also fixes 27 of 79 vulnerabilities in VUL4J and resolves 164 of 300 issues in SWE-Bench-Lite. Moreover, with a patch size of 16, Psearch reduces monetary cost to roughly 50% of strong baselines while maintaining superior repair effectiveness. These results highlight the effectiveness of Psearch for improving LLM-based APR.

链接与引用

DOI 原文 · arXiv ·

BibTeX
@inproceedings{paperbot12456,
  title = {PSearch: Search-Based Patch Generation in the Era of LLM-Based Automated Program Repair},
  author = {Haichuan Hu and Ye Shang and Weifeng Sun and Quanjun Zhang},
  booktitle = {ASE},
  year = {2026},
  doi = {10.1145/3832783.3834422}
}