Instructions to use majentik/Qwen3.5-27B-RotorQuant-MLX-8bit with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- MLX
How to use majentik/Qwen3.5-27B-RotorQuant-MLX-8bit with MLX:
# Make sure mlx-lm is installed # pip install --upgrade mlx-lm # Generate text with mlx-lm from mlx_lm import load, generate model, tokenizer = load("majentik/Qwen3.5-27B-RotorQuant-MLX-8bit") prompt = "Write a story about Einstein" messages = [{"role": "user", "content": prompt}] prompt = tokenizer.apply_chat_template( messages, add_generation_prompt=True ) text = generate(model, tokenizer, prompt=prompt, verbose=True) - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- LM Studio
- Pi
How to use majentik/Qwen3.5-27B-RotorQuant-MLX-8bit with Pi:
Start the MLX server
# Install MLX LM: uv tool install mlx-lm # Start a local OpenAI-compatible server: mlx_lm.server --model "majentik/Qwen3.5-27B-RotorQuant-MLX-8bit"
Configure the model in Pi
# Install Pi: npm install -g @mariozechner/pi-coding-agent # Add to ~/.pi/agent/models.json: { "providers": { "mlx-lm": { "baseUrl": "http://localhost:8080/v1", "api": "openai-completions", "apiKey": "none", "models": [ { "id": "majentik/Qwen3.5-27B-RotorQuant-MLX-8bit" } ] } } }Run Pi
# Start Pi in your project directory: pi
- Hermes Agent new
How to use majentik/Qwen3.5-27B-RotorQuant-MLX-8bit with Hermes Agent:
Start the MLX server
# Install MLX LM: uv tool install mlx-lm # Start a local OpenAI-compatible server: mlx_lm.server --model "majentik/Qwen3.5-27B-RotorQuant-MLX-8bit"
Configure Hermes
# Install Hermes: curl -fsSL https://hermes-agent.nousresearch.com/install.sh | bash hermes setup # Point Hermes at the local server: hermes config set model.provider custom hermes config set model.base_url http://127.0.0.1:8080/v1 hermes config set model.default majentik/Qwen3.5-27B-RotorQuant-MLX-8bit
Run Hermes
hermes
- OpenClaw new
How to use majentik/Qwen3.5-27B-RotorQuant-MLX-8bit with OpenClaw:
Start the MLX server
# Install MLX LM: uv tool install mlx-lm # Start a local OpenAI-compatible server: mlx_lm.server --model "majentik/Qwen3.5-27B-RotorQuant-MLX-8bit"
Configure OpenClaw
# Install OpenClaw: npm install -g openclaw@latest # Register the local server and set it as the default model: openclaw onboard --non-interactive --mode local \ --auth-choice custom-api-key \ --custom-base-url http://127.0.0.1:8080/v1 \ --custom-model-id "majentik/Qwen3.5-27B-RotorQuant-MLX-8bit" \ --custom-provider-id mlx-lm \ --custom-compatibility openai \ --custom-text-input \ --accept-risk \ --skip-health
Run OpenClaw
openclaw agent --local --agent main --message "Hello from Hugging Face"
- MLX LM
How to use majentik/Qwen3.5-27B-RotorQuant-MLX-8bit with MLX LM:
Generate or start a chat session
# Install MLX LM uv tool install mlx-lm # Interactive chat REPL mlx_lm.chat --model "majentik/Qwen3.5-27B-RotorQuant-MLX-8bit"
Run an OpenAI-compatible server
# Install MLX LM uv tool install mlx-lm # Start the server mlx_lm.server --model "majentik/Qwen3.5-27B-RotorQuant-MLX-8bit" # Calling the OpenAI-compatible server with curl curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "majentik/Qwen3.5-27B-RotorQuant-MLX-8bit", "messages": [ {"role": "user", "content": "Hello"} ] }'
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) orquarter memory, ≈7.6% perplexity increase). In Ollama:-ctk q4_0 -ctv q4_0(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.
Qwen3.5-27B-RotorQuant-MLX-8bit
MLX 8-bit weight-quantized variant of Qwen/Qwen3.5-27B with RotorQuant KV cache compression for efficient inference on Apple Silicon.
Overview
This model combines two complementary compression techniques:
- MLX 8-bit weight quantization — reduces model size from ~54GB to ~27GB
- RotorQuant KV cache compression — compresses key-value caches during inference using Clifford algebra block-diagonal rotations, enabling longer contexts with less VRAM
Quickstart
from mlx_lm import load, generate
from turboquant import IsoQuantCache
model, tokenizer = load("majentik/Qwen3.5-27B-RotorQuant-MLX-8bit")
# Standard generation
prompt = "Explain the theory of relativity"
response = generate(model, tokenizer, prompt=prompt, max_tokens=2048)
print(response)
Specifications
| Property | Value |
|---|---|
| Base Model | Qwen/Qwen3.5-27B |
| Parameters | 27B |
| Weight Quantization | MLX 8-bit affine |
| KV Cache Method | RotorQuant (Clifford algebra block-diagonal rotations) |
| Model Size | ~27 GB |
| Context Length | 262K (native), 1M+ (extended) |
| Platform | Apple Silicon (M1/M2/M3/M4/M5) |
What is RotorQuant?
RotorQuant uses Clifford algebra block-diagonal rotations for KV cache quantization, achieving superior efficiency compared to vector-quantization-based approaches like TurboQuant:
| Metric | RotorQuant | TurboQuant |
|---|---|---|
| Prefill speed | 5.3x faster | baseline |
| Decode speed | 28% faster | baseline |
| Quantizer parameters | 44x fewer | baseline |
| Perplexity | 6.91 | 7.07 |
RotorQuant compresses the KV cache to ~3-bit effective precision while maintaining lower perplexity than TurboQuant's 4-bit approach, thanks to the mathematical efficiency of geometric algebra rotations.
Thinking Mode
Qwen3.5-27B generates extended reasoning before responses by default. The combination of weight quantization and KV cache compression is especially valuable here — thinking tokens consume significant memory that is reduced by both techniques working together.
Memory Estimate
| Configuration | Model Weights | KV Cache (128K ctx) | Total |
|---|---|---|---|
| FP16 (baseline) | ~54 GB | ~13 GB | ~67 GB |
| MLX 8-bit + RotorQuant | ~27 GB | ~1.3 GB | ~28.3 GB |
See Also
Quant trade-off (MLX lane)
| Bits | Approx size | Use case | Recommendation |
|---|---|---|---|
| 2-bit | ~7.3 GB | Aggressive quantization | Very low-RAM Macs |
| 3-bit | ~10 GB | Lossy but small | Low-RAM Macs |
| 4-bit | ~12 GB | Balanced default | Recommended for most Macs |
| 5-bit | ~14 GB | Higher fidelity | Quality-sensitive |
| 6-bit | ~17 GB | Approaching FP16 quality | High-fidelity |
| 8-bit | ~21 GB | Near-lossless reference | Fidelity-critical work |
(Current variant — 8bit — is bolded.)
Variants in this family
(Showing 16 sibling variants under majentik/qwen3.5-27b-*. The current variant — RotorQuant-MLX-8bit — is bolded.)
| Variant | Runtime | Approx size | Use case |
|---|---|---|---|
| RotorQuant | runtime modifier | n/a | KV-cache root (weight-agnostic) |
| RotorQuant-2bit | transformers | n/a | Standalone 2-bit weights |
| RotorQuant-GGUF-IQ4_XS | llama.cpp | ~23 GB | Lossy 4-bit, low-RAM CPU/edge |
| RotorQuant-GGUF-Q2_K | llama.cpp | ~16 GB | Lossy, low-RAM CPU/edge |
| RotorQuant-GGUF-Q3_K_M | llama.cpp | ~21 GB | Smaller 3-bit, CPU-friendly |
| RotorQuant-GGUF-Q4_K_M | llama.cpp | ~30 GB | Balanced default |
| RotorQuant-GGUF-Q5_K_M | llama.cpp | ~36 GB | Higher fidelity, more RAM |
| RotorQuant-GGUF-Q8_0 | llama.cpp | ~57 GB | Near-lossless reference |
| RotorQuant-MLX-2bit | mlx-lm | ~8.6 GB | Apple Silicon, smallest |
| RotorQuant-MLX-4bit | mlx-lm | ~17 GB | Apple Silicon balanced |
| RotorQuant-MLX-8bit | mlx-lm | ~32 GB | Apple Silicon reference |
| TurboQuant | runtime modifier | n/a | KV-cache root (weight-agnostic) |
| TurboQuant-2bit | transformers | n/a | Standalone 2-bit weights |
| TurboQuant-MLX-2bit | mlx-lm | ~8.6 GB | Apple Silicon, smallest |
| TurboQuant-MLX-4bit | mlx-lm | ~17 GB | Apple Silicon balanced |
| TurboQuant-MLX-8bit | mlx-lm | ~32 GB | Apple Silicon reference |
- Downloads last month
- 63
8-bit
Model tree for majentik/Qwen3.5-27B-RotorQuant-MLX-8bit
Base model
Qwen/Qwen3.5-27B