Compaction: when to summarize an agent's history — and when it backfires
Anthropic's compaction API summarizes an agent's history when it hits a token threshold. How it works, the billing pass you don't see, and when it backfires.
3 posts in this category.
Concrete how-to guides for working with LLM APIs and tooling -- enabling prompt caching the right way, instrumenting cost telemetry, picking a model for a specific workload class. Each guide includes runnable code or commands, the exact vendor page that documents the API surface, and a date stamp that lets the reader judge how fresh the recipe is. We do not publish a how-to until it has been run against a live API at least once. The category opens empty in Phase D. The first guides will follow once the analysis catalogue covers the conceptual ground a how-to builds on.
Showing 3 of 3 posts — page 1 of 1
Anthropic's compaction API summarizes an agent's history when it hits a token threshold. How it works, the billing pass you don't see, and when it backfires.
Anthropic's context editing clears stale tool results from an agent's window, cutting token use up to 84%. How it works, the config, and the prompt-cache catch.
Caveman mode strips filler from Claude's output. The 65% headline is real for output tokens. Here's what it actually saves on your monthly bill.