Context Window
Definition
The context window is the maximum amount of text, measured in tokens, that a language model can take in and produce in one request. Everything counts against it: instructions, conversation history, retrieved documents and the reply itself.
What fills it
- System promptThe app's standing instructions, sent with every request.
- Conversation historyEarlier messages, which grow with every turn.
- Retrieved contentDocuments or search results added for this request.
- The replyRoom the model needs to write its answer.