Lean 4 proof completion
Researchers and formal-methods engineers who want an agent to fill proof holes, build helper lemmas, and iterate against compiler feedback.
Independent tool overview
Leanstral 1.5 is Mistral AI's Apache 2.0 open-weight mixture-of-experts model for Lean 4 formal proof engineering, automated theorem proving, autoformalization, and proof-oriented code agents. It has 119 billion total parameters with 6.5 billion active per token, a 256,000-token context window, downloadable weights, and a free Mistral API preview. Its most important limitation is operational: Mistral says the hosted API model will be retired on September 30, 2026. The weights can remain usable, but self-hosting requires substantial infrastructure and careful validation.
Visit the official Leanstral 1.5 site ↗
Overview
Leanstral 1.5 is a specialist coding and reasoning model built around Lean 4, not a general-purpose consumer math tutor. It can draft proof terms, repair Lean files, inspect goals and compiler errors, create auxiliary lemmas, navigate repositories, and iterate with a Lean language server until a target proof compiles or its budget is exhausted.
The model is a 119B-parameter mixture of experts with 6.5B parameters active per token, 128 experts and four active experts per token. Mistral documents a 256K context window, recommends keeping self-hosted context at or below 200K, accepts text and image input, and produces text. The model supports high reasoning effort, structured output, function calling, and agent or conversation APIs.
Mistral reports strong results on miniF2F, PutnamBench, FATE-H, FATE-X, and the open-sourced FLTEval proof-engineering benchmark. Those are provider-run results under specific token budgets and tool environments. Some headline outcomes used up to four million tokens per PutnamBench attempt, so benchmark accuracy and practical latency or cost are not interchangeable.
A Lean proof accepted by the kernel is much stronger evidence than a natural-language answer, but it proves only the formal statement in the chosen environment. If the theorem, definitions, assumptions, imported axioms, code translation, or intended specification is wrong, a compiling proof can establish the wrong thing perfectly.
Leanstral 1.5 is available as downloadable Apache 2.0 weights and through Mistral's free Labs API. Mistral's changelog states that the hosted model ID will retire September 30, 2026, only three months after release. New production work should therefore pin weights or a supported deployment path and design migration before depending on the hosted endpoint.
Use cases
The strongest fit depends on the job you need the product to complete, not the size of its feature list.
Researchers and formal-methods engineers who want an agent to fill proof holes, build helper lemmas, and iterate against compiler feedback.
Lean users exploring contest, undergraduate, graduate, or research-level formalization with all outputs checked in a pinned environment.
Teams that need help navigating dependencies, repairing broken proofs, refactoring tactics, or proposing changes across a Lean project.
Formal-verification teams translating program behavior into Lean specifications and using the model to search for proofs or counterexamples.
Organizations that need downloadable weights, an Apache 2.0 license, reproducible serving, or experimentation beyond a closed API.
Capabilities
Trained for theorem proving, proof repair, autoformalization, Lean code, and language-server feedback rather than broad conversational math alone.
Can submit candidate proofs, read Lean errors and goals, revise the file, and repeat across a multi-turn proof-engineering task.
Can inspect and edit files, run commands, use a Lean language server, add auxiliary lemmas, and persist through long tasks when placed in an authorized agent.
Mistral trained the model to try a theorem, react to feedback, and in some workflows attempt a negation or counter-property when proof search fails.
Provides a documented 256K context window for large proof states and repositories, with 200K or less recommended in the model card's local setup.
Supports high reasoning effort for complex tasks and a no-reasoning option for simpler or faster interactions.
Can call configured functions such as a Lean compiler or language-server bridge rather than merely returning untested source text.
The hosted model supports structured response formats for controlled integration into proof and agent workflows.
Mistral provides a Lean agent configuration for its terminal coding agent and recommends the Lean LSP MCP server.
The official model card documents self-hosting with vLLM, an OpenAI-compatible client, tensor parallelism, and the Mistral reasoning and tool parsers.
Weights are downloadable from Hugging Face under Apache 2.0, allowing continued use after the temporary hosted endpoint retires.
Process
Step 1
Record Lean, Mathlib, project commit, dependencies, compiler options, model weights or API ID, serving stack, agent prompt, and tool versions.
Step 2
Have a qualified mathematician or formal-methods engineer review the theorem, definitions, quantifiers, domains, assumptions, units, and intended connection to reality.
Step 3
Identify the exact theorem or proof hole and prohibit unrelated repository changes unless separately approved.
Step 4
Use a disposable branch or sandbox, restrict network and secrets, allowlist commands and paths, and never enable automatic approval on valuable systems.
Step 5
Supply relevant imports, neighboring lemmas, style expectations, failed attempts, and the exact Lean goals instead of dumping an entire repository blindly.
Step 6
Use Lean itself or the Lean LSP MCP so the model receives authoritative type errors and goal states after each proposal.
Step 7
Set token, time, command, disk, and retry limits; long benchmark-style attempts can consume millions of tokens and many compactions.
Step 8
Accept only code that passes in the pinned clean environment, not a response that says the proof should compile.
Step 9
Inspect imported axioms, unsafe declarations, admitted results, generated code, trusted translators, and whether the theorem actually expresses the intended claim.
Step 10
Require a human to evaluate readability, maintainability, unnecessary assumptions, proof robustness, licensing, and all changes outside the target.
Step 11
Rebuild from scratch, run project tests and linters, compare with alternate formulations or counterexamples, and have a domain expert challenge the specification.
Step 12
Before September 30, 2026, test a pinned local deployment or replacement endpoint and document latency, quality, infrastructure, privacy, and rollback.
Cost
Mistral currently lists Leanstral 1.5 input, cached input, and output as free in the Labs API. This is a public-preview price, not a durable production commitment: the hosted model is scheduled for retirement on September 30, 2026. The weights are free to download under Apache 2.0, but local inference, storage, accelerator capacity, engineering, monitoring, and proof-search compute remain the user's cost.
Free
Temporary hosted preview access to Leanstral 1.5.
No model-license fee under Apache 2.0
Download and operate Leanstral 1.5 independently.
Leanstral can be used from a free Mistral account
Mistral's recommended interactive agent path for Lean proof work.
Pricing checked . Check current pricing at the source ↗
Assessment
Compare
The right alternative depends on the specific output, workflow, controls and budget your project requires.
Project Management
A general-purpose coding and reasoning assistant with strong repository workflows, but without Leanstral's open weights or dedicated Lean 4 training and kernel-feedback positioning.
Explore Claude →Business Operations
A broad interactive assistant for explaining mathematics and drafting Lean code when a managed general model is preferable to a specialist open-weight deployment.
Explore ChatGPT →Business Operations
An open-model ecosystem alternative for mathematical and coding reasoning, though buyers should verify the exact prover model, license, deployment, and Lean-specific benchmark evidence.
Explore DeepSeek →Questions
Leanstral 1.5 is Mistral AI's open-weight model for Lean 4 formal proof engineering, theorem proving, autoformalization, and proof-oriented coding agents.
Mistral describes it as open source and publishes the model weights under the Apache License 2.0. The weights and model card are available on Hugging Face.
It is a 119B-total-parameter mixture-of-experts model with 6.5B parameters active per token, 128 experts, and four active experts per token.
Mistral documents a 256K-token context window. The official self-hosted model card recommends using no more than 200K tokens in its sample setup.
Yes as of August 31, 2026. Mistral lists input, cached input, and output as free for the Labs model. That preview is scheduled to retire September 30, 2026.
Mistral's changelog says the hosted Leanstral 1.5 API model will retire September 30, 2026. The downloadable Apache 2.0 weights are a separate artifact and can continue to be self-hosted.
Current Mistral model documentation lists the hosted ID as labs-leanstral-1-5. Older release copy uses a shorter name, so use the current console and documentation and plan for retirement.
Lean's kernel can verify that a proof term establishes the formal statement under its definitions and assumptions. It does not guarantee that the statement matches the intended informal claim or real system.
It can help prove Lean specifications and Mistral reports experiments on properties translated from Rust. The translation, specification, assumptions, compiler boundary, and connection to deployed code all require independent validation.
Yes. Mistral's model card documents vLLM serving with tensor parallelism and an OpenAI-compatible client. The model is large, so benchmark memory, throughput, context, and total infrastructure cost first.
No. It can accelerate proof search and Lean editing, but experts must define the right property, review assumptions and the trusted base, inspect changes, and decide whether the proof supports the real-world claim.
Not on sensitive or valuable repositories. Keep the agent sandboxed, restrict tools and paths, require approval for commands and edits, and review every diff before it reaches a trusted branch.
Bottom line
Leanstral 1.5 is one of the more practically interesting open-weight specialist models because its output can be checked by Lean rather than accepted on style alone. It is best used as a bounded proof engineer: pin the environment, connect authoritative compiler feedback, constrain repository access, and require expert review of the specification and trusted base. The immediate production caveat is decisive—the free hosted endpoint retires September 30, 2026. Evaluate quickly, but depend on it only with a tested self-hosted or replacement path.
Visit Leanstral 1.5 website ↗
Claude Science - Anthropic’s app for AI-powered scientific research

Kosmos - Next-generation AI scientist

TRIBE v2 - Meta's predictive foundation model that simulates human brain responses to sights, sounds, and language

Edison Analysis - Next-gen scientific analysis agent

Get access to all our AI courses, hundreds of real-world AI use cases, live expert-led workshops, an exclusive network of AI early adopters, and more.
Get unlimited access to all of our current & upcoming industry-specific AI courses for the duration of your subscription.
To keep up with the rapid pace of AI, our team publishes AI implementation guides daily. Our library contains 300+ practical use cases to automate real-world work.
Join weekly, live, interactive sessions with industry leaders who are at the forefront of AI for hands-on implementation guidance and exclusive insights.
Network with an exclusive community of AI-first professionals who are working smarter with AI. Learn how early adopters are using AI in their work and businesses.