RAG & Search
BM25
A widely used keyword-ranking algorithm that scores how relevant documents are to a search query.
Example
BM25 ranks a page highly when it contains important query terms without excessive repetition.
Why it matters
It gives search a practical starting method that does not require a language model.
You'll hear it
“The exact terms match, but the page is much longer than the useful passage.”
Can you control it?
Set by the team
The people building or running the AI choose this setup. An everyday user generally needs their help to change how this part works.
Common questions
- Does BM25 understand a passage like a person?
- No. It uses word-based calculations rather than establishing human-like understanding.
- Does adding more repeated keywords always help?
- No. The method limits the benefit of repeated terms and accounts for document length.
- Can it be combined with meaning-based search?
- Yes. A system can combine its word matching with other methods when that improves results.