Amazon SageMaker Inference now offers prefix-aware routing for model serving workloads. Under this routing strategy, incoming requests that share the same prompt prefix are directed to the same instance. This dispatch approach is designed specifically so the KV cache stays warm across queries.
The new routing method was evaluated in benchmarks on Llama 3.1 70B. During testing, the approach reduced P50 time-to-first-token by up to 77%. Furthermore, the benchmark demonstrated that KV cache hit rates increased from about 25% to over 80%.

