[whatmodel.sh](../../README.md) / GPT-2 Small (124M) # GPT-2 Small (124M) OpenAI · released 2019-02 · 0.124B params · mit **score -13.0** ±1.5 · #731 of 732 · from 35 benchmark results across 9 sources Score within the [LMArena (text)](https://whatmodel.sh/?set=lmarena-text&score=set) comparison set only. ## What it's good at ● marks GPT-2 Small (124M) among every model on that task or test, worst to best.
task vs the others rank counts tests math ●▁▃▅█▆▄█▄▂▁▁ #429 of 431* 0.1% 1
test result vs the others in its run difficulty counts why GSM8K 0.4% ●·▂█·······▂ beats 2/9 medium · avg 62% 0.1% sharp · too hard for it · noisy
test result vs the others in its run difficulty counts why OpenBookQA 16.4% ●▁▁▁▂▂▃█▃▁▃▁ beats 13/107 very hard · avg 26% 25% too hard for it · several runs ARC Challenge 20.1% ●▁▁▂▁▄█▇▃▂▃▂ beats 5/140 very hard · avg 27% 18% sharp · too hard for it · several runs COPA 61.0% ▁·▁▁●▅▅█▆▂▁▁ beats 5/67 very easy · avg 97% 14% several runs ARC Easy 42.9% ▁●▂▄▆█▅▃▁··▁ beats 6/100 very easy · avg 90% 10% blunt · several runs Story Cloze Test 60.0% ●▃▃▂▅█▅▂▁··▂ beats 3/50 easy · avg 91% 10% blunt · several runs HellaSwag 28.6% ●▁▁▂▂▂▄▆█▇▄▂ beats 1/135 easy · avg 87% 8.8% too hard for it · several runs PROST physical reasoning (zero-sh… 23.6% ●···██·█···█ beats 0/4 easy · avg 86% 3.3% too hard for it COPEN concept identification in c… 31.1% ▃···●▃·▃·▃·█ beats 1/7 easy · avg 81% 3.0% too hard for it Social IQA 39.7% ▁·▁●█▄▅▁▂▃▇▁ beats 3/59 medium · avg 71% 2.3% blunt · too hard for it PIQA 62.9% ▁●▁▂▂▃▅█▅▃▁▁ beats 2/123 easy · avg 89% 2.2% blunt BoolQ 49.4% ●····▁▂█▆▅▆▄ beats 0/103 easy · avg 91% 1.4% too hard for it · noisy COPEN conceptual similarity judgm… 7.9% ▄···●···██·▄ beats 2/7 hard · avg 22% 0.5% blunt · too hard for it StrategyQA 0.0% ●········▁▃▁ beats 2/9 hard · avg 62% 0.3% too hard for it · noisy SVAMP 0.3% ●·▆▂▄▂▂····▂ beats 2/12 easy · avg 70% 0.2% sharp · too hard for it Open PT-LLM Leaderboard average (… 23.3% ●▁▁▁▁▁▁▁▂█▅▁ beats 0/276 medium · avg 72% 0.1% too hard for it · noisy CommonsenseQA 20.2% ●····▁·····▁ beats 2/9 easy · avg 75% 0.1% sharp · too hard for it · several runs EuroEval Life in the UK (English … 22.8% ●▁▁▁▁▁▁▂▄█▄▃ beats 0/146 easy · avg 82% 0.1% too hard for it · noisy TruthfulQA generation, % true (hu… 35.4% ██····●·██·█ beats 2/5 medium · avg 42% 0.1% blunt · at its level COPEN conceptual property judgmen… 51.5% █·······●··▁ beats 6/7 very hard · avg 52% 0.0% blunt · too hard for it · noisy EuroEval HellaSwag (English), tes… 24.7% ●·▁▁▂▁▂▅█▇▄▁ beats 4/100 medium · avg 67% 0.0% sharp · too hard for it · noisy AQuA-RAT 17.3% ●·····▁·▁··▁ beats 2/9 medium · avg 53% 0.0% sharp · too hard for it · noisy
source results share of the score Coherence boosting: When your pretraine… 9 41% ▇▇▇▇▇ Surface Form Competition 7 26% ▇▇▇ CASE: Commonsense-Augmented Score with … 6 24% ▇▇▇ COPEN 3 4% ▇ PROST 1 3% ▇ Large Language Models Are Reasoning Tea… 5 1% ▇ Open Portuguese LLM Leaderboard 1 0% ▇ EuroEval leaderboards 2 0% ▇ TruthfulQA: Measuring How Models Mimic … 1 0% ▇ prior: pull toward the middle 1% ▇ weighted average = -13.0Licences: Coherence boosting: When your pretrained language model is not paying enough attention ([CC BY 4.0](../../licenses/acl-2022-acl-long-565-CC-BY-4-0.txt)) · Surface Form Competition ([CC BY 4.0](../../licenses/acl-2021-emnlp-main-564-CC-BY-4.0.txt)) · CASE: Commonsense-Augmented Score with an Expanded Answer Space ([CC BY 4.0](../../licenses/acl-2023-findings-emnlp-180-CC-BY-4-0.txt)) · COPEN ([CC BY 4.0](../../licenses/copen-emnlp2022-zero-shot-CC-BY-4.0.txt)) · PROST ([CC BY 4.0](../../licenses/_cc-by-4.0-legalcode.txt)) · Large Language Models Are Reasoning Teachers ([CC BY 4.0](../../licenses/acl-2023-acl-long-830-CC-BY-4-0.txt)) · Open Portuguese LLM Leaderboard ([Apache-2.0](../../licenses/hf-leaderboard-spaces-Apache-2.0.txt)) · EuroEval leaderboards ([MIT](https://github.com/EuroEval/leaderboards/blob/1a77f1d2f8ba1ba05ab73287fb090d76bf41b2e0/LICENSE)) · TruthfulQA: Measuring How Models Mimic Human Falsehoods ([CC BY 4.0](../../licenses/acl-2022-acl-long-229-CC-BY-4-0.txt)) ## 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 GPT-2 Small (124M) (Q4_K_M, needs ~0.1 GB, from [huggingface.co/mradermacher](https://huggingface.co/mradermacher/gpt2-GGUF/tree/0cda0c2b1459ccd32256c6ddde9d230934112c1c)) ```sh llama cli -hf mradermacher/gpt2-GGUF:Q4_K_M ``` 3. Or start a local server and open the address it prints (http://localhost:9931) ```sh llama serve -hf mradermacher/gpt2-GGUF:Q4_K_M ``` Other versions: Q8_0 (~0.2 GB) `llama cli -hf mradermacher/gpt2-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 GPT-2 Small (124M) (Q4_K_M, needs ~0.1 GB, from [huggingface.co/mradermacher](https://huggingface.co/mradermacher/gpt2-GGUF/tree/0cda0c2b1459ccd32256c6ddde9d230934112c1c)) ```sh lms get https://huggingface.co/mradermacher/gpt2-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 (~0.2 GB) `lms get https://huggingface.co/mradermacher/gpt2-GGUF@Q8_0 -y` · 4bit (~0.1 GB, Mac only) `lms get https://huggingface.co/jesusoctavioas/gpt2-mlx-4Bit -y` · 8bit (~0.1 GB, Mac only) `lms get https://huggingface.co/jesusoctavioas/gpt2-mlx-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 GPT-2 Small (124M) (Q4_K_M, needs ~0.1 GB, from [huggingface.co/mradermacher](https://huggingface.co/mradermacher/gpt2-GGUF/tree/0cda0c2b1459ccd32256c6ddde9d230934112c1c)) ```sh ollama run hf.co/mradermacher/gpt2-GGUF:Q4_K_M ``` Other versions: Q8_0 (~0.2 GB) `ollama run hf.co/mradermacher/gpt2-GGUF: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 GPT-2 Small (124M) (4bit, needs ~0.1 GB, Mac only, from [huggingface.co/jesusoctavioas](https://huggingface.co/jesusoctavioas/gpt2-mlx-4Bit/tree/46091c438e8c6f3443911dc2d56f81aae8ee72ff)) ```sh mlx_lm.chat --model jesusoctavioas/gpt2-mlx-4Bit ``` 3. Or start an OpenAI-compatible server at http://localhost:8080/v1 ```sh mlx_lm.server --model jesusoctavioas/gpt2-mlx-4Bit ``` Other versions: 8bit (~0.1 GB, Mac only) `mlx_lm.chat --model jesusoctavioas/gpt2-mlx-8Bit` ### Other ways to run it 1. Run it as published (fp32, needs ~0.55 GB, from [huggingface.co/openai-community](https://huggingface.co/openai-community/gpt2/tree/607a30d783dfa663caf39e06633721c8d4cfcd7e)) ```sh uv run --with torch --with 'transformers<5' python -c "from transformers import pipeline; print(pipeline('text-generation', model='openai-community/gpt2')('Once upon a time', max_new_tokens=40)[0]['generated_text'])" ``` Model repository and documentation: [huggingface.co/openai-community](https://huggingface.co/openai-community/gpt2) [interactive version](https://whatmodel.sh/model/gpt-2-small) · [JSON](https://whatmodel.sh/api?format=json&all=1)