Fix claude-bot replying to Hermes's own messages, route Hermes through LiteLLM
Critical bug: claude-bot only ignored its OWN messages and text explicitly
addressed to @hermes — it did not ignore Hermes's own replies appearing in
the room. A single @hermes mention cascaded into claude-bot replying to
Hermes's thread messages ('Hermes says: ...'), which could itself cascade
further. Fixed with an OTHER_AGENT_USER_IDS allowlist of sender IDs to
always ignore, not just a text-prefix check.
Also point Hermes's model provider at the local litellm gateway
(OPENAI_BASE_URL/OPENAI_API_KEY) instead of OpenRouter directly, matching
claude-agent's own chat path — one place to hold the OpenRouter credential.
This does NOT grant Hermes access to the Claude subscription; that's an
Anthropic-side restriction unrelated to which proxy sits in front of it,
already proven earlier in this session.
Separately (not a code fix): the 'Billing or credits exhausted: HTTP 402'
error Hermes hit is real — the OpenRouter account currently has 0 credits.
This commit is contained in:
@@ -30,6 +30,10 @@ MATRIX_CONTROL_ROOM_ID=
|
||||
# Required: without it the bot can't tell its own messages apart from real ones and would
|
||||
# reply to itself in a loop, so it refuses to start.
|
||||
MATRIX_BOT_USER_ID=
|
||||
# Comma-separated Matrix IDs of OTHER agents sharing the control room (currently just
|
||||
# @hermes:...) — without this, claude-bot treats every message another bot posts as
|
||||
# fresh chat input and replies to it, which that bot may then react to in turn.
|
||||
OTHER_AGENT_USER_IDS=@hermes:matrix.apps.williamturner.eu
|
||||
# Comma-separated "owner/repo" list the chat router is allowed to open code-change PRs
|
||||
# against. A plain chat message mentioning a repo NOT in this list is treated as chat,
|
||||
# never as a code task — the router only matches confidently against known repos.
|
||||
|
||||
Reference in New Issue
Block a user