Downloads · 30 days
20
10% of all-time downloads
MXLouis/Llama-Breeze2-3B-Instruct-Text-mlx-8Bit
Llama-Breeze2-3B-Instruct-Text-mlx-8Bit is a machine learning model from MXLouis. Use it for the machine learning task on the model card, and read the license before you ship it in a product. It is set up for mlx. The card lists the license as llama3.2.
The Model MXLouis/Llama-Breeze2-3B-Instruct-Text-mlx-8Bit was converted to MLX format from PenutChen/Llama-Breeze2-3B-Instruct-Text using mlx-lm version 0.26.4.
Downloads · 30 days
20
10% of all-time downloads
All-time downloads
196
Public
Parameters
3.6B
3.8 GB on disk
Likes
0
Public
Click a slice to open those files.
.safetensors3.8 GB · 100%
How the weights are stored.
U323.6B · 100%
From the Hugging Face model README
The Model MXLouis/Llama-Breeze2-3B-Instruct-Text-mlx-8Bit was converted to MLX format from PenutChen/Llama-Breeze2-3B-Instruct-Text using mlx-lm version 0.26.4.
pip install mlx-lm
Use the chat CLI and set a system prompt. If your model relies on custom tokenizer/chat template logic, also pass --trust-remote-code.
python -m mlx_lm chat \
--model MXLouis/Llama-Breeze2-3B-Instruct-Text-mlx-8Bit \
--trust-remote-code \
--system-prompt "You are a helpful AI assistant built by MediaTek Research. The user you are helping speaks Traditional Chinese and comes from Taiwan."
Then type your query at the >> prompt, for example:
>> 請用繁體中文簡短介紹 Swift Package Index。
Programmatically include the system prompt in the messages and apply the chat template.
from mlx_lm import load, generate
model, tokenizer = load("MXLouis/Llama-Breeze2-3B-Instruct-Text-mlx-8Bit")
SYSTEM_PROMPT = (
"You are a helpful AI assistant built by MediaTek Research. "
"The user you are helping speaks Traditional Chinese and comes from Taiwan."
)
user_prompt = "請用繁體中文簡短介紹 Swift Package Index。"
messages = [
{"role": "system", "content": SYSTEM_PROMPT},
{"role": "user", "content": user_prompt},
]
# If the tokenizer provides a chat template, apply it to build the prompt string.
if hasattr(tokenizer, "apply_chat_template") and tokenizer.chat_template is not None:
prompt = tokenizer.apply_chat_template(
messages, tokenize=False, add_generation_prompt=True
)
else:
# Fallback: simple concatenation if no chat template is available
prompt = f"System: {SYSTEM_PROMPT}\nUser: {user_prompt}\nAssistant:"
response = generate(model, tokenizer, prompt=prompt, verbose=True)
print(response)