AWS explains prompt caching for OpenAI models on Amazon Bedrock to lower agent costs
The AWS Machine Learning Blog has published a guide to prompt caching for OpenAI models on Amazon Bedrock, aimed at AI agents that carry out multi-step tasks. The method is presented as a way to reduce input cost and latency by letting an agent reuse context it has already processed.
Why agents reread their full context
The blog describes how each step an agent takes, such as calling a tool, reading the result and choosing its next move, requires sending the model its complete history so far. That history includes the tool definitions, the instructions, every earlier tool call and every result.
According to the post, the model predicts only the next token from the input it receives and keeps no internal memory between requests, so the full context must be processed again on every turn.
How the caching service reuses saved input
The service keeps the input prompt, covering instructions, tools and content, and applies it again to the following request at a reduced input price. The blog outlines a typical first call as made up of a tool list, instructions, session history and the newest turn, with the history expanding at every step.
Technically, the model first processes each input token in a stage called prefill, building the key and value vectors that form its working state. Prompt caching stores that state, so when a later request begins with the same input tokens, the service loads it instead of recalculating it and handles only the new material.