Enter opens the highlighted result. Esc closes.

GPT-4.1 Mini vs Llama 3.1 8B Instruct

GPT-4.1 Mini leads Llama 3.1 8B Instruct on the Artificial Analysis Intelligence Index, 10.2 to 6.9, and Llama 3.1 8B Instruct costs 20.0x less per output token ($0.08 vs $1.60 per million). Updated October 22, 2026; 47 benchmarks have a result for both.

GPT-4.1 MiniOpenAI
Coding
No data
Overall
31.9
Output $/M
$1.60
46
Llama 3.1 8B InstructMeta Llama
Coding
No data
Overall
17.9
Output $/M
$0.08
1
vs boards won of 47 shared

GPT-4.1 Mini or Llama 3.1 8B Instruct: which to pick

Neither model has a coding score yet, so the two cannot be ranked on coding.

Pick GPT-4.1 Mini for a larger context window (1.05M against 131K tokens) and work measured by Humanity's Last Exam (Artificial Analysis run), where it leads.

Shared results
47
GPT-4.1 Mini only
39
Llama 3.1 8B Instruct only
4
Like-for-like categories
7 of 9

Only benchmarks that tested both models count toward a pick; a result only one model has is shown but not compared.

Which one for your work

Each card is decided by one number both models carry. Where only one has it, the card says so and makes no call.

At a glance

Coding index
GPT-4.1 Mini not benchmarked, Llama 3.1 8B Instruct not benchmarked.
Widest category
Math, 41.1 points apart on average over 6 shared benchmarks.
Widest single gap
MATH level 5: GPT-4.1 Mini 87.3% against Llama 3.1 8B Instruct 22.9%, 64.4 points apart on a 0 to 100 scale.
Output price
GPT-4.1 Mini $1.60 against Llama 3.1 8B Instruct $0.08 per million output tokens, 20.0x apart.
Context window
GPT-4.1 Mini takes 1.05M tokens, Llama 3.1 8B Instruct 131K.

Benchmark by benchmark

First the score: boards each model leads, per category, where both have a result. Then every board, a category to a fold; bars are each result on a 0 to 100 scale, so compare the two in a row, not one row with another.

Boards won, where both have a result
CategoryGPT-4.1 MiniBarsLlama 3.1 8B InstructTies
Coding60
Intelligence20
Agentic work20
Reasoning51
Math60
Knowledge50
General200
All shared boards461
CodingLike-for-likeSix of these boards feed the Vibe Coding Index60
Coding benchmarks for GPT-4.1 Mini and Llama 3.1 8B Instruct
BenchmarkGPT-4.1 MiniLlama 3.1 8B InstructLeader
Aider polyglot32.4%Not measuredOnly GPT-4.1 Mini measured
SWE-bench Verified23.9%Not measuredOnly GPT-4.1 Mini measured
AA Coding Index20.25.4GPT-4.1 Mini
LiveCodeBench (Vals AI)58.2%Not measuredOnly GPT-4.1 Mini measured
LiveCodeBench (Artificial Analysis run)48.3%11.6%GPT-4.1 Mini
Terminal-Bench Hard (Artificial Analysis run)7.6%0.8%GPT-4.1 Mini
WeirdML37.6%1.7%GPT-4.1 Mini
LMArena Text: coding13671195GPT-4.1 Mini
LMArena Text: software and IT13601195GPT-4.1 Mini
Neither model has a result on the other 30 boards here
IntelligenceLike-for-likePublic boards, shown as published, kept out of the index20
Intelligence benchmarks for GPT-4.1 Mini and Llama 3.1 8B Instruct
BenchmarkGPT-4.1 MiniLlama 3.1 8B InstructLeader
AA Intelligence Index10.26.9GPT-4.1 Mini
Epoch Capabilities Index134.9116.5GPT-4.1 Mini
Agentic workLike-for-likePublic boards, shown as published, kept out of the index20
Agentic work benchmarks for GPT-4.1 Mini and Llama 3.1 8B Instruct
BenchmarkGPT-4.1 MiniLlama 3.1 8B InstructLeader
τ²-Bench Telecom52.9%16.4%GPT-4.1 Mini
BALROGNot measured15.1%Only Llama 3.1 8B Instruct measured
Berkeley Function Calling Leaderboard (BFCL)50.4%25.8%GPT-4.1 Mini
Neither model has a result on the other 38 boards here
ReasoningLike-for-likePublic boards, shown as published, kept out of the index51
Reasoning benchmarks for GPT-4.1 Mini and Llama 3.1 8B Instruct
BenchmarkGPT-4.1 MiniLlama 3.1 8B InstructLeader
GPQA Diamond67.9%Not measuredOnly GPT-4.1 Mini measured
MMMU Pro (Vals AI)70.5%Not measuredOnly GPT-4.1 Mini measured
GPQA Diamond (Artificial Analysis run)66.4%25.9%GPT-4.1 Mini
Humanity's Last Exam (Artificial Analysis run)5.0%5.3%Llama 3.1 8B Instruct
GPQA Diamond (Epoch AI run)65.8%27.0%GPT-4.1 Mini
ARC-AGI3.5%Not measuredOnly GPT-4.1 Mini measured
ARC-AGI-20.0%Not measuredOnly GPT-4.1 Mini measured
Chess puzzles1.0%Not measuredOnly GPT-4.1 Mini measured
Mystery game puzzles7.0%Not measuredOnly GPT-4.1 Mini measured
LMArena Text: hard prompts13491175GPT-4.1 Mini
LMArena Text: expert13381144GPT-4.1 Mini
LMArena Text: hard prompts in English13621196GPT-4.1 Mini
LMArena Vision: diagrams1182Not measuredOnly GPT-4.1 Mini measured
LMArena Vision: homework1214Not measuredOnly GPT-4.1 Mini measured
Kagi LLM Benchmark48.6%Not measuredOnly GPT-4.1 Mini measured
Neither model has a result on the other 7 boards here
MathLike-for-likePublic boards, shown as published, kept out of the index60
Math benchmarks for GPT-4.1 Mini and Llama 3.1 8B Instruct
BenchmarkGPT-4.1 MiniLlama 3.1 8B InstructLeader
AIME49.4%Not measuredOnly GPT-4.1 Mini measured
MATH 500 (Vals AI)88.0%Not measuredOnly GPT-4.1 Mini measured
MGSM (Vals AI)87.8%Not measuredOnly GPT-4.1 Mini measured
AA Math Index46.34.3GPT-4.1 Mini
AIME 2025 (Artificial Analysis run)46.3%4.3%GPT-4.1 Mini
OTIS Mock AIME44.7%1.7%GPT-4.1 Mini
FrontierMath, tiers 1 to 36.7%Not measuredOnly GPT-4.1 Mini measured
MATH level 587.3%22.9%GPT-4.1 Mini
GSM8KNot measured82.4%Only Llama 3.1 8B Instruct measured
LMArena Text: math13431179GPT-4.1 Mini
LMArena Text: mathematical work13471180GPT-4.1 Mini
Neither model has a result on the other 2 boards here
KnowledgeLike-for-likePublic boards, shown as published, kept out of the index50
Knowledge benchmarks for GPT-4.1 Mini and Llama 3.1 8B Instruct
BenchmarkGPT-4.1 MiniLlama 3.1 8B InstructLeader
MMLU Pro77.2%Not measuredOnly GPT-4.1 Mini measured
LegalBench (Vals AI)78.0%Not measuredOnly GPT-4.1 Mini measured
CorpFin (Vals AI)57.9%Not measuredOnly GPT-4.1 Mini measured
TaxEval (Vals AI)71.9%Not measuredOnly GPT-4.1 Mini measured
MortgageTax (Vals AI)65.5%Not measuredOnly GPT-4.1 Mini measured
MedQA (Vals AI)84.6%Not measuredOnly GPT-4.1 Mini measured
MMLU Pro (Artificial Analysis run)78.1%47.6%GPT-4.1 Mini
SimpleQA Verified12.7%Not measuredOnly GPT-4.1 Mini measured
MMLUNot measured56.1%Only Llama 3.1 8B Instruct measured
LMArena Text: science13281193GPT-4.1 Mini
LMArena Text: medicine and healthcare13241182GPT-4.1 Mini
LMArena Text: legal and government13431206GPT-4.1 Mini
LMArena Text: business and finance13221166GPT-4.1 Mini
Neither model has a result on the other 5 boards here
Web designDirectional onlyPublic boards, shown as published, kept out of the index6 boards, none shared
Web design benchmarks for GPT-4.1 Mini and Llama 3.1 8B Instruct
BenchmarkGPT-4.1 MiniLlama 3.1 8B InstructLeader
Design Arena: websites997Not measuredOnly GPT-4.1 Mini measured
Design Arena: UI components958Not measuredOnly GPT-4.1 Mini measured
Design Arena: game dev1070Not measuredOnly GPT-4.1 Mini measured
Design Arena: data viz1034Not measuredOnly GPT-4.1 Mini measured
Design Arena: 3D836Not measuredOnly GPT-4.1 Mini measured
Design Arena: all code categories993Not measuredOnly GPT-4.1 Mini measured
Neither model has a result on the other 3 boards here
GeneralLike-for-likePublic boards, shown as published, kept out of the index200
General benchmarks for GPT-4.1 Mini and Llama 3.1 8B Instruct
BenchmarkGPT-4.1 MiniLlama 3.1 8B InstructLeader
IFBench38.3%28.6%GPT-4.1 Mini
Long context reasoning (AA-LCR)44.0%18.0%GPT-4.1 Mini
DTBench68.8%50.9%GPT-4.1 Mini
LMCA21.1%5.4%GPT-4.1 Mini
Fiction.LiveBench44.4%Not measuredOnly GPT-4.1 Mini measured
PIQANot measured81.2%Only Llama 3.1 8B Instruct measured
LMArena Text13411187GPT-4.1 Mini
LMArena Text: instruction following13331159GPT-4.1 Mini
LMArena Text: creative writing12991154GPT-4.1 Mini
LMArena Vision1181Not measuredOnly GPT-4.1 Mini measured
LMArena Text: English13561218GPT-4.1 Mini
LMArena Text: non-English13181148GPT-4.1 Mini
LMArena Text: Chinese13291151GPT-4.1 Mini
LMArena Text: German13501144GPT-4.1 Mini
LMArena Text: Japanese12901061GPT-4.1 Mini
LMArena Text: Korean12981053GPT-4.1 Mini
LMArena Text: French13581178GPT-4.1 Mini
LMArena Text: Spanish13191169GPT-4.1 Mini
LMArena Text: Russian13241158GPT-4.1 Mini
LMArena Text: Polish1326Not measuredOnly GPT-4.1 Mini measured
LMArena Text: multi-turn13541172GPT-4.1 Mini
LMArena Text: longer queries13441181GPT-4.1 Mini
LMArena Text: writing and language13191162GPT-4.1 Mini
LMArena Text: entertainment and media13001145GPT-4.1 Mini
LMArena Vision: English1191Not measuredOnly GPT-4.1 Mini measured
LMArena Vision: Chinese1186Not measuredOnly GPT-4.1 Mini measured
LMArena Vision: reading text1188Not measuredOnly GPT-4.1 Mini measured
LMArena Vision: humor1182Not measuredOnly GPT-4.1 Mini measured
LMArena Vision: captioning1174Not measuredOnly GPT-4.1 Mini measured
LMArena Vision: recognizing things1187Not measuredOnly GPT-4.1 Mini measured
LMArena Vision: creative writing1182Not measuredOnly GPT-4.1 Mini measured
Neither model has a result on the other 15 boards here
Image generationNot comparablePublic boards, shown as published, kept out of the index0 boards, none shared
Image generation benchmarks for GPT-4.1 Mini and Llama 3.1 8B Instruct
BenchmarkGPT-4.1 MiniLlama 3.1 8B InstructLeader
Neither model has a result on 5 boards here

What each workload costs

Three fixed token mixes at each model's listed price, so per-token rates become a bill.

Chat turn

1K input + 500 output tokens

GPT-4.1 Mini$0.0012Fits in one request
Llama 3.1 8B Instruct$0.0001Fits in one request

Llama 3.1 8B Instruct costs less

Repository review

50K input + 3K output tokens

GPT-4.1 Mini$0.025Fits in one request
Llama 3.1 8B Instruct$0.0027Fits in one request

Llama 3.1 8B Instruct costs less

Agent loop

200K input + 10K output tokens

GPT-4.1 Mini$0.096Fits in one request
Llama 3.1 8B Instruct$0.011Exceeds the context window

Llama 3.1 8B Instruct costs less

Listed OpenRouter rates, without cache or batch discounts. A workload that does not fit a model's context window would need splitting.

Specification differences

The leading value in a row is marked; a row with a missing value names no leader. Our two rows are marked in red.

Specifications of GPT-4.1 Mini and Llama 3.1 8B Instruct
SpecificationOpenAI GPT-4.1 MiniMeta Llama 3.1 8B Instruct
MakerOpenAIMeta Llama
WeightsNo public weights listedOpen weights
ReleasedApril 14, 2025July 23, 2024
Context window1.05M131K
Input $/Mtok$0.40$0.05
Output $/Mtok$1.60$0.08
Coding indexNot benchmarkedNot benchmarked
Independent measurements behind it00
Cost per solved task$1.818Not computable
SourceOpenRouter listingOpenRouter listing

Questions

Is GPT-4.1 Mini better than Llama 3.1 8B Instruct for coding?

Neither model has a coding score yet, so the two cannot be ranked on coding. Pick GPT-4.1 Mini for a larger context window (1.05M against 131K tokens) and work measured by Humanity's Last Exam (Artificial Analysis run), where it leads.

Which is cheaper, GPT-4.1 Mini or Llama 3.1 8B Instruct?

GPT-4.1 Mini costs $0.40 per million input tokens and $1.60 per million output tokens; Llama 3.1 8B Instruct costs $0.05 and $0.08. Cost per solved task is known for GPT-4.1 Mini only.

Which has the bigger context window, GPT-4.1 Mini or Llama 3.1 8B Instruct?

GPT-4.1 Mini, with 1.05M tokens against 131K.

How many benchmarks is the GPT-4.1 Mini vs Llama 3.1 8B Instruct comparison based on?

47 benchmarks have a result for both models as of October 22, 2026. GPT-4.1 Mini's coding index rests on 0 independent benchmarks and Llama 3.1 8B Instruct's on 0. Where only one model has a result, the page says so instead of naming a winner.

Compare next