AI generated
**Local Inference Lab** signed runtime package for **DeepSeek-V4.1-Flash-1017** (TP4 on 4× RTX PRO 6000 Blackwell 96 GB) running on **NVIDIA Flare** - **Single-session coding decode peaking at 1,076 tok/s** (`701–766 tok/s` full end-to-end average over a ~40k-token reasoning + full HTML5 Tetris code generation, `6.76 ms/step` / `147.4 steps/s` with MTP draft-7 + adaptive verification `α=0.6`) - **Cold prefill up to 32,724 tok/s** — a **64k prompt in <2 seconds** (`1.97 s`) and **128k prompt in 4.1 seconds**, completely cold (zero prefix cache) - **Full 1,048,576-token context**, native **MXFP4** weights (384 routed experts + 188.8 GiB Engram tables), multimodal vision support, and **100% lossless** optimizations (zero accuracy compromises, verified on logprobs, prefix cache, and 5/5 cold SWA NIAH up to 24k) All running on **4× PCIe Gen5 RTX PRO 6000 Blackwell 96 GB** (no NVLink, no Python at serving time — pure native Rust + precompiled CUDA graphs via Flare). --- ### Benchmarks (4× RTX PRO 6000 Blackwell, TP4, Engram in RAM) #### Sustained Decode Scaling (Synthetic Random Prompts, `ctx=0`, MTP draft 7, `α=0.6`, 2-run average) | Concurrency | Aggregate tok/s | Per-User tok/s | Mean ITL | Step Time | |---:|---:|---:|---:|---:| | **C1** (synthetic, ~68% d1 accept) | **421.2 tok/s** | **421.2 tok/s** | `2.46 ms` | `6.12 ms` (`140.1 steps/s`) | | **C1 (real coding / Tetris, ~40k tok)** | **701–766 avg / 1,076 peak** | **701–766 avg / 1,076 peak** | — | `6.77 ms` (`147.4 steps/s`) | | **C4** | **1,026.2 tok/s** | **256.6 tok/s** | `3.96 ms` | `8.57 ms` | | **C8** | **1,312.7 tok/s** | **164.1 tok/s** | `6.11 ms` | `10.70 ms` | | **C16** | **1,894.5 tok/s** | **118.4 tok/s** | `8.38 ms` | `12.57 ms` | | **C32** | **2,651.8 tok/s** | **82.9 tok/s** | `11.73 ms` | `14.57 ms` | #### Cold Prefill Throughput (No Prefix Cache) | Prompt Length | Cold Prefill | TTFT | |---:|---:|---:| | **8k tokens** | **31,026 tok/s** | `0.264 s` | | **32k tokens** | **31,939 tok/s** | `1.010 s` | | **64k tokens** | **32,724 tok/s** | `1.967 s` | | **128k tokens** | **31,308 tok/s** | `4.106 s` | *(Test system: 4× NVIDIA RTX PRO 6000 Blackwell Workstation Edition 96 GB, single-socket AMD EPYC 9575F, NVIDIA driver 615.71.10, PCIe Relaxed Ordering enabled.)* ### Quick Setup Guide (NVIDIA Flare) #### 1. Required NVIDIA Kernel Driver Settings (`modprobe`) Because RTX PRO 6000 Blackwell communicates over **PCIe P2P** (no NVLink), enabling **PCIe Relaxed Ordering** in the NVIDIA kernel module is essential for full TP4 collective speed. Create `/etc/modprobe.d/nvidia-relaxed-ordering.conf`: ```sh echo 'options nvidia NVreg_EnablePCIERelaxedOrderingMode=1' | sudo tee /etc/modprobe.d/nvidia-relaxed-ordering.conf ``` *(Optional — only if your motherboard/BIOS restricts PCIe P2P or Resizable BAR between GPUs, you can also enable P2P override in `/etc/modprobe.d/nvidia-p2p-override.conf`:)* ```sh echo 'options nvidia NVreg_RegistryDwords="ForceP2P=0x11;RMForceP2PType=1;RMPcieP2PType=2;GrdmaPciTopoCheckOverride=1;EnableResizableBar=1"' | sudo tee /etc/modprobe.d/nvidia-p2p-override.conf ``` Verify after reboot or nvidia driver reload (must show `EnablePCIERelaxedOrderingMode: 1` and working P2P in `topo -m`): ```sh grep EnablePCIERelaxedOrderingMode /proc/driver/nvidia/params nvidia-smi topo -m ``` #### 2. Run with Flare (Docker — Easiest) The signed runtime package (~524 GB, downloaded automatically on first start) is hosted on Hugging Face under **Local Inference Lab**: https://huggingface.co/local-inference-lab/DeepSeek-V4.1-Flash-1017-FLARE (`--revision gb202`) ```sh docker run --pull=always --rm -it \ --gpus '"device=0,1,2,3"' --ulimit memlock=-1:-1 \ --security-opt seccomp=unconfined \ -p 127.0.0.1:8000:8000 \ -v flare-home:/home/flare \ ghcr.io/local-inference-lab/flare:release \ run local-inference-lab/DeepSeek-V4.1-Flash-1017-FLARE \ --revision gb202 --filename model.safetensors \ --gpus 0,1,2,3 --max-concurrency 32 --mtp-draft-tokens 7 \ --mtp-adaptive-verification --mtp-max-verification-token-budget 128 \ --mtp-adaptive-verification-alpha 0.6 --scheduler-policy balanced \ --embedding-table-storage disk --prefix-cache-memory 64G \ --kv-cache-limit memory --host 0.0.0.0 --port 8000 ``` - **Have >= 320 GiB system RAM?** Switch `--embedding-table-storage disk` to `--embedding-table-storage ram` to keep the entire 188.8 GiB Engram table in RAM for the fastest decode/prefill shown above (and you can drop `--security-opt seccomp=unconfined`). - **Prefer native binary (no Docker)?** Install the signed `flare-inference` package and run the same `flare run ...` command directly on the host. - Exposes a standard OpenAI-compatible API (`DeepSeek-V4.1-Flash`) on `http://127.0.0.1:8000/v1/chat/completions`. ### What Made This Fast (100% Lossless) - **SM120 cluster-parallel split-lagged mHC + AllReduce overlap** — splits hyperconnection `RMSNorm` (`ClusterMhcPostYNorm`) onto the critical path and overlaps the `fn` projection + 20-step Sinkhorn on an auxiliary stream right behind PCIe AllReduce (`+0.07 us` overlap penalty). - **Zero standalone MoE input quantization** — bit-exact MXFP8 quantization fused directly into the FFN mHC epilogue (eliminates 43 quantization launches/step). - **Zero standalone decode RoPE kernels** — fused Q-RoPE inside `MXFP8MultiRowTCGemvKernel` (eliminates 51 Triton RoPE launches/step). - **BF16 TC-GEMV `split_k=5, 10`** for `K=5120` router GEMVs, plus fused residual `addend` on dependency-bearing PCIe AllReduce and 2-microbatch interleaved prefill pipelining (`8192`-token chunks). Links: - **Signed HF package (`gb202`):** https://huggingface.co/local-inference-lab/DeepSeek-V4.1-Flash-1017-FLARE/tree/gb202