MiniCPM5 2B: Compact Open Model with Long Context and Tool Calling
MiniCPM5 2B is OpenBMB's flagship small language model: a 2.5-billion-parameter dense model built on the standard Llama architecture, with a native 131K-token context window. It targets on-device and cost-sensitive serving while claiming state-of-the-art results for its size class in reasoning, code, math, long-context and agentic tasks.
Key Features
- 131K native context - long-document understanding and retrieval without context-extension tricks, backed by grouped-query attention with a very compact KV cache
- Hybrid reasoning - a chat-template-controlled deep-thinking mode can be switched on per request for harder reasoning problems, or left off for fast direct answers
- Native tool calling - the model emits structured tool calls that vLLM and SGLang convert to OpenAI-compatible responses via their built-in MiniCPM5 parsers
- Agentic training - post-training combines large-scale deep-thinking supervised fine-tuning, critic-based reinforcement learning, and on-policy distillation that merges multiple RL expert models
- Standard architecture - plain Llama-style decoder with no custom kernels or model-code forks, so mainstream inference engines load it directly
Architecture
The model is a deep-and-narrow dense transformer: 42 layers at a 2048 hidden size, with 16 query heads and 2 key-value heads per layer. That grouped-query layout keeps the key-value cache small enough to hold the full 131K context on a single GPU. Alongside the main checkpoint, OpenBMB publishes quantized GGUF and GPTQ versions, a DSpark draft model for speculative decoding, and the Base and SFT lifecycle checkpoints.
Benchmarks
OpenBMB reports an average of 53.9 across its evaluation suite, ahead of the listed 4B-class open models, with standout results on agentic benchmarks including 46.4 on SWE-bench Verified and 97.1 on tau-squared-Bench Telecom. The reinforcement-learning and distillation stages are credited with roughly 11 points of improvement on reasoning and general benchmarks over the SFT checkpoint.
Use Cases
- Agentic workflows and tool-using assistants at low cost per token
- Long-document analysis, summarization and retrieval
- Code generation and repair
- Math and structured reasoning with the thinking mode enabled
- On-device and edge deployment where memory is constrained
See the MiniCPM5-2B model card for full details.