Megrez: A Knowledge-Guided Agent for Formal Mathematics over MK Set Theory
On the map: LLM agents and tool use → Educational agents and math problem solving
Abstract (arXiv)
General-purpose coding agents equipped with proof-assistant tools have shown strong performance on standalone competition problems, yet cumulative textbook formalization inside a low-resource mathematical library still faces three obstacles: aligning textbook concepts with library declarations, keeping long-horizon search synchronized with live proof states, and integrating locally verified proofs reliably into a growing codebase. We present Megrez, a knowledge-guided formalization agent for Rocq libraries built on Morse--Kelley (MK) set theory. Megrez coordinates a general coding agent through three mechanisms: (1) a source-rebuildable knowledge graph merging formal declarations, compiler references, and curated metadata to support retrieval via Chinese aliases, concept clusters, proof dependencies, and multi-lane full-text ranking; (2) a feedback-driven 1--5 tactic short-burst proving loop paired with a goal-local branch ledger and exponential-interval structured reflection; and (3) a three-check acceptance pipeline (statement fidelity, axiom auditing, and full builds) coupled with a multi-corpus Provider stack and a candidate-bound recoverable batch state machine. Deployment and evaluation on a point-set topology corpus demonstrate effective cross-chapter formalization and scalable premise retrieval.
Key facts. No citing papers in the map yet (data through 24 Nov 2026). Placed in Educational agents and math problem solving, one of 16 directions in LLM agents and tool use. Builds on 17 of its 24 references that are in the map. Submitted 10 Nov 2026.
Builds on
17 of 24 references.
Closest ancestors · 2
Same direction, newest first
- 2026Numina-Lean-Agent: An Open and General Agentic Reasoning System for Formal Mathematics20 Jan
- 2023An In-Context Learning Agent for Formal Theorem-Proving6 Oct
Other references · 15
- 2022ReAct: Synergizing Reasoning and Acting in Language Modelscited by 9,589
- 2023Reflexion: Language Agents with Verbal Reinforcement Learningcited by 4,789
- 2023LeanDojo: Theorem Proving with Retrieval-Augmented Language Modelscited by 457
- 2020Generative Language Modeling for Automated Theorem Provingcited by 419
- 2025DeepSeek-Prover-V2: Advancing Formal Mathematical Reasoning via Reinforcement Learning for Subgoal Decompositioncited by 335
- 2022Draft, Sketch, and Prove: Guiding Formal Theorem Provers with Informal Proofscited by 319
- 2025Kimina-Prover Preview: Towards Large Formal Reasoning Models with Reinforcement Learningcited by 203
- 2025Goedel-Prover-V2: Scaling Formal Theorem Proving with Scaffolded Data Synthesis and Self-Correctioncited by 182
- 2023Baldur: Whole-Proof Generation and Repair with Large Language Modelscited by 133
- 2023Magnushammer: A Transformer-Based Approach to Premise Selectioncited by 55
- 2019Generating Correctness Proofs with Neural Networkscited by 39
- 2024Rango: Adaptive Retrieval-Augmented Proving for Automated Software Verificationcited by 33
3 more
Built on by
Not cited yet.
Similar, not cited
Close in wording, no citation either way
- 2026Albilich: Steerable Proof-State Orchestration for LLM-Based Mathematical Research with CAS Integration
- 2026RMA: an Agentic System for Research-Level Mathematical Problems
- 2026Turing Agent: Agentic Formal Verification for Mathematical Research
- 2026Advancing Mathematics Research with AI-Driven Formal Proof Search
- 2026Math Foundation Formalization Agent: A General-Purpose Approach to Formalizing Mathematical Foundations
- 2025Hilbert: Recursively Building Formal Proofs with Informal Reasoning
- 2026ReuF2F: Benchmarking Coding Agents on Formalized Undergraduate Research Problems
- 2026Beyond the Library: An Agentic Framework for Autoformalizing Research Mathematics