---
title: "StarCoder: A State-of-the-Art LLM for Code"
description: "StarCoder and StarCoderBase are ~15B-parameter code LLMs trained on 1 trillion tokens of permissively licensed GitHub data from The Stack 1.2, covering 80+ languages, commits, issues and notebooks, with StarCoder further fine-tuned on 35B Python tokens."
url: "https://swe.quest/articles/starcoder-a-state-of-the-art-llm-for-code-ae224d2374e67db4"
canonical: "https://huggingface.co/blog/starcoder"
source: "Hugging Face"
published: "2023-05-04"
difficulty: "easy"
kind: "Announcement"
reading_minutes: 5
tags: ["llms","ai-coding","evals","open-source"]
---

# StarCoder: A State-of-the-Art LLM for Code

A post on [Hugging Face](https://swe.quest/sources/hugging-face.md), published 2023-05-04, 5 min read, Announcement. Original: [https://huggingface.co/blog/starcoder](https://huggingface.co/blog/starcoder)

## Summary

StarCoder and StarCoderBase are ~15B-parameter code LLMs trained on 1 trillion tokens of permissively licensed GitHub data from The Stack 1.2, covering 80+ languages, commits, issues and notebooks, with StarCoder further fine-tuned on 35B Python tokens. With an 8K+ token context, they beat other open code models and match or exceed OpenAI's code-cushman-001 on HumanEval, MBPP, MultiPL-E and DS-1000. A solution-file prompt prefix lifts StarCoder's HumanEval score from 34% to 40.8%, and prompting alone turns the model into a technical assistant. The release includes weights under OpenRAIL-M, training code, an evaluation harness, a PII-redaction dataset and a code attribution tool.

Written by swe.quest, not by the author.

**Difficulty:** Easy: no special background needed; explains what something is and why it matters

## Topics

- [LLMs](https://swe.quest/tags/llms.md) (AI & ML)
- [AI for coding](https://swe.quest/tags/ai-coding.md) (AI & ML)
- [Evaluation](https://swe.quest/tags/evals.md) (AI & ML)
- [Open source](https://swe.quest/tags/open-source.md) (Engineering practices)

## Prerequisites

- large language models ([easy posts on LLMs](https://swe.quest/tags/llms.md?difficulty=easy))
- code generation benchmarks ([easy posts on AI for coding](https://swe.quest/tags/ai-coding.md?difficulty=easy))

## Keywords

StarCoder, StarCoderBase, BigCode, The Stack, HumanEval, OpenRAIL, code-cushman-001, MultiPL-E

## Related posts

- [StarCoder2-Instruct: Fully Transparent and Permissive Self-Alignment for Code Generation](https://swe.quest/articles/starcoder2-instruct-fully-transparent-and-permissive-self-alignment-for-code-7d548d6a3e65fc89.md): Hugging Face · 2024-04-29 · Hard · 6 min read · Model training, LLMs, AI for coding, Evaluation
  StarCoder2-15B-Instruct is instruction-tuned entirely on data generated by its own base model, with no human annotations or distillation from proprietary LLMs.
- [Code Llama: Meta’s state-of-the-art LLM for coding](https://swe.quest/articles/code-llama-meta-s-state-of-the-art-llm-for-coding-c2f826fd04e42ba1.md): Meta Engineering · 2023-08-24 · Easy · 7 min read · LLMs, AI for coding, Model training
  Code Llama is a code-specialized family of Llama 2 models, built by further training Llama 2 on 500B tokens of code (1T for the 70B model).
- [Creating a Coding Assistant with StarCoder](https://swe.quest/articles/creating-a-coding-assistant-with-starcoder-ee69e88ef6796911.md): Hugging Face · 2023-05-09 · Medium · 23 min read · Model training, LLMs, AI for coding, Python
  StarCoder, BigCode's 16B-parameter open code model with an 8k context window, can be turned into a coding assistant either by dialogue prompting or by fine-tuning it on conversations.
- [CoderForge-Preview: SOTA open dataset for training efficient coding agents](https://swe.quest/articles/coderforge-preview-sota-open-dataset-for-training-efficient-coding-agents-83e1f3c7a7bdb67a.md): Together AI · 2026-02-25 · Hard · 14 min read · Model training, AI for coding, AI agents, Evaluation, LLMs
  CoderForge-Preview is an open dataset of 258K test-verified coding agent trajectories (155K passing) covering 51K tasks across 1,655 repositories from R2E-Gym, SWE-Smith and SWE-Rebench.
- [Personal Copilot: Train Your Own Coding Assistant](https://swe.quest/articles/personal-copilot-train-your-own-coding-assistant-058d44307821dd4e.md): Hugging Face · 2023-10-27 · Hard · 15 min read · Model training, AI for coding, LLMs
  HugCoder is a code LLM fine-tuned on the top 10 Hugging Face GitHub repositories, built by cloning repos in parallel, filtering non-code files and training StarCoder with a fill-in-the-middle objective.

Browse: [Latest posts](https://swe.quest/index.md) · [Topics](https://swe.quest/tags.md) · [Sources](https://swe.quest/sources.md) · [Topic map](https://swe.quest/map.md) · [Site guide (llms.txt)](https://swe.quest/llms.txt)
