Inkling-2-Mini — EXL3 3.70 bpw (mul1) + BF16 DSpark
An EXL3 (mul1 codebook, 3.697 avg bpw) mixed-precision quantization of Thinking Machines Lab's Inkling 2 Mini, engineered specifically to bring 120K pure-GPU and 256K long-context inference with bundled BF16 DSpark speculative decoding to 16 GB GPUs — built, tuned, and hardware-validated on AMD ROCm via EXL3-AMD.
- EXL3 Runtime for AMD GPUs (ROCm): github.com/RishiJain905/EXL3-AMD
- Base Model: thinkingmachines/Inkling-2-Mini (Apache 2.0)
- Total Size:
12.23 GiBEXL3 text weights (4safetensors shards) +0.59 GiBunquantized BF16 DSpark drafter (mtp.safetensors) =12.82 GiBtotal - Measured Fidelity:
0.02560mean KLD vs dequantized BF16 (95.92%top-1 token agreement;97.39%on coding) - Measured RX 7800 XT (16 GB) Speed:
61.2 tok/s@ 8K pure GPU ·56.1 tok/s@ 120K pure GPU (826 tok/sprefill) ·32.7 tok/s@ 256K with 2-layer CPU offload (699 tok/sprefill)
Scope note: This checkpoint contains the text decoder (
model.llm) and the unquantized 3-layer BF16 DSpark speculative drafter (mtp.safetensors). Vision encoder weights from the upstream multimodal checkpoint are not bundled in this release. A higher-bit-rate tier (FP16 attention + 4 bpw core + 6 bpw tail) is planned separately for 24 GB+ GPUs.
About Inkling 2 Mini
Inkling 2 Mini (released November 20, 2026 by Thinking Machines Lab, Inc.) is a 26.4B-parameter sparse Mixture-of-Experts (MoE) looped transformer built for local agentic coding, tool use, search, reasoning, and long-context workflows up to 1M tokens.
Architectural Highlights
- Looped Transformer Depth (
24physical layers →48logical passes): Layers0–5run once, the middle 12 core layers (L6–17) execute 3× with shared weights, and layers18–23run once. While3.4Bparameters are active per single pass, each additional loop pass adds ~`1.0Beffective compute — yielding **5.4B` effective active parameters per token** from a compact 26.4B footprint. - Fine-Grained Sparse MoE:
128routed experts per layer, top-8 routing (route_scale = 8.0), with softcapped SwiGLU activations (gate_cap = 4.0,up_cap = 25.0). - Extreme Long-Context KV Efficiency: Only 4 physical layers (
L5, L11, L17, L23→ 8 logical global visits plus 1 global layer in DSpark) use full global attention. The remaining 40 logical layers use 1,024-token sliding-window attention (SWA) rings (~`0.34 GiBconstant VRAM regardless of context length!). Combined withAsterKV-5orQ4KV quantization, **120K context requires only ~1.94 GiBtotal KV cache** and **256K context requires only ~3.07 GiB`**. - Recurrent & Attention Innovations: Block attention residuals (
6 layers/block), rank-64 cross-pass loop message controllers (L6–17), static & dynamic causal short convolutions (kernel = 4), QK/Rel L2-clipping + log-scaling, data-dependent relative position bias (rel_extent = 1024), and per-token attention sinks. - Native DSpark Speculative Drafter (
mtp.safetensors): A bundled 3-layer BF16 multi-token draft head tapping hidden states[5, 23, 41, 48]with a rank-256 Markov head for lossless speculative decoding.
Upstream Base Model Capabilities (thinkingmachines/Inkling-2-Mini)
The following scores are reported by Thinking Machines Lab for the upstream thinkingmachines/Inkling-2-Mini release (for reference on what the model is designed for; these benchmarks have not been independently re-run on this EXL3 quantization):
| Category | Benchmark | Inkling 2 Mini (Upstream) |
|---|---|---|
| Coding & SWE | SWE-bench Verified (bash only) | 79.2% |
| SWE-bench Pro v2 (Hard) | 77.9% | |
| SWE-bench Multilingual (bash only) | 73.7% | |
| Vibe Code Bench v1.1 | 77.9% | |
| DeepSWE v1.1 | 48.2% | |
| Terminal Bench v2.1 | 71.6% | |
| Agentic Search & Tools | DeepSearchQA | 85.3% |
| MCP Atlas (Public) | 82.7% | |
| BrowseComp | 79.0% | |
| Long Context & Reasoning | GraphWalks BFS (256K) | 69.7% |
| LongBench v2 | 66.9% | |
| MRCR v2 (8-needle 256K–512K) | 46.4% | |
| ARC-AGI v1 / v2 | 84.5% / 49.3% | |
| AA Index (v5.0) / Vals Index (v2.2) | 20.1 / 46.5% |
EXL3 Quantization Recipe (3.70 bpw, mul1)
The upstream Inkling 2 Mini checkpoint is distributed (20 GB) in mixed NVFP4 (12 GiB GPU footprint** so 16 GB cards can run 120K context entirely in VRAM:L0–19 experts) and MXFP8 (L20–23 experts). This quantization mirrors that native sensitivity profile while keeping every control path unquantized and targeting a strict **
| Component | Native Training Precision | EXL3 Precision | Approx. Size |
|---|---|---|---|
| Attention projections (all 24 layers) | BF16 / MXFP8 | 8 bpw mul1 |
0.61 GiB |
lm_head (unembed) |
BF16 | 8 bpw mul1 |
0.44 GiB |
Pre-loop L0–5 experts (1× visit) |
NVFP4 | 3 bpw mul1 |
2.14 GiB |
Looped core L6–11 experts (3× visit) |
NVFP4 | 3 bpw mul1 |
2.14 GiB |
Looped core L12–17 experts (3× visit) |
NVFP4 | 4 bpw mul1 |
2.85 GiB |
Post-loop L18–19 experts (1× visit) |
NVFP4 | 3 bpw mul1 |
0.71 GiB |
High-sensitivity tail L20–23 experts (1× visit) |
MXFP8 | 5 bpw mul1 |
2.37 GiB |
Routers, loop controllers, attn_res, sconv, sinks, rel_logits_proj |
BF16 / FP32 | 100% Unquantized (BF16/FP32) | 0.08 GiB |
DSpark Speculative Drafter (mtp.safetensors) |
BF16 | 100% Unquantized (BF16) | 0.59 GiB |
| Token embeddings (CPU-resident, 0 VRAM) | BF16 | 100% Unquantized (BF16) | 0.88 GiB |
| Total Realized | — | 3.697 avg bpw (mul1) |
12.23 GiB weights + 0.59 GiB DSpark |
Loop-Aware Hessian Calibration
- Dequantized upstream
thinkingmachines/Inkling-2-Minicleanly to BF16 before EXL3 conversion. - 3-pass loop-aware Hessian capture: During conversion, passes
0,1, and2are replayed through layersL6–17and Hessians are accumulated across all 3 passes simultaneously (activate_all_experts=True). - Calibration corpus:
24 × 512=12,288tokens on 1× layers (36,864effective tokens on 3× looped layers), spanning Python/C++/TypeScript/SQL coding, mathematical proofs, systems architecture, JSON tool-calling, technical documentation, and Inkling-2 chat templates.
Quantization Fidelity (KLD vs Unquantized BF16)
Measured directly against the unquantized dequantized BF16 reference over a 662-token multi-domain evaluation set (coding, math, systems, json_tool):
| Domain | Tokens | Mean KLD vs BF16 | Median KLD | P95 KLD | Same Top-1 Token |
|---|---|---|---|---|---|
| Coding | 230 | 0.01411 | 5.4e-8 |
0.06093 | 97.39% |
| Math | 132 | 0.02229 | 0.00075 |
0.09425 | 96.21% |
| Systems | 122 | 0.01901 | 0.00698 |
0.07925 | 96.72% |
| JSON / Tool-Calling | 178 | 0.04741 | 3.5e-5 |
0.24071 | 93.26% |
| Overall | 662 | 0.02560 | — | — | 95.92% |
Functional & Long-Context Needle Verification
- Quality spot checks (DSpark
n=5, greedy): 3/3 PASS with coherent reasoning and exact answers (capital@71.3 tok/s,math 17×24+89=497@68.1 tok/s, Pythonmerge_intervals@65.3 tok/s). - 120K Needle-in-a-Haystack (
119,994prompt tokens,AsterKV-5, pure GPU): PASS (exact retrieval ofCOBALT-7492-FALCON). - 256K Needle-in-a-Haystack (
249,971prompt tokens,Q4KV,-ncmoe 2): PASS (exact retrieval ofOBSIDIAN-9183-AURORA).
Note: The 662-token KLD probe is a compact fidelity benchmark measured against dequantized BF16; it is not directly interchangeable with GGUF KLD numbers measured against UD-Q8_K_XL on different corpora.
Optimized for 16 GB AMD GPUs (ROCm) — Try It with EXL3-AMD
This quant was specifically co-designed with EXL3-AMD (inkling2-opt-v1 ROCm extension) to deliver fast native inference on 16 GB AMD Radeon GPUs (validated on an AMD Radeon RX 7800 XT, gfx1101, 15.80 GiB VRAM, ROCm 7.2.4, WSL2):
- Fused Inkling-2 HIP ops: Block attention residuals, cross-pass message gate mix, static/dynamic short convolutions, QK/Rel L2-clip, and DSpark Markov argmax fused in native ROCm/HIP.
- K=8 packed projection kernels: Native 8-bit
mul1small-M, mid-batch, and prefill kernels for Inkling-2's 8 bpw attention andlm_head. - Triton Inkling-2 attention: Split-KV FlashDecoding for SWA ring decode + chunked Hadamard-space FP16 staging for quantized global KV prefill (
AsterKV-5/Q4). - Loop-aware CPU MoE offload (
-ncmoe): Automatically ranks layers by(visit_count ASC, -expert_bytes ASC)so single-visit 5 bpw tail layers (L23, L22, ...) offload before the 3× looped core — paired with host-driven overlapped handoff and AVX-512 VBMI / AVX2 CPU softcap SwiGLU kernels.
Measured RX 7800 XT (15.80 GiB) Benchmarks
| Workload | KV Cache | MoE Offload | Prefill | Decode | DSpark Accept | Peak VRAM (Reserved) | Needle |
|---|---|---|---|---|---|---|---|
8K Target-only (M=1) |
aster5 |
None (100% GPU) | 167.9 tok/s (T=49) |
48.78 tok/s |
— | 12.73 GiB (13.22) |
— |
8K DSpark n=3 |
aster5 |
None (100% GPU) | 629.0 tok/s (T=1024) |
61.24 tok/s |
0.450 |
12.83 GiB (13.36) |
— |
8K DSpark n=5 / n=7 |
aster5 |
None (100% GPU) | 446.0 tok/s (T=256) |
54.14 / 53.10 tok/s |
0.331 / 0.310 |
12.83 GiB (13.36) |
— |
120K (119,994 tok, n=5) |
aster5 |
None (100% GPU) | 826.4 tok/s (145.2 s) |
56.10 tok/s |
0.560 |
14.19 GiB (14.72) |
PASS |
256K (249,971 tok, n=5) |
q4 |
-ncmoe 2 (L23, L22) |
698.8 tok/s (357.7 s) |
32.71 tok/s |
0.394 |
14.15 GiB (14.65) |
PASS |
Quick Start on AMD GPUs (EXL3-AMD)
- Follow the build and runtime setup instructions in EXL3-AMD (
docs/BUILD.md). - Download this model:
hf download trjxter/Inkling-2-Mini-EXL3-3.7bpw --local-dir ./Inkling-2-Mini-EXL3-3.7bpw - Launch the local OpenAI-compatible server (
http://127.0.0.1:8000/v1):
120K Context — 100% Pure GPU (AsterKV-5, ~`56 tok/s` on RX 7800 XT)
python run.py serve `
-m "./Inkling-2-Mini-EXL3-3.7bpw" `
-c 122880 -b 1024 `
--cache-type aster5 `
--spec-type draft-dspark --mtp 5 `
--decode-fusions off `
--gpu-memory-fraction 0.95 --max-gpu-memory-fraction 0.97 `
--alias inkling2-120k --port 8000
256K Context — 2-Layer CPU Offload (Q4 KV, ~`33 tok/s` on RX 7800 XT)
python run.py serve `
-m "./Inkling-2-Mini-EXL3-3.7bpw" `
-c 262144 -b 1024 `
--cache-type q4 `
--spec-type draft-dspark --mtp 5 `
-ncmoe 2 `
--decode-fusions off `
--gpu-memory-fraction 0.95 --max-gpu-memory-fraction 0.97 `
--alias inkling2-256k --port 8000
Runtime Tips
- Desktop VRAM headroom: If Windows/desktop apps are using extra VRAM and
--gpu-memory-fraction 0.95is tight on a 16 GB card, omit the two memory-fraction flags (keeping the0.90default) and bump-ncmoeby+1(-ncmoe 1at 120K;-ncmoe 3at 256K). - Use
-ncmoeinstead of--moe-cpu-split: On Inkling-2's looped architecture, whole-layer offload automatically targets single-visit tail layers (L23, L22, ...) and runs 2.2×–2.5× faster than uniform expert splitting at the same VRAM budget. - Draft depth:
--mtp 3is fastest on short prompts (61+ tok/s);--mtp 5is the validated long-context sweet spot. - Sampling: Add
--temperature,--top-p, etc., for sampled serving (upstreamgeneration_config.jsonusestemperature=1.0,do_sample=true; speculative sampling stays enabled automatically).
Limitations, Safety & License
- Quantization & hardware scope: Hardware validation covers AMD Radeon RX 7800 XT (
gfx1101, ROCm 7.2.4, WSL2) on text + DSpark inference. Vision weights are not bundled. Quantization can introduce subtle differences from the upstream NVFP4/MXFP8 release, particularly on strict JSON/tool schemas or edge-case reasoning. - Upstream model limitations: As documented by Thinking Machines Lab, Inkling 2 Mini is a compact local model and may hallucinate, enter repetitive reasoning loops on difficult debugging tasks (set output-token and agent-turn limits), perform weaker outside English, or take unintended actions in agentic environments — always run agentic workloads in a sandbox with confirmation for destructive operations.
- License & attribution: Original model created by Thinking Machines Lab, Inc. (
thinkingmachines/Inkling-2-Mini) and released under the Apache 2.0 License (LICENSE). See also Thinking Machines Lab's Model Acceptable Use Policy and Training Data Documentation.
- Downloads last month
- 59
Model tree for trjxter/Inkling-2-Mini-EXL3-3.7bpw
Base model
thinkingmachines/Inkling-2-Mini