CourseAI System Design: The Complete Course · Module 3: Capacity and Cost Estimation · part 24 of 107
Part 24 · Module 3: Capacity and Cost Estimation

Lesson 5: Splitting three seconds across every hop

27 min read·
Module 3 · Lesson 5 · About 50 minutes · Needs: Lessons 1 and 2 (requests and tokens), and what a span in a trace is (Module 1). One short streamed call to Groq or Gemini at the end; everything else runs with no key.

The situation

Week 3 at Northdesk. Joel's target says every Ask answer arrives in 3 seconds. Funmi opens simulated trace ask-1073, lesson 2's example: a Marlow County Council employee's question on 29 September, 3,012 tokens in, 516 out. It took 14,117 ms. Joel asks which part to make faster. Helen wants the 3 seconds split across every hop on paper first. This is the latency part of the roadmap's worked estimate.

THE SITUATION 14 seconds against 3 ASK-1073, END TO END simulated trace decode past the target 3 s target hops 229 ms 14,117 ms 98% of the request is the model 14,117 ms end to end, target 3,000
Trace ask-1073 took 14,117 ms against a 3-second target (red line, over budget); the model (amber) took 98% of it.

The rest of this course is yours to keep

This course is bought on its own, once, and stays readable afterwards, including the parts added to it later.

Or open everything with a plan