Mem0

Mem0 é um sistema poderoso de gerenciamento de memória projetado especificamente para agentes de IA. Ele fornece um repositório de memória persistente e pesquisável que permite aos agentes lembrar interações passadas, aprender com experiências e manter contexto entre conversas e execuções de workflows.

Com o Mem0, você pode:

  • Armazenar memórias do agente: Salvar histórico de conversas, preferências do usuário e contexto importante
  • Recuperar informações relevantes: Usar busca semântica para encontrar as interações passadas mais relevantes
  • Construir agentes contextuais: Permitir que seus agentes referenciem conversas anteriores e mantenham continuidade
  • Personalizar interações: Adaptar respostas com base no histórico e nas preferências do usuário
  • Implementar memória de longo prazo: Criar agentes que aprendem e se adaptam ao longo do tempo
  • Escalar o gerenciamento de memória: Atender às necessidades de memória de múltiplos usuários e workflows complexos

No Zoen, a integração com o Mem0 permite que seus agentes mantenham memória persistente entre execuções de workflows. Isso possibilita interações mais naturais e contextuais, em que os agentes podem relembrar conversas passadas, lembrar preferências do usuário e construir sobre interações anteriores. Ao conectar o Zoen ao Mem0, você pode criar agentes com capacidade mais humana de lembrar e aprender com experiências passadas. A integração oferece suporte a adicionar novas memórias, pesquisar memórias existentes de forma semântica e recuperar registros específicos. Essa capacidade de gerenciamento de memória é essencial para construir agentes sofisticados que mantêm contexto ao longo do tempo, personalizam interações com base no histórico do usuário e melhoram continuamente o desempenho por meio do conhecimento acumulado.

Usage Instructions

Integrate Mem0 into the workflow. Can add, search, and retrieve memories.

Actions

mem0_add_memories

Add memories to Mem0 for persistent storage and retrieval

Input

ParameterTypeRequiredDescription
userIdstringYesUser ID associated with the memory (e.g., "user_123", "alice@example.com")
messagesjsonYesArray of message objects with role and content (e.g., [{"role": "user", "content": "Hello"}])
apiKeystringYesYour Mem0 API key

Output

ParameterTypeDescription
messagestringStatus message for the queued memory processing job
statusstringProcessing status returned by Mem0
event_idstringEvent ID for polling memory processing status

mem0_search_memories

Search for memories in Mem0 using semantic search

Input

ParameterTypeRequiredDescription
userIdstringYesUser ID to search memories for (e.g., "user_123", "alice@example.com")
querystringYesSearch query to find relevant memories (e.g., "What are my favorite foods?")
limitnumberNoMaximum number of results to return (e.g., 10, 50, 100)
apiKeystringYesYour Mem0 API key

Output

ParameterTypeDescription
searchResultsarrayArray of search results with memory data and similarity scores
idstringUnique identifier for the memory
memorystringThe content of the memory
user_idstringUser ID associated with this memory
agent_idstringAgent ID associated with this memory
app_idstringApp ID associated with this memory
run_idstringRun/session ID associated with this memory
hashstringHash of the memory content
metadatajsonCustom metadata associated with the memory
categoriesjsonAuto-assigned categories for the memory
created_atstringISO 8601 timestamp when the memory was created
updated_atstringISO 8601 timestamp when the memory was last updated
scorenumberSimilarity score from vector search
idsarrayArray of memory IDs found in the search results

mem0_get_memories

Retrieve memories from Mem0 by ID or filter criteria

Input

ParameterTypeRequiredDescription
userIdstringYesUser ID to retrieve memories for (e.g., "user_123", "alice@example.com")
memoryIdstringNoSpecific memory ID to retrieve (e.g., "mem_abc123")
startDatestringNoStart date for filtering by created_at (e.g., "2024-01-15")
endDatestringNoEnd date for filtering by created_at (e.g., "2024-12-31")
limitnumberNoMaximum number of results to return (e.g., 10, 50, 100)
pagenumberNoPage number to retrieve for paginated list results
apiKeystringYesYour Mem0 API key

Output

ParameterTypeDescription
memoriesarrayArray of retrieved memory objects
idstringUnique identifier for the memory
memorystringThe content of the memory
user_idstringUser ID associated with this memory
agent_idstringAgent ID associated with this memory
app_idstringApp ID associated with this memory
run_idstringRun/session ID associated with this memory
hashstringHash of the memory content
metadatajsonCustom metadata associated with the memory
categoriesjsonAuto-assigned categories for the memory
created_atstringISO 8601 timestamp when the memory was created
updated_atstringISO 8601 timestamp when the memory was last updated
idsarrayArray of memory IDs that were retrieved
countnumberTotal number of memories matching the filters
nextstringURL for the next page of results
previousstringURL for the previous page of results

On this page