Master Claude Chat, Cowork, Code

← Master Claude Chat, Cowork, Code5 oct. · 49 min

15. Prompt Caching and Durable State (The Economics of Context and Memory)

15. Prompt Caching and Durable State (The Economics of Context and Memory)5 oct.49 min

<p>In Episode 15 of <strong>Beyond Prompting</strong>, author Sho Shimoda breaks down prompt caching—the single largest cost lever in the Claude Code ecosystem—and demonstrates how to manage long-term project memory. We explore why two identical sessions can vary dramatically in cost based on how they handle cached context and how to structure state that outlives individual sessions. In this episode, we cover:</p><ul><ul><li><strong>The Three Cached Layers:</strong> How prompt caching organizes context into three ordered layers—system prompt, project context, and conversation—allowing routine turns to run at roughly a tenth of standard input costs by reading cached prefixes.</li></ul><ul><li><strong>What Discards the Cache:</strong> Unintentional actions that invalidate the cached prefix—such as switching models mid-task, changing effort levels, toggling fast mode, or connecting MCP servers on the fly—and how planning session parameters upfront avoids expensive cache rebuilds.</li></ul><ul><li><strong>Cache Lifetimes (5-Minute vs. 1-Hour TTL):</strong> How cache retention periods operate across subscription plans and usage credits, and how to configure TTL settings to match your working rhythm.</li></ul><ul><li><strong>Durable State Beyond Sessions:</strong> Why conversation history is the wrong place to store architectural history, and how to maintain version-controlled decision records (decisions.md) that agents read at session start and update upon completing tasks.</li></ul></ul><p><em>(Note for listeners: This episode covers Chapter 15 of Sho Shimoda&#39;s book </em><strong>RUNNING CLAUDE: The Operator’s Guide to Chat, Cowork and Claude Code</strong><em>, available on Amazon as the successor book to </em><strong>Master Claude: Chat, Cowork and Code</strong><em>).</em></p>