[whatmodel.sh](../../README.md) / StarCoder2 15B # StarCoder2 15B BigCode · released 2024-02 · 15.96B params · bigcode-openrail-m **score 40.5** ±0.5 · #556 of 732 · from 17 benchmark results across 5 sources Score within the [LMArena (text)](https://whatmodel.sh/?set=lmarena-text&score=set) comparison set only. ## What it's good at ● marks StarCoder2 15B among every model on that task or test, worst to best.
task    vs the others          rank  counts  tests
coding  ▁▁▁▃●▇█▇▅▄▃▁    #399 of 469     87%      9
math    ▁▁▃▅█●▄█▄▂▁▁   #242 of 431*    2.8%      1
coding · #399 of 469 · 87% of its score Beats [DeepSeek R1 Distill Qwen 7B](deepseek-r1-distill-qwen-7b.md), [Qwen3.5 2B](qwen3-5-2b.md), [DeepSeek R1 Distill Llama 8B](deepseek-r1-distill-llama-8b.md) here, though they rank higher overall. Trails [Qwen2.5 1.5B Instruct](qwen2-5-1-5b.md), [WizardLM 13B V1.2](wizardlm-13b-v1-2.md), [Falcon3 3B Instruct](falcon3-3b.md) here, though they rank lower overall.
test                                result  vs the others in its run  difficulty        counts  why
HumanEval                            46.3%  ▁·▁▁▃▄●▅█▃▁▁ beats 30/99  easy · avg 76%       45%  sharp · at its level · several runs
HumanEval+                           37.8%  ▁·▁▁▁▃●▄▄█▃▁ beats 27/99  easy · avg 70%       18%  sharp · at its level
MBPP                                 51.2%  █·▅▃▃▃▅▃▃▅·● beats 14/15  easy · avg 81%      6.0%  at its level · several runs
HumanEvalSynthesize (HumanEvalPac…   44.4%  ▁·▂▁▂▆▅█●▄▁▂ beats 26/35  medium · avg 62%    4.8%  at its level
DS-1000 (maker)                      33.8%  ▄▄·▄██▄█·●·▄ beats 10/12  medium · avg 49%    2.9%  at its level
HumanEvalExplain (HumanEvalPack, …   17.0%  ▄▇●▃▄▇▄▁▇▃·▁ beats 12/35  medium · avg 46%    2.9%  at its level
CRUXEval-I                           47.4%  ▃▅█▃▃▅·▃▃▅·● beats 14/15  medium · avg 56%    2.8%  at its level · several runs
HumanEvalFix (HumanEvalPack, 6-la…   21.9%  ▁·▁▁▄██●█▁▅▅ beats 20/35  medium · avg 51%    2.7%  sharp
CRUXEval-O                           46.7%  ▃·▃██▅▃·▃▃▅● beats 15/15  medium · avg 54%    2.2%  blunt · at its level · several runs
math · #242 of 431 · 2.8% of its score Beats [GPT-4o (2024-08-06)](gpt-4o-2024-08-06.md), [Command A (03-2025)](command-a.md), [GPT-4o (2024-05-13)](gpt-4o-2024-05-13.md) here, though they rank higher overall. Trails [Gemma 7B (base)](gemma-7b-base.md), [CodeGemma 7B (v1.0)](codegemma-7b.md), [Phi-2 (2.7B)](phi-2.md) here, though they rank lower overall.
test           result  vs the others in its run  difficulty      counts  why
GSM8K (maker)   65.1%  ▄▄▄·▄█·██·█● beats 12/12  easy · avg 75%    2.8%  sharp · at its level
other tests (2)
test                             result  vs the others in its run  difficulty        counts  why
EvoEval (overall)                 29.0%  ▂▂▃▄●█▁▄▅▃▁▃ beats 13/42  medium · avg 52%    7.2%  at its level
BigCodeBench (Complete) (maker)   38.3%  ▂▁▁▄▂▅●█▆▂▂▂ beats 22/58  medium · avg 48%    3.0%  at its level
## How the score was worked out Each result implies a score on its own, after adjusting for how hard that test is and who ran it. The model's 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 is added up by who ran the tests. [Method](../method.md)
source                                    results  share of the score
EvalPlus / EvalPerf published evaluatio…        2   41% ▇▇▇▇▇
Top Leaderboard Ranking = Top Coding Pr…        2   21% ▇▇
StarCoder 2 and The Stack v2: The Next …        6   19% ▇▇
Granite Code Models: A Family of Open F…        6   17% ▇▇
BigCodeBench paper (submitted / maker-r…        1    3% ▇
prior: pull toward the middle                        0% ▇
weighted average                                   = 40.5
Licences: EvalPlus / EvalPerf published evaluation runs ([Apache-2.0](../../licenses/evalplus-published-runs-Apache-2.0.txt)) · Top Leaderboard Ranking = Top Coding Proficiency ([CC BY 4.0](../../licenses/paper-2403.19114v1-CC-BY-4.0.txt)) · StarCoder 2 and The Stack v2: The Next Generation ([CC BY-SA 4.0](../../licenses/paper-2402.19173v1-CC-BY-SA-4.0.txt)) · Granite Code Models: A Family of Open Foundation Models for Code Intelligence ([CC BY 4.0](../../licenses/paper-2405.04324v1-CC-BY-4.0.txt)) · BigCodeBench paper ([CC BY 4.0](http://creativecommons.org/licenses/by/4.0/)) ## How to run it ### llama.cpp (recommended) 1. Install llama.cpp. Homebrew and winget installs name the commands llama-cli and llama-server instead. [Other ways to install](https://github.com/ggml-org/llama.cpp/blob/master/docs/install.md) ```sh # macOS / Linux curl -LsSf https://llama.app/install.sh | sh # Windows irm https://llama.app/install.ps1 | iex ``` 2. Run StarCoder2 15B (Q4_K_M, needs ~9.9 GB, from [huggingface.co/second-state](https://huggingface.co/second-state/StarCoder2-15B-GGUF/tree/4d76ffd0a6da75113a3971639b36309cde2364d7)) ```sh llama cli -hf second-state/StarCoder2-15B-GGUF:Q4_K_M ``` 3. Or start a local server and open the address it prints (http://localhost:9931) ```sh llama serve -hf second-state/StarCoder2-15B-GGUF:Q4_K_M ``` Other versions: Q8_0 (~17 GB) `llama cli -hf second-state/StarCoder2-15B-GGUF:Q8_0` ### LM Studio 1. Install LM Studio. Open the app once before using the lms command. [Download it (macOS / Windows / Linux)](https://lmstudio.ai/download) 2. Run StarCoder2 15B (Q4_K_M, needs ~9.9 GB, from [huggingface.co/second-state](https://huggingface.co/second-state/StarCoder2-15B-GGUF/tree/4d76ffd0a6da75113a3971639b36309cde2364d7)) ```sh lms get https://huggingface.co/second-state/StarCoder2-15B-GGUF@Q4_K_M -y ``` 3. Then run lms ls to see its name, and lms chat followed by that name Other versions: Q8_0 (~17 GB) `lms get https://huggingface.co/second-state/StarCoder2-15B-GGUF@Q8_0 -y` · 4bit (~9 GB, Mac only) `lms get https://huggingface.co/mlx-community/bigcode-starcoder2-15b-4bit -y` · 8bit (~17 GB, Mac only) `lms get https://huggingface.co/mlx-community/bigcode-starcoder2-15b-8bit -y` ### Ollama 1. Install Ollama. [Download it (macOS / Windows)](https://ollama.com/download) ```sh # Linux curl -fsSL https://ollama.com/install.sh | sh ``` 2. Run StarCoder2 15B (Q4_K_M, needs ~9.9 GB, from [ollama.com](https://ollama.com/library/starcoder2/tags)) ```sh ollama run starcoder2:15b-q4_K_M ``` Other versions: Q8_0 (~17 GB) `ollama run starcoder2:15b-q8_0` ### MLX (Mac) 1. Install MLX (Mac). Apple silicon Macs only, text only. ```sh # with uv uv tool install mlx-lm # or pip install mlx-lm ``` 2. Run StarCoder2 15B (4bit, needs ~9 GB, Mac only, from [huggingface.co/mlx-community](https://huggingface.co/mlx-community/bigcode-starcoder2-15b-4bit/tree/7b68b8f7cc25665c4cd615b631afbe2701e11380)) ```sh mlx_lm.chat --model mlx-community/bigcode-starcoder2-15b-4bit ``` 3. Or start an OpenAI-compatible server at http://localhost:8080/v1 ```sh mlx_lm.server --model mlx-community/bigcode-starcoder2-15b-4bit ``` Other versions: 8bit (~17 GB, Mac only) `mlx_lm.chat --model mlx-community/bigcode-starcoder2-15b-8bit` Model repository and documentation: [huggingface.co/bigcode](https://huggingface.co/bigcode/starcoder2-15b) [interactive version](https://whatmodel.sh/model/starcoder2-15b) · [JSON](https://whatmodel.sh/api?format=json&all=1)