RAG for Everyone

← Back to practice

Chapter 16 Interview Prep45 min review

Interview Questions: Retrieval Strategies and Top-K

Use these to explain retrieval control like a production engineer.

Q01

What is top-k?

The number of retrieval candidates returned from search before later stages such as dedupe, reranking, or context assembly.

Q02

How do you choose top-k?

Use evals across Recall@k, citation support, answer quality, latency, token budget, and duplicate rate.

Q03

What happens if k is too low?

The correct evidence may rank below k and never reach the model.

Q04

What happens if k is too high?

Noisy, duplicate, stale, or conflicting chunks can crowd the context window and increase cost.

Q05

Are similarity scores confidence?

No. They are ranking signals that need calibration and must be interpreted with metadata, evals, and citations.

Q06

Why use metadata filters?

To enforce tenant, access, active status, region, source type, and freshness before context assembly.

Q07

When is query rewriting useful?

When user wording is vague, conversational, acronym-heavy, multilingual, or missing domain terms.

Q08

When is multi-query retrieval useful?

When a single phrasing may miss evidence and recall is important enough to justify extra searches.

Q09

What should a retrieval trace include?

Original query, rewritten query, filters, top-k, scores, ranks, selected chunks, dedupe count, citations, and index version.

Q10

How do you debug a retrieval miss?

Check whether gold evidence exists, whether it was filtered, its rank, score distribution, duplicates, rewrite behavior, and context assembly.

← Practice BankProject →