Model comparison

GLM-5 vs Llama 3.1-8B

GLM-5 is the stronger model overall, scoring 46.1 to 23.0 on the Noometry Index. Llama 3.1-8B costs 27× less per token, which makes it the better buy when GLM-5's lead doesn't matter for your workload.

Last verified . 23 shared benchmarks.

GLM-5 Z.ai (Zhipu)

46.1

Rank #66 Confirmed

Llama 3.1-8B Meta

23.0

Rank #352 Confirmed

Summary

  • They share 23 benchmarks with published results for both. GLM-5 scores higher in 9 categories and Llama 3.1-8B in 0 categories; 9 gaps are clear of the uncertainty.
  • The widest gap is in knowledge, where GLM-5 leads 52.3 to 8.0.
  • The biggest single-benchmark swing is OTIS Mock AIME 2024-2025: 80% for GLM-5 and 1.7% for Llama 3.1-8B.
  • Llama 3.1-8B is cheaper at $0.05 / $0.08 per million input/output tokens, against $1 / $3.20 for GLM-5.
  • GLM-5 accepts more context: 205K tokens versus 128K.

Side by side

GLM-5 and Llama 3.1-8B specifications
GLM-5Llama 3.1-8B
ProviderZ.ai (Zhipu)Meta
Noometry Index46.123.0
Released2026-02-112024-07-23
WeightsOpenOpen
Context window205K128K
Max output131K4K
Input $ / M tokens$1$0.05
Output $ / M tokens$3.20$0.08
Results tracked4543

Sponsored placements are available on pages like this one. Advertise on Noometry

Category by category

Coding GLM-5 leads

GLM-5: 49.0 (#52), Llama 3.1-8B: 20.2 (#340)

Coding benchmarks
BenchmarkGLM-5Llama 3.1-8B
WeirdML48.2%1.7%
LMArena Coding14611195
SWE-bench Verified72.1%—
SWE-bench Verified (bash only)72.8%—
LMArena WebDev1434—
SWE-bench Multilingual69.7%—
SciCode—13.2%
BigCodeBench Instruct—32.8%
BigCodeBench Complete—40.5%
ALE-Bench765.62—
HumanEval+—62.8%
MBPP+—55.6%

Agentic & Tool Use GLM-5 leads

GLM-5: 31.1 (#71), Llama 3.1-8B: 22.5 (#131)

Agentic & Tool Use benchmarks
BenchmarkGLM-5Llama 3.1-8B
Terminal-Bench52.4%—
Berkeley Function Calling Leaderboard—25.8%
τ²-bench Airline82.5%—
τ²-bench Banking9.8%—
τ²-bench Retail73.7%—
τ²-bench Telecom86.8%—
BALROG—15.1%
Vending-Bench 24,432—

Reasoning GLM-5 leads

GLM-5: 27.6 (#116), Llama 3.1-8B: 14.9 (#321)

Reasoning benchmarks
BenchmarkGLM-5Llama 3.1-8B
Chess Puzzles10%0%
LMArena Hard Prompts14521175
Epoch Capabilities Index145.83116.57
ARC-AGI-24.9%—
SimpleBench53.2%—
Kagi LLM Benchmark75%—
NYT Connections (extended)74.8%—
ARC-AGI-144.7%—
CritPt—0%
DTBench—50.9%
LMCA—5.4%
ForecastBench61—
PIQA—81.2%

Math GLM-5 leads

GLM-5: 46.4 (#71), Llama 3.1-8B: 10.2 (#317)

Math benchmarks
BenchmarkGLM-5Llama 3.1-8B
OTIS Mock AIME 2024-202580%1.7%
LMArena Math14401179
MathArena Final-Answer Competitions65.7%—
Omni-MATH—13.7%
MATH Level 5—22.9%
FrontierMath (Feb 2025 set)16.4%—
FrontierMath Tier 4 (v1)2.1%—
GSM8K—82.4%

Knowledge GLM-5 leads

GLM-5: 52.3 (#64), Llama 3.1-8B: 8.0 (#307)

Knowledge benchmarks
BenchmarkGLM-5Llama 3.1-8B
GPQA Diamond87.8%27%
LMArena Expert14541144
MMLU-Pro—40.6%
Vectara Hallucination Rate10.1%—
GPQA (HELM)—24.7%
BoolQ—82.8%
MMLU—56.1%

Multilingual GLM-5 leads

GLM-5: 53.7 (#58), Llama 3.1-8B: 34.0 (#249)

Multilingual benchmarks
BenchmarkGLM-5Llama 3.1-8B
LMArena Non-English14301148
LMArena Chinese15111151
LMArena French14551177
LMArena German14451144
LMArena Japanese14161061
LMArena Korean14231053
LMArena Russian14361158
LMArena Spanish14541169

Instruction Following GLM-5 leads

GLM-5: 75.2 (#67), Llama 3.1-8B: 58.9 (#258)

Instruction Following benchmarks
BenchmarkGLM-5Llama 3.1-8B
LMArena Instruction Following14281159
IFEval—74.3%

Long Context GLM-5 leads

GLM-5: 44.7 (#60), Llama 3.1-8B: 35.8 (#238)

Long Context benchmarks
BenchmarkGLM-5Llama 3.1-8B
LMArena Longer Query14461182
CL-bench18.7%—

Writing & Preference GLM-5 leads

GLM-5: 66.0 (#38), Llama 3.1-8B: 29.7 (#290)

Writing & Preference benchmarks
BenchmarkGLM-5Llama 3.1-8B
LMArena Text14461187
LMArena Creative Writing14391154
EQ-Bench Creative Writing1601713
LMArena Multi-Turn14561172
WildBench—68.7%

Frequently asked questions

Is GLM-5 better than Llama 3.1-8B?

GLM-5 is the stronger model overall, scoring 46.1 to 23.0 on the Noometry Index. Llama 3.1-8B costs 27× less per token, which makes it the better buy when GLM-5's lead doesn't matter for your workload.

Which is cheaper, GLM-5 or Llama 3.1-8B?

Llama 3.1-8B is cheaper. It lists at $0.05 per million input tokens and $0.08 per million output tokens; GLM-5 lists at $1 and $3.20.

Is GLM-5 or Llama 3.1-8B better for coding?

GLM-5 scores higher on coding benchmarks: 49.0 versus 20.2 in the Noometry coding category.

Which has the bigger context window?

GLM-5 does, with 205K tokens against 128K.

How many benchmarks do GLM-5 and Llama 3.1-8B share?

23 benchmarks have published results for both models. GLM-5 has 45 scored results on Noometry and Llama 3.1-8B has 43.

Related comparisons

Go deeper