ソースを参照

Make the docs match the adapter's actual behavior

Mention gating defaults to off and covers channel-kind rooms only; the
capability-matrix rule now allows supersets of the startup banner; the
version floor tracks the vendored chattolib (0.4.20.post1 / v0.4.20);
the invented /sethome command is gone from Home Channel; AGENTS.md
documents after-install.md as the post-install convention.
Paul Klumpp 1 週間 前
コミット
9b7fb32b87
3 ファイル変更30 行追加18 行削除
  1. 19 6
      AGENTS.md
  2. 10 11
      README.md
  3. 1 1
      plugin.yaml

+ 19 - 6
AGENTS.md

@@ -21,10 +21,10 @@ is unclear on our side, the Chatto server source is the reference:
 git clone https://github.com/chattocorp/chatto.git
 ```
 
-The vendored copy corresponds to upstream `chattolib[realtime]`, the 0.4.x line
-(realtime protocol v1) — Chatto servers older than v0.4.19 are not supported.
-Respect that floor when refreshing `vendor/` via `vendor_chattolib.sh`
-(see VENDORING.md).
+The vendored copy is upstream `chattolib[realtime]` 0.4.20.post1 (realtime
+protocol v1); the matching server floor is Chatto v0.4.20. Refreshing `vendor/`
+via `vendor_chattolib.sh` can move that floor (see VENDORING.md) — after each
+refresh, restate the new version here and in README.md.
 
 ## README.md is the human README
 
@@ -47,6 +47,17 @@ behaves, how to configure it. Unambiguous in practice means:
   server floor, and README.md has to move with it. ("Tested against Chatto
   v0.4.19" outlived its truth the moment the vendored copy became 0.4.20.)
 
+### after-install.md
+
+**Hermes Agent displays `after-install.md` to the user right after plugin
+installation — that is the platform-plugin convention, not our timing choice.**
+
+It is the first instruction anyone reads, ahead of README.md, config files and
+source. Hold it to the same no-ambiguity bar and keep it in step with reality:
+every env var, command and next step printed there must work exactly as
+written, so it moves whenever setup, configuration or first-run behavior
+changes.
+
 ## Behavioural contract
 
 **These behaviours are promises to users, documented in README.md — adapter
@@ -247,8 +258,10 @@ So when you add an overridden `BasePlatformAdapter` method:
    hint goes into the system prompt and is the only way the model learns what the
    channel can do — without it the agent falls back to shelling out.
 3. Add a test in `TestRegistration` if the capability is user-visible.
-4. Update the capability matrix and feature notes in README.md — that is the
-   public version of the same list.
+4. Update the capability matrix and feature notes in README.md — the
+   user-facing counterpart of the startup list. It may say more than the
+   banner (setup-level features such as markdown or reconnect belong there),
+   but nothing less.
 
 The reverse holds too: drop a method and its line disappears from the log on its
 own, but its `_CAPABILITY_LABELS` entry should go with it, along with its row in

+ 10 - 11
README.md

@@ -4,7 +4,7 @@ A [Chatto](https://github.com/chattocorp/chatto) platform adapter plugin for [He
 
 All API interaction goes through [chattolib](https://github.com/chattocorp/chattolib): a persistent WebSocket realtime connection delivers inbound events, ConnectRPC over HTTP handles outbound messages, reactions, uploads and more. Messages are processed through the full Hermes Agent pipeline (tool use, memory, reasoning) and answered in real time.
 
-Tested against Chatto v0.4.19 with `chattolib[realtime]>=0.4.19` (realtime protocol v1). Chatto servers older than v0.4.19 are not supported.
+Tested against Chatto v0.4.20 with the vendored `chattolib[realtime]` 0.4.20.post1 (realtime protocol v1). Chatto servers older than v0.4.20 are not supported.
 
 Before setup, here's the part most people want to know: how Hermes behaves once it's in your Chatto instance.
 
@@ -13,13 +13,13 @@ Before setup, here's the part most people want to know: how Hermes behaves once
 | Context | Behavior |
 |---------|----------|
 | **DMs** | Hermes responds to every message. No `@mention` needed. Each DM has its own session. |
-| **Rooms** | Without a `@mention`, Hermes ignores the message (configurable via `CHATTO_REQUIRE_MENTION`). When you `@mention` it, Hermes responds. |
+| **Rooms** | Hermes responds to every room message by default. With `CHATTO_REQUIRE_MENTION=true`, channel-kind rooms answer only `@mentions`; group-kind rooms always respond. |
 | **Threads** | If you reply in a thread, Hermes keeps the thread context isolated from the parent room. The bot auto-follows threads it participates in. |
 | **Processing indicators** | Hermes adds a 👀 reaction when it starts processing a message, and replaces it with ✅ on success or ❌ on failure. |
 | **Typing indicators** | Hermes broadcasts persistent typing indicators while it's working, so users know the bot is active. |
 | **Message splitting** | Long responses (>10000 chars) are automatically split into multiple messages. |
 
-> **Tip:** If you want Hermes to respond to all messages in a room without requiring an `@mention`, set `CHATTO_REQUIRE_MENTION=false`. DMs always get a response regardless of this setting.
+> **Tip:** By default Hermes answers every message in a room. Set `CHATTO_REQUIRE_MENTION=true` to have him answer only `@mentions` in channel-type rooms.
 
 ## Capability Matrix
 
@@ -52,7 +52,7 @@ Capabilities natively implemented by the Chatto plugin adapter:
 3. **Room membership** — the bot account must be a member of any room where you want it to respond. The adapter auto-joins rooms specified in `CHATTO_CHANNELS`. For DMs, simply start a direct message with the bot.
 4. **Network access** — the Hermes host must reach the Chatto server URL over HTTPS (or HTTP) and establish a WebSocket connection to `/api/realtime`.
 
-> **Info:** The adapter uses WebSocket protocol v1 (compatible with Chatto v0.4.19+). Ensure your Chatto server is up to date.
+> **Info:** The adapter uses WebSocket protocol v1 (compatible with Chatto v0.4.20+). Ensure your Chatto server is up to date.
 
 ## Install
 
@@ -102,8 +102,8 @@ CHATTO_PASSWORD=your-password
 # Optional: allow any user to talk to the bot (default: false)
 # CHATTO_ALLOW_ALL_USERS=true
 
-# Optional: require @mention in channels (default: false). DMs always respond.
-# CHATTO_REQUIRE_MENTION=false
+# Optional: answer only @mentions in channels — group rooms and DMs always respond
+# CHATTO_REQUIRE_MENTION=true
 
 # Optional: rooms that answer without a mention even when require_mention is on
 # CHATTO_FREE_RESPONSE_CHANNELS=REljMv5Pgolo6Y9
@@ -165,7 +165,7 @@ Once configured, start the gateway:
 hermes gateway
 ```
 
-The bot should connect to your Chatto server within a few seconds. Send it a message — either a DM or an `@mention` in a room — to test.
+The bot should connect to your Chatto server within a few seconds. Send it a message — a DM or any message in a room — to test.
 
 If nothing happens at startup — plugin failed to load, credentials rejected, server unreachable — run `hermes logs` to see what the Chatto adapter reported.
 
@@ -197,7 +197,7 @@ Hermes uses emoji reactions for processing lifecycle notifications:
 - ✅ — replaces 👀 when processing completes successfully
 - ❌ — replaces 👀 when processing fails
 
-The adapter converts Unicode emoji to Chatto shortcode names internally (e.g., `👀` → `eyes`, `✅` → `white_check_mark`). Reactions can also be added/removed programmatically by the agent. Disable the lifecycle reactions with `CHATTO_REACTIONS=false`.
+Disable the lifecycle reactions with `CHATTO_REACTIONS=false`.
 
 ### Message Editing and Deletion
 
@@ -274,7 +274,6 @@ The home channel is where the bot sends proactive messages — cron job output,
 
 - `CHATTO_HOME_CHANNEL` env var (room ID)
 - `config.yaml` → `gateway.platforms.chatto.extra.home_channel`
-- `/sethome` slash command in any room where the bot is present
 
 If unset, the first watched room is used as the default home channel.
 
@@ -325,7 +324,7 @@ If the response does not include a `token` field, the credentials are wrong. Res
 
 **Cause**: The Chatto server is running an older version that doesn't support realtime protocol v1.
 
-**Fix**: The adapter uses protocol v1, supported by Chatto v0.4.19 and later. Upgrade your Chatto server:
+**Fix**: The adapter uses protocol v1, supported by Chatto v0.4.20 and later. Upgrade your Chatto server:
 
 ```bash
 curl -s https://chat.example.com/api/version | jq .
@@ -370,7 +369,7 @@ For more information on securing your Hermes Agent deployment, see the security
 ## Notes
 
 - **Self-hosted friendly**: Works with any self-hosted Chatto instance. No cloud account or subscription required.
-- **Minimal dependencies**: Only requires `chattolib[realtime]>=0.4.19`.
+- **Minimal dependencies**: Only requires `chattolib[realtime]>=0.4.20.post1`, which is vendored — nothing to install.
 - **Resume cursor support**: On reconnect, the adapter resumes from the last event cursor, so no messages are lost or replayed during transient disconnects.
 
 ## License

+ 1 - 1
plugin.yaml

@@ -41,7 +41,7 @@ optional_env:
     prompt: "Allow all users? (true/false)"
     password: false
   - name: CHATTO_REQUIRE_MENTION
-    description: "Only respond to @mentions in rooms (default: true). DMs always get a response."
+    description: "Only respond to @mentions in channels (default: false). Group-kind rooms and DMs always get a response."
     prompt: "Require mention in rooms? (true/false)"
     password: false
   - name: CHATTO_AUTO_THREAD