The Model
mrtoots/unsloth-Magistral-Small-2509-mlx-8Bit was converted to MLX format from
unsloth/Magistral-Small-2509 using mlx-lm version
0.26.4.
This model was converted and quantized utilizing unsloth's version of Mistral's magistral-small-2509.
Please follow and support
mistral's work and support
unsloth's work if you like it!
1from mlx_lm import load, generate
2
3model, tokenizer = load("mrtoots/Magistral-Small-2509-mlx-8Bit")
4
5prompt="hello"
6
7if hasattr(tokenizer, "apply_chat_template") and tokenizer.chat_template is not None:
8 messages = [{"role": "user", "content": prompt}]
9 prompt = tokenizer.apply_chat_template(
10 messages, tokenize=False, add_generation_prompt=True
11 )
12
13response = generate(model, tokenizer, prompt=prompt, verbose=True)