Hermes Agent

How-To Guide

Share Memory Between Hermes Agents Safely

Share memory between Hermes Agent profiles or machines with an external provider, without pointing two agents at the same Hermes home or corrupting local state.

Quick answer

To share memory between Hermes agents, give every agent its own profile or HERMES_HOME, then connect the cooperating profiles to one intentionally shared namespace in an external memory provider. Never run two agents against the same ~/.hermes directory or continuously sync live state. Keep private facts in profile-scoped MEMORY.md and USER.md, share only reviewed project knowledge, and prove both recall and isolation with a two-agent test.

Multiple agents should not share one live ~/.hermes directory. Hermes deliberately scopes built-in memory and sessions to a profile because concurrent writers can merge facts, histories, and identities into state that neither agent authored. The safe pattern is separate profiles plus one intentionally shared external memory namespace for the knowledge that truly belongs to the team.

Deploy Hermes faster with FlyHermes

Managed cloud · API costs included · Skill library · Cancel anytime

Before you start:

  • Hermes Agent updated on every machine or profile
  • A separate Hermes profile or HERMES_HOME for each running agent
  • A clear list of shared knowledge versus private agent state
  • Credentials for the external provider you choose, stored in the correct profile .env

Steps

  1. 1

    Decide what should actually be shared

    Write down the small set of facts every agent needs: project conventions, approved decisions, stable user preferences, or reusable research. Keep secrets, raw transcripts, temporary task state, and private client context out of the shared pool. Use Hermes profiles for isolation first; sharing should be an explicit exception.

  2. 2

    Give every agent its own Hermes home

    Never point two running agent processes at the same HERMES_HOME or continuously sync the live ~/.hermes directory. Built-in MEMORY.md, USER.md, state.db, sessions, and provider config are profile-scoped. Create a separate profile with hermes profile create coder or a separate installation before adding shared recall.

  3. 3

    Choose one external memory provider

    Run hermes memory setup and select one provider. Hermes supports Honcho, OpenViking, Mem0, Hindsight, Holographic, RetainDB, ByteRover, and Supermemory. Only one external provider can be active per profile, and it runs alongside built-in memory. Choose by storage location, cost, identity controls, and whether multiple agents can intentionally use one workspace, bank, user, or container.

  4. 4

    Configure the same shared namespace deliberately

    Point only the cooperating agents at the same provider namespace. In Honcho, profiles can share a workspace and user peer while keeping a distinct AI peer per profile. Hindsight can use a shared bank for common knowledge or a bank_id_template such as hermes-{profile} for isolation. Supermemory can use named custom containers for shared project knowledge. Do not assume that using the same vendor automatically shares the right data.

  5. 5

    Keep local memory and shared memory separate

    Store machine paths, private preferences, and agent-specific operating rules in each profile's built-in memory. Put only cross-agent knowledge in the provider namespace. External providers are additive: they can prefetch, retain, search, or synthesize knowledge, but MEMORY.md and USER.md still load as the local frozen snapshot at session start.

  6. 6

    Verify provider status in every profile

    Run hermes memory status under each profile and confirm the intended provider is active. Then start a fresh session so the local memory snapshot and provider tools load cleanly. A successful setup wizard is not enough: verify the actual profile, provider, namespace, and storage mode on every machine.

  7. 7

    Run a two-agent acceptance test

    Have Agent A save a harmless, unique project fact to the shared provider. Start a fresh turn or session with Agent B and ask for that fact without including it in the prompt. Confirm Agent B can cite it, then save an agent-private fact locally and confirm the other agent cannot retrieve it. This tests both sharing and isolation.

  8. 8

    Add review, backup, and deletion rules

    Decide who may write, which tags or containers are allowed, how conflicts are corrected, and how provider data is exported or deleted. Enable built-in memory approval when local writes need review. Back up each profile separately with the Hermes backup guide; provider-side data may need its own export and retention policy.

Pro Tips

  • 💡Start with one shared project namespace, not a global memory pool for every bot and user.
  • 💡Use provider tags, banks, workspaces, peers, or containers to make the sharing boundary visible.
  • 💡Keep raw logs and transcripts in session history; promote only reviewed conclusions into shared memory.
  • 💡Test deletion and correction before trusting shared recall with production work.
  • 💡If you only need a one-time move, use profile export/import or a controlled backup instead of permanent shared memory.

Troubleshooting

Agent B cannot recall the fact saved by Agent A

Run hermes memory status in both profiles, verify both use the same intended provider namespace, and check whether recall is asynchronous or requires a new turn. Also confirm the fact was written to the external provider rather than only to Agent A's local MEMORY.md.

Private memories appear in the other agent

Stop writes, separate the agents into distinct profiles, and inspect the provider workspace, bank, user, peer, tag, or container mapping. Remove the leaked memory and retest both a shared fact and a private fact before resuming.

Memory duplicates or conflicts after syncing files

Stop syncing the live ~/.hermes directory. Restore each agent to a separate profile or backup, then use an external provider for intentional sharing. Two active agents must not write to one Hermes home.

The provider works in CLI but not Telegram, Discord, or a bot

The gateway or Bot may use a different profile. Verify the active profile and provider on the real channel, restart the gateway after configuration changes, and repeat the two-agent acceptance test through that surface.

FAQ

Can two Hermes agents use the same ~/.hermes directory?

No. Official Hermes guidance is one agent per Hermes home. Concurrent writers can compound each other's memory and session state. Use separate profiles and an external provider when the agents need shared recall.

Does an external memory provider replace MEMORY.md and USER.md?

No. The external provider is additive. Built-in memory remains profile-scoped and loads as a frozen snapshot at session start while the provider adds recall, extraction, search, or synthesis.

Which Hermes memory provider is best for multiple agents?

There is no universal winner. Honcho exposes workspace and peer identities, Hindsight exposes banks and templates, and Supermemory exposes containers. Choose the provider whose identity and storage model matches the sharing boundary you can test and operate.

Should I sync ~/.hermes with rsync or Syncthing?

Not while agents are running, and not as a real-time shared-memory design. Use a controlled profile backup or export for a one-time transfer. Use an external provider for ongoing cross-agent recall.

How do I know shared memory is configured correctly?

Agent B should retrieve one harmless fact written by Agent A, while failing to retrieve a different fact saved only in Agent A's local memory. Verify the active profile, provider status, namespace, and real gateway or Bot surface.

Is shared agent memory the same as session search?

No. Session search queries conversations inside one Hermes state database. Shared external memory lets separate profiles or machines retrieve knowledge from an intentionally common provider namespace.

Related setup and cost guides

Related Guides