Instructions to use yeasah/MiniCPM5-2B-exl3 with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use yeasah/MiniCPM5-2B-exl3 with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="yeasah/MiniCPM5-2B-exl3")# pip install -U transformers accelerate # Load model directly from transformers import AutoModel model = AutoModel.from_pretrained("yeasah/MiniCPM5-2B-exl3", device_map="auto") - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use yeasah/MiniCPM5-2B-exl3 with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "yeasah/MiniCPM5-2B-exl3" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "yeasah/MiniCPM5-2B-exl3", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker
docker model run hf.co/yeasah/MiniCPM5-2B-exl3
- SGLang
How to use yeasah/MiniCPM5-2B-exl3 with SGLang:
Install from pip and serve model
# Install SGLang from pip: pip install sglang # Start the SGLang server: python3 -m sglang.launch_server \ --model-path "yeasah/MiniCPM5-2B-exl3" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "yeasah/MiniCPM5-2B-exl3", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker images
docker run --gpus all \ --shm-size 32g \ -p 30000:30000 \ -v ~/.cache/huggingface:/root/.cache/huggingface \ --env "HF_TOKEN=<secret>" \ --ipc=host \ lmsysorg/sglang:latest \ python3 -m sglang.launch_server \ --model-path "yeasah/MiniCPM5-2B-exl3" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "yeasah/MiniCPM5-2B-exl3", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }' - Docker Model Runner
How to use yeasah/MiniCPM5-2B-exl3 with Docker Model Runner:
docker model run hf.co/yeasah/MiniCPM5-2B-exl3
EXL3 quantizations of openbmb/MiniCPM5-2B
Made from commit 42433e90 of the base model.
These quantizations can be used with exllamav3 or vLLM via vllm-exl3-plugin.
The token embedding is quantized too, which needs exllamav3 1.6.4 or later.
They are calibrated broadly, on what models read and write while working (documents and tool output in conversations, code and diffs, the model's own replies) rather than on web text alone.
Bits are allocated per tensor, from the model's measured sensitivity on its own replies, at the same total size as uniform bits.
Values are rounded against how much each output matters to the model's predictions (two-sided LDLQ with an output-side Fisher factor, after YAQA), which changes only how they are rounded: the size and format are the same.
Actual consumed VRAM may be significantly lower than the total checkpoint size, depending on configuration: see the VRAM column below.
Which size?
Each bitrate is available as a separate revision of this repository. When planning available VRAM for kv space, refer to the VRAM column.
Every other quant on this card was scored at a specific revision of its repository: which ones.
bartowski/MiniCPM5-2B-GGUF is drawn on the same axes, scored by llama.cpp on the same evals: absolute excess KLD at the same size measure, so any point compares with any other, across sizes too.
The dashed line marks MiniCPM5-2B-GGUF Q6_K, scored on the same evals as these quants: a familiar point to read them against. GGUF lines are scored by llama.cpp, as served.
| BPW | Size on disk | VRAM (vLLM) | Excess KLD | Δ perplexity |
|---|---|---|---|---|
| 3.00 | 0.98 GiB | 0.85 GiB | 0.0573 | +6.24% |
| 3.50 | 1.09 GiB | 0.97 GiB | 0.0283 | +2.95% |
| 4.00 | 1.24 GiB | 1.11 GiB | 0.0142 | +1.42% |
| 5.00 | 1.50 GiB | 1.34 GiB | 0.0037 | +0.36% |
| 6.00 | 1.73 GiB | 1.57 GiB | 0.0010 | +0.13% |
| (base) | 4.69 GiB |
- BPW: Average bits per weight across tensors (not including input embeddings, encoders, MTP draft layers, or output head)
- Size on disk: Total aggregate size of tensors in checkpoint, in GiB
- VRAM (vLLM): Weights held in VRAM by vLLM with vllm-exl3-plugin, in GiB (the input embedding's table in host memory, as the plugin serves it by default; offloaded/omitted encoders, no MTP draft layers)
- Excess KLD: how far each quant's next-token distribution is from the unquantized model's, minus the unquantized model's own rounding noise, so 0 would be indistinguishable from the original (lower is better)
- Δ perplexity: change in perplexity on the same text, same weights (lower is better)
What it still knows
Quantization can leave a model fluent but wrong about facts, which KLD does not show. Each quant answered 871 closed-book questions the unquantized model gets right, with the answer scored token by token. This is a test of memory on short factual questions, not of overall capability.
| bpw | Facts kept | Confident errors |
|---|---|---|
| 3.00 | 75.8% | 3.56% |
| 3.50 | 84.9% | 2.99% |
| 4.00 | 86.9% | 1.38% |
| 5.00 | 93.4% | 0.46% |
| 6.00 | 97.0% | 0.11% |
- Facts kept: of the correct answers the unquantized model would give when sampling, the share this quant still gives.
- Confident errors: questions where this quant puts at least 70% on a wrong token, so it states something false rather than hesitating.
Loss is not spread evenly. A quant holds on to what the unquantized model was sure of and loses more of what it barely knew:
How the unquantized model holds what it knows matters as much as how a quant treats each band: of the facts it gets right, it holds 43% sure, 18% firm, 16% leaning, 12% shaky, 11% barely (by the bands above). A model whose knowledge leans toward the lower bands has more to lose once a quant runs short of bits; hedging is a valid way to know things, and it is measured here as it is held.
Bars are approximate and cover both sampling and the difference between equivalent conversions. Differences of a point or two between rungs mean little.
Other published quants of this model, scored on the same questions, show how much is at stake at each size, and how fast facts go once a quant is small enough:
Each dot is one published quant, at its weights as served. Each is a single conversion, and conversions with the same settings land a few points apart here, so read where the dots lie as a group rather than any one of them against this card's line.
More detail
What each eval slice is, every slice compared on its own, how the composite is built, the calibration, and how to reproduce these quants: TECHNICAL.md.
Model tree for yeasah/MiniCPM5-2B-exl3
Base model
openbmb/MiniCPM5-2B

