One line in your system prompt is silently killing your prompt cache hits

Arindam_1729 · x · 2026-11-02

Arindam highlights a common agent performance trap: embedding a dynamic timestamp in your system prompt (like f"Current time: {datetime.now()}") destroys prompt caching.

Why it breaks

Other things that quietly break caching

The fix: stable stuff first, volatile stuff last — put the date in the newest user message, not the system prompt. His companion article 'Cached Tokens, Clearly Explained' details why agent loops keep paying for the same prompt prefix.

Original post →

More from coding & agent

coding & agent channel →