How to Pick the Right Open-Source LLM for Your Project
Published . Facts checked against each project's own site, repository, or license text.
Pick the license first, then the size your hardware can hold, then test two or three candidates on your own tasks. Most "open-source LLMs" are open-weight models: you can download and run the weights, but the license may add conditions, and the training data is usually not published. Those conditions matter more for a product than a few points on a benchmark.
This guide uses license and size data checked on October 13, 2026, from each model's Hugging Face page and its publisher's license text. Models change quickly, so confirm the model card before you commit.
Open source, open weights, and why the difference matters
The Open Source Initiative published version 1.0 of its Open Source AI Definition. It asks for the same freedoms as open-source software: use the system for any purpose without asking permission, study how it works, modify it, and share it. For a machine-learning system it also requires three things under OSI-approved terms: detailed information about the training data, the complete code used to train and run the model, and the model parameters.
Few popular models meet all of that. Most publish weights and inference code but not enough about the training data. In practice you are choosing between three kinds of license:
- Standard open-source licenses such as Apache-2.0 or MIT applied to the weights. You can use, modify, and ship the model commercially, with the usual notice requirements.
- Custom community licenses, such as Meta's Llama license or Google's Gemma terms for Gemma 3. They let you use, modify, and redistribute the model, but they add conditions, and some of those conditions travel with the model when you redistribute it.
- Fully open releases, where the publisher also releases training data and code. AI2's OLMo is the clearest example in this list.
The main options, checked October 2026
| Model | License on Hugging Face | Size (parameters) | What to know |
|---|---|---|---|
| gpt-oss-20b (OpenAI) | Apache-2.0 | about 21B | The model card says it runs within 16 GB of memory with its MXFP4 quantization. |
| gpt-oss-120b (OpenAI) | Apache-2.0 | about 117B (5.1B active) | Fits on a single 80 GB GPU, such as an NVIDIA H100, according to the model card. |
| Qwen3-8B, Qwen3-32B (Alibaba Qwen) | Apache-2.0 | 8.2B and 32.8B | Two sizes from one family, useful when you want to test a small and a large model from the same release. |
| Mistral-7B-Instruct-v0.3, Mistral-Small-3.1-24B (Mistral AI) | Apache-2.0 | about 7B and 24B | Check each Mistral model separately: some other Mistral releases, such as Codestral-22B and Mistral-Large-Instruct-2407, use Mistral's own non-production or research licenses instead. |
| Gemma 3 (Google) | Gemma terms | for example 12B | If you distribute Gemma or a model derived from it, Section 3.1 of the Gemma terms requires you to include its use restrictions in your agreement with the people you distribute it to. |
| Gemma 4 (Google) | Apache-2.0 | five sizes, up to 31B | Google's Gemma 4 models are listed under Apache-2.0, unlike Gemma 3. |
| Llama 3.1, 3.3, and 4 (Meta) | Llama community licenses | 8B, 70B, and 405B for 3.x | Commercial use is allowed, with the conditions described below. Downloads on Hugging Face require accepting the license. |
| DeepSeek-R1 (DeepSeek) | MIT | 671B (37B active) | Very large. The full model needs a multi-GPU server. |
| OLMo 2 13B Instruct (AI2) | Apache-2.0 | about 14B | The model card says it was trained on the Dolma dataset and that AI2 releases code, checkpoints, and training details. |
| Phi-4 (Microsoft) | MIT | 14B | A mid-size model under a permissive license. |
The Llama licenses have two terms that surprise teams late. If your products had more than 700 million monthly active users in the month before the model's release date, you must request a separate license from Meta. And if you distribute the model or a product built on it, you must show "Built with Llama," and any model you build with Llama or its outputs and then distribute must include "Llama" at the beginning of its name. Both terms are in the Llama 3.1 and Llama 4 license files Meta publishes.
How much hardware a model needs
A model's weights take roughly its parameter count multiplied by the bytes stored per parameter. At 16-bit precision that is two bytes per parameter, so an 8B model needs about 16 GB just for the weights. Quantized to 4 bits, the same model needs about 4 GB. Your runtime also needs memory for the context window (the KV cache) and its own overhead, so leave headroom on top of these numbers.
That arithmetic narrows the list quickly:
- A laptop or a single consumer GPU suits models up to roughly 8B to 14B when quantized, and gpt-oss-20b according to its card.
- A single 80 GB data-center GPU fits gpt-oss-120b and 70B-class models when quantized.
- DeepSeek-R1 at full size needs several GPUs.
Pick a runtime that matches how you will serve it
The model is only half the decision. The software that runs it decides how easy it is to operate.
- Ollama (MIT) is the simplest way to run models locally from the command line or an API. The gpt-oss model card itself uses Ollama as its consumer-hardware example.
- llama.cpp (MIT) is a C/C++ inference engine, listed by Ollama as its backend, and the one to use when you want control over quantization formats.
- vLLM (Apache-2.0) is built for high-throughput serving, which matters once several users or services share one GPU.
- LocalAI (MIT) gives you an OpenAI-style API for local models, which helps when existing code already calls the OpenAI API.
If people rather than programs will use the model, add a chat interface such as LibreChat or AnythingLLM. Our list of open-source ChatGPT alternatives compares the options for that layer.
A shortlist process that works
- Write down the job in one sentence, such as "summarize support tickets in English and Spanish" or "answer questions from our docs."
- Remove models whose license your legal team will not accept. If you ship to customers, this usually leaves Apache-2.0 and MIT models, or a community license you have read in full.
- Remove models your hardware cannot hold, using the memory arithmetic above.
- Run the two or three survivors on 30 to 50 real examples from your own data and compare the outputs side by side. Public benchmarks measure general skill; your examples measure your job.
- Measure speed on your hardware with your context length, because speed usually falls as the context grows.
- Keep the prompt and test set, so you can rerun the comparison when a new model version appears.
Frequently asked questions
- Is Llama open source?
- Meta releases Llama weights under its own community license, not an OSI-approved license. It allows commercial use but adds conditions, including the 700 million monthly active user threshold and the "Built with Llama" notice.
- Which open-source LLM is best?
- None is best for every job. For a product you will ship, start with a permissively licensed model that fits your hardware, such as gpt-oss, Qwen3, Mistral's Apache-2.0 models, or Gemma 4, and decide by testing them on your own examples.
- Can I run an open-source LLM without a GPU?
- Yes, for small quantized models. Runtimes such as llama.cpp and Ollama run on a CPU, but generation is slower than on a GPU, so test with your real prompt lengths.
- Do open-weight models send my data anywhere?
- Not when you run them yourself. The prompts stay on the machine running the model, which is the main reason many teams self-host.
Sources
Checked October 13, 2026.
- Open Source Initiative, Open Source AI Definition 1.0
- Hugging Face model pages and API: openai/gpt-oss-20b, openai/gpt-oss-120b, Qwen/Qwen3-8B, Qwen/Qwen3-32B, mistralai/Mistral-7B-Instruct-v0.3, mistralai/Mistral-Small-3.1-24B-Instruct-2503, google/gemma-3-12b-it, google/gemma-4-31B-it, meta-llama/Llama-3.1-8B-Instruct, deepseek-ai/DeepSeek-R1, allenai/OLMo-2-1124-13B-Instruct, microsoft/phi-4; license tags for mistralai/Codestral-22B-v0.1 and mistralai/Mistral-Large-Instruct-2407; Llama sizes from meta-llama/Llama-3.1-405B-Instruct and meta-llama/Llama-3.3-70B-Instruct
- Google, Gemma Terms of Use and Gemma 4 license
- Meta, Llama license files in meta-llama/llama-models (Llama 3.1, Llama 3.3, and Llama 4)
- GitHub repositories for Ollama, llama.cpp, vLLM, and LocalAI