context editing
Removing stale content, such as old tool results, from a conversation's context before the next call.
In more detail
Clearing old tool results is the cheapest way to shrink a long agent conversation, since they are bulky and rarely needed again. Anthropic offers it as a server-side feature that clears by rule while keeping the tool calls themselves.
Related terms
- context compaction — Replacing older turns of a long conversation with a model-written summary so the history fits the context again.
- tool result — The message your code sends back after running a tool call, matched to it by id, which the model reads before continuing.
Taught in
- Memory And Compaction — AI Engineering: LLM Apps, RAG & Agents