Skip to main content
Okapi BM25

Okapi BM25

Search complete. 27 mentions across 12 episodes found for "Okapi BM25".

Sep 15, 2026

Connor HeggieGUEST
35:21
When we were working on this sort of transition off of Elasticsearch, we, we h- did a bunch of work to evaluate a different technology, which was reverse indices in Postgres.
Connor HeggieGUEST
35:35
So our thesis was, okay, we will run Elasticsearch, basically, Elasticsearch style Lucene reverse indices, BM25 indices, in Postgres.
Connor HeggieGUEST
35:49
And there was this company, this startup, this YC startup that was doing it.
Connor HeggieGUEST
35:53
Brilliant team, really top-notch, great technology.
speaker_1HOST
5:05
For that, they use Vectorize and AI search.
speaker_1HOST
5:08
This handles your HNSW dense vector indexing combined with BM25 keyword matching for your hybrid search.
speaker_1HOST
5:15
And then they wrap all of this in their AI gateway, which handles edge caching, rate limiting, observability.
speaker_1HOST
5:21
Got it.

7 MINS LATER

speaker_1HOST
11:57
Precisely.
speaker_1HOST
11:58
And that's just the state coordination.
speaker_1HOST
12:00
When we look at the RxZ support, Cloudflare's AI search handles managed hybrid search out of the box, so dense vectors combined with BM25.
speaker_0HOST
12:08
Which is great.
Sam O'NuallainGUEST
11:50
The one that is ranked low, the analysis agent can like analyze the goal document, analyze the query, see what got ranked above it by using its tools and say, oh, like it seems like things that were ranked higher, I see this pattern.
Sam O'NuallainGUEST
12:04
And I have a theory that something in the query, like we were using BM25 as a retriever.
Sam O'NuallainGUEST
12:09
So it's very important to have like overlapping terms, obviously.
Sam O'NuallainGUEST
12:13
So, oh, it seems like a really important thing term that's not common in other documents in the goal document um our representation program currently just left it out for some reason like we deleted it that's like a very simple case and the analysis agent kind of like looks at that and can kind of reason about the feedback it's getting from using these tools and exploring the data set to figure out what's wrong with the current representation.

9 MINS LATER

Sam O'NuallainGUEST
21:10
And it was kind of like messing it up.
Sam O'NuallainGUEST
21:12
Cause the N 25 is just like a lexical matching retriever.
Sam O'NuallainGUEST
21:16
Um, And I think the reason that worked well with BM25 is because it's very easy to see just in text what is going wrong.
Sam O'NuallainGUEST
21:23
Like it's a bag of words.
Malte LandwehrGUEST
44:24
Yeah, I like the crispy fries.
Malte LandwehrGUEST
44:25
I like the juicy burger and then then people are more likely to use that in the reviews i would add as under explored bm25 it's a technique algorithm to measure how relevant a document or text passage is for a search term And I see a lot of evidence that various LLMs are using this in some of the steps used for the ranking and re-ranking of documents for their fanouts.
Malte LandwehrGUEST
44:51
It can be very educational for you to take one of your prompts or keywords or fanout queries and your text that you are writing and just look at the BM25 scoring of that and documents who are beating you and see if there's something in there you can find how you can optimize your content.
James DooleyGUEST
45:06
Yeah, for sure.
James DooleyGUEST
45:07
Just move on with regards to what Kazza said about the reviews on the citations.
Malte LandwehrGUEST
44:24
Yeah, I like the crispy fries.
Malte LandwehrGUEST
44:25
I like the juicy burger and then then people are more likely to use that in the reviews i would add as under explored bm25 it's a technique algorithm to measure how relevant a document or text passage is for a search term And I see a lot of evidence that various LLMs are using this in some of the steps used for the ranking and re-ranking of documents for their fanouts.
Malte LandwehrGUEST
44:51
It can be very educational for you to take one of your prompts or keywords or fanout queries and your text that you are writing and just look at the BM25 scoring of that and documents who are beating you and see if there's something in there you can find how you can optimize your content.
James DooleyGUEST
45:06
Yeah, for sure.
James DooleyGUEST
45:07
Just move on with regards to what Kazza said about the reviews on the citations.
speaker_0HOST
20:33
How does it actually do that?
speaker_1HOST
20:35
Specifically, it uses an algorithm called BM25.
speaker_1HOST
20:39
And BM25 doesn't just do a dumb find in page search.
speaker_1HOST
20:42
It calculates term frequency versus inverse document frequency.
speaker_0HOST
20:46
OK, you're gonna have to break that down for me.
speaker_1HOST
20:48
It asks a mathematical question.
speaker_1HOST
20:50
How many times does this exact part number show up in this specific document compared to how rare it is across the entire company database? If the part number 4F9920X is very rare globally, but shows up 10 times in one specific PDF, BM25 heavily weighs that PDF as the correct answer.
speaker_0HOST
21:09
Oh, so it understands the rarity and the density of the exact keyword.
Connor ShortenHOST
54:47
That insight is, especially in the world of search, earlier in the year, I had Doug Turnbull on the WeVA podcast, who's like legend in the search community.
Connor ShortenHOST
54:55
And he was really excited about RLMs and writing search programs, the way you can, like, because like with Grep and BM25, the way you can search and then get that feedback.
Connor ShortenHOST
55:07
It's so powerful, and it can write this particular regular expression to, you know, command to find the files.
Connor ShortenHOST
55:13
It's such a captivating world in search.
Doug TurnbullGUEST
11:06
Uh, the, the very first thing on my playbook is, is evals and measurement, and I know-
Hugo Bowne-AndersonGUEST
11:13
BM25 as a baseline, perhaps.
Doug TurnbullGUEST
11:16
Yeah, just, just get a good baseline in place and measure how good it is to see where you're gonna find things that work really well and things that don't work really well.
Doug TurnbullGUEST
11:24
And that's honestly the biggest gap most organizations have with search.

Unknown podcast

EP389: Solving the AI Memory Trilemma

Aug 25 · 2 Mentions

speaker_1HOST
10:17
Yeah.
speaker_1HOST
10:17
It uses sparse lexical retrieval, specifically BM 25 running in parallel with dense embeddings.
speaker_0HOST
10:23
Wait, pause on reciprocal rank fusion and those terms for a second.
speaker_1HOST
10:26
Let's break it down.
speaker_0HOST
10:27
Yeah.
speaker_0HOST
10:27
For those of us who aren't search engineers, let's translate that.
speaker_0HOST
10:30
Lexical retrieval, BM 25, that's basically just fancy keyword matching, right?
speaker_1HOST
10:36
Yes.
DanielHOST
4:10
And once you're building a custom frontend anyway, the argument for keeping things simple with Markdown files starts to feel... quaint.
Herman PoppleberryHOST
4:18
Why not just use Pinecone? Because Pinecone costs money and adds operational complexity and ties you to a specific vendor and requires you to manage embedding models and re-indexing pipelines and all of that for what? For a few thousand tokens of project memory, the BM25 algorithm, which is just a fancy bag-of-words search, no embeddings, no GPU, performs comparably to dense retrieval for moderate-sized document collections.
Herman PoppleberryHOST
4:45
You can run it on a laptop.
Herman PoppleberryHOST
4:47
For tens of thousands of tokens of markdown files, BM25 or a tiny local embedding model like all, MiniLML6v2 is more than enough.
Herman PoppleberryHOST
4:57
You don't need a vector database until you're dealing with millions of documents.
Herman PoppleberryHOST
5:01
So the market has

8 MINS LATER

Herman PoppleberryHOST
13:00
When the user asks a question, you embed the question, compute cosine similarity against all the stored vectors, and pull the top k results.
Herman PoppleberryHOST
13:08
The whole thing runs in milliseconds for a few thousand documents.

2 more episodes mention Okapi BM25.

Create an account to see the whole feed, search across every transcript, and follow the entities you care about.

We value your privacy

We use cookies to understand how you use our platform and to improve your experience. Click “Accept All” to consent, or “Decline non-essential” to opt out of non-essential cookies. Read our Privacy Policy.