Machine Learning · Lean · Proof

MLP-Bench: Towards End-to-End Formal Research Assistance in Machine Learning Theory

Are today's LLM agents ready to assist theoretical ML research end-to-end under formal verification?

Yaowenqi Liu*, Ruida Wang*, Rui Pan*, Yuxing Liu, Yifan Hao, Tong Zhang

University of Illinois Urbana-Champaign*Co-first authors

Abstract

Large language models (LLMs) have demonstrated strong mathematical reasoning and autonomous research abilities, yet whether they can assist the rigorous construction and verification of machine learning (ML) theory remains underexplored. Since ML theory rests on precise assumptions and derivations, we ground our study in Lean, which mechanically checks every derivation against its stated assumptions. Mirroring how theory is actually developed and refereed, we frame formal ML theory research as two complementary capabilities: forward construction, which assists theory derivation, and backward verification, which assists reviewing.

We instantiate this framework in the Machine Learning Lean Proof Benchmark (MLP-Bench), a 360-problem benchmark spanning 16 topics. Forward construction is realized by two tasks, formalizing natural-language (NL) theorems into Lean statements and proving given Lean statements. Backward verification is realized by a third task, judging whether a proof is correct and, if not, localizing the first erroneous step with Lean-checked evidence.

Evaluating 11 models, forward construction remains challenging. Auto-formalization reaches at most a 27.5% bidirectional equivalence (BEq) pass rate against gold Lean statements, with omitted implicit assumptions a major failure mode, and specialized provers solve 0.0% of theorem-proving problems. In backward verification, models localize errors more reliably by constructing Lean-checked refutation than by attempting to prove each step. To our knowledge, MLP-Bench is the first Lean benchmark for end-to-end LLM assistance in ML theory research.

Two directions · Three tasks

Forward construction & backward verification

MLP-Bench evaluates forward construction and backward verification in Lean through auto-formalization, theorem-proving, and proof-verification.

Forward construction

01Auto-formalization

Given a Lean 4 file with one target theorem’s statement blanked out, together with the NL source theorem and its context, the model must restore the statement while preserving the intended mathematical meaning. The proof is fixed to sorry.

Forward construction

01Auto-formalization

Input
NL source theorem + context
Output
Lean statement
Metric
BEq and validity rate
Forward construction

02Theorem-proving

Given a Lean 4 file with a human-verified target statement and its proof replaced by sorry, the model must supply a complete Lean proof without changing the statement.

Forward construction

02Theorem-proving

Input
Lean statement (proof = sorry)
Output
Complete Lean proof
Metric
Lean-verified proof success rate
Backward verification

03Proof-verification

Each problem presents 3–5 ordered theorems with NL proofs pre-segmented into steps. The model must formalize every step in Lean itself and locate the first substantive error, if any.

Backward verification

03Proof-verification

Input
3–5 ordered theorems with NL proofs
Output
Earliest flagged step, or no error
Metrics
Precision, recall, accuracy, and F1
Examples of the three MLP-Bench tasks from the paper.
100% ↗
MLP-Bench forward-backward framework: Forward construction (top) covers auto-formalization and theorem-proving. Backward verification (bottom) covers proof verification, localizing the first erroneous step with Lean-checked evidence.

The benchmark

360 problems across 16 topics

360Benchmark problems
16ML theory topics
3Complementary tasks
11Evaluated models

For forward construction, we draw graduate-level tasks from graduate instructional materials and research-level tasks from JMLR papers published between 2002 and 2024.

120 theorem instances

Each yielding one auto-formalization problem and one theorem-proving problem, for a total of 240 problems. Each theorem instance includes the original NL theorem, context, and proof, along with a verified Lean statement and its gold proof.

120 proof-verification problems

Each presents three to five ordered theorems with their NL proofs; 60 contain a substantive error and 60 are fully correct. Real flawed cases are recovered from ICLR submissions and public peer reviews (2016–2026); synthetic cases introduce a localized error into a verified proof.

Formalization & validation

Candidates undergo manual semantic faithfulness checks and Lean compilation. All 120 Lean statements have gold proofs aligned with their original NL proofs. Human reviewers verify that the labeled step is the first substantive error, with all preceding steps valid.

Sunburst chart showing the distribution of MLP-Bench topics.
Topic distribution of MLP-Bench.

Experimental results

Main results

We evaluate 11 open- and closed-source models, comparing Chain-of-Thought (CoT) with autonomous agents. For agent evaluations, we use Codex as the default harness and Claude Code for Claude models.

Auto-formalization
27.5%Best auto-formalization BEq

BEq, Agent (%)

Claude-Opus-527.5
GPT-5.6-Sol25.0
GPT-5.6-Terra18.3
Claude-Sonnet-517.5
Theorem-proving
41.7%Best research proving success

Research, Agent (%)

GPT-5.6-Sol41.7
Claude-Opus-540.0
Claude-Sonnet-528.3
GPT-5.6-Terra10.0
Proof-verification
61.7%Best verification F1

F1, Agent + FL Refute (%)

Claude-Opus-561.7
Claude-Sonnet-541.8
GPT-5.6-Sol38.2
GPT-5.6-Terra29.9

01Auto-formalization

Faithfully translating natural-language theorems into Lean remains challenging. Claude-Opus-5 achieves the highest agentic BEq score, but only 27.5% of its statements are verified as equivalent to the gold.

Auto-formalization results on 120 theorems, reporting BEq and validity (Valid) rates (%) under CoT and Agent settings.
ModelBEq
CoT
BEq
Agent
Valid
CoT
Valid
Agent
Closed-source models
GPT-5.6-Luna13.317.541.755.8
GPT-5.6-Terra13.318.340.055.0
GPT-5.6-Sol20.825.049.266.7
Claude-Sonnet-515.017.550.864.2
Claude-Opus-523.327.574.278.3
Open-source models
DeepSeek-V4 Flash10.015.038.345.8
Gemma-4 26B-A4B0.00.017.520.0
Qwen3.5-9B0.00.015.016.7

02Theorem-proving

Successful proof construction largely depends on agentic iteration and repair. CoT achieves at most 1.7% on graduate problems and 0.0% on research problems, whereas agents reach 68.3% and 41.7%, respectively. Yet all three open-source specialized provers score 0.0% on both splits, even when sampling is scaled up to pass@32.

Theorem-proving results on 60 graduate and 60 research-level Lean statements, reporting Lean-verified proof success rates (%).
ModelGraduate
CoT
Graduate
Agent
Research
CoT
Research
Agent
Closed-source models
GPT-5.6-Luna0.03.30.010.0
GPT-5.6-Terra0.05.00.010.0
GPT-5.6-Sol1.748.30.041.7
Claude-Sonnet-50.046.70.028.3
Claude-Opus-50.068.30.040.0
Open-source provers
Kimina-Prover-Distill-8B0.00.00.00.0
DeepSeek-Prover-V2-7B0.0–0.0–
Goedel-Prover-V2-8B0.00.00.00.0

03Proof-verification

FL Refute consistently outperforms FL Prove across all five closed-source models. In the Agent setting, switching from FL Prove to FL Refute raises GPT-5.6-Luna’s F1 from 3.4% to 17.9% and Claude-Opus-5’s from 24.8% to 61.7%. This suggests that a Lean-checked refutation is a more reliable error signal than a failed proof attempt.

FL Prove

Flags the first step the model fails to prove, treating proof failure as a rejection signal.

FL Refute

Flags a step only when Lean accepts the model’s refutation of the step’s formalization.

Proof-verification results on 120 MLP-Bench problems in the Agent setting, comparing FL Prove and FL Refute (%).
ModelAccuracy
FL Prove
Accuracy
FL Refute
F1
FL Prove
F1
FL Refute
Closed-source models
GPT-5.6-Luna2.519.23.417.9
GPT-5.6-Terra3.332.54.429.9
GPT-5.6-Sol10.839.211.538.2
Claude-Sonnet-519.255.016.641.8
Claude-Opus-535.867.524.861.7
Open-source models
DeepSeek-V4 Flash1.725.02.36.2
Gemma-4 26B-A4B0.00.80.00.0
Qwen3.5-9B0.00.00.00.0

Experiment analysis

Auto-formalization

Assumption omission is a major problem.

Even among Lean statements that compile, 65.0–83.8% are flagged as omitting at least one assumption in the gold statement. Recovering the necessary assumptions is necessary but not sufficient.

Paper analysis of omitted assumptions by assumption family.
Omitted assumptions by family for two leading models.
Theorem-proving

Single-step proving.

On 150 non-trivial leaf subgoals extracted from gold proofs, specialized provers solve only 12.7–18.7%, compared with 52.0–84.7% for general-purpose models.

Claude-Opus-584.7
GPT-5.6-Sol70.0
Claude-Sonnet-564.0
GPT-5.6-Terra60.7
GPT-5.6-Luna52.0
DeepSeek-Prover-V2-7B18.7
Goedel-Prover-V2-8B15.3
Kimina-Prover-Distill-8B12.7
Solve rates on 150 subgoals (%).
Proof-verification

FL Prove introduces an early-localization bias.

FL Prove predominantly reports steps before the first actual error. FL Refute instead requires a Lean-checked refutation, shifting reports toward the gold step.

Error-localization offsets for FL Prove and FL Refute.
Error-localization offsets, averaged across five models.

Conclusion

Current agents struggle to recover implicit assumptions and construct complete proofs, yet readily refute false Lean statements. Their current promise lies more in assisting critical scrutiny than in producing rigorous theoretical results.