SuperAPI AI Directory

Leanstral 1.5 - Mistral AI's Open-Source Formal Verification Large Model

Author: AI小集 · Original source: AI工具集

What is Leanstral 1.5

Leanstral 1.5 is Mistral AI's open-source formal verification large model, optimized specifically for Lean 4 automated theorem proving. The model adopts a 119B parameter MoE architecture and supports a 256k ultra-long context and image-text input. The model achieves SOTA performance on mathematical proving benchmarks such as miniF2F and PutnamBench, and can advance the automation of AI formal mathematical verification and code correctness proving.

Leanstral 1.5

Main Features of Leanstral 1.5

  • Automated Theorem Proving: Automatically generates complete formal mathematical proofs based on the Lean 4 language, covering high-difficulty fields such as algebra, geometry, and number theory.
  • Formal Verification: Conducts rigorous logical verification of software code and mathematical propositions, ensuring that every step of derivation conforms to Lean 4's type system and axiom system.
  • Joint Image-Text Reasoning: Supports parsing and understanding multimodal inputs such as mathematical diagrams and formula screenshots during the proving process, assisting complex geometric and symbolic derivation.
  • Long-Document Proof Generation: With a 256k context window, it can handle proof tasks at the level of an entire textbook or long paper, maintaining logical consistency across chapters.
  • Agent-Style Interactive Proving: Uses code Agent mode to autonomously call the Lean 4 compiler, retrieve mathematical libraries, and iteratively correct errors, achieving end-to-end automation.
Dig GitHub

Follow WeChat and reply "Open Source" to joinAI Open Source Project Exchange Group

Technical Principles of Leanstral 1.5

  • Sparse Mixture-of-Experts Architecture (MoE): Total parameter count is 119B, with only 6.5B parameters activated per token, achieving large model capacity while maintaining inference efficiency.
  • Lean 4-Specific Corpus Training: Post-training is conducted on a large number of formal mathematics libraries (such as mathlib4), competition problems (IMO, Putnam), and manually annotated proof paths.
  • Reinforcement Learning Fine-Tuning: Through clear feedback signals indicating proof success or failure, combined with RL to optimize the policy network, improving the search and construction capabilities for complex theorems.
  • Multimodal Encoder Fusion: Integrates a visual encoder to convert LaTeX formula images and geometric diagrams into embedded representations unified with text, enabling cross-modal joint reasoning.
  • Long-Context Positional Encoding: Adopts an extended positional encoding scheme supporting 256k tokens, ensuring that dependencies in ultra-long proof chains are not lost.

How to Use Leanstral 1.5

  • Visit HuggingFace to Download Weights: Go to https://huggingface.co/mistralai/Leanstral-1.5-119B-A6B to obtain the open-source model files and configuration files.
  • Configure the Lean 4 Runtime Environment: Install the Lean 4 compiler and mathlib4 dependency library locally to ensure that the code generated by the model can be correctly parsed and verified.
  • Load the Model and Connect to the Proving Interface: Use Transformers or vLLM to load the model weights, and convert natural language propositions into Lean 4 code through an API or local scripts.
  • Start the Automated Proving Agent: Call the model to generate a proving strategy; the model will automatically iterate through compilation, error correction, and library retrieval until it obtains proof complete or reaches the attempt limit.
  • Quick Online Experience: Log in to Mistral AI Console (https://console.mistral.ai/),选择 labs-leanstral-1-5 Enter propositions directly at the endpoint for verification.

Core Advantages of Leanstral 1.5

  • Extremely Low Inference Cost: Under the MoE architecture, 6.5B parameters are activated per token, greatly reducing GPU memory and compute consumption compared with Dense models of comparable performance.
  • Comprehensive Leadership on Mathematical Benchmarks: It reaches 100% saturation on miniF2F, solves 587/672 problems on PutnamBench, and achieves 87% on FATE-H, all of which are the current SOTA.
  • Native Support for Lean 4: Deeply optimized for the formal verification domain, the generated code can pass Lean compiler checks directly, avoiding the syntax errors commonly seen in general-purpose models.
  • Ultra-Long Context Support: The 256k context enables it to handle formal verification of entire books or large software specifications, far exceeding the window limits of similar competitors.

Project Address of Leanstral 1.5

  • Project Official Website:https://mistral.ai/news/leanstral-1-5/
  • HuggingFace Model Repository:https://huggingface.co/mistralai/Leanstral-1.5-119B-A6B

Comparison of Leanstral 1.5 with Similar Competitors

Comparison Dimension Leanstral 1.5 DeepSeek-Prover-V2
Developer Mistral AI DeepSeek
Open-Source License Apache 2.0 (fully open source) MIT (open source)
Architecture 119B MoE (6.5B per token) 671B MoE (37B per token)
Specialized Language Lean 4 Lean 4
miniF2F Performance 100% saturation High score but saturation not publicly disclosed
Context Length 256k tokens 128k tokens
Multimodal Support Supports image-text input Mainly supports text
Inference Cost Fewer activated parameters per token, lower cost Larger number of activated parameters, higher cost

Application Scenarios of Leanstral 1.5

  • Mathematical Research Assistance: Helps mathematicians quickly verify conjectures and generate draft lemma proofs, accelerating exploration in fields such as algebraic geometry and number theory.
  • Competition Training and Problem Solving: Automatically solves high-level mathematics competition problems such as IMO and Putnam, and provides complete machine-verifiable formal solutions.
  • Software Correctness Verification: Generates formal specifications and verification proofs for critical software in aerospace, financial systems, and other fields, replacing part of manual auditing work.
  • Automated Grading in Education: In higher education, automatically verifies Lean 4 proof assignments submitted by students and provides feedback precise to each step.
  • AI Safety Alignment Verification: Used to verify the logical consistency and policy safety of complex AI systems, ensuring through formal methods that key decisions have no vulnerabilities.