LiveFR

Context window vs RAG

Definition: Putting everything in the context window means feeding the model all the documents directly; RAG instead retrieves only the relevant passages on demand.

Long context is simple but costs tokens on every call and can dilute the useful information; RAG scales to huge stores but depends on retrieval quality. The two approaches are often combined rather than opposed.

See also

← Full AI glossary · AI news