arXiv:2604.16584cs.SEcs.AI2026-04被引 3

用多模态验证器实现自动程序生成与证明,提升可靠性与成功率。

Certified Program Synthesis with a Multi-Modal Verifier

  • 构建融合动态测试、自动证明与交互脚本的多模态验证框架
  • 在相同预算下,认证通过率显著高于单一模式基线
  • 适合需要高可信度程序生成的研究者与工业用户

认证程序合成(即形式化编码)是从自然语言描述中自动生成程序、其形式化规范及机器可检查的对齐证明的过程。现有方法面临两大挑战:一是从自然语言生成的规范常过弱或过强,缺乏系统性检测手段;二是验证工具分散,各自支持自动-主动或交互式推理,导致合成方法受限于特定范式。本文提出以多模态验证器为核心构建合成流程,实现动态验证、自动化证明与交互式脚本一体化。基于Lean实现的LeetProof框架,通过随机化属性测试提前验证规范,利用验证条件分解任务,并将剩余证明交由针对Lean优化的前沿AI证明器处理。在源自先前工作的基准上评估显示,其规范验证发现了原有基准缺陷,且分阶段管道在相同预算下,对两种前沿LLM后端均显著提升了完全认证解的比例。

原文摘要 · Abstract (English)

Certified program synthesis (aka vericoding) is the process of automatically generating a program, its formal specification, and a machine-checkable proof of their alignment from a natural-language description. Two challenges make vericoding difficult. First, specifications synthesised from natural language are often either too weak to be meaningful or too strong to be implementable, yet existing approaches lack systematic means to detect such defects. Second, the landscape of program verifiers is fragmented: each tool supports a particular reasoning mode -- auto-active (e.g., Dafny, Verus) or interactive (e.g., Coq, Lean) -- with its own trade-off between automation and expressivity. This forces every synthesis methodology to be tailored to a single verification paradigm, limiting the class of tasks it can handle effectively. We overcome both challenges by structuring the certified synthesis workflow around a multi-modal verifier -- a single tool combining dynamic validation, automated proofs, and interactive proof scripting in one foundational framework. We realise this idea in LeetProof, an agentic pipeline built on Velvet, a multi-modal verifier embedded in Lean. Multi-modality enables LeetProof to validate generated specifications via randomised property-based testing before any code is synthesised, decompose the synthesis task into sub-problems guided by verification conditions, and delegate residual proof obligations to frontier AI provers specialised for Lean. We evaluate LeetProof on benchmarks derived from prior work on certified synthesis. Our specification validation uncovers defects in existing reference benchmarks, and LeetProof's staged pipeline achieves a significantly higher rate of fully certified solutions than a single-mode baseline at the same budget -- consistently across two frontier LLM backends.

程序合成形式验证多模态AI证明

Thank you to arXiv for use of its open access interoperability. PaperDance 不是 arXiv 官方产品;中文卡片由大模型生成,请以原文为准。