Research: Hermes CLI profile-create semantics #43

Closed
opened 2026-09-03 16:33:13 +02:00 by AlexKucera · 2 comments
Owner

Part of #13

Question

What are the exact semantics of profile creation in the installed Hermes CLI? Facts to capture, verified against the real binary (and the docs at https://hermes-agent.nousresearch.com/docs):

  • The exact subcommand and flags that create the museion profile (hermes profile create museion? something else?) — and whether it prompts interactively (it must be safe non-interactively)
  • Idempotency: behavior when the profile already exists — exit code, output, does it touch or clobber anything?
  • Exit codes / stderr on success and failure
  • What the created profile directory actually contains (shape, config file name and format)
  • Whether a fresh profile needs anything else before hermes acp -p museion runs against it
  • Version sensitivity: does the command surface differ across recent hermes-agent versions? Museion targets current latest.
    Method: run hermes profile --help and subcommand help on the installed binary; probe with a throwaway profile name; cite command transcripts, not conclusions.

[Generated by AI]

Part of #13 ## Question What are the exact semantics of profile creation in the installed Hermes CLI? Facts to capture, verified against the real binary (and the docs at https://hermes-agent.nousresearch.com/docs): - The exact subcommand and flags that create the museion profile (`hermes profile create museion`? something else?) — and whether it prompts interactively (it must be safe non-interactively) - Idempotency: behavior when the profile already exists — exit code, output, does it touch or clobber anything? - Exit codes / stderr on success and failure - What the created profile directory actually contains (shape, config file name and format) - Whether a fresh profile needs anything else before `hermes acp -p museion` runs against it - Version sensitivity: does the command surface differ across recent hermes-agent versions? Museion targets current latest. Method: run `hermes profile --help` and subcommand help on the installed binary; probe with a throwaway profile name; cite command transcripts, not conclusions. [Generated by AI]
AlexKucera added the wayfinder:research label 2026-09-03 16:33:14 +02:00
AlexKucera added a new dependency 2026-09-03 16:34:34 +02:00
AlexKucera added a new dependency 2026-09-03 16:34:35 +02:00
AlexKucera removed a dependency 2026-09-03 16:35:16 +02:00
Author
Owner

Research complete — every fact below verified against the installed binary with stdin closed (</dev/null). Throwaway profiles wf-research-probe / probe2 used for probing, both deleted afterwards (~/.hermes/profiles/ back to museion/ only).

Binary: /Users/alex/.local/bin/hermes — Hermes Agent v0.20.6 (2026.8.27) · upstream 562ee8ab · local 493e88da (+3 carried commits); hermes acp --version → 0.20.6 (exit 0).

1. Command & non-interactive safety

$ hermes profile create wf-research-probe </dev/null
Profile 'wf-research-probe' created at /Users/alex/.hermes/profiles/wf-research-probe
82 bundled skills synced.
Wrapper created: /Users/alex/.local/bin/wf-research-probe
…(next-steps hints, "no API keys yet" warning)…
exit=0

No prompts, no TTY needed — hermes profile create museion is exactly right. Flags (from hermes profile create --help): --no-alias (skip the ~/.local/bin/<name> wrapper — Museion should pass this, it doesn't want a museion shell command), --no-skills (empty skills dir + .no-bundled-skills marker, opts out of hermes update skill sync — relevant since Museion seeds its own curated set additively), --description, --clone/--clone-all/--clone-from.

2. Idempotency (profile already exists)

$ hermes profile create wf-research-probe </dev/null
Error: Profile 'wf-research-probe' already exists at /Users/alex/.hermes/profiles/wf-research-probe
exit=1

stderr is EMPTY — error text goes to stdout. Nothing clobbered: md5 of config.yaml and state.db identical before/after. So "create if missing" = run create; exit 1 + already exists on stdout = treat as success.

3. Exit codes / error channel

  • Success: exit 0, report on stdout.
  • Every failure probed: exit 1, Error: … on stdout, stderr empty.
  • Invalid name: Error: Invalid profile name 'bad_name!'. Must match [a-z0-9][a-z0-9_-]{0,63} (name is lowercased before validation — Bad_Name! reported as bad_name!).
  • Bad clone source: Error: Source profile 'nope' does not exist at /Users/alex/.hermes/profiles/nope.

4. Created profile contents (~/.hermes/profiles/<name>/)

  • config.yaml — YAML, 2 KB, _config_version: 39; model: block copied from the active root profile (same provider/model/base_url — here glm-5.3 / zai), plugins: {enabled: []}, agent: {}, remainder commented defaults.
  • .env — comments only, no keys (165 B).
  • SOUL.md — default 513 B persona.
  • state.db (+-wal/-shm) — SQLite session store (sessions, messages + FTS tables, gateway_*, schema_version).
  • skills/ — 82 bundled skills synced + .bundled_manifest (lines of name:md5). With --no-skills: only the autonomous-ai-agents/ category ships + a .no-bundled-skills marker.
  • Empty dirs: audio_cache, cache, cron, home, hooks, image_cache, logs, memories, pairing, plans, sessions, skins, workspace.
  • Wrapper script at ~/.local/bin/<name> (71 B → hermes -p <name>) unless --no-alias.

5. Is a fresh profile ACP-ready?

  • hermes acp -p wf-research-probe --check → Hermes ACP check OK, exit 0.
  • Live JSON-RPC initialize over stdio → proper ACP response (agentInfo: hermes-agent 0.20.6, protocolVersion: 1, authMethods incl. terminal hermes-setup). Nothing else needed to boot ACP.
  • Caveat A — credentials: profile .env has no keys; model calls fall back to shell-env keys (create output warns about this). Museion must ensure provider credentials exist in the profile (or root ~/.hermes/.env) before real turns.
  • Caveat B — transport: ACP stdout must be a real pipe/socket, not a regular file: redirecting stdout to a file crashed with ValueError: Pipe transport is only for pipes, sockets and character devices (acp stdio transport). Ordinary Process pipes are fine.

6. Version sensitivity

Docs (https://hermes-agent.nousresearch.com/docs/user-guide/profiles) match the binary exactly for profile create NAME [--clone|--clone-all|--clone-from|--no-alias|--no-skills|--description]; the binary additionally ships describe/install/update/info subcommands (superset, no contradiction). Installed 0.20.6 reports an update available; the error-on-stdout channel and exit-1 already-exists behavior are implementation details worth pinning in Museion's tests and re-checking after any hermes update bump.

[Generated by AI]

Research complete — every fact below verified against the installed binary with stdin closed (`</dev/null`). Throwaway profiles `wf-research-probe` / `probe2` used for probing, both deleted afterwards (`~/.hermes/profiles/` back to `museion/` only). **Binary**: `/Users/alex/.local/bin/hermes` — `Hermes Agent v0.20.6 (2026.8.27) · upstream 562ee8ab · local 493e88da (+3 carried commits)`; `hermes acp --version` → `0.20.6` (exit 0). ### 1. Command & non-interactive safety ``` $ hermes profile create wf-research-probe </dev/null Profile 'wf-research-probe' created at /Users/alex/.hermes/profiles/wf-research-probe 82 bundled skills synced. Wrapper created: /Users/alex/.local/bin/wf-research-probe …(next-steps hints, "no API keys yet" warning)… exit=0 ``` No prompts, no TTY needed — `hermes profile create museion` is exactly right. Flags (from `hermes profile create --help`): `--no-alias` (skip the `~/.local/bin/<name>` wrapper — Museion should pass this, it doesn't want a `museion` shell command), `--no-skills` (empty skills dir + `.no-bundled-skills` marker, opts out of `hermes update` skill sync — relevant since Museion seeds its own curated set additively), `--description`, `--clone/--clone-all/--clone-from`. ### 2. Idempotency (profile already exists) ``` $ hermes profile create wf-research-probe </dev/null Error: Profile 'wf-research-probe' already exists at /Users/alex/.hermes/profiles/wf-research-probe exit=1 ``` stderr is EMPTY — error text goes to **stdout**. Nothing clobbered: md5 of `config.yaml` and `state.db` identical before/after. So "create if missing" = run create; exit 1 + `already exists` on stdout = treat as success. ### 3. Exit codes / error channel - Success: exit 0, report on stdout. - Every failure probed: exit 1, `Error: …` on **stdout**, stderr empty. - Invalid name: `Error: Invalid profile name 'bad_name!'. Must match [a-z0-9][a-z0-9_-]{0,63}` (name is lowercased before validation — `Bad_Name!` reported as `bad_name!`). - Bad clone source: `Error: Source profile 'nope' does not exist at /Users/alex/.hermes/profiles/nope`. ### 4. Created profile contents (`~/.hermes/profiles/<name>/`) - `config.yaml` — **YAML**, 2 KB, `_config_version: 39`; `model:` block **copied from the active root profile** (same provider/model/base_url — here `glm-5.3 / zai`), `plugins: {enabled: []}`, `agent: {}`, remainder commented defaults. - `.env` — comments only, **no keys** (165 B). - `SOUL.md` — default 513 B persona. - `state.db` (+`-wal`/`-shm`) — SQLite session store (`sessions`, `messages` + FTS tables, `gateway_*`, `schema_version`). - `skills/` — 82 bundled skills synced + `.bundled_manifest` (lines of `name:md5`). With `--no-skills`: only the `autonomous-ai-agents/` category ships + a `.no-bundled-skills` marker. - Empty dirs: `audio_cache, cache, cron, home, hooks, image_cache, logs, memories, pairing, plans, sessions, skins, workspace`. - Wrapper script at `~/.local/bin/<name>` (71 B → `hermes -p <name>`) unless `--no-alias`. ### 5. Is a fresh profile ACP-ready? - `hermes acp -p wf-research-probe --check` → `Hermes ACP check OK`, exit 0. - Live JSON-RPC `initialize` over stdio → proper ACP response (`agentInfo: hermes-agent 0.20.6`, `protocolVersion: 1`, authMethods incl. terminal `hermes-setup`). Nothing else needed to **boot** ACP. - Caveat A — credentials: profile `.env` has no keys; model calls fall back to shell-env keys (create output warns about this). Museion must ensure provider credentials exist in the profile (or root `~/.hermes/.env`) before real turns. - Caveat B — transport: ACP stdout must be a real pipe/socket, not a regular file: redirecting stdout to a file crashed with `ValueError: Pipe transport is only for pipes, sockets and character devices` (acp stdio transport). Ordinary `Process` pipes are fine. ### 6. Version sensitivity Docs (https://hermes-agent.nousresearch.com/docs/user-guide/profiles) match the binary exactly for `profile create NAME [--clone|--clone-all|--clone-from|--no-alias|--no-skills|--description]`; the binary additionally ships `describe/install/update/info` subcommands (superset, no contradiction). Installed 0.20.6 reports an update available; the error-on-stdout channel and exit-1 already-exists behavior are implementation details worth pinning in Museion's tests and re-checking after any `hermes update` bump. [Generated by AI]
Author
Owner

Follow-up (charting session): the 82 engine-bundled skills live under category subdirectories (apple/, creative/, research/, software-development/… — flat-name categories), while Museion's 11 payload skills are flat at the skills/ root. Name collision between payload and engine-bundled skills is therefore impossible by layout; additive-only seeding is safe as specced.

[Generated by AI]

Follow-up (charting session): the 82 engine-bundled skills live under **category subdirectories** (apple/, creative/, research/, software-development/… — flat-name categories), while Museion's 11 payload skills are **flat** at the skills/ root. Name collision between payload and engine-bundled skills is therefore impossible by layout; additive-only seeding is safe as specced. [Generated by AI]
Sign in to join this conversation.