Codestral 2 is Mistral's code generation specialized model built specifically for high-precision fill-in-the-middle (FIM) completion. It helps developers write and interact with code through a shared instruction and completion API endpoint. As it masters code and can also converse in a variety of languages, it can be used to design advanced AI applications for software developers.
The latest release of Codestral 2 delivers measurable upgrades over prior version Codestral (25.01):
- 30% increase in accepted completions.
- 10% more retained code after suggestion.
- 50% fewer runaway generations, improving confidence in longer edits.
Improved performance on academic benchmarks for short and long-context FIM completion.
- Code generation: code completion, suggestions, translation.
- Code understanding and documentation: code summarization and explanation.
- Code quality: code review, refactoring, bug fixing and test case generation.
- Code fill-in-the-middle: users can define the starting point of the code using a prompt, and the ending point of the code using an optional suffix and an optional stop. The Codestral model will then generate the code that fits in between, making it ideal for tasks that require a specific piece of code to be generated.
Codestral 2 is well-suited for tasks such as:
- Code generation
- Fill-in-the-middle completion
- Software development applications
View model card in Model Garden
| Model ID | codestral-2 |
|
|---|---|---|
| Launch stage | GA | |
| Supported inputs & outputs |
|
|
| Usage types |
|
|
| Versions |
|
|
| Supported regions | ||
|
Model availability |
|
|
|
ML processing |
|
|
| Quota limits |
us-central1:
europe-west4:
|
|
| Pricing | See Pricing. | |