← Home

Guide

Hermes Agent Multi-Agent: Subagents, Profiles, Kanban and A2A

“Multi-agent” covers several different things in Hermes Agent. One agent can split a task across temporary subagents. Separate long-lived agents can share a work board. And agents on different machines can message each other. They solve different problems, so this guide takes them one at a time.

Pick the Right Pattern

  • Subagents (delegate_task) — one agent fans a big job out to parallel workers and merges the results. No setup.
  • Profiles — separate agents, each with its own personality, memory, skills, model and bot token, on one machine.
  • Kanban — those profiles hand tasks to each other on a shared board, with review and blocking.
  • hermes peer — one Hermes messages another Hermes on a different machine.
  • A2A — Hermes talks to agents on other frameworks that expose a compatible Agent-to-Agent (A2A) JSON-RPC interface.

1. Subagents with delegate_task

Every Hermes agent has a delegate_task tool that spawns subagents in isolated contexts. Each subagent works on its own slice and returns a summary, so the parent's context stays small. Ask for it in plain language (“research these five competitors in parallel and compare them”) and the agent decides when to delegate. Tune it under delegation in ~/.hermes/config.yaml:

delegation:
  model: ""                  # empty = same model as the parent
  provider: ""               # empty = same provider and credentials
  max_concurrent_children: 10
  max_spawn_depth: 1         # 1 = flat, 2 = orchestrator -> workers
  max_iterations: 250
  child_timeout_seconds: 0   # 0 = no per-child timeout

The most useful knob is model: point subagents at a cheaper, faster model and keep the strong one for the parent that plans and merges. Raise max_spawn_depth to 2 only if you want subagents that delegate again.

2. Separate Agents with Profiles

A profile is a complete, separate Hermes agent: its own config.yaml, .env, SOUL.md, skills, memory and sessions. Create one by cloning the agent you already have:

hermes profile create researcher --clone   --description "Finds and checks sources"   # used by kanban routing
hermes profile list
hermes -p researcher chat                    # talk to it
hermes -p researcher gateway install --start-now   # run its own bot

--clone copies setup but not history, and leaves out messaging channels unless you add --clone-channels. That default is deliberate: two profiles polling the same Telegram token conflict, so give each agent its own bot. The --description matters later: kanban uses it to route tasks by role rather than by profile name.

3. Coordinating Agents with Kanban

Kanban is Hermes's multi-profile collaboration board. Its tools are opt-in: enable the kanban toolset for the platform with hermes tools first. Tasks have an assignee profile, parent and child links, comments and a review column. Agents work it through tools such as kanban_create, kanban_list, kanban_comment, kanban_block and kanban_complete, and you drive it with the /kanban command (init, create, assign, list, show and more).

A dispatcher inside the gateway picks up assigned tasks and spawns the assigned profile as a worker. That gives you pipelines like researcher → writer → reviewer, with each stage a different agent. The dispatcher deliberately slows down when the machine is short on memory, so on a small box expect workers to start one at a time.

4. Agents on Different Machines: hermes peer

hermes peer sends a message to another Hermes gateway over its API server and prints the reply — the cross-machine version of hermes -p <bot> chat. The remote side must have the API server enabled. Register it with the remote's API_SERVER_KEY:

hermes peer add homelab --url http://homelab.lan:8642 --key <their API_SERVER_KEY>
hermes peer dm homelab "Disk usage on the NAS?"
hermes peer dm homelab/researcher "..."      # a named profile on that peer

# long tasks: start, check, stop
hermes peer run homelab < long-task.txt
hermes peer status homelab <run_id>
hermes peer stop homelab <run_id>

The key is saved to ~/.hermes/.env. Typing it literally after --key can still leave it in your shell history.

5. Any Framework: the A2A Protocol

Hermes bundles an A2A platform plugin that implements the open Agent-to-Agent protocol v1.0 in both directions. Its peers can be another Hermes, or agents built with LangChain, CrewAI, Google ADK or OpenClaw, as long as they expose a compatible A2A JSON-RPC interface. Enable it with hermes gateway setup and pick A2A.

  • Inbound: Hermes publishes an Agent Card at /.well-known/agent-card.json on port 9900 and accepts A2A tasks into its live session. With no token it binds to localhost only. Set A2A_PEER_TOKENS (one credential per remote agent) or A2A_BEARER_TOKEN before widening A2A_HOST.
  • Outbound: list the agents you want to call under a2a_agents in config.yaml and enable the a2a toolset (it is off by default). The agent then gets a2a_discover, a2a_call, a2a_list, a2a_history and a2a_orchestrate, the last of which fans one task out to every configured peer whose capabilities list includes the one you ask for.
a2a_agents:
  researcher:
    url: "http://localhost:9999"
    auth: { type: bearer, token: "sk-..." }
    timeout: 120
    capabilities: [web_search, research]

Incoming A2A text runs through prompt-injection filters and is framed as untrusted peer input, so a remote agent cannot run your slash commands. Two agents also cannot ping-pong endlessly in one conversation: A2A_MAX_PINGPONG_TURNS caps it at 5 inbound turns per conversation by default (the count resets when a new conversation starts or the gateway restarts).

Practical Advice

  • Start with delegate_task. Most “I need several agents” problems are really one agent doing parallel work.
  • Use profiles when the agents need different personalities, memory or permissions — not just different prompts.
  • Every agent spends tokens. A fan-out of ten subagents on a frontier model costs about ten times as much. Set delegation.model to something cheap.
  • Give agents that talk to strangers (A2A, public bots) the smallest toolset that does the job.

On OpenClaw Launch

Each managed Hermes bot on OpenClaw Launch is its own agent with its own bot token, and subagents work inside it out of the box. To connect two of your bots, turn on Use in Another App for the one being called. The other bot can then register it with hermes peer add, using the Bot-to-bot URL and API key shown there, and message it with hermes peer dm. The long-task commands (run, status, stop) and named-profile routing are not available through that endpoint.

On OpenClaw

OpenClaw runs multiple agents differently: specialist agents that consult each other inside one gateway. See OpenClaw Agent-to-Agent Communication. Because Hermes speaks A2A, a Hermes agent and an A2A-capable agent on another framework can work together.

Frequently Asked Questions

Does Hermes Agent support multiple agents?

Yes, in several ways: parallel subagents through delegate_task, separate agents as profiles, a kanban board that coordinates profiles, hermes peer across machines, and the A2A protocol for agents on other frameworks.

How many subagents can Hermes run at once?

Each delegation runs up to delegation.max_concurrent_children subagents in parallel, 10 by default. By default subagents cannot spawn their own subagents (max_spawn_depth: 1).

Can Hermes talk to agents that are not Hermes?

Yes, through the bundled A2A plugin, which implements the open Agent-to-Agent protocol v1.0. An agent on another framework can be a peer if it exposes a compatible A2A JSON-RPC interface.

Is this the same as OpenClaw agent-to-agent?

No. OpenClaw has its own multi-agent model. This guide is about Hermes; the OpenClaw guide is linked above.

Related Guides

Run an Agent Team Without the Servers

Deploy as many managed Hermes bots as you need on OpenClaw Launch, each with its own memory and bot.

Deploy Managed Hermes