whatmodel.sh / StarCoder2 3B

StarCoder2 3B is an open-weights language model from BigCode, released February 2024. Its published size is 3.03B parameters and a 16k-token context window. Licence: bigcode-openrail-m.

Catalogue identity notes

Maker repo bigcode/starcoder2-3b @733247c: licence tag bigcode-openrail-m. 3,030,371,328 parameters from the Hugging Face safetensors metadata (dense, so active = total). Released 2024-02: stated above. Base model. Released 2024-02 with the StarCoder 2 paper (HF repo created earlier, 2023-11-29). Ollama tags starcoder2:3b-q4_K_M, starcoder2:3b-q8_0 (sizes as listed on the tags page, observed 2026-09-29).

33.3±0.6#616 of 719 LLMsfrom 17 benchmark results across 5 sources

$ how it compares

The LLMs ranked either side of StarCoder2 3B, out of 828 with a score, then more from BigCode.

#modelscorewhereRAMreleased
710Llama 2 13B Chat Meta33±1local~9.8GB2023-07
711Flan-T5 XXL Google33±1local~49GB2022-10
712StarCoder2 3B BigCode33±1local~3.4GB2024-02
713Granite 3B Code Base (2K) IBM33±1local~3.7GB2024-04
714GPT-3 davinci (API base model) OpenAI33±1comparison only2020-06
more from BigCode
521StarCoder2-15B-Instruct-v0.1 BigCode46±1local~11GB2024-04
639StarCoder2 15B BigCode39±1local~11GB2024-02
698StarCoder2 7B BigCode35±1local~6.1GB2024-02

see all LLMs · find the ones that fit your machine

$ what it's good at

coding▁▁▁▃▆██▇▆▄▃▁ #418 of 458 · 89% of its score · 9 tests

Beats DeepSeek R1 Distill Qwen 7B, Qwen3.5 2B, DeepSeek R1 Distill Llama 8B here, though they rank higher overall. Trails Llama 3.2 1B Instruct, SmolLM2 1.7B Instruct, Granite 3B Code Base (2K) here, though they rank lower overall.

testresultvs the others in its rundifficultycountswhy
HumanEval +231.7% ✎▁·▁▁▃▄▆▅█▃▁▁ beats 16/99easy · avg 79%▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇ 48%sharp · at its level · several runs
HumanEval+27.4% ✎▁·▁▁▁▃▄▄▄█▃▁ beats 16/99easy · avg 74%▇▇▇▇▇▇▇ 17%sharp · at its level
MBPP +142.4% ✎█·▅▃▃▃▅▃▃▅·▅ beats 9/15easy · avg 82%▇▇▇ 6.7%at its level · several runs
HumanEvalSynthesize (HumanEvalPack, 6-language average)31.7% ✎▁·▂▁▂▆▅█▄▄▁▂ beats 9/35medium · avg 64%▇▇ 4.8%at its level
CRUXEval-I +132.1% ✎▃▅█▃▃▅·▃▃▅·▅ beats 5/15medium · avg 59%▇ 2.9%at its level · several runs
DS-1000 lab25.0% ✎▄▄·▄██▄█·█·▄ beats 6/12medium · avg 52%▇ 2.8%typical
HumanEvalExplain (HumanEvalPack, 6-language average)13.1% ✎▄▇█▃▄▇▄▁▇▃·▁ beats 5/35medium · avg 49%▇ 2.5%typical
CRUXEval-O +134.0% ✎▃·▃██▅▃·▃▃▅▃ beats 6/15medium · avg 55%▇ 2.4%blunt · at its level · several runs
1 more test
testresultvs the others in its rundifficultycountswhy
HumanEvalFix (HumanEvalPack, 6-language average)11.0% ✎▁·▁▁▄██▄█▁▅▅ beats 8/35medium · avg 56%▇ 2.0%sharp
math▁▃▃▅▆▅▄█▄▁▁▁ #376 of 398 * · 1.9% of its score · 1 test

Beats Command R (03-2024), Molmo 7B-D (0924), Mistral 7B Instruct v0.3 here, though they rank higher overall. Trails Gemma 2B (base), SmolLM2 1.7B Instruct, LFM2 350M here, though they rank lower overall.

testresultvs the others in its rundifficultycountswhy
GSM8K lab27.7% ✎▄▄▄·▄█·██·█▄ beats 5/12easy · avg 75%▇ 1.9%sharp · at its level
other tests2 not in a task · 9.2% of its score
testresultvs the others in its rundifficultycountswhy
EvoEval (overall)20.2% ✎▂▂▃▄▄█▁▄▅▃▁▃ beats 4/42medium · avg 55%▇▇▇ 6.3%typical
BigCodeBench (Complete) lab21.4% ✎▃▁▁▄▂▅▇█▆▂▂▂ beats 1/58medium · avg 50%▇ 2.8%at its level

$ where to run it

llama.cpp · recommended

version

  1. Install llama.cpp · Homebrew and winget installs name the commands llama-cli and llama-server instead.
    macOS / Linux
    curl -LsSf https://llama.app/install.sh | sh
    Windows
    irm https://llama.app/install.ps1 | iex

    other ways to install ↗

  2. Run StarCoder2 3B · needs ~1.8 GB · from huggingface.co/second-state
    chat in the terminal
    llama cli -hf second-state/StarCoder2-3B-GGUF:Q4_K_M
  3. Or start a local server and open the address it prints (http://localhost:9931)
    llama serve -hf second-state/StarCoder2-3B-GGUF:Q4_K_M

LM Studio

version

  1. Install LM Studio · Open the app once before using the lms command.

    download it (macOS / Windows / Linux) ↗

  2. Run StarCoder2 3B · needs ~1.8 GB · from huggingface.co/second-state

    open in LM Studio ↗

  3. Or download it in the terminal
    lms get https://huggingface.co/second-state/StarCoder2-3B-GGUF@Q4_K_M -y
  4. Then run lms ls to see its name, and lms chat followed by that name

Ollama

version

  1. Install Ollama

    download it (macOS / Windows) ↗

    Linux
    curl -fsSL https://ollama.com/install.sh | sh
  2. Run StarCoder2 3B · needs ~1.8 GB · from ollama.com
    chat in the terminal
    ollama run starcoder2:3b-q4_K_M

MLX (Mac)

version

  1. Install MLX (Mac) · Apple silicon Macs only, text only.
    with uv
    uv tool install mlx-lm
    or
    pip install mlx-lm
  2. Run StarCoder2 3B · needs ~1.9 GB, Mac only · from huggingface.co/mlx-community
    chat in the terminal
    mlx_lm.chat --model mlx-community/starcoder2-3b-4bit
  3. Or start an OpenAI-compatible server at http://localhost:8080/v1
    mlx_lm.server --model mlx-community/starcoder2-3b-4bit

Official weights and documentation: huggingface.co/bigcode ↗

$ how the score was worked out · EvalPlus / EvalPerf published… 43%, Top Leaderboard Ranking = Top… 20%, StarCoder 2 and The Stack v2:… 18% and 2 more

Each result implies a score on its own, after adjusting for how hard its test is and who ran it. The score is their weighted average, with a small pull toward the middle for thinly tested models. Each test's weight is its counts column above; here it's added up by who ran the tests. How it works

$ improve this page

Use a short GitHub form or edit the data through a pull request. Every number needs a source; here's which ones we can use.

data updated · sources and licences · json