moodmosaic

Inkling 2 Mini's Compute Buffer

I run local models on a few Macs, each served by the Llama app, a llama.cpp build. From 0.48 its model router holds more than one model at once when they fit. On the 128 GB machine, one answered a background job while I chatted with another, and the two would not stay up together.

The eviction

Qwen3.8 27B at 8-bit served the background job at a 262,144-token context, and I chatted with Inkling 2 Mini at the same context. Every few turns Inkling stopped and reloaded: the router was evicting one model to serve the other.

That should not happen on 128 GB, so I started ruling things out.

Three wrong guesses

I checked three things first, and each one fit.

Asking the router

The router reports its own memory. Its model list gives, per model and per device, the bytes held for the weights, for the context (the KV cache), and for the compute buffer the model needs while it processes a request. Here is what the two reserved at a 262,144-token context, in gibibytes:

Model, 262,144 ctx weights KV cache compute total
Qwen3.8 27B 25.4 20.7 6.4 52.5
Inkling 2 Mini 25.4 8.7 25.4 59.6

The device has about 107 GiB for models, the GPU’s share of the 128. The two totals are 52.5 and 59.6, which is 112, against 107 free. They do not both fit, so a request for one evicts the other. Either alone has room; the pair does not.

The surprise is the compute column. For Qwen it is 6 GiB; for Inkling it is 25, as large as the weights.

That reservation, not the weights and not the KV cache, is the byte that evicted the model, and it scales with the context.

The fix

Context is the lever, but only on the right model. Lowering the background model’s context would shrink the window of the job it serves. So I lowered the context of the model I chat with, Inkling, to 32,768, and left Qwen at 262,144.

Inkling weights KV cache compute total
262,144 ctx 25.4 8.7 25.4 59.6
32,768 ctx 25.4 1.7 3.3 30.5

The compute reservation fell with the context, from 25 GiB to 3. The two totals are now 52.5 and 30.5, which is 83 against 107 free, and both stay resident. The app caches its settings, so the change took a restart to read; the router’s model list then showed both loaded at once, with room.

What this shows and doesn’t

The number that decides whether a model fits is not the one on the model card. The weights you can read off in advance; the context and the compute buffer you have to measure, and on a looped model the compute buffer can be the one that decides whether a second model stays up.