Mistral Leanstral 1.5: An LLM That Proves Its Own Code
Mistral AI's Leanstral 1.5 is an open-weight Lean 4 model that formally proves code correctness, solving 587 of 672 PutnamBench problems.
Mistral AI's Leanstral 1.5 is an open-weight Lean 4 model that formally proves code correctness, solving 587 of 672 PutnamBench problems.
Introduction
Mistral AI officially announced Leanstral 1.5 on July 2, 2026. The model is a specialized coding-agent LLM built for Lean 4, a programming language and proof assistant used for formal verification. Unlike general-purpose coding models that generate plausible-looking code, Leanstral 1.5 can construct machine-checked mathematical proofs that its code is correct.
This distinction matters because most AI coding tools today, often described as "vibe coding" assistants, produce code that looks right but carries no guarantee of correctness. Leanstral 1.5 targets that trust gap directly. Mistral released the model with open weights under the Apache 2.0 license, making it available for inspection, modification, and commercial use without restriction.
Feature Overview
Leanstral 1.5 uses a Mixture-of-Experts architecture with 119 billion total parameters and approximately 6 billion active parameters per inference pass, according to Mistral's official release notes and the model card published on Hugging Face as mistralai/Leanstral-1.5-119B-A6B. This sparse design allows the model to draw on a large parameter pool while keeping per-token compute costs closer to those of a much smaller dense model.
Mistral trained Leanstral 1.5 in three stages: mid-training on Lean 4 and mathematical corpora, supervised fine-tuning (SFT) on curated proof examples, and reinforcement learning using a method Mistral calls CISPO. The RL stage rewards the model for producing proofs that actually compile and check successfully in the Lean 4 kernel, rather than proofs that merely resemble correct ones.
For readers unfamiliar with the underlying concepts, Lean 4 is a language in which every mathematical statement and every step of a proof must be expressed in a form that a computer program, called a proof checker, can verify line by line. Formal verification is the broader practice of using this kind of machine-checked reasoning to establish that a piece of code, or a mathematical claim, behaves exactly as specified, with no ambiguity and no reliance on testing alone. A model that works in Lean 4 is not just writing code; it is writing an argument that a strict, mechanical judge either accepts or rejects.
On official benchmarks published at mistral.ai/news/leanstral-1-5/, Leanstral 1.5 reached 100% on miniF2F, a benchmark of competition-level formal math problems, saturating both its validation and test sets. On PutnamBench, a benchmark built from Putnam Competition mathematics problems, the model solved 587 of 672 problems. On FATE-H and FATE-X, two harder formal theorem-proving benchmarks, Mistral reported scores of 87% and 34% respectively, describing both as state-of-the-art at time of release. On FLTEval, a formal Lean-based task evaluation, the model achieved Pass@1 of 28.9% and Pass@8 of 43.2%.
Mistral also reported a notable test-time scaling result. At an inference budget of 50,000 tokens, Leanstral 1.5 solved only 44 of the 672 PutnamBench problems. When the budget was increased to 4 million tokens, the same model solved 587 problems. This gap shows that the model's proof-search process benefits substantially from additional compute at inference time, a property that is relevant when deciding how much budget to allocate for harder problems.
Usability Analysis
Mistral and independent testing referenced by MarkTechPost validated Leanstral 1.5 against 57 open-source repositories, rather than synthetic benchmarks alone. This process surfaced five previously unknown or unreported bugs, including a critical sign-overflow bug in the zigzag decoding function of the datrs/varinteger library. Finding a real, previously undetected bug in a widely available open-source library is a meaningful usability signal, since it demonstrates the model's proof-search capability transferring to genuine software rather than only curated proof datasets.
Developers can access Leanstral 1.5 through a free API endpoint under the identifier leanstral-1-5, and the model is integrated into Mistral's Vibe CLI tool, allowing it to be invoked directly from a command-line coding workflow. According to MarkTechPost's coverage, running the model against a PutnamBench-style problem costs approximately $4 per problem, a figure that reflects the higher token budgets needed for the deepest proof searches shown in the test-time scaling results above.
This usage profile suggests Leanstral 1.5 is best suited to targeted verification tasks, such as checking a specific critical function or library, rather than blanket use across an entire codebase. The per-problem cost and the token budgets required for strong results mean it functions more as a specialized verification pass than a drop-in replacement for a general coding assistant.
Pros and Cons
Leanstral 1.5's open weights, Apache 2.0 license, and free API access lower the barrier for developers and researchers to experiment with formal verification workflows. Its benchmark results, particularly the saturated miniF2F score and the PutnamBench result of 587 out of 672, indicate strong capability within the Lean 4 proof domain specifically. The real-world bug discovery across 57 repositories adds evidence beyond benchmark performance alone.
The model's scope is narrow by design. It is built for Lean 4 formal proofs, not general-purpose software development in languages like Python, JavaScript, or Rust, so it does not replace a general coding assistant. The cost of approximately $4 per problem, combined with token budgets reaching into the millions for the hardest cases, makes exhaustive verification runs expensive at scale. FATE-X's 34% score also shows that even state-of-the-art performance leaves the majority of the hardest formal problems unsolved.
Outlook
Leanstral 1.5 sits at an early but concrete point in a broader push to give AI-generated code verifiable guarantees, rather than relying purely on the fluency of a general-purpose coding LLM. Where mainstream coding models are typically judged on benchmarks like SWE-bench, which measure whether generated patches pass a test suite, Leanstral 1.5 is judged on whether its proofs are formally accepted by Lean's kernel, a stricter and narrower standard. This makes direct benchmark comparison with general coding LLMs difficult, but it also signals a different use case: verification of specific, high-stakes components rather than broad code generation.
As formal methods tooling matures, models like Leanstral 1.5 could become a complementary layer in software development, used to verify safety-critical functions, cryptographic primitives, or low-level parsing code, such as the datrs/varinteger bug it uncovered, after a general-purpose model has already generated the initial implementation. The open license also means the research community can build on the released weights rather than treating the model as a closed evaluation target.
Conclusion
Mistral AI's Leanstral 1.5 is a specialized, open-weight model that brings formal mathematical proof to AI-assisted coding rather than promising it as a general-purpose replacement. Its miniF2F and PutnamBench results, along with a real bug find across 57 repositories, support its stated purpose. It is best suited to researchers, formal methods engineers, and teams working on safety-critical or cryptographic code who need mathematical guarantees rather than plausible-looking output, not to developers seeking an everyday coding assistant.
Editor's Verdict
Mistral Leanstral 1.5: An LLM That Proves Its Own Code earns a solid recommendation within the other llm space.
The strongest case for paying attention is fully open weights under Apache 2.0, usable and modifiable without licensing restrictions, which raises the bar for what readers should now expect from peers in this space. Reinforcing that, state-of-the-art results on FATE-H and FATE-X, plus saturated miniF2F performance adds practical value rather than just headline appeal. The broader signal worth registering is straightforward: leanstral 1.5 targets formal correctness rather than plausible-looking code, addressing a known trust gap in AI-assisted coding. On the other side of the ledger, narrow focus on Lean 4 formal proofs limits use outside specialized verification workflows is a real constraint, not a marketing footnote, and it should factor into any serious decision. Layered on top of that, cost of approximately $4 per problem, with token budgets reaching millions for hard cases, limits large-scale use narrows the set of teams for whom this is an obvious yes.
For multi-model deployment teams, cost-conscious operators, and developers willing to evaluate beyond the major labs, this is a serious evaluation candidate, not just a curiosity to bookmark. For everyone else, the safer posture is to monitor coverage and revisit once the use cases that matter to your team are demonstrated in the wild.
Pros
- Fully open weights under Apache 2.0, usable and modifiable without licensing restrictions
- State-of-the-art results on FATE-H and FATE-X, plus saturated miniF2F performance
- Demonstrated real-world value by uncovering a previously unreported bug in an active open-source library
- Free API access and direct integration into the Vibe CLI simplify adoption for developers
- Efficient Mixture-of-Experts design keeps active parameter count low relative to total capacity
Cons
- Narrow focus on Lean 4 formal proofs limits use outside specialized verification workflows
- Cost of approximately $4 per problem, with token budgets reaching millions for hard cases, limits large-scale use
- FATE-X score of 34% shows the hardest formal problems remain largely unsolved
- Requires familiarity with Lean 4 and formal methods concepts, raising the learning curve for general developers
References
Comments0
Key Features
1. Mixture-of-Experts architecture: 119B total parameters, approximately 6B active per pass. 2. Formal proof generation in Lean 4, verified by a machine proof checker rather than test-based validation. 3. Trained in three stages: mid-training, supervised fine-tuning, and CISPO reinforcement learning. 4. State-of-the-art results on FATE-H (87%) and FATE-X (34%), plus 100% on miniF2F and 587/672 on PutnamBench. 5. Open weights under Apache 2.0, free API access, and integration into Mistral's Vibe CLI.
Key Insights
- Leanstral 1.5 targets formal correctness rather than plausible-looking code, addressing a known trust gap in AI-assisted coding.
- Its Mixture-of-Experts design (119B total, ~6B active) keeps inference cost lower than a dense model of similar total size.
- Test-time scaling results (44 problems solved at 50k tokens vs. 587 at 4M tokens) show proof search benefits heavily from added inference compute.
- Real-world validation across 57 open-source repositories, including a critical bug found in datrs/varinteger, extends its credibility beyond synthetic benchmarks.
- Apache 2.0 licensing and a free API endpoint lower the barrier to experimentation for researchers and independent developers.
- The narrow Lean 4 focus means it complements rather than replaces general-purpose coding LLMs.
- Per-problem cost of approximately $4, with proofs requiring up to millions of tokens, limits use to targeted, high-value verification tasks.
- FATE-X's 34% score shows meaningful headroom remains on the hardest formal theorem-proving problems.
Was this review helpful?
Share
Related AI Reviews
Mistral OCR 4 Launch: Structure-Aware Document AI with 85.20 OlmOCRBench Score
Mistral AI launched OCR 4 on June 23, 2026. The structure-aware model scores 85.20 on OlmOCRBench, supports 170 languages, and offers self-hosting for data sovereignty.
GLM-5.2 Review: Top Open-Weight Coding LLM, 1M Context, MIT Licensed
Zhipu AI released GLM-5.2 on June 17, 2026. MIT-licensed with no regional locks, it tops the AA Intelligence Index v4.1 at 51 points and scores 74.4% on FrontierSWE.
Mistral AI Seeks €3B at €20B Valuation: Europe's AI Bet Doubles Down
Mistral AI is in early talks to raise €3B (~$3.5B) at a €20B valuation — nearly doubling its Sept 2025 valuation of €11.7B. The French startup crossed $400M ARR in early 2026.
xAI Launches Grok Imagine Video 1.5: #1 Ranked Video Generation API with Native Audio
xAI released Grok Imagine Video 1.5 on June 3, 2026, debuting at #1 on the Artificial Analysis Video Arena with native synchronized audio, 15-second clips, and developer-ready API access.
