induwara.lk
induwara.lkAI · Local models

Small Language Model (SLM) Comparison

Compare small, self-hostable LLMs by parameters, context window, license and modality — then enter your RAM or VRAM to see exactly which ones run on your machine. Every spec is cited to the official model card. No signup, no API keys.

By Induwara AshinsanaUpdated Jul 18, 2026
Will it run on your machine?17 small models
Model cards · verified 2026-07-18
GB RAM

Your total system RAM available for the model.

Presets
Compute target
Quantization

4-bit k-quant — the common local default; smallest footprint.

Context you need
Best fit for 8 GB RAM · 8K context

Needs about 7 GB at Q4_K_M — leaving headroom in your 8 GB. Its 128K context window covers 8K, license is Gemma Terms (Yes, with conditions), and it handles 140+ languages.

13 of 17listed models fit these settings. “Best fit” is the most capable (highest-parameter) model that still runs on your hardware.

ModelParamsContextMin RAMCommercialFits?
Gemma 3 4BGoogle vision4.3B128K7 GBYes, with conditionsFits
Qwen3 4BAlibaba4B32K7 GBYesFits
Phi-4-miniMicrosoft3.8B128K7 GBYesFits
Llama 3.2 3BMeta3.21B128K6 GBYes, with conditionsFits
Falcon 3 3BTII3.2B32K6 GBYes, with conditionsFits
Granite 3.3 2BIBM2.5B128K6 GBYesFits
Qwen3 1.7BAlibaba1.7B32K4 GBYesFits
SmolLM2 1.7BHugging Face1.7B8K4 GBYesFits
Falcon 3 1BTII1.5B8K4 GBYes, with conditionsFits
Llama 3.2 1BMeta1.24B128K3 GBYes, with conditionsFits
Gemma 3 1BGoogle1B32K3 GBYes, with conditionsFits
Qwen3 0.6BAlibaba0.6B32K3 GBYesFits
SmolLM2 360MHugging Face0.36B8K3 GBYesFits
Falcon 3 7BTII7.5B32K9 GBYes, with conditions
Granite 3.3 8BIBM8.1B128K11 GBYes
Ministral 8BMistral AI8B32K11 GBNo (research only)
Qwen3 8BAlibaba8.2B32K11 GBYes

Specs are each model's own published figures — click a model name to open its official card. The memory number is a conservative estimate (±~10%) for the “will it fit?” decision, not a guarantee of speed. Verified 2026-07-18.

How it works

The comparison data is a static table of hard facts read from each model's official Hugging Face card and config.json — parameter count, transformer layers, hidden size, context window, license and modality. The one thing the tool computes is the minimum memory to run, which is fully deterministic and reproducible by hand:

  1. Weights memory. weights_GB = params_billions × bytes_per_param, where bytes-per-param is 2.0 for FP16, 1.0 for Q8_0, and 0.56 for Q4_K_M (the 4-bit k-quant runs at roughly 4.5 bits per weight including metadata). These are cross-checked against the actual file sizes published on each model's -GGUF repository.
  2. KV-cache memory. kv_GB = 2 × n_layers × d_model × context_tokens × 2 / 1e9. The leading 2 counts one key and one value tensor; the trailing 2 is an FP16 cache. The layer count and hidden size come from each model's config. This term grows with the context you select — on the smallest models it can exceed the weights.
  3. Runtime overhead. A fixed +1.0 GB for the runtime, activations and OS headroom, matching real-world llama.cpp and Ollama footprints.
  4. Estimate and fit. min_memory_GB = ceil(weights_GB + kv_GB + 1.0). A model fits when this is at or below your available memory andthe model's own maximum window is at least the context you asked for.

The weights term is verified two independent ways — from bytes-per-param and from nominal bits-per-weight (÷8) — which agree to within about half a percent, so the estimate is not resting on a single magic number. The KV-cache formula uses the full hidden size with no grouped-query-attention reduction, which makes the figure a deliberate, safe over-estimate. It is meant for the “will it fit?” decision (±~10%), not for provisioning to the megabyte, and it says nothing about speed — throughput depends on your specific CPU or GPU.

Worked examples

Qwen3 4B · Q4_K_M · 8K context · 16 GB laptop

  1. Weights: 4.0B × 0.56 = 2.24 GB
  2. KV cache: 2 × 36 × 2560 × 8192 × 2 / 1e9 = 3.02 GB
  3. Overhead: 1.0 GB
  4. Minimum: ceil(2.24 + 3.02 + 1.0) = ceil(6.26) = 7 GB
  5. 7 GB ≤ 16 GB → fits ✓ (also fits an 8 GB GPU)

Llama 3.2 3B · 4K context · 8 GB laptop — Q4_K_M vs FP16

  1. Q4_K_M weights: 3.2B × 0.56 = 1.79 GB
  2. KV cache: 2 × 28 × 3072 × 4096 × 2 / 1e9 = 1.41 GB
  3. Minimum: ceil(1.79 + 1.41 + 1.0) = 5 GB → 5 ≤ 8, fits ✓
  4. Same model at FP16: weights 3.2 × 2.0 = 6.4 GB
  5. Minimum: ceil(6.4 + 1.41 + 1.0) = 9 GB → 9 > 8, does not fit ✗
  6. Tool suggests dropping to Q8_0 (6 GB) or Q4_K_M (5 GB)

License filter — Ministral 8B, commercial-use ON

  1. Ministral 8B ships under the Mistral Research License
  2. That license is research-only without a separate agreement
  3. With 'Commercial-use OK' enabled, Ministral 8B is filtered out
  4. The recommendation skips to the next fitting Apache-2.0 model
  5. e.g. Qwen3 4B / IBM Granite 2B — cited, not opinion

Frequently asked questions

Sources & references

Related tools

Rate this tool
Be the first to rate

Comments & feedback

Spotted a bug or want an improvement? Tell us — our team reviews every comment, and good ideas get built. Comments are public and anonymous.

Found a bug, a stale spec, or want another model added?

Email me at [email protected] — most fixes ship within 24 hours.