In a lucene based search engine, BM25 rewards shorter snippets of text. I’ve mentioned that term frequency might not matter, it’s still good to bias towards shorter snippets of text with fewer terms.

Consider the case a user searches for angularjs

Which is more relevant?

  • A book title mentions “angularJS” but also “web design” and “javascript”
  • A book title JUST mentioning angularJS, and nothing else

The latter will be more “about” the concept than the one mentioning many topics. It’s a safer bet.

-Doug

​

​

This is part of Doug’s Daily Search tips - subscribe here


Starting in November: AI-Powered Search — Modern Retrieval for Humans & Agents

AI-Powered Search course with Doug Turnbull and Trey Grainger

Learn the latest AI search skills with the authors of AI-Powered Search. Join Doug Turnbull and Trey Grainger to explore modern retrieval for humans and agents. Explore the course on Maven.

Doug Turnbull

More from Doug
Twitter | LinkedIn | Newsletter | Bsky