Model comparison

Phi-3-medium-4k-instruct vs llama-3-youko-8b

These two publish different quantization sets; the table below has the exact sizes. At long context the gap widens: llama-3-youko-8b's KV cache at 32K is 1.6× smaller, which usually matters more than the difference in weights.

From the file· summed bytes, KV per layer

Side by side

Phi-3-medium-4k-instructllama-3-youko-8b
Parameters14.0B8.0B
Architecturephi3llama
Layers4032
Native context4,0968,192
Mixture of expertsnono
Quantizations published542
Smallest quantization2.75 GiB5.34 GiB
Q4_K_M7.98 GiB
Licencemitllama3

KV cache by context

the term that decides long-context viability
ContextPhi-3-medium-4k-instructllama-3-youko-8bRatio
4,0960.78 GiB0.50 GiB1.56×
8,1921.56 GiB1.00 GiB1.56×
16,3843.13 GiB2.00 GiB1.56×
32,7686.25 GiB4.00 GiB1.56×
65,53612.50 GiB8.00 GiB1.56×
131,07225.00 GiB16.00 GiB1.56×