If you run local AI at home on an 8GB or 12GB graphics card, you have probably hit the same wall everyone else runs into: dense 7B and 8B models are fast, yet they stumble on multi-step coding and tricky instructions, while 27B and 32B models normally demand a 24GB card or expensive high-bandwidth unified memory.
In the last few weeks of 2026, two developments changed the math for budget setups. True ternary quantization squeezed a 27B agentic coding model under 6 GB, and updated Mixture-of-Experts (MoE) offloading in llama.cpp made 26B-class models genuinely usable even when they spill out of an 8GB GPU into system RAM.
If you already own a card like an RTX 3060, RTX 4060, or an 8GB gaming laptop GPU—and you have no interest in spending four figures on a VRAM upgrade during a memory crunch—here is how to get 27B-class results on the hardware you have.
1. Ternary Quantization: Squeezing a 27B Model Into 6 GB
Standard 4-bit quantization (Q4_K_M) cuts a 27B model down to roughly 17 GB—still way too large for an 8GB or 12GB card. On November 24, 2026, PrismML released Ternary Bonsai 2.5 27B under an Apache 2.0 license, pushing compression much further without throwing away coding reliability.
Built on the 27.36B-parameter Qwen3.8-27B architecture, Ternary Bonsai 2.5 stores weights as ternary values ({-1, 0, +1}) at roughly 1.76 bits per weight. The result is a 5.93 GB PTQ1_0 file—about nine times smaller than the 53.8 GB full-precision reference.
Earlier ultra-low-bit models often collapsed on tool calling and multi-turn bug fixing. According to PrismML’s benchmarks, the 2.5 update narrows that gap substantially:
- SWE-bench Verified: 75.6 (up from 60.8 on Bonsai 2, compared to 80.6 on full-precision Qwen3.8 27B)
- AppWorld: 90.5 (up from 51.2 on Bonsai 2)
- tau³-Bench: 73.9 (up from 69.1)
In community testing on a budget 12GB RTX 3060, testers reported around 74 tokens per second with Multi-Token Prediction (MTP) speculative decoding enabled, versus roughly 47 tokens per second without MTP.
Which Bonsai 2.5 File Should You Download?
PrismML ships several GGUF packings in prism-ml/Ternary-Bonsai-2.5-27B-GGUF, and picking the right one depends on how much tinkering you want to do:
PTQ1_0(~5.93 GB): Smallest footprint and fastest on NVIDIA GPUs when paired with PrismML’s runtime builds and MTP draft heads. Fits comfortably on 8GB and 12GB cards with room left for context.Q2_0(~7.6 GB): The easiest drop-in option if you want standard upstreamllama.cpp(buildb11556or newer) without custom binaries. Best suited for 12GB cards once you add context overhead.PQ2_0(~7.2 GB) / MLX 2-bit: Targeted at Apple Silicon and PrismML builds where faster prompt processing matters.
One important caveat: ternary unpacking is fast on a GPU, but slow on CPU-only paths. Keep the weights in VRAM rather than spilling a ternary model to system RAM.
2. Sparse MoE Offloading: Letting a 26B Model Spill Gracefully on 8GB VRAM
What if you want standard 4-bit quality for everyday writing, reasoning, and coding on an 8GB GPU? Normally, spilling a 16.8 GB model into system memory ruins generation speed. Mixture-of-Experts (MoE) models break that rule.
Take Google’s Gemma 4 26B A4B. It contains 25.2B–26B total parameters across 128 experts, so the Q4_K_M GGUF weighs 16.80 GB. However, it only activates about 3.8B parameters per token. Because each generated word reads only a small fraction of the file, partial offloading to system RAM is dramatically faster than spilling a dense 27B model.
In late-November 2026 testing by Kingy AI on an 8GB RTX 5070 laptop paired with 32 GB of system RAM, gemma-4-26B-A4B-it-Q4_K_M.gguf ran through llama.cpp with automatic fitting at 46.6 tokens per second on real coding and writing jobs—scoring 84.4 overall compared to 76.1 for Qwen3 8B.
What You Need for MoE Splitting
- 32 GB of system RAM: With a ~16.8 GB model plus 8K context (~18.9 GB total), 16 GB of system memory is too tight once Windows or Linux overhead is factored in.
- Pin attention and KV cache to the GPU: In
llama.cpp, the-cmoeflag (or manual--n-gpu-layerstuning) keeps the compute-heavy attention layers and KV cache on your 8GB card while leaving the expert layers in system RAM. - Use CUDA over Vulkan when possible: On NVIDIA 8GB cards, community benchmarks consistently show CUDA delivering multiples of Vulkan’s token speed under MoE offloading.
- Expect slower long-prompt starts: While token generation stays snappy, feeding an 8,192-token document into an offloaded MoE model on an 8GB card can take around 40 seconds before the first word appears.
A clean starting command in llama.cpp looks like this:
llama-server -hf lmstudio-community/gemma-4-26B-A4B-it-GGUF:Q4_K_M -c 8192 --no-mmproj
If your PC only has 16 GB of system RAM, skip MoE spilling and stick to a true small dense model like Qwen3-8B-Q4_K_M.gguf (5.03 GB), which leaves enough headroom for your OS and browser.
3. Trim Context Overhead With llama.cpp KV-Cache Tuning
On an 8GB or 12GB GPU, the model weights are only half the battle. Your conversation history and pasted code live in the KV cache, which can quietly eat several gigabytes of VRAM if you leave context wide open.
Following llama.cpp reaching v1.0.0 and v1.1.0 in November 2026, two simple habits keep budget cards from hitting out-of-memory errors:
- Cap context to what the job needs: Setting
-c 8192instead of 32K or 64K saves gigabytes of VRAM and keeps small cards out of slow fallback paths. - Drop unused vision projectors: Many modern open-weight releases bundle multimodal
mmprojfiles. Adding--no-mmprojwhen you only need text saves several hundred megabytes immediately. - Quantize the KV cache carefully: Standard
-ctk q8_0 -ctv q8_0(with Flash Attention enabled) cuts KV memory roughly in half versus FP16 with minimal quality loss. On newer NVIDIA GPUs (Ada Lovelace and later),llama.cppbuildb12274also added OCP FP8 KV cache support (-ctk f8_e4m3 -ctv f8_e4m3), thoughq8_0remains the safer default on CPU-heavy or MoE split setups where FP8 cache support is disabled.
Quick Cheat Sheet: Which Path Fits Your Rig?
| Your Hardware | Best 2026 Strategy | Model to Try |
|---|---|---|
| 8GB VRAM + 16GB RAM | Compact dense 4-bit | Qwen3-8B-Q4_K_M (5.03 GB) |
| 8GB VRAM + 32GB RAM | Sparse MoE split (llama.cpp auto-fit / -cmoe) |
gemma-4-26B-A4B-it-Q4_K_M (16.80 GB) |
| 12GB VRAM (e.g., RTX 3060) | Ternary 27B all-in-VRAM | Ternary-Bonsai-2.5-27B (PTQ1_0 5.93 GB or Q2_0 7.6 GB) |
Running local AI on a budget no longer means settling exclusively for 7B chatbots. Between ternary compression and MoE layer splitting, an older 8GB or 12GB GPU still has plenty of life left—as long as you match the model architecture to where your memory actually lives.





