Hypothetical question embedding improves retrieval by representing each document chunk through questions it can answer rather than only through its original wording. An LLM or chatbot conversation history can supply those questions. At query time, the system embeds the user’s question, finds semantically similar precomputed question embeddings, and retrieves the documents containing the answers. section 3.0
A practical implementation follows this sequence:
- Identify questions that each document or chunk can answer. section 3.0
- Generate questions with an LLM or derive them from chatbot conversation history, then precompute their embeddings. section 3.0
- Embed each user query, search for nearest question vectors, and return the associated documents. section 3.0
Matching a user question
A document that answers “What did Leopold study at the University of California?” can store that hypothetical question as vector [1,2,3,0,5]. A semantically similar user query retrieves the document through the question vector rather than matching the document’s original wording. section 3.0
Figure 3.2 Hypothetical question and parent document retriever strategies
Compare hypothetical question embeddings with parent document embeddings and child-chunk retrieval. section 3.0
