Image-Text-to-Text
MLX
Safetensors
inkling2_loop
apple-silicon
Mixture of Experts
dspark
speculative-decoding
mlx-vlm
conversational
4-bit precision
Instructions to use netprojects/Inkling-2-Mini-LayerFit-MLX-3bit with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- MLX
How to use netprojects/Inkling-2-Mini-LayerFit-MLX-3bit with MLX:
# Make sure mlx-vlm is installed # pip install --upgrade mlx-vlm from mlx_vlm import load, generate from mlx_vlm.prompt_utils import apply_chat_template from mlx_vlm.utils import load_config # Load the model model, processor = load("netprojects/Inkling-2-Mini-LayerFit-MLX-3bit") config = load_config("netprojects/Inkling-2-Mini-LayerFit-MLX-3bit") # Prepare input image = ["http://images.cocodataset.org/val2017/000000039769.jpg"] prompt = "Describe this image." # Apply chat template formatted_prompt = apply_chat_template( processor, config, prompt, num_images=1 ) # Generate output output = generate(model, processor, formatted_prompt, image) print(output) - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- LM Studio
- Pi
How to use netprojects/Inkling-2-Mini-LayerFit-MLX-3bit with Pi:
Start the MLX server
# Install MLX LM: uv tool install mlx-lm # Start a local OpenAI-compatible server: mlx_lm.server --model "netprojects/Inkling-2-Mini-LayerFit-MLX-3bit"
Configure the model in Pi
# Install Pi: npm install -g @earendil-works/pi-coding-agent # Add to ~/.pi/agent/models.json: { "providers": { "mlx-lm": { "baseUrl": "http://localhost:8080/v1", "api": "openai-completions", "apiKey": "none", "models": [ { "id": "netprojects/Inkling-2-Mini-LayerFit-MLX-3bit" } ] } } }Run Pi
# Start Pi in your project directory: pi
- Hermes Agent
How to use netprojects/Inkling-2-Mini-LayerFit-MLX-3bit with Hermes Agent:
Start the MLX server
# Install MLX LM: uv tool install mlx-lm # Start a local OpenAI-compatible server: mlx_lm.server --model "netprojects/Inkling-2-Mini-LayerFit-MLX-3bit"
Configure Hermes
# Install Hermes: curl -fsSL https://hermes-agent.nousresearch.com/install.sh | bash hermes setup # Point Hermes at the local server: hermes config set model.provider custom hermes config set model.base_url http://127.0.0.1:8080/v1 hermes config set model.default netprojects/Inkling-2-Mini-LayerFit-MLX-3bit
Run Hermes
hermes
- Atomic Chat
- OpenClaw
How to use netprojects/Inkling-2-Mini-LayerFit-MLX-3bit with OpenClaw:
Start the MLX server
# Install MLX LM: uv tool install mlx-lm # Start a local OpenAI-compatible server: mlx_lm.server --model "netprojects/Inkling-2-Mini-LayerFit-MLX-3bit"
Configure OpenClaw
# Install OpenClaw: npm install -g openclaw@latest # Register the local server and set it as the default model: openclaw onboard --non-interactive --mode local \ --auth-choice custom-api-key \ --custom-base-url http://127.0.0.1:8080/v1 \ --custom-model-id "netprojects/Inkling-2-Mini-LayerFit-MLX-3bit" \ --custom-provider-id mlx-lm \ --custom-compatibility openai \ --custom-text-input \ --accept-risk \ --skip-health
Run OpenClaw
openclaw agent --local --agent main --message "Hello from Hugging Face"
Card: LayerFit™ section and comparison
Browse files
README.md
CHANGED
|
@@ -15,13 +15,13 @@ tags:
|
|
| 15 |
- mlx-vlm
|
| 16 |
---
|
| 17 |
|
| 18 |
-
# Inkling 2 Mini for Apple Silicon (MLX, 3-bit LayerFit, for 24 GB Macs, + DSpark)
|
| 19 |
|
| 20 |
✅ Works with stock mlx-vlm (main now, next release) · OpenAI tool calls via [inkling2-mlx](https://github.com/internet-projects/inkling2-mlx)
|
| 21 |
|
| 22 |
[thinkingmachines/Inkling-2-Mini](https://huggingface.co/thinkingmachines/Inkling-2-Mini) (revision `6e7c824`) for MLX on
|
| 23 |
Apple Silicon, with its DSpark speculative-decoding draft bundled (`mtp.safetensors`) and its vision encoder included.
|
| 24 |
-
This build uses standard MLX affine quantization with a per-layer recipe found by our LayerFit search: each group of layers gets its own bits, chosen by measuring how much each choice changes the model's output. The routed experts, re-quantized from their released NVFP4 / MXFP8 values, are 4-bit (group 64) in layers 0–17, except the gate and down projections of layer 14 and the up projection of layer 15 (3-bit, group 64), and 3-bit (group 128) in layers 18–23. Attention is 8-bit (group 64) in layers 6, 8 and 12, 5-bit in layers 19–22 and 6-bit in the others. Embeddings and the output layer are 5-bit and the vision encoder is 4-bit (all group 64). The full per-layer recipe is in `quant-recipe.json`. Size: 14.1 GB plus the 0.64 GB draft, the same as the 3-bit build it replaces.
|
| 25 |
|
| 26 |
Inkling 2 Mini is Thinking Machines' looped mixture-of-experts model: 26.4B parameters, about 3.4B active per token,
|
| 27 |
24 layers of which the middle twelve run three times (48 layer passes per token), text and image input, up to 1M tokens of context.
|
|
@@ -57,12 +57,20 @@ Each pick leaves room for macOS and a long prompt (the download is at most about
|
|
| 57 |
columns are explained under "What was checked".
|
| 58 |
|
| 59 |
<!-- layerfit-card:start -->
|
| 60 |
-
## LayerFit
|
| 61 |
|
| 62 |
-
LayerFit is how
|
| 63 |
-
some lose a lot when squeezed, others barely notice. LayerFit measures each
|
| 64 |
-
the recipe that stays closest to the original model at a fixed size, and spends the bits where they
|
| 65 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 66 |
<!-- layerfit-card:end -->
|
| 67 |
|
| 68 |
## What changed (26 November 2026)
|
|
@@ -159,8 +167,6 @@ MacBook Pro M5 Max (128 GB), idle, 21 November 2026; median of 3 runs. Decode: 5
|
|
| 159 |
| 2.5bit | not measured | not measured | not measured |
|
| 160 |
| 2bit | not measured | not measured | not measured |
|
| 161 |
|
| 162 |
-
The 4bit and 3bit rows, and the inkling2-mlx speeds below, were measured on the earlier 4-bit and 3-bit files. The LayerFit files that replaced them on 26 November 2026 are the same size but keep attention at 6 to 8 bits, so their speeds can differ slightly; they have not been re-measured yet.
|
| 163 |
-
|
| 164 |
The draft's default block size (8) is slower on this model; use 3 or 4 as below.
|
| 165 |
|
| 166 |
With [inkling2-mlx](https://github.com/internet-projects/inkling2-mlx) v0.2.6 (faster decode and prompt reading, on by default; same greedy text as the original MLX-VLM, KL max 0.014), on the 4-bit build plain generation is 84.1 tok/s with a 1K prompt and 79.7 tok/s with an 8K prompt (original MLX-VLM: 40.7 / 38.5; v0.2.4: 59.5 / 57.2), and a 256-token chat answer runs at 86.4 tok/s (MLX-VLM 36.7). DSpark (block 4) reaches 125.0 tok/s at 1K on text that repeats earlier text, but on ordinary chat it is now slower than plain generation (64.3 tok/s), so use DSpark for code edits and rewrites and plain generation for chat (greedy, 23 November 2026; a separate run from the table above). Prompt reading (prefill) is 12-16% faster than in earlier versions: 1642 tok/s at 8.7K and 1608 tok/s at 16K (was 1467 / 1382). `INKLING2_FAST_DECODE=0` switches back. With v0.2.7, sampled DSpark checks drafts with speculative sampling (same output law as plain generation): on the 4-bit build a rewrite at temperature 1.0 runs at 97.4 tok/s with DSpark vs 83.3 plain (with top-p 0.95: 96.6 vs 82.0), while chat stays faster without DSpark (25 November 2026, 256 tokens, median of 3).
|
|
@@ -185,7 +191,7 @@ harnesses and settings; a selection of their table):
|
|
| 185 |
|
| 186 |
## What was checked
|
| 187 |
|
| 188 |
-
On the same MacBook Pro M5 Max (128 GB) as the other builds, 26 November 2026, for the LayerFit files of this build, with [inkling2-mlx](https://github.com/internet-projects/inkling2-mlx) v0.2.4 (MLX-VLM plus Inkling's tool-call parser).
|
| 189 |
|
| 190 |
- **Against Thinking Machines' code.** Their Transformers implementation (pull request #51050) ran on the CPU with the
|
| 191 |
released weights, on 12 short chat texts (488 answer positions). This build gave the same next token at
|
|
@@ -196,7 +202,7 @@ On the same MacBook Pro M5 Max (128 GB) as the other builds, 26 November 2026, f
|
|
| 196 |
- **Coding:** 3/3 short Python tasks passed their asserts. **Thinking** (reasoning `low`): 2/2
|
| 197 |
questions answered correctly after one closed thinking block. **Vision:** named the red square and blue circle of a test image.
|
| 198 |
- **Memory** (inkling2-mlx v0.2.4 defaults): weights 14.1 GB; peak 20.44 GB with a 4K-token prompt, 21.36 GB with an 8K-token prompt and 27.18 GB with a 32K-token prompt. With a smaller prefill step (measured on the earlier files, which are the same size, stock MLX-VLM main, 8K-token prompt, draft not loaded): 17.1 GB at `prefill_step_size=512`, 16.0 GB at 256 and 15.3 GB at 128. On a 24 GB Mac (default GPU limit about 16 GB) use `prefill_step_size=128` (`--prefill-step-size 128`) and leave the DSpark draft off for prompts up to 8K tokens; with the draft (+0.64 GB) or longer prompts, raise the limit first (`sudo sysctl iogpu.wired_limit_mb=18432`, resets at restart).
|
| 199 |
-
- **DSpark:** the bundled draft
|
| 200 |
|
| 201 |
Known limitation of the current server: when the model calls a tool, `content` can also carry a short sentence of its
|
| 202 |
reasoning and the tool name.
|
|
@@ -207,6 +213,6 @@ Apache-2.0, as Inkling 2 Mini. Use of the model is also governed by Thinking Mac
|
|
| 207 |
[Model Acceptable Use Policy](https://thinkingmachines.ai/model-acceptable-use-policy/). `LICENSE` is the Apache-2.0
|
| 208 |
text and `NOTICE` describes the conversion. Inkling 2 Mini is by Thinking Machines Lab; please cite their work.
|
| 209 |
|
| 210 |
-
Published by [NetProjects](https://netprojects.com) (Internet Projects Ltd). Not affiliated with Thinking Machines.
|
| 211 |
|
| 212 |
More MLX builds from NetProjects: [huggingface.co/netprojects](https://huggingface.co/netprojects) · [netprojects.com](https://netprojects.com)
|
|
|
|
| 15 |
- mlx-vlm
|
| 16 |
---
|
| 17 |
|
| 18 |
+
# Inkling 2 Mini for Apple Silicon (MLX, 3-bit LayerFit™, for 24 GB Macs, + DSpark)
|
| 19 |
|
| 20 |
✅ Works with stock mlx-vlm (main now, next release) · OpenAI tool calls via [inkling2-mlx](https://github.com/internet-projects/inkling2-mlx)
|
| 21 |
|
| 22 |
[thinkingmachines/Inkling-2-Mini](https://huggingface.co/thinkingmachines/Inkling-2-Mini) (revision `6e7c824`) for MLX on
|
| 23 |
Apple Silicon, with its DSpark speculative-decoding draft bundled (`mtp.safetensors`) and its vision encoder included.
|
| 24 |
+
This build uses standard MLX affine quantization with a per-layer recipe found by our **LayerFit™** search: each group of layers gets its own bits, chosen by measuring how much each choice changes the model's output. The routed experts, re-quantized from their released NVFP4 / MXFP8 values, are 4-bit (group 64) in layers 0–17, except the gate and down projections of layer 14 and the up projection of layer 15 (3-bit, group 64), and 3-bit (group 128) in layers 18–23. Attention is 8-bit (group 64) in layers 6, 8 and 12, 5-bit in layers 19–22 and 6-bit in the others. Embeddings and the output layer are 5-bit and the vision encoder is 4-bit (all group 64). The full per-layer recipe is in `quant-recipe.json`. Size: 14.1 GB plus the 0.64 GB draft, the same as the 3-bit build it replaces.
|
| 25 |
|
| 26 |
Inkling 2 Mini is Thinking Machines' looped mixture-of-experts model: 26.4B parameters, about 3.4B active per token,
|
| 27 |
24 layers of which the middle twelve run three times (48 layer passes per token), text and image input, up to 1M tokens of context.
|
|
|
|
| 57 |
columns are explained under "What was checked".
|
| 58 |
|
| 59 |
<!-- layerfit-card:start -->
|
| 60 |
+
## LayerFit™: same size, closer to the original
|
| 61 |
|
| 62 |
+
**LayerFit™** is how NetProjects builds its small quants. A plain build squeezes every layer the same way, but layers are
|
| 63 |
+
not equal: some lose a lot when squeezed, others barely notice. LayerFit™ measures each part of each layer on its own,
|
| 64 |
+
then searches for the recipe that stays closest to the original model at a fixed size, and spends the bits where they
|
| 65 |
+
matter. Every LayerFit™ recipe is scored against the original model before we publish it. The result is a normal MLX
|
| 66 |
+
build: it loads in stock MLX-VLM, with no custom runtime. At the same 14.1 GB, this build is closer to Thinking Machines' code than the 3-bit files it replaced (mean KL 0.0225 instead of 0.0424); see "What changed".
|
| 67 |
+
|
| 68 |
+
| Inkling 2 Mini, same size | Same next token as Thinking Machines' code | KL vs their code |
|
| 69 |
+
|---|---|---|
|
| 70 |
+
| Standard 3-bit, 14.1 GB | 95.5% | 0.0424 |
|
| 71 |
+
| **LayerFit™ 3-bit, 14.1 GB (this build)** | **95.5%** | **0.0225 (47% lower)** |
|
| 72 |
+
|
| 73 |
+
All Inkling 2 Mini LayerFit™ builds: [4-bit](https://huggingface.co/netprojects/Inkling-2-Mini-LayerFit-MLX-4bit) · [3-bit](https://huggingface.co/netprojects/Inkling-2-Mini-LayerFit-MLX-3bit) · [2.5-bit](https://huggingface.co/netprojects/Inkling-2-Mini-LayerFit-MLX-2.5bit) · [2-bit, for 16 GB Macs](https://huggingface.co/netprojects/Inkling-2-Mini-LayerFit-MLX-2bit). Also: [Qwen3.8-27B LayerFit™](https://huggingface.co/netprojects/Qwen3.8-27B-LayerFit-MLX-4bit).
|
| 74 |
<!-- layerfit-card:end -->
|
| 75 |
|
| 76 |
## What changed (26 November 2026)
|
|
|
|
| 167 |
| 2.5bit | not measured | not measured | not measured |
|
| 168 |
| 2bit | not measured | not measured | not measured |
|
| 169 |
|
|
|
|
|
|
|
| 170 |
The draft's default block size (8) is slower on this model; use 3 or 4 as below.
|
| 171 |
|
| 172 |
With [inkling2-mlx](https://github.com/internet-projects/inkling2-mlx) v0.2.6 (faster decode and prompt reading, on by default; same greedy text as the original MLX-VLM, KL max 0.014), on the 4-bit build plain generation is 84.1 tok/s with a 1K prompt and 79.7 tok/s with an 8K prompt (original MLX-VLM: 40.7 / 38.5; v0.2.4: 59.5 / 57.2), and a 256-token chat answer runs at 86.4 tok/s (MLX-VLM 36.7). DSpark (block 4) reaches 125.0 tok/s at 1K on text that repeats earlier text, but on ordinary chat it is now slower than plain generation (64.3 tok/s), so use DSpark for code edits and rewrites and plain generation for chat (greedy, 23 November 2026; a separate run from the table above). Prompt reading (prefill) is 12-16% faster than in earlier versions: 1642 tok/s at 8.7K and 1608 tok/s at 16K (was 1467 / 1382). `INKLING2_FAST_DECODE=0` switches back. With v0.2.7, sampled DSpark checks drafts with speculative sampling (same output law as plain generation): on the 4-bit build a rewrite at temperature 1.0 runs at 97.4 tok/s with DSpark vs 83.3 plain (with top-p 0.95: 96.6 vs 82.0), while chat stays faster without DSpark (25 November 2026, 256 tokens, median of 3).
|
|
|
|
| 191 |
|
| 192 |
## What was checked
|
| 193 |
|
| 194 |
+
On the same MacBook Pro M5 Max (128 GB) as the other builds, 26 November 2026, for the LayerFit files of this build, with [inkling2-mlx](https://github.com/internet-projects/inkling2-mlx) v0.2.4 (MLX-VLM plus Inkling's tool-call parser).
|
| 195 |
|
| 196 |
- **Against Thinking Machines' code.** Their Transformers implementation (pull request #51050) ran on the CPU with the
|
| 197 |
released weights, on 12 short chat texts (488 answer positions). This build gave the same next token at
|
|
|
|
| 202 |
- **Coding:** 3/3 short Python tasks passed their asserts. **Thinking** (reasoning `low`): 2/2
|
| 203 |
questions answered correctly after one closed thinking block. **Vision:** named the red square and blue circle of a test image.
|
| 204 |
- **Memory** (inkling2-mlx v0.2.4 defaults): weights 14.1 GB; peak 20.44 GB with a 4K-token prompt, 21.36 GB with an 8K-token prompt and 27.18 GB with a 32K-token prompt. With a smaller prefill step (measured on the earlier files, which are the same size, stock MLX-VLM main, 8K-token prompt, draft not loaded): 17.1 GB at `prefill_step_size=512`, 16.0 GB at 256 and 15.3 GB at 128. On a 24 GB Mac (default GPU limit about 16 GB) use `prefill_step_size=128` (`--prefill-step-size 128`) and leave the DSpark draft off for prompts up to 8K tokens; with the draft (+0.64 GB) or longer prompts, raise the limit first (`sudo sysctl iogpu.wired_limit_mb=18432`, resets at restart).
|
| 205 |
+
- **DSpark:** the bundled draft loads with this build; greedy output follows the model's own except at near-ties (checked: divergences only where the top two tokens were within 0.2 logits). Speeds are under "Speed".
|
| 206 |
|
| 207 |
Known limitation of the current server: when the model calls a tool, `content` can also carry a short sentence of its
|
| 208 |
reasoning and the tool name.
|
|
|
|
| 213 |
[Model Acceptable Use Policy](https://thinkingmachines.ai/model-acceptable-use-policy/). `LICENSE` is the Apache-2.0
|
| 214 |
text and `NOTICE` describes the conversion. Inkling 2 Mini is by Thinking Machines Lab; please cite their work.
|
| 215 |
|
| 216 |
+
Published by [NetProjects](https://netprojects.com) (Internet Projects Ltd). LayerFit™ is a NetProjects trademark. Not affiliated with Thinking Machines.
|
| 217 |
|
| 218 |
More MLX builds from NetProjects: [huggingface.co/netprojects](https://huggingface.co/netprojects) · [netprojects.com](https://netprojects.com)
|