Which Local LMs are Best For Which Tasks
A local language model is one whose actual weights, the enormous file of learned numbers that constitutes the trained model, you download and run entirely on your own hardware.
Someone spends an evening reading "best local LLM" roundups, settles on whichever name keeps showing up at the top, downloads it, and points it at the thing they actually needed help with that week, say, cleaning up a Python script. But it's mediocre at that. Not broken, just unimpressive, in the specific way a generalist is unimpressive at a specialist's job.
The model wasn't bad. It was never a coding model to begin with, and nothing in the roundup that recommended it ever said so. That mismatch is the entire reason this guide exists. "Best" was never a single ranking, and treating it like one is how a genuinely capable model ends up feeling disappointing for no fault of its own.
This article works the other way around: what a local language model actually is, why running one on your own hardware is worth doing at all, and then, model by model, with real cited proof rather than vibes, exactly what each one is good at. It closes with one table built specifically to answer the only question that actually matters: for the task in front of you right now, which model should you reach for?
What Is a Language Model, and What Makes One "Local"?
A language model is, at its core, a system trained to predict text: given everything that came before it in a conversation or a document, what's the most plausible next piece of text? That simple mechanism, applied at enormous scale, is what lets a model answer questions, write code, summarize a document, or hold a conversation.
Every well-known AI chat product, whether it's ChatGPT, Claude, or Gemini, is built on top of a language model doing exactly this.
"Local" describes something about how you access that model, not what it is. A local language model is one whose actual weights, the enormous file of learned numbers that constitutes the trained model, you download and run entirely on your own hardware. No API call leaves your machine. No account is required to use it. No company's server ever sees your prompt.
That's a genuinely different relationship to the technology than using a hosted model through a website or an API key, where every request travels to someone else's infrastructure and the model itself is something you can query but never actually possess.
Why Local Language Models Actually Matter
- Privacy is the most obvious one: if nothing about a prompt ever leaves your device, there's no third party in a position to log, train on, or leak it, which matters directly for anything involving client data, medical information, unpublished work, or a company's internal documents
- Cost is the second, since once the weights are on disk, there's no per-token bill accumulating with every request, which changes the calculus entirely for anything high-volume or experimental
- Offline capability is the third, genuinely useful for fieldwork, air-gapped environments, or just an unreliable connection
- Control is the fourth and most underrated: a local model doesn't get silently swapped, deprecated, or have its behavior changed by a provider's update; it behaves the same way today as it will in a year, because you're the one holding the weights
Ollama, the tool that's become the de facto standard for running these models locally, hosts a public library of ready-to-pull GGUF builds for every model covered in this article, and the real download numbers behind some of these models, covered in detail later in this piece, run into the tens of millions.
Why "Best" Depends on the Task, Not the Leaderboard
This is the idea the rest of the article is built around, so it's worth making explicit. A single aggregate benchmark score, or a raw parameter count, tells you surprisingly little about whether a specific model will actually serve you well on a specific task. A model can score well on general knowledge and still write mediocre code. A small, efficient model can lead its entire weight class on tool calling while trailing badly on creative writing. Treating any one number as "the" ranking is how people end up disappointed by genuinely good models used for the wrong job.
It helps to know, briefly, what the benchmarks that show up throughout this article are actually measuring, since they're not interchangeable. Massive Multitask Language Understanding (MMLU) tests broad general knowledge across dozens of academic subjects, a reasonable proxy for how much a model "knows." HumanEval specifically tests whether a model can write correct, functioning code for a given problem, a direct measure of coding capability rather than general intelligence. MT-Bench measures how well a model follows instructions and holds a coherent multi-turn conversation, closer to what "feels good to actually talk to" captures.
Keep those distinctions in mind as the numbers show up model by model below, since a model leading on one says nothing certain about where it lands on the others.
The Models, One at a Time
Seven models make up this article: six general-purpose chat models plus one embedding model that plays a different but essential role in any local retrieval-augmented generation (RAG) setup. Every claim below is checked against the model's own official card or a cited independent benchmark, not repeated secondhand.
1. Phi-4-mini
Phi-4-mini is Microsoft's answer to a specific question: how much real capability can you fit into a genuinely small model? Per Microsoft's own Phi-4-Mini Technical Report, it scores 67.3 on MMLU (5-shot) and 70.4 on BigBench-Hard, competitive numbers for a model roughly a fifth the size of many 20B-class competitors. A separate, independent 2026 evaluation of reasoning consistency across foundation models found Phi-4-mini leading its comparison group on step-by-step reasoning accuracy specifically, per a cross-platform reasoning capabilities study. That's a meaningfully different claim than just "knows a lot of facts"; it suggests the model's actual reasoning process holds together reliably even at this size.
What it's exceptionally good at:
- Lightweight general question-answering
- Structured output and function calling
- It's the model worth reaching for when the constraint is the hardware itself, not the ambition of the task
2. Gemma 4 E2B and E4B
Gemma 4 is Google DeepMind's current generation of open-weight models, released April 2, 2026, and verified directly from Google's own model card. The E2B and E4B variants are the two smallest in a five-size family. They are natively multimodal, accepting text, images, and, on these smaller variants specifically, audio too. Both carry native function-calling support trained directly into the model weights rather than bolted on through prompting, and a 128K context window even at this small size.
What it's exceptionally good at:
- Writing and document-focused work, where its multimodal input and clean instruction adherence show up directly in output quality, and genuinely constrained edge deployment, since the E2B variant's footprint is small enough to run on phones and other genuinely limited devices
3. Qwen2.5-7B-Instruct and Qwen2.5-Coder-7B-Instruct
Qwen2.5-7B-Instruct posts 74.2 on MMLU and 84.8 on HumanEval according to Qwen's own technical release notes, genuinely strong numbers on both general knowledge and coding for a 7B model. The dedicated coding variant, Qwen2.5-Coder-7B-Instruct, pushes further still, reaching 88.4 on HumanEval in independently logged evaluation results, a real jump over the general-purpose version specifically on code generation.
What it's exceptionally good at:
- Coding assistance, where the Coder variant specifically earns its name, and multilingual work, since Qwen's training data and tokenizer give it a real edge over Llama-family models for non-English tasks
4. Qwen3.5-9B
Qwen3.5-9B is a genuinely current release, verified directly on its own Hugging Face model page: natively multimodal from the ground up rather than adapted after the fact, a 262K native context window, and a Mixture-of-Experts architecture built around Gated Delta Networks for efficient inference relative to its total parameter count. It's Apache 2.0 licensed, meaning it can be fine-tuned and deployed commercially without restriction.
What it's exceptionally good at:
- Agentic workflows and tool calling specifically, where architecture and training were built with exactly that use case in mind. It's also a strong, safe default pick generally: the model worth reaching for when you're genuinely unsure what else on this list fits, since it's currently the strongest all-around generalist in its size class.
5. Mistral 7B
Mistral 7B remains one of the most widely fine-tuned open-weight base models in the entire ecosystem, verified via Mistral AI's own Hugging Face organization page. Its defining trait was never raw benchmark-topping capability; it's the clarity and reliability of its instruction-following, producing clean, well-structured output with comparatively little prompt engineering required to get there.
What it's exceptionally good at:
- General chat, commit messages, README files, and documentation, exactly the kind of writing where clarity and consistency matter more than pushing the frontier of raw reasoning ability
6. Llama 3.1 8B
Llama 3.1 8B's real, verified size and release come directly from Meta's own model card and Meta's official launch announcement. One factual note worth being precise about, since it trips up a lot of guides: Meta's later Llama 3.3 release exists only as a 70B model. There is no official Llama 3.3 8B, so Llama 3.1 8B remains the correct, current reference point at this specific size within the Llama family.
What it's exceptionally good at:
- Sitting at the center of, by a wide margin, the largest community fine-tuning ecosystem of any model on this list. If a specific niche use case exists - legal document review, a particular coding language, a regional dialect - there's a meaningfully higher chance someone has already built and published a Llama-based fine-tune for it than for any other model here.
7. nomic-embed-text - Nomic AI, Apache 2.0
This is the one model on this list that isn't a chat model at all, and arguably the most quietly essential one for anyone building a local RAG pipeline. Per a June 2026 benchmarked comparison of every major Ollama embedding model, nomic-embed-text runs at 137 million parameters with a footprint under 300MB and supports an 8,192-token native context window. Note that Ollama's default listing sometimes shows a smaller 2,048 figure, so explicitly set the context length rather than assuming the larger number applies automatically. As of that comparison, it had accumulated 85.6 million pulls on Ollama, the single clearest piece of real, measurable adoption evidence anywhere in this article.
What it's exceptionally good at:
- The embedding half of any local RAG setup
- Converting text into the vector representations a semantic search pipeline actually searches over
- It pairs with any of the six chat models above rather than competing with them, since embedding and generation are two different jobs in the same pipeline
The Summary Table
Here's the payoff this entire article has been building toward, the one table worth bookmarking.
| If you want to | Use this model | Why | Approximate VRAM at Q4 |
|---|---|---|---|
| Run something capable on very limited hardware | Phi-4-mini | Best capability-per-gigabyte at 3.8B, strong reasoning consistency for its size | ~2.5GB |
| Write documents, emails, or handle multimodal input on the edge | Gemma 4 E2B / E4B | Native multimodal input, clean writing output, runs on genuinely small devices | ~1.5-3GB |
| Get coding help or work in a language other than English | Qwen2.5-Coder-7B / Qwen2.5-7B-Instruct | Leading HumanEval scores in its class, strong multilingual tokenizer and training data | ~5-6GB |
| Build an agent that reliably calls tools | Qwen3.5-9B | Architecture and training built specifically around agentic tool use | ~6.5GB |
| Draft clean, reliable general writing without much prompt engineering | Mistral 7B | Clear, consistent instruction-following out of the box | ~5GB |
| Find a fine-tune for a specific niche use case | Llama 3.1 8B | By far the largest community fine-tuning ecosystem of any model here | ~6GB |
| Power the retrieval side of a local RAG pipeline | nomic-embed-text | Tiny footprint, long native context, by far the most widely adopted local embedding model | ~0.3GB |
| Pick one model when you're not sure what else fits | Qwen3.5-9B | Strongest current all-around generalist in its size class | ~6.5GB |
All seven models are available as ready-to-pull GGUF builds through Ollama, a single ollama pull away, with no separate conversion or setup step required for any of them.
Conclusion
The useful question was never "what's the best local model?" It's "what am I actually trying to do right now?" The honest answer to that question changes depending on whether the task is writing a cover letter, debugging a Flask app, or building the retrieval layer of a RAG pipeline. Seven models, seven real, cited reasons each one earns its place on this list. Match the model to the task in front of you, not the other way around, and the disappointment that opened this article stops happening at all.
Shittu Olumide is a software engineer and technical writer passionate about leveraging cutting-edge technologies to craft compelling narratives, with a keen eye for detail and a knack for simplifying complex concepts. You can also find Shittu on Twitter.
Comments
No comments yet. Start the discussion.