Skip to content

LLM Parameters Explained: What Billions of Parameters Mean (With Counts for Popular Models)

What does it actually mean when a model has 8 billion or 1 trillion parameters? A clear guide to LLM parameters: weights, biases and embeddings, where parameters live inside a transformer, the formula to count them with worked examples, a table of popular models, total vs active parameters in mixture-of-experts, memory requirements, and how parameters differ from tokens, hyperparameters and…

5 min read

LLM Parameters Explained — llm parameters

Short answer

LLM parameters are the numbers a large language model learns during training: the weights and biases that determine how it transforms input text into output. A model described as "8B" has about 8 billion of these numbers. Most parameters sit in the transformer's attention and feed-forward (MLP) layers, with the rest in embeddings. A dense transformer has roughly 12 × layers × hidden size² parameters, which gives about 175 billion for GPT-3. Each parameter needs 2 bytes in 16-bit precision or about 0.5 bytes at 4-bit, so an 8B model needs about 16 GB or 5 GB of memory. In mixture-of-experts models, only a fraction of parameters is active per token (for example, 37 billion of DeepSeek-V3's 671 billion). More parameters usually mean more capability, but training data, architecture and training methods matter just as much.

What is a parameter?

A neural network is a large mathematical function. Its parameters are the adjustable numbers inside it. During training, the model predicts the next token, measures its error, and nudges every parameter slightly to reduce that error using gradient descent and backpropagation. After trillions of tokens, the parameters encode grammar, facts, reasoning patterns and style.

TypeWhat it doesShare of parameters
WeightsMultipliers that set how strongly one value influences anotherAlmost all
BiasesConstant offsets added to outputs (many modern LLMs omit them)Tiny or zero
Embedding parametersVectors representing each token in the vocabularySmall to moderate share
Normalisation parametersScale values in layer normsTiny

Where parameters live in a transformer

ComponentWhat it containsApprox. parameters per layer (dense, hidden size *d*)
Attention (Q, K, V, O projections)Weights that decide which tokens attend to which~4*d*² (less with grouped-query attention)
Feed-forward network (MLP)Weights that transform each token's representation~8*d*² (standard 4× expansion)
Layer normsScale (and shift) values~2*d*
Token embeddings (once per model)One vector per vocabulary tokenvocabulary × *d*

See What is a transformer? and the attention mechanism simulator.

How to count parameters

Rule of thumb for a classic dense transformer:

parameters ≈ 12 × layers × d² + vocabulary × d

Worked example: GPT-3

  • 96 layers, hidden size *d* = 12,288, vocabulary ≈ 50,257
  • 12 × 96 × 12,288² ≈ 174 billion
  • Embeddings: 50,257 × 12,288 ≈ 0.6 billion
  • Total ≈ 175 billion, matching the published figure.

Worked example: an 8B Llama-style model

Modern models use SwiGLU MLPs (three matrices) and grouped-query attention:

PartCalculationParameters
Attention per layer (d = 4,096; KV dimension 1,024)4,096² × 2 + 4,096 × 1,024 × 2~42 million
MLP per layer (intermediate size 14,336)3 × 4,096 × 14,336~176 million
32 layers(42M + 176M) × 32~6.98 billion
Input and output embeddings (vocabulary 128,256, untied)2 × 128,256 × 4,096~1.05 billion
Total~8.0 billion

Notice that the MLP layers hold most of the parameters.

ModelYearTotal parametersActive per tokenType
GPT-220191.5 billion1.5BDense
GPT-32020175 billion175BDense
PaLM2022540 billion540BDense
Mixtral 8x7B202346.7 billion~12.9BMoE
Llama 3.1 405B2024405 billion405BDense
DeepSeek-V3 / R12024–25671 billion37BMoE
Qwen3-235B-A22B2025235 billion22BMoE
Llama 4 Maverick2025400 billion17BMoE
gpt-oss-120b2025117 billion5.1BMoE
gpt-oss-20b202521 billion3.6BMoE
Kimi K22025~1 trillion32BMoE
GPT-4, Claude, Gemini (frontier closed models)2023–UndisclosedUndisclosedReports and estimates vary widely

Parameter counts for closed models are not officially published; figures circulating online are estimates. See best open source LLMs to run locally.

Total vs active parameters (mixture of experts)

In a mixture-of-experts model, each layer has many "expert" MLPs, and a router sends each token to only a few of them.

Total parametersActive parameters
DeterminesMemory needed to store the modelCompute and speed per token
DeepSeek-V3 example671B (must all be loaded)37B (used per token)

This is why MoE models are fast for their size but still need lots of memory.

How much memory do parameters need?

PrecisionBytes per parameter8B model70B model405B model
FP32432 GB280 GB1.62 TB
BF16 / FP16216 GB140 GB810 GB
FP8 / INT818 GB70 GB405 GB
4-bit (Q4)~0.5–0.6~5 GB~40 GB~230 GB

Running a model also needs memory for the KV cache, and training needs roughly 16 bytes per parameter for weights, gradients and optimizer states. Use the VRAM calculator and see LLM quantization.

Parameters vs tokens vs hyperparameters vs settings

TermMeaningExample
ParametersLearned numbers inside the model"70B parameters"
Training tokensAmount of text the model learned from"Trained on 15 trillion tokens"
Context windowHow many tokens the model can read at once"128K context"; see context windows
HyperparametersChoices made before trainingLearning rate, number of layers, batch size
Inference settingsControls when generating textTemperature, top-p; see LLM temperature

Confusingly, settings like temperature are sometimes called "parameters" in API documentation, but they are not learned weights.

Do more parameters mean a better model?

Generally, yes, if other things are equal. Scaling laws show that loss falls predictably as parameters, data and compute grow together. But:

  • Data matters: DeepMind's Chinchilla (70B) outperformed the much larger Gopher (280B) by training on more tokens.
  • Training methods matter: instruction tuning, reinforcement learning and reasoning training add capability without more parameters.
  • Small models keep improving: today's 8B models often beat much older 70B+ models. See small language models.
  • Speed and cost scale with (active) parameters, so bigger isn't always practical.

Frequently asked questions

What does 7B or 70B mean in AI models?

The number of parameters: 7 billion or 70 billion learned weights.

Are parameters the same as neurons?

No. Neurons are computational units; parameters are the weights and biases connecting and adjusting them. A model has many more parameters than neurons.

How many parameters does GPT-4 have?

OpenAI has not disclosed it. Widely repeated figures are unconfirmed estimates.

How much VRAM do I need per billion parameters?

About 2 GB in 16-bit, 1 GB in 8-bit and roughly 0.55–0.6 GB at 4-bit, plus extra for context.

What is the difference between parameters and tokens?

Parameters are what the model learned (its size); tokens are pieces of text it reads and writes. See What are tokens in AI?

Sources and further reading

Think you understand it now? Prove it.

Solve real Tensor Core math in the TensorCore.si Challenge and earn a certificate with your name.

Take the challenge

Leave a Reply

Your email address will not be published. Required fields are marked *