Model reference · open weights

MiniCPM3

LLMs openbmb Text gen 1 build Open weights 27k dl/mo

MiniCPM3 is an open-weight language model from openbmb. MiniCPM3-4B (BF16) weighs 8.1 GB; the smallest configuration that runs it is RTX 3060 12 GB.

  • MiniCPM3-4B is a text-generation model developed by openbmb that supports Chinese and English.
  • It features a 32,768 token context window and includes capabilities for function calling and code interpretation.
  • The model is released under the Apache-2.0 license.

Summary of the openbmb/MiniCPM3-4B model card, 2026-10-01

What it is

Released byopenbmb
Released2024-09-03
VRAM8.1 GB for the weights

What it runs on

Memory and cards for MiniCPM3-4B (BF16)

8.1 GBweights, file size
36 MBcache per 1K tokens
599 MBruntime overhead, at least
32,768 tokenscontext max
CardRequests at onceContext maxMemory
8K each32K each
RTX 3060 12 GB92all 32K11.6 GB
RTX 4060 Ti 16 GB225all 32K15.4 GB
RTX 3090 24 GB5012all 32K23.4 GB
RTX 4090 24 GB4912all 32K23.4 GB
RTX 5090 32 GB7619all 32K31.0 GB
L40S 48 GB12030all 32K44.0 GB
A100 80 GB23759all 32K78.2 GB
H100 80 GB22656all 32K78.1 GB
RTX PRO 6000 Blackwell 96 GB27969all 32K93.8 GB
DGX Spark (GB10) 128 GB unified32581all 32K107 GB
H200 141 GB430107all 32K138 GB
B200 180 GB560140all 32K176 GB
Memory needed at each load
Requests at once8K tokens each32K tokens each
19.0 GB9.9 GB
510.2 GB14.6 GB
811.1 GB18.1 GB
1613.4 GB27.5 GB
3218.1 GB46.2 GB
6427.5 GB83.6 GB

One card, with vLLM's small-card settings.

From the model card

What openbmb says about MiniCPM3

Read the model card

Introduction

MiniCPM3-4B is the 3rd generation of MiniCPM series. The overall performance of MiniCPM3-4B surpasses Phi-3.5-mini-Instruct and GPT-3.5-Turbo-0125, being comparable with many recent 7B~9B models.

Compared to MiniCPM1.0/MiniCPM2.0, MiniCPM3-4B has a more powerful and versatile skill set to enable more general usage. MiniCPM3-4B supports function call, along with code interpreter. Please refer to Advanced Features for usage guidelines.

MiniCPM3-4B has a 32k context window. Equipped with LLMxMapReduce, MiniCPM3-4B can handle infinite context theoretically, without requiring huge amount of memory.

Usage

Inference with Transformers

from transformers import AutoModelForCausalLM, AutoTokenizer
import torch

path = "openbmb/MiniCPM3-4B"
device = "cuda"

tokenizer = AutoTokenizer.from_pretrained(path, trust_remote_code=True)
model = AutoModelForCausalLM.from_pretrained(path, torch_dtype=torch.bfloat16, device_map=device, trust_remote_code=True)

messages = [
    {"role": "user", "content": "推荐5个北京的景点。"},
]
model_inputs = tokenizer.apply_chat_template(messages, return_tensors="pt", add_generation_prompt=True).to(device)

model_outputs = model.generate(
    model_inputs,
    max_new_tokens=1024,
    top_p=0.7,
    temperature=0.7
)

output_token_ids = [
    model_outputs[i][len(model_inputs[i]):] for i in range(len(model_inputs))
]

responses = tokenizer.batch_decode(output_token_ids, skip_special_tokens=True)[0]
print(responses)

Inference with vLLM

For now, you need to install our forked version of vLLM.

pip install git+https://github.com/OpenBMB/vllm.git@minicpm3
from transformers import AutoTokenizer
from vllm import LLM, SamplingParams

model_name = "openbmb/MiniCPM3-4B"
prompt = [{"role": "user", "content": "推荐5个北京的景点。"}]

tokenizer = AutoTokenizer.from_pretrained(model_name, trust_remote_code=True)
input_text = tokenizer.apply_chat_template(prompt, tokenize=False, add_generation_prompt=True)

llm = LLM(
    model=model_name,
    trust_remote_code=True,
    tensor_parallel_size=1
)
sampling_params = SamplingParams(top_p=0.7, temperature=0.7, max_tokens=1024, repetition_penalty=1.02)

outputs = llm.generate(prompts=input_text, sampling_params=sampling_params)

print(outputs[0].outputs[0].text)

Evaluation Results

Statement

  • As a language model, MiniCPM3-4B generates content by learning from a vast amount of text.
  • However, it does not possess the ability to comprehend or express personal opinions or value judgments.
  • Any content generated by MiniCPM3-4B does not represent the viewpoints or positions of the model developers.
  • Therefore, when using content generated by MiniCPM3-4B, users should take full responsibility for evaluating and verifying it on their own.

LICENSE

  • This repository is released under the Apache-2.0 License.
  • The usage of MiniCPM3-4B model weights must strictly follow MiniCPM Model License.md.
  • The models and weights of MiniCPM3-4B are completely free for academic research. after filling out a "questionnaire" for registration, are also available for free commercial use.

Citation

@article{hu2024minicpm,
  title={MiniCPM: Unveiling the Potential of Small Language Models with Scalable Training Strategies},
  author={Hu, Shengding and Tu, Yuge and Han, Xu and He, Chaoqun and Cui, Ganqu and Long, Xiang and Zheng, Zhi and Fang, Yewei and Huang, Yuxiang and Zhao, Weilin and others},
  journal={arXiv preprint arXiv:2404.06395},
  year={2024}
}

Quoted from the model card on Hugging Face. The full card is behind the Hugging Face link above.

© 2026 AxForge · EU-hosted AI infrastructure Pricing Docs Trust Privacy Terms