📢 Announcing our research paper: Zentry achieves 26% higher accuracy than OpenAI Memory, 91% lower latency, and 90% token savings! Read the paper to learn how we're revolutionizing AI agent memory.
Integrate Zentry’s memory capabilities with OpenAI’s Agents SDK to create AI agents with persistent memory.
You can create agents that remember past conversations and use that context to provide better responses.
memory_agent = Agent[ZentryContext]( name="Memory Assistant", instructions="""You are a helpful assistant with memory capabilities. You can: 1. Store new information using add_to_memory 2. Search existing information using search_memory 3. Retrieve all stored information using get_all_memory When users ask questions: - If they want to store information, use add_to_memory - If they're searching for specific information, use search_memory - If they want to see everything stored, use get_all_memory""", tools=[add_to_memory, search_memory, get_all_memory],)
User: Remember that my favorite color is blueAgent: Calling a toolAgent: Tool call output: Stored message: my favorite color is blueAgent: I've stored that your favorite color is blue in my memory. I'll remember that for future conversations.
User: What's my favorite color?Agent: Calling a toolAgent: Tool call output: my favorite color is blueAgent: Your favorite color is blue, based on what you've told me earlier.
User: What do you know about me?Agent: Calling a toolAgent: Tool call output: favorite color is bluemy birthday is on March 15Agent: Based on our previous conversations, I know that:1. Your favorite color is blue2. Your birthday is on March 15