hermes-agent/plugins/memory/mem0
buihongduc132 b6d2ac176e feat(mem0): add self-hosted support via MEM0_HOST / host config
The mem0 plugin previously hardcoded api.mem0.ai as the endpoint.
This adds a `host` config key and MEM0_HOST env var so users can
point the plugin at a self-hosted Mem0 instance.

Changes:
- _load_config(): read MEM0_HOST env var
- is_available(): accept host OR api_key (self-hosted may not need a real key)
- get_config_schema(): add host field
- initialize(): read host from config
- _get_client(): pass host kwarg to MemoryClient when set
- system_prompt_block(): show target (cloud vs URL)
- README: document self-hosted setup
2026-06-21 17:28:02 -07:00
..
__init__.py feat(mem0): add self-hosted support via MEM0_HOST / host config 2026-06-21 17:28:02 -07:00
plugin.yaml feat(memory): pluggable memory provider interface with profile isolation, review fixes, and honcho CLI restoration (#4623) 2026-04-02 15:33:51 -07:00
README.md feat(mem0): add self-hosted support via MEM0_HOST / host config 2026-06-21 17:28:02 -07:00

Mem0 Memory Provider

Server-side LLM fact extraction with semantic search, reranking, and automatic deduplication.

Supports both Mem0 Cloud and self-hosted instances.

Requirements

  • pip install mem0ai
  • Mem0 Cloud API key or a self-hosted Mem0 server

Setup

Cloud

hermes memory setup    # select "mem0"

Or manually:

hermes config set memory.provider mem0
echo "MEM0_API_KEY=your-key" >> ~/.hermes/.env

Self-Hosted

hermes config set memory.provider mem0
echo "MEM0_HOST=http://your-mem0-server:24220" >> ~/.hermes/.env
echo "MEM0_API_KEY=your-api-key" >> ~/.hermes/.env   # if auth is enabled

Config

Config file: $HERMES_HOME/mem0.json

Key Default Description
api_key API key (required for cloud; optional for self-hosted without auth)
host https://api.mem0.ai Self-hosted Mem0 URL. When set, overrides the cloud endpoint.
user_id hermes-user User identifier
agent_id hermes Agent identifier
rerank true Enable reranking for recall

Tools

Tool Description
mem0_profile All stored memories about the user
mem0_search Semantic search with optional reranking
mem0_conclude Store a fact verbatim (no LLM extraction)