Skip to main content
ES CAT EN IT FR DE 中文
Method

Deleting your keyword index is the most expensive mistake in a vector rollout

We specified hybrid search to look inside our own vault, and hybrid search was exactly what broke. Not through a decision, but through an API that returned half of it and said nothing.

What we found

  • Adding contextual BM25 on top of contextual embeddings cuts the retrieval failure rate from 3,7 % to 2,9 %, a 49 % reduction against baseline; with reranking it reaches 67 % (Anthropic, September 2024).
  • The k = 60 that Azure AI Search, Elasticsearch, OpenSearch and Qdrant use by default to fuse rankings was fixed during a pilot and never revisited, according to the paper that introduced it (SIGIR 2009).
  • In BEIR, covering 18 datasets and 10 systems evaluated zero-shot, BM25 holds up as a robust baseline while dense models often underperform outside their training domain (NeurIPS 2021).

When a team shows us their internal search and tells us it works badly, it almost never works badly. It works exactly as designed, and it was designed to match strings. The problem shows up when the person searching does not name the thing they want, but describes the problem they have.

That distance has expensive consequences, and the industry's reaction on discovering it has nearly always been the same: rip out what was there and install vectors. It is the wrong call, and there is enough public evidence to show it.

01Two ways of matching, and only one understands the question#

Keyword search rests on three pieces: an inverted index mapping each term to the documents containing it, some frequency statistics and a scoring formula. BM25 is that formula, and it is good: it saturates term frequency so the hundredth occurrence counts for less than the tenth, and it normalises by length so long documents do not win by accumulation.

What none of those three pieces does is understand. The index does not know that "couch" and "sofa" are related, nor that "I cannot get in" and "I forgot my password" are the same problem. It matches strings, which is its job.

Dense retrieval attacks the problem from the other side. Instead of representing a document as the set of words it contains, it places it as a point in a high-dimensional space where texts with similar meaning land close together. The query goes through the same model and its neighbours are retrieved. Retrieval stops being matching and becomes geometry.

Comparative diagram: the same query running down two paths, the lexical one with an inverted index and the vector one with an approximate nearest neighbour index, and how each reaches a different document
One query, two matching paths and two different documents in first place · Source: 498A, October 2026

The gain is measured. Dense Passage Retrieval beat a solid BM25 baseline by between 9 and 19 absolute points of top-20 passage retrieval accuracy, across several open-domain question sets.

The counterweight is measured too, which makes the story more interesting. The BEIR benchmark evaluated 10 retrieval systems over 18 datasets under zero-shot conditions, meaning outside the domain each model was trained for. Its conclusion is that BM25 behaves as a robust baseline and that dense models often underperform other approaches. Reranking models achieve the best average, at a high compute cost.

Put together, the two results say something neither says alone: vectors win a great deal inside the territory they were trained for, and turn fragile on leaving it.

02Where each one fails, by query type#

The useful question is not which engine is better, but which class of query belongs to each. And that classification can be done in an afternoon with your own search logs.

Split by query type. In a real search engine most of the volume falls in the last three rows and most of the critical incidents in the first four
Query typeWhat winsWhy
Exact identifierKeywordsA vector places ERR-5021 next to ERR-5022 because they look alike. One is the right runbook and the other is a different incident
Navigation and filtersKeywords"Red ones under 500 euros" is set logic over structured fields, not a similarity problem
Wording-sensitive textKeywordsIn contracts and regulation, "shall" and "may" cannot be paraphrased. Treating them as neighbours is a legal risk
Rare brand or neologismKeywordsThe model barely saw that name during training, so it represents it poorly. Literal matching never needed to have seen it
Paraphrase and synonymVectorThe words do not overlap and the meaning does. The inverted index never even gets to score it
Described needVectorThe person describes a symptom and the document describes a solution. Crossing that gap takes understanding, not indexing
Cross-language queryVectorA multilingual model places the same concept written in two languages close together

There is one detail worth holding on to from the first row, because it is what turns a vector rollout into a support crisis: when an identifier query fails, the system does not return an error. It returns something similar.

03How they fuse, and the constant nobody revalidated#

If both paths coexist, their results have to be combined, and there the problem appears that a BM25 score and a cosine similarity do not live on the same scale. The standard solution sidesteps the problem entirely: instead of fusing scores, it fuses positions.

Reciprocal Rank Fusion adds up, for each document, one divided by the sum of a constant and the position that document holds in each ranking. Positions are comparable across engines. It is simple, hard to get badly wrong, and that is why it has become half the sector's default.

What almost nobody has read is the small print. The paper that introduced it, in 2009, runs to two pages, and on the constant it says in so many words that the value 60 "was fixed during a pilot investigation and not altered during subsequent validation". That number is today the default in Azure AI Search, Elasticsearch, OpenSearch, Weaviate, Qdrant and PyTerrier.

Technical detail · what the constant actually does

The constant dampens how much being in the top positions counts. With a high value, the difference between first and fifth flattens out and the fusion rewards documents appearing in both lists even when they lead neither. With a low value, a single engine's first place can drag the result. A document coming first in vector and third in lexical accumulates more than one that is only first in one of the two, and that behaviour is exactly what you want. The value 60 is neither magic nor wrong; it simply was never tuned to anybody's particular corpus, and tuning it is one of the few cheap levers left.

That fusion matters is not an opinion. When Anthropic measured its contextual retrieval pipeline, the sequence ran like this: the baseline failed to retrieve the relevant chunk in the top twenty 5,7 % of the time; with contextual embeddings it dropped to 3,7 %; adding contextual BM25 on top, to 2,9 %; and with a reranking layer, to 1,9 %.

Those four numbers are worth reading slowly. The jump from putting the lexical leg back in is comparable to the one from the reranker, which is the expensive piece. And the reason the report itself gives is the usual one: embeddings miss exact matches, and unique identifiers and technical terms are precisely exact matches.

04What happened to us building search for our own vault#

In September 2026 we designed a local AI platform over our own Obsidian archive: models running on the machine, nothing sent outside, retrieval across thousands of working notes. Hybrid search was not one more line in the spec. It was the requirement that decided the rest.

It decided, to begin with, the embedding model. We chose BGE-M3 because in a single pass it produces three representations: the dense vector, per-token lexical weights that work like a learned BM25, and a multi-vector matrix. Its direct rival scores better, 64,33 against 59,56 on the MTEB multilingual table, with more context and a more comfortable licence. We ruled it out anyway, and the verdict left in the architecture note was one line long: it loses for being dense-only.

We deliberately picked the model that was worse on paper so as not to lose the lexical half of the system. And we lost it anyway.

Verifying the install against the machine turned up that the embedding call on the server we were going to use returned only the dense vector. No lexical weights, no multi-vector matrix. The two capabilities we had chosen that model for, and which the model does produce, were unreachable through the API we intended to consume it with. Recovering them meant serving it with another library, in another process, that was neither budgeted nor supervised.

The known anti-pattern is switching off the keyword index on day one of a vector rollout. What happened to us is the silent version of the same accident: nobody switched anything off, the lexical half went missing in the serving layer. A correct model, correctly installed, served by an interface that silently discarded the very thing it had been chosen for.

The second lesson came from arithmetic. We had planned a dedicated vector engine, chosen not for scale but for format, because it was the only one storing all three representations and fusing them in a single query. The audit knocked it down with an elementary calculation: the real corpus runs to between thirty and sixty thousand vectors, around 246 MB. The whole index fits in memory inside the relational database that was already deployed, and on top of that it travels inside the backup that was already being taken. A dedicated service was not justified by capacity.

Between that corpus and the ten million documents where raw vectors already take up tens of gigabytes there are three orders of magnitude. The right question was never which vector database to use, but which stretch of that curve you are on. Almost nobody works out their own before choosing.

And a third, local and distinctly unglamorous: we work in Catalan. With a dense-only model you would have to build and maintain a second lexical leg with its own tokeniser and its own behaviour in Catalan, something no English-language comparison table reflects. Alongside it, the failure mode that sums up this whole article: some models require task prefixes on the query, and a misplaced prefix degrades retrieval without throwing any error.

The honest caveat belongs here: this is an architecture decision, documented and verified against the machine, not a production result. We do not yet have our own retrieval metrics on that corpus. What we do have is the bill for having taken the lexical leg for granted.

05What changes when the one searching for you is a model#

Everything above describes an internal search engine, but it explains something that affects any brand with a website, and it is one of the underlying reasons GEO and SEO do not behave alike.

Classic SEO optimises against an inverted index and a link graph: strings and authority. A generative engine works differently. It retrieves fragments by meaning, and before retrieving anything it decomposes the question. Google documents that its AI surfaces can issue several related searches across subtopics from a single user question. What you have to win stops being the query somebody types and becomes the set of queries the machine derives from it.

Out of that come, with no mysticism involved, all the practices we recommend: paragraphs that stand on their own, figures with their unit and their date in the same sentence, entity definitions that do not depend on the previous paragraph, sections with their own anchor so a fragment can be cited rather than the whole page. Seven rules that are one instruction in disguise: make your fragment a good neighbour.

It also explains why measuring this looks nothing like a rankings report. At GEORadar every study simulates between 6.000 and 30.000 custom prompts precisely because the question that matters is not how you do on one query, but what share of your market's query space retrieves you. It is the same coverage problem, seen from the brand's side.

If there is one thing to do with this before touching a line of code, it is the cheapest item in the article: take fifty real queries from your own search logs and sort them into the rows of the table above. Most teams discover two things at once. That the list is longer than they expected. And that their search problem was never an engine problem, but a matter of never having classified what was being asked of it.

For anyone building this on their own models with data that does not leave the building, that split is also an infrastructure decision, and it is the part that is cheapest to get right at the start and dearest to correct later.

Sources
  1. Cormack, Clarke and Büttcher. Reciprocal Rank Fusion outperforms Condorcet and individual Rank Learning Methods. SIGIR 2009. https://dl.acm.org/doi/10.1145/1571941.1572114
  2. Thakur, Reimers, Rücklé, Srivastava and Gurevych. BEIR: A Heterogeneous Benchmark for Zero-shot Evaluation of Information Retrieval Models. NeurIPS 2021. https://arxiv.org/abs/2104.08663
  3. Karpukhin et al. Dense Passage Retrieval for Open-Domain Question Answering. EMNLP 2020. https://arxiv.org/abs/2004.04906
  4. Anthropic. Introducing Contextual Retrieval, September 2024. https://www.anthropic.com/news/contextual-retrieval
  5. Malkov and Yashunin. Efficient and robust approximate nearest neighbor search using Hierarchical Navigable Small World graphs. IEEE TPAMI. https://doi.org/10.1109/TPAMI.2018.2889473
  6. Formal et al. SPLADE: Sparse Lexical and Expansion Model for First Stage Ranking. 2021. https://arxiv.org/abs/2107.05720
Carlos Ortet
Carlos Ortet
Co-founder and CEO of 498 Advance

Runs 498A, the applied AI lab of the Zoopa group, and GEORadar. Visiting lecturer at the UAB, where he supervises master's work in AI with the IIIA-CSIC.