BM25
also: keyword search · lexical search
The classic keyword-ranking function — still the baseline every fancy retriever must beat.
BM25 scores documents by term frequency (saturating, so the 10th occurrence adds little), inverse document frequency (rare terms count more), and length normalization. Decades old, no training, and still embarrassingly competitive — exact identifiers, names and codes that embeddings blur, BM25 nails. That is why production retrieval is usually hybrid: BM25 + vectors, fused.