AI Model & Product
Context window
Also known as: context length, token window, context limit
A context window is the maximum amount of text, measured in tokens, that a large language model can take into account in a single request. It covers everything the model sees at once: system instructions, the conversation so far, any retrieved or pasted documents, and the response being generated. Once the limit is reached, older or less relevant content has to be dropped, summarised or split across requests.
What it is
The context window is the working memory of a language model for one exchange. It is counted in tokens rather than words, where a token is roughly a short word fragment, so a long brief, transcript or set of retrieved pages consumes the budget quickly. Different models expose different limits, and the limit covers both the input and the generated output.
Why it matters
Context limits decide how much of your content an AI assistant can actually hold while answering a question, which affects whether your page is used in full or reduced to a fragment. In AI search and retrieval systems, a crowded window means only the highest-scoring chunks make it through, so structure and self-contained passages matter more than page length. For teams building assistants, the window also drives cost and latency, because every token in the window is paid for and processed.
How it works
Practitioners measure token counts before sending requests, then manage the budget by trimming system prompts, summarising earlier turns, and retrieving a small number of relevant chunks rather than whole documents. Long tasks are broken into stages, with intermediate summaries carried forward instead of raw text. Content teams help by writing sections that make sense on their own, with clear headings and definitions near the top, so a single retrieved chunk still answers the question.
When it applies
It applies whenever you prompt a model with long inputs, build retrieval augmented generation, run document analysis, or maintain multi-turn chat where the history keeps growing.
Examples
- A support assistant loses details from the start of a long chat because earlier turns were dropped to make room for new messages and retrieved help articles.
- An analyst pastes a 90-page annual report into a model and gets vague answers, then splits it into chapters with per-chapter summaries to stay inside the limit.
- A retrieval pipeline is capped at eight passages of around 400 tokens each so the prompt, sources and answer all fit within the model's limit.
How it is measured
- Average and peak tokens per request, shown as a percentage of the model's limit
- Truncation rate: share of requests where history or retrieved content had to be dropped
- Number and size of retrieved chunks passed into each prompt
- Cost and latency per request, tracked against token volume
Insights on Context window
Related terms in AI Model & Product
- Agents APIAn Agents API is a programming interface for building applications where a model plans, calls tools and completes multi-step tasks rather than returning a single reply. The term is most often used for OpenAI's agent building interfaces, though other vendors offer equivalents. Teams use it to connect models to search, internal data and actions such as booking, updating records or generating reports.
- AI assistantAn AI assistant is a software product that uses a language model to hold a conversation, answer questions and carry out tasks on a user's behalf. It sits on top of one or more underlying models and adds an interface, memory, tools and safety controls. Examples include ChatGPT, Google Gemini, Microsoft Copilot, Claude and voice assistants such as Siri and Alexa.
- AI transcriptionAI transcription is the automatic conversion of spoken audio into written text using speech recognition models. Modern systems often add speaker labels, punctuation, timestamps and language detection, and can feed the output into summarisation or search. It is also called automatic speech recognition or ASR.
- BingBing is Microsooft's web search engine, available at bing.com and integrated into Microsoft Copilot and other Microsoft products. It maintains its own crawler, Bingbot, and its own index, and provides Bing Webmaster Tools for site owners. Its index and APIs have also supplied results to third-party search products and AI assistants.
- ChatGPT VoiceChatGPT Voice is the spoken conversation mode in OpenAI's ChatGPT apps, which lets you talk to the assistant and hear its replies read aloud. Advanced Voice Mode processes speech directly, so exchanges feel closer to a phone call and you can interrupt mid-answer. People use it hands free on mobile, and it is also available on desktop.
- Claude CodeClaude Code is Anthropic's agentic coding tool that works directly with a codebase, reading files, proposing and making edits, and running commands with permission. It runs in the terminal and in supported development environments, driven by natural language instructions rather than manual file by file editing. Marketing and growth teams use it for technical SEO, structured data and data tasks that would otherwise wait for engineering.