System Design
19. AI System Design and LLM InfrastructureAnimated
Continuous Batching
Add and remove requests from the batch every step.
The idea
Finished requests leave and new ones join immediately, keeping the GPU full.
Watch it work
Press play, pause, or step through. Some animations have settings you can change.
Continuous batching: every tick, each running request makes one token of progress.
- tick:
- 1
1/17
Continuous batching is how vLLM, TGI and TensorRT-LLM keep throughput high.
Step by step
- 1Run a decoding step for all requests
- 2Remove finished ones
- 3Insert waiting ones
- 4Repeat
Where it is used
LLM serving.
Watch out for
Scheduling complexity and memory limits.