How to use from
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 analogalok/Qwen3.8-27B-DFlash2-Q2_K-GGUF:Q2_K
# Run inference directly in the terminal:
llama cli -hf analogalok/Qwen3.8-27B-DFlash2-Q2_K-GGUF:Q2_K
Install from WinGet (Windows)
winget install llama.cpp
# Start a local OpenAI-compatible server with a web UI:
llama serve -hf analogalok/Qwen3.8-27B-DFlash2-Q2_K-GGUF:Q2_K
# Run inference directly in the terminal:
llama cli -hf analogalok/Qwen3.8-27B-DFlash2-Q2_K-GGUF:Q2_K
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 analogalok/Qwen3.8-27B-DFlash2-Q2_K-GGUF:Q2_K
# Run inference directly in the terminal:
./llama-cli -hf analogalok/Qwen3.8-27B-DFlash2-Q2_K-GGUF:Q2_K
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 analogalok/Qwen3.8-27B-DFlash2-Q2_K-GGUF:Q2_K
# Run inference directly in the terminal:
./build/bin/llama-cli -hf analogalok/Qwen3.8-27B-DFlash2-Q2_K-GGUF:Q2_K
Use Docker
docker model run hf.co/analogalok/Qwen3.8-27B-DFlash2-Q2_K-GGUF:Q2_K
Quick Links

Qwen3.8-27B-DFlash2-Q2_K (2-Bit Zero-Loss Speculative Drafter)

This repository provides the Q2_K (2-bit) quantization of z-lab/Qwen3.8-27B-DFlash2 (~700 MB on disk).

It is engineered specifically for 24GB consumer GPUs (NVIDIA GeForce RTX 4090 / RTX 3090) to run speculative decoding alongside Qwen3.8-27B dense models without spilling into system RAM.


🚀 Benchmark Discovery: Zero Quality Loss at 2-Bit

By quantizing the DFlash 2 block-diffusion drafter down from the official Q4_K_M (1.1 GB) to Q2_K (700 MB), we save ~400–450 MB of VRAM with zero degradation in speculative draft accuracy.

Strict A/B Performance on Single RTX 4090 (24GB VRAM):

Evaluated on Qwen3.8-27B-UD-Q4_K_XL using llama-server (PR #27342) with --spec-draft-n-max 3 across a 28k prompt baseline.

Drafter Quant File Size Mean Accepted Length Acceptance Rate Decode Speed Max Usable Context (24GB VRAM)
Official Q4_K_M ~1.10 GB 2.80 / 3.0 tokens 60.00% 75.89 t/s 150,000 tokens (Q4 KV)
Custom Q2_K (This Repo) ~700 MB 2.81 / 3.0 tokens 60.22% 75.93 t/s 170,000 tokens (+20k)

Key Takeaways:

  1. Identical Acceptance Rate: The target 27B model accepts 2.81 out of 3.0 drafted tokens on average $(93.7% \text{ theoretical efficiency})$, matching the 4-bit drafter identically.
  2. Context Expansion: The ~400 MB saved VRAM directly unlocks:
    • 170,000 Context on Q4_0 KV (~76 t/s @ 23.89 GB)
    • 100,000 Context on high-precision Q8_0 KV (~75 t/s @ 23.88 GB)

⚙️ Why Q2_K is the True Physical Floor for DFlash 2

DFlash 2 is a cross-layer block-diffusion drafter that extracts hidden states from layers [6, 20, 34, 48, 62] of the base model. Because it is not a standalone causal LM, standalone llama-imatrix calibration fails (dflash requires ctx_other to be set).

This means importance-matrix quants (IQ1_S, IQ2_XXS) cannot be computed, making Q2_K the absolute lowest non-degrading quantization floor for DFlash 2.


🛠️ Quickstart with llama.cpp

Requires llama.cpp built from PR #27342.

1. Build llama.cpp:

git clone https://github.com/ggml-org/llama.cpp.git
cd llama.cpp
git fetch origin pull/27342/head:pr-27342
git switch pr-27342

# Build with CUDA
cmake -B build -DGGML_CUDA=ON && cmake --build build -j
Downloads last month
497
GGUF
Model size
2B params
Architecture
dflash
Hardware compatibility
Log In to add your hardware

2-bit

Inference Providers NEW
This model isn't deployed by any Inference Provider. 🙋 Ask for provider support

Model tree for analogalok/Qwen3.8-27B-DFlash2-Q2_K-GGUF

Base model

Qwen/Qwen3.8-27B
Quantized
(2)
this model