Mem0 AI Tools icon

Mem0 AI Tools

Provides Mem0 memory tools (search, add, get, delete) to an AI Agent node

Mem0 AI Tools

AI-generated

Summary

Supply DynamicStructuredTool instances for Mem0 memory operations to an n8n AI Agent

Inputs

None.

Output shape

Array of DynamicStructuredTool instances via the 'ai_tool' output connector. Each tool carries a name, description, JSON schema, and async function that executes the corresponding Mem0 API request and returns the response as a JSON string.

When the node runs as a regular trigger (execute()), it returns [{ json: { message: 'Mem0 AI Tools node is connected to an AI Agent. Use it by connecting the ai_tool output to an AI Agent node.', enabledTools: [...] } }.

Examples

Example 1: Search memories

Enable 'Search Memory' in 'Tools to Enable', set 'Top K' if needed. The AI Agent will invoke mem0_search_memory with a JSON argument { query: '...', ... } matching the tool's schema.

Example 2: Add a memory

Enable 'Add Memory'. The AI Agent calls mem0_add_memory with { content: '...', role: 'user' | 'assistant', ... }.

Example 3: Delete a memory

Enable 'Delete Memory'. The AI Agent must provide { memory_id: '...' } as required by the tool schema.

Links

Discussion