passdrill
AI & LLM Engineering · RAG & Embeddings · Card 020/022 easy

A team considers dropping their RAG pipeline entirely now that a newer model supports a 1-million-token context window, reasoning they could simply paste their whole private document collection into every prompt instead of retrieving a handful of relevant passages. Independent benchmarking comparing this long-context approach against RAG on the same workload found the long-context approach answered correctly about as often, but was far more expensive and far slower per query. What best explains why RAG can still be the better choice even when a model's context window is large enough to fit the whole corpus?

  1. A larger context window causes the model to ignore the retrieved information entirely and answer purely from its own training data instead, regardless of what is included in the prompt
  2. Feeding a full corpus into every single prompt means paying to process and re-process a huge number of tokens on every query, which research measuring this trade-off found costs and takes many times longer than retrieving and sending only a handful of relevant passages, so at meaningful query volume the long-context approach's cost and latency scale far worse even when its answer quality is comparable
  3. Context windows above roughly 100,000 tokens are not actually supported by any current model despite vendor claims, so the long-context approach would fail outright rather than merely being slower
  4. RAG pipelines are the only approach capable of producing an answer that cites which source passage it came from, so long-context prompting can never support citations under any circumstances
Next card → Shuffle