What you can do
- Pull user profiles and relevant memories before an agent runs
- Store agent outputs and decisions for future sessions
- Give agents tools to search and add memories on their own
Setup
Install the packages:Get your Supermemory API key from console.supermemory.ai.
Basic integration
The simplest approach: fetch user context and pass it in the agent’s instructions.Core concepts
User profiles
Supermemory keeps two buckets of user info:- Static facts: Stuff that doesn’t change much (preferences, job, expertise)
- Dynamic context: What they’re working on right now
Storing memories
Save agent interactions so future sessions have context:Searching memories
Look up past interactions before running an agent:Adding memory tools to agents
You can give agents direct access to memory operations. They’ll decide when to search or store information.Example: support agent with memory
A support agent that knows who it’s talking to. Past tickets, account info, communication preferences - all available without the customer repeating themselves.Multi-agent handoffs with shared memory
Agents handing off to each other usually lose context. Not if they’re sharing a memory store.Metadata for filtering
Tags let you narrow down searches later:Related docs
User profiles
How automatic profiling works
Search
Filtering and search modes
OpenAI SDK
Function calling with the regular OpenAI SDK
LangChain
Memory for LangChain apps