Compare
Llama 3.1 8B vs Qwen3 8B
Qwen3 8B has 8.19B parameters and Llama 3.1 8B 8.03B, about the same. In BF16 the weights take 16.1 GB and 16.4 GB.
| Llama 3.1 8B | Qwen3 8B | Ratio | |
|---|---|---|---|
| Parameters | 8.03B 8,030,261,248 | 8.19B 8,190,735,360 | 1.02× |
| Active per token | all (dense) | all (dense) | 1.02× |
| Layers | 32 | 36 | 1.13× |
| Hidden size (d) | 4,096 | 4,096 | same |
| Attention | 32 heads, 8 KV heads × 128 | 32 heads, 8 KV heads × 128 | |
| FFN | SwiGLU, 14,336 | SwiGLU, 12,288 | |
| Vocabulary | 128,256 | 151,936 | 1.18× |
| Tied embeddings | no | no | |
| Max context | 128K | 40K | 0.31× |
| Weights, BF16 | 16.1 GB | 16.4 GB | 1.02× |
| Weights, 4-bit | 4.0 GB | 4.1 GB | 1.02× |
| KV cache per token (BF16) | 131.1 KB | 147.5 KB | 1.13× |
| KV cache at 32K tokens | 4.3 GB | 4.8 GB | 1.13× |
| FLOPs per token (4K context) | 18.2 GFLOPs | 18.8 GFLOPs | 1.03× |
The full workings: Llama 3.1 8B · Qwen3 8B · change the models