All glossary terms

Serving

Replica autoscaling

Adding or removing identical inference servers based on a live signal such as queue depth. Right-sized capacity means no idle hardware and no growing queues.

A replica is one complete inference server: model loaded, cache ready, admitting requests. Autoscaling runs more replicas when demand rises and fewer when it falls, so capacity follows the traffic instead of paying for the year's peak all the time.

The signal is the first decision, and GPU compute gauges are a trap: decode is memory-bound, so a busy card can report low utilization while its queue grows. Queue depth, request wait above a target, or aggregate tokens per second against a replica's measured ceiling are the honest signals, because they are user-visible before the card is.

The second decision is the ramp. A new replica pays the cold start before it helps, so scaling reacts to a forecast window, not to the last second: the pool needs to have launched before the queue grows. The third is the reverse move, draining: remove replicas only after their in-flight replies finish, and keep a floor (for redundancy at the minimum size) because one overloaded replica is worse than one idling.

A worked example

Measurements show one replica sustains 3,000 aggregate tokens per second inside the latency SLO. Peak demand is 9,000 tokens per second. Cards rent at $2.50 per hour.

  1. Replicas for the peak: 9,000 / 3,000 = 3, which leaves zero headroom.
  2. One spare absorbs a deploy or a failure: 3 + 1 = 4 replicas.
  3. At $2.50 per hour: 4 x $2.50 = $10 per hour, versus $7.50 with no spare.
  4. When traffic halves to 4,500 tokens per second, capacity needs are 4,500 / 3,000 = 1.5, so 2 replicas carry the load and 2 can be released.

The spare replica is $2.50 an hour, which is cheap next to the outage a single failure causes at exactly 3 replicas; and the release side is where autoscaling actually pays for itself.

Where this shows up

Test yourself

Related terms