Improving semantic equivalence in research-level math formalization
Ayush Khaitan, Liam Fowl, Tomàs Ortega, Alex Kontorovich, Sanjeev Arora
Abstract
Formalizing mathematics in Lean is never a word-for-word translation of a paper: a Lean formalization changes definitions, strengthens hypotheses, splits arguments, and adds lemmas the paper never mentions. It stands to reason that a model that is good at autoformalization must be a good predictor of how a natural language source must differ from its faithful Lean formalization. With that in mind, we collect 4{,}076 audited examples of such changes from 832 Lean projects that formalize research-level mathematics, and use them to ask a practical question: how well can a model \emph{write} Lean inside a real research-level project that may contain tens of thousands of lines of code, and does training on discrepancies between natural language sources and their faithful Lean formalizations help? Our training set consists of 3{,}431 tasks from 141 repositories, and the test set consists of 645 tasks from the remaining 27 repositories. Training on in-project Lean nearly doubles complete proofs () and raises the share of statements in gold agreement with the project's own formalization by nearly a third ( to ). The gain comes from the pairs themselves: an adapter trained only to predict how the Lean will differ, or a model told the difference in advance, barely helps. Training on where formalizations depart from their sources is thus an effective way of improving semantic equivalence in research-level formalization.
Create a lesson
Related papers
Improving the Improver: Semantic PID Control for Medical Agent Self-Improvement
Shared title terminology · Dexia Chen, YiLong Hu, Wenqi Zhong et al.
Bel: Step-Level Policy Improvement of Visual Agents Without Training
Shared title terminology · Jiajun Fan, Ziwen Wang, Zhaoyu Zhu et al.
Do You Even Know What I Want? Improving LLMs Ability to Detect Hidden User Intent
Shared title terminology · Kelsey Sikes, Sarath Sreedharan
Human-in-the-Loop Runbook Improvement with Agentic Support Automation
Shared title terminology · Rocker D'Antonio, Harry Xie
Diversity over Scale: Recursive Self-Improvement with Ensembles of Small Open-Weight Models
Shared title terminology · Navapat Nananukul, Mayank Kejriwal
SMAD: A Semantics-Guided Multi-Agent Framework for Unsupervised Time-Series Anomaly Detection
Shared title terminology · Qinghua Liu, Junpeng Wang, Mingzhi Hu et al.