Codestral 22B

by Mistral AI · mistral family

22B

parameters

text-generation code-generation

Codestral 22B is Mistral AI's dedicated code generation model, trained on over 80 programming languages. It excels at code completion, generation, and explanation tasks, with particular strength in Python, JavaScript, TypeScript, Java, C++, and many other languages. This model is optimized for developer workflows including fill-in-the-middle completion, test generation, and code documentation. It offers significantly better coding performance than general-purpose models of similar size.

Quick Start with Ollama

ollama run 22b-v0.1-q4_K_M
Creator Mistral AI
Parameters 22B
Architecture transformer-decoder
Context Length 32K tokens
License Mistral AI Non-Production License
Released May 29, 2024
Ollama codestral

Quantization Options

Format File Size VRAM Required Quality Ollama Tag
Q4_K_M recommended 11.2 GB 14.7 GB
22b-v0.1-q4_K_M
Q5_K_M 13 GB 16.9 GB
22b-v0.1-q5_K_M
Q8_0 19.8 GB 24 GB
22b-v0.1-q8_0

Compatible Hardware for Q4_K_M

Showing compatibility for the recommended quantization (Q4_K_M, 14.7 GB VRAM).

Compatible Hardware

Hardware VRAM Type Fit
Mac Pro M2 Ultra 192GB 192 GB mac Runs
Mac Studio M4 Ultra 192GB 192 GB mac Runs
Mac Studio M4 Max 128GB 128 GB mac Runs
MacBook Pro M4 Max 128GB 128 GB mac Runs
Mac Studio M4 Max 64GB 64 GB mac Runs
MacBook Pro M4 Max 64GB 64 GB mac Runs
Mac mini M4 Pro 48GB 48 GB mac Runs
MacBook Pro M4 Max 48GB 48 GB mac Runs
MacBook Pro M4 Pro 48GB 48 GB mac Runs
NVIDIA GeForce RTX 5090 32 GB gpu Runs
Mac mini M4 32GB 32 GB mac Runs
AMD Radeon RX 7900 XTX 24 GB gpu Runs
NVIDIA GeForce RTX 3090 24 GB gpu Runs
NVIDIA GeForce RTX 4090 24 GB gpu Runs
Mac mini M4 Pro 24GB 24 GB mac Runs
MacBook Air M4 24GB 24 GB mac Runs
MacBook Pro M4 Pro 24GB 24 GB mac Runs
AMD Radeon RX 7900 XT 20 GB gpu Runs
AMD Radeon RX 7800 XT 16 GB gpu Runs (tight)
Intel Arc A770 16 GB gpu Runs (tight)
NVIDIA GeForce RTX 4060 Ti 16GB 16 GB gpu Runs (tight)
NVIDIA GeForce RTX 4070 Ti Super 16 GB gpu Runs (tight)
NVIDIA GeForce RTX 4080 16 GB gpu Runs (tight)
NVIDIA GeForce RTX 5080 16 GB gpu Runs (tight)
Mac mini M4 16GB 16 GB mac Runs (tight)
MacBook Air M3 16GB 16 GB mac Runs (tight)
MacBook Air M4 16GB 16 GB mac Runs (tight)
NVIDIA GeForce RTX 3060 12GB 12 GB gpu CPU Offload
NVIDIA GeForce RTX 3080 12GB 12 GB gpu CPU Offload
NVIDIA GeForce RTX 4070 Ti 12 GB gpu CPU Offload
NVIDIA GeForce RTX 4070 12 GB gpu CPU Offload
5 hardware device(s) cannot run this model configuration.

Benchmark Scores

60.0
mmlu