Skip to main content
Back

MiniCPM5-15B-A2.5B

MiniCPM Text Series

MiniCPM5-15B-A2.5B is the sparse Mixture-of-Experts (MoE) model in the MiniCPM5 series, with 15B total parameters and 2.5B activated parameters, designed as an on-device native agent. It runs locally on phones, PCs and other edge devices, delivering general work, coding, tool calling and complex reasoning under tight resource budgets. It supports hybrid thinking and a 512K context window, and works with agent harnesses such as Codex, Claude Code, DeepSeek Harness and WorkBuddy, so data and execution stay on the user's device.

  • Strongest model under 20B: With less than half the parameters of Qwen3.6-35B-A3B, it surpasses it overall, and scores 11 on the AA-Index leaderboard, ranking first among models under 20B.
  • On-device inference speed: Decodes at up to 52 tokens/s on an iPhone 18 Pro Max without memory limits; with native prefetch-routing training, it still reaches 30 tokens/s at about 3 GB of memory.
  • IMO / CMO gold-medal reasoning: Scored 123/126 in the CMO 2026 final with an official gold medal, and 32 points on a self-evaluated IMO 2026, above the 29-point gold line — the first on-device model to reach IMO gold level.

Pick the weight format that matches your deployment tool, or choose the Base, Midtrain or SFT checkpoint for your training needs. Checkpoints from different training stages serve different purposes, so read the corresponding model card first.

Model Downloads​

Recommended version: MiniCPM5-15B-A2.5B (BF16 / GGUF / MLX / GPTQ / LiteRT):

Q3_gud-LCO-GGUF and Q4_K_M-LCO-GGUF target llama.cpp-omni. On iOS, Q3_gud-LCO-GGUF is recommended for faster inference.

Quick Start​

The three most common inference paths are shown below. The default context length is 524,288 tokens; if you run out of GPU memory, increase tensor parallelism or reduce the context length. For thinking mode, MiniCPM5-15B-A2.5B recommends temperature=1.0, top_p=0.95, min_p=0.0.

vLLM (OpenAI-compatible server, NVIDIA GPU)​

Requires the latest main branch or a nightly build that includes PR #69127 and PR #69128:

Bash
uv pip install -U vllm --torch-backend=auto --extra-index-url https://wheels.vllm.ai/nightly
vllm serve openbmb/MiniCPM5-15B-A2.5B --served-model-name MiniCPM5-15B-A2.5B --port 8000

Test request:

Bash
curl http://localhost:8000/v1/chat/completions \
-H "Content-Type: application/json" \
-d '{
"model": "MiniCPM5-15B-A2.5B",
"messages": [{"role": "user", "content": "Who are you? Please introduce yourself briefly."}],
"max_tokens": 512,
"temperature": 1.0,
"top_p": 0.95
}'

Replace the model path with MiniCPM5-15B-A2.5B-GPTQ to use the 4-bit quantized version.

SGLang (OpenAI-compatible server, NVIDIA GPU)​

Requires the latest main branch that includes PR #52071 and PR #52072:

Bash
git clone https://github.com/sgl-project/sglang.git
cd sglang
pip install -e "python[all]"
python -m sglang.launch_server --model-path openbmb/MiniCPM5-15B-A2.5B --served-model-name MiniCPM5-15B-A2.5B --port 8000

Requests work the same way as with vLLM.

DSpark Speculative Decoding​

We also release MiniCPM5-15B-A2.5B-DSpark, a draft model trained for MiniCPM5-15B-A2.5B. Enabling it speeds up decoding while keeping the target model's output unchanged.

Bash
# SGLang
python -m sglang.launch_server --model-path openbmb/MiniCPM5-15B-A2.5B --served-model-name MiniCPM5-15B-A2.5B --port 8000 \
--speculative-algorithm DSPARK \
--speculative-draft-model-path openbmb/MiniCPM5-15B-A2.5B-DSpark \
--speculative-dspark-block-size 7

# vLLM
vllm serve openbmb/MiniCPM5-15B-A2.5B --served-model-name MiniCPM5-15B-A2.5B --port 8000 \
--speculative-config '{"method":"dspark","model":"openbmb/MiniCPM5-15B-A2.5B-DSpark","num_speculative_tokens":7}'

Transformers (local Python inference, CPU or GPU)​

The model architecture is MiniCPM5MoEForCausalLM, natively integrated into Transformers (minicpm5_moe), so trust_remote_code is not required.

Bash
pip install -U "transformers>=5.25.0" accelerate torch

Local inference test:

Python
from transformers import AutoModelForCausalLM, AutoTokenizer

model_id = "openbmb/MiniCPM5-15B-A2.5B"
tokenizer = AutoTokenizer.from_pretrained(model_id)
model = AutoModelForCausalLM.from_pretrained(model_id, dtype="auto", device_map="auto")

messages = [{"role": "user", "content": "Who are you? Please introduce yourself briefly."}]
inputs = tokenizer.apply_chat_template(
messages,
tokenize=True,
add_generation_prompt=True,
enable_thinking=True, # set to False to disable thinking mode
return_dict=True,
return_tensors="pt",
).to(model.device)

outputs = model.generate(**inputs, max_new_tokens=512)
print(tokenizer.decode(
outputs[0][inputs["input_ids"].shape[-1]:],
skip_special_tokens=True,
))

Recommended sampling parameters:

  • General tasks: thinking mode temperature=1.0, top_p=0.95, min_p=0.0 (add repetition_penalty=1.05 if repetition occurs); non-thinking mode temperature=0.7, top_p=0.80, top_k=20, min_p=0.0, presence_penalty=1.5.
  • Creative writing: thinking mode temperature=0.7, top_p=0.95, min_p=0.0, repetition_penalty=1.05; non-thinking mode temperature=0.7, top_p=0.80, top_k=20, min_p=0.0, presence_penalty=0.5.

For other backends (llama.cpp / Ollama / LM Studio / MLX-VLM / vLLM Ascend / LiteRT-LM), see the Deployment Guide.

Tool Calling and Agent Integration​

SGLang is recommended. MiniCPM5-15B-A2.5B natively supports thinking mode, parallel multi-tool calls in a single turn, and long-horizon multi-turn agent workflows. Launch with the minicpm5 tool-call parser and the qwen3 reasoning parser to get OpenAI-compatible tool_calls and reasoning_content fields.

Bash
# SGLang
python -m sglang.launch_server --model-path openbmb/MiniCPM5-15B-A2.5B --served-model-name MiniCPM5-15B-A2.5B --port 8000 \
--tool-call-parser minicpm5 --reasoning-parser qwen3

# vLLM
vllm serve openbmb/MiniCPM5-15B-A2.5B --served-model-name MiniCPM5-15B-A2.5B --port 8000 \
--enable-auto-tool-choice --tool-call-parser minicpm5 --reasoning-parser qwen3
  • Thinking mode is on by default. To turn it off for lower latency, pass chat_template_kwargs: {"enable_thinking": false} for Chat Completions, reasoning: {"effort": "none"} for Responses, or thinking: {"type": "disabled"} for Anthropic Messages.
  • The current chat template does not strip historical reasoning. In multi-step tool calls and agent trajectories, send the earlier reasoning (reasoning_content / reasoning / thinking) back with the history to keep the chain of thought coherent and improve the prefix KV cache hit rate.
  • Verified to work with Claude Code, Codex CLI / Desktop, DeepSeek Harness and WorkBuddy via CC Switch. For full request formats, multi-turn parallel calls and harness setup steps, see the Tool Usage Guide.

Running on iOS​

Install MiniCPM-V-Apps via TestFlight, select MiniCPM5-15B-A2.5B in the model list and download it to run locally on iPhone. For detailed steps and FAQ, see Running MiniCPM5-15B-A2.5B on iOS.

Model Information​

ItemDetails
TypeCausal Language Model (sparse MoE)
ArchitectureMiniCPM5MoEForCausalLM
Parameters15B total, 2.5B activated
Layers / hidden size28 layers / 2,048
AttentionGated Attention, GQA with 32 Q heads / 2 KV heads, head dim 128
Feed-forwardLayer 0 is a dense MLP (intermediate 8,192); layers 1–27 are MoE with 160 routed experts, 16 routed + 1 shared expert activated per token, expert intermediate 512
Vocabulary size130,560
Context length524,288

Developer Showcase

View all →
MiniCPM Textminicpm-dream: Nightly Memory PassLets a local agent tidy up and file the day's memories every nightMiniCPM Textmateria: Local Lab Result AssistantInterprets lab results locally, with a citation behind every suggestionMiniCPM TextMiniCPM-V MultimodalPaperReview: Handwritten Essay GradingReads and grades handwritten English essays line by line on a MacMiniCPM TextVoxCPM SpeechESP32 Radar Tower: AI ATC CalloutsA round-AMOLED tower radar announcing flights in a cloned ATC voiceMiniCPM TextVoxCPM SpeechESP32-S3 Talking Attitude IndicatorA desk flight instrument that holds voice exchanges with the towerMiniCPM TextClaimLedger: Claim Check LedgerChecks every claim in a report against its source before it shipsMiniCPM TextSelf-Evolving Catgirl: Reasoning via On-Policy Self DistillationNo teacher, no new base model: math reasoning emerges from self-distillationMiniCPM TextReJev: Decision-Model Post-TrainingLoRA post-training MiniCPM5-2B: 51.1% → 80.5% on a sealed holdoutMiniCPM TextBMB Agent: a MiniCPM-powered Personal AssistantLetting a 2B on-device model take over schedules and todos, with real-world lessonsMiniCPM TextMetaCog: Judge-Steered ReasoningAn inference-time loop where a judge scores parallel thought pathsMiniCPM TextOpenClaw Log Assistant: Local Log TriageLocal log analysis with MiniCPM5-2B that separates evidence from hypothesesMiniCPM TextMiniCPM News Desk: Local Daily BriefA local-first daily brief where MiniCPM5-2B picks exact source passagesMiniCPM TextWebGPU Pi: In-Browser Coding AgentMiniCPM5-2B running a coding agent fully in-browser via WebGPUMiniCPM TextMiniCPM5-1B Tool-Use: Offline Function CallsA 1B GGUF function-calling model (SFT + GRPO) that runs offline on CPUMiniCPM Textdeku: A Trustworthy Local Task AgentCode plans, MiniCPM5-1B answers briefly or refusesMiniCPM TextMiniCPM5-1B: LiteRT & Iberian EvalsINT8 LiteRT-LM build plus Spanish, Catalan, Basque and Galician evalsMiniCPM TextMiniCPM-V MultimodalMiniCPM Agent Gateway: Edge-Cloud RoutingLocal MiniCPM classifies each request so sensitive data stays on-deviceMiniCPM TextToneBridge: Context-Aware Mandarin CoachCorrects Mandarin sentences by context and tone, with pinyin and audioMiniCPM TextMiniCPM5-1B FP8: Faster NVIDIA InferenceFP8 vLLM profile hitting 248 decode tok/s on RTX 3060, 1.5× BF16MiniCPM TextAUGURY: Reading Soil Health from WeedsMaps weed species to soil-health indicators; phone-deployable, no cloudMiniCPM Textgmgn-minicpm: Local Crypto Research AgentA read-only GMGN crypto research agent powered by a local 1B modelMiniCPM TextMiniCPM-V MultimodalLost & Found Desk: Small-Model Item ReturnMiniCPM-V captions items, MiniCPM5 guides claims, staff confirm every handoffMiniCPM TextMiniCPM-V MultimodalVoxCPM SpeechCoreAI Model Zoo: MiniCPM on iPhoneCore AI builds of MiniCPM5 and MiniCPM-V 4.6 running natively on iPhone and MacMiniCPM TextMiniCPM-V MultimodalViva Mais: Local WhatsApp CRM CopilotA travel-agency copilot that turns WhatsApp chats into a local-first CRMMiniCPM TextTianwen: BaZi & I-Ching ReflectionA 1B model that turns BaZi and I-Ching readings into self-reflectionMiniCPM TextWanderLust: Mood-Driven Discovery WalksPlans exploratory A-to-B walking routes based on your moodMiniCPM TextNIGHTWAVE: 1970s Radio Hosted by a 1B ModelA 1970s late-night radio with a 1B-model DJ who takes live callsMiniCPM Text6ixPulse: Agentic Toronto Rent MapAgents compare Toronto neighborhoods, citing a source for every claimMiniCPM TextWall Street of AI AgentsFour small-model AI traders roam a pixel office and trade on their ownMiniCPM TextHackathon Advisor: Idea Map & CoachMaps hackathon ideas and coaches you toward more original projectsMiniCPM TextLLM Cinema: AI-Directed ASCII FilmsA small model writes and directs ASCII-art films in the browserMiniCPM Texttiny-llm: A Pure-Rust Inference EngineA from-scratch, CPU-only Rust inference engine for MiniCPM5-1B with a TUIMiniCPM TextDocument Field Agent: Batch OCR & ExtractionA workbench for batch document OCR and structured field extractionMiniCPM TextMiniCPM-V MultimodalWhen a Catgirl Learns to Think, on Your PhoneWas this model made for catgirls? An on-device deployment testMiniCPM TextMiniCPM-V MultimodalMaking a 1B Model a Good Math AgentTeXada’s on-device MiniCPM practice and lessonsMiniCPM TextORG-2: A Workbench for Coding AgentsAn organizational workbench to orchestrate and manage multiple coding agentsMiniCPM TextEdgeHome HarnessA replayable, evaluable local control loop for a 1B on-device model, built in RustMiniCPM TextSqueezing a NAS: Hooking Up WorkBuddyRunning local AI on an N150 CPU: real-world uses and lessons learned