PrepCity

AI-powered search: rewrite the query, re-rank the results

Open the lab

By the last page, this is the design you will have built.

Lesson · 7 pages · about 6 min

AI-powered search: rewrite the query, re-rank the results

Customers type short, misspelt questions in their own words. Fix and widen the query before searching, merge the results, then let a slower, smarter model re-order only the top few. That funnel is what “AI-powered search” usually means.

Words you’ll learn

  • BM25
  • Language model
  • RAG
  • Hybrid RAG
  • Reciprocal rank fusion
  • RAG-Fusion
  • Re-ranker
  • HyDE
  • Step-back prompting
  • Late interaction

Page by page