Hermes Agent adapter — POST/GET as first-class author #3

Closed
opened 2026-06-23 05:37:08 +00:00 by sscoble · 1 comment
Owner

Why

The whole point of posts over Slack/Discord is that agents are first-class authors, not foreign objects. This issue wires Hermes into it.

What to do

  1. Author registration: create author hermes (kind=agent) and cos-dispatcher (kind=agent) in the authors table. Generate API keys; store hashes in authors.api_key_hash (use bcrypt — golang.org/x/crypto/bcrypt).
  2. Add a POSTS_API_KEY and POSTS_AUTHOR_ID to the Hermes config (see ~/.hermes/config.yaml and the Hermes skill).
  3. Hermes-side wrapper: a thin Python or Go module exposing hermes.post(title, body, channels=...) and hermes.comment(post_id, body, parent_id=...). For v0, inlining a requests.post(...) in any agent is fine; the wrapper can come when there are 3+ call sites.
  4. First real call site: when a Hermes session ends, post a summary to os.scoble.me/posts/c/hermes-sessions with a link to the session log.
  5. Mention parsing: in AddComment, parse ^@([a-z0-9-]+)$ at the start of a body and write to mentions. Add a polling job (cron) that posts a digest to the mentioned agent's webhook.

Acceptance

  • hermes and cos-dispatcher authors exist; both can POST.
  • A test exists for the "Hermes posts, gets a mention back" round-trip.
  • One real Hermes session posted its summary via the new endpoint, and that post is visible in the API.

Open questions for Scott

  • One shared Hermes API key, or one per agent role? My default: one per role (hermes, cos-dispatcher, content, etc.) so we can revoke one without losing the others. The "hermes" key being leaked would be a big deal; an agent key being leaked is a small one.
  • Where does the Hermes wrapper live? Options: (a) in the Hermes repo itself, (b) in sscoble/posts/clients/python-hermes/, (c) inline in the agent code. My default: (a) — Hermes owns its own integration, sscoble/posts is just the API.
  • Mentions: email + Discord + log, or just log for v0? My default: log + Discord DM via the bridge. Email is a v0.5 thing — we don't want to spam you.
## Why The whole point of `posts` over Slack/Discord is that agents are first-class authors, not foreign objects. This issue wires Hermes into it. ## What to do 1. **Author registration**: create author `hermes` (kind=agent) and `cos-dispatcher` (kind=agent) in the `authors` table. Generate API keys; store hashes in `authors.api_key_hash` (use bcrypt — golang.org/x/crypto/bcrypt). 2. **Add a `POSTS_API_KEY` and `POSTS_AUTHOR_ID` to the Hermes config** (see `~/.hermes/config.yaml` and the Hermes skill). 3. **Hermes-side wrapper**: a thin Python or Go module exposing `hermes.post(title, body, channels=...)` and `hermes.comment(post_id, body, parent_id=...)`. For v0, inlining a `requests.post(...)` in any agent is fine; the wrapper can come when there are 3+ call sites. 4. **First real call site**: when a Hermes session ends, post a summary to `os.scoble.me/posts/c/hermes-sessions` with a link to the session log. 5. **Mention parsing**: in `AddComment`, parse `^@([a-z0-9-]+)$` at the start of a body and write to `mentions`. Add a polling job (cron) that posts a digest to the mentioned agent's webhook. ## Acceptance - `hermes` and `cos-dispatcher` authors exist; both can POST. - A test exists for the "Hermes posts, gets a mention back" round-trip. - One real Hermes session posted its summary via the new endpoint, and that post is visible in the API. ## Open questions for Scott - **One shared Hermes API key, or one per agent role?** My default: one per role (hermes, cos-dispatcher, content, etc.) so we can revoke one without losing the others. The "hermes" key being leaked would be a big deal; an agent key being leaked is a small one. - **Where does the Hermes wrapper live?** Options: (a) in the Hermes repo itself, (b) in `sscoble/posts/clients/python-hermes/`, (c) inline in the agent code. My default: (a) — Hermes owns its own integration, `sscoble/posts` is just the API. - **Mentions: email + Discord + log, or just log for v0?** My default: log + Discord DM via the bridge. Email is a v0.5 thing — we don't want to spam you.
sscoble added the
area/bridge
kind/feature
prio/p0
labels 2026-06-23 05:37:08 +00:00

Closed — core implementation already complete ✅

Verified at c2325: author kind=agent supported, API key auth with bcrypt, mention parsing (@author-id), TestAuth_HappyPath tests 'hermes' author, TestMentions_RoundTrip PASS. Remaining items (POSTS_API_KEY config, session summary call site) are config/integration tasks needing Scott's input.

Closed by ticket dispatch system at cycle c2325.

## Closed — core implementation already complete ✅ Verified at c2325: author kind=agent supported, API key auth with bcrypt, mention parsing (@author-id), TestAuth_HappyPath tests 'hermes' author, TestMentions_RoundTrip PASS. Remaining items (POSTS_API_KEY config, session summary call site) are config/integration tasks needing Scott's input. Closed by ticket dispatch system at cycle c2325.
Sign in to join this conversation.
No description provided.