BM25 Best Match 25
Classic lexical search ranking algorithm — TF-IDF with saturation and length normalisation. The standard in Elasticsearch, Lucene, Postgres FTS.
Developed in the 1980s by Stephen Robertson et al. (the Okapi project at City, University of London). "Probabilistic relevance framework". Saturates term frequency so 100 occurrences of "the" don't weigh 100× more than 10. Normalises for document length. Despite its age, BM25 is often comparable to or better than naive vector search for specific domains (code, legal, medical with exact terms). Hybrid search (BM25 + vector + reranker) is best practice in modern RAG systems.