8/30
Part 2 of 7 · The memory budgetLearn and do

Longer conversations take more of the room

The cache grows with every token, so longer conversations take more of the room.

for context in (2000, 4000, 8000, 32000):
    fits = int(room_gb // (kv_per_token * context / 1e9))
    print(f"{context:6,} tokens each: {fits:3} sequences")
Predict

Customers start pasting order histories, and conversations grow from 2,000 tokens to 8,000. What happens to the 477?

Pick one to see what it prints.
Pick an answer above to see the rest