xddd-mlx-2Bit / README.md
Kfjjdjdjdhdhd's picture
Upload README.md with huggingface_hub
6134325 verified
---
library_name: transformers
tags:
- mlx
- mlx-my-repo
base_model: hghghgkskdmskdms/xddd
---
# Kfjjdjdjdhdhd/xddd-mlx-2Bit
The Model [Kfjjdjdjdhdhd/xddd-mlx-2Bit](https://huggingface.co/Kfjjdjdjdhdhd/xddd-mlx-2Bit) was converted to MLX format from [hghghgkskdmskdms/xddd](https://huggingface.co/hghghgkskdmskdms/xddd) using mlx-lm version **0.22.0**.
## Use with mlx
```bash
pip install mlx-lm
```
```python
from mlx_lm import load, generate
model, tokenizer = load("Kfjjdjdjdhdhd/xddd-mlx-2Bit")
prompt = "hello"
if hasattr(tokenizer, "apply_chat_template") and tokenizer.chat_template is not None:
messages = [{"role": "user", "content": prompt}]
prompt = tokenizer.apply_chat_template(
messages, tokenize=False, add_generation_prompt=True
)
response = generate(model, tokenizer, prompt=prompt, verbose=True)
```