aboutsummaryrefslogtreecommitdiff
path: root/packages/tools/README.md
diff options
context:
space:
mode:
Diffstat (limited to 'packages/tools/README.md')
-rw-r--r--packages/tools/README.md1
1 files changed, 1 insertions, 0 deletions
diff --git a/packages/tools/README.md b/packages/tools/README.md
index c0308141..e859ede7 100644
--- a/packages/tools/README.md
+++ b/packages/tools/README.md
@@ -58,6 +58,7 @@ const addTool = addMemoryTool(process.env.SUPERMEMORY_API_KEY!, {
- `withSupermemory` will take advantage supermemory profile v4 endpoint personalized based on container tag
- You can provide the Supermemory API key via the `apiKey` option to `withSupermemory` (recommended for browser usage), or fall back to `SUPERMEMORY_API_KEY` in the environment for server usage.
+- **Per-turn caching**: Memory injection is cached for tool-call continuations within the same user turn. The middleware detects when the AI SDK is continuing a multi-step flow (e.g., after a tool call) and reuses the cached memories instead of making redundant API calls. A fresh fetch occurs on each new user message turn.
```typescript
import { generateText } from "ai"