A text method for giving words scores based on frequency and rarity.
TF-IDF is like spotting toppings on pizza boxes. “Cheese” is everywhere, but one box yelling “anchovy” twice gets noticed.
In search, it pushes common words down. It lifts words with stronger topic clues.
Bag-of-Words
TF-IDF starts with Bag-of-Words, then gives each word a weight.
IR
TF-IDF is a classic signal for search ranking.
BM25
BM25 is a stronger version built for search ranking.
Vector search
TF-IDF leans on keyword matches. Vector search leans on meaning.