Skip to content
ginsberg.si

Decisions in Practice · Part 1 of 2

Four bits, one GPU: NVFP4 deciders and a Rust harness

Quantizing pplx-decider v1.1 and v1.2 to NVFP4 so a 27B decider fits one RTX 5090, and serving it from hand-written CUDA kernels called from Rust.

17 Nov 2026

Four bits, one GPU

Decision Models ended with a “build your own” path (Part 8). This companion series follows one person down it. Richard quantized Perplexity's pplx-decider-v1.1-27b and pplx-decider-v1.2 to NVFP4 in October, then wrote decisions-rust, a server that runs the forward pass as hand-written CUDA kernels called from Rust instead of PyTorch.

A decider stops after prefill: it reads the prompt once and turns the last hidden state into probabilities over a fixed set of answers, with no decode loop (Part 1). That makes it a good fit for low precision. The question is whether 27 billion parameters fit on one consumer card. In BF16 the v1.1 checkpoint's shards are 52.17 GB (48.59 GiB)independently measured. Richard's NVFP4 checkpoint is 25.16 GB (23.43 GiB)independently measured, which is 48.2%our arithmetic of BF16. Once the Rust server has converted a few layers at load, about 19.6 GBour arithmetic of weights sit on a 32 GBvendor-claimed RTX 5090.

Labels used throughout: vendor-claimed (NVIDIA, the OCP spec, model cards, project files), independently measured (Hugging Face and Docker Hub metadata), measured by Richard (the decisions-rust README's RTX 5090 runs), our arithmetic, not published and secondary. Pages were fetched 17 November 2026, about 11:40 PM–midnight ET.

NVFP4, MXFP4 and FP8

All three formats solve the same problem. A 4-bit (or 8-bit) number can't cover the range of a weight matrix on its own, so groups of values share a scale. They differ in the size of the group and in how precisely the scale is stored.

ElementE2M1: 1 sign, 2 exponent, 1 mantissa bit; values 0, 0.5, 1, 1.5, 2, 3, 4, 6
Block16 values
ScaleFP8 E4M3 per block, plus one FP32 scale per tensor
Bits per value4.5vendor-claimed NVIDIA: “one 4-bit value plus minor overhead of one FP8 scale per 16 values (4.5 bits per value)”.
Tensor coresBlackwell (fifth-generation Tensor Cores)
Sourcedeveloper.nvidia.com
NVFP4 decoding, per NVIDIA: each 4-bit value times its block's FP8 scale, under a per-tensor FP32 scale. MXFP4 has a power-of-two block scale and no tensor scale.

NVFP4 (NVIDIA): E2M1 values (magnitudes 0, 0.5, 1, 1.5, 2, 3, 4, 6), one E4M3 scale per 16 valuesvendor-claimed, and one FP32 scale per tensor, for 4.5 bits per valuevendor-claimed. NVIDIA puts the memory saving at about 3.5× vs FP16 and 1.8× vs FP8vendor-claimed. MXFP4 (OCP MX v1.0): the same E2M1 element, but a 32-valuevendor-claimed block and an E8M0vendor-claimed scale, a pure power of two, so 4.25 bits per valueour arithmetic. FP8 E4M3: 8 bits per value, three mantissa bits, largest normal ±448, with a scale per tensor or per row.

cuBLAS exposes the two block formats as separate scaling modes: VEC16_UE4M3 for FP4 and VEC32_UE8M0 for FP8 block scaling (cuBLAS docs). The PTX ISA has a matching kind::mxf4nvf4 tensor-core instruction and defines ue4m3 and ue8m0 scale types. NVIDIA's case for NVFP4 over MXFP4 is the smaller block and the finer scale. A power-of-two scale can only land on the nearest 2n, and a large value in a 32-value block squashes 31 neighbours instead of 15.

Values
Show
Grey: the original magnitudes. Colour: after quantizing and decoding. The shaded half is NVFP4's second 16-value block.
FormatBlock scale(s)Bits / valueMean squared errorNon-zero values flushed to 0
NVFP4E4M3 448.0 ÷ FP32 6720 · E4M3 44.00 ÷ FP32 67204.53.73e-57 of 32
MXFP4E8M0 2^-44.258.36e-512 of 32
FP8 (E4M3)FP32 0.000892985.29e-70 of 32
E2M1 can only say 0, 0.5, 1, 1.5, 2, 3, 4, 6 (and their negatives), so the block scale decides everything. NVFP4 picks an FP8 (E4M3) scale per 16 values, under a per-tensor FP32 scale; MXFP4 picks a power of two per 32 values (E8M0), as the OCP MX spec defines; FP8 keeps three mantissa bits but needs 8 bits per value. Push the outlier up and watch the small values in its block collapse to zero; with NVFP4 the other block is untouched. Rounding follows the cuBLAS block-quantization steps; errors are our arithmetic on these 32 sample values, not on the model.

NVIDIA's accuracy evidence (DeepSeek-R1-0528 within about 1% of FP8 on its evaluations) is vendor-claimed and isn't about deciders. It suggests what to expect, but it isn't a measurement of these models.

What four bits buy on Blackwell

Four bits pay twice on Blackwell. There are fewer bytes to stream: every pass reads every weight once. And there's faster arithmetic: the fifth-generation tensor cores multiply FP4 natively, with the block scales applied in hardware (NVIDIA calls this micro-tensor scaling). The RTX Blackwell whitepaper lists the RTX 5090 at 1,676 dense FP4 TFLOPSvendor-claimed, 419 FP8 (FP32 accumulate)vendor-claimed, 209.5 BF16vendor-claimed and 1,792 GB/svendor-claimed. The spec page's “3,352 AI TOPS” is the FP4 figure with sparsity.

Which advantage matters depends on the length of the pass. A matmul reads its weights once and does 2 × parameters × tokens operations. Below a certain token count, the weight read takes longer than the arithmetic. For NVFP4 on a 5090 that crossover is about 263 tokensour arithmetic. Short decider prompts are bandwidth-bound, so the 4.5-bit bytes are what help. Long ones are compute-bound, so the FP4 rate is what helps.

Tokens in the pass
MLP + attention:
DeltaNet:
MLP + full attention in NVFP4 · 18,790,481,920 parameters · compute-bound
tensor-core floor
76.2 ms
weight-read floor
5.9 ms
Crossover: about 263 tokens; below it, the bytes of the weights set the pace, above it the NVFP4 tensor-core rate does.
DeltaNet qkv / z / out in FP8 (E4M3) · 5,536,481,280 parameters · compute-bound
tensor-core floor
89.9 ms
weight-read floor
3.1 ms
Crossover: about 117 tokens; below it, the bytes of the weights set the pace, above it the FP8 (E4M3) tensor-core rate does.
166.1 ms
Matmul floor, this pass
our arithmetic from peak specs
266 ms
Measured whole pass, 3,400 tokens
measured by Richard (Rust, RTX 5090)
Floors are our arithmetic: compute = 2 × parameters × tokens ÷ dense peak; weight-read = bytes ÷ bandwidth. They leave out attention scores, the delta rule, elementwise kernels and launch gaps, so a real pass is slower — Richard's profile puts all matmuls at 59% of a long pass. RTX Blackwell whitepaper, Appendix A (GB202 / RTX 5090): dense peaks — FP4 1,676 TFLOPS (3,352 “AI TOPS” with sparsity), FP8 419 with FP32 accumulate (838 with FP16 accumulate), BF16 209.5 with FP32 accumulate; 1,792 GB/s.vendor-claimed The README doesn't say which FP8 accumulate mode cuBLASLt picks here.

At 3,400 tokens the NVFP4 matmuls have a floor of ≈ 76 msour arithmetic. Run the same layers in FP8 and the floor becomes ≈ 305 msour arithmetic, more than Richard's whole measured pass of 266 msmeasured by Richard. For the B200 we divided the DGX B200 figures by eight: about 9 PFLOPS FP4, 4.5 PFLOPS FP8, 8 TB/s, 180 GBour arithmetic per GPU.

The recipe, and what stays BF16

Every quant used the same llm-compressor recipe (recipe.yaml):

QuantizationModifier:
  targets: [Linear]
  ignore: ['re:.*visual.*', 're:.*linear_attn.*']
  scheme: NVFP4
  requires_calibration_data: true

The config.json records the result in compressed-tensors format (nvfp4-pack-quantized). Weights are FP4 in groups of 16 with E4M3 scales. Activations are also FP4, with dynamic local scales computed at run time. The KV cache isn't quantized, and 350 modules are on the ignore list vendor-claimed. The calibration dataset and sample count aren't recorded anywhere not published.

DeltaNet stays BF16. In Qwen3.8-27B, 48 of the 64 layers are Gated DeltaNet layers (Part 6), and their projections hold 5,560,074,240 parametersour arithmetic, 21% of the model. In BF16 they take 11.12 GBour arithmetic; in NVFP4 they would take about 3.13 GBour arithmetic. The recipe doesn't say why they were left alone. It is the same ignore list llm-compressor ships in its own Qwen3.5 and Qwen3-Next NVFP4 examples (re:.linear_attn.), which don't explain it either not published. A plausible reason, and only our reading: these projections feed a recurrence that carries state across the whole prompt, so errors can compound rather than stay local.

The vision tower stays BF16, as llm-compressor's guidance says to do for vision towers. It is small: 460,730,096 parametersour arithmetic, under 2% of the model. Quantizing it would save about 0.66 GBour arithmetic. Embeddings and norms aren't Linear layers, so targets: [Linear] never touches them. The 255-row decision head ships separately in readout.safetensors, still in BF16 (2.6 MB).

Fitting a 27B decider on one RTX 5090

Toggle each layer group between formats and compare the total with an RTX 5090 and a B200. The groups come from the checkpoint's own safetensors headers, and their parameters sum exactly to Part 6's 26,085,330,160independently measured.

Preset
Layer groupParametersFormatGB
MLP (gate, up, down) × 64 layers
5120 → 17408 → 5120 in every layer
17,112,760,320
as in the checkpoint
9.63
Full attention (q, k, v, o) × 16 layers
the noncausal layers, every fourth
1,677,721,600
as in the checkpoint
0.94
Gated DeltaNet projections × 48 layers
in_proj_qkv, in_proj_z, out_proj, in_proj_a, in_proj_b
5,560,074,240
as in the checkpoint
11.12
Token embeddings
[248320, 5120]
1,271,398,400
as in the checkpoint
2.54
Vision tower (27 blocks + merger)
460,730,096 parameters, 457,666,560 of them in Linear layers
460,730,096
as in the checkpoint
0.92
Norms, conv, gates' biases
RMSNorm weights, DeltaNet conv1d, A_log, dt_bias, head norms
2,645,504
as in the checkpoint
0.01
Weights on the GPU: 25.16 GB (23.43 GiB), 48.2% of BF16
GeForce RTX 5090 · 32 GB
6.8 GB left
B200 (one GPU of a DGX B200) · 180 GB
154.8 GB left
Group sizes are our arithmetic from the v1.1 NVFP4 checkpoint's safetensors headers; they sum to Part 6's 26,085,330,160 parameters. A format that matches the checkpoint uses its stored bytes; any other is parameters × bits ÷ 8 (NVFP4 4.5, MXFP4 4.25, FP8 8, BF16 16), ignoring per-tensor scalars. The 2.6 MB readout head is added. Weights only: activations and the server's workspace are not published, and the server keeps 4 GiB of headroom before it loads embeddings and vision. RTX 5090: 32 GB vendor-claimed; B200: 180 GB our arithmetic (DGX B200's 1,440 GB ÷ 8).

BF16 doesn't fit. Richard's checkpoint is 25.16 GBindependently measured. As the Rust server holds it, it is about 19.6 GBour arithmetic, leaving roughly 12 GB for activations and workspace. An all-FP8 model (about 26.1 GBour arithmetic) would also squeeze in on paper, with about 6 GB to spare. So four bits aren't strictly what makes it fit. They're what leaves room for long batches (the default allows 16,384 tokens per batch), and what unlocks the FP4 tensor cores. If free memory is short, the server switches to a low-memory mode: embeddings on the CPU and no vision tower (device.rs).

The shelf: October 5 to November 1

The Perplexity quants came within days of each release: v1.1 about three days after Perplexity published it, v1.2 about 2.7 days after. The two NVFP4 repos have byte-identical shard sizes but different hashes independently measured, because it's the same recipe on the same architecture with different weights. v1.2 is the checkpoint the Rust harness serves. Click any point.

Oct 5
Oct 12
Oct 19
Oct 26
Nov 2
Richard's quant · 2026-10-08 3:16 PM EDT
The first quant: llm-compressor NVFP4, ignoring the vision tower and the DeltaNet projections. The card's heading is Richard's; the body is Perplexity's card.
25,159,582,040 bytes (23.43 GiB)
NVFP4 shards
independently measured
48.2%
Share of BF16
our arithmetic
about 3 days
After upstream
our arithmetic
109
Downloads (17 Nov)
independently measured
Dates and times are ET, converted from the Hugging Face, GitHub, Docker Hub and RunPod timestamps; US daylight time ended on 1 Nov. Download counts are the Hub's rolling count on 17 Nov independently measured. Only work before 17 Nov is shown.

Other deciders I quantized (all Apache-2.0, same tooling):

QuantUpstreamBasePublished
d3-NVFP4vllm-sr/d3Qwen3.8-27B11 Oct 2026
d3-turbo-NVFP4vllm-sr/d3-turbonot declared (Qwen3_5Model)20 Oct 2026
KnowLine-31B-Gen1-NVFP4PelaAI/KnowLine-31B-Gen1Gemma-4-31B-it1 Nov 2026

Why a Rust harness

The README gives the reason: the Python server launches “~1,500 small kernels per pass”, pads mixed-length batches, and re-tunes Triton kernels “for minutes at every start” vendor-claimed. decisions-rust keeps that server's HTTP contract (/v1/systemone and /v1/decisions, Bearer auth, the same response) and replaces everything below it:

  • A token-exact protocol port. The prompt builder is checked against 156 requests recorded from the Python encoder.
  • Packed sequences and continuous batching, so there's no padding to compute.
  • Fused quantization. RMSNorm, residual add and SiLU-gate are fused with the NVFP4 or FP8 activation quantization that follows them.
  • cuBLASLt for the NVFP4 block-scaled and FP8 matmuls, with plans cached per shape, algorithms autotuned at warm-up, and the tuned choices kept on the volume.
  • Non-causal attention. pplx-decider lifts the causal mask in its 16 full-attention layers (Part 6), so a stock causal kernel would give wrong answers.
  • The gated delta rule on the tensor cores, in flash-linear-attention's three-kernel structure.
  • CUDA graphs of the text layers, one per warmed bucket, replacing “some 700 kernel launches”.

It runs on Blackwell only: the image builds for sm_100 (B200/B300) and sm_120 (RTX 5090, RTX PRO 6000). All 23 commits landed between 4:19 PM and 11:04 PM EDT on 31 October.

Is it faithful, and is it fast?

Richard checked the port with compare_servers.py, which sends the same decisions to both servers. It fails if any top answer changes or if a probability moves more than 0.2. He also checked accuracy on 316 labeled decisions. Speed is reported as server-side medians on one RTX 5090.

135 tokens · CUDA-graph replay
Rust
22 ms
150 tokens · 1.3× faster
Rust
30 ms
Python server
40 ms
1,000 tokens · 1.8× faster
Rust
79 ms
Python server
143 ms
3,400 tokens · 2.0× faster
Rust
266 ms
Python server
~540 ms
Server-side medians on one RTX 5090, proxy excluded, both servers on the same NVFP4 v1.2 checkpoint measured by Richard. Speed-ups are our arithmetic. Richard also reports many-question medium requests at “about 2×”. Source: the README's Phase 3 section.

The headline numbers, all measured by Richard: 315/316measured by Richard decisions agree with Python; 96.2% vs 96.5%measured by Richard accuracy; 266 ms vs ~540 msmeasured by Richard on a 3,400-token pass; 22 msmeasured by Richard on a 135-token pass; ~80 smeasured by Richard startup. The RunPod page sums it up as “roughly 2× on many-question requests and ~50% on long single-question passes”. Read the second figure as about half the time, which is what 266 vs ~540 ms means.

Run it yourself: Docker and RunPod

The image is aigpu/decide-in-rust: 16 tags from 1.0.0 to 1.3.3, pushed on 31 October, each about 1.99 GBindependently measured compressed, linux/amd64 only, with no latest tag. The runtime stage has Python and huggingface_hub to fetch the checkpoint, and no torch. The RunPod template (“Rust Decider - pplx-decider-v1.2-NVFP4”) uses image 1.3.3 with a 30 GBvendor-claimed volume and a 5 GB container disk. The first start downloads about 25 GB to the volume. The request body is the same /v1/systemone shape as Part 8's request builder (Part 8).

# RunPod template: image aigpu/decide-in-rust:1.3.3, volume 30 GB at /workspace, container disk 5 GB, HTTP port 8000
AUTOJEV_API_KEY=<your-key>
DECISION_MODEL_ID=machinez/pplx-decider-v1.2-NVFP4
DECISION_MODEL_REVISION=fdeb7a9694eb633c29103f7a39181f0bda2fa0f9
No warnings for this combination.
Then ask it something
curl -s https://<pod-host>:8000/v1/systemone \
  -H "Authorization: Bearer $AUTOJEV_API_KEY" -H "Content-Type: application/json" \
  -d '{"state": "My integration keeps failing. Please help.",
       "questions": {"kind": {"type": "choice", "instructions": "What kind of request is this?",
                              "criteria": {"bug": "Something is broken", "billing": "Money or invoices", "other": "Anything else"}},
                     "needs_engineer": {"type": "noul", "instructions": "Does this need an engineer to look at it?"}}}'
Defaults from the README and Dockerfile at 79dc968: the image bakes in v1.2 at revision fdeb7a9, port 8000, a 32,768-token max length, 16,384 batch tokens.fetch_model.py requires joint_config.json, which only v1.2 among these repos has. Which tag first carries a knob is our arithmetic: the commit that added the variable, paired with the next tag by push time (the repo has no git tags). The template's GPU and env values aren't public not published. Never paste a real key into a page or a shared template.

What we don't know yet

  • NVFP4 vs BF16 accuracy, for any of the quants not published No card, config or README states one. The 96.2% / 96.5% figures compare two servers on the same NVFP4 checkpoint.
  • Calibration data and sample count not published recipe.yaml says requires_calibration_data: true but names no dataset.
  • The 316 labeled decisions not published The set is not in the repo, so the agreement can't be re-run by readers.
  • Python vs Rust per-item probabilities not published Only the summary (max 0.07, mean 0.02 in Phase 2) is published.
  • GPU memory used at runtime (activations, workspace) not published The fit explorer counts weights only; the server keeps 4 GiB headroom before loading embeddings and vision.
  • Which pass length the time profile describes not published README: “a long pass”.
  • Why the recipe keeps DeltaNet in BF16 not published The ignore list matches llm-compressor's own Qwen3.5 / Qwen3-Next examples, which don't give a reason either.

So is NVFP4 good enough for a decider?

Answer. Probably close, but nobody has shown it for these models. Running the same 316 decisions on the BF16 checkpoint would answer it for this set. On a 32 GB card that means a bigger GPU, or the Python server on something like a B200.

Why not just use FP8 everywhere?

Answer. It fits on paper (about 26 GB of weights), but it leaves about 6 GB for everything else, and FP8 runs at a quarter of the 5090's dense FP4 rate (419 vs 1,676 TFLOPS with FP32 accumulate). On our arithmetic, the MLP alone would need about 305 ms of compute at 3,400 tokens.

Does this work with v1.1, d3 or KnowLine?

Answer. Not with this server before 17 November. It needs a protocol-3 checkpoint with joint_config.json, and among these repos only v1.2 has one.

Next: when the prompt is the API

Perplexity's next version, pplx-decider v1.3, keeps the shape of the weights but changes the contract around them. That's enough to stop a server that was faithful to v1.2. Part 2 covers what broke, why it matters to anyone wrapping a decider, and how to migrate.

Part 2 also covers Locate and batch invariance.

Related reading in Decision Models:

Sources

Fetched 17 November 2026, about 11:40 PM–midnight ET. Every link was live-checked then. Repo files are linked at commit 79dc968, the last one before Part 2's scope. The Hugging Face repos: v1.1 NVFP4, v1.2 NVFP4.

  1. Introducing NVFP4 for Efficient and Accurate Low-Precision Inferencedeveloper.nvidia.com
  2. cuBLAS: 16/32-element 1D block scaling for FP8 and FP4docs.nvidia.com
  3. PTX ISA: ue4m3 / ue8m0 scale formats, tcgen05.mma kind::mxf4nvf4docs.nvidia.com
  4. OCP Microscaling Formats (MX) v1.0 specopencompute.org
  5. NVIDIA RTX Blackwell GPU architecture whitepaper (Appendix A)images.nvidia.com
  6. GeForce RTX 5090 spec pagenvidia.com
  7. NVIDIA DGX B200 specificationsnvidia.com
  8. Blackwell architecture: micro-tensor scaling, FP4nvidia.com
  9. llm-compressorgithub.com
  10. llm-compressor Qwen3.5 NVFP4 example (ignore list)github.com
  11. llm-compressor Qwen3-Next NVFP4 example (ignore list)github.com
  12. machinez/pplx-decider-v1.1-27b-NVFP4huggingface.co
  13. v1.1 NVFP4 recipe.yamlhuggingface.co
  14. v1.1 NVFP4 config.json (quantization_config)huggingface.co
  15. machinez/pplx-decider-v1.2-NVFP4huggingface.co
  16. perplexity-ai/pplx-decider-v1.1-27b (upstream)huggingface.co
  17. perplexity-ai/pplx-decider-v1.2 (upstream)huggingface.co
  18. machinez/d3-NVFP4huggingface.co
  19. machinez/d3-turbo-NVFP4huggingface.co
  20. machinez/KnowLine-31B-Gen1-NVFP4huggingface.co
  21. decisions-rustgithub.com
  22. decisions-rust README at 79dc968github.com
  23. src/cuda/device.rs at 79dc968 (FP8 at load, low-memory mode)github.com
  24. Dockerfile at 79dc968github.com
  25. scripts/fetch_model.py at 79dc968github.com
  26. scripts/compare_servers.py at 79dc968github.com
  27. aigpu/decide-in-rust on Docker Hubhub.docker.com
  28. aigpu/decide-in-rust tagshub.docker.com
  29. RunPod template 3yzxdcqbcsconsole.runpod.io