Is it possible to use agent + caching ? #9539
Replies: 2 comments
-
|
Hi @TheUncharted 👋 There isn’t a first-class “agent cache” flag today. The Agent is just orchestrating model/tool calls, so you add caching at your app layer—exactly like generateText—and/or cache tool results. (Bedrock itself doesn’t provide response caching.) **Where to cache
2. Tool-level caching (often biggest win) 3. Streamed agents Tips
TL;DR: No built-in agent cache switch; wrap the agent call and (especially) your tools with your store (KV/Redis). That gives you the same wins you saw with generateText, now across the whole agent flow. |
Beta Was this translation helpful? Give feedback.
-
|
This discussion was automatically locked because it has not been updated in over 30 days. If you still have questions about this topic, please ask us at community.vercel.com/ai-sdk |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
Hi
I'm using the Aws Bedrock Provider and the caching is working well with generateText in the example.
But I saw no option for caching for the agent : does this option exists ?
Beta Was this translation helpful? Give feedback.
All reactions