All Questions
Ai Coding And Product Systems hard

Your completion backend receives about 15 requests per second from each actively typing user, GPUs are saturated, and over 90% of generated suggestions are never displayed because the user kept typing. What change fixes this while keeping the latency target?

  1. A Batch each user's keystroke requests into one larger request every 2 seconds to maximize GPU batching efficiency and throughput.
  2. B Scale the GPU fleet behind a least-connections load balancer, since discarded completions are an unavoidable cost of the feature.
  3. C Debounce briefly on the client, cancel in-flight requests on new keystrokes, and reuse a suggestion the user is typing through.
  4. D Cache completions keyed on a hash of the full file content so identical files return instantly regardless of cursor position.

One system design question a day, with spaced repetition so the ones you miss come back.

Get the app

Related questions