Text Generation
NInfer
qwen.83
qwen3_8
blackwell
sm120a
mtp
speculative-decoding
indexed88
vocabulary-prune
coding
agentic
nvfp4
conversational
Instructions to use Schestex/ThinkingCap-Qwen3.8-27B-NInfer with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- NInfer
How to use Schestex/ThinkingCap-Qwen3.8-27B-NInfer with NInfer:
# No code snippets available yet for this library. # To use this model, check the repository files and the library's documentation. # Want to help? PRs adding snippets are welcome at: # https://github.com/huggingface/huggingface.js
- Notebooks
- Google Colab
- Kaggle
Upload README.md with huggingface_hub
Browse files
README.md
CHANGED
|
@@ -1,214 +1,179 @@
|
|
| 1 |
---
|
| 2 |
-
|
| 3 |
tags:
|
| 4 |
-
|
| 5 |
-
|
| 6 |
-
|
| 7 |
-
|
| 8 |
-
|
| 9 |
-
|
|
|
|
| 10 |
---
|
| 11 |
|
| 12 |
-
# ThinkingCap
|
| 13 |
|
| 14 |
-
|
|
|
|
| 15 |
|
| 16 |
-
|
| 17 |
|
| 18 |
-
|
|
|
|
|
|
|
| 19 |
|
| 20 |
## Artifact
|
| 21 |
|
| 22 |
-
|
| 23 |
|
| 24 |
-
|
| 25 |
-
thinkingcap-qwen3.8-27b-d48.ninfer
|
| 26 |
-
```
|
| 27 |
|
| 28 |
-
|
| 29 |
-
|---|---:|
|
| 30 |
-
| Model | ThinkingCap-Qwen3.8-27B |
|
| 31 |
-
| Runtime format | NInfer |
|
| 32 |
-
| Variant | D48 |
|
| 33 |
-
| Artifact size | 16,705,529,348 bytes |
|
| 34 |
-
| Runtime weight capacity | 16,692,422,656 bytes |
|
| 35 |
-
| Workspace | 159,981,568 bytes |
|
| 36 |
-
| Target GPU | NVIDIA RTX PRO 4000 Blackwell 24 GB |
|
| 37 |
-
| Base NInfer recipe | `qwen3_8_27b` |
|
| 38 |
-
| Additional optimization | 48 selected MLP Down projections → NVFP4 |
|
| 39 |
|
| 40 |
-
|
| 41 |
|
| 42 |
-
|
| 43 |
-
The smaller size does not imply that this build uses a more aggressive full-model NVFP4 profile. It is a selective mixed-precision configuration optimized around the measured ThinkingCap sensitivity map.
|
| 44 |
|
| 45 |
-
|
| 46 |
|
| 47 |
-
|
| 48 |
|
| 49 |
-
|
| 50 |
|
| 51 |
-
``
|
| 52 |
-
0, 1, 4, 5, 6, 7, 9,
|
| 53 |
-
13, 14, 15, 16, 17, 19, 20, 22, 23, 24,
|
| 54 |
-
28, 29, 30, 31,
|
| 55 |
-
33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50,
|
| 56 |
-
53, 54, 55, 56, 58, 59, 60, 61, 62
|
| 57 |
-
```
|
| 58 |
|
| 59 |
-
##
|
| 60 |
|
| 61 |
-
|
| 62 |
-
|
| 63 |
-
25, 26, 27, 32,
|
| 64 |
-
51, 52, 57, 63
|
| 65 |
-
```
|
| 66 |
|
| 67 |
-
|
| 68 |
|
| 69 |
-
|
|
|
|
|
|
|
|
|
|
| 70 |
|
| 71 |
-
|
| 72 |
|
| 73 |
-
|
| 74 |
-
ThinkingCap BF16/FP16 Safetensors
|
| 75 |
-
│
|
| 76 |
-
▼
|
| 77 |
-
NInfer qwen3_8_27b recipe
|
| 78 |
-
│
|
| 79 |
-
▼
|
| 80 |
-
standard mixed-precision NInfer baseline
|
| 81 |
-
│
|
| 82 |
-
▼
|
| 83 |
-
selected MLP Down projections → NVFP4
|
| 84 |
-
│
|
| 85 |
-
▼
|
| 86 |
-
ThinkingCap D48 NInfer
|
| 87 |
-
```
|
| 88 |
|
| 89 |
-
D48
|
| 90 |
|
| 91 |
-
|
| 92 |
|
| 93 |
-
|
| 94 |
|
| 95 |
-
``
|
| 96 |
-
context: 4096
|
| 97 |
-
stride: 2048
|
| 98 |
-
KV cache: BF16
|
| 99 |
-
scored tokens: 782,535
|
| 100 |
-
streams: 12
|
| 101 |
-
```
|
| 102 |
|
| 103 |
-
|
| 104 |
|
| 105 |
-
|
| 106 |
-
|---|---:|---:|
|
| 107 |
-
| English long-form | 7.918420 | 7.944685 |
|
| 108 |
-
| English reference | 6.264029 | 6.219786 |
|
| 109 |
-
| Code | 1.651905 | 1.654696 |
|
| 110 |
-
| **Overall** | **4.351060** | **4.348019** |
|
| 111 |
|
| 112 |
-
|
| 113 |
|
| 114 |
-
|
| 115 |
|
| 116 |
-
|
| 117 |
|
| 118 |
-
|
| 119 |
|
| 120 |
-
|
| 121 |
-
|---|---:|
|
| 122 |
-
| PP512 | 1293.37 tok/s |
|
| 123 |
-
| PP2048 | 1333.02 tok/s |
|
| 124 |
-
| PP8192 | 1310.12 tok/s |
|
| 125 |
-
| TG256 | 32.46 tok/s |
|
| 126 |
-
| TG1024 | 32.03 tok/s |
|
| 127 |
-
| PP2048 + TG512 — prefill | 1323.95 tok/s |
|
| 128 |
-
| PP2048 + TG512 — decode | 31.92 tok/s |
|
| 129 |
-
| PP8192 + TG512 — prefill | 1297.68 tok/s |
|
| 130 |
-
| PP8192 + TG512 — decode | 31.43 tok/s |
|
| 131 |
|
| 132 |
-
|
| 133 |
|
| 134 |
-
|
| 135 |
|
| 136 |
-
|
| 137 |
|
| 138 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
| 139 |
|---|---:|---:|---:|
|
| 140 |
-
|
|
| 141 |
-
|
|
| 142 |
-
|
|
| 143 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 144 |
|
| 145 |
-
|
|
|
|
| 146 |
|
| 147 |
-
|
| 148 |
|
| 149 |
-
|
|
|
|
| 150 |
|
| 151 |
-
|
| 152 |
-
|
| 153 |
-
|
| 154 |
-
3. D48 quality-first Down anchor ← this release
|
| 155 |
-
4. ThinkingCap-specific IMatrix
|
| 156 |
-
5. Gate / Up sensitivity analysis
|
| 157 |
-
6. Combined mixed-precision optimization
|
| 158 |
-
7. Final task-level quality validation
|
| 159 |
-
8. MTP and/or DFlash2 integration
|
| 160 |
-
```
|
| 161 |
|
| 162 |
-
|
|
|
|
| 163 |
|
| 164 |
-
|
|
|
|
| 165 |
|
| 166 |
-
|
| 167 |
-
- Agentic-workload importance calibration
|
| 168 |
-
- dedicated Gate optimization
|
| 169 |
-
- dedicated Up optimization
|
| 170 |
-
- final Gate/Up + Down joint optimization
|
| 171 |
-
- MTP speculative decoding model
|
| 172 |
-
- DFlash2 speculative decoding model
|
| 173 |
-
- final task-level evaluation suite
|
| 174 |
|
| 175 |
-
|
|
|
|
|
|
|
| 176 |
|
| 177 |
-
|
| 178 |
|
| 179 |
-
The
|
| 180 |
|
| 181 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 182 |
|
| 183 |
-
|
| 184 |
|
| 185 |
-
|
| 186 |
-
9e163eee4b8acec21ab0ac765107b6a3f287b217
|
| 187 |
-
```
|
| 188 |
|
| 189 |
-
|
|
|
|
| 190 |
|
| 191 |
-
|
|
|
|
| 192 |
|
| 193 |
-
##
|
| 194 |
|
| 195 |
-
|
|
|
|
| 196 |
|
| 197 |
-
|
| 198 |
-
|
| 199 |
-
- mixed-precision / NVFP4 research
|
| 200 |
-
- quality/performance trade-off analysis
|
| 201 |
-
- further model-specific optimization work
|
| 202 |
|
| 203 |
-
|
| 204 |
|
| 205 |
-
|
| 206 |
-
1. Preserve model quality
|
| 207 |
-
2. Improve real inference throughput
|
| 208 |
-
3. Reduce persistent model/VRAM footprint
|
| 209 |
-
4. Keep experiments reproducible
|
| 210 |
-
```
|
| 211 |
|
| 212 |
-
|
| 213 |
|
| 214 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
---
|
| 2 |
+
library_name: ninfer
|
| 3 |
tags:
|
| 4 |
+
- ninfer
|
| 5 |
+
- qwen
|
| 6 |
+
- quantized
|
| 7 |
+
- nvfp4
|
| 8 |
+
- blackwell
|
| 9 |
+
- preview
|
| 10 |
+
license: other
|
| 11 |
---
|
| 12 |
|
| 13 |
+
# ThinkingCap Qwen3.8 27B — NInfer D48+O44 Preview
|
| 14 |
|
| 15 |
+
This repository contains a **preview NInfer quantization candidate** for
|
| 16 |
+
ThinkingCap-Qwen3.8-27B.
|
| 17 |
|
| 18 |
+
It is not yet the final quantization release.
|
| 19 |
|
| 20 |
+
The cumulative D48+O44 performance candidate has passed conversion and
|
| 21 |
+
target validation. A cumulative Full-PPL evaluation is still pending at
|
| 22 |
+
the time of this preview release.
|
| 23 |
|
| 24 |
## Artifact
|
| 25 |
|
| 26 |
+
`thinkingcap-d48-o44-preview.ninfer`
|
| 27 |
|
| 28 |
+
SHA256:
|
|
|
|
|
|
|
| 29 |
|
| 30 |
+
`db5f12b03ddc48d1776179c8564144325d967f4e5d5d36deb34e9bd70d1b5e17`
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 31 |
|
| 32 |
+
Artifact size:
|
| 33 |
|
| 34 |
+
`16,575,798,788 bytes`
|
|
|
|
| 35 |
|
| 36 |
+
Baseline artifact size:
|
| 37 |
|
| 38 |
+
`17,106,573,056 bytes`
|
| 39 |
|
| 40 |
+
Reduction versus baseline:
|
| 41 |
|
| 42 |
+
`530,774,268 bytes` (~506.2 MiB, ~3.10%)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 43 |
|
| 44 |
+
## Quantization layout
|
| 45 |
|
| 46 |
+
The candidate was converted directly from the original BF16/FP16 source.
|
| 47 |
+
It was not requantized from another `.ninfer` artifact.
|
|
|
|
|
|
|
|
|
|
| 48 |
|
| 49 |
+
It combines:
|
| 50 |
|
| 51 |
+
- **D48**: 48 selected MLP Down projections converted to NVFP4.
|
| 52 |
+
- **O44**: 44 selected output projections converted to NVFP4.
|
| 53 |
+
- 35 GDN output projections
|
| 54 |
+
- 9 Attention output projections
|
| 55 |
|
| 56 |
+
Total validated NVFP4 conversion jobs:
|
| 57 |
|
| 58 |
+
**92**
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 59 |
|
| 60 |
+
### D48 MLP Down layers
|
| 61 |
|
| 62 |
+
`0,1,4,5,6,7,9,13,14,15,16,17,19,20,22,23,24,28,29,30,31,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,53,54,55,56,58,59,60,61,62`
|
| 63 |
|
| 64 |
+
### O44 GDN Output layers
|
| 65 |
|
| 66 |
+
`0,5,9,12,13,14,16,17,18,20,22,28,32,33,34,36,37,40,41,42,44,45,46,48,49,50,52,53,54,56,57,58,60,61,62`
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 67 |
|
| 68 |
+
### O44 Attention Output layers
|
| 69 |
|
| 70 |
+
`11,19,27,31,39,51,55,59,63`
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 71 |
|
| 72 |
+
## Size impact
|
| 73 |
|
| 74 |
+
D48 artifact:
|
| 75 |
|
| 76 |
+
`16,705,529,348 bytes`
|
| 77 |
|
| 78 |
+
D48+O44 artifact:
|
| 79 |
|
| 80 |
+
`16,575,798,788 bytes`
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 81 |
|
| 82 |
+
O44 therefore removes another:
|
| 83 |
|
| 84 |
+
`129,730,560 bytes` (~123.7 MiB)
|
| 85 |
|
| 86 |
+
from the D48 candidate.
|
| 87 |
|
| 88 |
+
## Performance
|
| 89 |
+
|
| 90 |
+
The meaningful comparison below uses the same physical GPU0.
|
| 91 |
+
|
| 92 |
+
| Test | D48 | D48+O44 | Change |
|
| 93 |
|---|---:|---:|---:|
|
| 94 |
+
| pp512 prefill | 774.13 tok/s | 840.81 tok/s | +8.61% |
|
| 95 |
+
| pp2048 prefill | 782.36 tok/s | 850.04 tok/s | +8.65% |
|
| 96 |
+
| pp8192 prefill | 746.28 tok/s | 790.06 tok/s | +5.87% |
|
| 97 |
+
| tg256 decode | 18.74 tok/s | 19.06 tok/s | +1.68% |
|
| 98 |
+
| tg1024 decode | 18.28 tok/s | 18.72 tok/s | +2.44% |
|
| 99 |
+
| pp2048+tg512 prefill | 735.53 tok/s | 765.80 tok/s | +4.11% |
|
| 100 |
+
| pp2048+tg512 decode | 18.53 tok/s | 18.70 tok/s | +0.94% |
|
| 101 |
+
| pp8192+tg512 prefill | 723.44 tok/s | 754.14 tok/s | +4.24% |
|
| 102 |
+
| pp8192+tg512 decode | 18.31 tok/s | 18.52 tok/s | +1.16% |
|
| 103 |
+
|
| 104 |
+
The D48 control used 2 warmups and 3 measured repetitions.
|
| 105 |
+
The D48+O44 run used 2 warmups and 5 measured repetitions.
|
| 106 |
+
|
| 107 |
+
The result is therefore suitable as a performance screening measurement,
|
| 108 |
+
not as the final release benchmark.
|
| 109 |
+
|
| 110 |
+
Approximate mean change over the measured cases:
|
| 111 |
|
| 112 |
+
- Prefill: **+6.3%**
|
| 113 |
+
- Decode: **+1.6%**
|
| 114 |
|
| 115 |
+
## Quality status
|
| 116 |
|
| 117 |
+
The individual sensitivity sweeps used a 782,535-token English/code
|
| 118 |
+
development corpus with:
|
| 119 |
|
| 120 |
+
- context: 4096
|
| 121 |
+
- stride: 2048
|
| 122 |
+
- KV cache: BF16
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 123 |
|
| 124 |
+
D48 previously showed no measurable degradation on this development
|
| 125 |
+
corpus.
|
| 126 |
|
| 127 |
+
The individual O44 projections were selected from the completed Output64
|
| 128 |
+
sensitivity map using the `ΔNLL <= 0.0002` boundary.
|
| 129 |
|
| 130 |
+
**Important:** individual layer deltas are not assumed to add linearly.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 131 |
|
| 132 |
+
The cumulative D48+O44 Full-PPL measurement is still pending for this
|
| 133 |
+
preview. This artifact should therefore be treated as an experimental
|
| 134 |
+
performance candidate rather than the final quality-validated release.
|
| 135 |
|
| 136 |
+
## Runtime benchmark configuration
|
| 137 |
|
| 138 |
+
The throughput benchmark uses the public NInfer `ninfer_bench` route with:
|
| 139 |
|
| 140 |
+
- KV cache: FP8 E4M3 row256
|
| 141 |
+
- maximum context: 16384
|
| 142 |
+
- prefill chunk: 1024
|
| 143 |
+
- prefill tests: 512, 2048, 8192 tokens
|
| 144 |
+
- decode tests: 256, 1024 tokens
|
| 145 |
+
- combined tests:
|
| 146 |
+
- 2048 prompt + 512 generation
|
| 147 |
+
- 8192 prompt + 512 generation
|
| 148 |
|
| 149 |
+
Raw JSON benchmark reports are included in `benchmarks/`.
|
| 150 |
|
| 151 |
+
## Tokenizer and chat resources
|
|
|
|
|
|
|
| 152 |
|
| 153 |
+
Tokenizer and chat-template resources are copied from the original
|
| 154 |
+
ThinkingCap-Qwen3.8-27B source directory.
|
| 155 |
|
| 156 |
+
They are provided for use with the NInfer artifact and do not imply that
|
| 157 |
+
this repository contains Hugging Face Transformers weights.
|
| 158 |
|
| 159 |
+
## Provenance
|
| 160 |
|
| 161 |
+
The conversion was performed from the original BF16/FP16 source using a
|
| 162 |
+
local NInfer development checkout.
|
| 163 |
|
| 164 |
+
The conversion metadata, artifact checksum and available build provenance
|
| 165 |
+
are included with this preview.
|
|
|
|
|
|
|
|
|
|
| 166 |
|
| 167 |
+
## Status
|
| 168 |
|
| 169 |
+
**Preview / experimental**
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 170 |
|
| 171 |
+
Planned before the final release:
|
| 172 |
|
| 173 |
+
1. cumulative D48+O44 Full-PPL
|
| 174 |
+
2. completed Input64 sensitivity analysis
|
| 175 |
+
3. cumulative Down + Output + Input candidate
|
| 176 |
+
4. Full-PPL validation
|
| 177 |
+
5. final Prefill/Decode benchmark
|
| 178 |
+
6. frozen final quantization anchor
|
| 179 |
+
7. MTP work after the final quantization anchor
|