File size: 5,389 Bytes
74983fc | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 | ---
license: mit
library_name: gguf
base_model: deepseek-ai/DeepSeek-V4-Flash-0731
base_model_relation: quantized
tags:
- gguf
- deepseek-v4
- dspark
- speculative-decoding
- draft-model
- auxiliary-model
---
# DeepSeek V4 Flash 0731 DSpark Drafter GGUF
This repository contains only the **DSpark auxiliary drafter** extracted from
DeepSeek V4 Flash 0731. It is not a standalone language model and does not
contain the target model weights.
The GGUF is built from the official
[`deepseek-ai/DeepSeek-V4-Flash-0731`](https://huggingface.co/deepseek-ai/DeepSeek-V4-Flash-0731)
checkpoint using the standalone Python scripts included here. The complete
source manifest, build recipe, structural parser, numeric verifier, dependency
pin, and build results are published alongside the artifact.
## Artifact
| File | Bytes | SHA-256 |
|---|---:|---|
| `DeepSeek-V4-Flash-0731-DSpark-Drafter-MXFP4-Q8_0.gguf` | 10,897,110,272 | `5c8a1ce75e4797c170e22ac65080281a1b694c77f2e4fa7a703fbf09c5de0e33` |
The artifact uses GGUF v3 with the custom architecture
`deepseek_v4_flash_dspark_draft` and contains 81 tensors:
| Output type | Tensors | Transformation |
|---|---:|---|
| F32 | 45 | BF16 expanded exactly to F32, or source F32 bytes preserved |
| F16 | 2 | BF16 Markov heads rounded to F16 |
| Q8_0 | 25 | FP8 E4M3 weights with E8M0 block scales dequantized, then quantized to Q8_0 |
| MXFP4 | 9 | Routed-expert FP4 nibbles and E8M0 scales repacked without requantization |
The MXFP4 transformation is bit-preserving. Q8_0 and F16 transformations are
lossy and are checked against explicit numeric error bounds. This repository
does not claim that the complete conversion is lossless.
## Pinned source
- Repository: `deepseek-ai/DeepSeek-V4-Flash-0731`
- Revision: `9e165c30e2704aec5d9d593cce3eebd58bbef1cb`
- Input: only safetensors shards 46, 47, and 48
- Total source size: 10,863,342,388 bytes
Exact file sizes and SHA-256 values are in
[`manifest/source.json`](manifest/source.json). The downloader and converter
refuse any source that does not match them.
## Reproduce
The reference build used Linux aarch64, Python 3.14.6, NumPy 2.5.1, uv 0.11.29,
and Hugging Face CLI 1.24.0. The NumPy wheel is pinned by hash in
`requirements-linux-aarch64-py314.lock`. The upstream checkpoint is public, so
a Hugging Face token is not required for source download.
```bash
uv venv --python 3.14.6 .venv
uv pip install --python .venv/bin/python \
--require-hashes --only-binary=:all: \
-r requirements-linux-aarch64-py314.lock
.venv/bin/python scripts/download_sources.py --destination sources
.venv/bin/python -m unittest discover -s tests -v
.venv/bin/python scripts/reproduce.py \
--sources sources \
--recipe mxfp4-q8_0 \
--manifest-dir manifest \
--repeat-check
sha256sum -c SHA256SUMS
```
`--repeat-check` performs a second clean conversion and requires its complete
GGUF SHA-256 to match the verified first build byte for byte. The converter
memory-maps the source shards and processes FP8 tensors in bounded bands. It
does not require PyTorch, CUDA, safetensors, a GGUF package, or a GPU.
## Verification
The included verifier checks pinned source hashes and tensor inventories, GGUF
structure and metadata, exact F32/F16 bytes, exact MXFP4 repacking, and Q8_0
encoding plus reconstruction error against a fresh FP8 source decode.
Reference-build results:
| Check | Result |
|---|---:|
| Tensor count | 81 |
| Exact F32/F16 tensors | 47 |
| Exact MXFP4 tensors | 9 |
| Maximum Q8_0 block-relative error | 0.00396728515625 |
| Q8_0 limit | 0.01 |
| Repeat build | byte-identical |
Machine-readable observations are in
[`manifest/validation.json`](manifest/validation.json) and
[`manifest/build.json`](manifest/build.json).
## Compatibility and limitations
- This is an auxiliary drafter, not a complete checkpoint.
- A consumer must explicitly support the
`deepseek_v4_flash_dspark_draft` GGUF architecture and `dspark.*` tensor
namespace defined by the checked-in recipe.
- Generic GGUF support alone is insufficient. No compatibility with llama.cpp,
Ollama, LM Studio, vLLM, or other runtimes is implied.
- The drafter must be paired with a compatible DeepSeek V4 Flash 0731 target
model. No universal quality, acceptance-rate, or speed claim is made across
target quantizations or runtimes.
- This is a community conversion, not an official DeepSeek release or
endorsement.
## DSpark configuration
The pinned source configuration defines block size 5, target layers 40, 41,
and 42, Markov rank 256, hidden size 4096, and vocabulary size 129,280. These
values are embedded in the GGUF metadata and validated during the build.
## License and references
The source-derived weights remain under DeepSeek's MIT terms in
[`LICENSE`](LICENSE). The newly authored conversion and verification scripts
are under [`LICENSE.code`](LICENSE.code). The pinned checkpoint's
[upstream license](https://huggingface.co/deepseek-ai/DeepSeek-V4-Flash-0731/blob/9e165c30e2704aec5d9d593cce3eebd58bbef1cb/LICENSE)
and the DS4/GGML attribution in
[`THIRD_PARTY_NOTICES.md`](THIRD_PARTY_NOTICES.md) provide the applicable notices.
- [Official DeepSeek V4 Flash 0731 checkpoint](https://huggingface.co/deepseek-ai/DeepSeek-V4-Flash-0731)
- [DeepSeek V4 technical report](https://arxiv.org/abs/2606.19348)
- [DeepSpec](https://github.com/deepseek-ai/DeepSpec)
|