Dense Retrieval: Semantic Search & Bi-Encoder Implementation › Limitations and Impact
Language AI HandbookAll chapters Dense Retrieval: Semantic Search & Bi-Encoder Implementation › Limitations and ImpactOne section · Sections in this chapter10 / 12 ↓
Reading tools Definitions & inline links
Choose your expertise level to adjust how many terms are explained. Beginners see more tooltips, experts see fewer to maintain reading flow. Hover over underlined terms for instant definitions.
Article links
Make inline references clickable
Dense retrieval has transformed information retrieval and forms the foundation of modern knowledge-intensive NLP systems. However, understanding its limitations is needed for effective deployment. No retrieval technology is universal, and dense retrieval has specific failure modes that practitioners must account for.
Key Limitations
Dense retrievers require substantial training data to perform well on any given domain. Unlike BM25, which works out-of-the-box on any text collection using only the document corpus itself, dense models need labeled query-document pairs that match the target domain. A retriever trained on Wikipedia passages may perform poorly on legal contracts, scientific papers, clinical notes, or source code because those domains use different vocabulary and writing styles to express their semantic relationships. This domain sensitivity creates a "cold start" problem: organizations adopting dense retrieval for specialized applications need to either find a pre-trained model that covers their domain, collect domain-specific training data, or accept degraded performance. Collecting labeled training data is expensive and time-consuming, and for highly specialized domains, it may require domain experts who are scarce and expensive.
The computational and memory requirements of dense retrieval are significant and should not be underestimated at scale. Each document must be processed by a transformer encoder, and the resulting embeddings must be stored and indexed. For a corpus of 100 million documents with 384-dimensional embeddings in float32 precision, storage alone requires approximately 150 gigabytes, before any indexing structure overhead. While approximate nearest neighbor indices like HNSW or IVF-PQ can reduce search latency to milliseconds, they require additional memory and careful tuning. Sparse indices based on inverted lists, as used by BM25, typically require far less memory and can be searched efficiently with simple term lookups. The infrastructure investment for production dense retrieval, including GPU servers for encoding, vector databases for indexing, and replication for high availability, is substantially larger than for sparse retrieval.
Dense retrievers can also fail silently in ways that sparse retrievers do not. When BM25 returns poor results, the explanation is often immediately clear: the query terms simply do not appear in relevant documents. When a dense retriever fails, diagnosing the problem is much harder. The model might not have learned good representations for certain concepts, might confuse similar-sounding but semantically distinct entities (e.g., "Python the language" vs "Python the snake"), might not handle negation correctly (retrieving documents that say "A does not cause B" when the query asks "what causes A"), or might have distribution shift between its training data and the deployment domain. These opacity challenges make debugging and systematically improving dense retrieval systems more difficult than improving lexical systems.
Negation and logical constraints present a well-known challenge. Dense retrieval operates on semantic similarity, so "hotels without swimming pools" may retrieve documents about "hotels with swimming pools" because both texts are semantically about hotels and pools. The model lacks a mechanism to understand that the user explicitly wants to exclude certain properties. Similarly, numerical constraints ("papers from 2020 to 2022") and logical combinations ("A but not B") are poorly handled by similarity-based retrieval and often require post-retrieval filtering or more specialized architectures.
Impact on NLP Systems
Despite these limitations, dense retrieval has had enormous impact on NLP and AI systems. Semantic matching at scale made several previously impractical capabilities feasible:
Open-domain question answering systems improved dramatically when they could retrieve passages by meaning rather than keywords. Systems like RAG, FiD (Fusion-in-Decoder), and REALM all rely on dense retrieval as their backbone, achieving human-competitive performance on open-domain QA benchmarks by grounding generation in retrieved evidence. This was a major milestone in moving NLP from narrow task-specific systems to general knowledge-intensive question answering.
Retrieval-Augmented Generation systems, which we introduced in the previous chapters, depend critically on dense retrieval. The ability to find semantically relevant passages allows LLMs to answer questions about events after their knowledge cutoff, provide responses grounded in specific private documents, and reason over large knowledge bases without memorizing everything in their parameters. Every major commercial LLM assistant now uses some form of retrieval augmentation, and dense retrieval is the workhorse of the retrieval component in most of these systems.
Semantic search products from Google, Microsoft Bing, and other major search providers now incorporate dense retrieval techniques to handle conversational queries, long-form questions, and semantic information needs that were previously poorly served by keyword search. The transition from keyword search to semantic search at commercial scale represents one of the most significant applied NLP developments of the 2020s.
Cross-lingual applications became far more practical because multilingual dense models can encode meaning across languages, letting search systems where queries and documents may be in different languages. A user querying in English can retrieve relevant passages from documents in Spanish, French, or Japanese, as long as the multilingual encoder has learned to map semantically equivalent content in different languages to similar regions of the embedding space.
The combination of transformer pre-training, contrastive learning for retrieval, and approximate nearest neighbor search established a new paradigm for information access that goes far beyond traditional search. Dense retrieval combines representation learning with information retrieval, an area that continues to drive active research and development. The next chapter examines contrastive learning for retrieval: the training objectives, loss functions, and hard negative mining techniques that determine the quality of the learned embedding space.