From b2e045c9f1f715f7707c28cd1cfe94b8609c4ee0 Mon Sep 17 00:00:00 2001 From: Phil Date: Wed, 11 Nov 2026 14:56:25 -0700 Subject: [PATCH] Mac: fix Hermes approval guardian on Haiku 5.5; Bot Chat folder Hermes's OpenRouter code treats Claude models it doesn't list as reasoning-mandatory and drops the guardian's "reasoning off" for Haiku 5.5, which then sometimes spends the 16-token budget thinking and returns nothing, escalating the command to the user. Send extra_body.reasoning {effort: none} for the approval task; replays of the failing commands went 21/21 correct. Also create ~/hermes, the folder the Hermex Bot Chat session works in. Co-Authored-By: Claude Opus 5.5 --- group_vars/mac/main.yml | 8 ++++++-- roles/mac/README.md | 5 +++++ roles/mac/tasks/hermes-settings.yml | 9 +++++++++ roles/mac/vars/main.yml | 1 + 4 files changed, 21 insertions(+), 2 deletions(-) diff --git a/group_vars/mac/main.yml b/group_vars/mac/main.yml index 6fd4433..c9f6881 100644 --- a/group_vars/mac/main.yml +++ b/group_vars/mac/main.yml @@ -66,10 +66,14 @@ hermes_settings: # Short-answer tasks turn reasoning off and allow only a few tokens (the # approval guardian: 16, titles: 64). GLM-5.3 Flash can't turn reasoning off # (OpenRouter: reasoning mandatory), spends the budget thinking and returns - # nothing, so the guardian escalated every command to you. Haiku 5.5 has - # reasoning off by default. + # nothing, so the guardian escalated every command to you. Haiku 5.5 can + # turn reasoning off, but Hermes's OpenRouter code treats Claude models it + # doesn't list as reasoning-mandatory and drops the "off" (hermes-agent + # #134761). Haiku then sometimes thinks through the 16 tokens on longer + # commands. extra_body.reasoning is sent to OpenRouter as written. auxiliary.approval.provider: openrouter auxiliary.approval.model: anthropic/claude-haiku-5.5 + auxiliary.approval.extra_body: {reasoning: {effort: none}} auxiliary.title_generation.provider: openrouter auxiliary.title_generation.model: anthropic/claude-haiku-5.5 auxiliary.memory_query_rewrite.provider: openrouter diff --git a/roles/mac/README.md b/roles/mac/README.md index f081ab5..a80c4e3 100644 --- a/roles/mac/README.md +++ b/roles/mac/README.md @@ -30,8 +30,13 @@ Manages cogitator-02, an Apple Silicon Mac on the tailnet (`mac.yml`, memory, disabled toolsets, skill-write approval, deny rules, streaming, voice-note transcription, and models: chat on GPT-6.1 Sol, short side tasks (approval, titles) on Claude Haiku 5.5, longer ones and cron on GLM-5.3 Flash, subagents on DeepSeek V4.1 Flash, `/model` aliases. + The approval guardian also gets `extra_body.reasoning: {effort: none}`, + because Hermes drops its own "reasoning off" for Haiku 5.5 on OpenRouter. Keys in `hermes_settings_force` are set with `--force` (Hermes reads `agent.reasoning_effort` but `config set` refuses it, hermes-agent #140221). + Also creates `~/hermes`, the Bot Chat's folder (the Hermex app's default + bot). The session's saved folder was set once by hand; Hermes has no + command for it. - **MCP servers and secrets** (also tag `hermes-settings`): MCP servers are `mcp_servers.` entries in `hermes_settings`, each running in a throwaway Podman container. Secrets they need are in `hermes_env_secrets` diff --git a/roles/mac/tasks/hermes-settings.yml b/roles/mac/tasks/hermes-settings.yml index 9af0a26..291e36c 100644 --- a/roles/mac/tasks/hermes-settings.yml +++ b/roles/mac/tasks/hermes-settings.yml @@ -1,3 +1,12 @@ +# The Hermex app's Bot Chat works here: its session's saved folder is +# mounted into the sandbox at /workspace. Saved once with Hermes's +# update_session_cwd, since Hermes has no command for it. +- name: Bot Chat workspace folder + ansible.builtin.file: + path: "{{ hermes_bot_workspace }}" + state: directory + mode: "0755" + # Secrets go in first, so servers and settings that reference them # (${VAR}) find them when the gateway restarts. - name: Secrets in Hermes's .env diff --git a/roles/mac/vars/main.yml b/roles/mac/vars/main.yml index 818d3e9..c0f9dd7 100644 --- a/roles/mac/vars/main.yml +++ b/roles/mac/vars/main.yml @@ -4,3 +4,4 @@ hermes_dashboard_label: local.hermes-dashboard tailscale_cli: /Applications/Tailscale.app/Contents/MacOS/Tailscale hermes_cli: "{{ ansible_user_dir }}/.local/bin/hermes" podman_machine_label: local.podman-machine +hermes_bot_workspace: "{{ ansible_user_dir }}/hermes"