20/26
Part 4 of 4 · Prefill, decode and memoryLearn and do

How many requests fit

The cache's size decides how many requests fit on one GPU. Take one GPU with 80 GiB and sequences of 8,192 tokens: the weights take about 15 GiB, which leaves about 65 GiB for the cache, if you ignore activations and overhead. With 8 key/value heads, each sequence needs 1 GiB, so 65 fit.

Predict

Give each of the 32 query heads its own key and value, as plain multi-head attention does. How many 8K sequences fit in the 65 GiB now?

Pick an answer above to see the rest