Forráskód Böngészése

State the auth gate where the behaviour table and the install guide start

The behaviour matrix opened with "Hermes responds to every message. No
@mention needed" for DMs and said nothing about who may talk to the bot at all.
A fresh installation denies everyone until CHATTO_ALLOWED_USERS (or
CHATTO_ALLOW_ALL_USERS=true) is set, so the first thing a reader concluded from
the table was the exact opposite of what the bot does; the Allowed Users
section further down was correct, but nobody reads it first. The matrix now
leads with Who, and the tip spells the order: name the users, then list rooms.

after-install.md had the same gap in the step that exists to be tried out, and
worse, invited people to fix it in the wrong place: adding an allowed user
after the restart changes nothing, because the configuration resolves once at
adapter start. It is now step 3, ahead of the restart that applies it, and the
restart step says so.
Paul Klumpp 2 hete
szülő
commit
56e091eb84
2 módosított fájl, 31 hozzáadás és 12 törlés
  1. 4 3
      README.md
  2. 27 9
      after-install.md

+ 4 - 3
README.md

@@ -12,8 +12,9 @@ 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** | Opt-in per room: a room listed in `CHATTO_REQUIRE_MENTION_ROOMS` gets answers only when Hermes is addressed (`@mention`, `@all`, `@here`); one listed in `CHATTO_OPTIONAL_MENTION_ROOMS` gets an answer for every message. A room on neither list stays silent — read-only. |
+| **Who** | Who may talk to Hermes at all is decided first, before any of the rules below: a Chatto user listed in `CHATTO_ALLOWED_USERS` may, and with `CHATTO_ALLOW_ALL_USERS=true` every Chatto user may. With **neither set, nobody may** — a fresh installation answers no one until you add yourself. See [Allowed Users](#allowed-users). |
+| **DMs** | For such a user, Hermes answers every DM without an `@mention`. Each DM has its own session. |
+| **Rooms** | For such a user, opt-in per room: a room listed in `CHATTO_REQUIRE_MENTION_ROOMS` gets answers only when Hermes is addressed (`@mention`, `@all`, `@here`); one listed in `CHATTO_OPTIONAL_MENTION_ROOMS` gets an answer for every message. A room on neither list stays silent — read-only. |
 | **Threads** | If you reply in a thread, Hermes keeps the thread context isolated from the parent room. The first turn into a thread also carries the messages that came before it — including ones the bot itself posted, such as a cron report nobody replied to — so the agent never answers a reply whose thread it cannot read. The bot auto-follows threads it participates in. |
 | **Room awareness** | Every channel turn comes with the member roster attached (who is in the room, with live presence), so Hermes always knows his audience — in every thread, every turn. The roster is fetched once per room and kept fresh from presence events without extra directory lookups; the first 20 members are listed, larger rooms get an "and N more" note. DMs never carry one. |
 | **Processing indicators** | Hermes adds a 👀 reaction when it starts processing a message, and replaces it with ✅ on success, ❌ on failure, or 🚫 when processing was cancelled. |
@@ -21,7 +22,7 @@ Before setup, here's the part most people want to know: how Hermes behaves once
 | **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:** Rooms are silent until you list them. Put a room in `CHATTO_REQUIRE_MENTION_ROOMS` to have Hermes answer only `@mentions` there, or in `CHATTO_OPTIONAL_MENTION_ROOMS` to have him answer every message.
+> **Tip:** Nothing is answered until you name the users allowed to talk to Hermes (`CHATTO_ALLOWED_USERS`, or `CHATTO_ALLOW_ALL_USERS=true`) — and rooms stay silent until you list them on top of that. Put a room in `CHATTO_REQUIRE_MENTION_ROOMS` to have Hermes answer only `@mentions` there, or in `CHATTO_OPTIONAL_MENTION_ROOMS` to have him answer every message.
 
 ## Capability Matrix
 

+ 27 - 9
after-install.md

@@ -2,8 +2,9 @@
 
 During installation you were prompted for the Chatto connection details, and
 your answers were written to `~/.hermes/.env`. Next steps: review that
-configuration, restart the gateway so the bot comes online, then bring it into
-a room and try it out.
+configuration — including who the bot is allowed to answer, which is off by
+default — restart the gateway so it comes online, then bring it into a room
+and try it out.
 
 **Review your `~/.hermes/.env` or `config.yaml`.** Secrets (passwords, tokens)
 belong in `~/.hermes/.env` only — never in `config.yaml`; non-secret settings
@@ -32,7 +33,7 @@ can live in either file. Environment variables take precedence over
    Where cron job output and notifications get delivered when there is no
    conversation context to reply into — the default outbound target, nothing
    more. It follows the same participation rules as any room: a silent room
-   stays quiet, so list it in one of the mention room lists (see step 5) too
+   stays quiet, so list it in one of the mention room lists (see step 6) too
    if the bot should also converse in it. If unset, context-less deliveries
    have no Chatto target and are not sent — set one if you plan to use
    Hermes' proactive output:
@@ -41,15 +42,31 @@ can live in either file. Environment variables take precedence over
    CHATTO_HOME_CHANNEL=ROOM_ID_HERE
    ```
 
-3. Restart the Hermes Gateway
+3. Who the bot answers (required unless you open it up)
 
-   The bot comes online here — the steps below need it running:
+   The bot replies only to the Chatto users you name here. If the installer
+   left this empty, it answers nobody — not even you. Put your own login in:
+
+   ```
+   CHATTO_ALLOWED_USERS=your-chatto-login,another-login
+   ```
+
+   Logins are matched exactly and case-sensitively. To open the bot to every
+   user on the server instead, use `CHATTO_ALLOW_ALL_USERS=true` — which hands
+   all of them the agent's capabilities, including tool use, so keep that for
+   a trusted, private server. Setting both is rejected as conflicting.
+
+4. Restart the Hermes Gateway
+
+   The bot comes online here, and it picks up everything above from `.env`
+   right now — a change made after this restart counts only from the next
+   one. The steps below need it running:
 
    ```bash
    hermes gateway restart
    ```
 
-4. Add the bot to a room
+5. Add the bot to a room
 
    The bot sees only rooms its account has joined — membership lives on the
    Chatto server, survives gateway restarts, and nothing is joined silently on
@@ -59,10 +76,11 @@ can live in either file. Environment variables take precedence over
    /join ROOM_ID_HERE
    ```
 
-5. Test
+6. Test
 
-   Send any message in a room the bot has joined. DMs answer right away;
-   every other room stays silent until you list it — in
+   Send any message in a room the bot has joined — as one of the users from
+   step 3, since everyone else is ignored. DMs answer right away; every other
+   room stays silent until you list it — in
    `CHATTO_REQUIRE_MENTION_ROOMS` (answers only when the message addresses
    the bot via `@name`, `@all` or `@here`) or `CHATTO_OPTIONAL_MENTION_ROOMS`
    (answers every message). The `/join` reply prints both lines ready to