A RAG system retrieves poorly on user queries that use different terminology than the indexed documents. Users ask about 'heart attack' but relevant documents use 'myocardial infarction.' The system misses relevant results because the semantic distance between lay and clinical terminology is larger than the similarity threshold. What is the most effective query expansion approach using Claude?
Select an answer to reveal the explanation.
Short Explanation
You want Claude to generate query variants before retrieval, because it can bridge lay and clinical terminology by producing alternatives like 'acute MI,' 'cardiac infarction,' and 'coronary event.' You then embed each variant, retrieve for each, and union the results before reranking. That maximizes recall while preserving precision.
Full Explanation
The correct approach is the Claude-based query expansion method: given the user's query, ask Claude to produce 3-5 alternative phrasings using both lay and clinical terminology, embed each variant, retrieve top-k for each, and union the result sets before reranking. This works because Claude understands that 'heart attack' and 'myocardial infarction' are synonymous and can generate contextually appropriate variants such as 'acute MI,' 'cardiac infarction,' and 'coronary event' that span the terminology space. Unioning retrieval results across variants maximizes recall before reranking for precision. The static medical synonym dictionary approach is wrong because static synonym dictionaries cannot cover the full scope of lay-to-clinical term variation; they require manual maintenance and miss contextually derived synonyms, abbreviations, and domain-specific jargon combinations. The lower similarity threshold approach is wrong because lowering the similarity threshold retrieves more documents but does not bridge the terminology gap; the problematic queries return wrong documents at high similarity, not correct documents at low similarity. The fine-tuned embedding model approach is wrong because fine-tuning embedding models is expensive, requires specialized training data, and takes weeks to execute, while Claude-based query expansion is deployable immediately with high coverage.