ResearchPublication
Context compression for production AI agents
A post of May 2026 on ARC, built for toqan. It keeps every turn of a long conversation, sums the history up in typed fields, and lets the agent fetch an older turn when the summary does not hold enough.

Where this comes from
This is a post on the Prosus AI Tech Blog, written by Pradyut Nair and Isha Agrawal and published on 8 May 2026. It is about toqan, which the post calls the platform where teams across the Prosus group build and deploy AI agents, and about how it keeps a long conversation within what a model can read. What follows is from the post.
What the post asks
Conversations in toqan regularly run past 100,000 tokens. When the context window fills up, toqan condenses the history into one summary so that the agent can go on. That serves a simple follow-up. A question about a specific figure, a calculation or a file from earlier in the conversation fails. To keep every turn relevant, the authors built ARC, short for Abstracted Record of Context.
How ARC works
ARC puts three operations where there was one summary, in a design the post says follows Factory.ai’s structured summaries that persist.
Ingest
Every interaction is saved to a database in the background, so the conversation never waits for it.
Summarize
When the conversation has to be condensed, ARC builds a structured summary that rolls on with it.
Select
An optional tool fetches the older interactions that bear on the question.
The summary is written in typed fields, which make the summarizer keep what a summary in prose drops: exact numbers, the details of files, and pointers the agent can act on. /select is offered to the model as a tool: the model decides whether the summary has enough detail, and when it has not, it fetches the older interactions it needs.
| Field | What it keeps |
|---|---|
| session_intent | Why the conversation exists, and what success looks like |
| play_by_play | What happened in order, with what caused what |
| artifact_trail | Concrete outputs: results of tools, files, generated content |
| data_snapshot | Numbers, IDs and status codes, word for word |
| breadcrumbs | Cheap pointers for fetching things again: IDs, paths, names of tools |
| key_decisions | Commitments the agent must keep |
| topic | A label of one line |
How it was tested
Four methods answered 41 turns that came after a condensation, from 65 real conversations in toqan: the baseline, toqan’s previous compression, which compresses the whole history once it fills 70% of the model’s context window; ARC from its summary alone; ARC with Select; and Bear 1.2, a commercial compression model of The Token Company. A language model, GPT-5.2, scored every answer from 1 to 5 on accuracy, completeness, how far it helps the user, and awareness of what was said before.
What it found
- overall score of ARC with Select over the baseline
- +17.0%
- its overall score over Bear 1.2, the best alternative
- +7.6%
- turns on which the model chose to call /select
- 8 of 41
- the extra cost of one compression event with ARC
- $0.012
Bear 1.2, at one setting, also scored above the baseline, which shows that even basic compression helps. ARC did better still, which the post puts down to its structure: it pulls out the right information as well as removing what repeats. The few turns on which the model called /select are the ones where the baseline failed hardest. In one, the user asked how a percentage given earlier had been worked out: the summary had kept the conclusion and dropped the table behind it, and ARC with Select fetched the interaction that held the table and worked the figure out again.
A needle in a haystack
To test longer contexts, the authors put one short fact, such as an invoice number or a launch date, into a context of 20 thousand to 128 thousand tokens, at depths from a tenth to nine tenths of the way through, and asked each method to keep it through compression: 250 cases for each method.
- of the facts kept by ARC with Select
- 93.6%
- kept by ARC alone
- 75.6%
- kept by Bear 1.2
- 50.8%
- kept by the baseline
- 25.6%
From 75 thousand tokens the baseline failed on most of the grid, and Bear 1.2 fell away sharply as the fact lay deeper in a long context. ARC with Select stayed strong almost everywhere: when the summary fell short, retrieval brought back the exact interaction that held the fact. ARC’s summary also takes less time than the baseline’s condensation, and is made in the background, so the user does not wait for it.
What the authors take from it
- The return is favorable for the small extra cost of each compression.
- Typed fields make the summarizer keep the information users come back to ask about.
- Fetching older turns only when needed is cheap insurance. In the post’s words, “The agent can identify and fill its own context gaps.”
- The findings are limited by the size of the sample, by few commercial methods to compare with, and by no test of each field on its own. The authors plan to compare more methods on more benchmarks.
The post
Context Compression for Production AI AgentsPradyut Nair, Isha Agrawal. Prosus AI Tech Blog, 2026Authors
Pradyut Nair
Isha Agrawal
References
- Context Compression for Production AI AgentsPradyut Nair, Isha Agrawal. Prosus AI Tech Blog, Medium, 8 May 2026
- Evaluating Context Compression for AI AgentsFactory.ai Research, the approach the post says its design and evaluation follow