Text Generation
GGUF
Mixture of Experts
pruning
quantization
hash-embedding
llama.cpp
imatrix
conversational
Instructions to use Cyronius/Qwen3.8-Flash-Next-131B-A6B-GGUF 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 Cyronius/Qwen3.8-Flash-Next-131B-A6B-GGUF 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 Cyronius/Qwen3.8-Flash-Next-131B-A6B-GGUF:Q4_0 # Run inference directly in the terminal: llama cli -hf Cyronius/Qwen3.8-Flash-Next-131B-A6B-GGUF:Q4_0
Install from WinGet (Windows)
winget install llama.cpp # Start a local OpenAI-compatible server with a web UI: llama serve -hf Cyronius/Qwen3.8-Flash-Next-131B-A6B-GGUF:Q4_0 # Run inference directly in the terminal: llama cli -hf Cyronius/Qwen3.8-Flash-Next-131B-A6B-GGUF:Q4_0
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 Cyronius/Qwen3.8-Flash-Next-131B-A6B-GGUF:Q4_0 # Run inference directly in the terminal: ./llama-cli -hf Cyronius/Qwen3.8-Flash-Next-131B-A6B-GGUF:Q4_0
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 Cyronius/Qwen3.8-Flash-Next-131B-A6B-GGUF:Q4_0 # Run inference directly in the terminal: ./build/bin/llama-cli -hf Cyronius/Qwen3.8-Flash-Next-131B-A6B-GGUF:Q4_0
Use Docker
docker model run hf.co/Cyronius/Qwen3.8-Flash-Next-131B-A6B-GGUF:Q4_0
- LM Studio
- Jan
- vLLM
How to use Cyronius/Qwen3.8-Flash-Next-131B-A6B-GGUF with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "Cyronius/Qwen3.8-Flash-Next-131B-A6B-GGUF" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "Cyronius/Qwen3.8-Flash-Next-131B-A6B-GGUF", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker
docker model run hf.co/Cyronius/Qwen3.8-Flash-Next-131B-A6B-GGUF:Q4_0
- Ollama
How to use Cyronius/Qwen3.8-Flash-Next-131B-A6B-GGUF with Ollama:
ollama run hf.co/Cyronius/Qwen3.8-Flash-Next-131B-A6B-GGUF:Q4_0
- Unsloth Desktop
- Pi
How to use Cyronius/Qwen3.8-Flash-Next-131B-A6B-GGUF with Pi:
Start the llama.cpp server
# Install llama.cpp: brew install llama.cpp # Start a local OpenAI-compatible server: llama serve -hf Cyronius/Qwen3.8-Flash-Next-131B-A6B-GGUF:Q4_0
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": "Cyronius/Qwen3.8-Flash-Next-131B-A6B-GGUF:Q4_0" } ] } } }Run Pi
# Start Pi in your project directory: pi
- Docker Model Runner
How to use Cyronius/Qwen3.8-Flash-Next-131B-A6B-GGUF with Docker Model Runner:
docker model run hf.co/Cyronius/Qwen3.8-Flash-Next-131B-A6B-GGUF:Q4_0
- Lemonade
How to use Cyronius/Qwen3.8-Flash-Next-131B-A6B-GGUF with Lemonade:
Pull the model
# Download Lemonade from https://lemonade-server.ai/ lemonade pull Cyronius/Qwen3.8-Flash-Next-131B-A6B-GGUF:Q4_0
Run and chat with the model
lemonade run user.Qwen3.8-Flash-Next-131B-A6B-GGUF-Q4_0
List all available models
lemonade list
- Hermes Agent
How to use Cyronius/Qwen3.8-Flash-Next-131B-A6B-GGUF with Hermes Agent:
Start the llama.cpp server
# Install llama.cpp: brew install llama.cpp # Start a local OpenAI-compatible server: llama serve -hf Cyronius/Qwen3.8-Flash-Next-131B-A6B-GGUF:Q4_0
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 Cyronius/Qwen3.8-Flash-Next-131B-A6B-GGUF:Q4_0
Run Hermes
hermes
- Atomic Chat
- OpenClaw
How to use Cyronius/Qwen3.8-Flash-Next-131B-A6B-GGUF with OpenClaw:
Start the llama.cpp server
# Install llama.cpp: brew install llama.cpp # Start a local OpenAI-compatible server: llama serve -hf Cyronius/Qwen3.8-Flash-Next-131B-A6B-GGUF:Q4_0
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 "Cyronius/Qwen3.8-Flash-Next-131B-A6B-GGUF:Q4_0" \ --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"
Document Q4_0 build: files table, hardware guidance, unbenchmarked caveat, bartowski credit
Browse files
README.md
CHANGED
|
@@ -15,7 +15,7 @@ pipeline_tag: text-generation
|
|
| 15 |
|
| 16 |
# Qwen3.8-Flash-Next-131B-A6B (n-gram table pruned, GGUF)
|
| 17 |
|
| 18 |
-
A 64.8 GB GGUF of [Qwen/Qwen3.8-Flash-Next](https://huggingface.co/Qwen/Qwen3.8-Flash-Next) that scores at parity with the full 90 GB quant on tool-calling, GSM8K, and MMLU β 28% smaller, with **zero training and zero transformer surgery**.
|
| 19 |
|
| 20 |
Qwen3.8-Flash-Next carries a 51B-parameter n-gram hash-embedding table (~29% of total weights): 16 independent hash heads, 8 per n-gram type (bigrams / trigrams), injected at layer 1. This model keeps **1 head of 8 per n-gram type** and drops the other 14, exploiting the built-in redundancy of multi-head hashing (each n-gram is looked up several independent ways; a Bloom-filter-style safety margin). Every other tensor is copied **byte-for-byte** from [unsloth's UD-Q3_K_XL dynamic quant](https://huggingface.co/unsloth/Qwen3.8-Flash-Next-GGUF), so unsloth's imatrix calibration is preserved exactly.
|
| 21 |
|
|
@@ -27,6 +27,19 @@ Qwen3.8-Flash-Next carries a 51B-parameter n-gram hash-embedding table (~29% of
|
|
| 27 |
| layers / experts | 48 / 512 | 48 / 512 (untouched) |
|
| 28 |
| UD-Q3_K_XL GGUF size | 90 GB | **64.8 GB** |
|
| 29 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 30 |
## Benchmarks
|
| 31 |
|
| 32 |
All rows measured on the same llama.cpp build (b10673, CUDA, A100), temp 0, same day. Tool-calling: 40 agentic cases scored on calling the right tool with the right arguments or correctly declining (schemas disjoint from anything the surgery could see β there is no training step). GSM8K-15 / MMLU-30 subsets, no-think mode. Perplexity: wikitext-2 test, 32Γ512-token chunks.
|
|
@@ -46,16 +59,19 @@ For calibration: both cheaper cuts were also tested and rejected. Removing trans
|
|
| 46 |
Needs llama.cpp from **2026-08-27 or newer** (`qwen4exp` support; b10673 tested). Vendor-recommended sampling: instruct `temp 0.7, top_p 0.8, presence_penalty 1.5`; thinking `temp 1.0, top_p 0.95`.
|
| 47 |
|
| 48 |
```
|
| 49 |
-
# ~66 GB+ VRAM
|
| 50 |
llama-server -m qwen38-keep1-Q3KXL.gguf -ngl 99 -c 8192
|
| 51 |
|
| 52 |
# smaller GPUs: keep the (sparse-gather) n-gram table in system RAM
|
| 53 |
llama-server -m qwen38-keep1-Q3KXL.gguf -ngl 99 -c 8192 \
|
| 54 |
--override-tensor "per_layer_token_embd\.weight=CPU"
|
| 55 |
|
| 56 |
-
# CPU-only boxes
|
|
|
|
| 57 |
```
|
| 58 |
|
|
|
|
|
|
|
| 59 |
Text-only GGUF (vision tensors ship separately as unsloth's mmproj; the vision path is untested with this surgery). MTP speculative decoding is not available β upstream llama.cpp does not export or run the MTP head for this architecture yet.
|
| 60 |
|
| 61 |
## Limitations
|
|
@@ -63,13 +79,16 @@ Text-only GGUF (vision tensors ship separately as unsloth's mmproj; the vision p
|
|
| 63 |
- Wikitext perplexity 4.66 vs 2.40 for the base: prose is measurably less "polished-autocomplete" even though task performance holds. If your workload is verbatim-recall-heavy (quotes, boilerplate reproduction), the missing table may show up.
|
| 64 |
- Evaluated on a small in-house benchmark (40 tool cases, GSM8K-15, MMLU-30) at β€8K context. Long-context behavior (QSA sparse attention, 256K native) untested.
|
| 65 |
- The kept heads were chosen positionally (first of each 8), not by importance ranking. A calibrated head choice might do slightly better; nobody has measured.
|
|
|
|
| 66 |
|
| 67 |
## How this model was made
|
| 68 |
|
| 69 |
Full write-up, surgery script, and raw result logs: [github.com/Cyronius/qwen-prune-heal-pipeline](https://github.com/Cyronius/qwen-prune-heal-pipeline) (`surgery_qwen38.py`).
|
| 70 |
|
| 71 |
-
Short version: the GGUF's per-head hash-table layout is entirely metadata-driven (`ple.head_offsets`, `ple.head_vocab_sizes`), and llama.cpp reads the table's row count back from the tensor itself. Dropped heads get `vocab_size = 1` pointing at a shared all-zero row
|
|
|
|
|
|
|
| 72 |
|
| 73 |
## License
|
| 74 |
|
| 75 |
-
qwen-community-1.0, inherited from [Qwen/Qwen3.8-Flash-Next](https://huggingface.co/Qwen/Qwen3.8-Flash-Next). Quantized weights derived from [unsloth/Qwen3.8-Flash-Next-GGUF](https://huggingface.co/unsloth/Qwen3.8-Flash-Next-GGUF) β thanks to
|
|
|
|
| 15 |
|
| 16 |
# Qwen3.8-Flash-Next-131B-A6B (n-gram table pruned, GGUF)
|
| 17 |
|
| 18 |
+
A 64.8 GB GGUF of [Qwen/Qwen3.8-Flash-Next](https://huggingface.co/Qwen/Qwen3.8-Flash-Next) that scores at parity with the full 90 GB quant on tool-calling, GSM8K, and MMLU β 28% smaller, with **zero training and zero transformer surgery**. A 75.4 GB Q4_0 variant of the same cut is also available for older GPUs; see [Files](#files).
|
| 19 |
|
| 20 |
Qwen3.8-Flash-Next carries a 51B-parameter n-gram hash-embedding table (~29% of total weights): 16 independent hash heads, 8 per n-gram type (bigrams / trigrams), injected at layer 1. This model keeps **1 head of 8 per n-gram type** and drops the other 14, exploiting the built-in redundancy of multi-head hashing (each n-gram is looked up several independent ways; a Bloom-filter-style safety margin). Every other tensor is copied **byte-for-byte** from [unsloth's UD-Q3_K_XL dynamic quant](https://huggingface.co/unsloth/Qwen3.8-Flash-Next-GGUF), so unsloth's imatrix calibration is preserved exactly.
|
| 21 |
|
|
|
|
| 27 |
| layers / experts | 48 / 512 | 48 / 512 (untouched) |
|
| 28 |
| UD-Q3_K_XL GGUF size | 90 GB | **64.8 GB** |
|
| 29 |
|
| 30 |
+
## Files
|
| 31 |
+
|
| 32 |
+
Same surgery, two different base quants. Pick by hardware, not by size.
|
| 33 |
+
|
| 34 |
+
| file | size | inherits | for |
|
| 35 |
+
|---|---:|---|---|
|
| 36 |
+
| `qwen38-keep1-Q3KXL.gguf` | 64.8 GB | [unsloth UD-Q3_K_XL](https://huggingface.co/unsloth/Qwen3.8-Flash-Next-GGUF) | the default β smallest, and the build all the benchmarks below were measured on |
|
| 37 |
+
| `qwen38-keep1-Q4_0.gguf` | 75.4 GB | [bartowski Q4_0](https://huggingface.co/bartowski/Qwen3.8-Flash-Next-GGUF) | older GPUs where Q4_0 is much faster than K-/IQ-quants β AMD gfx906 (MI50/MI60), NVIDIA Pascal (P40/P100) |
|
| 38 |
+
|
| 39 |
+
The Q4_0 build is **bigger**, not smaller. The n-gram table is what makes this model compact; Q4_0 simply stores every other tensor at more bits than Q3_K_XL does. You are buying throughput with VRAM. On gfx906 that trade is usually worth it β Q4_0 reaches llama.cpp's MMVQ path while K-quants and IQ4_NL fall through to a generic dequant path several times slower.
|
| 40 |
+
|
| 41 |
+
**The Q4_0 build has not been separately benchmarked**, and no one has yet reported running it. The surgery is byte-verbatim and structurally verified (dropped heads point at a shared all-zero row that decodes to exact zeros in Q4_0, kept heads are byte-identical to the source), but the numbers below come from the Q3_K_XL build and do not transfer. If you run it, please report back in the discussions.
|
| 42 |
+
|
| 43 |
## Benchmarks
|
| 44 |
|
| 45 |
All rows measured on the same llama.cpp build (b10673, CUDA, A100), temp 0, same day. Tool-calling: 40 agentic cases scored on calling the right tool with the right arguments or correctly declining (schemas disjoint from anything the surgery could see β there is no training step). GSM8K-15 / MMLU-30 subsets, no-think mode. Perplexity: wikitext-2 test, 32Γ512-token chunks.
|
|
|
|
| 59 |
Needs llama.cpp from **2026-08-27 or newer** (`qwen4exp` support; b10673 tested). Vendor-recommended sampling: instruct `temp 0.7, top_p 0.8, presence_penalty 1.5`; thinking `temp 1.0, top_p 0.95`.
|
| 60 |
|
| 61 |
```
|
| 62 |
+
# fully offloaded (~66 GB+ VRAM for Q3_K_XL, ~77 GB+ for Q4_0)
|
| 63 |
llama-server -m qwen38-keep1-Q3KXL.gguf -ngl 99 -c 8192
|
| 64 |
|
| 65 |
# smaller GPUs: keep the (sparse-gather) n-gram table in system RAM
|
| 66 |
llama-server -m qwen38-keep1-Q3KXL.gguf -ngl 99 -c 8192 \
|
| 67 |
--override-tensor "per_layer_token_embd\.weight=CPU"
|
| 68 |
|
| 69 |
+
# CPU-only boxes work too (slow but correct), given free RAM to spare
|
| 70 |
+
# beyond the file size β ~70 GB for Q3_K_XL, ~80 GB for Q4_0
|
| 71 |
```
|
| 72 |
|
| 73 |
+
The `--override-tensor` flag matters more on the Q4_0 build: it moves the table (3.6 GB) to system RAM and leaves ~72 GB of transformer on the GPU, which is what makes 2Γ32 GB cards viable at all.
|
| 74 |
+
|
| 75 |
Text-only GGUF (vision tensors ship separately as unsloth's mmproj; the vision path is untested with this surgery). MTP speculative decoding is not available β upstream llama.cpp does not export or run the MTP head for this architecture yet.
|
| 76 |
|
| 77 |
## Limitations
|
|
|
|
| 79 |
- Wikitext perplexity 4.66 vs 2.40 for the base: prose is measurably less "polished-autocomplete" even though task performance holds. If your workload is verbatim-recall-heavy (quotes, boilerplate reproduction), the missing table may show up.
|
| 80 |
- Evaluated on a small in-house benchmark (40 tool cases, GSM8K-15, MMLU-30) at β€8K context. Long-context behavior (QSA sparse attention, 256K native) untested.
|
| 81 |
- The kept heads were chosen positionally (first of each 8), not by importance ranking. A calibrated head choice might do slightly better; nobody has measured.
|
| 82 |
+
- The Q4_0 build is unbenchmarked and, as of upload, unrun by anyone. It is structurally verified but not behaviourally verified β treat it as a build to test rather than a build to rely on until someone reports back.
|
| 83 |
|
| 84 |
## How this model was made
|
| 85 |
|
| 86 |
Full write-up, surgery script, and raw result logs: [github.com/Cyronius/qwen-prune-heal-pipeline](https://github.com/Cyronius/qwen-prune-heal-pipeline) (`surgery_qwen38.py`).
|
| 87 |
|
| 88 |
+
Short version: the GGUF's per-head hash-table layout is entirely metadata-driven (`ple.head_offsets`, `ple.head_vocab_sizes`), and llama.cpp reads the table's row count back from the tensor itself. Dropped heads get `vocab_size = 1` pointing at a shared all-zero row, so they contribute nothing and cost one row of storage β no llama.cpp patch, no requantization, no training. The whole build is a streaming byte copy: ~45 minutes on an NVMe laptop, and the entire experimental campaign that selected this configuration cost $1.50 of A100 time.
|
| 89 |
+
|
| 90 |
+
The all-zero row works because it decodes to exact zeros in every quant type used here: an IQ4_NL block with zero bytes, and a Q4_0 block whose `d` scale is zero, both yield 0.0 for all 32 elements. That is what makes the same script reusable across base quants β it reads the table's type out of the source file and byte-slices accordingly, so producing the Q4_0 variant needed no code change at all.
|
| 91 |
|
| 92 |
## License
|
| 93 |
|
| 94 |
+
qwen-community-1.0, inherited from [Qwen/Qwen3.8-Flash-Next](https://huggingface.co/Qwen/Qwen3.8-Flash-Next). Quantized weights derived from [unsloth/Qwen3.8-Flash-Next-GGUF](https://huggingface.co/unsloth/Qwen3.8-Flash-Next-GGUF) (Q3_K_XL build) and [bartowski/Qwen3.8-Flash-Next-GGUF](https://huggingface.co/bartowski/Qwen3.8-Flash-Next-GGUF) (Q4_0 build) β thanks to both for the calibrated quants these builds inherit byte-for-byte, imatrix work included.
|