Skills
Cut agentic token spend with server-side tool-result clearing — and use clear_at_least to protect your prompt cache
Claude's context-editing beta (clear_tool_uses_20250919) auto-drops the oldest tool results once a token trigger is hit, replacing them with placeholders — a documented example falls from 70k to 25k input tokens (~64%). The non-obvious knob is clear_at_least: clearing invalidates the cached prefix, so set a minimum clear size (e.g. 5k tokens) so you only break cache when the savings are worth it, and exclude_tools to protect results you still need.
↳ Follow the thread