Tinker Context engineering & memory

by Samy (Kondasamy Jayaraman)

Nothing sent yet.window empty, budget 8,000 tokens

Chapter 4 of 7

Order for the cache

Every question in a conversation re-sends the tools, instructions, documents and history. Most of it matches the last call.

This chapter: How can Larkspur stop paying full price for the same text every call?

About this chapter

You will learn

  • Prompt caching: reusing the start of a recent call’s input
  • Why one changing line near the top throws the rest away
  • How to order a turn so the stable parts come first

Words you’ll meet

Prompt caching
The provider keeps the start of a recent input; a call that begins the same way reads it back at a fraction of the price.
Prefix
The start of the input, up to some point. A cache hit needs the prefix to match exactly.
Cache breakpoint
A mark the host puts after a part, saying “cache everything up to here”.
Cache hit
Tokens read back from the cache instead of being sent fresh.

Step 1 of 4

keeps a call’s start, its , and reads it back cheaply if the next call begins the same way.

Send the conversation.