No description
  • Cuda 39%
  • C++ 31.4%
  • Python 24.9%
  • JavaScript 1.4%
  • CMake 1%
  • Other 2.2%
Find a file
Repository files (latest commit first)
Filename Latest commit message Latest commit date
2026-11-29 10:17:00 +03:00
.github README: Ling-3.2-air (128 B) in the model list, intro, download badges and credits, in every language 2026-11-27 01:10:16 +00:00
assets Repository presentation: new logo, issue forms, docs index, SECURITY.md (#881) 2026-11-06 12:37:00 +00:00
bench Quant-making tools and recipes are no longer in this repository 2026-11-25 14:23:24 +00:00
cmake Windows: ggml-cpu's AVX2/FMA/AVX-512 from the CPU itself, not from blockable CMake test programs 2026-11-27 23:27:49 +00:00
data Ling-3.2-air on its own engine, maya-ling: setup, server, MTP drafting, CPU lane, SSD expert tier and pictures (#1224) 2026-11-26 22:04:00 +00:00
docker Rename the internal strata names to maya: include/maya, namespace maya, MAYA_ build options and defines 2026-11-22 12:57:16 +00:00
docs docs(inkling2-mini): update for Maya v1.1.84, GSQ-RCO MMA, DSpark Q8_0, and --ablate 2026-11-29 10:17:00 +03:00
include/maya glm: retry auto prefill against the measured expert pool (#1254) 2026-11-27 13:22:50 +00:00
ref Ling-3.2-air on its own engine, maya-ling: setup, server, MTP drafting, CPU lane, SSD expert tier and pictures (#1224) 2026-11-26 22:04:00 +00:00
serve Merge v1184-quick: ds4_iq GEMV PRs #1292 #1293 #1294 #1296 #1308 #1314 #1315, #1254, #910 2026-11-27 20:12:57 +00:00
src ik2: add bit-exact grouped IQ/Q2_0 block MMA for DSpark and vectorized FP16 decode for prefill 2026-11-29 09:52:44 +03:00
tests ik2: add bit-exact grouped IQ/Q2_0 block MMA for DSpark and vectorized FP16 decode for prefill 2026-11-29 09:52:44 +03:00
third_party Metal: avoid GGML free-block exhaustion on long-context prefill (#742) 2026-11-02 13:16:22 +00:00
tools Inkling 2 Mini: GSQ-RCO files on maya-ik2, and per-visit multi-direction refusal ablation 2026-11-28 19:19:01 +03:00
.gitattributes v1.1.57: GLM-5.3 (744B) on Maya's GLM engine (NVIDIA from the V100 and AMD, up to 1M context), the setup header and model API fixes 2026-11-09 12:22:12 +00:00
.gitignore bench: keep every round's engine log, print a layout line per start, name differing facts in --compare 2026-11-24 20:00:02 +00:00
CHANGELOG.md CHANGELOG: v1.1.84's Windows build line 2026-11-28 01:03:24 +00:00
chat.py Server: --engine maya (the old name strata still accepted); MCP client and chat.py introduce themselves as Maya 2026-11-01 14:38:19 +00:00
CMakeLists.txt Windows: ggml-cpu's AVX2/FMA/AVX-512 from the CPU itself, not from blockable CMake test programs 2026-11-27 23:27:49 +00:00
CODE_OF_CONDUCT.md Add a pull request template and a code of conduct 2026-11-12 11:47:04 +00:00
CONTRIBUTING.md Rename the internal strata names to maya: include/maya, namespace maya, MAYA_ build options and defines 2026-11-22 12:57:16 +00:00
LICENSE README: created and led by Peasant Smith, co-maintained with @needmorevram (a byline, and a People entry first in the credits); LICENSE: Project Maya's own copyright line above the inherited one 2026-10-15 15:03:53 +01:00
LICENSE.deepseek-v41 DeepSeek-V4.1: prompts rendered with DeepSeek's reference encoder, agent tool histories kept (#300) 2026-10-20 20:01:57 +01:00
LICENSE.hy4-flash LICENSE.hy4-flash: the Tencent Hy License, as Tencent's repo has it 2026-11-19 00:46:28 +00:00
LICENSE.minimax-m31 MiniMax-M3.1-Flash in setup, server and dashboard: MiniMax's template plus Off, Auto by default, the card's sampling, contexts to 1M, pictures on 2026-10-26 16:47:06 +00:00
LICENSE.qwen-community-1.0 CYBER-FROST: Qwen-3.8-Flash-Next's Q5_K_M GGUF with its MTP drafter on the maya engine - the setup, experts straight from the GGUF, its efforts in the dashboard 2026-10-27 22:41:02 +00:00
maya.py Windows: ggml-cpu's AVX2/FMA/AVX-512 from the CPU itself, not from blockable CMake test programs 2026-11-27 23:27:49 +00:00
maya.sh Metal: GLM-5.3-Flash on Apple Silicon (maya-metal), experimental (#334) 2026-10-30 01:34:05 +00:00
README.ja.md README: DeepSeek speed rows from #1006 (2x RTX 4090 D) and #1242 (RTX 5090 + 2x RTX 3090) 2026-11-27 07:56:41 +00:00
README.md docs(inkling2-mini): update for Maya v1.1.84, GSQ-RCO MMA, DSpark Q8_0, and --ablate 2026-11-29 10:17:00 +03:00
README.pt-BR.md README: DeepSeek speed rows from #1006 (2x RTX 4090 D) and #1242 (RTX 5090 + 2x RTX 3090) 2026-11-27 07:56:41 +00:00
README.zh-CN.md README: DeepSeek speed rows from #1006 (2x RTX 4090 D) and #1242 (RTX 5090 + 2x RTX 3090) 2026-11-27 07:56:41 +00:00
SECURITY.md Repository presentation: new logo, issue forms, docs index, SECURITY.md (#881) 2026-11-06 12:37:00 +00:00
setup.py Windows: ggml-cpu's AVX2/FMA/AVX-512 from the CPU itself, not from blockable CMake test programs 2026-11-27 23:27:49 +00:00
setup.sh Metal: GLM-5.3-Flash on Apple Silicon (maya-metal), experimental (#334) 2026-10-30 01:34:05 +00:00
START-MAYA.bat Drop the experimental mark from AMD, Windows and the EXL3 quants 2026-11-04 00:22:06 +00:00
VERSION v1.1.84 2026-11-28 00:48:00 +00:00

Inkling 2 Mini on ONE RTX 3090: up to 131 tok/s plain, 231 with DSpark

Thinking Machines' 26B looped MoE, all of it in 24 GB of VRAM. Now on Project Maya v1.1.84 with full GSQ-RCO support (IQ3_S to IQ2_S: 125–131 tok/s plain, 184–231 tok/s with DSpark, ~2,510–2,570 tok/s prefill), Unsloth UD-Q4_K_XL (124 tok/s plain, 179 tok/s with DSpark), runtime refusal ablation (--ablate), dspark-Inkling-2-Mini-Q8_0.gguf & mtp.safetensors drafting, up to 344K context, images, and tools. Also runs on 8–16 GB GPUs, Linux and Windows, NVIDIA CUDA and AMD HIP, with continuous batching (--parallel) and host-RAM conversation caching (IK2_SESSION_CACHE_GB).

Read the guide · Quick start · GSQ-RCO Uncensored Pack (HF) · GSQ-RCO Weights · Unsloth Weights

Speed on ONE RTX 3090 (24 GB, 300 W)

All quants stay 100% resident in 24 GB VRAM (resident: every expert in VRAM) with FP8 KV (IK2_KV=fp8) and DSpark drafting (128K context in the benchmark table below; 262K + DSpark also fits with 6.7–8.9 GiB headroom on GSQ-RCO):

Quant Size on disk Plain decode, tok/s With DSpark drafter, tok/s Prefill 2K / 8K, tok/s Experts VRAM
GSQ-RCO IQ3_S 11.43 GB 125.4 (124.9 with --ablate) 183.8 (190.3 with --ablate) 2,511 / 2,556 9.2 GiB
GSQ-RCO IQ3_XXS 10.61 GB 126.5 198.6 2,515 / 2,561 8.4 GiB
GSQ-RCO Q2_K_XL 9.79 GB 128.6 208.6 2,519 / 2,566 7.8 GiB
GSQ-RCO IQ2_S 8.98 GB 131.2 231.3 2,528 / 2,572 7.0 GiB
Unsloth UD-Q4_K_XL 17.63 GB 124.0 179.3 2,481 / 2,530 14.7 GiB

On UD-Q4_K_XL across workloads (cold prompt every time, 1× RTX 3090, FP8 KV; llama.cpp b12590 gets 57.0 tok/s on prose and 42.7 at 65K): prose decodes at 126 tok/s plain / 131 with DSpark, new Python code hits 182–207 tok/s through the HTTP server, editing a document hits 212 tok/s, and a 64K-token document runs at 104–106 tok/s plain / 125 with DSpark (prefill up to 2,742 tok/s at 4K, 2,361 at 64K, 2,079 at 128K). Every launch and log is in the guide.

What you get

  • maya-ik2 (Project Maya v1.1.84), an engine for Inkling 2 Mini: the 24 layers, the loop (layers 6 to 17 run 3 times, 48 layer visits per token), the relative bias, the short convs, and the attention residuals.
  • GSQ-RCO low-bit quants at full tensor-core speed. Supports ISTA-DASLab's GSQ-RCO files (IQ3_S, IQ3_XXS, Q2_K_XL, IQ2_S) and llama.cpp master's inkling2_loop layout: dense non-Q8 projections repack to planar Q8_0 at load (IK2_REPACK_DENSE=1, wqkvrg/wqrg fused), routed experts run whole-superblock mma16816 tensor-core kernels (IQ1_S/M, IQ2_XXS/XS/S, IQ3_XXS/S gate_up and IQ4_NL/Q2_0 down), and verify windows use bit-exact grouped IQ/Q2_0 block MMA plus vectorized uint4 FP16 decode for prefill.
  • Built-in runtime refusal ablation (--ablate). Weights stay untouched. maya-ik2 projects single directions or per-visit multi-direction banks (ik2_ablate.hpp) out of the residual stream at runtime, per conversation, and individual API requests can toggle "ablate": true/false when loaded with --ablate-default off. Ready-to-use fitted direction banks for all 4 GSQ-RCO quants ship in alesha-pro/Inkling-2-Mini-GSQ-RCO-Uncensored-GGUF.
  • The whole model stays in 24 GB VRAM. All 3,072 experts (7.0–9.2 GiB on GSQ-RCO, 14.7 GiB on UD-Q4_K_XL), the dense weights, and an FP8 KV cache fit on one 24 GB card: up to 344,064 tokens without the drafter, 262,144 with it (GSQ-RCO keeps 6.7–8.9 GiB of headroom at 262K + DSpark).
  • Speculative decoding with DSpark (dspark-Inkling-2-Mini-Q8_0.gguf and mtp.safetensors). Both the Q8_0 GGUF drafter (dspark-Inkling-2-Mini-Q8_0.gguf) and Thinking Machines' BF16 mtp.safetensors are supported. The engine verifies 2 to 8 tokens at a time in one CUDA-graphed pass using grouped expert MMA (max |dlogit| = 0 bit-exact vs plain decode).
  • Runs on 8–16 GB GPUs too. Supports Maya's offload + CPU lane path (IK2_OFF / IK2_LANE, as well as ik2-mini-8gb.json which keeps experts in pinned host RAM with a VRAM cache at ~41 tok/s on an RTX 5070 Laptop 8 GB vs 12.5 tok/s in llama.cpp).
  • Continuous batching (--parallel N) and conversation caching (IK2_SESSION_CACHE_GB). Pass --parallel N (2 to 8, single GPU) to serve concurrent requests over a shared paged global KV pool (~205 tok/s aggregate for 4 concurrent 300-token prompts on one 3090). On --parallel 1, IK2_SESSION_CACHE_GB parks displaced conversations in host RAM so interleaved agent calls restore without re-prefilling.
  • Linux, Windows (MSVC / CUDA 13), and AMD (HIP). Native Windows builds work out of the box, and AMD RDNA 3 / 3.5 / 4 GPUs build via ROCm/HIP (-DMAYA_ENABLE_HIP=ON -DMAYA_PREFILL_MMQ=ON).
  • Images, tools, reasoning control, streaming through OpenAI and Anthropic compatible APIs on /v1.

Quick start

Linux or Windows (MSVC), an NVIDIA GPU (sm_80 or newer, CUDA 12.8+ / 13.x; 24 GB for full resident VRAM or 8 GB+ with offload) or an AMD GPU with ROCm/HIP, CMake 3.24+, Ninja, and Python 3.10+.

git clone https://github.com/alesha-pro/maya-inkling-mini && cd maya-inkling-mini
pip install numpy jinja2 regex pyyaml tqdm requests pillow psutil "jsonschema>=4.18,<5" huggingface_hub

# the engine (NVIDIA CUDA; set CMAKE_CUDA_ARCHITECTURES to your GPU, e.g. 86, 89, 120)
cmake -S . -B build -G Ninja -DCMAKE_BUILD_TYPE=Release -DMAYA_ENABLE_CUDA=ON \
  -DCMAKE_CUDA_ARCHITECTURES=86 -DMAYA_BUILD_TESTS=OFF
cmake --build build -j 24 --target maya-ik2

# the image encoder (skip it for text only)
cmake -S tools/vision -B build-vision -G Ninja -DCMAKE_BUILD_TYPE=Release -DLLAMA_DIR=third_party/llama.cpp
cmake --build build-vision -j 24 --target maya-vision

Option A: GSQ-RCO Uncensored pack (11.4 GB IQ3_S, runtime refusal ablation + DSpark)

hf download alesha-pro/Inkling-2-Mini-GSQ-RCO-Uncensored-GGUF \
  Inkling-2-Mini-GSQ-RCO-IQ3_S.gguf \
  refusal-directions/Inkling-2-Mini-GSQ-RCO-IQ3_S-refusal-direction.gguf \
  dspark-Inkling-2-Mini-Q8_0.gguf \
  mmproj-Inkling-2-Mini-BF16.gguf \
  --local-dir models
python tools/strata_tokenizer.py --gguf models/Inkling-2-Mini-GSQ-RCO-IQ3_S.gguf --out ik2 \
  --chat-template tools/ik2/chat_template.jinja --check

python serve/server.py --engine maya --config docs/inkling2-mini/ik2-mini-gsq-iq3s-uncensored.json --host 127.0.0.1 --port 18000

(Or pick iq3xxs, q2kxl, or iq2s with the matching file and config in docs/inkling2-mini/; you can also download --include "tokenizer/*" straight from the HF pack and copy models/tokenizer to ik2/tokenizer.)

Option B: Unsloth UD-Q4_K_XL (17.6 GB NVFP4/Q8_0)

hf download unsloth/Inkling-2-Mini-GGUF Inkling-2-Mini-UD-Q4_K_XL.gguf mmproj-BF16.gguf --local-dir models
hf download thinkingmachines/Inkling-2-Mini mtp.safetensors --local-dir models
python tools/strata_tokenizer.py --gguf models/Inkling-2-Mini-UD-Q4_K_XL.gguf --out ik2 \
  --chat-template tools/ik2/chat_template.jinja --check

python serve/server.py --engine maya --config docs/inkling2-mini/ik2-mini.json --host 127.0.0.1 --port 18000

For an AMD GPU (HIP), configure with -DMAYA_ENABLE_HIP=ON -DMAYA_PREFILL_MMQ=ON and your AMDGPU_TARGETS / CMAKE_HIP_ARCHITECTURES (for example gfx1201). See the guide for Windows MSVC and AMD HIP build flags.

Then talk to http://127.0.0.1:18000/v1 with any OpenAI or Anthropic client, model inkling-2-mini. docs/inkling2-mini/ includes 9 configs: 4 GSQ-RCO Uncensored configs (ik2-mini-gsq-{iq3s,iq3xxs,q2kxl,iq2s}-uncensored.json: DSpark Q8_0 drafter, 262K context, runtime --ablate, CPU vision) plus the 5 UD-Q4_K_XL configs (ik2-mini.json, ik2-mini-long.json, ik2-mini-text.json, ik2-mini-gpu-vision.json, ik2-mini-8gb.json). Add "--parallel", "4" to args in a config to serve concurrent requests.

Why it's faster than llama.cpp

llama.cpp runs about 7,350 kernel launches per token for this model. A token here is ~757 launches replayed as one CUDA graph, and the GPU never waits for the host between the embedding and the logits.

After that a token costs what its weights weigh: ~2.1–2.7 GB read from VRAM on GSQ-RCO (3.7 GB on UD-Q4_K_XL). Attention reads the KV cache at up to 846 GB/s, dense non-Q8 projections repack to planar Q8_0 (IK2_REPACK_DENSE=1) with fused wqkvrg/wqrg, and both NVFP4 and GSQ-RCO IQ/Q2_0 experts decode in registers straight into mma16816 tensor-core instructions (445 GB/s IQ3_S gate_up, 610 GB/s IQ4_NL down).

The drafter's window has its own path: the tokens' expert picks are grouped on the GPU so an expert is read once for all the tokens that picked it, and the verify window runs bit-exact grouped IQ/Q2_0 block MMA (T=2..8) inside one CUDA graph.

The guide has the details, and what didn't help.

Quality

  • GSQ-RCO speed kernels vs scalar reference: across all 4 GSQ-RCO quants with IK2_REPACK_DENSE=1, median KL is 0.00067–0.00143 on prose and 1.6e-7–4.0e-7 on code (0.000000 with IK2_REPACK_DENSE=0).
  • DSpark vs plain decode parity: under IK2_WINDOW_CHECK=1, greedy DSpark matches plain 1-token decode 100% bit-for-bit (max |dlogit| = 0) across all 4 GSQ-RCO quants and with --ablate on. ik2_kernels_test passes all checks (test_repack_q8p, 16 test_decode formats, test_experts_iq_mma, and bit-exact experts_block_iq == T=1).
  • Refusal ablation (--ablate): fitted per-quant dual-direction banks (none + high) remove ~95% of refusals on IQ3_S / IQ3_XXS / IQ2_S (~85% on Q2_K_XL) while keeping 62–64/64 harmless Alpaca prompts intact (full AdvBench, JailbreakBench, and KLD tables on the HF pack card).
  • Base UD-Q4_K_XL: on 96 GSM8K questions, greedy: 74 solved with plain decode and 77 with the drafter. Against the float64 reference in ref/inkling2.py, the engine picks the same top token on 45 to 46 of 47 positions. Batched --parallel 4 decode matches solo forward() with median KL ~3e-8 and 0 argmax disagreements (IK2_SLOTS_CHECK=32).

Limits

  • --parallel N (2 to 8 concurrent requests) is single-GPU and non-managed KV only; DSpark speculates when 1 slot is active and switches to batched decode when 2+ run together. Two GPUs run as expert parallel (IK2_EP=1) or tensor-parallel experts (IK2_TP=1) with --parallel 1, and the drafter runs on one GPU. IK2_SESSION_CACHE_GB applies to --parallel 1.
  • Supported GGUF formats: Thinking Machines / Maya-L (NVFP4 + Q8_0), Unsloth UD-Q4_K_XL / UD-IQ3_XXS, and ISTA-DASLab GSQ-RCO (IQ3_S, IQ3_XXS, Q2_K_XL, IQ2_S). UD-Q8_K_XL keeps the last 4 layers' experts in BF16 and is not loaded.
  • Decode slows down with depth, because 8 of the 48 layer visits attend over the full prefix: 16 KB of FP8 KV cache per token of context is read for every new token.
  • The drafter helps code, edits, and structured text. On free prose it accepts fewer tokens per window and the adaptive controller (IK2_DRAFT_ADAPT) falls back toward plain decode.
  • The image encoder runs on the CPU in the default configs.
  • Tested hardware: Linux on RTX 3090 (with gpu-unlock, Ubuntu 22.04, driver 610.43) and AMD RX 9070 XT / RX 7900 XTX (gfx1201, gfx1100); Windows 11 (MSVC + CUDA 13.5) on RTX 4090, RTX 5090, RTX 5070 Laptop 8 GB, and dual RTX 5080 + RTX 4060 Ti.

About this repo

This is Project Maya v1.1.84, the engine family by Peasant Smith (@mw00) and the Maya contributors, which grew out of Strata by Niko1221. maya-ik2 started as the Inkling 2 Small engine from Maya's pull requests #981 and #1079. This release combines upstream v1.1.84 with GSQ-RCO tensor-core MMA & planar Q8 dense repacking, DSpark grouped IQ block MMA, and per-visit multi-direction runtime refusal ablation (--ablate).

Community contributions merged here and upstreamed into Project Maya:

  • @cobra91: initial Windows / CUDA 13 port and two-GPU expert parallel.
  • @PrasoonPratham: Windows MSVC hardening (SIGUSR1, 64-bit offsets, PrefetchVirtualMemory, VirtualAlloc, CMake UTF-8 & Threads, #3).
  • @ImagineNotChetng: 8 GB GPU cache + CPU miss path at ~41 tok/s and ik2-mini-8gb.json (#4).
  • @joeldeteves: native --parallel continuous batching with paged global KV (#5).
  • @DeseretSaint: AMD HIP build and compatibility layer for maya-ik2 (#7).
  • @mkultraware: Windows serve_multi build fix (#10) and host-RAM conversation caching (IK2_SLOT_KEEP, #11, superseded in v1.1.84 by IK2_SESSION_CACHE_GB).

Core Inkling 2 Mini work is offered upstream in mw00/project-maya#1095. The rest of Maya (GLM-5.3, DeepSeek-V4.1-Flash, MiniMax-M3.1-Flash, Hy4-flash and the app around them) is in the tree; use upstream Maya for general Maya releases.

Weights: Inkling 2 Mini and its drafter by Thinking Machines, GGUF by Unsloth, GSQ-RCO quants by ISTA-DASLab, and GSQ-RCO Uncensored pack by alesha-pro.

License

The code is MIT, as upstream (LICENSE). The model weights are Apache 2.0.