mem0

Store and retrieve scoped user memories across sessions with deduplication.

2|Updated Apr 10, 2026
One-click install
npx skills add https://github.com/t0lab/harness-kit --skill mem0
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: mem0
Source: https://github.com/t0lab/harness-kit/tree/main/packages/harness-kit/skills/mem0
Command: npx skills add https://github.com/t0lab/harness-kit --skill mem0

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

mem0 MCP helps teams manage long-term memory across sessions by securely storing, indexing, and retrieving relevant prior conversations to maintain continuity.

Core Features & Use Cases

  • Persistent memory across sessions: store and retrieve user-specific memories with proper scoping using user_id, agent_id, and run_id.
  • Guided memory operations: use search_memories to fetch relevant facts, add_memory to persist resolved exchanges, and get_memory/get_memories for admin/debug.
  • Use Case: When a user references past decisions or preferences, query mem0 to surface prior facts and maintain consistency.

Quick Start

To begin, search memories at the start of a turn, then store the resolved exchange with add_memory at turn end using the required user_id.

Frequently Asked Questions about mem0

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I maintain persistent memory for user conversations across different sessions?

Persistent memory for user conversations is maintained by storing resolved exchanges at the end of a turn using add_memory, then retrieving prior facts with search_memories. This requires scoping data with a specific user_id, agent_id, and run_id.

What is the best way to scope long-term agent memory for individual users?

The best way to scope long-term agent memory is by assigning unique identifiers—user_id, agent_id, and run_id—to every memory operation. This ensures that persistent context and preferences are isolated to the correct user and agent dialogue.

How does deduplicated context storage work for multi-turn dialogues?

Deduplicated context storage works by indexing relevant facts from user exchanges and filtering out redundant data before persistence. When search_memories is called, it retrieves only the unique, scoped context necessary for the current dialogue.

Can I query prior user preferences and decisions without duplicating context?

Yes, you can query prior preferences without duplication. The search_memories operation fetches relevant facts from the persistent store, automatically applying deduplication so the agent receives only unique context scoped to the user_id.

Do I need a specific user_id to add and retrieve agent memory?

Yes, a specific user_id is required to add and retrieve agent memory. Scoping with user_id, alongside optional agent_id and run_id, ensures that persistent context is securely isolated and correctly attributed during multi-turn dialogues.

When do I need to search memories during a multi-turn conversation?

You need to search memories at the start of a new turn to surface prior decisions and preferences. After resolving the exchange, you use add_memory at the turn's end to persist the new context for future recall.