Loading…
Loading…
MLX 4-bit quantization of XHToken/Spark-X2.6-4B, an on-device hybrid-attention language model (4B parameters) engineered for high-efficiency agent execution. Native context: 1,048,576 tokens (1M).
Benchmark results reported by XHToken for Spark-X2.6-4B in thinking mode.
| Quantization | Repository | Size |
|---|---|---|
| 8-bit | Spark-X2.6-4B-MLX-8bit | 4.37 GB |
| 6-bit | Spark-X2.6-4B-MLX-6bit | 3.34 GB |
| 4-bit | Spark-X2.6-4B-MLX-4bit | 2.32 GB |
Includes upstream chat_template.jinja. Checksums: SHA256SUMS.txt.
# Install MLX-LM
pip install mlx-lm
# Text generation
python -m mlx_lm generate \
--model abenzerps/Spark-X2.6-4B-MLX-4bit \
--prompt "Hello! Introduce yourself in one sentence." \
--max-tokens 512
from mlx_lm import load, generate
model_id = "abenzerps/Spark-X2.6-4B-MLX-4bit"
model, tokenizer = load(model_id)
response = generate(
model,
tokenizer,
prompt="Hello! Introduce yourself in one sentence.",
max_tokens=512,
verbose=True,
)
print(response)
XHToken/Spark-X2.6-4B