AI State of the Art
Mistral/Mistral Models: Complete Catalog/15 min
Section 249

Devstral 2 & Devstral Small 2: The Dedicated Code Models (2025-2026)

Listen as a podcast →
Status as of July 2026

Devstral is no longer an active line, and the two models did not fall at the same time.

Devstral Small 2 was deprecated as early as 27 February 2026 and retired from the API on 31 March 2026, the first of the two to go, even though it shipped on the same day as its big brother. Devstral 2 lasted longer: deprecated on 22 May 2026, it is retired on 31 July 2026.

For both, the official documentation gives the same replacement: Mistral Medium 3.5, which also became the default model in Mistral's coding agent, Vibe CLI, in place of Devstral 2. The weights remain downloadable on Hugging Face, the retirement applies to the API, not to files already published.

The rest of this page keeps the full history: what a dedicated code model was, and why the category existed for two years before being folded back in.

Devstral: From AI Copilot to AI Developer Agent

There is a fundamental difference between a model that completes code line by line and a model that understands an entire project and can refactor it in one go. From Codestral to Devstral, that is exactly the leap that happened.

The analogy: Codestral was a copilot whispering suggestions word by word. Devstral was a junior developer who could read the whole codebase, understand the architecture, and propose structural improvements across several files at once.

What Fundamentally Changed

Structural project understanding: Devstral did not just see the current file. It understood the file hierarchy, the dependencies between modules, the design patterns in use, the project's naming conventions.

Multi-file refactoring: need to change 5 files at once to fix a broken architecture? Rename an interface and update all its consumers? Devstral handled that in a single pass.

Contextual debugging: you gave it a stack trace, and instead of suggesting a superficial patch, Devstral navigated the whole codebase back to the root cause.

The qualitative leap: autocompletion vs agentic

Codestral = "complete my function" (line/function level) Devstral = "understand my project and improve it" (architecture level) It is the move from smart autocompletion to a developer agent capable of reasoning about an entire codebase. That distinction is still valid today: it outlived the product that carried it.

The Two Models of December 2025

Mistral announced Devstral 2 and Devstral Small 2 on 9 December 2025. Two sizes, two licences, two audiences.

Devstral 2Devstral Small 2
Parameters123 billion24 billion
ArchitectureDenseDense
Context256,000 tokens256,000 tokens
LicenceModified MITApache 2.0
SWE-bench Verified72.2%68.0%
API price (input / output, per million tokens)$0.40 / $2.00$0.10 / $0.30
A common mix-up

You will often read that "Devstral 2 is a 24 billion parameter model". That is wrong: the 24 billion figure belongs to Devstral Small 2. Devstral 2, the large one, has 123 billion. The confusion comes from the earlier 2025 Devstral models, which were all 24B. When reading a spec sheet, check the exact name of the weights repository: Devstral-2-123B-Instruct-2512 and Devstral-Small-2-24B-Instruct-2512 leave no room for ambiguity.

The Real Argument: Compactness

What Mistral emphasised was not topping a leaderboard, but reaching those scores with far fewer parameters than the open competition. According to the announcement, Devstral 2 (123 billion) and Devstral Small 2 (24 billion) are respectively 5x and 28x smaller than DeepSeek V3.2, and 8x and 41x smaller than Kimi K2.

Why does size matter this much? Because it decides who can actually run the model. A model 40 times smaller fits on infrastructure 40 times cheaper, and for a company that wants to host its coding assistant on its own servers, for source-code confidentiality reasons, that is the difference between a fundable project and a theoretical one. Architectural efficiency over raw size: Mistral's recurring theme since Mistral 7B.

SWE-bench Verified: Why This Benchmark

SWE-bench does not test isolated functions in a vacuum. It uses real bugs from real GitHub projects. The model has to read the project, understand the problem, locate the bug, and produce the fix, which is then validated by actually running the project's test suite. That is developer work, not a programming exercise.

The word "Verified" refers to a subset of SWE-bench whose task descriptions were reviewed by humans to remove under-specified or impossible items. It is the variant serious vendors quote, and the one you should insist on: "72% on SWE-bench" without saying which variant means very little.

SWE-bench vs HumanEval: two different worlds

HumanEval tests functions in isolation: "write a function that reverses a list." SWE-bench tests fixing real bugs in real projects. It is the difference between a programming exam and an actual working day. Devstral was built for the latter.

Devstral Small 2: The One You Host Yourself

For teams that valued autonomy and cost:

Local deployment: 24 billion parameters is the size that makes self-hosting credible on reasonable hardware, without a data centre. That was the model's central argument.

Minimal cost: the API price says it all. $0.10 against $0.40 on input, $0.30 against $2.00 on output, Small 2 cost 4x less on input and nearly 7x less on output than Devstral 2. For autocompletion workloads, where request volume is enormous and each request tiny, that gap is decisive.

Genuinely open: Apache 2.0, without the restrictions carried by its big brother's licence. See the next section.

Two Licences, and That Is Not a Detail

This is the trap in this line-up, and it is worth understanding precisely because it recurs with every vendor.

Devstral Small 2 was Apache 2.0. A classic permissive open-source licence that every legal department already knows: commercial use allowed, no reciprocity clause, obligations limited to preserving copyright and licence notices.

Devstral 2 was "Modified MIT". The important word is modified. The standard MIT licence is one of the most permissive in existence; adding modifications to it can only go in the direction of restriction. The exact text shipped alongside the weights, in the LICENSE file of the Hugging Face repository.

The legal reflex on open weights

"Open weights" is not a licence, it is a marketing description. Two models from the same family, released on the same day by the same vendor, can carry completely different terms of use, which is exactly what happened here. The only binding text is the LICENSE file published with the weights you download, for the version you download. Neither the product page, nor the press release, nor this course page substitutes for it.

What Devstral Could Do

Unit test generation: read a function, identify edge cases (null inputs, empty lists, extreme values), and generate tests covering those scenarios.

Code migration: Python 2 to 3, JavaScript to TypeScript, React class components to hooks. Refactoring guided by an understanding of equivalences between paradigms.

Automatic documentation: read the code and generate docstrings, READMEs, API guides. Documentation is usually the first casualty of a deadline.

Code review: style, potential bugs, performance optimisations, best-practice violations.

None of these capabilities were lost: they live in Mistral Medium 3.5, which Mistral describes as optimised precisely for agentic and coding use cases.

Why Dedicated Code Models Disappeared

This is the structural story of 2026, and it goes well beyond Mistral.

Where specialisation came from. Around 2023-2024, training a model specifically on code gave an enormous edge over a generalist. Specialisation paid, so each capability became its own commercial reference, a SKU: a code model, a reasoning model, a vision model.

Why it stopped paying. Three reasons.

First, capabilities refused to stay in their box. Fixing a real bug demands sustained reasoning; reading an error screenshot demands vision. A pure "code model" was becoming a crippled model.

Second, routing fell on the customer. It was up to you to guess which model to call for which task, and a good share of integration work consisted of writing that routing logic, which then got it wrong.

Third, every extra reference is expensive to maintain: documentation, safety evaluations, weights to host, a deprecation curve to manage. A catalogue of fifteen models means fifteen migrations imposed on your customers.

What replaces them. A single set of weights, with behaviour set at call time rather than chosen upfront. Mistral Medium 3.5 illustrates the formula: reasoning effort configurable per request, on one set of weights. You no longer swap models by task, you turn a dial. OpenAI and Anthropic made the same shift earlier in 2026.

What stays specialised. Not everything, and this matters: Mistral kept Codestral for in-editor code completion. The reason is latency, not capability, a suggestion that appears while you type has to answer within tens of milliseconds, which a 128-billion-parameter model cannot do no matter how good it is. Consolidation stops where physical constraints begin.

The habit to keep. Do not hard-code a model name into a contract or an architecture if you can avoid it. At the pace observed in 2025-2026, a commercial reference lives between twelve and twenty-four months: Devstral Small 2 was deprecated less than three months after release. Capabilities, on the other hand, survive.

The future: autonomous developer agents

GitHub Copilot Workspace, Cursor, Devin, and now Vibe at Mistral: all these tools converge on the same vision. From passive autocompletion to autonomous agents implementing complete features from a natural-language description. Devstral was the stage where the code model learned to act; the next stage was making that skill unremarkable inside a generalist model.


Devstral 2 and Small 2 were Mistral's bet on AI for software development: not just autocompletion, but project-level intelligence. The models are retired; the bet was won so thoroughly that the category became unnecessary.