Views
No views yet
[!TIP] KV-cache quantization without any fork (recommended, 2026): upstream llama.cpp/Ollama now cover this natively — use-ctk q8_0 -ctv q8_0(~half KV memory, negligible quality loss: perplexity +0.002–0.05) or-ctk q4_0 -ctv q4_0(~quarter memory, ≈7.6% perplexity increase). In Ollama:OLLAMA_KV_CACHE_TYPE=q8_0withOLLAMA_FLASH_ATTENTION=1. Keep K and V types symmetric to stay on the fast fused Flash-Attention path. Since April 2026, mainline llama.cpp also applies Hadamard rotation to KV activations (PR #21038), which greatly improves low-bit KV quality (opt-out:LLAMA_ATTN_ROT_DISABLE=1).The RotorQuant/TurboQuant fork flow below is experimental/legacy: the TurboQuant llama.cpp PR was closed without merging (June 2026) and the fork is unmaintained relative to mainline. It is NOT required to use this model.
| Property | Value |
|---|---|
| Base Model | Mistral Small 4 (March 2026) |
| Total Parameters | 119B |
| Active Parameters | 6.5B per token (Sparse MoE) |
| Architecture | Sparse MoE -- 128 experts, 4 active per token |
| Context Length | 256K tokens |
| Modality | Text + Images (multimodal) |
| Capabilities | Thinking / reasoning, tool use, multilingual |
| License | Apache 2.0 |
| Weight Quantization | 8-bit (MLX) |
| KV Cache Quantization | RotorQuant 3-bit |
| Configuration | Weights | KV Cache (256K) | Total |
|---|---|---|---|
| FP16 baseline | ~238 GB | ~32 GB | ~270 GB |
| This model (8-bit MLX + RotorQuant) | ~120 GB | ~6.5 GB | ~126.5 GB |
Note: This is a Sparse MoE model -- only 6.5B parameters are active per token, so inference is fast despite the 119B total parameter count.
1from mlx_lm import load, generate
2
3model, tokenizer = load("majentik/Mistral-Small-4-119B-RotorQuant-MLX-8bit")
4
5prompt = "Explain sparse mixture-of-experts architectures."
6messages = [{"role": "user", "content": prompt}]
7text = tokenizer.apply_chat_template(messages, tokenize=False, add_generation_prompt=True)
8
9response = generate(model, tokenizer, prompt=text, max_tokens=512)
10print(response)-ctk/-ctv q8_0, OLLAMA_KV_CACHE_TYPE).| Method | Prefill Speed | Decode Speed | Memory Savings | Reference |
|---|---|---|---|---|
| TurboQuant | Baseline | Baseline | High | arXiv: 2504.19874 |