AI-300 Practice Question 49: Hybrid Semantic Ranking k Value
Microsoft Machine Learning Operations Engineer Associate (AI-300) · Test 5 · question 9 of 10
A RAG application runs a hybrid query (keyword plus vector) with semantic ranking enabled in Azure AI Search. The vector queries use k set to 10, and the team finds that the semantic ranker often misses relevant passages that appear a little lower in the fused results. Which change is recommended for this configuration?
Show answer and explanation
Answer:
The Azure AI Search documentation for vector queries says: *"Whenever you use semantic ranking with vectors, set k to 50. Semantic ranker uses up to 50 matches as input. Specifying less than 50 deprives the semantic ranking models of necessary inputs."* The scored results from the vector and keyword queries are fused with RRF, and the secondary semantic ranking then boosts the passages that are most aligned to the query, so giving it the full 50 candidates fixes the missed passages (option A).
- B is wrong because k = 1 starves the ranker even more, which is the opposite of what is needed. - C is wrong because removing semantic ranking discards the re-ranking that improves the ordering of the fused results, and vector scores alone are not a fix for missing candidates. - D is wrong because the documentation gives the best practice to *"always use the same embedding models used to generate embeddings in the source documents"* for queries. A mismatch makes the vectors incomparable and degrades retrieval.
Reference: Create a Vector Query - Azure AI Search