Compare
Mixtral 8x7B vs Llama 3.1 70B
Llama 3.1 70B has 70.6B parameters, 1.5 times the 46.7B of Mixtral 8x7B. In BF16 the weights take 93.4 GB and 141 GB. Llama 3.1 70B needs 2.5 times as much KV cache per token (327.7 KB against 131.1 KB): GQA against GQA.
| Mixtral 8x7B | Llama 3.1 70B | Ratio | |
|---|---|---|---|
| Parameters | 46.7B 46,702,792,704 | 70.6B 70,553,706,496 | 1.51× |
| Active per token | 12.9B | all (dense) | 5.48× |
| Layers | 32 | 80 | 2.50× |
| Hidden size (d) | 4,096 | 8,192 | 2.00× |
| Attention | 32 heads, 8 KV heads × 128 | 64 heads, 8 KV heads × 128 | |
| FFN | 8 experts × 14,336, top 2 | SwiGLU, 28,672 | |
| Vocabulary | 32,000 | 128,256 | 4.01× |
| Tied embeddings | no | no | |
| Max context | 32K | 128K | 4.00× |
| Weights, BF16 | 93.4 GB | 141 GB | 1.51× |
| Weights, 4-bit | 23.4 GB | 35.3 GB | 1.51× |
| KV cache per token (BF16) | 131.1 KB | 327.7 KB | 2.50× |
| KV cache at 32K tokens | 4.3 GB | 10.7 GB | 2.50× |
| FLOPs per token (4K context) | 27.9 GFLOPs | 151.8 GFLOPs | 5.44× |
The full workings: Mixtral 8x7B · Llama 3.1 70B · change the models