Downloads · 30 days
21
27% of all-time downloads
Jeff98/MiniCPM5-2B-int4-gq-ov
MiniCPM5-2B-int4-gq-ov is a text generation model from Jeff98. Use it when you need the model to write or continue text. It is set up for openvino. The card lists the license as apache-2.0.
This repository contains an INT4 group-wise quantized OpenVINO conversion of openbmb/MiniCPM5-2B.
Downloads · 30 days
21
27% of all-time downloads
All-time downloads
77
Public
Repo size
1.6 GB
Likes
0
Public
Click a slice to open those files.
.bin1.6 GB · 99%
From the Hugging Face model README
This repository contains an INT4 group-wise quantized OpenVINO conversion of openbmb/MiniCPM5-2B.
The model is intended for efficient local inference on OpenVINO-supported hardware, including Intel CPUs, GPUs, and NPUs (tested on U7-155H) with reduced memory footprint compared with the original floating-point model.
This is a community conversion. The model architecture, training, tokenizer, chat template, capabilities, and license originate from the original MiniCPM5-2B model by OpenBMB.
| Property | Value |
|---|---|
| Base model | openbmb/MiniCPM5-2B |
| Framework | OpenVINO |
| Task | Text generation with KV cache |
| Weight precision | INT4 |
| Quantization scheme | Symmetric group-wise weight quantization |
| Group size | 128 |
| INT4 ratio | 1.0 |
| Export task | text-generation-with-past |
| Primary languages | Chinese / English |
| License | Apache-2.0 |
The model uses weight-only INT4 compression. Activations are not explicitly quantized by the export command used for this repository.
A group size of 128 provides a practical trade-off between compression efficiency, inference performance, and model quality for small language models.
The main quantization parameters are:
weight format : INT4
symmetric : true
ratio : 1.0
group size : 128
ratio=1.0 requests 4-bit compression for all eligible weight layers. Operations that cannot use the requested compression configuration may be handled according to the exporter's fallback behavior.
This repository uses data-free weight compression and does not apply AWQ, GPTQ, scale estimation, or calibration-dataset-based optimization.
This model is suitable for:
For full information about the model's original training, capabilities, evaluation results, and limitations, see the upstream model:
import openvino_genai as ov_genai
model_path = "Jeff98/MiniCPM5-2B-int4-gq-ov"
pipe = ov_genai.LLMPipeline(
model_path,
"GPU",
)
result = pipe.generate(
"Explain what OpenVINO is in simple terms.",
max_new_tokens=256,
)
print(result)
If the repository has first been downloaded locally:
import openvino_genai as ov_genai
pipe = ov_genai.LLMPipeline(
r"/path/to/MiniCPM5-2B-int4-gq-ov",
"GPU",
)
print(
pipe.generate(
"你好,请简单介绍一下你自己。",
max_new_tokens=256,
)
)
Depending on your OpenVINO installation and hardware, the target device may be changed to:
CPU
GPU
NPU
Device support and generation quality should be validated on the target hardware and OpenVINO version.
The model can also be served through OpenVINO Model Server (OVMS).
Example:
ovms \
--model_name MiniCPM5-2B \
--model_path /path/to/MiniCPM5-2B-int4-gq-ov \
--rest_port 8000 \
--target_device GPU
On Windows PowerShell:
ovms `
--model_name MiniCPM5-2B `
--model_path "C:\models\MiniCPM5-2B-int4-gq-ov" `
--rest_port 8000 `
--target_device GPU
Once started, OVMS exposes an OpenAI-compatible API.
Example:
from openai import OpenAI
client = OpenAI(
base_url="http://127.0.0.1:8000/v3",
api_key="unused",
)
response = client.chat.completions.create(
model="MiniCPM5-2B",
messages=[
{
"role": "user",
"content": "Hello! Briefly introduce yourself."
}
],
max_tokens=256,
)
print(response.choices[0].message.content)
MiniCPM5 supports tool-calling capabilities inherited from the original model.
When serving through a backend that applies the original MiniCPM5 chat template, ensure that the backend supports the Jinja features used by the template and provides the corresponding MiniCPM5 tool parser.
Tool-calling behavior may depend on:
The model can be used with OpenVINO CPU inference:
--target_device CPU
INT4 weight compression substantially reduces the model's memory footprint compared with floating-point weights.
Intel GPU is a recommended deployment target for this conversion:
--target_device GPU
Actual latency and throughput depend on the GPU architecture, driver version, OpenVINO version, prompt length, and generation settings.
OpenVINO support and model compatibility on Intel NPUs evolve over time.
Although an OpenVINO IR model may successfully compile on an NPU, this does not by itself guarantee identical numerical behavior to CPU or GPU inference. In particular, long-context or long-generation workloads should be validated on the specific NPU generation, driver, and OpenVINO version being used.
For production or long-reasoning workloads, compare the output against CPU/GPU inference before deployment.
INT4 compression reduces model size and memory bandwidth requirements but may introduce a small accuracy loss relative to the original floating-point checkpoint.
This repository uses:
symmetric INT4
group size = 128
ratio = 1.0
Smaller group sizes or data-aware quantization methods may improve accuracy at the cost of conversion time, model size, or inference performance.
For applications that are particularly sensitive to reasoning or generation quality, consider comparing this model against:
This conversion inherits all limitations of the original MiniCPM5-2B model.
Possible limitations include:
The model should not be assumed to produce identical outputs across Transformers, OpenVINO CPU, OpenVINO GPU, and OpenVINO NPU backends.
This repository only provides an optimized OpenVINO representation of the original MiniCPM5-2B model.
No additional fine-tuning, preference optimization, or alignment training has been performed.
openbmb/MiniCPM5-2B
│
│ Optimum Intel / OpenVINO export
│
├── INT4 weight compression
├── symmetric quantization
├── group size 128
└── text-generation-with-past
│
▼
Jeff98/MiniCPM5-2B-int4-gq-ov
The original MiniCPM5 model was developed by the OpenBMB team.
Please refer to the original model repository for model architecture, training methodology, benchmark results, ethical considerations, and upstream licensing information.
This repository follows the Apache License 2.0 used by the original openbmb/MiniCPM5-2B checkpoint.
Users should review the upstream model card and license before redistribution or deployment.