自适应证明精化与LLM引导的策略选择
Adaptive Proof Refinement with LLM-Guided Strategy Selection
AI总结:
针对现有证明精化策略固定、无法动态调整的问题,提出Adapt框架,利用LLM引导的决策者动态选择精化策略,在基准上显著提升定理证明成功率,并验证了其泛化性。
摘要:
通过定理证明进行的形式化验证能够实现软件正确性的表达性规范和严格证明,但由于需要大量的手动工作和专业知识,难以扩展。虽然大型语言模型(LLMs)在证明生成方面显示出潜力,但它们经常在首次尝试时产生不正确的证明,并需要额外的策略进行迭代精化。然而,现有方法采用固定的精化策略,无法根据生成证明中的特定问题动态选择有效策略,这限制了它们的性能。为了克服这一限制,我们引入了Adapt,一种新颖的证明精化框架,利用LLM引导的决策者根据证明助手的状态和错误证明的可用上下文动态选择合适的精化策略。我们在两个基准上对Adapt与四种现有方法进行了评估,发现它在两个基准上分别证明了16.63%和18.58%更多的定理,显著优于最佳基线。此外,我们通过在五个不同的LLM上进行评估来展示Adapt的泛化能力。我们还进行了消融研究,以衡量每个组件的贡献,并比较替代决策者设计的权衡。
英文摘要:
Formal verification via theorem proving enables the expressive specification and rigorous proof of software correctness, but it is difficult to scale due to the significant manual effort and expertise required. While Large Language Models (LLMs) show potential in proof generation, they frequently produce incorrect proofs on the first attempt and require additional strategies for iterative refinement. However, existing approaches employ fixed refinement strategies and cannot dynamically choose an effective strategy based on the particular issues in a generated proof, which limits their performance. To overcome this limitation, we introduce Adapt, a novel proof refinement framework that leverages an LLM-guided decision-maker to dynamically select a suitable refinement strategy according to the state of the proof assistant and available context of an incorrect proof. We evaluate Adapt on two benchmarks against four existing methods and find that it significantly outperforms the best baseline on both by proving 16.63% and 18.58% more theorems, respectively. Furthermore, we demonstrate Adapt's generalizability by evaluating it across five different LLMs. We also conduct ablation studies to measure the contribution of each component and compare the trade-offs of alternative decision-maker designs.
机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。