PatchPilot:一款在形式验证领域开展早期尝试的高成本效益软件工程智能体
PatchPilot: A Cost-Efficient Software Engineering Agent with Early Attempts on Formal Verification
AI总结:
针对现有软件补丁智能体性能、成本与稳定性难以兼顾的问题,提出含五组件定制化规则规划工作流的PatchPilot,在SWE-bench上以低成本实现优于开源方法的性能与更高稳定性。
摘要:
近期研究构建了多种将大语言模型(LLM)与非机器学习工具结合的补丁修复智能体,在最先进的(SOTA)软件补丁基准测试SWE-bench上取得了可观成果。根据补丁修复工作流的确定方式,现有补丁修复智能体可分为两类:基于智能体的规划方法(依赖LLM进行规划)和基于规则的规划方法(遵循预定义工作流)。总体而言,基于智能体的规划方法补丁修复性能高,但成本高且稳定性有限;而基于规则的规划方法更稳定高效,但其工作流存在关键局限,会削弱补丁修复性能。本文提出PatchPilot——一款在补丁修复效果、稳定性和成本效益间取得平衡的智能体补丁修复工具。PatchPilot提出了一种新颖的基于规则的规划工作流,包含五个组件:复现、定位、生成、验证和优化(其中优化组件为PatchPilot独有)。我们为每个组件设计了新颖的定制化方案,以优化其有效性和效率。通过在SWE-bench基准上开展的大量实验,PatchPilot表现出优于现有开源方法的性能,同时保持低成本(每个实例不到1美元)且稳定性更高。我们还开展了详细的消融实验,以验证每个组件中的关键设计。我们的代码可在https://github.com/ucsb-mlsec/PatchPilot获取。
英文摘要:
Recent research builds various patching agents that combine large language models (LLMs) with non-ML tools and achieve promising results on the state-of-the-art (SOTA) software patching benchmark, SWE-bench. Based on how to determine the patching workflows, existing patching agents can be categorized as agent-based planning methods, which rely on LLMs for planning, and rule-based planning methods, which follow a pre-defined workflow. At a high level, agent-based planning methods achieve high patching performance but with a high cost and limited stability. Rule-based planning methods, on the other hand, are more stable and efficient but have key workflow limitations that compromise their patching performance. In this paper, we propose PatchPilot, an agentic patcher that strikes a balance between patching efficacy, stability, and cost-efficiency. PatchPilot proposes a novel rule-based planning workflow with five components: reproduction, localization, generation, validation, and refinement (where refinement is unique to PatchPilot). We introduce novel and customized designs to each component to optimize their effectiveness and efficiency. Through extensive experiments on the SWE-bench benchmarks, PatchPilot shows a superior performance than existing open-source methods while maintaining low cost (less than 1$ per instance) and ensuring higher stability. We also conduct a detailed ablation study to validate the key designs in each component. Our code is available at https://github.com/ucsb-mlsec/PatchPilot.
机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。