GitHub Repo Kalibrated-DeepSeek-V4-Flash-Vision-One-DGX-Spark
This is a serving recipe for DeepSeek-V4-Flash-Vision-Exp (the abliterated variant) on a single GB10, and a new EXL3 pack for it, Kalibrated Vision Exp, built on vcruz305’s MixedK pack.
Install
git clone https://github.com/GaelicThunder/DeepSeek-V4-Flash-Vision-One-DGX-Spark
cd DeepSeek-V4-Flash-Vision-One-DGX-Spark
./start.sh
It downloads the ready-to-serve pack (106 GB, public, not gated), starts the engine, waits for /v1/models and prints a test request. No image rebuild and no CUDA compile: it is the sparkinfer image the MiaAI-Lab recipe uses for the text model, with vLLM’s DeepSeek-V4 vision support (PR #54566) mounted over it as a read-only overlay of 26 Python files. PACK=mixedk ./start.sh takes the other route: vcruz305’s pack downloaded and converted on the Spark (~30 min).
What you get on one Spark
| measured | |
|---|---|
| context | 245,760 tokens per request (KV pool 269k tokens at utilization 0.925) |
| images | same endpoint (image_url), 1 to 3 images per prompt verified |
| decode, DSpark K5 draft | 37.6 tok/s code · 34.1 counting · 19.7 free prose with thinking (medians of 3) |
| CUDA graphs | captured (PIECEWISE + FULL), not enforce-eager |
| weights resident | 100.08 GiB, 28 s warm load (the first boot compiles ~10 min of kernels) |
The pack: Kalibrated Vision Exp
vcruz305’s MixedK is all 256 routed experts at 2-bit trellis with six layers at 3-bit, ~95 GB. Kalibrated adds 22 more expert layers re-quantized at a calibrated 3-bit (28 of 43), all 256 experts kept, the layers chosen by their measured quantization error. Everything else — the other 15 expert layers, attention, indexer, shared experts, router, head, vision tower, draft plan — is his files, unchanged. The K in the name is MixedK’s.
How much of the original model each single-Spark pack keeps: the geometric mean, over 64,859 frozen tokens (wikitext · gsm8k · code), of the probability the pack gives the true next token divided by the probability the original-precision release gives it (FP8 attention + MXFP4 experts, served on two Sparks). 100 % is the original.
| % of the original’s token probability kept | prose | math | code | all |
|---|---|---|---|---|
| Kalibrated Vision Exp | 87 % | 99.8 % | 92 % | 90 % |
| MixedK (vcruz305) | 76 % | 94 % | 85 % | 81 % |
| 216-expert 3-bit REAP build of the same model | 57 % | 98 % | 94 % | 70 % |
Paired on the same tokens, Kalibrated − MixedK is −0.133 ± 0.005 nats on prose, −0.062 ± 0.008 on math, −0.081 ± 0.005 on code. MMLU-Pro (251 items, two option orders): 63.2 % vs 64.3 %, a tie within the harness noise of ±1 item. Decode is ~8 % slower per step than MixedK (the promoted layers read 1.5× the bytes), 37.6 vs 37.5 tok/s on code thanks to a slightly higher acceptance.
A caveat on comparisons. The 0731 text packs (0xSero / MiaAI-Lab) are a different base model (DeepSeek-V4-Flash-0731, text only). The repo compares them only with that caveat, and never as a quantization comparison.
Why it works
Measured on this model with byte-identical weights: pruning 40 of the 256 experts (the REAP keep list) costs 76 → 52 % on prose, and 3-bit on the remaining 216 gives back only 52 → 57 %. Keeping the experts and spending the bits on the sensitive layers gives 87 %. The memory for those bits comes from the runtime: with the non-expert tensors in FP8 and CUDA graphs, about 16 GiB more are free than on the PyPI vLLM + plugin stack, spent here on expert bits rather than on a bigger KV pool (269k tokens instead of 986k; one full-length request still fits). A 256-expert pack at 3-bit on all 43 layers (~111 GiB of experts) would not leave room for a KV cache.
The layer choice was checked by measurement: swapping the four lowest-ranked promoted layers for four spare converted ones changes nothing (−0.001 nats, noise), swapping four mid-ranked ones costs +0.011, swapping the top four costs +0.017. The ranking holds.
Things to know
- One request at a time (the DSpark draft runs with
MAX_NUM_SEQS=1); concurrent clients queue. - Never set the GPU memory utilization above 0.93 on 128 GB: the driver starves before the kernel and the box can hard-lock.
start.shruns a smallMemAvailablewatchdog that stops the container first. Page cache counts on unified memory:DROP_CACHES=1before a boot if the previous model is still cached. - The stack occasionally emits the token
)Skipat clause ends. It is a decode-path logits fault (prefill scores the token p 0.007, decode p 0.15 on the same prefix), not sampling;start.shputs a proxy in front of the engine that adds"bad_words": [")Skip", ",Skip", ".Skip"]to every request. The root cause is still open and documented in the repo. - Every number has a receipt in
receipts/, and the studies behind the pack are indocs/KALIBRATED.md: the original-precision reference, experts-versus-bits with identical weights, the 216-expert engine path verified bit-exact against a float reference, the layer choice, a draft-depth sweep (deeper drafts are slower here), and a retraction of an earlier “pruning is free” result.
Links
- Recipe (Apache-2.0): GitHub - GaelicThunder/DeepSeek-V4-Flash-Vision-One-DGX-Spark: DeepSeek-V4-Flash-Vision-Exp (EXL3 MixedK, 256 experts, uncensored) on one NVIDIA DGX Spark with vLLM + sparkinfer: 245,760 context, vision + DSpark speculative decoding, CUDA graphs. Recipe, overlay patches, benchmarks, receipts. · GitHub
- Pack, ready to serve: GaelicThunder/DeepSeek-V4-Flash-Vision-Exp-ablit-EXL3-Kalibrated · Hugging Face
- Model: deepseek-ai/DeepSeek-V4-Flash-Vision-Exp · Hugging Face (DeepSeek)
- Abliterated source: drowzeys/keys-DeepSeekV4Flash-Vision-EXP-ablit · Hugging Face (drowzeys)
- MixedK pack and recipe: vcruz305/DSV4-Flash-Vision-ablit-EXL3-MixedK · Hugging Face · GitHub - vcruz305/DeepSeek-V4-Flash-Vision-EXL3-MixedK-DGX-Spark-recipe: Serve DeepSeek-V4-Flash-Vision EXL3 MixedK (full 256 experts) on one NVIDIA DGX Spark with vLLM — recipe, loader patches, and receipts · GitHub (vcruz305)
- Single-Spark text recipe and the DSpark draft: GitHub - MiaAI-Lab/DeepSeek-v4-Flash-One-DGX-Spark: DeepSeek v4 Flash EXL3 on one DGX Spark · GitHub (MiaAI-Lab)
- sparkinfer image and the rank-sliced tp1 layout: 0xSero/deepseek-v4-flash-0731-spark · Hugging Face ·
ghcr.io/0xsero/deepseek-v4-flash-0731-spark-sparkinfer(0xSero) - EXL3 and the converter: GitHub - turboderp-org/exllamav3: An optimized quantization and inference library for running LLMs locally on modern consumer-class GPUs · GitHub (turboderp)
- Vision model implementation: [New model][Multimodal] Add DeepSeek-V4-Flash-Vision-Exp support by Isotr0py · Pull Request #54566 · vllm-project/vllm · GitHub (vLLM)
Credits
vcruz305 first: this is his MixedK pack with 22 layers added, and if he wants them folded into MixedK they are his to take, same format, same layout, same license. His recipe found the same load_weights bug on the same day, which is the best kind of confirmation. DeepSeek for the model; drowzeys for the abliteration; 0xSero for the sparkinfer image and the tp1 layout; MiaAI-Lab for the single-Spark recipe this one mirrors, install included; turboderp for EXL3 and a converter that takes a per-tensor recipe and resumes from a checkpoint.
