Loading page…
One strong interview answer to "design typeahead search": two systems in one, an online path that does a single in-memory lookup from a replicated 10 GB snapshot, and an offline path that ranks queries by decayed popularity and hourly trends, filters them, and precomputes the top ten for every prefix; plus the client tricks, the CDN, and how to ship a snapshot safely.
Type s y s into a search box, and ten suggestions appear before your finger reaches the next key.