Index Ai Academy
Glossary · Phase 10 · Agent harnesses

Compaction

Replacing the older part of a conversation with a summary, keeping recent turns, so a long task fits in the context window.

Try it now

The cut starts on a user message of tool results, so it steps back once, to the assistant message that made those calls.

Learn it properly

Managing the context window · Budgets, clearing old tool results, compaction and a cacheable prefix. About 40 minutes.

Create a free account See what's in the lesson

Other terms from the same lesson

Never trained an AI?

Teach a small one to write, right in your browser. It takes about 20 seconds and needs no account.

Teach it to write