From f5c2817c19f7e64ddaa66f6721ec21c3c03664bf Mon Sep 17 00:00:00 2001 From: Mikei386 <44135113+Mikei386@users.noreply.github.com> Date: Tue, 25 Aug 2026 15:41:30 +0200 Subject: [PATCH] Avoid Hermes Home Assistant toolset collision --- platform/hermes/config.yaml | 2 +- platform/hermes/install-profiles.sh | 15 +++++++++++++-- 2 files changed, 14 insertions(+), 3 deletions(-) diff --git a/platform/hermes/config.yaml b/platform/hermes/config.yaml index 07a5f28..2f272de 100644 --- a/platform/hermes/config.yaml +++ b/platform/hermes/config.yaml @@ -149,7 +149,7 @@ mcp_servers: timeout: 300 connect_timeout: 30 supports_parallel_tool_calls: false - homeassistant: + homeassistant-admin: url: "http://mcp-homeassistant:8000/mcp" timeout: 300 connect_timeout: 30 diff --git a/platform/hermes/install-profiles.sh b/platform/hermes/install-profiles.sh index 2fb6620..70c11a0 100755 --- a/platform/hermes/install-profiles.sh +++ b/platform/hermes/install-profiles.sh @@ -52,10 +52,21 @@ import pathlib root = pathlib.Path(os.environ["HERMES_DATA_DIR"]) / "profiles" placeholder = "${ROUTER_API_KEY}" -for path in sorted(root.glob("*/config.yaml")): +paths = [pathlib.Path(os.environ["HERMES_DATA_DIR"]) / "config.yaml"] +paths.extend(sorted(root.glob("*/config.yaml"))) +for path in paths: + if not path.exists(): + continue text = path.read_text() if placeholder in text: - path.write_text(text.replace(placeholder, os.environ["ROUTER_API_KEY"], 1)) + text = text.replace(placeholder, os.environ["ROUTER_API_KEY"], 1) + # Avoid collision with Hermes' disabled built-in `homeassistant` toolset. + # The collision filters the healthy external MCP out of agent snapshots. + text = text.replace( + "\n homeassistant:\n url: http://mcp-homeassistant:8000/mcp\n", + "\n homeassistant-admin:\n url: http://mcp-homeassistant:8000/mcp\n", + ) + path.write_text(text) PY "${STACK_DIR:-/opt/mike-ai/stack}/platform/hermes/install-skills.sh"