FreshContext , home
Drawing
02 · Benchmarks
Sheet
2 of 3
Rev
A · 2026-10-01

Model family ← Models

Gemma 4 12B

Google's 12-billion-parameter model, in Google's own 7 GB 4-bit file. It became our tagging model and is one of the most reliable models we have tested at sticking to the documents it is given, but it ignores rules placed in a tool's description.

Parameters
12B
Files tested
2
Scored runs
52
Smallest Mac
16 GB for the file we kept

Made by Google · released 23 May 2026

Overview Should you use it · what it taught us · why we tested it · what happened

How this page was made. The tests run automatically on our Mac Studio, and every score here comes straight from those runs. This overview was written by Claude, an AI model, from the lab's own records: the run log, notes kept at the time, and the working sessions where each decision was made. Quotes are Alan's words, with spelling fixed. How these pages are made.

Should you use it?

Yes, for document work: tagging, pulling facts out of text, answering only from what it is given, and long inputs in little memory. At short context it fits a 16 GB Mac; its full length needed about 12 GB in our tests. Put any tool rules in the system prompt, not in the tool's description. We haven't tested its vision. Check the smallest Mac for the file we kept, below.

What it taught us

Why we tested it

On 23 August Alan asked to try the smaller Gemma 4 models at their full length: "also want to try gemma4 smaller models at full context". The 12B reads up to 262,144 tokens, and 40 of its 48 layers look back only 1,024 tokens, so the question was whether a full-length conversation could fit in little memory.

The same night we tried it on tagging, labelling each saved conversation turn for our memory system, because our tagging model then was a fine-tune of a smaller Gemma 4. Alan hoped for more: "reality is I could even run 2 x 12b models and the tagger if the 12b was good for agentic AND good at tagging or synthesis etc, I already know it's multimodal so I get vision too."

What it took

Nothing unusual. Google publishes a 4-bit file made with quantisation-aware training, meaning the model was trained to run at that size, and llama.cpp runs it as it comes. We considered larger, more precise copies and kept this one. Alan: "nah qat stays", and "it's what makes gemma as good as it is now, it's been retuned".

As a permanent tagging service it needed one change: thinking turned off, after it spent a short test's whole allowance thinking and replied with nothing.

What happened

  • It holds a long conversation in little memory. 12.07 GB at its full 262,144 tokens and 10.07 GB at 131,072, where Qwen3-8B needed 22.70 GB. It found a fact planted in the text at 8K, 32K and 128K tokens. The longest test timed out while it was still reading.
  • Reading long prompts is its slow side. At 16K tokens in, it read about 111 tokens a second and wrote 28.6.
  • It is the best tagger we have measured. 93.8% on our tagging test and 97.9% when allowed to leave a field empty, repeated exactly on a newer llama.cpp. An 80-billion-parameter model managed 90.4% on the second, and the fine-tune built for the job scored below its own base model. The 12B took over tagging, and has run it as a permanent service since 20 September.
  • It sticks to the documents it is given. It answered from the supplied document, not its own knowledge, 48 times in 48. In our test of handling corrected, conflicting and single-source records it scored 97.5%, and it flagged claims resting on a single source 7 times in 8, which no model we had tested before it did. (In another test, turning tool results into an answer, it flagged none of 10.) It declined correctly 88.9% of the time when the answer wasn't there.
  • Tool rules belong in its system prompt. An if-then rule there made it call the tool 12 times in 12. The same rule in the tool's own description: 0 in 12. Its tool test overall: 55.0%.
  • Agent work was mixed. It followed a 200-step chain of tool calls without losing its place in four runs out of four, though it got the running total wrong each time, which is why that test shows 50%. In an outside agent benchmark it explored before acting and ran over its budget of calls.
  • It ran nine days and 2.74 million tasks before it crashed, in llama.cpp's GPU code; the cause wasn't found. Since 29 September macOS restarts it automatically. Alan, on 11 October: "I think it's gemma that's the only hard seat in the whole fleet doing real work".
The files 2 tested · each has its own page
  • QAT Q4_0 kept

    The one we kept. Google's 4-bit build, and our tagging model since September.

    Google GGUF, downloaded · On disk · 7.0 GB · 52 scored runs · smallest Mac 16 GB

  • mmproj

    The add-on that lets it read images. Loaded for a while, never tested, and not used for tagging.

    Vision projector, Google QAT repo · On disk · 0.2 GB · never scored

Corrections 13 to the record published 21 October 2026
  • Build of llama.cpp on 6 runs was 0.4.0-dev (build 10893, commit c32d1dabe), now 0.2.0-dev (build 10618, commit eb25b7263). The run finished before the llama.cpp upgrade to build 10893; it was served by build 10618, and the later stamp was carried over.

    Corrected 26 October 2026 · a mechanical fix

  • On the tagger run of 24 August 2026: cases passed was 178, now 180; cases measured was 191, now 193; cases attempted was 238, now 240; coverage (%) was 80.3, now 80.4. One result row pair had been run together on a single line and was missed; counting every row gives 240 attempted, 193 measured and 180 passed.

    Corrected 26 October 2026 · a mechanical fix

  • On the tagger run of 24 August 2026: accuracy (%) was 93.2, now 93.3. With every result row counted, 180 of 193 measured cases passed, which is 93.3 percent.

    Corrected 26 October 2026 · a headline fix

  • Why it was tested corrected. The record shows it was added as a smaller model to test at full context, not as a cheap tagger after the 80B; the 80B tagger measurement came later.

    What it said before

    Why it was tested: Tested as a cheap tagger after the 80B proved expensive for a task that runs constantly.

    Corrected 26 October 2026 · a headline fix

  • Size (GB) was 7.0, now 6.98. The file this write-up describes (gemma-4-12b-it-qat-q4_0.gguf) is 6,975,879,296 bytes, 6.98 GB.

    Corrected 26 October 2026 · a mechanical fix

The lab's record Every decision, with its date · the model's specification
Decisions, in order
  • 2026-08-23 10:19Z — download with E4B/E2B, on Alan's "also want to try gemma4 smaller models at full context".
  • 2026-08-23 23:11Z — QAT stays; no higher quant. Alan: "are there higher quants of gemma 12b?". The assistant first offered a non-QAT build to restore the logprob path. It then argued against: at 60% of bandwidth ceiling, Q6_K/Q8_0 would cost 29–45% decode, and Qwen3.5-9B Q8 vs Q4 differed on 7 of 622 cases. Alan: "nah qat stays", then "it's what makes gemma as good as it is now, it's been retuned". Rejected alternative: a Q4_K_M non-QAT at 7.38 GB as a QAT-vs-PTQ curiosity.
  • 2026-08-24 07:19Z — the low-bit 27B line closed in its favour. After qwen3.8-27b UD-IQ1_S (6.19 GB) scored chainwalk follow 1/200 against gemma's 200/200, Alan: "yesh I think we can drop the 1 bit". The assistant's framing: "gemma4-12b at 6.98 GB already dominates that memory band".
  • 2026-08-24 16:52–16:56Z — tagger prompt A/B (-ab). Alan: "there's tagger then there's entities, tagger is minor enrichment, entity is falkor prep and edges". That prompted tagger-nullable/1 as a separate frozen suite, run on the same server process as tagger/2.
  • 2026-08-24 22:02Z — screening built for it. Alan: "can we implement screening for 12b". The result: it catches 20/20 but false-rejects 4/20 real values, so Devstral is the clean screener.
  • 2026-08-25 20:19Z — role defined. Alan: "Speak clearly, 12b the best shot for what". The answer: reading untrusted content, and entity extraction into memory. Not short tool tasks under tight budgets. The assistant then withdrew its own three-model proposal: "12b is best at both. That's one resident model, not three".
  • 2026-08-26 14:29Z — physical quarantine offered. Alan: "I can run 12b on a different machine, I have space". Not on record as having been carried out.
  • 2026-08-31 16:12Z — baseline re-validated before trusting it. Alan: "Yeah but Gemma had issues". The assistant checked that the logprob bug doesn't reach generation-graded suites and proposed a b10618 control re-run; Alan: "Yes". 93.8 and 97.9 reproduced exactly. It became the tagging seat on paper.
  • 2026-09-08 07:48Z — kept through a sweep it was named in. Alan: "Kill Nemotron thinking cap and Gemma dense". The assistant read "Gemma dense" as gemma4-31b-dense and kept this one as "your tagging seat at 93.8/97.9". That reading is an assistant judgement; Alan's reply is not on record. Same day: the tagger-e2b-v1 cutover was cancelled, and "gemma4-12b keeps the tagging seat" (The tagger fine-tune scored below its own base model).
  • 2026-09-09 16:29Z — into the resident fleet. Alan: "we need the gemma models in fleet, why haven't we got there yet and where's reap in all this" and "gemma was a tagger candidate". It was served with --mmproj -c 8192 -np 2, and the 09-09 synthesis/worldview runs used that server.
  • 2026-09-10 08:28Z — first agent-board run (-midrange). It was "your tagger, never on the agent board". That run produced gemma4-12b does not act on rules placed in tool descriptions and The 6.7 GB tagger is the most epistemically reliable model in the fleet.
  • 2026-09-10 16:53Z — vision. Alan: "is vision not in 12b gemma? not sure all of these will fit though so let's try k2 36b as default with the others". The assistant corrected itself: the seat had --mmproj loaded.
  • 2026-09-12 09:57Z — stood down, then reseated as reasoning backup + tagger. Alan: "kill gemma for now", then 10:09Z "I just need it a good reasoning backup model and the tagger etc but we can worry about aux models later". reasoning-seat-gemma12b.sh (-c 65536 -np 1) was written from the board. It then served zero requests: "All 11 aux roles point at Ornith". Alan: "leave it for now we can try it with and without".
  • 2026-09-13 20:36–20:43Z — tagger confirmed; seat at q4_0 KV. Alan: "should I just switch my tagger to vanilla qwen 12b?", corrected to "gemma 12b I mean". The board answered yes. Then: "qwen taking over core responsibilities, gemma on q4 kv please and I'm going to bench a comparison between them on another machine". It was served at -c 131072 -np 2 -ctk q4_0 -ctv q4_0 --mmproj. The other-machine comparison is not on record.
  • 2026-09-20 17:49Z — permanent TAG worker. Alan: "hemma 4 been dropped?" / "gemma". The assistant: "dropped *through the cracks… it's a worker, not a play-seat candidate". Seated at -c 8192 -np 1 -ctk q4_0 -ctv q4_0 -fa on, with thinking pinned off after an empty smoke-test reply.
  • 2026-09-20 22:04Z — 4 slots for the 17k backfill. Alan: "keep an eye on memory, running batch embedding of 17k turnpairs with new embeddings and running through tagger too". At ~14 s/turn on one slot, the assistant restarted it at -c 32768 -np 4. The justification ("np=1 vs np=4 measured identical … 76.7 vs 76.9") was MiniCPM5-2B's measurement, not gemma's (One baseline was 25 points off and nothing in the stamp could explain it; the other six matched their recorded scores).
  • 2026-09-21 09:43Z — not swappable by design. Alan: "what if I swap to gemma". Gemma is a permanent worker, not on the bench.
  • 2026-09-28 15:55Z — not replaced by Splash 3.8. Alan: "could it replace gemma?" / "gemma heavy model kv wise". Answer: no, because tagging is a batch JSON workload.
  • 2026-09-29 — supervised by launchd after a Metal segfault left the tagging seat down. Alan: "why is gemma down in the fleet?" and "so gemma seems to be a bit flakey then". The assistant's answer was "Not really": the crash was in the shared Metal flash-attention path, after 9 days and 2.74M tasks.
  • 2026-10-05 14:50Z — a complaint, no change. Alan: "gemma my most hungry model which annoys me". A smaller-Gemma provenance check was proposed. Its outcome is not on record.
  • 2026-10-11 — b11552 gate passed; the hard seat. tagger 92.5 / tagger_nullable 95.8, "within noise", with the recommendation to switch production to b11552. Alan: "I think it's gemma that's the only hard seat in the whole fleet doing real work". Traffic logs confirmed it: "gemma is the one hard seat" … "the only seat with traffic that isn't mine". Gemma also "stays, by 26+ points on tagging and 32 on provenance" against the Kolibri/Sakura candidates. The live binary was still b10893 on 2026-10-23 (.local/bin/llama-server --version), so the switch had not been made.
What we learned, in the lab's words
Why it was tested, in the lab's words
  • Brought in as one of the "gemma4 smaller models", not as a tagger. Alan, 2026-08-23 10:16Z: "ffs was hoping to test this (you can see in okf what we've been doing), can you pull the 3.5 9b and put it through its paces at q8 and then q4? also want to try gemma4 smaller models at full context". The assistant downloaded the 12B, E4B and E2B QAT GGUFs at 10:19Z. It registered them in the context ladder and needle ladder at their native windows. The question was whether Gemma 4's sliding-window/K=V design holds a full window cheaply. That came from rethinking the fleet-notes entry ("gemma4-31b as worst-in-fleet for KV").
  • Then as a driver/agentic candidate. Alan, 22:20Z: "the 12b would need the full agentic suite ran against it and we now have example turnpairs to design a suite for it". Alan, 22:22Z: "reality is I could even run 2 x 12b models and the tagger if the 12b was good for agentic AND good at tagging or synthesis etc, I already know it's multimodal so I get vision too.". Alan, 22:31Z: "feel free to try both e2b and e4b too as well as 12b seeing as we're back in gemma territory (this alone fascinates me)".
  • The tagger link came from the family. Alan, 22:24Z: "tagger was traing on gemma 4 so the family is good.". The production tagger tagger-e2b-v1 is a LoRA on gemma-4-e2b (a lab note). So the 12B was run on the tagger/2 contract the same night, in the first Gemma grid.
Open questions
  • KV per token is recorded three incompatible ways. The 08-23 serving ladder implies ~15 KB/token at f16 ((12.07−10.07) GB / 131,072). The 09-13 arithmetic used 96 KB/token f16. fleetview and the runbook carry "~1.5 KB/tok KV (measured)" at q4_0. That last figure came from diffing footprint on a --no-warmup server at 8K vs 32K, where untouched KV pages may not be counted. A served-load ladder at q4_0 would settle it.
  • Is gemma4-12b's tagging accuracy really -np-insensitive? The claim behind the 4-slot seat (2026-09-20 to 09-29) was measured on MiniCPM5-2B.
  • Would the 258,048-token needle pass? It was never retried with the 9000 s timeout (a lab note Open).
  • QAT q4_0 vs a non-QAT Q4_K_M at near-equal size: declined, never run.
  • Was the 2026-09-13 "bench a comparison between them on another machine" (gemma vs qwen3.8) ever run? Not on record.
  • Do E4B/E2B carry the single_source provenance skill? The answer is not on record.
  • The 10-05 claim that gemma was resident at 10.9 GB "at the 65k window" conflicts with the launchd plist (-c 8192, since 2026-09-29). The seat's actual flags that day are not on record.
The model in detail
fieldvalue
vendorGoogle (Gemma 4 family)
upstream reposgoogle/gemma-4-12B-it (instruct, created 2026-05-23); google/gemma-4-12B-it-qat-q4_0-gguf (QAT GGUF, created 2026-06-05; on 2026-08-23 it held two files: gemma-4-12b-it-qat-q4_0.gguf 6.98 GB and mmproj-gemma-4-12b-it-qat-q4_0.gguf 0.18 GB)
revisionnot on record (downloaded from resolve/main with pget.sh; no .cache/huggingface metadata in models/gemma4-12b-dense/, checked 2026-10-23)
licencenot on record for the 12B. (The e2b-derived tagger-e2b-v1 card says apache-2.0 but links the Gemma 4 licence.)
releasedinstruct weights 2026-05-23, QAT GGUF 2026-06-05 — eleven weeks after the March family launch (E2B/E4B 2026-03-02, 26B-A4B/31B 2026-03-11)
architecture (HF config.json, not the local GGUF header)Gemma4UnifiedForConditionalGeneration (text + vision + audio towers); dense text model, 48 layers (40 sliding-window at 1024 tokens, 8 full-attention), hidden 3840, FFN 15360, 16 attention heads, 8 KV heads, head_dim 256 / global_head_dim 512, attention_k_eq_v: true, final logit softcap 30
parameters12B, dense (the card text was not recorded)
native context262,144 (max_position_embeddings) — the only Gemma 4 member below the 31B with that window
runtime used herellama.cpp only: llama.cpp at b10369 (6e62ba538), b10618 (eb25b7263) and b10893 (c32d1dabe); llama.cpp-b11552 at b11552 (23b0202a1) for the 2026-10-11 gate
tool-call formatGemma 4's own tool-call tags; llama.cpp's --jinja path parses it into OpenAI tool_calls

No MLX, BF16, Q8 or K-quant build of the 12B was ever held. Higher quants were considered and declined on 2026-08-23 (decision log). The gemma4-12b-hf-tokenizer/ directory (fetched 2026-08-24 07:01Z from google/gemma-4-12B-it) holds only tokenizer and chat-template files. It was used to check the template's tool support for the BFCL handler.