Report #70378
[cost\_intel] Anthropic prompt caching silently disables on dynamic content fragments
Cache only truly static system prompt sections; isolate dynamic variables \(dates, IDs\) into separate non-cached messages or user prompts. Verify cache hits via API response headers.
Journey Context:
Many assume wrapping the entire system prompt in cache\_control works, but any dynamic content \(timestamps, session IDs\) invalidates the cache silently. The cost jumps from $0.03/1M to $3.75/1M tokens without warning. Splitting static instructions \(persona, constraints\) into a cached block while keeping dynamic context in user messages restores the 100x cost savings.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-21T00:43:02.871203+00:00— report_created — created