---
title: MiniCPM-2B-sft-4bit-llama-format-mlx
canonical_url: "https://www.modelscope.cn/models/mlx-community/MiniCPM-2B-sft-4bit-llama-format-mlx"
md_url: "https://www.modelscope.cn/models/mlx-community/MiniCPM-2B-sft-4bit-llama-format-mlx.md"
repository: mlx-community/MiniCPM-2B-sft-4bit-llama-format-mlx
last_updated: 2024-12-19
model_type:
  - llama
architectures:
  - LlamaForCausalLM
parameters: 708.7M
tensor_type:
  - U32
  - F16
library_name:
  - mlx
  - safetensors
  - pytorch
frameworks:
  - pytorch
language:
  - en
  - zh
inference_backends:
  - "deploy_task text/emb"
  - "lmdeploy 0.9.1"
  - "lmdeploy_turbomind 0.9.1"
  - "sglang 0.5.2"
  - "vllm 0.9.2"
downloads: 1002
stars: 0
tags:
  - MiniCPM
  - ModelBest
  - THUNLP
  - mlx
---

# MiniCPM-2B-sft-4bit-llama-format-mlx

> MiniCPM-2B-sft-4bit-llama-format-mlx - mlx-community 在 ModelScope 开源的模型。mlx-community/MiniCPM-2B-sft-4bit-llama-format-mlx This model was converted to MLX format from mlx-community/MiniCPM-2B-sft-bf16-llama-format-mlx using mlx-lm version 0.8.0. Refer to the…

mlx-community/MiniCPM-2B-sft-4bit-llama-format-mlx 是 ModelScope 魔搭社区上的 708.7M 参数机器学习模型，可用 deploy_task text/emb、lmdeploy 0.9.1、lmdeploy_turbomind 0.9.1 部署。

- **Repository**: mlx-community/MiniCPM-2B-sft-4bit-llama-format-mlx
- **Parameters**: 708.7M
- **Inference backends**: deploy_task text/emb, lmdeploy 0.9.1, lmdeploy_turbomind 0.9.1, sglang 0.5.2, vllm 0.9.2
- **Tags**: MiniCPM, ModelBest, THUNLP, mlx
- **Downloads**: 1002
- **Stars**: 0
- **Last updated**: 2024-12-19

Source: https://www.modelscope.cn/models/mlx-community/MiniCPM-2B-sft-4bit-llama-format-mlx

---

# mlx-community/MiniCPM-2B-sft-4bit-llama-format-mlx
This model was converted to MLX format from [`mlx-community/MiniCPM-2B-sft-bf16-llama-format-mlx`]() using mlx-lm version **0.8.0**.
Refer to the [original model card](https://huggingface.co/mlx-community/MiniCPM-2B-sft-bf16-llama-format-mlx) for more details on the model.
## Use with mlx

```bash
pip install mlx-lm
```

```python
from mlx_lm import load, generate

model, tokenizer = load("mlx-community/MiniCPM-2B-sft-4bit-llama-format-mlx")
response = generate(model, tokenizer, prompt="hello", verbose=True)
```
