AaronWong1999/hermesclaw
Run Hermes Agent and OpenClaw on the same WeChat account
HermesClaw – Run Multiple WeChat‑linked LLM bots together
What it does
HermesClaw is a tiny Python proxy that lets a single WeChat account talk to three different AI agents at the same time:
- Hermes Agent (Nous Research)
- OpenClaw (the “lobster” assistant)
- OpenCode (code‑focused LLM, e.g. MiniMax M2.5 Free)
WeChat only allows one iLink connection per account, so normally you can run either Hermes Agent or OpenClaw, never both. HermesClaw becomes the sole iLink poller and forwards each incoming message to the appropriate local proxy (or ACP bridge for OpenCode). With simple slash commands you can switch the active bot, or have two/three bots reply together.
Why you might want it
- Combine strengths – let Hermes handle general chat while OpenClaw answers specific queries, or let OpenCode do code‑related tasks.
- Voice‑to‑code – send a WeChat voice message, HermesClaw forwards the transcription to OpenCode, which can generate or edit code.
- One‑click switching –
/hermes,/openclaw,/opencode,/both,/threechange the routing instantly. - No code changes in the original agents – the proxy only forwards raw iLink messages; each agent still does its own media decryption, formatting, and LLM calls.
How it works (high‑level)
iLink API ←→ HermesClaw (sole poller)
│ │ │ │
│ ├─ Proxy A (19999) → OpenClaw gateway
│ ├─ Proxy B (19998) → Hermes gateway
│ └─ ACP bridge → OpenCode subprocess
│
└─ Raw iLink messages (text, voice transcription, image/video URLs, etc.)
HermesClaw listens for messages, looks at the command prefix, and forwards the payload to the selected proxy. Replies are sent back to WeChat with a small tag ([Hermes Agent], [OpenClaw], [OpenCode]) when multiple agents are active.
Getting started
- Install the agents you need – at least one of:
- OpenClaw + clawbot (the
openclaw‑weixinpackage) - Hermes Agent with its WeChat gateway
- OpenClaw + clawbot (the
- Run the one‑liner installer:
curl -fsSL https://raw.githubusercontent.com/AaronWong1999/hermesclaw/main/install.sh | bash- Detects which gateways are present
- Extracts the iLink token from their config files
- Patches each gateway to point at the local proxy ports
- Installs Python dependencies (
requests,python‑dotenv) - Sets up a systemd service (or launchd on macOS) to keep HermesClaw running
- Restart your gateways and send
/whoamiin WeChat to verify the route. - (Optional) Add OpenCode –
npm install -g opencode-ai; the installer will auto‑detect it and enable/opencodeand/three.
Commands you’ll use in WeChat
| Command | Effect |
|---|---|
/hermes |
Route messages only to Hermes Agent |
/openclaw |
Route only to OpenClaw |
/opencode |
Route only to OpenCode |
/both |
Send to Hermes + OpenClaw; replies are prefixed with the bot name |
/three |
Send to all three agents simultaneously |
/whoami |
Shows which route is active and the status of each proxy |
| any other text | Forwarded to the currently active agent(s) |
Installation details
- Python proxy –
hermesclaw.py(~870 lines) implements two HTTP proxies and an ACP bridge. - Installer script –
install.shauto‑detects the environment, patches config files, creates a systemd unit (or launchd plist on macOS), and can run non‑interactively with-yorHERMESCLAW_YES=1. - Tests – 117 pytest cases cover routing, media handling, ACP recovery, and installer edge cases.
- Uninstall – A scripted removal restores the original gateway configs and disables the background service.
Who built it
Aaron Wong (@AaronWong1999), with contributions from the Hermes Agent and OpenClaw communities. The project is MIT‑licensed.
HermesClaw doesn’t modify the AI models themselves; it simply lets you run multiple existing WeChat‑linked LLM bots together with a single account.
Related
- Project
- Project
- Project
- Project
- Project