The commands and behaviour described come from the mistral.rs documentation, read on 2 December 2026.
The most common local AI question is "will this model fit on my graphics card?" Download a model that's too big and it either fails to load or spills into system RAM and slows to a crawl. mistral.rs, the open-source Rust LLM engine, has a command that answers the question before you download the weights: mistralrs tune. It reads only the model's small config files, works out how big each quantisation would be, compares that with your hardware, and prints a ready-to-run command for the one it recommends.
If you haven't installed mistral.rs yet, start with our guide to running local LLMs with mistral.rs. GPU acceleration needs an NVIDIA RTX 30-series card or newer, or a Mac.
Why quantisation decides what fits
Quantisation stores each weight in fewer bits. mistral.rs's quantisation guide gives the rule of thumb: a 14B model in 16-bit BF16 needs about 28 GB for its weights, about half that at 8 bits and about a quarter, roughly 7 GB, at 4 bits. That's the difference between needing a 32 GB card such as the NVIDIA GeForce RTX 5090 Founders Edition and fitting on a 12 GB card such as the ASUS RTX 3060 12GB Dual Gaming OC V2.
Weights aren't the whole story. The docs say the KV cache, which holds the conversation so far, is a separate memory budget that depends on context length rather than on quantisation. A model that only just fits may leave little room for long chats. Our context length and VRAM explainer covers why.
Step 1: Run tune on the model you want
Give tune a Hugging Face model ID:
mistralrs tune -m Qwen/Qwen3-4B
The docs say tune prints one row per quantisation format, with:
the estimated size,
its share of your GPU memory,
how much context fits beside it,
a quality label (near-lossless for 8-bit, good for 5 and 6-bit, acceptable for 4-bit, degraded for 3 and 2-bit),
a status: Recommended, Fits, Hybrid (split across GPU and CPU) or Too Large.
Below the table it prints a ready-to-run command for the recommended row. Because tune only reads config files, nothing large is downloaded at this stage.
Step 2: Choose a profile
By default tune uses the balanced profile, which starts at 6-bit and works down. You can change what it favours with --profile:
Profile | Bit widths it tries, in order (NVIDIA and CPU) | Use it when |
|---|
quality
| 8, 6, 5, 4, 3, 2 | You want the most precise version that fits |
balanced (default)
| 6, 5, 4, 3 | You want a good trade between quality and memory |
fast
| 4, 3, 2 | You want the smallest, fastest version |
For example:
mistralrs tune -m Qwen/Qwen3-4B --profile quality
The balanced profile is also what --quant auto uses when you load a model, so tune shows you in advance what auto would pick. If you already know the format you want, --isq q4k asks tune to recommend that one if it fits.
Step 3: Plan for the context you actually need
If you need long prompts, such as pasting in big documents or using a coding agent, tell tune with --max-model-len, which sets the most tokens one request may use. The context length guide suggests 8k to 32k tokens for chat, while coding agents want as much as the model and memory allow.
If the context you want won't fit, the docs list a few options:
--pa-cache-type f8e4m3 stores the KV cache in 8-bit floating point, which holds about twice as many tokens in the same memory.
A smaller quantisation, such as 4-bit instead of 8-bit, leaves more memory for the cache.
--gpu-memory-utilization sets the share of GPU memory (for example 0.9) mistral.rs uses for weights, activations and the cache.
These flags work with tune and with serve, so you can check a combination with tune first, then use it for real.
Step 4: Save the recommendation and run it
To keep tune's answer, write it to a config file and run from that:
mistralrs tune -m Qwen/Qwen3-4B --emit-config qwen.toml
mistralrs from-config -f qwen.toml
If you'd rather script it, --json gives machine-readable output instead of the table.
When the model is too big: split it between GPU and CPU
A Hybrid result means the model only fits if some of it runs from system RAM on the CPU. That works, but layers on the CPU generally run slower than layers in VRAM. mistral.rs gives you two ways to control the split.
The simple one is -n (--device-layers), which sets how many layers go on each device, such as 0:10;1:20 for 10 layers on GPU 0 and 20 on GPU 1. Leave it out and mistral.rs maps layers automatically.
For more control, a topology file sets the device and quantisation for each range of layers. The docs' example splits a 40-layer model across two GPUs and the CPU:
0-16:
device: cuda[0]
isq: q4k
16-32:
device: cuda[1]
isq: q4k
32-40:
device: cpu
isq: q8_0
Load it with mistralrs serve -m <model> --isq q4k --topology topology.yaml. Ranges include the first number and exclude the last, so 0-16 means layers 0 to 15. Two caveats from the docs: putting any numbered layer on the CPU turns off paged attention for that model, and for most people the automatic layout without a topology file is the right setup.
For mixture-of-experts models, --isq-organization moqe quantises only the expert layers and leaves the rest at full precision. See our guide to running MoE models on low VRAM for why MoE models behave differently.
Check the real numbers
Tune's figures are estimates. The quantisation guide recommends checking actual memory use with nvidia-smi once a model is loaded; on Windows you can also use Task Manager, as our guide to checking VRAM usage on Windows shows. When mistral.rs starts, it also prints the context limit per request and how many full-length requests fit in the KV cache.