Все Новий

user:thomas gists створені користувачем

title:mygist gists з наданим ім'ям

description:sync gists with given description

filename:myfile.txt gists мають файли з наданим ім'ям

extension:yml gists мають файли з наданим розширенням

language:go gists мають файли з наданою мовою

topic:homelab gists with given topic

all:systemctl search all fields

Реєстрація

Увійти

Все Новий Реєстрація Увійти

linkjobai

Зареєстрован 21 hours ago

Нещодавні зверху створені
Нещодавні знизу створені
Нещодавні зверху оновлені
Нещодавні знизу оновлені
Всі gist 1

linkjobai / System Design: Search Autocomplete (Typeahead)

0 вподобань
0 форк(-ів)
1 файл(-ів)
Остання активність 21 hours ago
Interview prep notes
interview

System Design: Search Autocomplete (Typeahead)

Designing autocomplete, like the search box suggestions on Google or Amazon, is a popular interview question because it combines a classic data structure (the trie) with real latency constraints.

Requirements

  • Return the top 5 to 10 suggestions for a prefix as the user types.
  • Latency under about 100 ms end to end, so each lookup must be a few milliseconds.
  • Suggestions ranked by popularity, with some freshness (trending queries).
  • Scale example: 10M daily users, about 10 keystrokes per search.
Новіше Пізніше

Працює на Opengist ⋅ Load: 10ms⋅

Українська
Čeština Deutsch English Español Français Magyar Italiano 日本語 Polski Português Русский Türkçe Українська 中文 繁體中文