← Back to Glossary
Context Window
Phase 02 · LLM Fundamentalscore-concept

The maximum number of tokens an LLM can read and remember in a single request, including prompt and reply.

Why it exists

LLMs process text within a fixed sequence boundary. Everything — system prompt, conversation history, retrieved documents, and output tokens — must fit within this limit.

How it works

If a model has a 128k context window, sending 130k tokens results in truncation or error. Modern attention optimizations like KV caching allow efficient context scaling.

Where you'll use this