cs.AINov 27, 2026

Par for the Proof: Agentic Compression of Lean 4 Proofs under Exact Compiler Feedback

Authors: Supreeth Rao, Anirudh Gupta, Ajay Kumar Nair, Manan Tayal

Organizations: Emergence AI · Student at the Indian Institute of Science

Abstract

We describe our closed-track entry to the Lean Refactor Arena, where Lean 4 proofs must be rewritten to be shorter (fewer tokens) and cheaper to check (fewer heartbeats) while still compiling on every listed toolchain, for at most $3 of API spend per problem. We treat the task as a search against an exact, compiler-defined cost. A frontier model (gpt-6.1-sol) proposes proofs. A Lean metaprogram inserted into the target file measures each candidate as the competition does, at the cost of elaborating one declaration, and the best candidate so far is replaced only by one with a strictly higher three-axis score. A deterministic Lean optimizer then polishes the winner with verified local rewrites, and a reproduction of the competition scorer judges it. On the 60-problem final benchmark, our submission scores a combined 87.88 on the arena (length -80.2%, heartbeats -83.4%, all 67 cross-toolchain checks passed), at $2.83 per problem on average and $2.97 at most. The score tracked the number of verified evaluations the budget bought: a cheaper model per turn, a session policy that spends the whole allowance, and half-price Flex tokens each raised it, while more information, more structure, or forced diversity did not.

Figures & tables

Appendix figures & tables7 assets

Supplementary material from the paper’s appendix.

Appendix

Explore similar work

CardsList
  1. Lean Refactor: Multi-Objective Controllable Proof Optimization via Agentic Strategy Search

    May 18, 2026Jialin Lu, Soonho Kong, Rodrigo Stehling +4Large Language Model-Guided OptimizationLean Theorem Proving

  2. Verified Proof Refactoring with Codex and Qwen

    Nov 24, 2026Lazar Milikic, Gordan Đurić, Viktor KunčakAutomated Code RefactoringLean Theorem Proving

  3. LeanPolish: Verified Supervision for Lean Proof Compression

    Sep 29, 2026Pauline BourigaultLean Theorem Proving