Jargonautica
Running It in Production

Continuous Batching

How a serving system keeps the hardware busy when requests arrive at random times and finish at different lengths. Instead of waiting for a whole batch to complete, it slots new requests in as others finish, which raises throughput dramatically.

Technical view

Also called in-flight batching. The scheduler admits and evicts sequences at each decoding step rather than at batch boundaries, avoiding the padding waste and head-of-line blocking of static batching. Paired with paged attention, which manages the key-value cache in non-contiguous blocks to avoid fragmentation, it is the main reason modern inference servers achieve several times the throughput of naive implementations.


Part of AI Terminology Index, section: Running It in Production.

How it connects

Continuous Batching links to 10 other terms. The faint lines are links between those terms. See it in the full graph.

InferenceInferenceCachingCachingLatency, Throughput and Time to First TokenLatency, Throughput…Memory BandwidthMemory BandwidthGrouped Query AttentionGrouped Query Atten…Paged AttentionPaged AttentionArithmetic IntensityArithmetic IntensityEarly ExitEarly ExitBatch InferenceBatch InferenceDeterminism and SeedDeterminism and SeedContinuous Batching