P

Python

Python programming, data science, and scripting

PostgreSQL Hybrid Search Course – Keyword (BM25) + Vector Retrieval

Learn how to build a complete Wikipedia search engine entirely within PostgreSQL using BM25 keyword matching, vector embeddings, and reciprocal rank fusion. This step-by-step course covers setting up `pg_textsearch` and `pgvector-scale`, analyzing query plans, tuning hybrid weights, and serving resu...

Watch on YouTubeadded 21 October 2026

Key moments

  1. 0:00Introduction & Project Overview
  2. 4:06Matching vs. Ranking & PostgreSQL Text Search
  3. 7:20Understanding BM25 (IDF, Term Frequency, & Document Length)
  4. 11:39Setting Up Tiger Data Cloud & PostgreSQL
  5. 14:06Environment Setup & Enabling Database Extensions
  6. 15:43Loading Wikipedia Dataset & Schema Setup
  7. 20:30Native PostgreSQL Full-Text Search Baseline
  8. 24:38Analyzing Query Plans with EXPLAIN ANALYZE
  9. 27:40Implementing BM25 Keyword Search with pg_textsearch
  10. 32:32Building the Keyword Search Query & Highlighting (TS_HEADLINE)
  11. 36:18Boolean Conditions & Phrase Search
  12. 37:32Semantic Search Fundamentals & Generating Embeddings
  13. 41:33Vector Indexing with pgvector-scale
  14. 43:28Reciprocal Rank Fusion (RRF) for Hybrid Search
  15. 46:58Query Plan Analysis for Hybrid Search
  16. 49:12Comparing Keyword, Semantic, and Hybrid Results
  17. 52:13Connecting the FastAPI Backend & Connection Pooling
  18. 54:06Testing the Web Interface & Weight Tuning
  19. 55:23Adding New Records via Transactional Writes
  20. 57:24Scale Benchmarks & Next Steps for Optimization

Chapters by freeCodeCamp.org

Sign in to add a comment

Other Coverage

Related Videos

Did you find what you came for?