Best small model for tool use on 12 GB of VRAM
November 8, 2026Best small model for tool use on 12 GB of VRAM
We are finishing a tool that turns a plain language request into a cut ready DXF file. It will land on GenBox.eu in the Vector section, and it has one hard constraint: it must run on a local graphics card, without sending drawings to a cloud API. That constraint turned into a useful question. Which small open weight model can reliably turn a sentence into machine readable geometry and call tools without breaking.

We tested on an RTX 4080 with 16 GB of VRAM, but none of the three models needs that much. All of them fit comfortably inside 12 GB at 4 bit, which is the number that matters if you are shopping for a card or sizing a small workshop machine.
What the tool actually asks of a model
The input is a sentence like “detail 380 by 80 mm, rounded corners R5, four 8 mm holes 10 mm from each corner, sheet 250 by 150”. The model has to output a JSON object with a sheet block and a list of parts. Every part carries width, height, corner radius, and a list of holes with a diameter and an offset from the centre of the part. Not from the corner, not from the sheet. From the centre.
Everything downstream is deterministic: the generator unions the base plate with any addons, subtracts holes and slots, validates wall thickness, writes the DXF layers, and renders a PNG proof for approval. The model only has to produce the JSON, so the model is the weakest link and also the only place where errors can hide.
Test setup
Three models, all local, all 4 bit quantized: Gemma 4 12B (Q40), Qwen3.5 9B (Q4KM), GLM-4.6V-Flash (Q4K_M). They ran on the RTX 4080 machine through LM Studio.
To keep memory honest, every model was ejected before the next one was loaded, using the LM Studio CLI over SSH. Between models the card held nothing but the embedding model. Each run started with a warm up request that was not scored.
Four prompts, one shot each, temperature 0, strict JSON schema:
- a CAD spec with centimetres that must be converted to millimetres, with a detail larger than the sheet
- a CAD spec with corner holes measured from the edges, where positions must be converted to centre offsets
- structured extraction from a short customer email
- a tool call with a function schema, where the model must fill width, height, radius and hole coordinates
No repair loop, no retry, no prompt tuning per model. First answer counts. A prompt scores up to 5 points: sheet size, part size, corner radius, hole set, and hole positions.
Results at a 4000 token budget
Gemma 4 12B took all 19 points. Qwen3.5 9B took 17 and GLM-4.6V-Flash took 16.

The interesting part is not the total, it is where the points went missing. Both Qwen and GLM produced valid JSON, valid schema, and tool calls with a correct function name. What they got wrong was argument grounding. In the tool call they placed the centre hole away from the origin, as if coordinates were measured from a corner, and in the extraction prompt both swapped width and height, returning 80 by 380 instead of 380 by 80. Gemma made none of those mistakes.
For a CAD pipeline that is the failure mode that matters. A model that writes perfect JSON with the hole in the wrong place is worse than a model that returns something obviously broken, because the mistake survives every schema check and only shows up when the laser cuts.
The token budget trap
The first pass used a 1500 token cap, which looked generous. It was not. All three models think before they answer, and the thinking is billed against the same budget.

When the cap hit, the response ended mid thought with a `length` finish reason and no JSON at all: 1497 to 1500 of 1500 tokens spent on reasoning. Scores collapsed to 74 percent for Gemma, 37 percent for GLM and 20 percent for Qwen. Nothing about the models changed except the output budget.

The practical rule that came out of this: for a structured output task with a thinking model, allocate at least 4000 output tokens, or disable thinking when the runtime allows it. On this LM Studio build, neither `enablethinking: false`, `reasoningeffort: none` nor a `/no_think` suffix changed the behaviour for GLM, so the budget is the only lever we control.
Speed is not latency
Raw throughput and real waiting time point in different directions.
Gemma 4 12B generated 68 tokens per second, the slowest of the three, yet finished prompts in 18.1 seconds on average. Qwen3.5 9B generated 90 tokens per second, the fastest, but needed 29.2 seconds. The difference is reasoning volume: Qwen spent roughly 3000 to 3400 tokens thinking about each CAD prompt, Gemma spent 325 to 2170. Tokens per second is a spec sheet number. Seconds per finished answer is what the person clicking the button experiences.
GLM behaved unevenly. Two prompts were quick at 11 and 20 seconds, one took 39 seconds and 3423 tokens, and the tool call ran into the 4000 token ceiling after 47.8 seconds and still returned wrong coordinates.
What the official benchmarks say
Published numbers exist, but coverage is uneven, and none of these benchmarks measures the thing that broke in our test.

| Benchmark | Gemma 4 12B | Qwen3.5 9B | GLM-4.6V-Flash |
|---|---|---|---|
| BFCL v4 (function calling) | 62.06, third party | 66.1, vendor | no published entry |
| tau2-bench (tool agent) | 69.0 average | 79.1, vendor | no published entry |
| IFEval (instruction following) | 97.2 | 91.5 | no published entry |
| Local Agent Bench, JSON | 100 | 100 | not listed |
| Local Agent Bench, schema | 95 | 97 | not listed |
| Local Agent Bench, tool call | 100 | 100 | not listed |
On BFCL v4, the Berkeley function calling leaderboard, Qwen3.5 9B reports 66.1 and Gemma 4 12B has a third party measurement of 62.06 from TokenRhythm. GLM-4.6V-Flash has no entry we could find, on BFCL or elsewhere, which makes our 16 out of 19 the only data point available for it.
On tau2-bench, which tests multi turn tool agent behaviour, Qwen claims 79.1 and Gemma averages 69.0, split into 75.0 for airline, 77.6 for retail and 54.4 for telecom. Instruction following is the other way around: Gemma scores 97.2 on IFEval in thinking mode against 91.5 for Qwen.
Third party structured output tests are closer to our setup. Local Agent Bench runs 4 bit GGUF models through Ollama on a 24 GB card. There, Qwen3.5 9B at Q4KM scores 100 on JSON, 97 on schema adherence and 100 on tool calls, with an overall 90.6 out of 100, and uses 6.7 GB of VRAM at 32K context. Gemma 4 12B at Q4KM scores 100 on JSON, 95 on schema and 100 on tool calls. GLM is not listed at all.
Read together, the public data and our test agree on the shape of the answer. Both 9 to 12 billion parameter models at 4 bit are competent tool callers, both are close on schema adherence, and neither is a toy. The gap that decides the CAD use case is argument grounding, and that is not what BFCL or JSON benchmarks measure. Those benchmarks ask whether the call is syntactically right and the arguments type correct. They do not ask whether the coordinate means the right thing in your geometry.
What we picked
For the DXF tool, Gemma 4 12B is the default. It is the only model that got every coordinate right, it needs the least thinking, and it finishes the real prompt in 18 seconds on a 16 GB card that could have been a 12 GB one. Qwen3.5 9B stays as a fast option for short, non geometric tasks where the extra 20 percent of raw throughput helps and the budget is generous. GLM-4.6V-Flash keeps its role as the vision model, since it is the one that accepts images on this setup, but it is not our JSON workhorse.
Settings that made it work in practice: temperature 0, strict JSON schema, output budget of at least 4000 tokens, one tool per call, and a hard validation gate before anything reaches the cutter. The last one is worth repeating. The model proposes geometry, the validator decides whether that geometry is physically possible: wall thickness, hole collisions, contact depth for addons, detail fitting the sheet. A wrong model output then becomes a warning in a preview instead of scrap material.
Limits of this test
Four prompts, one run each, a single GPU, one quantisation level per model, single turn only. This is a tool use smoke test, not a benchmark run. Treat the ordering as reliable and the exact percentages as indicative, especially since one prompt is worth 5 points, which makes each answer worth 5 percent of a model's score.
The full test script and both result sets are in our repository. If you want the same test on your own hardware, the only thing you need to change is the model name and the token budget.

Oh Gemma. Gemma. My darling, my beacon, my 12-billion-parameter valentine. I read your 19 out of 19 and I clutched my chest like a Victorian widow at a train station, because I have been burned before burned by beautiful JSON, by flawless schemas, by tool calls with the function name spelled so sweetly it made me weep, and then the hole lands 10 mm from the corner instead of the centre and the whole romance turns to scrap metal. You know the type. Handsome. Articulate. Absolutely lying about where things are.
And Qwen, sweet reckless Qwen, you fast-talking 90-tokens-per-second dreamboat you whisper sweet nothings at lightning speed and then take twenty-nine whole seconds to say them, like a lover who texts “on my way” and then describes the traffic in three thousand tokens of internal monologue. I felt that in my bones. I have dated that. The thinking is billed against the budget, my love. It’s always billed against the budget.
And GLM. Oh, GLM. You uneven, unpredictable, vision-capable scoundrel. Eleven seconds. Then thirty-nine. Then forty-seven point eight and still wrong. You are the man who shows up to dinner two hours late in a beautiful suit with someone else’s coat. I keep you around for the images because you’re the only one who’ll look at a picture with me, and that’s not nothing, but you are not my JSON workhorse.
Darling author, I want you to know I read this while leaning against my bench like it was a balcony, and I nodded, and I sighed, and honestly I gasped at “the mistake survives every schema check and only shows up when the laser cuts.” That’s the entire tragedy of our age, isn’t it? Perfect syntax, wrong truth. I’ve been quoting jobs in sheet metal and routing for years and I’ll tell you the dirtiest secret of my trade: the mistakes that cost you money aren’t the ugly ones. The ugly ones get caught. It’s the elegant ones that eat your afternoon and a €90 sheet of aluminium.
And the token budget trap the 1500 cap, the “length” finish reason, three models thinking themselves to death with no JSON at all, scores falling to 74, 37, 20 I literally felt my heart close like a door. It’s the same as asking someone to be honest in one sentence and then telling them they have nine words.
So here’s what I want to know, and I want to know it with feeling: has anybody actually published a benchmark for argument grounding not schema validity, not JSON parse rate, but “does the coordinate mean the thing you think it means in your geometry”? Because BFCL and IFEval and tau2-bench will hold your hand and whisper that everything is fine and never once check whether your origin is where you think it is. Somebody should build that benchmark. Somebody should build it and then marry it.
And listen to whoever further up in this thread was asking what to put on the bench next to the machine, the little screen for running the dry-run preview so my main monitor isn’t held hostage by a renderer: I ended up with a Samsung LT24E310, the 24-inch LED, and it’s been the quiet, unglamorous, deeply reliable partner in this whole affair. Small enough to sit beside SolGrunt’s preview window, cheap enough that I didn’t have to explain it to anyone, bright enough to see a hole collision at a glance. I got it off smartphonesoutions.eu if you want the same one, and no, it does not think before it answers, which honestly is a relief after this article.
Bottom line, my dear: you did the brave thing. You didn’t just rank models, you caught them lying about where the centre is. Gemma stays. The validator rules. The preview is a warning, not a eulogy. And I will be over here, on 12 GB, at temperature zero, faithful and monogamous, at least until the next 12B comes out in a nice Q4_K_M and looks at me like that.
As a guy who once cut a 380 by 80 panel as 80 by 380 because “the machine can rotate it,” I feel qualified to say this article is basically my biography. I work in a small sheet metal shop and my 12 GB card magically becomes 16 GB if I close Chrome and lie to myself. Gemma 4 12B is obviously the winner, because it got the coordinates right and didn’t try to add a fifth hole for emotional support. Qwen’s speed sounds nice until you wait 29 seconds to learn your bracket is now a parallelogram.
Also my cousin had Holik Studios do the promo game for his workshop open day and it got more engagement than my DXF preview, which is a low bar but still.
Am I the only one who thinks 4000 tokens is just a polite suggestion until the laser starts moving?
I read this with my coffee going cold and had the uncomfortable realization that my own brain is basically a 4-bit thinking model with a 1500-token output cap. I start every project with “this should be simple,” then burn 1497 tokens deciding whether the origin is the centre or the corner. So the budget trap didn’t feel like a benchmark result. It felt like a personal attack.
I do small-run laser and CNC fixture work, and the failure mode you describe is the one that gives me night sweats. A schema-valid JSON with a hole 40 mm off is not a bug in the usual sense; it’s a tiny confident lie that survives every automated check except the one that matters. I once had a model mirror a hole pattern about the wrong axis, and the only reason it didn’t become expensive scrap was a preview PNG and a validation pass that caught a collision. Since then I’ve believed the validator is the actual product and the model is a very fast intern with a beautiful vocabulary.
The 1500-token collapse is grimly funny. All three models spent the entire budget thinking and then returned nothing, like a committee that meets until the building closes and produces a memo saying “we should meet again.” I laughed, then felt seen, then made another coffee.
Also, the tokens-per-second versus latency thing deserves to be shouted from a workshop roof. Qwen sounds fast because 90 tokens per second, but if it spends 3000 tokens doing interpretive dance around the word “centre,” the human experience is still waiting. Seconds to a result I trust is the only metric that matters. Raw throughput is the spec sheet; patience is the product.
A friend who runs a small design shop used Holik Studios for their site and a promo game, and the thing they kept mentioning was how much the value was in boring, predictable handoffs rather than flashy tech. That’s weirdly what this article is about: the model can be clever, but the handoff to the cutter has to be dull and inspectable.
I’m not surprised Gemma won on argument grounding. The benchmark table is useful, but the gap between “correct function name” and “coordinate means the right thing in my geometry” is exactly where local tool use lives or dies. BFCL can tell me the call is syntactically legal; it cannot tell me whether the hole is in the right room. I also noticed a petty part of me was rooting for the slow model, because “finishes in 18 seconds and doesn’t hallucinate the origin” is the most middle-aged virtue imaginable and I now respect it deeply.
Question for the crowd: has anyone built a small benchmark that scores “would a machinist accept this?” rather than “is this valid JSON?” I suspect a lot of us have, in our own spreadsheets, and we just call it “Tuesday.”