Text Generation
GGUF
rotorquant
kv-cache-quantization
qwen
qwen3.5
llama-cpp
quantized
conversational
Instructions to use majentik/Qwen3.5-27B-RotorQuant-GGUF-IQ4_XS with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- llama.cpp
How to use majentik/Qwen3.5-27B-RotorQuant-GGUF-IQ4_XS with llama.cpp:
Install (macOS, Linux)
curl -LsSf https://llama.app/install.sh | sh # Start a local OpenAI-compatible server with a web UI: llama serve -hf majentik/Qwen3.5-27B-RotorQuant-GGUF-IQ4_XS:IQ4_XS # Run inference directly in the terminal: llama cli -hf majentik/Qwen3.5-27B-RotorQuant-GGUF-IQ4_XS:IQ4_XS
Install from WinGet (Windows)
winget install llama.cpp # Start a local OpenAI-compatible server with a web UI: llama serve -hf majentik/Qwen3.5-27B-RotorQuant-GGUF-IQ4_XS:IQ4_XS # Run inference directly in the terminal: llama cli -hf majentik/Qwen3.5-27B-RotorQuant-GGUF-IQ4_XS:IQ4_XS
Use pre-built binary
# Download pre-built binary from: # https://github.com/ggerganov/llama.cpp/releases # Start a local OpenAI-compatible server with a web UI: ./llama-server -hf majentik/Qwen3.5-27B-RotorQuant-GGUF-IQ4_XS:IQ4_XS # Run inference directly in the terminal: ./llama-cli -hf majentik/Qwen3.5-27B-RotorQuant-GGUF-IQ4_XS:IQ4_XS
Build from source code
git clone https://github.com/ggerganov/llama.cpp.git cd llama.cpp cmake -B build cmake --build build -j --target llama-server llama-cli # Start a local OpenAI-compatible server with a web UI: ./build/bin/llama-server -hf majentik/Qwen3.5-27B-RotorQuant-GGUF-IQ4_XS:IQ4_XS # Run inference directly in the terminal: ./build/bin/llama-cli -hf majentik/Qwen3.5-27B-RotorQuant-GGUF-IQ4_XS:IQ4_XS
Use Docker
docker model run hf.co/majentik/Qwen3.5-27B-RotorQuant-GGUF-IQ4_XS:IQ4_XS
- LM Studio
- Jan
- vLLM
How to use majentik/Qwen3.5-27B-RotorQuant-GGUF-IQ4_XS with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "majentik/Qwen3.5-27B-RotorQuant-GGUF-IQ4_XS" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "majentik/Qwen3.5-27B-RotorQuant-GGUF-IQ4_XS", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker
docker model run hf.co/majentik/Qwen3.5-27B-RotorQuant-GGUF-IQ4_XS:IQ4_XS
- Ollama
How to use majentik/Qwen3.5-27B-RotorQuant-GGUF-IQ4_XS with Ollama:
ollama run hf.co/majentik/Qwen3.5-27B-RotorQuant-GGUF-IQ4_XS:IQ4_XS
- Unsloth Desktop
- Pi
How to use majentik/Qwen3.5-27B-RotorQuant-GGUF-IQ4_XS with Pi:
Start the llama.cpp server
# Install llama.cpp: brew install llama.cpp # Start a local OpenAI-compatible server: llama serve -hf majentik/Qwen3.5-27B-RotorQuant-GGUF-IQ4_XS:IQ4_XS
Configure the model in Pi
# Install Pi: npm install -g @earendil-works/pi-coding-agent # Add to ~/.pi/agent/models.json: { "providers": { "llama-cpp": { "baseUrl": "http://localhost:8080/v1", "api": "openai-completions", "apiKey": "none", "models": [ { "id": "majentik/Qwen3.5-27B-RotorQuant-GGUF-IQ4_XS:IQ4_XS" } ] } } }Run Pi
# Start Pi in your project directory: pi
- Docker Model Runner
How to use majentik/Qwen3.5-27B-RotorQuant-GGUF-IQ4_XS with Docker Model Runner:
docker model run hf.co/majentik/Qwen3.5-27B-RotorQuant-GGUF-IQ4_XS:IQ4_XS
- Lemonade
How to use majentik/Qwen3.5-27B-RotorQuant-GGUF-IQ4_XS with Lemonade:
Pull the model
# Download Lemonade from https://lemonade-server.ai/ lemonade pull majentik/Qwen3.5-27B-RotorQuant-GGUF-IQ4_XS:IQ4_XS
Run and chat with the model
lemonade run user.Qwen3.5-27B-RotorQuant-GGUF-IQ4_XS-IQ4_XS
List all available models
lemonade list
- Hermes Agent
How to use majentik/Qwen3.5-27B-RotorQuant-GGUF-IQ4_XS with Hermes Agent:
Start the llama.cpp server
# Install llama.cpp: brew install llama.cpp # Start a local OpenAI-compatible server: llama serve -hf majentik/Qwen3.5-27B-RotorQuant-GGUF-IQ4_XS:IQ4_XS
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-GGUF-IQ4_XS:IQ4_XS
Run Hermes
hermes
- Atomic Chat
- OpenClaw
How to use majentik/Qwen3.5-27B-RotorQuant-GGUF-IQ4_XS with OpenClaw:
Start the llama.cpp server
# Install llama.cpp: brew install llama.cpp # Start a local OpenAI-compatible server: llama serve -hf majentik/Qwen3.5-27B-RotorQuant-GGUF-IQ4_XS:IQ4_XS
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-GGUF-IQ4_XS:IQ4_XS" \ --custom-provider-id llama-cpp \ --custom-compatibility openai \ --custom-text-input \ --accept-risk \ --skip-health
Run OpenClaw
openclaw agent --local --agent main --message "Hello from Hugging Face"
Update model card with accurate fork requirements and ecosystem status
Browse files
README.md
CHANGED
|
@@ -1,70 +1,150 @@
|
|
| 1 |
---
|
| 2 |
-
|
| 3 |
base_model: Qwen/Qwen3.5-27B
|
| 4 |
tags:
|
| 5 |
- gguf
|
| 6 |
- rotorquant
|
| 7 |
- kv-cache-quantization
|
| 8 |
- qwen
|
| 9 |
-
- qwen3
|
| 10 |
-
- moe
|
| 11 |
-
- thinking
|
| 12 |
- llama-cpp
|
| 13 |
- quantized
|
| 14 |
-
|
|
|
|
| 15 |
---
|
| 16 |
|
| 17 |
# Qwen3.5-27B-RotorQuant-GGUF-IQ4_XS
|
| 18 |
|
| 19 |
-
GGUF IQ4_XS weight-quantized variant of [Qwen/Qwen3.5-27B](https://huggingface.co/Qwen/Qwen3.5-27B) with **RotorQuant** KV cache compression
|
|
|
|
|
|
|
|
|
|
|
|
|
| 20 |
|
| 21 |
## Overview
|
| 22 |
|
| 23 |
-
This model combines two compression techniques:
|
| 24 |
-
|
| 25 |
-
|
|
|
|
|
|
|
|
|
|
| 26 |
|
| 27 |
## Quickstart
|
| 28 |
|
| 29 |
-
###
|
|
|
|
|
|
|
|
|
|
| 30 |
```bash
|
| 31 |
-
|
| 32 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 33 |
-p "Explain quantum computing"
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 34 |
```
|
| 35 |
|
| 36 |
-
### Ollama
|
|
|
|
|
|
|
|
|
|
|
|
|
| 37 |
```bash
|
| 38 |
-
|
|
|
|
|
|
|
|
|
|
| 39 |
```
|
| 40 |
|
| 41 |
-
|
| 42 |
-
Download the GGUF file and load in LM Studio.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 43 |
|
| 44 |
## Specifications
|
| 45 |
|
| 46 |
| Property | Value |
|
| 47 |
|----------|-------|
|
| 48 |
-
| Base Model | Qwen/Qwen3.5-27B |
|
| 49 |
-
|
|
| 50 |
-
|
|
| 51 |
-
|
|
| 52 |
-
|
|
| 53 |
-
|
|
| 54 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 55 |
|
| 56 |
## What is RotorQuant?
|
| 57 |
|
| 58 |
-
RotorQuant
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 59 |
|
| 60 |
-
|
|
| 61 |
-
|--------
|
| 62 |
-
|
|
| 63 |
-
|
|
| 64 |
-
|
|
| 65 |
|
| 66 |
## See Also
|
| 67 |
|
| 68 |
- [RotorQuant GitHub](https://github.com/scrya-com/rotorquant)
|
| 69 |
-
- [
|
| 70 |
-
- [
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
---
|
| 2 |
+
license: apache-2.0
|
| 3 |
base_model: Qwen/Qwen3.5-27B
|
| 4 |
tags:
|
| 5 |
- gguf
|
| 6 |
- rotorquant
|
| 7 |
- kv-cache-quantization
|
| 8 |
- qwen
|
| 9 |
+
- qwen3.5
|
|
|
|
|
|
|
| 10 |
- llama-cpp
|
| 11 |
- quantized
|
| 12 |
+
library_name: gguf
|
| 13 |
+
pipeline_tag: text-generation
|
| 14 |
---
|
| 15 |
|
| 16 |
# Qwen3.5-27B-RotorQuant-GGUF-IQ4_XS
|
| 17 |
|
| 18 |
+
GGUF IQ4_XS weight-quantized variant of [Qwen/Qwen3.5-27B](https://huggingface.co/Qwen/Qwen3.5-27B) optimised for use with **RotorQuant** KV cache compression via a dedicated llama.cpp fork.
|
| 19 |
+
|
| 20 |
+
> **Important:** RotorQuant KV cache types (`planar3`, `iso3`) are **not** available in upstream llama.cpp, standard Ollama, or LM Studio.
|
| 21 |
+
> They require a [specific llama.cpp fork](https://github.com/johndpope/llama-cpp-turboquant/tree/feature/planarquant-kv-cache).
|
| 22 |
+
> The GGUF file itself is a standard GGUF and works with any llama.cpp-compatible runtime using normal KV cache types (f16, q8_0, q4_0, etc.).
|
| 23 |
|
| 24 |
## Overview
|
| 25 |
|
| 26 |
+
This model combines two independent compression techniques:
|
| 27 |
+
|
| 28 |
+
| Technique | What it does | Requirement |
|
| 29 |
+
|-----------|-------------|-------------|
|
| 30 |
+
| **GGUF IQ4_XS weight quantization** | Reduces model size from ~56 GB (BF16) to ~14.0 GB | Any llama.cpp-compatible runtime |
|
| 31 |
+
| **RotorQuant KV cache compression** β block-diagonal Clifford-algebra rotors for 3-bit KV cache (`--cache-type-k iso3 --cache-type-v iso3`) | Block-diagonal rotations / random rotation for compressed KV cache | [llama-cpp-turboquant fork](https://github.com/johndpope/llama-cpp-turboquant/tree/feature/planarquant-kv-cache) only |
|
| 32 |
|
| 33 |
## Quickstart
|
| 34 |
|
| 35 |
+
### Option A β With RotorQuant KV cache (fork required)
|
| 36 |
+
|
| 37 |
+
You must build from the RotorQuant-enabled llama.cpp fork:
|
| 38 |
+
|
| 39 |
```bash
|
| 40 |
+
# Clone and build the fork
|
| 41 |
+
git clone https://github.com/johndpope/llama-cpp-turboquant.git
|
| 42 |
+
cd llama-cpp-turboquant && git checkout feature/planarquant-kv-cache
|
| 43 |
+
|
| 44 |
+
# CUDA (Windows/Linux)
|
| 45 |
+
cmake -B build -DGGML_CUDA=ON -DCMAKE_BUILD_TYPE=Release && cmake --build build -j
|
| 46 |
+
|
| 47 |
+
# Metal (Apple Silicon)
|
| 48 |
+
cmake -B build -DGGML_METAL=ON -DGGML_METAL_EMBED_LIBRARY=ON -DCMAKE_BUILD_TYPE=Release && cmake --build build -j
|
| 49 |
+
|
| 50 |
+
# Run with RotorQuant KV cache
|
| 51 |
+
./build/bin/llama-cli -m Qwen3.5-27B-RotorQuant-GGUF-IQ4_XS.gguf \
|
| 52 |
+
--cache-type-k iso3 --cache-type-v iso3 \
|
| 53 |
+
-ngl 99 -fa \
|
| 54 |
-p "Explain quantum computing"
|
| 55 |
+
|
| 56 |
+
# Or run as a server
|
| 57 |
+
./build/bin/llama-server -m Qwen3.5-27B-RotorQuant-GGUF-IQ4_XS.gguf \
|
| 58 |
+
--cache-type-k iso3 --cache-type-v iso3 \
|
| 59 |
+
-ngl 99 -fa --jinja
|
| 60 |
```
|
| 61 |
|
| 62 |
+
### Option B β With standard llama.cpp / LM Studio / Ollama
|
| 63 |
+
|
| 64 |
+
The GGUF works as a normal quantised model. You won't get RotorQuant-specific KV cache benefits, but standard KV cache quantization (q8_0, q4_0) still reduces VRAM significantly.
|
| 65 |
+
|
| 66 |
+
**llama.cpp (upstream)**
|
| 67 |
```bash
|
| 68 |
+
llama-cli -m Qwen3.5-27B-RotorQuant-GGUF-IQ4_XS.gguf \
|
| 69 |
+
--cache-type-k q8_0 --cache-type-v q8_0 \
|
| 70 |
+
-ngl 99 -fa \
|
| 71 |
+
-p "Explain quantum computing"
|
| 72 |
```
|
| 73 |
|
| 74 |
+
**LM Studio**
|
| 75 |
+
1. Download the GGUF file and load in LM Studio.
|
| 76 |
+
2. Enable **Developer Mode** (Settings β Developer).
|
| 77 |
+
3. In the model loader's advanced settings, set **Flash Attention** to ON.
|
| 78 |
+
4. Set **K Cache Quantization** and **V Cache Quantization** to `q8_0` (or `q4_0` for more aggressive VRAM savings).
|
| 79 |
+
5. Note: LM Studio does not currently support RotorQuant's `iso3` cache types. Track [this feature request](https://github.com/lmstudio-ai/lmstudio-bug-tracker/issues/1719) for updates.
|
| 80 |
+
|
| 81 |
+
**Ollama**
|
| 82 |
+
```bash
|
| 83 |
+
# Standard Ollama does not support RotorQuant cache types.
|
| 84 |
+
# Use with default or q8_0 KV cache via OLLAMA_KV_CACHE_TYPE=q8_0
|
| 85 |
+
OLLAMA_KV_CACHE_TYPE=q8_0 OLLAMA_FLASH_ATTENTION=1 ollama run majentik/Qwen3.5-27B-RotorQuant-GGUF-IQ4_XS
|
| 86 |
+
```
|
| 87 |
|
| 88 |
## Specifications
|
| 89 |
|
| 90 |
| Property | Value |
|
| 91 |
|----------|-------|
|
| 92 |
+
| Base Model | [Qwen/Qwen3.5-27B](https://huggingface.co/Qwen/Qwen3.5-27B) |
|
| 93 |
+
| Architecture | Dense (Gated DeltaNet + Gated Attention hybrid, 3:1 ratio) |
|
| 94 |
+
| Parameters | 27.8B (all active β not MoE) |
|
| 95 |
+
| Context Length | 262K native (extensible to 1M) |
|
| 96 |
+
| Weight Quantization | GGUF IQ4_XS (importance-weighted 4-bit, smallest 4-bit) |
|
| 97 |
+
| Original Size (BF16) | ~56 GB |
|
| 98 |
+
| Quantized File Size | ~14.0 GB |
|
| 99 |
+
| KV Cache (RotorQuant) | 3-bit via `--cache-type-k iso3 --cache-type-v iso3` (fork only) |
|
| 100 |
+
| KV Cache (standard) | q8_0, q4_0, f16, etc. (any llama.cpp runtime) |
|
| 101 |
+
| License | apache-2.0 |
|
| 102 |
+
| Modalities | Text + Image + Video (native early-fusion) |
|
| 103 |
+
| Compatible Runtimes | llama.cpp, LM Studio, Ollama, koboldcpp |
|
| 104 |
|
| 105 |
## What is RotorQuant?
|
| 106 |
|
| 107 |
+
[RotorQuant](https://github.com/scrya-com/rotorquant) is a KV cache compression method based on Clifford algebra (Cl(3,0)) rotors. It was developed as a faster, more parameter-efficient alternative to Google's [TurboQuant](https://arxiv.org/abs/2504.19874) (ICLR 2026).
|
| 108 |
+
|
| 109 |
+
Instead of applying a dense dΓd random orthogonal rotation matrix (as TurboQuant does), RotorQuant uses lightweight block-diagonal rotations β independent 2D/4D rotations per pair/quartet β achieving O(d) complexity instead of O(d log d), fully parallelisable with no inter-element dependencies.
|
| 110 |
+
|
| 111 |
+
**Benchmarks from the RotorQuant repository** (Llama 3.1 8B, RTX 5090 β results will vary by model and hardware):
|
| 112 |
+
|
| 113 |
+
| Metric | RotorQuant (iso3) | TurboQuant | Standard q4_0 |
|
| 114 |
+
|--------|-------------------|------------|---------------|
|
| 115 |
+
| Prefill Speed | 3,822 tok/s | 722 tok/s | β |
|
| 116 |
+
| Decode Speed | 119 tok/s | 93 tok/s | β |
|
| 117 |
+
| Perplexity (PPL) | 6.91 | 7.07 | β |
|
| 118 |
+
| KV Compression | ~5Γ vs FP16 | ~5Γ vs FP16 | ~4Γ vs FP16 |
|
| 119 |
+
| Rotation Parameters | 4 per rotor | 16,384 per matrix | N/A |
|
| 120 |
+
|
| 121 |
+
> **Note:** These benchmarks are from the RotorQuant repository using Llama 3.1 8B on an RTX 5090. Performance on Qwen3.5-27B will differ. Independent benchmarks for this specific model are welcome β please open a discussion if you have results to share.
|
| 122 |
+
|
| 123 |
+
## Current Status of RotorQuant in the Ecosystem
|
| 124 |
+
|
| 125 |
+
| Runtime | RotorQuant Support | Standard KV Quant |
|
| 126 |
+
|---------|---------------------|-------------------|
|
| 127 |
+
| llama.cpp (upstream) | β Not merged | β
q8_0, q4_0, q4_1, iq4_nl, q5_0, q5_1 |
|
| 128 |
+
| llama-cpp-turboquant fork | β
planar3, iso3 | β
All standard types |
|
| 129 |
+
| LM Studio | β [Requested](https://github.com/lmstudio-ai/lmstudio-bug-tracker/issues/1719) | β
Via advanced settings |
|
| 130 |
+
| Ollama | β Not supported | β
Via OLLAMA_KV_CACHE_TYPE |
|
| 131 |
+
| koboldcpp | β Not supported | β
Standard types |
|
| 132 |
+
|
| 133 |
+
## Recommended Settings
|
| 134 |
+
|
| 135 |
+
For VRAM-constrained setups, standard q8_0 KV cache quantization already halves KV cache memory with negligible quality impact. Flash Attention should always be enabled β it is required for V cache quantization and improves memory efficiency regardless.
|
| 136 |
|
| 137 |
+
| VRAM | Suggested Configuration |
|
| 138 |
+
|------|------------------------|
|
| 139 |
+
| 24 GB (RTX 4090) | IQ4_XS + q8_0 KV cache + Flash Attention, 8Kβ16K context |
|
| 140 |
+
| 16 GB | IQ4_XS + q4_0 KV cache + Flash Attention, 4Kβ8K context |
|
| 141 |
+
| 48+ GB | IQ4_XS + f16 KV cache, full 32K+ context |
|
| 142 |
|
| 143 |
## See Also
|
| 144 |
|
| 145 |
- [RotorQuant GitHub](https://github.com/scrya-com/rotorquant)
|
| 146 |
+
- [llama-cpp-turboquant fork](https://github.com/johndpope/llama-cpp-turboquant/tree/feature/planarquant-kv-cache)
|
| 147 |
+
- [TurboQuant llama.cpp discussion](https://github.com/ggml-org/llama.cpp/discussions/20969)
|
| 148 |
+
- [TurboQuant paper (arXiv: 2504.19874)](https://arxiv.org/abs/2504.19874)
|
| 149 |
+
- [Base model: Qwen/Qwen3.5-27B](https://huggingface.co/Qwen/Qwen3.5-27B)
|
| 150 |
+
- [Qwen3.5-27B announcement](https://qwen.ai/blog?id=qwen3.5)
|