Context Window
The maximum amount of text an LLM can read and reason over in a single interaction. Everything outside the context window is invisible to the model. For processing long documents like 100-page contracts or multi-invoice batches, context window size is a hard technical constraint.
What is a Context Window?
A context window is the total amount of text — measured in tokens — that a language model can hold in working memory at one time. Tokens are roughly 0.75 words each, so a 128,000-token context window fits about 96,000 words, or roughly a 200-page document. Everything inside the window is available to the model for reasoning. Everything outside it is not — the model has no memory of text it processed beyond this limit.
Context windows have grown dramatically: GPT-3 launched with 4,096 tokens; current models reach 200,000 or more. But size still matters for operational use cases that involve long documents, multi-document comparisons, or extended conversation histories.
Why Context Window Size Matters
For document-processing workflows, the context window determines what is technically possible in a single pass. A 100-page supplier contract, a full year of purchase history, or a batch of 50 invoices — these either fit or they do not. When they do not fit, the system must chunk documents into pieces and process them separately, which introduces risk: relevant context from page 3 may be missing when the model processes page 7.
Short documents (invoices, delivery notes): Context window is rarely a constraint — a standard invoice is under 2,000 tokens
Long documents (contracts, specifications): Chunking strategies or long-context models are required
Multi-document reasoning: Comparing a PO against an invoice against a delivery note in one pass requires all three to fit simultaneously
Conversation history: In agentic workflows, prior steps consume context — long chains of tool calls reduce the space available for new document content
Context Window in Operations
At Lleverage, context window management is a practical engineering consideration. A three-way match — purchase order, goods receipt, supplier invoice — typically fits within 8,000 tokens and runs in a single pass. A full framework agreement with amendments requires a chunked approach with overlap to avoid losing cross-reference context. The rule of thumb: if a document fits in the context window, process it whole. If it does not, design the chunking strategy carefully and validate that critical cross-document references are not split across chunk boundaries.