Language Models

Context Window

How much text an AI can "see" at once: its short-term memory.

In everyday terms

Everything in the chat (your messages, its replies, attached files) must fit inside the window. When it overflows, the oldest parts fall out and the AI "forgets" them.

For professionals

The maximum sequence length the model attends over, measured in tokens. Long contexts cost more compute and recall can degrade in the middle.

Think of it like…

A desk of fixed size. New papers push the oldest ones off the edge.

You've already seen it

A long chat where the AI forgets what you said at the start.

Myth vs reality

Myth: The AI remembers all our past conversations.

Reality: Unless a product adds a memory feature, each chat only sees its own context window.

Quick check

Why might a chatbot forget instructions from early in a very long chat?

Show answer

They fell outside the context window: Oldest content drops out when the window is full.

Builds on

Token

Related

Token · Retrieval-Augmented Generation (RAG) · Prompt

🔎esc