PaperFormalizer: Author-in-the-Loop Autoformalization of Research Papers in Lean
Abstract
Even a carefully proofread paper can leave small gaps in its proofs or its stated assumptions. We introduce PaperFormalizer, a Lean-based agentic pipeline that helps authors find and close such gaps in their own papers and turn each paper into a Lean-verified version. Starting from the LaTeX source, PaperFormalizer transcribes the paper into a dependency graph of statements, audits each statement in natural language for faithfulness, ambiguity and correctness, and then formalizes and proves the statements in Lean against Mathlib, optional domain libraries and the author's personal toolkit. Only the author knows what a statement is meant to say and how a formalization gap in a result is best fixed. The pipeline therefore stops and asks the author whenever a statement admits more than one reading, presents every repair, in natural language and TeX symbols, as a proposal that the author can accept, decline or redirect, and leaves to the author every decision that could potentially change what the paper claims. The output is an annotated and revised version of the paper, a report of the changes, and Lean code in which each declaration is linked to the statement it formalizes. The author's toolkit grows as more papers are formalized, and authors can share their verified papers so that researchers who build on them can reuse their Lean code. By making verified papers practical to produce, PaperFormalizer aims to make research that rests on mathematical proofs more robust. PaperFormalizer runs inside a coding agent (Claude Code or Codex) and is available at https://github.com/Jiyuan-Tan/PaperFormalizer. Papers with Lean code shared by users are available at https://paperformalizer.org.
Create a lesson
Metadata
- Categories
- cs.AI, cs.LO
Related papers
Numina Fuse: Interactive Autoformalization in Lean 4
Shared title terminologycs.AIJustin Asher, Yichuan Cao, Ruichen Qiu et al.
Improving semantic equivalence in research-level math formalization
Shared title terminologycs.AIAyush Khaitan, Liam Fowl, Tomàs Ortega et al.
When do stored facts become available in looped transformers?
Shared title terminologycs.AIFabio Valerio Massoli, Arnau Padrés Masdemont, Jordi Ros Giralt et al.
Human-in-the-Loop Runbook Improvement with Agentic Support Automation
Shared title terminologycs.AIRocker D'Antonio, Harry Xie
Specialized Large Language Models for Markovian Reasoning: Structural Cache Compression, Transition Pretraining, and Dual-Loop Transformers
Shared title terminologycs.AIHaibin Tong, Liangliang Xin, Yamei Zhu et al.
Beyond Self-Critique: Epistemic Convergence Control for Multi-Agent Research Verification
Shared title terminologycs.AIChrisantus Eze