@hydra-acp/cli 0.1.5 → 0.1.7

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -178,7 +178,7 @@ hydra-acp daemon start
178
178
  # spawned-by-editor cases where stdio is already piped. The first
179
179
  # session/new asks the daemon which agent to spawn (defaults to
180
180
  # config.defaultAgent). If you'd rather the editor pin a specific agent,
181
- # spawn `hydra-acp launch <agent-id>` (see "Launcher mode" below).
181
+ # spawn `hydra-acp launch <agent>` (see "Launcher mode" below).
182
182
 
183
183
  # 4. From a terminal, drive a session interactively (TUI).
184
184
  hydra-acp # bare invocation in a TTY launches the TUI
@@ -198,8 +198,8 @@ hydra-acp --session-id hydra_session_abc123
198
198
  hydra-acp # auto-dispatch: TUI in a TTY, shim when stdio is piped
199
199
  hydra-acp shim # explicit shim mode (forces shim regardless of TTY)
200
200
  hydra-acp tui # explicit terminal-UI mode
201
- hydra-acp launch <agent-id> # launcher mode: shim that forces the
202
- # daemon to spawn <agent-id> on session/new
201
+ hydra-acp launch <agent> # launcher mode: shim that forces the
202
+ # daemon to spawn <agent> on session/new
203
203
  hydra-acp --session-id <id> # attach to existing session
204
204
  # (TUI in a TTY, shim otherwise)
205
205
 
@@ -234,7 +234,7 @@ A bare invocation (`hydra-acp` with no subcommand) auto-dispatches based on whet
234
234
 
235
235
  ### Launcher mode
236
236
 
237
- `hydra-acp launch <agent-id>` is a convenience for "shim me, and use *this* registry agent." It's the easiest way to wrap an existing ACP-speaking editor configuration whose agent-spawn surface is just a command and arguments:
237
+ `hydra-acp launch <agent>` is a convenience for "shim me, and use *this* registry agent." It's the easiest way to wrap an existing ACP-speaking editor configuration whose agent-spawn surface is just a command and arguments:
238
238
 
239
239
  ```text
240
240
  # Configure your editor's ACP-launch command to:
@@ -243,9 +243,9 @@ hydra-acp launch claude-code
243
243
 
244
244
  When the editor sends `session/new`, the shim rewrites the params to `{ ..., agentId: "claude-code" }` before forwarding to the daemon. The daemon resolves `claude-code` against the cached ACP Registry, downloads/installs the agent on first use under `~/.hydra-acp/agents/`, and spawns the subprocess. The editor sees a normal ACP agent. From then on, `hydra-acp sessions` lists the live session and any other client can `session/attach` to it.
245
245
 
246
- `<agent-id>` is the registry ID — e.g. `claude-code`, `gemini-cli`, `codex`. Run `hydra-acp agents` to browse what's available, or fetch the registry CDN URL directly.
246
+ `<agent>` is the registry ID — e.g. `claude-code`, `gemini-cli`, `codex`. Run `hydra-acp agents` to browse what's available, or fetch the registry CDN URL directly.
247
247
 
248
- If both `launch <agent-id>` and `--session-id` are given, `--session-id` wins (attach mode); the agent ID is ignored because the agent process is already running.
248
+ If both `launch <agent>` and `--session-id` are given, `--session-id` wins (attach mode); the agent is ignored because the agent process is already running.
249
249
 
250
250
  ### Naming sessions from the editor
251
251
 
@@ -286,9 +286,9 @@ Each session carries a stable **`lineageId`** that survives every export/import
286
286
 
287
287
  The first attach to an imported session is slow: hydra spawns a fresh agent, runs `session/new`, and feeds the imported history back in as a synthesized takeover transcript (same machinery as `/hydra agent`). Subsequent attaches use the normal `session/load` path. This is a text-level handover — the originating agent's internal state (tool-call chains, compacted earlier turns) isn't preserved, so the resumed conversation may be cognitively shallower than the original.
288
288
 
289
- ### Forwarding agent args (`hydra-acp launch <agent-id> ...`)
289
+ ### Forwarding agent args (`hydra-acp launch <agent> ...`)
290
290
 
291
- Anything you put after `<agent-id>` in launcher mode is forwarded to the underlying agent's command. Hydra appends the extra args to the registry-provided spawn plan. Example:
291
+ Anything you put after `<agent>` in launcher mode is forwarded to the underlying agent's command. Hydra appends the extra args to the registry-provided spawn plan. Example:
292
292
 
293
293
  ```text
294
294
  hydra-acp launch codex-acp -c sandbox_mode=danger-full-access
@@ -303,14 +303,17 @@ Every config-knob flag has an `HYDRA_ACP_FOO_BAR` env-var equivalent. Flag wins
303
303
  | Flag | Env var |
304
304
  |---|---|
305
305
  | `--name` | `HYDRA_ACP_NAME` |
306
- | `--agent-id` | `HYDRA_ACP_AGENT_ID` |
306
+ | `--agent` | `HYDRA_ACP_AGENT` |
307
+ | `--model` | `HYDRA_ACP_MODEL` |
307
308
  | `--session-id` | `HYDRA_ACP_SESSION_ID` |
308
309
 
310
+ `--model` is a one-shot override for the per-agent `defaultModels` entry in `~/.hydra-acp/config.json`. It only applies at fresh session creation — resurrect and `/hydra agent` switch ignore it (resurrected sessions stay on whatever model they were last using).
311
+
309
312
  Action commands (`init`, `daemon`, `sessions`, `--help`, `--version`, `--rotate-token`) are not config knobs and are flag-only.
310
313
 
311
314
  ### Registry id resolution
312
315
 
313
- When you ask hydra to spawn an agent (via `launch <id>`, `--agent-id`, or `HYDRA_ACP_AGENT_ID`), the daemon first tries an exact match against the ACP Registry's `id` field. If nothing matches, it falls back to matching against the **npx package basename** (the segment after the last `/` and before the version `@`). That means common binary names work transparently:
316
+ When you ask hydra to spawn an agent (via `launch <agent>`, `--agent`, or `HYDRA_ACP_AGENT`), the daemon first tries an exact match against the ACP Registry's `id` field. If nothing matches, it falls back to matching against the **npx package basename** (the segment after the last `/` and before the version `@`). That means common binary names work transparently:
314
317
 
315
318
  | You spawn… | Registry `id` | Resolves via |
316
319
  |---|---|---|
@@ -344,6 +347,8 @@ When you ask hydra to spawn an agent (via `launch <id>`, `--agent-id`, or `HYDRA
344
347
 
345
348
  `daemon.sessionRecentMinutes` (default 30) controls how far back `hydra-acp sessions` (and the `/v1/sessions` REST endpoint without `?all=true`) looks for cold (disk-only) sessions. Set to `0` to never list cold sessions.
346
349
 
350
+ `tui.mouse` (default `true`) controls whether the TUI captures mouse events. With capture on, the scroll wheel drives scrollback but selecting text requires `shift+drag` to bypass mouse reporting in your terminal. Set to `false` to disable capture — plain click-drag selects text, but wheel-driven scrollback stops working (use `PgUp` / `PgDn` instead).
351
+
347
352
  ### Extensions
348
353
 
349
354
  Hydra can spawn user-configured extension processes when the daemon starts. Extensions are arbitrary commands — written in any language — that talk to the daemon over its existing REST or WSS endpoints. Hydra handles their lifecycle (spawn on start, kill on stop, auto-restart on crash with exponential backoff up to ~60s) and injects daemon connection info via env vars.