--- base_model: unsloth/Inkling-2-Mini-GGUF license: apache-2.0 tags: - loom - loom-serve - gguf - strix-halo - speculative-decoding - dflash - vision - image-text-to-text --- # Inkling-2-Mini (UD-Q4_K_XL) for AMD Loom A [Loom](https://github.com/ROCm/hrx-system) package (`.loom` programs and a `model.json` card) for the unmodified GGUF checkpoint [unsloth/Inkling-2-Mini-GGUF](https://huggingface.co/unsloth/Inkling-2-Mini-GGUF) (`Inkling-2-Mini-UD-Q4_K_XL.gguf`), generated on an AMD Ryzen AI Max+ 395 "Strix Halo" with the [loom-skills](https://github.com/loom-fun/loom-skills) workflow. Learn more on the [Loom ecosystem website](https://loom-fun.github.io/loom-dev/). ## Quick start ```bash pipx install "hrx-loom[hf]==0.2.0" loom-fetch huggingface:loom-fun/unsloth-Inkling-2-Mini-loom:chat --materialize=copy --output=Inkling-2-Mini loom-serve --model=Inkling-2-Mini '--device=amdgpu://?completion_spin_ns=4294967295' --pool_backing=fixed --parameter_mode=preload ``` - `--materialize=copy` puts copies of the fetched package files in the output directory. - `completion_spin_ns=4294967295` enables active waiting for GPU completions (uses CPU while GPU work is in flight); the card's performance measurements use this setting. - `--pool_backing=fixed` commits the preset's memory pool up front instead of growing elastic backing. - `--parameter_mode=preload` only changes how the weights are loaded on the host, so the performance rows were measured without it unless their job served with it. ## Send a request In another terminal (optional thinking is turned off): ```bash curl http://127.0.0.1:8080/v1/chat/completions \ -H 'Content-Type: application/json' \ -d '{"model": "Inkling-2-Mini", "messages": [{"role": "user", "content": "Hello"}], "chat_template_kwargs": {"enable_thinking": false}}' ``` ## Performance vs llama.cpp | metric | llama.cpp | Loom | margin vs best llama.cpp | roofline | Loom % of roofline | |---|---|---|---|---|---| | decode tok/s, short prompt | 15.7 | 54.2 [54.0, 54.4] (95% CI) (acceptance 20 %) | +245 % | 40.4 | 134 % ‡ | | decode tok/s, 2k context | 14.9 | 52.8 [51.2, 53.3] (95% CI) (acceptance 24 %) | +254 % | 42.2 | 125 % ‡ | | decode tok/s, 32k context | 10.7 | 43.1 [42.0, 43.8] (95% CI) (acceptance 19 %) | +303 % | 35.3 | 122 % ‡ | | prefill tok/s, 1k document | 292.8 | 1992.1 [1990.3, 2002.7] (95% CI) | +580 % | 4762.1 | 42 % | | prefill tok/s, 2k document | 278.6 | 2200.3 [2190.4, 2210.1] (95% CI) | +690 % | 4614.1 | 48 % | | prefill tok/s, 8k document | 241.5 | 2363.7 [2361.0, 2378.4] (95% CI) | +879 % | 4469.7 | 53 % | | prefill tok/s, 16k document | 203.9 | 2297.5 [2295.7, 2307.8] (95% CI) | +1027 % | 4297.3 | 53 % | | prefill tok/s, 32k document | 158.1 | 2174.1 [2171.3, 2187.3] (95% CI) | +1275 % | 3989.5 | 54 % | | 4 streams, aggregate tok/s (drafting off) | 39.4 | 108.3 [107.8, 109.4] (95% CI) | — | 211.8 | 51 % | | 4 streams, aggregate tok/s (drafting on) | n/a | 108.4 [108.1, 108.6] (95% CI) (acceptance 0 %) | — | 99.3 | 109 % ‡ | | speculative decoding, drafted tokens accepted | — | 44 % ¹ | — | n/a | n/a | **Decode by content class** | content class | Loom tok/s | drafted tokens accepted | |---|---|---| | prose | 55.8 [55.1, 55.9] (95% CI) | 21 % | | code | 63.7 [63.0, 63.8] (95% CI) | 34 % | | chat | 53.4 [52.7, 53.5] (95% CI) | 17 % | **Methodology** - Compared: Loom against llama.cpp ROCm `llamacpp-rocm/b1383`; the same GGUF, the same historical baseline and re-measured Loom jobs, the same prompts; Loom served with the active wait. Values are the median of 4 sessions (a session's value is the median of its samples: 3 samples for decode, decode_2k, decode_32k, prefill_1k, prefill_2k, prefill_8k, prefill_16k, prefill_32k) (4 streams: median of 4); Loom is timed by the client, llama.cpp by its server. - llama.cpp: one session on 2026-11-22 (llamacpp-rocm b1383); Loom: re-measured on 2026-11-25, 4 sessions - Out of the box on both engines: Loom serves the preset shipped in this package; llama.cpp runs its build defaults plus only the server arguments listed below (offload, context and slots). No tuning sweep on either engine. - Drafting, 1-stream rows (decode, decode_2k, decode_32k, prefill): Loom DFlash depth 3; llama.cpp ROCm no drafting (NOT the same choice on both engines). Each engine is loaded once for all these rows. - 4 streams: 4 concurrent requests, the same prompt, 120 generated tokens each, T=1, top_p=1, top_k=0 (full vocabulary), a different fixed seed per stream; aggregate = all generated tokens / wall time from the first request to the last token, prefill included. Drafting off on both engines; streams4_drafted is the same measurement with Loom drafting on (shipped default). - Rows: decode = short-context decode; decode_2k / decode_32k = decode after a ~2k / ~32k-token context; prefill_Nk = prompt processing of an N k-token prompt; streams4 = 4-stream aggregate decode. A margin within +-3 % (the measured same-runner noise) is a tie. - llama.cpp ROCm server arguments: `-ngl 99 -cram 0 -c 38000 -kvu -np 1 --temp 1.0 --top-p 1.0 --top-k 0 --min-p 0.0 (c4: -c 35024 -np 4)`. - Loom measured on AMD RYZEN AI MAX+ 395 w/ Radeon 8060S, AMD Radeon 8060S Graphics, Ubuntu 24.04.4 LTS, a named machine. - Margin vs best llama.cpp: (Loom / max(ROCm, Vulkan) - 1) × 100 %, using the available measured tokens/s for each row on this GPU. With only one valid backend, that backend is used; with neither, the margin is not measured. Raw backend values and their measurement sources are retained below and in the table. - Historical llama.cpp four-stream workload is not recorded as this wall-time workload; its value is retained, not relabelled or used for a margin. - Confidence intervals: 95% percentile bootstrap over independent session medians (2000 resamples, seed 0); approximate with small session counts. Duplicate evidence does not add sessions. - Measured 2026-11-25; device AMD RYZEN AI MAX+ 395 w/ Radeon 8060S, AMD Radeon 8060S Graphics, Ubuntu 24.04.4 LTS; hrx-loom `0.2.0` (hrx-system `0cd370f`); source: named-machine run. - ¹ Measured 2026-11-25; device AMD RYZEN AI MAX+ PRO 395 w/ Radeon 8060S, AMD Radeon 8060S Graphics, Ubuntu 24.04; hrx-loom unknown; source: local run. - Drafted tokens accepted: the share of the drafter's proposed tokens the model accepted during the `spec` gate's requests. - ‡ measured above the modeled ceiling; the roofline is an estimate (228 GB/s effective bandwidth). - Roofline: the hardware ceiling for this GGUF on AMD Ryzen AI Max+ 395 "Strix Halo" (gfx1151) at 228 GB/s and 44 TFLOP/s sustained at 85 W (spec 59), from loom-roofline `roofline.py` (loom-skills unknown commit); decode rows with speculative decoding: verify passes × (1 + acceptance × depth 3) tokens per pass, the drafter's cost not counted, with the acceptance measured in the row's own session: decode 20 %, decode at 2k 24 %, decode at 32k 19 %; single-pass ceiling (no acceptance measured on this package) for 4 streams drafted; 4 streams run without drafting, so its ceiling is single-pass; the 4-stream ceiling of this mixture-of-experts model assumes the four streams route to the same experts (the bound a run may not exceed). - — not measured; n/a not applicable. **Environment (Loom measurement)** - Box: halo3 (xsj-aimlab-halo-02) (NucBox_EVO-X2; AMD RYZEN AI MAX+ 395 w/ Radeon 8060S, Radeon 8060S gfx1151, 123 GiB RAM visible to the OS; Ubuntu 24.04.4 LTS; firmware American Megatrends International, LLC. EVO-X2 1.12 12/09/2025). - Power limit (W): not recorded. - Kernel: 7.0.0-43-generic. - ROCm: none installed (Loom runs on the hrx-loom 0.2.0 HAL; no ROCm runtime). - Mesa: mesa-vulkan-drivers 25.2.8-0ubuntu0.24.04.5 (not used by Loom). - BIOS UMA split: 2 GiB GPU carve-out (mem_info_vram_total), 110.0 GiB GTT. - Clock policy: power profile performance (powerprofilesctl); power_dpm_force_performance_level auto; sclk DPM levels 600/1100/2900 MHz; package power cap not exposed by hwmon, so not recorded. - Cool-start policy: each session starts a fresh loom-serve after the GPU has been idle (busy 0 %) with edge temperature <= 60 C for 45 s (wait capped at 480 s, the reached values are recorded); the same policy before every session; sessions strictly one server at a time. **Sampling (Loom measurement)** - T=1, top_p=1, top_k=0 (0 = full vocabulary); seeds: 42, 43, 44, 45, 1000, 1001, 1002, 1003, 1004, 1005, 1006, 1007, 1008, 2000, 2001, 2002, 3000, 3001, 3002. ## Features | feature | status | detail | |---|---|---| | API | ✅ | OpenAI-style `/v1/chat/completions` | | tool calling | ✅ | OpenAI-style `tools` and `tool_calls` | | reasoning / thinking | ✅ | on by default; `chat_template_kwargs: {"enable_thinking": false}` turns it off | | reasoning effort | ✅ | `reasoning_effort`: none, minimal, low, medium, high, xhigh, max (default high) | | speculative decoding | ✅ | DFlash, depth 3, on by default; drafter [unsloth/Inkling-2-Mini-GGUF](https://huggingface.co/unsloth/Inkling-2-Mini-GGUF) | | image input | ✅ | OpenAI-style `image_url` parts; projector `mmproj-F16.gguf` | | audio input / output | — | not applicable | | sampling | ✅ | `temperature`, `top_p`, `top_k`, `seed` | | context size | ✅ | 262,144 tokens per request | | concurrency | ✅ | 4 concurrent requests | | max output tokens | ✅ | 4,096 (preset `max_tokens`) | ## Correctness | gate | description | result | |---|---|---| | `kernel_tests` | Unit tests of the generated kernels against reference implementations | ❌ no evidence | | `golden` | llama.cpp reference recorded on the same GGUF: greedy tokens and top-5 log-probs, short prompts and 1k-32k documents | ✅ pass ¹ | | `compare` | Greedy output vs the llama.cpp reference, token by token; every divergence is a near-tie | ✅ pass ¹ | | `vision` | Image input vs llama.cpp with the same projector: identical prompt tokens, replies equal up to near-ties | ✅ pass ¹ | | `consistency` | Concurrent requests give the same output as the same requests run alone | ✅ pass ¹ | | `spec` | seed-for-seed identical tokens, drafted vs undrafted, at T=1 | ✅ pass ¹ | | `agent` | Multi-turn tool-calling loop: exact prompt rendering, history reuse, valid tool calls, output vs llama.cpp | ✅ pass ¹ | | `agent_think_off` | The tool-calling loop with thinking off | ✅ pass ¹ | | `sampling` | temperature, top_k and seed behave as specified; first-token distribution matches llama.cpp | ✅ pass ¹ | | `logits` | Host logits readback (llm.logits on): at T=0 every returned row's argmax is the device's token, the top-k matches llama.cpp, greedy text is unchanged | ❌ no evidence | | `decision` | Decision answers (choice, score, noul probabilities) vs llama.cpp on the same prompts | — not applicable | - ¹ local run, LEVEL=full, 2026-11-25; device AMD RYZEN AI MAX+ PRO 395 w/ Radeon 8060S, AMD Radeon 8060S Graphics, Ubuntu 24.04; hrx-loom `0.2.0` (hrx-system `0cd370f`). - Gates are the loom-benchmark correctness gates (`gates.sh`); a gate without a recorded run shows no evidence. ## Acknowledgments Techniques in this package that came from other people's work (ideas only, no code copied): | technique | credit | |---|---| | Drafter proposals coupled to the request's own Gumbel-Max draw (exact at T>0) | [francescobozzo, gufo-org/gufo#1340](https://github.com/gufo-org/gufo/pull/1340); [Majid Daliri, Christopher Musco, Ananda Theertha Suresh](https://arxiv.org/abs/2408.07978); [Joseph Rowan, Buu Phan, Ashish Khisti](https://arxiv.org/abs/2506.05632); [ashalliants, ashalliants/ninfer-3090#561](https://github.com/ashalliants/ninfer-3090/pull/561) | | Per-step drafter-confidence verify width | [francescobozzo, gufo#1340 "Lead 3"](https://github.com/gufo-org/gufo/pull/1340) | | Direct FP16 attention output (flash2_o16, "E1(b)") for prefill | [francescobozzo, gufo#1340 (E1(b))](https://github.com/gufo-org/gufo/pull/1340) | | Coalesced b128 conv-weight loads in short-conv KV prep | [francescobozzo, gufo#1340 (small-kernel latency focus)](https://github.com/gufo-org/gufo/pull/1340) | | MoE gate/up rows-per-wave sweep (R=2, 16 waves per WG) | [danielhanchen, unslothai/llama.cpp#417](https://github.com/unslothai/llama.cpp/pull/417) | | Register-packed f16 P->A WMMA pass-through in far attention | [woct0rdho, feather-attn](https://github.com/woct0rdho/feather-attn) | | Fused Q8-out Q8_0 MoE decode matvec | [Annieren, ggml-org/llama.cpp#26301](https://github.com/ggml-org/llama.cpp/pull/26301); [shawnshekari](https://github.com/shawnshekari/strixite) | | Single-token multi-matrix projection fusion (-136 dispatches/step) | [shawnshekari](https://github.com/shawnshekari/strixite) | | DSpark drafter graph (3-layer DFlare plus Markov head) | [pwilkin, ggml-org/llama.cpp#32218 (`graph_inkling2`)](https://github.com/ggml-org/llama.cpp/pull/32218) | | Inkling-2 target layout (inkling2 / inkling2_loop tensor names) | [ggml-org/llama.cpp#32694](https://github.com/ggml-org/llama.cpp/pull/32694); [ggml-org/llama.cpp#32695](https://github.com/ggml-org/llama.cpp/pull/32695); [Unsloth unsloth/Inkling-2-Mini-GGUF rev 8078d149](https://huggingface.co/unsloth/Inkling-2-Mini-GGUF) | | FlashAttention-2 online-softmax tiling | [Tri Dao, FlashAttention-2](https://arxiv.org/abs/2307.08691) | ## Files - `model.json` / `model.json.lock`: the card and the pinned source files (sha256 checked by `loom-fetch`). - `program/*.loom`, `weights.loom`: the generated Loom programs. - `tokenizer.json`: the tokenizer. - `llm_config.json`: the configuration the programs were generated from. - `info.json`: the measurements, gate evidence and versions this card shows; everything else comes from the files above. - [raw/perf_loom.jsonl](raw/perf_loom.jsonl): raw per-run results (JSON lines). - [raw/c4_off.jsonl](raw/c4_off.jsonl): raw per-run results (JSON lines). - [raw/c4_on.jsonl](raw/c4_on.jsonl): raw per-run results (JSON lines). - [raw/c4_steady_off.jsonl](raw/c4_steady_off.jsonl): raw per-run results (JSON lines). - [raw/sensors.jsonl](raw/sensors.jsonl): raw per-run results (JSON lines). - [raw/env.json](raw/env.json): raw JSON record. - [raw/sampling.json](raw/sampling.json): raw JSON record. - [raw/block.log](raw/block.log): measurement log. - [raw/commands.txt](raw/commands.txt): measurement log. - [raw/gates_t68_LEVEL_full.json](raw/gates_t68_LEVEL_full.json): raw JSON record. - [reproduce.sh](reproduce.sh): reproduce script. - `REPORT.md`: how the values above were measured: setup, commands and the value of every run. Versions: card schema `loom-card/3`; loom-skills unknown; hrx-loom `0.2.0` (hrx-system `0cd370f`); card generator unknown. Source files, fetched by `loom-fetch` from their own repositories: - checkpoint: [unsloth/Inkling-2-Mini-GGUF](https://huggingface.co/unsloth/Inkling-2-Mini-GGUF) @ `8078d14`, `Inkling-2-Mini-UD-Q4_K_XL.gguf` - drafter: [unsloth/Inkling-2-Mini-GGUF](https://huggingface.co/unsloth/Inkling-2-Mini-GGUF) @ `8078d14`, `dspark-Inkling-2-Mini-Q8_0.gguf` - projector: [unsloth/Inkling-2-Mini-GGUF](https://huggingface.co/unsloth/Inkling-2-Mini-GGUF) @ `8078d14`, `mmproj-F16.gguf`