← Back to AlgoVision SD hub Override

Design search autocomplete

Typeahead for web or app search: prefix matching, ranking, and extreme read QPS with tight latency budgets.

~22 minDesign interview
Ready
Step 0 / 0
Interview script (outline)
  1. Clarify: scope (web docs vs global query log), languages, offensive filtering, personalization level.
  2. Estimate: keystroke rate, suggestions per keystroke, p99 latency target (often <100ms).
  3. Data structure: trie / prefix tree / FST; optional n-gram index for fuzzy.
  4. Ranking: popularity, previous clicks, freshness; A/B bucket.
  5. Serving: cache hot prefixes at edge; debounce client; collapse duplicate requests.
  6. Update path: batch index build + streaming updates for fresh queries.
← Chat service Next: URL shortener →