BuildSpark AI

Map · Foundations · 02 · Context Window

Concept card · Foundations

Context Window

The context window is the fixed text one request can hold: instructions, history, documents, and the answer.

The fixed text one request can hold: instructions, history, documents, and the answer.

Last checked 2026-10-16 Free card 4 min

Ask about Context Window

What changed

Oct 16: Cost now notes that resending the same history or documents adds up, and that prompt caching can make the repeated part cheaper. The risk line no longer says how often a full window causes a miss.

1 What it is

The context window is how much text one request can hold. That includes the system prompt, the conversation so far, documents you attach, and the answer the model is still writing. Text that does not fit is not visible to the model for that request.

This meter is a picture of a fixed 100-unit window. The number is not a real model limit. Pieces fill in order: system prompt, history, documents, then the answer. What does not fit is left out. Real products differ: some refuse the request instead of cutting.

  • System prompt
  • History
  • Documents
  • Answer
System prompt18
History22
Documents28
Answer16

2 Why it matters

Cost

You pay for the tokens that sit in the window, including history and documents the question may not need. Re-sending the same history or documents every turn adds up. Prompt caching can make the repeated part much cheaper.

Quality

When the window is full of old turns or long documents, less room is left for the question and the answer.

Risk

Text that does not fit is outside that request. An instruction or a fact can be among what the model does not see.

3 How to apply · try today

On a long chat, start a fresh thread and paste only the brief and the source you still need.

Common mistake

Assuming the model still sees the first messages after the thread has grown past the window.

Self-check

You send the same long document on every turn. What can change the cost of that repeated part?

Questions

What is a context window?
The context window is the fixed text one request can hold: instructions, history, documents, and the answer. Text that does not fit is not visible to the model for that request.
Does the model still see the start of a long thread?
Not once those messages fall outside the window. What does not fit is outside that request.
What can change the cost of sending the same document on every turn?
Prompt caching can make the repeated part much cheaper. Sending it again without caching adds up.