Skip to content

Qwen3.8-Flash-Next on any consumer hardware: one-click install for Windows / Linux. Strata inference engine, OpenAI/Anthropic API on localhost, optional image input.

C++

docs: speed tables measured with engine 0.1.14 (prompts 1.2-2.4x faster than the old tables)

Niko122106f41f49a852
diff --git a/README.md b/README.md
index 9fb6f021b..05226068e 100644
--- a/README.md
+++ b/README.md
@@ -25,13 +25,14 @@ Measured on an RTX 5070 (12 GB), a Ryzen 5 7600 and 64 GB of RAM:
| Size | Writes answers (short chat) | Writes answers (128K context) | Reads your prompt |
| --- | ---: | ---: | ---: |
-| **Q2_0** | 95 tokens/s | 65 tokens/s | 539 tokens/s |
-| **IQ2_XS** | 78 tokens/s | 52 tokens/s | 463 tokens/s |
-| **IQ3_XXS** | 66 tokens/s | 45 tokens/s | 410 tokens/s |
-| **IQ3_S** | 54 tokens/s | 42 tokens/s | 374 tokens/s |
+| **Q2_0** | 90 tokens/s | 67 tokens/s | 1,310 tokens/s |
+| **IQ2_XS** | 74 tokens/s | 60 tokens/s | 1,240 tokens/s |
+| **IQ3_XXS** | 62 tokens/s | 46 tokens/s | 1,110 tokens/s |
+| **IQ3_S** | 52 tokens/s | 41 tokens/s | 1,070 tokens/s |
- **Writes answers** = how fast the reply appears (tokens per second).
-- **Reads your prompt** = how fast it takes in what you send (long documents, code, chat history).
+- **Reads your prompt** = how fast it takes in what you send (long documents, code, chat history), measured on a
+ 32K-token prompt; a 4K prompt reads at 740-1,000 tokens/s. A 32K prompt takes about 25 seconds with Q2_0.
A card with more VRAM is faster, because more of the model fits on the GPU: an RTX 3090 (24 GB) should do roughly
100-140 tokens per second. All measurements, long-context numbers and estimates for other cards are in the
diff --git a/bench/results/2026-09-28-speed-0114/README.md b/bench/results/2026-09-28-speed-0114/README.md
new file mode 100644
index 000000000..f6c1aba87
--- /dev/null
+++ b/bench/results/2026-09-28-speed-0114/README.md
@@ -0,0 +1,32 @@
+# Speed with engine 0.1.14
+
+RTX 5070 12 GB (PCIe 5.0 x16), Ryzen 5 7600, 64 GB DDR5-5200, Windows 10. The ready-made 0.1.14 engine, one-shot runs
+with what setup writes: `--prefill auto`, the shipped expert profile, `--expert-cache auto`, 8-bit KV above 4K, KV
+streaming (`--kv-resident 32768`) from 64K, MTP (`--spec 4 --spec-min-p 0.5`), greedy, 256 generated tokens. One
+code-agent prompt per length (`bench/prompts/*/…-code-agent.ids`, the same prompts as `2026-09-24-final`).
+
+The tables: [`matrix.md`](matrix.md) (prompt and output speed, draft acceptance, experts in VRAM); every run in
+[`matrix.json`](matrix.json).
+
+- **IQ2_XS** was measured with Swift 1.5's IQ2_XS (the original's file was not on the machine; the two run at the same
+ speed: 4K 465 vs 467 prompt tokens/s in `2026-09-24`).
+- **IQ3_S at 128K** comes from a first pass during which a large download was running (the clean rerun of that row
+ was stopped when Windows ran short of memory); the other rows are from runs on an otherwise idle machine.
+- **IQ3_XXS and IQ3_S at 262K** are not measured: with 43 / 50 GB of experts, a 260K context exceeds 64 GB of RAM.
+
+## Against 0.1.12
+
+Prompts are 1.2x (1K) to 2.4x (32K-128K) faster: the 0.1.13 prompt path (chunks of up to 8,192 tokens, MMQ experts,
+streamed expert copies; see `2026-09-28-prefill-speed`).
+
+Output speed moves with the text: speculative decoding is faster when more drafts are accepted, and the new prompt
+path's rounding changes the answer, so the same prompt can land a few percent either way (Q2_0 32K: acceptance 0.865
+then, 0.709 now). The engine itself is not slower: on the 4K prompt, run back to back on the same machine state,
+0.1.14 writes 88.5 tokens/s and 0.1.12 85.7 (3 runs each, same free VRAM).
+
+## Found on the way
+
+IQ3_XXS at 64K and 128K ended with `out of memory: cudaFuncSetAttribute` in the MMQ launch: CUDA loads a kernel's code
+when it is first used, and mid-prompt there was no VRAM left for it. Loading every kernel at start
+(`CUDA_MODULE_LOADING=EAGER`, which the engine now sets itself) fixes it for ~30 MB of VRAM; the IQ3_XXS 64K/128K rows
+were measured with that fix.
diff --git a/bench/results/2026-09-28-speed-0114/matrix.json b/bench/results/2026-09-28-speed-0114/matrix.json
new file mode 100644
index 000000000..ca9501e00
--- /dev/null
+++ b/bench/results/2026-09-28-speed-0114/matrix.json
@@ -0,0 +1,322 @@
+[
+ {
+ "model": "Q2_0",
+ "tier": "1k",
+ "prompt_tokens": 1017,
+ "exit": 0,
+ "wall_s": 41.0,
+ "prefill_tok_s": 494.43,
+ "ttft_s": 3.55,
+ "decode_tok_s": 84.26,
+ "decoded": 256,
+ "spec_accept": 0.709,
+ "tokens_per_round": 2.72,
+ "vram_slots": 4176
+ },
+ {
+ "model": "Q2_0",
+ "tier": "4k",
+ "prompt_tokens": 3562,
+ "exit": 0,
+ "wall_s": 41.2,
+ "prefill_tok_s": 1006.63,
+ "ttft_s": 5.05,
+ "decode_tok_s": 90.26,
+ "decoded": 256,
+ "spec_accept": 0.846,
+ "tokens_per_round": 3.23,
+ "vram_slots": 4123
+ },
+ {
+ "model": "Q2_0",
+ "tier": "32k",
+ "prompt_tokens": 31566,
+ "exit": 0,
+ "wall_s": 63.1,
+ "prefill_tok_s": 1307.6,
+ "ttft_s": 25.63,
+ "decode_tok_s": 73.61,
+ "decoded": 256,
+ "spec_accept": 0.709,
+ "tokens_per_round": 2.68,
+ "vram_slots": 3833
+ },
+ {
+ "model": "Q2_0",
+ "tier": "64k",
+ "prompt_tokens": 64162,
+ "exit": 0,
+ "wall_s": 89.0,
+ "prefill_tok_s": 1293.5,
+ "ttft_s": 51.12,
+ "decode_tok_s": 69.02,
+ "decoded": 256,
+ "spec_accept": 0.679,
+ "tokens_per_round": 2.62,
+ "vram_slots": 3780
+ },
+ {
+ "model": "Q2_0",
+ "tier": "128k",
+ "prompt_tokens": 128478,
+ "exit": 0,
+ "wall_s": 147.4,
+ "prefill_tok_s": 1208.46,
+ "ttft_s": 107.81,
+ "decode_tok_s": 67.21,
+ "decoded": 256,
+ "spec_accept": 0.691,
+ "tokens_per_round": 2.64,
+ "vram_slots": 3697
+ },
+ {
+ "model": "Q2_0",
+ "tier": "262k",
+ "prompt_tokens": 259943,
+ "exit": 0,
+ "wall_s": 309.8,
+ "prefill_tok_s": 966.84,
+ "ttft_s": 270.35,
+ "decode_tok_s": 60.3,
+ "decoded": 256,
+ "spec_accept": 0.623,
+ "tokens_per_round": 2.43,
+ "vram_slots": 3525
+ },
+ {
+ "model": "IQ2_XS",
+ "tier": "1k",
+ "prompt_tokens": 1017,
+ "exit": 0,
+ "wall_s": 40.4,
+ "prefill_tok_s": 461.28,
+ "ttft_s": 2.28,
+ "decode_tok_s": 74.38,
+ "decoded": 256,
+ "spec_accept": 0.772,
+ "tokens_per_round": 2.84,
+ "vram_slots": 4386,
+ "note": "first pass"
+ },
+ {
+ "model": "IQ2_XS",
+ "tier": "4k",
+ "prompt_tokens": 3562,
+ "exit": 0,
+ "wall_s": 41.8,
+ "prefill_tok_s": 810.71,
+ "ttft_s": 4.48,
+ "decode_tok_s": 73.84,
+ "decoded": 256,
+ "spec_accept": 0.79,
+ "tokens_per_round": 3.24,
+ "vram_slots": 4336,
+ "note": "first pass"
+ },
+ {
+ "model": "IQ2_XS",
+ "tier": "32k",
+ "prompt_tokens": 31566,
+ "exit": 0,
+ "wall_s": 65.0,
+ "prefill_tok_s": 1237.98,
+ "ttft_s": 25.59,
+ "decode_tok_s": 71.49,
+ "decoded": 256,
+ "spec_accept": 0.856,
+ "tokens_per_round": 3.28,
+ "vram_slots": 4057,
+ "note": "first pass"
+ },
+ {
+ "model": "IQ2_XS",
+ "tier": "64k",
+ "prompt_tokens": 64162,
+ "exit": 0,
+ "wall_s": 97.1,
+ "prefill_tok_s": 1135.63,
+ "ttft_s": 56.59,
+ "decode_tok_s": 64.29,
+ "decoded": 256,
+ "spec_accept": 0.707,
+ "tokens_per_round": 2.76,
+ "vram_slots": 4005,
+ "note": "first pass"
+ },
+ {
+ "model": "IQ2_XS",
+ "tier": "128k",
+ "prompt_tokens": 128478,
+ "exit": 0,
+ "wall_s": 158.0,
+ "prefill_tok_s": 1070.61,
+ "ttft_s": 120.1,
+ "decode_tok_s": 59.76,
+ "decoded": 256,
+ "spec_accept": 0.726,
+ "tokens_per_round": 2.69,
+ "vram_slots": 3923,
+ "note": "first pass"
+ },
+ {
+ "model": "IQ2_XS",
+ "tier": "262k",
+ "prompt_tokens": 259943,
+ "exit": 0,
+ "wall_s": 332.4,
+ "prefill_tok_s": 886.2,
+ "ttft_s": 293.43,
+ "decode_tok_s": 52.83,
+ "decoded": 256,
+ "spec_accept": 0.628,
+ "tokens_per_round": 2.53,
+ "vram_slots": 3565,
+ "note": "first pass"
+ },
+ {
+ "model": "IQ3_XXS",
+ "tier": "1k",
+ "prompt_tokens": 1017,
+ "exit": 0,
+ "wall_s": 44.1,
+ "prefill_tok_s": 414.55,
+ "ttft_s": 2.54,
+ "decode_tok_s": 60.26,
+ "decoded": 256,
+ "spec_accept": 0.864,
+ "tokens_per_round": 3.52,
+ "vram_slots": 3304,
+ "note": "first pass"
+ },
+ {
+ "model": "IQ3_XXS",
+ "tier": "4k",
+ "prompt_tokens": 3562,
+ "exit": 0,
+ "wall_s": 45.8,
+ "prefill_tok_s": 769.57,
+ "ttft_s": 4.73,
+ "decode_tok_s": 62.07,
+ "decoded": 256,
+ "spec_accept": 0.855,
+ "tokens_per_round": 3.24,
+ "vram_slots": 3263,
+ "note": "first pass"
+ },
+ {
+ "model": "IQ3_XXS",
+ "tier": "32k",
+ "prompt_tokens": 31566,
+ "exit": 0,
+ "wall_s": 69.7,
+ "prefill_tok_s": 1107.75,
+ "ttft_s": 28.61,
+ "decode_tok_s": 51.4,
+ "decoded": 256,
+ "spec_accept": 0.678,
+ "tokens_per_round": 2.6,
+ "vram_slots": 3031,
+ "note": "first pass"
+ },
+ {
+ "model": "IQ3_XXS",
+ "tier": "64k",
+ "prompt_tokens": 64162,
+ "exit": 0,
+ "wall_s": 104.9,
+ "prefill_tok_s": 1065.31,
+ "ttft_s": 61.77,
+ "decode_tok_s": 49.95,
+ "decoded": 256,
+ "spec_accept": 0.741,
+ "tokens_per_round": 2.94,
+ "vram_slots": 2965,
+ "note": "first pass"
+ },
+ {
+ "model": "IQ3_XXS",
+ "tier": "128k",
+ "prompt_tokens": 128478,
+ "exit": 0,
+ "wall_s": 172.1,
+ "prefill_tok_s": 1015.11,
+ "ttft_s": 128.12,
+ "decode_tok_s": 45.78,
+ "decoded": 256,
+ "spec_accept": 0.665,
+ "tokens_per_round": 2.35,
+ "vram_slots": 2901,
+ "note": "first pass"
+ },
+ {
+ "model": "IQ3_S",
+ "tier": "1k",
+ "prompt_tokens": 1017,
+ "exit": 0,
+ "wall_s": 56.2,
+ "prefill_tok_s": 396.13,
+ "ttft_s": 4.14,
+ "decode_tok_s": 51.52,
+ "decoded": 256,
+ "spec_accept": 0.826,
+ "tokens_per_round": 3.12,
+ "vram_slots": 2617
+ },
+ {
+ "model": "IQ3_S",
+ "tier": "4k",
+ "prompt_tokens": 3562,
+ "exit": 0,
+ "wall_s": 57.5,
+ "prefill_tok_s": 736.9,
+ "ttft_s": 6.35,
+ "decode_tok_s": 51.6,
+ "decoded": 256,
+ "spec_accept": 0.747,
+ "tokens_per_round": 2.89,
+ "vram_slots": 2580
+ },
+ {
+ "model": "IQ3_S",
+ "tier": "32k",
+ "prompt_tokens": 31566,
+ "exit": 0,
+ "wall_s": 82.5,
+ "prefill_tok_s": 1069.83,
+ "ttft_s": 31.33,
+ "decode_tok_s": 48.19,
+ "decoded": 256,
+ "spec_accept": 0.772,
+ "tokens_per_round": 2.94,
+ "vram_slots": 2383
+ },
+ {
+ "model": "IQ3_S",
+ "tier": "64k",
+ "prompt_tokens": 64162,
+ "exit": 0,
+ "wall_s": 115.0,
+ "prefill_tok_s": 1069.8,
+ "ttft_s": 61.47,
+ "decode_tok_s": 48.75,
+ "decoded": 256,
+ "spec_accept": 0.786,
+ "tokens_per_round": 2.9,
+ "vram_slots": 2347
+ },
+ {
+ "model": "IQ3_S",
+ "tier": "128k",
+ "prompt_tokens": 128478,
+ "exit": 0,
+ "wall_s": 191.8,
+ "prefill_tok_s": 931.09,
+ "ttft_s": 138.11,
+ "decode_tok_s": 40.48,
+ "decoded": 256,
+ "spec_accept": 0.661,
+ "tokens_per_round": 2.71,
+ "vram_slots": 2310,
+ "note": "first pass (a download was running)"
+ }
+]
\ No newline at end of file
diff --git a/bench/results/2026-09-28-speed-0114/matrix.md b/bench/results/2026-09-28-speed-0114/matrix.md
new file mode 100644
index 000000000..5a92ac63a
--- /dev/null
+++ b/bench/results/2026-09-28-speed-0114/matrix.md
@@ -0,0 +1,35 @@
+### Prompt processing (tok/s)
+
+| Model | 1K | 4K | 32K | 64K | 128K | 262K |
+| --- | ---: | ---: | ---: | ---: | ---: | ---: |
+| Q2_0 | 494 | 1,007 | 1,308 | 1,294 | 1,208 | 967 |
+| IQ2_XS | 461 | 811 | 1,238 | 1,136 | 1,071 | 886 |
+| IQ3_XXS | 415 | 770 | 1,108 | 1,065 | 1,015 | - |
+| IQ3_S | 396 | 737 | 1,070 | 1,070 | 931 | - |
+
+### Output (tok/s)
+
+| Model | 1K | 4K | 32K | 64K | 128K | 262K |
+| --- | ---: | ---: | ---: | ---: | ---: | ---: |
+| Q2_0 | 84.3 | 90.3 | 73.6 | 69.0 | 67.2 | 60.3 |
+| IQ2_XS | 74.4 | 73.8 | 71.5 | 64.3 | 59.8 | 52.8 |
+| IQ3_XXS | 60.3 | 62.1 | 51.4 | 50.0 | 45.8 | - |
+| IQ3_S | 51.5 | 51.6 | 48.2 | 48.8 | 40.5 | - |
+
+### Draft acceptance
+
+| Model | 1K | 4K | 32K | 64K | 128K | 262K |
+| --- | ---: | ---: | ---: | ---: | ---: | ---: |
+| Q2_0 | 0.709 | 0.846 | 0.709 | 0.679 | 0.691 | 0.623 |
+| IQ2_XS | 0.772 | 0.790 | 0.856 | 0.707 | 0.726 | 0.628 |
+| IQ3_XXS | 0.864 | 0.855 | 0.678 | 0.741 | 0.665 | - |
+| IQ3_S | 0.826 | 0.747 | 0.772 | 0.786 | 0.661 | - |
+
+### Experts in VRAM
+
+| Model | 1K | 4K | 32K | 64K | 128K | 262K |
+| --- | ---: | ---: | ---: | ---: | ---: | ---: |
+| Q2_0 | 4,176 | 4,123 | 3,833 | 3,780 | 3,697 | 3,525 |
+| IQ2_XS | 4,386 | 4,336 | 4,057 | 4,005 | 3,923 | 3,565 |
+| IQ3_XXS | 3,304 | 3,263 | 3,031 | 2,965 | 2,901 | - |
+| IQ3_S | 2,617 | 2,580 | 2,383 | 2,347 | 2,310 | - |
diff --git a/docs/DETAILS.md b/docs/DETAILS.md
index d72bb336a..3ef673a76 100644
--- a/docs/DETAILS.md
+++ b/docs/DETAILS.md
@@ -11,26 +11,34 @@ New here? Start with the [README](../README.md) - it has everything you need to
## Speed (measured)
-RTX 5070 **12 GB**, Ryzen 5 7600 (6 cores), 64 GB DDR5-5200, Windows. One code-agent prompt per length, 256 generated
-tokens, MTP speculative decoding on. "262K" is the model's full context window (a 259,943-token prompt).
+RTX 5070 **12 GB**, Ryzen 5 7600 (6 cores), 64 GB DDR5-5200, Windows, engine 0.1.14 with the settings setup writes
+(`--prefill auto`, 8-bit KV above 4K, KV streaming from 64K). One code-agent prompt per length, 256 generated tokens,
+MTP speculative decoding on. "262K" is the model's full context window (a 259,943-token prompt). The IQ2_XS row was
+measured with Swift 1.5's IQ2_XS, which runs at the original's speed.
### Prompt processing (tokens/s)
| Model | 1K | 4K | 32K | 64K | 128K | 262K |
| --- | ---: | ---: | ---: | ---: | ---: | ---: |
-| **Q2_0** | 389 | 539 | 571 | 561 | 543 | 496 |
-| **IQ2_XS** | 332 | 463 | 495 | 486 | 472 | 437 |
-| **IQ3_XXS** | 285 | 410 | 435 | 427 | 414 | - |
-| **IQ3_S** | 260 | 374 | 397 | - | 378 | - |
+| **Q2_0** | 494 | 1,007 | 1,308 | 1,294 | 1,208 | 967 |
+| **IQ2_XS** | 461 | 811 | 1,238 | 1,136 | 1,071 | 886 |
+| **IQ3_XXS** | 415 | 770 | 1,108 | 1,065 | 1,015 | - |
+| **IQ3_S** | 396 | 737 | 1,070 | 1,070 | 931 | - |
### Output (tokens/s)
| Model | 1K | 4K | 32K | 64K | 128K | 262K |
| --- | ---: | ---: | ---: | ---: | ---: | ---: |
-| **Q2_0** | 88.7 | 94.6 | 87.5 | 76.4 | 65.1 | 56.3 |
-| **IQ2_XS** | 82.0 | 78.0 | 65.3 | 63.7 | 52.0 | 48.0 |
-| **IQ3_XXS** | 64.6 | 65.6 | 57.3 | 54.4 | 44.8 | - |
-| **IQ3_S** | 51.2 | 54.4 | 51.1 | - | 42.2 | - |
+| **Q2_0** | 84.3 | 90.3 | 73.6 | 69.0 | 67.2 | 60.3 |
+| **IQ2_XS** | 74.4 | 73.8 | 71.5 | 64.3 | 59.8 | 52.8 |
+| **IQ3_XXS** | 60.3 | 62.1 | 51.4 | 50.0 | 45.8 | - |
+| **IQ3_S** | 51.5 | 51.6 | 48.2 | 48.8 | 40.5 | - |
+
+Output speed depends on the text as well: speculative decoding runs faster when more of the drafted tokens are
+accepted, so a different answer to the same prompt moves it by several percent. Run back to back on the 4K prompt,
+0.1.14 writes 88.5 tokens/s and 0.1.12 85.7. The numbers before 0.1.13 (prompts about half as fast):
+[`bench/results/2026-09-24-final`](../bench/results/2026-09-24-final/matrix.md); these:
+[`bench/results/2026-09-28-speed-0114`](../bench/results/2026-09-28-speed-0114/README.md).
IQ3_XXS and IQ3_S at 262K are not measured: with their 43 / 50 GB of experts, a 260K-token context brings a 64 GB PC
to its memory limit. Use up to 128K with them on 64 GB (setup caps it). IQ3_S (engine 0.1.4 or newer) is only published
@@ -47,8 +55,8 @@ halves the KV cache's memory with a Hadamard rotation before 4-bit rounding (PR
is measurably less precise on long documents (perplexity +8-12%; needle tests still pass). 8-bit stays the default.
Details: [`bench/results/2026-09-27-kv-q4`](../bench/results/2026-09-27-kv-q4/README.md).
-Time to first token is prompt length / prompt speed: about 7 s at 4K, 55 s at 32K, 4 minutes at 128K and 9 minutes at
-262K (engine 0.1.12; long prompts are about twice as fast since 0.1.13, below).
+Time to first token is prompt length / prompt speed: with Q2_0 about 4 s at 4K, 25 s at 32K, under 2 minutes at 128K
+and 4.5 minutes at 262K (engine 0.1.13 made long prompts about twice as fast, below).
**Faster prompts (engine 0.1.13):** the prompt is read in chunks of up to 8,192 tokens instead of 2,048 (`--prefill
auto`: the largest chunk whose buffers fit in the expert-cache slots it borrows, and a request borrows only what its
@@ -66,6 +74,8 @@ switch to `--prefill auto` the next time START-HERE / setup.sh starts them. The
Not measured - estimated from the runs above (same CPU and 64 GB RAM): the GPU part scaled by memory bandwidth, the CPU
part by how many more experts the card's VRAM holds. Treat as **±20%**. Numbers are *prompt / output* tokens/s.
+The prompt figures predate engine 0.1.13, which about doubled prompt speed on the measured card; how much of that a
+card gains depends on its PCIe link (the experts stream over it), so they are still the older estimates.
| GPU | Model | 1K | 4K | 32K | 64K | 128K | 262K |
| --- | ---: | ---: | ---: | ---: | ---: | ---: | ---: |