[KongchangAI]
· 3 min read· 1,567 words

Local AI Coding Models Tested: Can 18GB VRAM Beat Opus?

Local AI Coding Models Tested: Can 18GB VRAM Beat Opus?

A systematic guide to picking local coding models — exposing benchmark traps by VRAM tier.

This article breaks down the most common pitfalls in selecting local coding models: the massive gap between puzzle-style benchmarks like Live Code Bench and real-world repo-fixing ability measured by SWE-Bench. Gemma shines on puzzles but scores just 17.4% on real repos, while Qwen hits 73.4% in the same tier. The 24GB sweet spot goes to Qwen3.6/3.8 27b, though Qwen3.8's claim of beating Opus relies on a vendor-modified benchmark. Bigger isn't always better — the 52GB Qwen3 Coder Next runs at just 5.5 tokens/s and scores lower than the 27b models. The core methodology: before trusting any leaderboard, check model recency, test source, benchmark type, and real VRAM headroom.

Why Choosing the Wrong Local Coding Model Costs You Twice

One of the most recommended local coding models right now is the Gemma series — it fits on a gaming GPU, it's free, and it's fast. But in Qwen's official comparison table, it only fixes 17.4% of real GitHub issues, while the Qwen model right next to it scores 73.4%. Same table, four-times the gap. So which one should you actually download?

A content creator abroad did a systematic breakdown of this question, covering four VRAM tiers — 16GB, 24GB, 32GB, and 64GB — with real Snake game code generation tests, speed benchmarks, and a benchmarking trap that can fool almost anyone. The key detail: every number in the video is sourced, not self-tested.

The cost of picking the wrong model is twofold: you download a 19GB file, and then your coding agent spins its wheels on a bug it fundamentally can't fix. Worse, many of the top-ranked leaderboards circulating right now are already outdated.

Rule #1: The Model Must Be Recent Enough

The first hard rule the creator set: every model in the video must have been released within the past 12 months (as verified on Hugging Face). This alone eliminated two long-standing favorites — Qwen3 Coder 30b and GPT-OSS 20b — which still appear on recommendation lists published in recent months.

The seven models that made the cut include: GLM 4.7 Flash and Qwen3 Coder Next, Gemma 4 26b and Gemma 4 31b, the Qwen3.6 series, Gemma 4 12b, and the latest Qwen3.8 27b. Keeping your model selection current is the first line of defense against being misled by outdated leaderboards.

The Benchmarking Trap: Puzzle Scores ≠ Repo-Fixing Ability

This is the most important insight in the whole piece. Different benchmarks measure entirely different capabilities:

  • SWE-Bench Verified: Gives the model real GitHub issues and checks whether its patch passes the tests
  • SWE-Bench Pro: A harder version of the above
  • Terminal Bench: Agent tasks run in the command line
  • Live Code Bench: Competition-style puzzle solving

Solving puzzles and fixing your actual codebase are two completely different things. Google's official model card gives Gemma 4 26b a 77.1% on Live Code Bench — looks elite. But Google's card includes no SWE-Bench score at all. The only source available is Qwen's model card, which gives Gemma 4 26b a SWE-Bench Verified score of just 17.4, while the MoE-based Qwen3.6 35b A3b scores 73.4 — four times higher for models in the same tier.

Gemma performs weaker on large-repo tasks

To be fair, that number comes from a competitor running tests inside Qwen's own agent environment. But Atomic Chat's coding guide reaches the same conclusion: Gemma "performs worse on large repository tasks." Stronger at puzzles, weaker on real repos — that's the through-line of this entire analysis.


SWE-Bench Verified is currently the mainstream benchmark closest to "real-world coding work." It pulls actual bug reports and their corresponding fix PRs from GitHub, has the model generate patches independently without knowing the answer, and then validates whether those patches actually fix the issue using the original test suite. This means the model must not only understand the codebase's context but also write changes that pass existing unit tests — simply memorizing syntax rules or solving algorithm puzzles is nowhere near sufficient. By contrast, Live Code Bench problems are closer to LeetCode competitions: given a standalone function signature, write a compliant implementation, with almost no cross-file dependencies, legacy code styles, or incremental edits involved. The two benchmarks test fundamentally different cognitive paths, which explains why a model can dominate the puzzle leaderboard while completely falling apart on real repository tasks.


VRAM and File Size: 16GB Machines Are Already Tight

According to Ollama's official library page: Gemma 4 12b is around 8GB, Gemma 4 26b is 16–19GB, Qwen3.8 27b is 18GB, GLM 4.7 Flash is 19GB, Qwen3.6 35b is 23–24GB, and Qwen3 Coder Next is a massive 52GB.

And remember — that's just the model file itself. Your context window, editor, and operating system all need additional memory. So downloading a 16–19GB model on a 16GB machine is already pushing it.

Did 18GB Really Beat Opus?

24GB is the sweet spot. Qwen3.6 27b (a dense model released in April) scores SWE-Bench Verified 77.2, SWE-Bench Pro 53.5, and Live Code Bench 83.9 on Qwen's card, with a file size of around 18–19GB. The newer Qwen3.8 27b is also 18GB, but its scores jump to SWE-Bench Pro 61.7, Terminal Bench 2.1 at 73, and Live Code Bench 90.3.

It's this table that claims it beats Opus 4.6 Max on SWE-Bench Pro: 61.7 vs. 53.4.

Comparison table claiming a win over Opus 4.6 Max on SWE-Bench Pro

But look at the footnotes: Opus's score is the officially reported figure, while the Qwen model ran on a "corrected and refined" version of the benchmark by Qwen itself — they're not running the same test at all. So no, an 18GB file hasn't actually beaten Opus.

The creator turned to the independent source Artificial Analysis and its Intelligence Index: Qwen3.8 27b scores 34, Qwen3.6 27b scores 21, Gemma 4 26b scores 17, GLM 4.7 Flash scores 15, Gemma 4 12b scores 14, and Qwen3 Coder Next scores just 9 (some marked as estimates). One more key detail: Artificial Analysis noted that Qwen3.8 generated at least 7 million tokens during testing, while the median was only 820,000 — it "overthinks." On a local machine, every thinking token is time you're waiting.


The Artificial Analysis Intelligence Index is a composite score weighted across multiple capabilities — coding, reasoning, instruction following, and more — run by a third-party organization in a unified environment. Its purpose is to provide a cross-model baseline that isn't under vendor control. Compared to vendor self-reported single benchmarks, it's much harder to game by "cherry-picking favorable tests." The gap between Qwen3.8 27b (34) and Gemma 4 26b (17) in this context is more informative than the numbers on vendor model cards. It's worth noting that some scores are flagged as "estimates," meaning not all models have completed the full test suite — cross-referencing other sources is still essential when making a selection.


Tiered Recommendations and Real-World Speed Tests

32GB can run Qwen3.6 35b A3b (23–24GB), which activates only about 3 billion parameters per token, making it fast — SWE-Bench Verified 73.4. The alternative is GLM 4.7 Flash (19GB, MIT license), with SWE-Bench Verified 59.2 — solid, but behind Qwen.

GLM 4.7 Flash uses the MIT license

In real output tests, Atomic Chat gave four models the same prompt: write a playable Snake game and play it until it loses. Gemma 4 26b ran at around 136 tokens/s, while the dense Qwen3.6 27b clocked around 47 tokens/s — same prompt, three times slower. Qwen3.6 27b produced the best Snake game of the four (score 80), but on the second test — a bouncing ball physics simulation — it was the only one that failed. Meanwhile, the much faster Gemma passed both tests.

At the 64GB tier, Qwen3 Coder Next is an 80-billion-parameter beast with only 3 billion active, scoring SWE-Bench Verified 70.2 — but in Atomic Chat's testing it ran at only 5.5 tokens/s, and on Artificial Analysis it scores just 9, lower than the 27b models. Bigger does not automatically mean better.

Speed also depends on your runtime. According to Stridenote, Ollama's own tests show Qwen3.5 35b jumping from 58 tokens/s to 112 tokens/s after switching to Apple Silicon's MLX — nearly double the speed, same model.

Speed nearly doubles after switching to MLX


MoE (Mixture of Experts) architecture is the key to understanding why "large parameter count but still fast" is possible. Traditional dense models activate all parameters on every inference pass; MoE models divide parameters into specialized "expert" modules and only route each token through a small subset, leaving the rest idle. The name Qwen3.6 35b A3b reflects this exactly: 35 billion total parameters, but only about 3 billion (A3b) are activated per token. This gives it inference speed and VRAM usage close to a 3B dense model, while its large pool of experts provides knowledge capacity and task performance closer to a much larger dense model. MLX is Apple's machine learning framework optimized for the unified memory architecture of Apple Silicon — it makes more efficient use of M-series chip bandwidth compared to Ollama's default backend, so it's no surprise that the same model runs nearly twice as fast under MLX.


Quick Selection Table and Four Verification Rules

Model Selection Quick Reference:

  • 16GB: Gemma 4 12b
  • 24GB: Qwen3.6 27b, or Qwen3.8 27b (if you can wait for it to think)
  • 32GB: Qwen3.6 35b (for speed)
  • 64GB: Qwen3.8 for higher accuracy, or Coder Next (if you have patience)

Four checks before trusting any leaderboard:

  1. Was the model released within the last year?
  2. Who ran the benchmark — the vendor or an independent third party?
  3. Which benchmark was used — real repository tasks or puzzle-solving?
  4. Does the file size plus context overhead actually fit in your VRAM?

The value of this methodology exceeds the specific recommendations themselves. In an era where vendors cherry-pick the most favorable benchmarks for their own models, learning to distinguish the source and nature of benchmark scores is the real skill local deployment users need to develop.

#local AI coding model#SWE-Bench#Qwen3 vs Gemma#local LLM VRAM#benchmark comparison#Qwen3.8 27b#MoE model#coding agent
Share:

Related articles