Debug a p99 latency spike in a streaming inference service

HardSystem design40 minSWEPro outline

The question

A token streaming service sits behind a load balancer, with a router in front of many GPU workers. After a routine deploy, median latency is unchanged but p99 time to first token went from 400 ms to 3 s. Error rates look normal.

Talk me through how you find the cause. Tell me what you look at, in what order, and what each result would tell you.

What the interviewer is looking for

  • Forms hypotheses before digging and tests the cheapest first
  • Uses the shape of the problem: p99 only, so a subset of requests or hosts
  • Splits the latency into stages: queueing, routing, prefill, network
  • Checks what changed in the deploy, including config and dependencies, not just code
  • Knows when to roll back first and debug after
  • Proposes a fix and a guard so it does not happen again

Your answer

Saved in this browser only. Nobody else sees it.

Why this question

Written by BlogLLM in the style of a publicly reported Cohere question type: Finding the root cause of a production issue in a distributed system.

Reported in: curebugs.com

Practice question written by BlogLLM based on publicly reported interview formats. Not an official Cohere question.