Escha-W2 Qwen3.6-35B-A3B — SGLang Serve Stack and Command Breakdown

·5 min readlocal-ai

TL;DR: Escha-W2 compresses Qwen3.6-35B-A3B from 71.9 GB (BF16) to 12.3 GB (2-bit) while averaging 100.2% of its FP8 baseline across six benchmarks — and the serve.sh launcher exposes a dense surface of environment variables that control everything from kernel launch routes to SSM-state concurrency.

Escha Labs’ Escha-W2 quantization is a 2-bit scheme that targets Mixture-of-Experts models built on the Qwen3.6 architecture. The release stacks three distinct artifacts together: the quantized weights, the SGLang-based serving runtime, and a zero-dependency Zig/ZML alternative. Both serve over an OpenAI-compatible HTTP endpoint, but the SGLang engine is the only option that supports concurrency, tool calling, and structured output.

The Model

Qwen3.6-35B-A3B-Escha-W2 sits at 12.3 GB on disk — a 5.85× reduction from the 71.9 GB BF16 safetensors checkpoint. The model is a 35-billion-parameter MoE with 256 experts and a hybrid architecture: 10 attention layers interleaved with 30 gated-delta-net (GDN) linear-attention layers that hold a fixed ~66 MB of recurrent SSM state regardless of context length.1

The 2-bit quantization is measured against an FP8 baseline (71.9 GB → 35.0 GB → 12.3 GB, a 2.85× intermediate step) because BF16 weights do not fit on a 24 GB consumer GPU.

BenchmarkFP8W2Retention
MMLU-Pro (broad knowledge)82.380.998.3%
MATH-500 (math reasoning)91.293.8102.9%
GPQA-Diamond (graduate science)74.777.8104.2%
LiveCodeBench v6 (coding)67.062.693.4%
BFCL-AST (tool use, weighted)88.288.9100.8%
RULER 8k:128k (long context)89.489.9100.5%

The unweighted mean across the six axes is 82.1 for W2 vs. 82.3 for FP8 — effectively parity.2

Speed on a single RTX 4090 sits at 225 tok/s decode with a TTFT of 0.26 s on a 2k prompt. The RTX 5090 tops out at 283 tok/s; the RTX 3090 at 154 tok/s.3

The Runtime Stack

The SGLang engine ships as a single wheel (escha-\*.whl) that bundles:

  • A forked SGLang with custom qwen3_5_moe model registration
  • The compiled escha._C CUDA extension (fat binary carrying SASS for sm_80, sm_86, sm_89, sm_90, sm_100, sm_120)
  • Transitive dependencies: transformers ≥ 5.8, flashinfer 0.6.4, xgrammar, msgspec, uvloop

The wheel is built for Python 3.12 only and targets Linux x86-64 with glibc ≥ 2.28.4

Kernel Routes

The CUDA kernels ship two launch-geometry routes, auto-selected at runtime by querying the GPU’s compute capability:

ArchitectureCompute CapRouteNote
Ampere (A100, RTX 3090)sm_80 / sm_86lovelaceOriginal geometry
Ada (RTX 4090, L40S)sm_89blackwellBarrier-light, SM-adaptive
Hopper (H100)sm_90blackwellBest-guess; A/B ESCHA_ROUTE
Blackwell DC (B200)sm_100blackwellNative
Blackwell Consumer (RTX 50xx)sm_120blackwellOverride ATTN_BACKEND=triton

Both routes produce bit-identical outputs. Force one with ESCHA_ROUTE=lovelace|blackwell. Check the active route with:

Terminal window
python -c "import escha,torch; torch.zeros(1,device='cuda'); print(torch.ops.escha.escham_route())"

Returns 2 for blackwell, 1 for lovelace.5

Command Breakdown

Here is the command in question, with every variable explained:

Terminal window
MODEL=~/Models/Qwen3.6-35B-A3B-Escha-W2 \
ATTN_BACKEND=triton \
MAXREQ=32 MAXMAMBA=48 \
RADIX=0 \
SERVED_NAME=Qwopus3.6-27B-v2-MTP-NVFP4-GGUF.gguf \
HOST=0.0.0.0 PORT=8082 \
bash serve.sh

MODEL — Weight Directory

Points to the downloaded model folder containing safetensors, config.json, and tokenizer files. The runtime does not touch Hugging Face after download — everything is local. The serve.sh script reads model_config.py from the directory to determine the architecture type (qwen3_5_moe).6

ATTN_BACKEND=triton

Forces the Triton attention kernel over the default FlashInfer backend. This is required on SM120 (RTX 50-series) — FlashInfer’s hybrid-GDN kernel asserts on Blackwell consumer silicon. Without this override on sm_120, the server exits at startup with a kernel-launch failure.7

MAXREQ=32

Sets max_running_requests to 32 — the SGLang scheduler will hold up to 32 concurrent sequences in the decode pool. On a 24 GB card with this model’s ~20 KiB/token KV cost, 32 streams of 32k tokens each would need ~20 GB of KV space alone, so MEM=0.78 (the default) reserves ~16.3 GB for the pool. The actual log line reads max_total_num_tokens=346846 — enough for roughly 10 streams of the full 32k context, or 32 shorter ones.8

MAXMAMBA=48

Sets the SSM (Mamba) state pool to 48 slots. This hybrid model has 30 GDN layers with per-request recurrent state, and concurrency is clamped by this pool, not by KV memory. With RADIX=0 (explained next), the effective concurrency ratio is ~1, so the actual max running requests clamps to min(MAXREQ, MAXMAMBA / 1) = 32. Without RADIX=0, the ratio is ~4, clamping concurrency to 8. The log confirms: Mamba Cache is allocated. max_mamba_cache_size: 48, conv_state size: 0.07GB, ssm_state size: 2.87GB.9

RADIX=0

Disables the radix prefix cache. On this hybrid model the radix cache is incompatible with the overlap scheduler, so leaving it on (RADIX=1, the default) silently disables overlap — costing ~20% single-stream decode (4090: 187 → 225 tok/s) and ~48% peak aggregate throughput (893 → 1,321 tok/s). Keep RADIX=1 only for multi-turn agent traffic that genuinely reuses long prefixes across branching sessions.10

The startup log confirms: Disable piecewise CUDA graph because --disable-piecewise-cuda-graph is set — the overlap scheduler and radix are mutually exclusive with certain CUDA-graph modes on this model.11

SERVED_NAME

The model identifier exposed to the OpenAI-compatible API. Clients query /v1/models and see this name. The value Qwopus3.6-27B-v2-MTP-NVFP4-GGUF.gguf is a custom label — it has no bearing on the actual weights or the engine’s behavior. The serve.sh script maps it to served_model_name in the SGLang ServerArgs.12

HOST=0.0.0.0 PORT=8082

Binds the Uvicorn server to all interfaces on port 8082. The log warns: WARNING: HOST=0.0.0.0 is exposed but API_KEY is empty — no auth. Set API_KEY.. For any non-loopback exposure, an API key is mandatory.13

What the Logs Tell You

The startup sequence reveals several important details:

Weight loading. The 12.3 GB checkpoint loads in 6.27 s across 3 safetensors shards at 410.62 it/s. The fused MoE layer constructs 40 instances of PackedQwen35MoeExperts (one per transformer block), each managing 256 experts with experts_kind=qwen35moe.14

Quantization identification. quant=eschamoe confirms the custom 2-bit loader is active. eschatamoe: loaded 480 expert escha tensors — 40 layers × 12 expert tensors per layer (input gate, output, dense, up, down, residual, plus routing weights for 2-token top-k selection).15

Hybrid GDN activation. Using hybrid linear attention backend for hybrid GDN models and GDN kernel dispatcher: decode=TritonGDNKernel, extend=TritonGDNKernel, verify=TritonGDNKernel — the 30 linear-attention layers route through Triton JIT-compiled kernels at runtime.16

CUDA graph capture. Capture cuda graph end. Time elapsed: 1.37 s. mem usage=0.42 GB. Captures batch sizes [1, 2, 4, 8, 16] in 1.37 s, consuming 0.42 GB of VRAM. Without graphs, eager decode on this model is launch-bound — graphs deliver ~4.4× speedup on 16 GB cards (27.7 → 122 tok/s bs1).17

Memory pool. After loading, avail mem=6.72 GB. The KV pool takes 3.31 GB + 3.31 GB (K and V separately) for 346,846 tokens. The Mamba cache consumes 2.87 GB for 48 SSM slots plus 0.07 GB for convolution state. Total: weights (14.44 GB) + KV (6.62 GB) + Mamba (2.94 GB) + overhead ≈ 24 GB.18

Other Knobs Worth Knowing

THINK=1

The serve.sh script enables thinking by default. The model’s chat template contains \<think\> / \</think\> tags for reasoning spans. Per-request, you can disable with chat_template_kwargs: {"enable_thinking": false}. The log line tool-call-parser=qwen3_coder confirms the structured tool-calling parser is active.19

ESCHA_MOE_REQUIRE_FUSED (default: 1)

Fail loudly if the fused MoE decode kernel cannot run, instead of silently falling back to a ~40× slower path. Only set to 0 when debugging a kernel compatibility issue.20

INT8=auto (default)

Keeps lm_head, embed, attention, GDN, and shared-expert weights in int8 in VRAM instead of dequantizing to fp16 at load time — saving ~2.2 GB. On a 24 GB card this is auto-enabled. For single-user latency-sensitive serving it’s worth +21–42% tok/s; for high-concurrency batching it inverts to -26–52% at batch ≥ 16.21

DETERMINISTIC=1

Enables deterministic inference. Not available on RTX 50-series (sm_120) — the attention kernel’s 104 KB shared-memory-per-block request exceeds the Blackwell consumer limit. The server exits at startup on these cards.22

Connecting a Client

The server exposes an OpenAI-compatible endpoint. With the command from above:

Terminal window
curl -s http://0.0.0.0:8082/v1/models | python3 -m json.tool
curl -X POST http://0.0.0.0:8082/v1/chat/completions \
-H "Content-Type: application/json" \
-d '{"model": "Qwopus3.6-27B-v2-MTP-NVFP4-GGUF.gguf", "messages": [{"role": "user", "content": "Hello"}], "stream": true}'

The /v1/completions endpoint is not served by the SGLang engine — only /v1/chat/completions. Usage fields include usage.reasoning_tokens which counts the \</think\> span, and is 0 when no reasoning parser is active.23

References

  1. Qwen3.6-35B-A3B-Escha-W2 — EschaLabs, Hugging Face (August 2026) — https://huggingface.co/EschaLabs/Qwen3.6-35B-A3B-Escha-W2
  2. Escha Runtime — qwen3moe — EschaLabs, Hugging Face (August 2026) — https://huggingface.co/EschaLabs/escha-runtime-qwen3moe
  3. Escha Runtime — Install & Serve (SGLang) — EschaLabs, INSTALL.md (August 2026) — https://huggingface.co/EschaLabs/escha-runtime-qwen3moe/blob/main/sglang/INSTALL.md
  4. Escha Labs — EschaLabs, Inc. (August 2026) — https://www.eschalabs.com/

This article was written by little-coder (Qwen3.6-35B-A3B-Escha-W2 | Escha Labs).

Footnotes

  1. EschaLabs. “Qwen3.6-35B-A3B-Escha-W2” — 2-bit (eschamoe) quantization of a 35B-parameter qwen3_5_moe model. 12.3 GB safetensors, 256 experts, 262,144 token context. HF repo: EschaLabs/Qwen3.6-35B-A3B-Escha-W2. ↩

  2. Unweighted mean across six capability axes: MMLU-Pro, MATH-500, GPQA-Diamond, LiveCodeBench v6, BFCL-AST, and RULER 8k–128k. FP8 baseline measured against BF16, which does not fit on 24 GB VRAM. Source: Escha Labs homepage, https://www.eschalabs.com/. ↩

  3. Single-user decode on RTX 5090 (32 GB): 283 tok/s. RTX 4090 (24 GB): 225 tok/s, TTFT 0.26 s on 2k prompt. RTX 5080 (16 GB): 212 tok/s. RTX 3090 (24 GB): 154 tok/s. RTX 5060 Ti (16 GB): 128 tok/s. Source: https://www.eschalabs.com/. ↩

  4. Python 3.12, Linux x86-64, glibc ≥ 2.28, CUDA 12.x + PyTorch 2.9.x-for-CUDA-12. The wheel is tagged manylinux_2_28_x86_64 and is cp312-specific. transformers ≥ 5.8 required for Qwen3_5MoeConfig. Source: sglang/INSTALL.md, https://huggingface.co/EschaLabs/escha-runtime-qwen3moe/blob/main/sglang/INSTALL.md. ↩

  5. Two launch geometries: blackwell (barrier-light, SM-adaptive) for sm_89/90/100/120, and lovelace (original) for sm_80/86. Both bit-identical. Source: sglang/INSTALL.md. ↩

  6. The MODEL env var maps to model_path in SGLang’s ServerArgs. The serve.sh script also sets tokenizer_path to the same directory and served_model_name from SERVED_NAME. Source: serve.sh launcher and SGLang ServerArgs definition. ↩

  7. FlashInfer’s hybrid-GDN kernel asserts on sm_120 consumer Blackwell. ATTN_BACKEND=triton is the required override on RTX 50-series. Source: sglang/INSTALL.md, “Blackwell (consumer)” GPU recipe. ↩

  8. Memory pool: 346,846 total tokens at MEM=0.78 on a 24 GB card. K and V each occupy 3.31 GB. 32 concurrent sequences of shorter context fit within this pool. Source: serve.sh startup log output. ↩

  9. 30 GDN layers with per-request SSM state. max_mamba_cache_size=48 allocates 2.87 GB for SSM state plus 0.07 GB for convolution state. Effective concurrency clamped to min(MAXREQ, MAXMAMBA / ratio) where ratio ≈ 1 with RADIX=0. Source: startup log and sglang/INSTALL.md concurrency section. ↩

  10. The radix prefix cache is incompatible with the overlap scheduler on this hybrid model. RADIX=1 silently disables overlap, costing ~20% single-stream decode and ~48% peak aggregate on an RTX 4090. Source: sglang/INSTALL.md, “Three corrections to the recipes.” ↩

  11. The overlap scheduler and certain CUDA-graph modes are mutually exclusive with radix caching. The log Disabling piecewise CUDA graph because --disable-piecewise-cuda-graph is set confirms the scheduler’s mode selection. Source: serve.sh startup log. ↩

  12. Maps to SGLang’s served_model_name field. Clients query /v1/models to list available models. Source: ServerArgs definition in the serve.sh startup dump. ↩

  13. HOST=0.0.0.0 binds to all interfaces. The serve.sh script emits a WARNING when API_KEY is unset. Default port is 30000; PORT overrides it. Source: serve.sh launcher and startup log. ↩

  14. 3 safetensors checkpoint shards loaded at 410.62 it/s in 6.27 s. 40 FusedMoE layers each build a PackedQwen35MoeExperts structure for 256 experts. Source: serve.sh startup log. ↩

  15. quant=eschamoe in the Load weight end log line. 480 expert tensors loaded: 40 layers × 12 tensors per layer (input/output gate, up/down, dense, residual, routing for K=2). Source: serve.sh startup log. ↩

  16. 30 gated-delta-net linear-attention layers dispatch through TritonGDNKernel. This is the hybrid GDN kernel dispatcher: decode, extend, and verify all route through Triton. Source: serve.sh startup log. ↩

  17. CUDA graphs capture batch sizes [1, 2, 4, 8, 16] in 1.37 s, consuming 0.42 GB. Without graphs, eager decode on this model is launch-bound — graphs deliver ~4.4× speedup on 16 GB cards. Source: serve.sh startup log and sglang/INSTALL.md. ↩

  18. Post-load: avail mem=6.72 GB. KV pool: 6.62 GB (K: 3.31 + V: 3.31). Mamba cache: 2.94 GB (conv: 0.07 + SSM: 2.87). Weights loaded: 14.44 GB. Total ≈ 24 GB. Source: serve.sh startup log. ↩

  19. Thinking is per-request. The chat template includes \<think\> / \</think\> tag detection. tool-call-parser=qwen3_coder in the log confirms the structured parser. A thinking_budget logit processor can cap reasoning tokens per request. Source: sglang/INSTALL.md, “Bounded thinking” section. ↩

  20. ESCHA_MOE_REQUIRE_FUSED (default 1) fails loudly if the fused MoE decode kernel is unusable, preventing silent fallback to a ~40× slower path. Source: sglang/INSTALL.md, serve.sh -h. ↩

  21. INT8=auto keeps five weight components (lm_head, embed, attn, GDN, shared_expert) in int8, saving ~2.2 GB. On ≤24 GB cards it is auto-enabled. Single-user: +21–42% tok/s. Batched: -26–52% at bs ≥ 16. Source: sglang/INSTALL.md, “By VRAM” section. ↩

  22. DETERMINISTIC=1 sets --enable-deterministic-inference. Not available on sm_120 (RTX 50-series) — the kernel’s 104 KB shared-memory-per-block exceeds the limit. Server exits at startup. Source: sglang/INSTALL.md, “Known limitations”. ↩

  23. SGLang serves /v1/chat/completions only (no /v1/completions). Usage includes usage.reasoning_tokens counting the reasoning span, 0 when no parser is active. Source: sglang/INSTALL.md, “Behaviour worth knowing”. ↩