Qwopus3.6-27B-v2 NVFP4 — NVFP4 Quant, 262K Context on RTX 5090

·5 min readlocal-ai

TL;DR: Qwopus3.6-27B-v2 NVFP4 runs full 262K context on a single RTX 5090 via 32 GiB CPU KV offload buffer, cuMem memory pool, and the Qwen3 reasoning parser.

This is the command:

Terminal window
CUDA_VISIBLE_DEVICES=0 \
NCCL_P2P_DISABLE=1 \
VLLM_SKIP_P2P_CHECK=1 \
VLLM_USE_FLASHINFER_SAMPLER=1 \
PYTORCH_CUDA_ALLOC_CONF=expandable_segments:True \
vllm serve crushleorey/Qwopus3.6-27B-v2-NVFP4 \
--attention-backend flashinfer \
--gpu-memory-utilization 0.93 \
--enable-chunked-prefill \
--max-num-seqs 2 \
--max-num-batched-tokens 4096 \
--enable-cumem-allocator \
--max-model-len 262144 \
--kv-cache-dtype fp8_e4m3 \
--served-model-name Qwopus3.6-27B \
--enable-auto-tool-choice \
--tool-call-parser qwen3_xml \
--enable-prefix-caching \
--kv_offloading_backend native \
--kv_offloading_size 32 \
--host 0.0.0.0 \
--port 8082 \
--tensor-parallel-size 1 \
--reasoning-parser qwen3

Tuned for one RTX 5090 — full 262K context, KV cache offloading to CPU, cuMem memory pool for colocated workloads.

Setup

Before serving, you need the hf CLI (install guide) to download both the model weights and the fixed chat template.

Install hf CLI

Terminal window
curl -LsSf https://hf.co/cli/install.sh | bash

Download the model

Terminal window
hf download crushleorey/Qwopus3.6-27B-v2-NVFP4 --local-dir crushleorey/Qwopus3.6-27B-v2-NVFP4

Apply the Jinja chat template fix

Download the corrected chat template from froggeric/Qwen-Fixed-Chat-Templates and place it in the same local directory:

Terminal window
hf download hf://froggeric/Qwen-Fixed-Chat-Templates/chat_template.jinja --local-dir crushleorey/Qwopus3.6-27B-v2-NVFP4

Or download chat_template.jinja manually from the repo if you prefer.

The Model

Qwopus3.6-27B-v2 is a reasoning-enhanced fine-tune of Qwen3.6-27B by Jackrong. Training uses Trace Inversion — reconstructing compressed “Reasoning Bubbles” from commercial LLM outputs into full step-by-step CoT traces:

  • 3-Stage Curriculum SFT — Format inauguration → complexity expansion → long-context (up to 32K)
  • claude-opus-4.6/4.7 Trace Inversion — 9,000 + 5,000 reconstructed reasoning chains
  • MTP — Multi-Token Prediction for decoding speedup (1.66× speedup)

The quantized version, crushleorey/Qwopus3.6-27B-v2-NVFP4, uses crushleorey’s hybrid precision strategy:

ModulePrecisionRationale
Core LLMNVFP4Minimum compression, ~18 GB total
Vision EncoderBF16Precision-critical — quantizing degrades image understanding
MTP HeadsBF16Small param count, accuracy-critical for speculative decoding

Base model: Jackrong/Qwopus3.6-27B-v2. NVFP4 variant: crushleorey/Qwopus3.6-27B-v2-NVFP4.

GPU Memory Budget

32 GB RTX 5090, with offloading to CPU:

ComponentSize
Model weights (NVFP4)~18 GB
Vision + MTP heads (BF16)~3–4 GB
FP8 KV cache~2–3 GB (offloaded to CPU when VRAM constrained)
Activations, CUDA graphs~1–2 GB
GPU total~23–27 GB

The 0.93 utilization sets the GPU budget to ~29.8 GB of the 32 GB. The 7% headroom (~2.2 GB) covers CUDA graph captures and memory spikes — vLLM profiles and reserves this extra memory during the profiling step. Without headroom, high-utilization (0.95+) causes OOM.

The Three Helpers

KV Cache Offloading

Terminal window
--kv_offloading_backend native
--kv_offloading_size 32

vLLM’s native CPU offloading connector swaps completed KV blocks between GPU and CPU RAM via the cpu_buddy’s swap_out/in logic. The --kv_offloading_size 32 reserves a 32 GiB buffer on system RAM (total across TP ranks when TP > 1). When VRAM pressure builds, blocks swap to system RAM; when memory frees up, blocks swap back.

cuMem Allocator

Terminal window
--enable-cumem-allocator

Replaces PyTorch’s default CUDA allocator with a custom pool backed by CUDA’s cuMemAlloc/cuMemMap (memory pool API). Enables multi-node NVLink memory visibility and paged memory management with tags. Primary use case: sleep mode — tagged GPU allocations are copied to CPU and GPU memory is released; on demand, memory is re-mapped and data is copied back.

--enable-cumem-allocator activates the pool. Without it, sleep mode doesn’t work — PyTorch’s default allocator can’t do tagged offload.

This parameter is needed if we want to enable PYTORCH_CUDA_ALLOC_CONF optimization with offloading KV cache.

Full 262K Context

Terminal window
--max-model-len 262144

Full native context window. CUDA memory pool + FP8 KV cache + NVFP4 weights make this fit on 32 GB.

Flag Breakdown

FlagPurpose
--attention-backendflashinfer
--gpu-memory-utilization0.93
--enable-chunked-prefillon
--max-num-seqs2
--max-num-batched-tokens4096
--enable-cumem-allocatoron
--max-model-len262144
--kv-cache-dtypefp8_e4m3
--served-model-nameQwopus3.6-27B
--enable-auto-tool-choiceon
--tool-call-parserqwen3_xml
--reasoning-parserqwen3
--kv_offloading_backendnative
--kv_offloading_size32
--host0.0.0.0
--port8082
--tensor-parallel-size1

Environment Variables

VariablePurpose
NCCL_P2P_DISABLE=1Disable NVLink P2P — single GPU
VLLM_SKIP_P2P_CHECK=1Skip P2P check — single-GPU
PYTORCH_CUDA_ALLOC_CONF=expandable_segments:TrueExpandable GPU allocator — reduces fragmentation
VLLM_USE_FLASHINFER_SAMPLER=1Sorting-free sampling — faster top-k/top-p

References

  1. Qwopus3.6-27B-v2 — Jackrong, HF — https://huggingface.co/Jackrong/Qwopus3.6-27B-v2
  2. Qwopus3.6-27B-v2-NVFP4 — crushleorey, HF — https://huggingface.co/crushleorey/Qwopus3.6-27B-v2-NVFP4
  3. Stable Qwopus3.6-27B NVFP4 on RTX 5090 — AI Suka — https://ai-suka.pages.dev/2026/07/01-qwen36-27b-nvfp4-stable-rtx5090-flashinfer/
  4. Inside vLLM’s New KV Offloading Connector — vLLM Blog — https://vllm.ai/blog/2026-01-08-kv-offloading-connector
  5. FlashInfer — https://github.com/flashinfer-ai/flashinfer

This article was written by Pi Coding Agent (Qwopus3.6 27B v2 | PC Eyay).