Repository navigation
[Model] Add Flint (RecursiveSI/flint) - #62938
Conversation
Add Recursive's Flint MoE (40B total, 2.5B active; 35 sliding-window + 14 full-attention layers with learned sinks; 256 experts, sigmoid top-6 plus a shared expert) for both released checkpoints: BF16 safetensors (RecursiveSI/flint) and an NVFP4 GGUF (RecursiveSI/flint-nvfp4-gguf), which is repacked losslessly to the ModelOpt layout and run W4A16. The model lives in vllm/models/flint/ with Flint-specific kernels for small-batch decode on a single Blackwell GPU (fused Q/K norm + RoPE + KV write, GEMV MoE and dense kernels, CuTe DSL decode attention with sinks and sliding windows, and a 7-kernel PDL-chained decode path). Other configurations use vLLM's standard layers. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Signed-off-by: Woosuk Kwon <woosuk@inferact.ai>
|
Documentation preview: https://vllm--62938.org.readthedocs.build/en/62938/ |
|
Validation on this PR's tree (
|
|
Thanks for the day-0 support! We brought Flint NVFP4 up on a single RTX 5090 (sm_120) with 1. It checks only TP=1 / quant type / EP, so on sm_120 it selects Gating it on arch makes sm_120 take the stock layers, as the docstring describes (plus def _flint_kernels(
quant_config: QuantizationConfig | None, parallel: ParallelConfig | None = None
) -> bool:
"""Flint's kernels serve the BF16 and NVFP4 checkpoints on a single GPU
- (TP=1, and for the MoE no EP/EPLB); other configurations use vLLM's stock
- layers."""
+ (SM90/SM100, TP=1, and for the MoE no EP/EPLB); other configurations use
+ vLLM's stock layers."""
+ if not (
+ current_platform.is_device_capability_family(90)
+ or current_platform.is_device_capability_family(100)
+ ):
+ return False
if get_tensor_model_parallel_world_size() != 1 or not (With this, the 5090 runs
Open question: the small-batch Triton decode MoE path (β€ 2. The Loading Minor: passing the |
|
Tried this on sm_120 with the NVFP4 GGUF: serving on an RTX PRO 6000 Blackwell Workstation Edition, kernel tests on an RTX 5070 Ti.
Routing, dequant, the Triton decode GEMVs, We gated it on the device: def _flint_kernels(quant_config, parallel=None) -> bool:
+ if not current_platform.is_device_capability_family(100):
+ return False
if get_tensor_model_parallel_world_size() != 1 or not (With that, sm_120 runs on the stock layers (Marlin W4A16 NVFP4, FlashInfer attention with sinks) and lands on Recursive's NVFP4 numbers: LiveCodeBench v6 82.2% on a 45 problem sample, SWE-bench Verified 80% on 50 tasks (mini-swe-agent, no network). The Test log, patch and setup: https://github.com/DataCraftsmanAU/flint-independent-eval ( |
- Use Flint's kernels only on SM100-family GPUs, where they are built and tested; other GPUs (e.g. sm_120) use vLLM's standard layers. - Install gguf>=0.19.0 in the vllm-openai image so the NVFP4 GGUF checkpoint loads out of the box. - Skip speculators detection for a single-file local model, so a .gguf path can be passed as --model. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Signed-off-by: Woosuk Kwon <woosuk@inferact.ai>
|
Thanks @zflowai and @DataCraftsmanAU for testing on sm_120 and for the detailed reports. Addressed in 826fd3f:
Tests:
|
The CuTe DSL W4A16 tactic warmup applies to every weight-only NVFP4 model on SM100, not just Flint, so it is proposed on its own. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Signed-off-by: Woosuk Kwon <woosuk@inferact.ai>
β¦ CI step - FlintForCausalLM no longer implements MixtureOfExperts; it was only used for EPLB, which Flint does not support. - Drop the unused head_dtype config field. - Run all Flint tests in the B200 step and remove the CPU step. - Recipe: drop VLLM_USE_RUST_FRONTEND=0 (the Python frontend is the default). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Signed-off-by: Woosuk Kwon <woosuk@inferact.ai>
- Reuse cute_primitives.mma in the decode attention kernel.
- combine_splits: num_warps (4 or 8) divides the GQA group, so every
warp owns a head; drop the always-true guard.
- Single o_proj tail in the attention forward; the cache views are all
None together, so check layer_slots only.
- RMSNorm: hidden size is always 2048, keep one num_warps.
- test_qkv_fused: m in {1, 2, 5, 8} (m is a runtime value).
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Signed-off-by: Woosuk Kwon <woosuk@inferact.ai>
- Prepare the FlashInfer W4A16 expert layout with vLLM's existing CuTe DSL MoE helpers instead of a local copy. - Drop the unused no-shared-expert paths. - Merge the router GEMV and fused add+RMSNorm router kernels into one. - Reuse the experts' router counter for the fused decode block. - Drop a test covered by test_moe_matches_reference. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Signed-off-by: Woosuk Kwon <woosuk@inferact.ai>
- Move the NVFP4 row load and the warp/cluster reduction shared by the dense and expert GEMVs into cute_primitives. - Share the expert GEMV compile boilerplate. - Drop the untuned-shape and beyond-largest-tile GEMV fallbacks, the per-launch support check, max_m and the dequantize_rows row offset; the dequantize-GEMM threshold is one constant. - Test the GEMVs on the tuned shapes and token tiles the model uses. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Signed-off-by: Woosuk Kwon <woosuk@inferact.ai>
β¦v_fused The BF16 GEMV no longer has an untuned-shape fallback. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Signed-off-by: Woosuk Kwon <woosuk@inferact.ai>
|
Simplified the Flint code: β198 lines, now 7,534 added. No change in behavior or speed. Commits
Tried and rejected, each measured A/B on GB200:
Validation on
|
|
/ci run |
|
β
Triggered Buildkite CI #96687 for commit |
cvt.rn.bf16x2.e2m1x2 needs PTX ISA 9.2 (ptxas >= 13.2). Images that run Triton with an older system ptxas (e.g. CUDA 13.0) fail to assemble the Triton MoE decode kernels. Use cvt.rn.f16x2.e2m1x2 there; E2M1 * E4M3 is exact in FP16 too. Newer ptxas keeps the BF16 form, which is faster. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Signed-off-by: Woosuk Kwon <woosuk@inferact.ai>
|
CI fix ( Cause. Fix. At import,
Validation (one GB200):
The other two failures are unrelated to this PR:
|
|
/ci run |
|
β
Triggered Buildkite CI #96692 for commit |
The model module imported FlashInfer's attention backend and the CuTe DSL decode-attention kernel at module level, so the registry import test failed on ROCm, which has neither. Import them where the model is built. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Signed-off-by: Woosuk Kwon <woosuk@inferact.ai>
|
AMD CI (
|
vllm-project/vllm@main:recipes 87b804f09d69 β 0bfeb8d0e367 [latest.vllm] vllm-project/vllm@87b804f...0bfeb8d Commits: - vllm-project/vllm@899a1689e2a0 [Model] Add Recursive Flint (vllm-project/vllm#62938) Recipes: - RecursiveSI/flint (added): https://recipes.vllm.ai/RecursiveSI/flint Signed-off-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
β¦mni@27fd77b48ccd vllm-project/vllm@main:recipes 47e2b610bea1 β 19c0e170d257 [latest.vllm] vllm-project/vllm@47e2b61...19c0e17 Commits: - vllm-project/vllm@544f182d9f0c [Doc] Kimi-K3: document the GB300 disaggregated specialized-decode points in the guide and command builder (vllm-project/vllm#63222) - vllm-project/vllm@eff8a5689681 [Doc][Recipe] MiniMax-M3.1-Flash: add Hopper FP8 variant, Docker-only install (vllm-project/vllm#63244) - vllm-project/vllm@d05b1c8305c9 [Doc][Recipe] Add MiniMax-M3.1-Flash recipe (vllm-project/vllm#63236) - vllm-project/vllm@899a1689e2a0 [Model] Add Recursive Flint (vllm-project/vllm#62938) Recipes: - MiniMaxAI/MiniMax-M3.1-Flash (added): https://recipes.vllm.ai/MiniMaxAI/MiniMax-M3.1-Flash - RecursiveSI/flint (added): https://recipes.vllm.ai/RecursiveSI/flint - moonshotai/Kimi-K3 (modified): https://recipes.vllm.ai/moonshotai/Kimi-K3 vllm-project/vllm-omni@main:recipes 798fef99a33f β 27fd77b48ccd [latest.vllm-omni] vllm-project/vllm-omni@798fef9...27fd77b Commits: - vllm-project/vllm-omni@88c9ccd7ceb3 [Model] Add JoyAI duplex tool delegation (vllm-project/vllm-omni#9149) Signed-off-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Signed-off-by: Woosuk Kwon <woosuk@inferact.ai> Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
Flint (vllm-project#62938) ran only on NVIDIA: on ROCm it failed at start-up importing FlashInfer, and with that bypassed it generated garbage. It also could not feed a speculative draft. - model.py: with any backend but FlashInfer, the fused q/k RMSNorm + RoPE kernel runs without its FlashInfer-layout cache write and the Attention layer writes the cache in the backend's own layout and dtype (int8 KV works) and runs attention with the sinks and sliding window. The FlashInfer path is unchanged. - ops/norm.py: _rsqrt was the PTX rsqrt.approx.ftz.f32 by inline assembly, which is not an instruction on AMD and corrupted every RMSNorm (the model printed "also also also ..."). CUDA keeps it; elsewhere tl.math.rsqrt. rms_norm, fused_add_rms_norm and silu_and_mul match a torch reference exactly on gfx1151. - ops/qk_norm_rope.py: heads fastest in the launch grid on ROCm. Tokens first, the programs running together read one head's columns of rows 10 KiB apart, which camp on the same DRAM channels on gfx11 APUs: 5.58 ms (30 GB/s) at 8k tokens, 0.85 ms heads first, bit-identical output. CUDA keeps its order. - model.py: FlintModel takes EagleModelMixin and records the residual stream after the layers the draft names (DFlash 2: target_layer_ids + 1 = 6, 16, 27, 37, 47); FlintForCausalLM declares SupportsEagle3, so incoai/Flint-DFlash2 runs as a dflash draft. Verify batches go through the non-FlashInfer attention with sinks, as plain decode does. HawkBearPig/flint-FP8-BF16 on gfx1151 with libstrix: greedy output follows the checkpoint's reference generations (token ids it ships for four prompts) - three of four in full, the fourth diverging where the model's top two tokens are 0.08 nats apart. With the DFlash 2 draft (int8 KV, 8 prompts, greedy, 256 tokens), output tok/s at 1 request / 8 at once and mean tokens accepted per step: no draft 62.2 / 135.8 2 tokens 69.3 / 138.1 (2.28) 3 tokens 71.8 / 137.2 (2.67) 5 tokens 52.0 / 137.0 (3.04) 7 tokens 54.7 / 125.4 (3.27) Every configuration matches the no-draft output except at near-ties (largest baseline top-1/top-2 gap at a divergence 0.63 nats). A longer verify batch reads more of the 256 experts per step than its extra accepted tokens pay for. GSM8K (n = 250, greedy, 768 tokens), one request at a time: 196 without the draft, 200 with 3 draft tokens; 12 / 16 discordant, McNemar p = 0.57.
Flint (vllm-project#62938) ran only on NVIDIA: on ROCm it failed at start-up importing FlashInfer, and with that bypassed it generated garbage. It also could not feed a speculative draft. - model.py: with any backend but FlashInfer, the fused q/k RMSNorm + RoPE kernel runs without its FlashInfer-layout cache write and the Attention layer writes the cache in the backend's own layout and dtype (int8 KV works) and runs attention with the sinks and sliding window. The FlashInfer path is unchanged. - ops/norm.py: _rsqrt was the PTX rsqrt.approx.ftz.f32 by inline assembly, which is not an instruction on AMD and corrupted every RMSNorm (the model printed "also also also ..."). CUDA keeps it; elsewhere tl.math.rsqrt. rms_norm, fused_add_rms_norm and silu_and_mul match a torch reference exactly on gfx1151. - ops/qk_norm_rope.py: heads fastest in the launch grid on ROCm. Tokens first, the programs running together read one head's columns of rows 10 KiB apart, which camp on the same DRAM channels on gfx11 APUs: 5.58 ms (30 GB/s) at 8k tokens, 0.85 ms heads first, bit-identical output. CUDA keeps its order. - model.py: FlintModel takes EagleModelMixin and records the residual stream after the layers the draft names (DFlash 2: target_layer_ids + 1 = 6, 16, 27, 37, 47); FlintForCausalLM declares SupportsEagle3, so incoai/Flint-DFlash2 runs as a dflash draft. Verify batches go through the non-FlashInfer attention with sinks, as plain decode does. HawkBearPig/flint-FP8-BF16 on gfx1151 with libstrix: greedy output follows the checkpoint's reference generations (token ids it ships for four prompts) - three of four in full, the fourth diverging where the model's top two tokens are 0.08 nats apart. With the DFlash 2 draft (int8 KV, 8 prompts, greedy, 256 tokens), output tok/s at 1 request / 8 at once and mean tokens accepted per step: no draft 62.2 / 135.8 2 tokens 69.3 / 138.1 (2.28) 3 tokens 71.8 / 137.2 (2.67) 5 tokens 52.0 / 137.0 (3.04) 7 tokens 54.7 / 125.4 (3.27) Every configuration matches the no-draft output except at near-ties (largest baseline top-1/top-2 gap at a divergence 0.63 nats). A longer verify batch reads more of the 256 experts per step than its extra accepted tokens pay for. GSM8K (n = 250, greedy, 768 tokens), one request at a time: 196 without the draft, 200 with 3 draft tokens; 12 / 16 discordant, McNemar p = 0.57.
Flint (vllm-project#62938) ran only on NVIDIA: on ROCm it failed at start-up importing FlashInfer, and with that bypassed it generated garbage. It also could not feed a speculative draft. - model.py: with any backend but FlashInfer, the fused q/k RMSNorm + RoPE kernel runs without its FlashInfer-layout cache write and the Attention layer writes the cache in the backend's own layout and dtype (int8 KV works) and runs attention with the sinks and sliding window. The FlashInfer path is unchanged. - ops/norm.py: _rsqrt was the PTX rsqrt.approx.ftz.f32 by inline assembly, which is not an instruction on AMD and corrupted every RMSNorm (the model printed "also also also ..."). CUDA keeps it; elsewhere tl.math.rsqrt. rms_norm, fused_add_rms_norm and silu_and_mul match a torch reference exactly on gfx1151. - ops/qk_norm_rope.py: heads fastest in the launch grid on ROCm. Tokens first, the programs running together read one head's columns of rows 10 KiB apart, which camp on the same DRAM channels on gfx11 APUs: 5.58 ms (30 GB/s) at 8k tokens, 0.85 ms heads first, bit-identical output. CUDA keeps its order. - model.py: FlintModel takes EagleModelMixin and records the residual stream after the layers the draft names (DFlash 2: target_layer_ids + 1 = 6, 16, 27, 37, 47); FlintForCausalLM declares SupportsEagle3, so incoai/Flint-DFlash2 runs as a dflash draft. Verify batches go through the non-FlashInfer attention with sinks, as plain decode does. HawkBearPig/flint-FP8-BF16 on gfx1151 with libstrix: greedy output follows the checkpoint's reference generations (token ids it ships for four prompts) - three of four in full, the fourth diverging where the model's top two tokens are 0.08 nats apart. With the DFlash 2 draft (int8 KV, 8 prompts, greedy, 256 tokens), output tok/s at 1 request / 8 at once and mean tokens accepted per step: no draft 62.2 / 135.8 2 tokens 69.3 / 138.1 (2.28) 3 tokens 71.8 / 137.2 (2.67) 5 tokens 52.0 / 137.0 (3.04) 7 tokens 54.7 / 125.4 (3.27) Every configuration matches the no-draft output except at near-ties (largest baseline top-1/top-2 gap at a divergence 0.63 nats). A longer verify batch reads more of the 256 experts per step than its extra accepted tokens pay for. GSM8K (n = 250, greedy, 768 tokens), one request at a time: 196 without the draft, 200 with 3 draft tokens; 12 / 16 discordant, McNemar p = 0.57.
Flint (vllm-project#62938) ran only on NVIDIA: on ROCm it failed at start-up importing FlashInfer, and with that bypassed it generated garbage. It also could not feed a speculative draft. - model.py: with any backend but FlashInfer, the fused q/k RMSNorm + RoPE kernel runs without its FlashInfer-layout cache write and the Attention layer writes the cache in the backend's own layout and dtype (int8 KV works) and runs attention with the sinks and sliding window. The FlashInfer path is unchanged. - ops/norm.py: _rsqrt was the PTX rsqrt.approx.ftz.f32 by inline assembly, which is not an instruction on AMD and corrupted every RMSNorm (the model printed "also also also ..."). CUDA keeps it; elsewhere tl.math.rsqrt. rms_norm, fused_add_rms_norm and silu_and_mul match a torch reference exactly on gfx1151. - ops/qk_norm_rope.py: heads fastest in the launch grid on ROCm. Tokens first, the programs running together read one head's columns of rows 10 KiB apart, which camp on the same DRAM channels on gfx11 APUs: 5.58 ms (30 GB/s) at 8k tokens, 0.85 ms heads first, bit-identical output. CUDA keeps its order. - model.py: FlintModel takes EagleModelMixin and records the residual stream after the layers the draft names (DFlash 2: target_layer_ids + 1 = 6, 16, 27, 37, 47); FlintForCausalLM declares SupportsEagle3, so incoai/Flint-DFlash2 runs as a dflash draft. Verify batches go through the non-FlashInfer attention with sinks, as plain decode does. HawkBearPig/flint-FP8-BF16 on gfx1151 with libstrix: greedy output follows the checkpoint's reference generations (token ids it ships for four prompts) - three of four in full, the fourth diverging where the model's top two tokens are 0.08 nats apart. With the DFlash 2 draft (int8 KV, 8 prompts, greedy, 256 tokens), output tok/s at 1 request / 8 at once and mean tokens accepted per step: no draft 62.2 / 135.8 2 tokens 69.3 / 138.1 (2.28) 3 tokens 71.8 / 137.2 (2.67) 5 tokens 52.0 / 137.0 (3.04) 7 tokens 54.7 / 125.4 (3.27) Every configuration matches the no-draft output except at near-ties (largest baseline top-1/top-2 gap at a divergence 0.63 nats). A longer verify batch reads more of the 256 experts per step than its extra accepted tokens pay for. GSM8K (n = 250, greedy, 768 tokens), one request at a time: 196 without the draft, 200 with 3 draft tokens; 12 / 16 discordant, McNemar p = 0.57.
Flint (vllm-project#62938) ran only on NVIDIA: on ROCm it failed at start-up importing FlashInfer, and with that bypassed it generated garbage. It also could not feed a speculative draft. - model.py: with any backend but FlashInfer, the fused q/k RMSNorm + RoPE kernel runs without its FlashInfer-layout cache write and the Attention layer writes the cache in the backend's own layout and dtype (int8 KV works) and runs attention with the sinks and sliding window. The FlashInfer path is unchanged. - ops/norm.py: _rsqrt was the PTX rsqrt.approx.ftz.f32 by inline assembly, which is not an instruction on AMD and corrupted every RMSNorm (the model printed "also also also ..."). CUDA keeps it; elsewhere tl.math.rsqrt. rms_norm, fused_add_rms_norm and silu_and_mul match a torch reference exactly on gfx1151. - ops/qk_norm_rope.py: heads fastest in the launch grid on ROCm. Tokens first, the programs running together read one head's columns of rows 10 KiB apart, which camp on the same DRAM channels on gfx11 APUs: 5.58 ms (30 GB/s) at 8k tokens, 0.85 ms heads first, bit-identical output. CUDA keeps its order. - model.py: FlintModel takes EagleModelMixin and records the residual stream after the layers the draft names (DFlash 2: target_layer_ids + 1 = 6, 16, 27, 37, 47); FlintForCausalLM declares SupportsEagle3, so incoai/Flint-DFlash2 runs as a dflash draft. Verify batches go through the non-FlashInfer attention with sinks, as plain decode does. HawkBearPig/flint-FP8-BF16 on gfx1151 with libstrix: greedy output follows the checkpoint's reference generations (token ids it ships for four prompts) - three of four in full, the fourth diverging where the model's top two tokens are 0.08 nats apart. With the DFlash 2 draft (int8 KV, 8 prompts, greedy, 256 tokens), output tok/s at 1 request / 8 at once and mean tokens accepted per step: no draft 62.2 / 135.8 2 tokens 69.3 / 138.1 (2.28) 3 tokens 71.8 / 137.2 (2.67) 5 tokens 52.0 / 137.0 (3.04) 7 tokens 54.7 / 125.4 (3.27) Every configuration matches the no-draft output except at near-ties (largest baseline top-1/top-2 gap at a divergence 0.63 nats). A longer verify batch reads more of the 256 experts per step than its extra accepted tokens pay for. GSM8K (n = 250, greedy, 768 tokens), one request at a time: 196 without the draft, 200 with 3 draft tokens; 12 / 16 discordant, McNemar p = 0.57.
Flint (vllm-project#62938) ran only on NVIDIA: on ROCm it failed at start-up importing FlashInfer, and with that bypassed it generated garbage. It also could not feed a speculative draft. - model.py: with any backend but FlashInfer, the fused q/k RMSNorm + RoPE kernel runs without its FlashInfer-layout cache write and the Attention layer writes the cache in the backend's own layout and dtype (int8 KV works) and runs attention with the sinks and sliding window. The FlashInfer path is unchanged. - ops/norm.py: _rsqrt was the PTX rsqrt.approx.ftz.f32 by inline assembly, which is not an instruction on AMD and corrupted every RMSNorm (the model printed "also also also ..."). CUDA keeps it; elsewhere tl.math.rsqrt. rms_norm, fused_add_rms_norm and silu_and_mul match a torch reference exactly on gfx1151. - ops/qk_norm_rope.py: heads fastest in the launch grid on ROCm. Tokens first, the programs running together read one head's columns of rows 10 KiB apart, which camp on the same DRAM channels on gfx11 APUs: 5.58 ms (30 GB/s) at 8k tokens, 0.85 ms heads first, bit-identical output. CUDA keeps its order. - model.py: FlintModel takes EagleModelMixin and records the residual stream after the layers the draft names (DFlash 2: target_layer_ids + 1 = 6, 16, 27, 37, 47); FlintForCausalLM declares SupportsEagle3, so incoai/Flint-DFlash2 runs as a dflash draft. Verify batches go through the non-FlashInfer attention with sinks, as plain decode does. HawkBearPig/flint-FP8-BF16 on gfx1151 with libstrix: greedy output follows the checkpoint's reference generations (token ids it ships for four prompts) - three of four in full, the fourth diverging where the model's top two tokens are 0.08 nats apart. With the DFlash 2 draft (int8 KV, 8 prompts, greedy, 256 tokens), output tok/s at 1 request / 8 at once and mean tokens accepted per step: no draft 62.2 / 135.8 2 tokens 69.3 / 138.1 (2.28) 3 tokens 71.8 / 137.2 (2.67) 5 tokens 52.0 / 137.0 (3.04) 7 tokens 54.7 / 125.4 (3.27) Every configuration matches the no-draft output except at near-ties (largest baseline top-1/top-2 gap at a divergence 0.63 nats). A longer verify batch reads more of the 256 experts per step than its extra accepted tokens pay for. GSM8K (n = 250, greedy, 768 tokens), one request at a time: 196 without the draft, 200 with 3 draft tokens; 12 / 16 discordant, McNemar p = 0.57.
Flint (vllm-project#62938) ran only on NVIDIA: on ROCm it failed at start-up importing FlashInfer, and with that bypassed it generated garbage. It also could not feed a speculative draft. - model.py: with any backend but FlashInfer, the fused q/k RMSNorm + RoPE kernel runs without its FlashInfer-layout cache write and the Attention layer writes the cache in the backend's own layout and dtype (int8 KV works) and runs attention with the sinks and sliding window. The FlashInfer path is unchanged. - ops/norm.py: _rsqrt was the PTX rsqrt.approx.ftz.f32 by inline assembly, which is not an instruction on AMD and corrupted every RMSNorm (the model printed "also also also ..."). CUDA keeps it; elsewhere tl.math.rsqrt. rms_norm, fused_add_rms_norm and silu_and_mul match a torch reference exactly on gfx1151. - ops/qk_norm_rope.py: heads fastest in the launch grid on ROCm. Tokens first, the programs running together read one head's columns of rows 10 KiB apart, which camp on the same DRAM channels on gfx11 APUs: 5.58 ms (30 GB/s) at 8k tokens, 0.85 ms heads first, bit-identical output. CUDA keeps its order. - model.py: FlintModel takes EagleModelMixin and records the residual stream after the layers the draft names (DFlash 2: target_layer_ids + 1 = 6, 16, 27, 37, 47); FlintForCausalLM declares SupportsEagle3, so incoai/Flint-DFlash2 runs as a dflash draft. Verify batches go through the non-FlashInfer attention with sinks, as plain decode does. HawkBearPig/flint-FP8-BF16 on gfx1151 with libstrix: greedy output follows the checkpoint's reference generations (token ids it ships for four prompts) - three of four in full, the fourth diverging where the model's top two tokens are 0.08 nats apart. With the DFlash 2 draft (int8 KV, 8 prompts, greedy, 256 tokens), output tok/s at 1 request / 8 at once and mean tokens accepted per step: no draft 62.2 / 135.8 2 tokens 69.3 / 138.1 (2.28) 3 tokens 71.8 / 137.2 (2.67) 5 tokens 52.0 / 137.0 (3.04) 7 tokens 54.7 / 125.4 (3.27) Every configuration matches the no-draft output except at near-ties (largest baseline top-1/top-2 gap at a divergence 0.63 nats). A longer verify batch reads more of the 256 experts per step than its extra accepted tokens pay for. GSM8K (n = 250, greedy, 768 tokens), one request at a time: 196 without the draft, 200 with 3 draft tokens; 12 / 16 discordant, McNemar p = 0.57.
Overview
Adds Recursive's Flint, a MoE model with 40B total and 2.5B active parameters, with day-0 support for both released checkpoints:
RecursiveSI/flint: BF16 safetensors;RecursiveSI/flint-nvfp4-gguf: an NVFP4 GGUF, served weight-only (W4A16).The model lives in
vllm/models/flint/, together with Flint-specific kernels for small-batch decode on a single Blackwell GPU.Claims
Architecture: 49 layers.
NVFP4 GGUF:
--hf-config-path,--tokenizer).gguf>=0.19.0.Numerics: the kernels follow the reference implementation's rounding points.
Speed: single-GPU (TP=1) forward time on GB200 with 100K tokens of context, from
vllm bench forward.Served end to end, batch-1 NVFP4 decode at 100K context takes 2.06 ms per token (about 485 tokens/s).
Kernels:
Fallback: other configurations use vLLM's standard layers: TP > 1, EP, and GPUs outside the SM100 family such as sm_120.
Serving: tool calling and reasoning use the existing
glm47parsers; see the recipe inrecipes/models/RecursiveSI/flint.yaml.Validation
Accuracy was measured on the development branch, which has the same model code as this PR, on one GB200 with the default sampling settings (temperature 1.0, top-p 0.95, top-k 20):
tests/models/flint/covers each kernel against a reference implementation, plus the GGUF repack. It runs in one new B200 CI step.pytest tests/models/flint: 165 passed, 1 skipped.Details
docker/Dockerfile: installsgguf>=0.19.0in thevllm-openaiimage, so the NVFP4 GGUF checkpoint loads out of the box.maybe_override_with_speculators: skips speculators detection for a single local file, so a.ggufpath can be passed as--model.--exclude-tools-when-tool-choice-none,--hf-config-pathand--tokenizer; the recipe setsVLLM_USE_RUST_FRONTEND=0.Pull Request Checklist
I used vLLM's
/pr-checklistskill. (Mandatory for agents, optional for humans).AI assistance was used during the creation of this PR.
Design Fit: Minimizes impact on core components, reuses existing functionality, and justifies added complexity.
Testing and Validation: Validates the change and ensures any added tests are meaningful and reliable, with CI coverage or documented CI resource constraints and validation performed outside CI.
Code Quality and Style: Keeps code and comments clear and concise, and updates relevant documentation and examples.
Pull Request Contents: Includes a brief summary and relevant links, supports claims with evidence, explains root causes and implementation trade-offs, and follows the contributing guide.
π€ Generated with Claude Code