
Mistral Leanstral formal verification AI code: Lean 4 guide for developers
Mistral Leanstral is an open-source Lean 4 code agent built to help developers turn AI-generated code into mechanically checked specifications and proofs. It does not make code correct by confidence alone; it helps produce artifacts that Lean’s proof checker can verify. What Is Mistral Leanstral? Mistral Leanstral is a Lean 4 proof-engineering agent announced by Mistral on March 16, 2026, for developers who want AI assistance with formal verification rather than just code completion. The model card identifies Leanstral 26.03 as labs-leanstral-2603, a Labs model with 119B total parameters, 6.5B active parameters, and a 256k context window. Its job is to work in formal repositories: reading Lean files, proposing definitions, writing theorem statements, filling proofs, and reacting to Lean compiler or language-server feedback. That makes it different from a generic chatbot that says an algorithm “looks right.” Leanstral is useful only when the desired behavior has been expressed as a precise Lean specification and checked by Lean’s small trusted kernel. The key takeaway: Leanstral is best treated as a specialized assistant for proof engineering, not a magic correctness label for arbitrary code. ...