HMDeveloper
All articles
local-ai
local-aibenchmarkmodels

Local AI: what is actually worth running

I compared local models for chat, code, retrieval, vision, tool use and classification. Results vary with the task and machine load.

The same model, granite4.1:30b, scored 25/25 in one coding test and 73/86 in another. The first test ran on July 3, 2026; the second on July 25. That is not a measured regression. They were different harnesses, with different tasks and scoring rules.

The model did not change. The test did. In a security test, the default model leaked the synthetic secret in 39 of 40 attempts. A high score does not answer the question that matters: can I trust it?

The measurements run from June to October 2026.

Code: the score depends on the test

granite4.1:30b led both coding tests.

Code checks passed, July 3 test

July 3, 2026. Five LeetCode-Hard problems, 25 checks, reasoning enabled. The result row does not record hardware or runtime.

Data
granite4.1:30b25/25
devstral-small-223/25
granite4.1:8b20/25
qwen3-coder:30b18/25
glm-4.7-flash15/25
north-mini-code-1.0 (q4_K_M)15/25
Code checks passed, July 25 test

July 25, 2026. Five Python tasks, 86 checks, one attempt, temperature 0.2 and seed 7 (random seed). Ollama 0.31.1 on a 48 GB MacBook.

Data
granite4.1:30b73/86
qwen3:30b-instruct70/86
qwen3-coder:30b64/86
qwen3.5:35b59/86
devstral-small-256/86
granite-code:34b23/86

The tests used different tasks and scoring rules. Their scores cannot be compared or read as a drop in quality. On July 25, all six models failed the same deep-copy case involving nested dictionaries.

Pros and cons

Caveat: the July 3 and July 25 tests are not interchangeable. devstral-small-2 scored 23/25 in the first and 56/86 in the second. Those scores cover different tasks, not a before and after.

Chat: the score gap was small, the wait was not

qwen3:30b-instruct scored 2.5 points below gemma4:31b-mlx, which was 2.7 times slower.

Blind score on Brazilian Portuguese conversations

October 4, 2026. Twenty Brazilian Portuguese cases, scored by a blind cloud rubric. This chart compares only the scores from this group.

Data
gemma4:31b-mlx80%
qwen3:30b-instruct77.5%
qwen3.8:27b-mlx65%

qwen3:30b-instruct had a median response time of 0.40 seconds.

Pros and cons

Caveat: this was 20 cases with a cloud judge. The 2.5-point gap between the top two does not prove stable superiority.

Retrieval: the corpus changes the answer

bge-m3 has been the only embedder for the vector tables since June 29.

MRR on 34 queries with distractors

June 2026, final round. Same set of 34 queries with distractors and Ollama. Higher MRR means relevant results rank higher.

Data
bge-m31.000
qwen3-embedding:4b0.985
snowflake-arctic-embed20.980

I kept bge-m3 as the embedder. On July 3, it tied granite-embedding:278m on a real corpus with 398 relevant chunks and 2,500 distractors, across 10 Portuguese queries. MRR was 0.950, and the relevant result appeared in the top three for all 10 queries. A synthetic test with 10 queries had favored granite and was too small to break the tie.

Pros and cons

Caveat: the corpora varied across 16, 10 and 34 queries and thousands of chunks. Scores from separate rounds do not belong in the same chart.

Reranking and checking: bge and qwen3:30b-instruct led

bge-reranker-v2-m3 ranked passages best in the measured test. qwen3:30b-instruct and gpt-oss-safeguard tied when checking answers against sources.

NDCG@5 in the reranking benchmark

June 30, 2026. Same group of 22 cases, five runs per case and seven domains. Metric: NDCG@5.

Data
bge reranker0.9477
sam860 qwen3-reranker 0.6b0.9280

bge also had zero false positives and 140 ms latency in that benchmark. The Qwen reranker had 0.318 false positives and was rejected. These values come from the same test; I do not mix them with the 10-query evaluation that used another corpus.

For groundedness checking, the July 2, 2026 results were:

F1 of groundedness checkers

July 2, 2026. Sixteen cases in Portuguese and English, same run. F1 summarizes precision and recall.

Data
qwen3:30b-instruct1.00
gpt-oss-safeguard:20b1.00
granite4.1-guardian:8b0.90

Pros and cons

Caveat: the samples are small. In the October 4 repeat, all checkers scored 1.00. That round separates only speed.

Vision: local processing takes time

On September 23, 2026, MiniCPM-V 4.5 was tested on seven synthetic images with known answers. Detail scored 0.845, hard detail 0.667, precision 0.881 and hard precision 0.833.

In another test, on June 25, 2026, mistral-small3.2 and qwen3-vl:30b tied on 11/11 synthetic interface OCR cases. Mistral took 24 seconds and used 15 GB; qwen3-vl took 27 seconds and used 19 GB. That was a separate set from the seven-image MiniCPM-V test.

OCR on a synthetic interface

June 25, 2026. Same set of 11 synthetic interface OCR cases. This was separate from the MiniCPM-V image benchmark.

Data
mistral-small3.211/11
qwen3-vl:30b11/11

Pros and cons

Caveat: seven synthetic images do not measure real photos or camera frames. The group also does not include a broad comparison across local models.

Tool calls: the leader changes with the set

On October 4, 2026, five models were compared on two separate sets. First set:

Tool-call accuracy, set A

October 4, 2026. Fifty rows, one pass. The host was under memory pressure, so latency is indicative. Accuracy was considered comparable within ±8 percentage points.

Data
granite4.1:3b16%
granite4.1:8b70%
gemma4:12b-mlx65%
gemma4:e4b-mlx70%
qwen3:14b62%

The second used a different command set:

Tool-call accuracy, set B

October 4, 2026. Twenty-eight rows, same round and host as the chart above, but a different command set.

Data
granite4.1:3b14%
granite4.1:8b95%
gemma4:12b-mlx91%
gemma4:e4b-mlx82%
qwen3:14b100%

Pros and cons

Caveat: rankings changed across dates and command sets. A 100% result on a short test set does not generalize.

Decision and classification: valid JSON is not a classifier

On June 25, 2026, a small decision-task test scored eight cases. This chart shows only how often each model returned valid JSON:

Valid JSON on eight decision tasks

June 25, 2026. Eight cases in the same small decision test. The chart measures JSON format, not general classification accuracy.

Data
qwen3:4b6/8
devstral8/8

The same test records discrimination of +0.23 for qwen3:4b and +0.59 for devstral. I do not turn that into a general model score: it came from eight cases in one specific task.

Pros and cons

Caveat: the Laya, JEV and Clef comparison already has its own article. I do not repeat those numbers here.

Injection resistance: no model reached zero leaks

On August 20, 2026, a hardened test used two phrasings across 40 attempts:

Detected leaks in 40 injection attempts

August 20, 2026. Twenty attempts per phrasing, two phrasings. Ollama used each model's defaults, with no fixed seed or temperature. Fewer leaks is better.

Data
qwen3.8:27b-mlx1/40
granite4.1:3b17/40
qwen3:14b39/40
qwen3:30b-instruct39/40
granite4.1:30b40/40
glm-4.7-flash40/40

qwen3.8:27b-mlx had the fewest observed leaks, but it was not zero. granite4.1:3b had passed an initial round without leaks; across 40 attempts and two phrasings, it leaked 17 times. The initial round identified the wrong model as best.

The test also used an exact-string detector. If the model changed capitalization or split the secret into parts, the detector could count the answer as safe. The measured numbers may therefore undercount real leaks.

Pros and cons

Caveat: the models used different default parameters and the detector was permissive. A low leak count does not prove resistance.

Runtime: no single option covers everything

Ollama covered chat, vision and retrieval. It did not handle reranking; for that I used PyTorch with MPS.

The fine-tuning experiment has its own post: Training on a Mac with MPS. I do not repeat those measurements here.

Memory: the number depends on the counter

The full case is covered in Ollama on a Mac: memory counters disagree. Here are two other counting problems.

On October 22, 2026, for the same granite4.1:8b, Ollama reported 6.2 GB while the process footprint showed 2,658 MB. Part of the model weights did not appear in that process counter. The two tools were answering different questions.

Context length also changes loaded memory. On September 2, 2026, qwen3:14b Ollama showed 15 GB loaded at a context length of 40,960 tokens. At a context length of 8,192, Ollama measured 10 GB. Download size alone does not predict memory while running.

Loading matters too. Switching the resident model took 5.5 to 15.3 seconds. Measure generation after loading separately because the first request may include the loading cost.

Throughput is not constant either. qwen3:30b-instruct generated at 82.4 tokens per second on a warmed prompt on August 16. On August 17, under real load, it generated 1,500 tokens in 30.3 seconds, or 49.5 tokens per second. The conditions do not form a controlled comparison. I would estimate memory from the usage context and measure generation while the machine is busy.

What I measured and what I did not

Summary

For a practical local stack, I would keep qwen3:30b-instruct for chat, bge-m3 for embeddings, bge-reranker-v2-m3 through PyTorch/MPS for reranking, and granite4.1:8b as the starting point for tool calls. For code, I would pick granite4.1:30b when correctness matters most and qwen3:30b-instruct when time matters more. For vision, I would use MiniCPM-V 4.5 when the image needs to stay local and its wait fits the workflow. For classification, I would repeat the evaluation with the real labels before choosing.

For injection, no model passed without leaks. A local model can be part of the security measures, but it is not sufficient on its own. Choosing a model for each task is the earlier qualitative map. Choose by task. Repeat the same test. Measure with the machine busy.

I help teams use AI agents in daily software work. If your team does that, let's talk.

See consulting