Hermes Atlas
Messaging bridges & gateways

hermes-multitenancy

eggyrooch-blip/hermes-multitenancy

Routes each Feishu user to their own Hermes profile from one shared bot

In short

hermes-multitenancy is a hermes-agent plugin that lets a single Feishu bot serve many users, each with an isolated Hermes profile. It suits teams that want per-person persona, memory and credentials without running one gateway process per user.

What hermes-multitenancy does

Hermes Agent assumes one bot serves one user. This plugin changes that by registering a pre_gateway_dispatch hook that resolves each Feishu sender and dispatches the message into that person's own ProfileRuntime, a sandboxed per-profile subprocess. Every user gets an independent SOUL.md, memory, session history, workspace, tools and LLM credentials. Routing, sessions and a credential vault live in a SQLite database at ~/.hermes/multitenancy.db. The plugin ships as a directory plugin and does not patch hermes-agent.

A pull-feishu sync reads the Feishu Contact directory, so new employees get a profile and route and departures are soft-deleted from routing while their memory stays on disk. A per-turn token ledger attributes usage to owners for a leaderboard, and a conversation-analytics CLI reports on demand and completion. Feishu features such as CardKit streaming cards, reactions, group chat and cron delivery are reused from hermes-agent, and a group @everyone never triggers the bot. The README is available in English and Simplified Chinese.

Key features

  • Per-user routing to separate profiles with their own SOUL.md, memory, sessions and credentials
  • Runs through the pre_gateway_dispatch hook without changes to hermes-agent
  • Org sync from the Feishu Contact directory for joins, moves and departures
  • Per-profile HOME, XDG and TMPDIR separation and a subprocess environment allowlist
  • Token ledger with owner-based usage attribution
  • Feishu OpenAPI access through a lark-cli bridge

When to use it

  • Give every employee in a Feishu organization a private Hermes agent behind one company bot
  • Track token usage per person across their chats, groups and agents
  • Keep a departed employee's agent memory on disk while removing their routing

Who it is for: Teams and operators who run Hermes Agent on Feishu and need one bot to serve many people with separate agents.

How it fits with Hermes Agent

A plugin for Hermes Agent that uses the gateway's pre_gateway_dispatch hook and leaves the upstream core untouched.

FAQ

What is hermes-multitenancy?

hermes-multitenancy is a plugin for hermes-agent that routes each Feishu user to their own Hermes profile, so one bot can act as many isolated agents with separate persona, memory, sessions and credentials.

Does hermes-multitenancy work with Hermes Agent?

Yes. It is built as a directory plugin that hooks into the Hermes gateway through pre_gateway_dispatch, and the README says it requires no changes to the hermes-agent code.

Is hermes-multitenancy free and open source?

Yes. The repository is published under the MIT license.

Similar messaging for Hermes Agent

All messaging

Related guides: How to run Hermes Agent securely · Run multiple Hermes agents with profiles