[whatmodel.sh](../../README.md) / Qwen2-Math 7B Instruct # Qwen2-Math 7B Instruct Alibaba · released 2024-08 · 7.62B params · apache-2.0 **score 49.6** ±1.9 · #384 of 732 · from 3 benchmark results across 1 source · † no independently run results verified Score within the [LMArena (text)](https://whatmodel.sh/?set=lmarena-text&score=set) comparison set only. ## What it's good at ● marks Qwen2-Math 7B Instruct among every model on that task or test, worst to best.
task  vs the others         rank  counts  tests
math  ▁▁▃▅●▆▄█▄▂▁▁   #291 of 431     98%      3
math · #291 of 431 · 98% of its score Beats [Molmo 2 8B](molmo-2-8b.md), [DeepSeek-Coder-V2 Instruct (0724)](deepseek-coder-v2-0724.md), [Llama 3.1 70B Instruct](llama-3-1-70b.md) here, though they rank higher overall. Trails [DeepSeek R1 Distill Qwen 1.5B](deepseek-r1-distill-qwen-1-5b.md), [Gemma 7B (base)](gemma-7b-base.md), [Mistral 7B v0.1 (base)](mistral-7b-v0-1.md) here, though they rank lower overall.
test                               result  vs the others in its run  difficulty           counts  why
Minerva MATH (maker)                34.6%  ▃·····▃··█●▅ beats 5/8    hard · avg 34%          39%  at its level
GSM8K (maker)                       89.9%  ▄···█▄●·▄·▄█ beats 4/8    very easy · avg 92%     37%  sharp
MATH (subset unspecified) (maker)   75.1%  ▃····▃·▅·●·█ beats 4/8    easy · avg 74%          22%  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
Qwen (submitted / maker-reported)        3   98% ▇▇▇▇▇▇▇▇▇▇▇▇
prior: pull toward the middle                 2% ▇
weighted average                            = 49.6
## 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 Qwen2-Math 7B Instruct (Q4_K_M, needs ~4.7 GB, from [huggingface.co/lmstudio-community](https://huggingface.co/lmstudio-community/Qwen2-Math-7B-Instruct-GGUF/tree/1fabe24d352de22d2c4bfaaaf63acc454135b096)) ```sh llama cli -hf lmstudio-community/Qwen2-Math-7B-Instruct-GGUF:Q4_K_M ``` 3. Or start a local server and open the address it prints (http://localhost:9931) ```sh llama serve -hf lmstudio-community/Qwen2-Math-7B-Instruct-GGUF:Q4_K_M ``` Other versions: Q8_0 (~8.1 GB) `llama cli -hf lmstudio-community/Qwen2-Math-7B-Instruct-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 Qwen2-Math 7B Instruct (Q4_K_M, needs ~4.7 GB, from [huggingface.co/lmstudio-community](https://huggingface.co/lmstudio-community/Qwen2-Math-7B-Instruct-GGUF/tree/1fabe24d352de22d2c4bfaaaf63acc454135b096)) ```sh lms get https://huggingface.co/lmstudio-community/Qwen2-Math-7B-Instruct-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 (~8.1 GB) `lms get https://huggingface.co/lmstudio-community/Qwen2-Math-7B-Instruct-GGUF@Q8_0 -y` · 4bit (~4.3 GB, Mac only) `lms get https://huggingface.co/mlx-community/Qwen2-Math-7B-Instruct-4bit -y` · 8bit (~8.1 GB, Mac only) `lms get https://huggingface.co/mlx-community/Qwen2-Math-7B-Instruct-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 Qwen2-Math 7B Instruct (Q4_0, needs ~4.4 GB, from [ollama.com](https://ollama.com/library/qwen2-math/tags)) ```sh ollama run qwen2-math:7b ``` ### 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 Qwen2-Math 7B Instruct (4bit, needs ~4.3 GB, Mac only, from [huggingface.co/mlx-community](https://huggingface.co/mlx-community/Qwen2-Math-7B-Instruct-4bit/tree/edb2aa05a3e98b2436e71bd56b143a4cc7207310)) ```sh mlx_lm.chat --model mlx-community/Qwen2-Math-7B-Instruct-4bit ``` 3. Or start an OpenAI-compatible server at http://localhost:8080/v1 ```sh mlx_lm.server --model mlx-community/Qwen2-Math-7B-Instruct-4bit ``` Other versions: 8bit (~8.1 GB, Mac only) `mlx_lm.chat --model mlx-community/Qwen2-Math-7B-Instruct-8bit` Model repository and documentation: [huggingface.co/Qwen](https://huggingface.co/Qwen/Qwen2-Math-7B-Instruct) [interactive version](https://whatmodel.sh/model/qwen2-math-7b) · [JSON](https://whatmodel.sh/api?format=json&all=1)