Apply to my task
arXiv:2606.10209 ★ 86 Jun 8, 2026

Compact Context: Less Chat History, Better Answers

Key result

71% success with the full history versus 91.6% with a trimmed one — while using 2.7 times fewer tokens. The longer the chat, the worse the model performs, because old messages compete with new ones for attention on equal terms, creating noise instead of value. The Compact Context method lets you run long working sessions without the answers degrading. The trick: every 10-15 messages you take a snapshot — a compressed summary of the older history — and open a new chat with just the summary and the last 4-6 exchanges. The model stops getting tangled in rejected options and works more accurately, faster and cheaper all at once.

01

TL;DR

The longer a chat runs, the worse an LLM handles the task — not because it runs out of memory, but because old context gets in the way more than it helps. The researchers call this context rot: old exchanges take up room in the model's head and compete with current information, creating noise. And it turned out that trimming the history isn't enough — you need to trim + briefly summarize what you cut.

The study tested four history-management strategies on complex multi-step tasks. The main finding is counterintuitive: the full conversation history gave a worse result (71%) than a trimmed history with a short summary of older messages (91.6%). On top of that, it used 2.7 times fewer tokens and ran 2.5 times faster.

The method works on the principle of "the last N interactions in full + a compressed summary of everything else." Fresh context is needed to work precisely with the current state, and the summary keeps the model from forgetting what's already been done and where things are headed.

Want this for your own case? Apply this study to your task: AI adapts its method to what you are working on and writes the prompt.

02

Method Blueprint

(One cycle — one session. Applied manually in the chat.)

STEP 1: Run the chat as usual
       → History builds up: decisions, attempts, edits

STEP 2: Every 10-15 messages — take a "snapshot"
       → Prompt: "Compress the history: what we decided, what's done, where we're stuck"
       → Output: a compact summary (3-7 sentences)

STEP 3: Open a new chat
       → Paste: [summary] + [your last 4-6 messages + the replies]
       → Keep working with a clean, relevant history

Key principle: Summary → at the start of the new chat. Last 4-6 exchanges → after the summary. The old full history → does not carry over.

03

Example in Practice

Task: You're helping Mark Davis, the founder of a design studio, nail down the editorial policy for a new media outlet: tone, format, sections, rules. The conversation is already 40 messages long — you've discussed the design, argued about headlines several times and made 5-6 key decisions. The model is starting to contradict itself and circle back to ideas you already dropped.

Prompt to create a snapshot:

You are an editor wrapping up the results of a working session.

Read our conversation above and create a compact snapshot with this structure:

## DECISIONS MADE
[What has been finally agreed — briefly, as bullet points]

## CURRENT TASK
[What we're working on right now — 1-2 sentences]

## OPEN QUESTIONS
[What hasn't been decided yet or is still disputed]

## CONTEXT
[Key constraints, agreements, principles — whatever
is important to remember going forward]

150 words max. Facts only, no fluff.

Then — a new chat:

[Paste the snapshot above]

---
We're continuing work on the editorial policy.
[Paste the last 4-6 messages from the old chat]

Next step: [your task]

Result: The model gets a structured snapshot of the decisions made plus the 4-6 freshest exchanges. The answers get sharper: no more circling back to rejected options, no contradictions with what was already agreed, no "fuzzy" grasp of the current context.

04

Why It Works

The problem: An LLM treats all tokens in its context roughly the same — old and new have equal "rights." When a chat grows to 40+ messages, early exchanges ("Maybe we add a design section?", "No, let's skip it") keep influencing the answers just as much as the latest ones. That's context rot: the model gets "tangled up" in outdated states and rejected options.

What LLMs are good at: Compression and synthesis — the model can pull the essence out of a large volume of text and keep only what matters. That's its strong suit.

How the method uses it: We ask the model to create a "compressed snapshot" of the history itself — strip out the noise, keep the facts. Then we give it only that snapshot + the freshest context. The result is a precise, lean working memory: orientation in the task (the summary) + the current state (the latest messages).

Control knobs:

Parameter Default value How to adjust
Snapshot frequency Every 10-15 messages Short tasks — less often; iterative ones (edits, development) — more often
Summary depth 150 words Increase for complex tasks with lots of constraints
Number of old messages 4-6 pairs Decrease for speed; increase if the task depends on tone/style
Snapshot format Structured (sections) For simple tasks — a single paragraph of prose
05

Prompt Template

Step 1 — Create the snapshot

Read our conversation above and create a working snapshot.

## DECISIONS MADE
[What has been finally agreed]

## CURRENT TASK
[What we're working on]

## OPEN QUESTIONS
[What hasn't been decided yet]

## IMPORTANT CONTEXT
[Constraints, principles, agreements — everything worth remembering]

{word_count} words max. Specifics only.

Step 2 — Start a new chat

## Context from previous work
{snapshot_from_step_1}

---
## Latest messages
{last_4_6_exchanges}

---
## Let's continue
{your_next_task}

Placeholders: - {word_count} — 100-200 for regular tasks, up to 300 for complex projects - {snapshot_from_step_1} — paste the output of the first prompt - {last_4_6_exchanges} — copy the last few "you → model" pairs from the old chat - {your_next_task} — what we do next


🚀 Quick start — paste into the chat:

Here is a template for creating a working snapshot of a conversation.
Adapt it to my task: {your task}.
Ask me questions to fill in the fields.

[paste the template above]

The LLM will ask about the structure of the task and what needs to be locked in — because the snapshot has to capture exactly what's critical for continuing your specific work, not a generic checklist.

06

Limitations

⚠️ Linear tasks: If the conversation is short (under 10-15 messages) and not iterative, you don't need the method. The snapshot adds an extra step with no payoff.

⚠️ Tasks that depend on style and tone: If it matters how exactly the previous answers sounded (mimicking a voice, keeping a style), the summary may lose nuance. Carry over the latest messages in full, not just the summary.

⚠️ Details lost in the summary: A short snapshot inevitably loses something. If the task requires every detail to be reproducible (legal wording, exact figures), add to the snapshot prompt: "Numbers, dates and exact wording — verbatim."

⚠️ Studied on automated agents: The research was done on multi-step agents making dozens of tool calls, not on a manual chat. The principles carry over, but the optimal parameters (N=5 for their task) need tuning for your own context.

07

Resources

Title: Less Context, Better Agents: Efficient Context Engineering for Long-Horizon Tool-Using LLM Agents

Authors: Abhilasha Lodha, Mahsa Pahlavikhah Varnosfaderani, Abir Chakraborty, Abhinav Mithal

Organization: Microsoft

Key references from the paper: ReAct (Yao et al.), LLMLingua, MemoryBank, ACON, Model Context Protocol (MCP), Microsoft Dynamics 365 Finance and Operations

Research digest

Key result

71% success with the full history versus 91.6% with a trimmed one — while using 2.7 times fewer tokens. The longer the chat, the worse the model performs, because old messages compete with new ones for attention on equal terms, creating noise instead of value. The Compact Context method lets you run long working sessions without the answers degrading. The trick: every 10-15 messages you take a snapshot — a compressed summary of the older history — and open a new chat with just the summary and the last 4-6 exchanges. The model stops getting tangled in rejected options and works more accurately, faster and cheaper all at once.

Principle

The researchers named the problem context rot. The model can't tell important context from outdated junk on its own. A token from message 40 carries the same weight in its eyes as a token from message 4. So a 40+ message chat is like a desk buried in drafts: new decisions get lost among the old ones. The rule: don't drag the whole history along — compress the old part into a snapshot and keep the fresh part as is. Just trimming doesn't work — the model loses track of what's already been done. Just summarizing without trimming — the noise stays. Only the "summary + latest messages" combo delivers the jump from 71% to 91.6%.

Why it works

There's one thing LLMs do well: compress and synthesize. That's exactly what we ask for — have the model build a compact snapshot of the history itself, stripping out the noise and keeping the facts. The snapshot clears the drafts off the desk and leaves only the results plus whatever matters right now. Then we hand over that snapshot and the freshest exchanges. The result is a precise working memory: orientation in the task via the summary and the current state via the latest messages. You're working with the model's strength, not against its weakness.

When to apply

Long iterative sessions → editing copy, strategy discussions, development with lots of revisions, research — especially when the chat has passed 15-20 messages and the model starts contradicting itself or returning to options already rejected. NOT suitable for: short sessions under 10-15 messages — an extra step with no payoff. Also be careful with tasks where precise tone and style matter — the summary can lose the author's voice.

Mini recipe

1. Run the chat as usual — until you feel the model "drifting" or you hit 15+ messages. 2. Take a snapshot: paste this prompt into the same chat: `Read our conversation and create a snapshot: ## DECISIONS MADE [what has been finally agreed] ## CURRENT TASK [what we're working on] ## OPEN QUESTIONS [what's undecided] ## IMPORTANT CONTEXT [constraints, principles, agreements]. 150 words max, facts only.` 3. Open a new chat: paste the snapshot → then paste the last 4-6 message pairs from the old chat → add the next task. 4. Repeat every 10-15 messages in the new chat.

Examples

[BAD]: You keep going in a 50-message chat about editorial policy — and the model once again suggests a section that was rejected back at message 20. [GOOD]: `Read our conversation and create a snapshot. ## DECISIONS MADE [what's agreed] ## CURRENT TASK [what we're working on] ## OPEN QUESTIONS [what's undecided] ## IMPORTANT CONTEXT [constraints and principles]. 150 words max, facts only, no fluff.` → You get a compact summary → Paste it into a new chat along with the last 4-6 exchanges → The model stops circling back to rejected ideas and stops contradicting what was agreed.

In plain words

Models have a critical bug: the longer you talk to them, the dumber they get. It's not about running out of memory — it's a problem of context rot (the chat history quietly going bad). The gist: an LLM treats the entire conversation history as one undifferentiated mush. Old ideas you abandoned ten messages ago keep pressing on the model just as hard as fresh input. The agent ends up contradicting itself, circling back to rejected options and simply losing focus as it tries to please everyone at once.

It's like planning a vacation with a friend for two hours straight: first you wanted the mountains, then you changed your minds and picked the beach, and at the very end he suddenly asks whether you packed the tent. Technically he remembers the start of the conversation, but in practice that old context only gets in the way of deciding things here and now. The model turns into that "forgetful friend" who can't clear the clutter out of his head, so current information drowns in the noise of past iterations.

To fix the chaos, the researchers propose efficient context engineering. Just chopping off the chat history is a bad idea — you lose important details. What works is a combo: aggressive trimming plus summarization. You throw out tons of intermediate junk (arguments, clarifications, mistakes) but keep the bottom line as a short recap. That lets the model hold only the final states and the decisions made in its "working memory," without getting distracted by the process of debating them.

The principle is universal: it works in programming, in long back-and-forths over editorial policy and in complex business tasks. It was tested on tool-using agents, where mistakes are costly, but the logic applies everywhere. If your ChatGPT thread has passed 40 messages and the model has started messing up, it's time for a forced cleanup. Instead of feeding the model the whole wall of text, feed it only the results of the previous stages. Less context, more getting things done.

Bottom line: it's time to admit that long memory isn't a gift for AI — it's a curse that turns a smart assistant into a cranky grandpa. Want a sane result? Cut the history without mercy, keeping only a distillation of the key facts. Either you manage the context, or the context starts managing your time and turns your work into an endless loop of corrections. Clean context beats long context 10 times out of 10.

AI lab assistant

Apply this study to your task

Describe what you're working on. AI takes the method and the measured results from this paper and adapts them to your case, or writes a ready prompt built on them.

Based on Compact Context: Less Chat History, Better Answers arXiv:2606.10209

Sign in to apply this study New accounts get 50 free credits.