The first answers in a new AI chat are sharp. Forty messages later, the assistant forgets a rule you gave at the start or repeats an idea you already rejected.
That is not bad luck. It comes from how the model's context window works, and once you understand it you can design your work around it. Here is what the research says, and a few habits that keep AI work reliable.
What a context window is
Anthropic's documentation describes the context window as all the text a model can refer to when it writes a response, including the response itself. It calls this the model's "working memory", which is different from the huge body of data the model was trained on.
In a chat, the window fills up turn by turn. Every message you send and every answer you get is added and kept, along with the system prompt, uploaded documents and tool results. Each answer then becomes part of the input for the next turn.
Windows are large today. Anthropic lists several current Claude models with a 1M-token window and others with 200k tokens. But the same page warns that more context isn't automatically better: as the token count grows, accuracy and recall degrade, which it calls context rot.
What's changing: the evidence on long contexts
Position matters. In "Lost in the Middle", Liu and colleagues found that models often did best when the relevant information sat at the beginning or end of the input. Performance dropped when the key fact sat in the middle, even for models built for long contexts.
Length matters, even for easy tasks. Chroma's July 2025 report tested 18 models, including GPT-4.1, Claude 4, Gemini 2.5 and Qwen3. Performance became less reliable as input grew, even on simple tasks such as retrieving a fact or copying text: models "do not use their context uniformly".
Distractors matter. The same Chroma study found that passages related to the topic, but not actually answering the question, hurt accuracy. Even a single distractor had an effect, and the damage grew as the input got longer.
Conversations add their own problem. In "LLMs Get Lost In Multi-Turn Conversation" (arXiv, May 2025), Laban and colleagues ran more than 200,000 simulated conversations across six generation tasks. Top models scored on average 39% lower when a task was revealed over several turns instead of in one message.
Most of that drop came from unreliability rather than lost skill. Models made early assumptions, attempted final answers too soon and then leaned on them.
Why does this happen? Anthropic's engineering team explains that a transformer lets every token relate to every other token, which creates n² pairwise relationships for n tokens. They describe context as an attention budget: a finite resource with diminishing returns, where every extra token uses up a little of the model's attention.
What drift looks like in real work
The examples below are illustrative scenarios, not case studies.
Example: A business analyst pastes a 60-page policy document and asks for the eligibility rules. The rule that matters is on page 31, in the middle, next to three similar-looking rules. The summary misses it, which is exactly the middle-plus-distractor pattern the research describes.
Example: A developer spends an afternoon in one chat building a feature. Early on they said "use the existing logging library", but by message 50 the assistant suggests a new one. The instruction is still in the window, it is just buried under thousands of tokens of code and error logs.
Example: A tester explains a bug in five short messages, one detail at a time. The assistant guesses the cause after message two, and every later answer defends that first guess. This is the "get lost and do not recover" behaviour from the multi-turn study.
How AI-DLC helps
The AI-Driven Development Life Cycle, described by AWS in July 2025, is built around the idea that a chat window is not where knowledge should live. The AWS post says AI saves and maintains persistent context across phases by storing plans, requirements and design artifacts in the project repository, so work can continue across sessions.
Inception produces validated context. In Mob Elaboration, AI turns business intent into requirements, stories and units of work, and the whole team checks its questions and proposals. That gives the next phase a clean, agreed starting point instead of a long, messy chat history.
Construction and Operations build on it. Construction uses the validated context from Inception to propose architecture, code and tests, and Operations uses context from earlier phases. Work runs in bolts, short cycles of hours or days, which naturally keeps each session small and focused.
This matches what Anthropic recommends for long tasks: compaction (summarising a conversation near its limit and continuing in a fresh window), structured notes saved outside the window, sub-agents with clean windows, and loading information just in time. AWS's open-source AI-DLC workflow rules also describe keeping persistent state and an audit trail.
Worked example: resetting a drifting chat
Illustrative scenario: you are 70 messages into designing a leave-approval workflow and the answers have started contradicting earlier decisions.
Step 1. Stop adding messages. Ask the assistant to list the decisions made so far, the open questions and the constraints, in under 300 words.
Step 2. Check that list yourself. Fix anything wrong, because a summary of a drifted chat can carry the drift with it.
Step 3. Save the corrected list as a file, for example decisions.md, in your project folder or shared drive. This is your persistent context, the same idea AI-DLC uses.
Step 4. Open a fresh chat. Paste the decisions file first, then ask your next question, keeping the most important rules at the start of the message rather than the middle.
Try it this week
Read the short official page on context windows first:
https://platform.claude.com/docs/en/build-with-claude/context-windows
Step 1. Take a long text you have permission to use, such as a public report, and plant one specific fact in the middle, for example "The project code is BLUE-47".
Step 2. Paste it into any free chat assistant and ask for the project code. Then move the fact to the very start, open a new chat, and ask again.
Step 3. Give a 6-part task one detail per message in one chat, and all at once in another. Compare the two answers.
Step 4. Write down what changed. If you want to go deeper, Chroma's open-source code for its context rot experiments is here:
https://github.com/chroma-core/context-rot
Your next step
🌱 Fresher: Run the planted-fact test from this article and note the result. Start a fresh chat whenever you switch to a new task.
🚀 Mid-career: Keep a decisions file for each piece of AI-assisted work and paste it at the top of new sessions. Put the whole task in your first message instead of feeding details one by one.
🧭 Senior: Ask your teams where project context lives today, in chats or in the repository. Make saved plans and decision logs a standard part of AI-assisted delivery.
Sources
Anthropic, "Context windows", Claude Platform documentation, accessed 25 Nov 2026.
https://platform.claude.com/docs/en/build-with-claude/context-windows
Chroma (Hong, Troynikov, Huber), "Context Rot: How Increasing Input Tokens Impacts LLM Performance", 14 Jul 2025.
https://www.trychroma.com/research/context-rot
Liu et al., "Lost in the Middle: How Language Models Use Long Contexts", TACL, 2023.
https://arxiv.org/abs/2307.03172
Laban, Hayashi, Zhou, Neville, "LLMs Get Lost In Multi-Turn Conversation", arXiv, 9 May 2025.
https://arxiv.org/abs/2505.06120
Anthropic Engineering, "Effective context engineering for AI agents", 29 Sep 2025.
https://www.anthropic.com/engineering/effective-context-engineering-for-ai-agents
AWS DevOps Blog (Raja SP), "AI-Driven Development Life Cycle: Reimagining Software Engineering", 31 Jul 2025.
https://aws.amazon.com/blogs/devops/ai-driven-development-life-cycle/