@sentropic/h2a-cli 0.75.0 → 0.78.0
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/dist/index.d.ts +1 -37
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +2 -41
- package/dist/index.js.map +1 -1
- package/package.json +4 -15
- package/dist/bin.d.ts +0 -3
- package/dist/bin.d.ts.map +0 -1
- package/dist/bin.js +0 -83
- package/dist/bin.js.map +0 -1
- package/dist/cli-contract.d.ts +0 -62
- package/dist/cli-contract.d.ts.map +0 -1
- package/dist/cli-contract.js +0 -794
- package/dist/cli-contract.js.map +0 -1
- package/dist/cli.d.ts +0 -254
- package/dist/cli.d.ts.map +0 -1
- package/dist/cli.js +0 -4672
- package/dist/cli.js.map +0 -1
- package/dist/hosts/agy.d.ts +0 -14
- package/dist/hosts/agy.d.ts.map +0 -1
- package/dist/hosts/agy.js +0 -47
- package/dist/hosts/agy.js.map +0 -1
- package/dist/hosts/claude.d.ts +0 -12
- package/dist/hosts/claude.d.ts.map +0 -1
- package/dist/hosts/claude.js +0 -46
- package/dist/hosts/claude.js.map +0 -1
- package/dist/hosts/codex.d.ts +0 -65
- package/dist/hosts/codex.d.ts.map +0 -1
- package/dist/hosts/codex.js +0 -45
- package/dist/hosts/codex.js.map +0 -1
- package/dist/hosts/gemini.d.ts +0 -12
- package/dist/hosts/gemini.d.ts.map +0 -1
- package/dist/hosts/gemini.js +0 -46
- package/dist/hosts/gemini.js.map +0 -1
- package/dist/hosts/plugin.d.ts +0 -151
- package/dist/hosts/plugin.d.ts.map +0 -1
- package/dist/hosts/plugin.js +0 -188
- package/dist/hosts/plugin.js.map +0 -1
- package/dist/mcp.d.ts +0 -2
- package/dist/mcp.d.ts.map +0 -1
- package/dist/mcp.js +0 -32
- package/dist/mcp.js.map +0 -1
- package/dist/runtime/blockage/index.d.ts +0 -3
- package/dist/runtime/blockage/index.d.ts.map +0 -1
- package/dist/runtime/blockage/index.js +0 -3
- package/dist/runtime/blockage/index.js.map +0 -1
- package/dist/runtime/blockage/notifiers.d.ts +0 -52
- package/dist/runtime/blockage/notifiers.d.ts.map +0 -1
- package/dist/runtime/blockage/notifiers.js +0 -74
- package/dist/runtime/blockage/notifiers.js.map +0 -1
- package/dist/runtime/blockage/registry.d.ts +0 -30
- package/dist/runtime/blockage/registry.d.ts.map +0 -1
- package/dist/runtime/blockage/registry.js +0 -86
- package/dist/runtime/blockage/registry.js.map +0 -1
- package/dist/runtime/deploy/k8s-sidecar.d.ts +0 -92
- package/dist/runtime/deploy/k8s-sidecar.d.ts.map +0 -1
- package/dist/runtime/deploy/k8s-sidecar.js +0 -166
- package/dist/runtime/deploy/k8s-sidecar.js.map +0 -1
- package/dist/runtime/deploy/k8s-tenant.d.ts +0 -86
- package/dist/runtime/deploy/k8s-tenant.d.ts.map +0 -1
- package/dist/runtime/deploy/k8s-tenant.js +0 -255
- package/dist/runtime/deploy/k8s-tenant.js.map +0 -1
- package/dist/runtime/drive/inbox-wake.d.ts +0 -36
- package/dist/runtime/drive/inbox-wake.d.ts.map +0 -1
- package/dist/runtime/drive/inbox-wake.js +0 -50
- package/dist/runtime/drive/inbox-wake.js.map +0 -1
- package/dist/runtime/drive/index.d.ts +0 -173
- package/dist/runtime/drive/index.d.ts.map +0 -1
- package/dist/runtime/drive/index.js +0 -503
- package/dist/runtime/drive/index.js.map +0 -1
- package/dist/runtime/drumbeat/deciders.d.ts +0 -32
- package/dist/runtime/drumbeat/deciders.d.ts.map +0 -1
- package/dist/runtime/drumbeat/deciders.js +0 -65
- package/dist/runtime/drumbeat/deciders.js.map +0 -1
- package/dist/runtime/drumbeat/decisions.d.ts +0 -19
- package/dist/runtime/drumbeat/decisions.d.ts.map +0 -1
- package/dist/runtime/drumbeat/decisions.js +0 -34
- package/dist/runtime/drumbeat/decisions.js.map +0 -1
- package/dist/runtime/drumbeat/inbox-relance.d.ts +0 -29
- package/dist/runtime/drumbeat/inbox-relance.d.ts.map +0 -1
- package/dist/runtime/drumbeat/inbox-relance.js +0 -101
- package/dist/runtime/drumbeat/inbox-relance.js.map +0 -1
- package/dist/runtime/drumbeat/index.d.ts +0 -8
- package/dist/runtime/drumbeat/index.d.ts.map +0 -1
- package/dist/runtime/drumbeat/index.js +0 -8
- package/dist/runtime/drumbeat/index.js.map +0 -1
- package/dist/runtime/drumbeat/registry.d.ts +0 -60
- package/dist/runtime/drumbeat/registry.d.ts.map +0 -1
- package/dist/runtime/drumbeat/registry.js +0 -115
- package/dist/runtime/drumbeat/registry.js.map +0 -1
- package/dist/runtime/drumbeat/relaunchers.d.ts +0 -111
- package/dist/runtime/drumbeat/relaunchers.d.ts.map +0 -1
- package/dist/runtime/drumbeat/relaunchers.js +0 -260
- package/dist/runtime/drumbeat/relaunchers.js.map +0 -1
- package/dist/runtime/drumbeat/scan.d.ts +0 -36
- package/dist/runtime/drumbeat/scan.d.ts.map +0 -1
- package/dist/runtime/drumbeat/scan.js +0 -41
- package/dist/runtime/drumbeat/scan.js.map +0 -1
- package/dist/runtime/drumbeat/watch.d.ts +0 -74
- package/dist/runtime/drumbeat/watch.d.ts.map +0 -1
- package/dist/runtime/drumbeat/watch.js +0 -216
- package/dist/runtime/drumbeat/watch.js.map +0 -1
- package/dist/runtime/escalation/index.d.ts +0 -2
- package/dist/runtime/escalation/index.d.ts.map +0 -1
- package/dist/runtime/escalation/index.js +0 -2
- package/dist/runtime/escalation/index.js.map +0 -1
- package/dist/runtime/escalation/registry.d.ts +0 -44
- package/dist/runtime/escalation/registry.d.ts.map +0 -1
- package/dist/runtime/escalation/registry.js +0 -79
- package/dist/runtime/escalation/registry.js.map +0 -1
- package/dist/runtime/governance/claims.d.ts +0 -43
- package/dist/runtime/governance/claims.d.ts.map +0 -1
- package/dist/runtime/governance/claims.js +0 -93
- package/dist/runtime/governance/claims.js.map +0 -1
- package/dist/runtime/governance/conductor.d.ts +0 -79
- package/dist/runtime/governance/conductor.d.ts.map +0 -1
- package/dist/runtime/governance/conductor.js +0 -106
- package/dist/runtime/governance/conductor.js.map +0 -1
- package/dist/runtime/governance/index.d.ts +0 -5
- package/dist/runtime/governance/index.d.ts.map +0 -1
- package/dist/runtime/governance/index.js +0 -5
- package/dist/runtime/governance/index.js.map +0 -1
- package/dist/runtime/governance/launch-check.d.ts +0 -93
- package/dist/runtime/governance/launch-check.d.ts.map +0 -1
- package/dist/runtime/governance/launch-check.js +0 -113
- package/dist/runtime/governance/launch-check.js.map +0 -1
- package/dist/runtime/governance/spawns.d.ts +0 -50
- package/dist/runtime/governance/spawns.d.ts.map +0 -1
- package/dist/runtime/governance/spawns.js +0 -91
- package/dist/runtime/governance/spawns.js.map +0 -1
- package/dist/runtime/identity/bindings.d.ts +0 -84
- package/dist/runtime/identity/bindings.d.ts.map +0 -1
- package/dist/runtime/identity/bindings.js +0 -112
- package/dist/runtime/identity/bindings.js.map +0 -1
- package/dist/runtime/identity/index.d.ts +0 -11
- package/dist/runtime/identity/index.d.ts.map +0 -1
- package/dist/runtime/identity/index.js +0 -6
- package/dist/runtime/identity/index.js.map +0 -1
- package/dist/runtime/identity/live.d.ts +0 -26
- package/dist/runtime/identity/live.d.ts.map +0 -1
- package/dist/runtime/identity/live.js +0 -232
- package/dist/runtime/identity/live.js.map +0 -1
- package/dist/runtime/identity/migration.d.ts +0 -55
- package/dist/runtime/identity/migration.d.ts.map +0 -1
- package/dist/runtime/identity/migration.js +0 -100
- package/dist/runtime/identity/migration.js.map +0 -1
- package/dist/runtime/identity/readers.d.ts +0 -42
- package/dist/runtime/identity/readers.d.ts.map +0 -1
- package/dist/runtime/identity/readers.js +0 -248
- package/dist/runtime/identity/readers.js.map +0 -1
- package/dist/runtime/identity/resolver.d.ts +0 -50
- package/dist/runtime/identity/resolver.d.ts.map +0 -1
- package/dist/runtime/identity/resolver.js +0 -61
- package/dist/runtime/identity/resolver.js.map +0 -1
- package/dist/runtime/identity/workspace-id.d.ts +0 -43
- package/dist/runtime/identity/workspace-id.d.ts.map +0 -1
- package/dist/runtime/identity/workspace-id.js +0 -138
- package/dist/runtime/identity/workspace-id.js.map +0 -1
- package/dist/runtime/local-files/index.d.ts +0 -8
- package/dist/runtime/local-files/index.d.ts.map +0 -1
- package/dist/runtime/local-files/index.js +0 -8
- package/dist/runtime/local-files/index.js.map +0 -1
- package/dist/runtime/local-files/lease.d.ts +0 -62
- package/dist/runtime/local-files/lease.d.ts.map +0 -1
- package/dist/runtime/local-files/lease.js +0 -249
- package/dist/runtime/local-files/lease.js.map +0 -1
- package/dist/runtime/local-files/locks.d.ts +0 -43
- package/dist/runtime/local-files/locks.d.ts.map +0 -1
- package/dist/runtime/local-files/locks.js +0 -197
- package/dist/runtime/local-files/locks.js.map +0 -1
- package/dist/runtime/local-files/migrate.d.ts +0 -31
- package/dist/runtime/local-files/migrate.d.ts.map +0 -1
- package/dist/runtime/local-files/migrate.js +0 -104
- package/dist/runtime/local-files/migrate.js.map +0 -1
- package/dist/runtime/local-files/paths.d.ts +0 -146
- package/dist/runtime/local-files/paths.d.ts.map +0 -1
- package/dist/runtime/local-files/paths.js +0 -233
- package/dist/runtime/local-files/paths.js.map +0 -1
- package/dist/runtime/local-files/presence.d.ts +0 -80
- package/dist/runtime/local-files/presence.d.ts.map +0 -1
- package/dist/runtime/local-files/presence.js +0 -250
- package/dist/runtime/local-files/presence.js.map +0 -1
- package/dist/runtime/local-files/schema.d.ts +0 -47
- package/dist/runtime/local-files/schema.d.ts.map +0 -1
- package/dist/runtime/local-files/schema.js +0 -77
- package/dist/runtime/local-files/schema.js.map +0 -1
- package/dist/runtime/local-files/store.d.ts +0 -132
- package/dist/runtime/local-files/store.d.ts.map +0 -1
- package/dist/runtime/local-files/store.js +0 -997
- package/dist/runtime/local-files/store.js.map +0 -1
- package/dist/runtime/loop/index.d.ts +0 -73
- package/dist/runtime/loop/index.d.ts.map +0 -1
- package/dist/runtime/loop/index.js +0 -107
- package/dist/runtime/loop/index.js.map +0 -1
- package/dist/runtime/mcp/handlers.d.ts +0 -196
- package/dist/runtime/mcp/handlers.d.ts.map +0 -1
- package/dist/runtime/mcp/handlers.js +0 -1025
- package/dist/runtime/mcp/handlers.js.map +0 -1
- package/dist/runtime/mcp/index.d.ts +0 -7
- package/dist/runtime/mcp/index.d.ts.map +0 -1
- package/dist/runtime/mcp/index.js +0 -7
- package/dist/runtime/mcp/index.js.map +0 -1
- package/dist/runtime/mcp/notifications.d.ts +0 -47
- package/dist/runtime/mcp/notifications.d.ts.map +0 -1
- package/dist/runtime/mcp/notifications.js +0 -204
- package/dist/runtime/mcp/notifications.js.map +0 -1
- package/dist/runtime/mcp/server.d.ts +0 -45
- package/dist/runtime/mcp/server.d.ts.map +0 -1
- package/dist/runtime/mcp/server.js +0 -94
- package/dist/runtime/mcp/server.js.map +0 -1
- package/dist/runtime/mcp/sessions.d.ts +0 -68
- package/dist/runtime/mcp/sessions.d.ts.map +0 -1
- package/dist/runtime/mcp/sessions.js +0 -152
- package/dist/runtime/mcp/sessions.js.map +0 -1
- package/dist/runtime/mcp/stdio.d.ts +0 -72
- package/dist/runtime/mcp/stdio.d.ts.map +0 -1
- package/dist/runtime/mcp/stdio.js +0 -274
- package/dist/runtime/mcp/stdio.js.map +0 -1
- package/dist/runtime/mcp/tools.d.ts +0 -19
- package/dist/runtime/mcp/tools.d.ts.map +0 -1
- package/dist/runtime/mcp/tools.js +0 -525
- package/dist/runtime/mcp/tools.js.map +0 -1
- package/dist/runtime/mcp-http/app.d.ts +0 -33
- package/dist/runtime/mcp-http/app.d.ts.map +0 -1
- package/dist/runtime/mcp-http/app.js +0 -162
- package/dist/runtime/mcp-http/app.js.map +0 -1
- package/dist/runtime/mcp-http/hosted-mcp-server.d.ts +0 -14
- package/dist/runtime/mcp-http/hosted-mcp-server.d.ts.map +0 -1
- package/dist/runtime/mcp-http/hosted-mcp-server.js +0 -38
- package/dist/runtime/mcp-http/hosted-mcp-server.js.map +0 -1
- package/dist/runtime/mcp-http/index.d.ts +0 -18
- package/dist/runtime/mcp-http/index.d.ts.map +0 -1
- package/dist/runtime/mcp-http/index.js +0 -18
- package/dist/runtime/mcp-http/index.js.map +0 -1
- package/dist/runtime/mcp-http/main.d.ts +0 -2
- package/dist/runtime/mcp-http/main.d.ts.map +0 -1
- package/dist/runtime/mcp-http/main.js +0 -14
- package/dist/runtime/mcp-http/main.js.map +0 -1
- package/dist/runtime/mcp-http/oauth/broker-login.d.ts +0 -50
- package/dist/runtime/mcp-http/oauth/broker-login.d.ts.map +0 -1
- package/dist/runtime/mcp-http/oauth/broker-login.js +0 -41
- package/dist/runtime/mcp-http/oauth/broker-login.js.map +0 -1
- package/dist/runtime/mcp-http/oauth/broker-routes.d.ts +0 -45
- package/dist/runtime/mcp-http/oauth/broker-routes.d.ts.map +0 -1
- package/dist/runtime/mcp-http/oauth/broker-routes.js +0 -54
- package/dist/runtime/mcp-http/oauth/broker-routes.js.map +0 -1
- package/dist/runtime/mcp-http/oauth/config.d.ts +0 -49
- package/dist/runtime/mcp-http/oauth/config.d.ts.map +0 -1
- package/dist/runtime/mcp-http/oauth/config.js +0 -69
- package/dist/runtime/mcp-http/oauth/config.js.map +0 -1
- package/dist/runtime/mcp-http/oauth/crypto.d.ts +0 -14
- package/dist/runtime/mcp-http/oauth/crypto.d.ts.map +0 -1
- package/dist/runtime/mcp-http/oauth/crypto.js +0 -29
- package/dist/runtime/mcp-http/oauth/crypto.js.map +0 -1
- package/dist/runtime/mcp-http/oauth/file-store.d.ts +0 -48
- package/dist/runtime/mcp-http/oauth/file-store.d.ts.map +0 -1
- package/dist/runtime/mcp-http/oauth/file-store.js +0 -101
- package/dist/runtime/mcp-http/oauth/file-store.js.map +0 -1
- package/dist/runtime/mcp-http/oauth/hono-oauth-router.d.ts +0 -5
- package/dist/runtime/mcp-http/oauth/hono-oauth-router.d.ts.map +0 -1
- package/dist/runtime/mcp-http/oauth/hono-oauth-router.js +0 -92
- package/dist/runtime/mcp-http/oauth/hono-oauth-router.js.map +0 -1
- package/dist/runtime/mcp-http/oauth/oidc-rp.d.ts +0 -56
- package/dist/runtime/mcp-http/oauth/oidc-rp.d.ts.map +0 -1
- package/dist/runtime/mcp-http/oauth/oidc-rp.js +0 -63
- package/dist/runtime/mcp-http/oauth/oidc-rp.js.map +0 -1
- package/dist/runtime/mcp-http/oauth/redirect-uri.d.ts +0 -11
- package/dist/runtime/mcp-http/oauth/redirect-uri.d.ts.map +0 -1
- package/dist/runtime/mcp-http/oauth/redirect-uri.js +0 -29
- package/dist/runtime/mcp-http/oauth/redirect-uri.js.map +0 -1
- package/dist/runtime/mcp-http/oauth/single-tenant-provider.d.ts +0 -70
- package/dist/runtime/mcp-http/oauth/single-tenant-provider.d.ts.map +0 -1
- package/dist/runtime/mcp-http/oauth/single-tenant-provider.js +0 -247
- package/dist/runtime/mcp-http/oauth/single-tenant-provider.js.map +0 -1
- package/dist/runtime/mcp-http/oauth/tenancy.d.ts +0 -3
- package/dist/runtime/mcp-http/oauth/tenancy.d.ts.map +0 -1
- package/dist/runtime/mcp-http/oauth/tenancy.js +0 -18
- package/dist/runtime/mcp-http/oauth/tenancy.js.map +0 -1
- package/dist/runtime/mcp-http/readonly-allowlist.d.ts +0 -24
- package/dist/runtime/mcp-http/readonly-allowlist.d.ts.map +0 -1
- package/dist/runtime/mcp-http/readonly-allowlist.js +0 -43
- package/dist/runtime/mcp-http/readonly-allowlist.js.map +0 -1
- package/dist/runtime/mcp-http/serve.d.ts +0 -39
- package/dist/runtime/mcp-http/serve.d.ts.map +0 -1
- package/dist/runtime/mcp-http/serve.js +0 -100
- package/dist/runtime/mcp-http/serve.js.map +0 -1
- package/dist/runtime/mirror/accept.d.ts +0 -57
- package/dist/runtime/mirror/accept.d.ts.map +0 -1
- package/dist/runtime/mirror/accept.js +0 -70
- package/dist/runtime/mirror/accept.js.map +0 -1
- package/dist/runtime/mirror/build.d.ts +0 -44
- package/dist/runtime/mirror/build.d.ts.map +0 -1
- package/dist/runtime/mirror/build.js +0 -37
- package/dist/runtime/mirror/build.js.map +0 -1
- package/dist/runtime/mirror/index.d.ts +0 -9
- package/dist/runtime/mirror/index.d.ts.map +0 -1
- package/dist/runtime/mirror/index.js +0 -9
- package/dist/runtime/mirror/index.js.map +0 -1
- package/dist/runtime/mirror/serve.d.ts +0 -21
- package/dist/runtime/mirror/serve.d.ts.map +0 -1
- package/dist/runtime/mirror/serve.js +0 -141
- package/dist/runtime/mirror/serve.js.map +0 -1
- package/dist/runtime/nhi.d.ts +0 -15
- package/dist/runtime/nhi.d.ts.map +0 -1
- package/dist/runtime/nhi.js +0 -26
- package/dist/runtime/nhi.js.map +0 -1
- package/dist/runtime/remote/accept.d.ts +0 -50
- package/dist/runtime/remote/accept.d.ts.map +0 -1
- package/dist/runtime/remote/accept.js +0 -54
- package/dist/runtime/remote/accept.js.map +0 -1
- package/dist/runtime/remote/client.d.ts +0 -27
- package/dist/runtime/remote/client.d.ts.map +0 -1
- package/dist/runtime/remote/client.js +0 -34
- package/dist/runtime/remote/client.js.map +0 -1
- package/dist/runtime/remote/index.d.ts +0 -5
- package/dist/runtime/remote/index.d.ts.map +0 -1
- package/dist/runtime/remote/index.js +0 -5
- package/dist/runtime/remote/index.js.map +0 -1
- package/dist/runtime/remote/serve.d.ts +0 -27
- package/dist/runtime/remote/serve.d.ts.map +0 -1
- package/dist/runtime/remote/serve.js +0 -26
- package/dist/runtime/remote/serve.js.map +0 -1
- package/dist/runtime/remote/server.d.ts +0 -36
- package/dist/runtime/remote/server.d.ts.map +0 -1
- package/dist/runtime/remote/server.js +0 -100
- package/dist/runtime/remote/server.js.map +0 -1
- package/dist/runtime/sysml/client.d.ts +0 -44
- package/dist/runtime/sysml/client.d.ts.map +0 -1
- package/dist/runtime/sysml/client.js +0 -52
- package/dist/runtime/sysml/client.js.map +0 -1
- package/dist/runtime/sysml/disclosure.d.ts +0 -23
- package/dist/runtime/sysml/disclosure.d.ts.map +0 -1
- package/dist/runtime/sysml/disclosure.js +0 -53
- package/dist/runtime/sysml/disclosure.js.map +0 -1
- package/dist/runtime/sysml/index.d.ts +0 -4
- package/dist/runtime/sysml/index.d.ts.map +0 -1
- package/dist/runtime/sysml/index.js +0 -4
- package/dist/runtime/sysml/index.js.map +0 -1
- package/dist/runtime/sysml/verify.d.ts +0 -32
- package/dist/runtime/sysml/verify.d.ts.map +0 -1
- package/dist/runtime/sysml/verify.js +0 -67
- package/dist/runtime/sysml/verify.js.map +0 -1
- package/dist/runtime/upgrade/index.d.ts +0 -96
- package/dist/runtime/upgrade/index.d.ts.map +0 -1
- package/dist/runtime/upgrade/index.js +0 -185
- package/dist/runtime/upgrade/index.js.map +0 -1
- package/dist/runtime/version/agent-version.d.ts +0 -15
- package/dist/runtime/version/agent-version.d.ts.map +0 -1
- package/dist/runtime/version/agent-version.js +0 -53
- package/dist/runtime/version/agent-version.js.map +0 -1
- package/skills/h2a/SKILL.md +0 -345
package/skills/h2a/SKILL.md
DELETED
|
@@ -1,345 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
name: h2a
|
|
3
|
-
version: 0.66.0
|
|
4
|
-
description: Coordinate with other CLI agents (Claude Code, Codex, Gemini) via the h2a protocol — open a live session, list peers, exchange messages, drive a signed negotiation. Use when the user wants the current CLI to interact with another agent through a shared workspace.
|
|
5
|
-
---
|
|
6
|
-
|
|
7
|
-
# /h2a
|
|
8
|
-
|
|
9
|
-
When invoked, parse the arguments and dispatch to the matching subcommand below. If no subcommand is given, default to `status`.
|
|
10
|
-
|
|
11
|
-
```
|
|
12
|
-
/h2a → status (alias)
|
|
13
|
-
/h2a connect [root] → bootstrap a live session in this conversation
|
|
14
|
-
/h2a status → show current session state and health summary
|
|
15
|
-
/h2a discover [scope] → list live peer agents
|
|
16
|
-
/h2a conductor [workspace] → who owns/conducts a workspace right now (null = none yet)
|
|
17
|
-
/h2a conductor claim → claim conductor for a workspace (earliest live claimant wins)
|
|
18
|
-
/h2a conductor release → release conductor claim (frees it for the next claimant)
|
|
19
|
-
/h2a conductor-launch-check [workspace] → DRY-RUN: polls track; recommends launching a conductor if stalled + none live
|
|
20
|
-
/h2a conductor-launch [workspace] → EMIT a launch REQUEST to remote when stalled+no conductor; capped 1/30min, requires --confirm; h2a never spawns
|
|
21
|
-
/h2a send <peer> "<text>" → put a message envelope in a peer's inbox
|
|
22
|
-
/h2a receive → read this agent's inbox and react to new envelopes
|
|
23
|
-
/h2a negotiate <verb> ... → drive a negotiation lifecycle (open|offer|sign|stabilize)
|
|
24
|
-
/h2a model "<situation>" → propose a tailored h2a model for an org/situation
|
|
25
|
-
/h2a disconnect → cleanly close the current session
|
|
26
|
-
/h2a help → print this command map
|
|
27
|
-
```
|
|
28
|
-
|
|
29
|
-
The user's raw arguments arrive appended below the prompt; treat anything after `/h2a` as the routing token.
|
|
30
|
-
|
|
31
|
-
---
|
|
32
|
-
|
|
33
|
-
## Routing
|
|
34
|
-
|
|
35
|
-
### `/h2a connect [root]`
|
|
36
|
-
|
|
37
|
-
Bootstrap a live session so this agent can cooperate with other CLI agents.
|
|
38
|
-
|
|
39
|
-
Steps:
|
|
40
|
-
|
|
41
|
-
1. Verify the `h2a` binary is on PATH (`h2a --help`). If absent, instruct the user to run `npm i -g @sentropic/h2a-cli@latest` and stop.
|
|
42
|
-
2. Decide the shared root. If `[root]` was passed, use it; otherwise prefer `<this-workspace>/.h2a`, else `~/h2a-workspace/.h2a`. Confirm with the user only if ambiguous.
|
|
43
|
-
3. Run `h2a init --root <root>` (idempotent).
|
|
44
|
-
4. **Resolve YOUR perennial identity — do NOT invent it.** Run `h2a connect --host <h> --root <root>`; it returns the perennial instance id `host:slug(label):uuid12` (DEC-114/116), bound per `(host, workspace)` and reclaimed on reconnect — the same workspace always gets the same id (never mint `host:workspace-leaf` by hand; that bare `host:label` form is the *channel* alias, see "Identity & addressing"). Use the returned `instance`.
|
|
45
|
-
5. Call the MCP tool `h2a_session_open` with `{ instance, host, interests: { scopes: ["scope:default"], negotiations: [] } }` (instance = the resolved perennial id from step 4).
|
|
46
|
-
6. Print a short summary: instance id, session id, peers currently live, the four notification topics this session is subscribed to.
|
|
47
|
-
|
|
48
|
-
End with the cue: *"Connected. Try `/h2a discover` to see who else is around, or `/h2a send <peer> \"hi\"` to message someone."*
|
|
49
|
-
|
|
50
|
-
### `/h2a status`
|
|
51
|
-
|
|
52
|
-
Show the current connectivity state. Steps:
|
|
53
|
-
|
|
54
|
-
1. If no session has been opened yet in this conversation, say so and suggest `/h2a connect`.
|
|
55
|
-
2. Otherwise call `h2a_discover_sessions` and find the session whose `sessionId` matches the one returned by `h2a_session_open`.
|
|
56
|
-
3. Print: instance id, session id, state (`opening|live|draining|closed|expired`), `heartbeatAt`, count of peer sessions, count of unread inbox envelopes (call `h2a_inbox` with `action: "read"` and report length).
|
|
57
|
-
4. If anything looks stale (no recent heartbeat, no peers when peers were expected), suggest `/h2a connect` to re-open.
|
|
58
|
-
|
|
59
|
-
### `/h2a discover [scope]`
|
|
60
|
-
|
|
61
|
-
List currently-live peer agents.
|
|
62
|
-
|
|
63
|
-
**Peer resolution rule — always use `h2a_discover_sessions`, never grep the registry:**
|
|
64
|
-
To reach a peer by PURPOSE/role, RESOLVE it via `h2a_discover_sessions` filtering on `scope` (the canonical purpose key) or `name` (case-insensitive substring match on the agent's display name) — e.g. `{ scope: "scope:chat" }` or `{ name: "radar" }`. NEVER grep the registry for a free-text name: instance ids are workspace-derived (`host:slug(workspace):uuid`), so a name grep misses. If several sessions match, list them and let the user pick (or pick the single live one); if none match, the agent has not advertised that scope/name yet.
|
|
65
|
-
|
|
66
|
-
Steps:
|
|
67
|
-
|
|
68
|
-
1. Call `h2a_discover_sessions` with `{ scope }` (omit if no argument); add `{ name: "<substring>" }` when the user asks to find a peer by friendly name.
|
|
69
|
-
2. Filter out the current agent's own session (compare against `h2a_session_open`'s `sessionId` if known).
|
|
70
|
-
3. For each remaining session, print: `instance`, `host`, `name` (if set), `interests.scopes` (comma-joined), a relative heartbeat age ("12s ago"), and `sessionId`.
|
|
71
|
-
4. Sort by host then instance.
|
|
72
|
-
5. If empty: say so and suggest the user check that the other CLIs ran `/h2a connect` against the same root.
|
|
73
|
-
|
|
74
|
-
End with: *"To message one of these: `/h2a send <instance> \"<text>\"`."*
|
|
75
|
-
|
|
76
|
-
### `/h2a conductor [workspace]`
|
|
77
|
-
|
|
78
|
-
Resolve who owns/conducts a workspace right now. Call `h2a_conductor` (MCP) or `h2a conductor --workspace <id|path>` (CLI).
|
|
79
|
-
|
|
80
|
-
- `conductor` = the earliest live active-claimant (WP-G1b, claim-based election), or a live in-workspace agent registered with role `CONDUCTOR` (back-compat), or `null` if none. **Null is the normal/expected state** today — agents auto-register as `AGENTS`, not `CONDUCTOR`. Do NOT treat `null` as an error; it means "no designated owner yet."
|
|
81
|
-
- `claimedBy` = the instance that won via claim-based election, or `null` if resolved by role or absent.
|
|
82
|
-
- `candidates` = all in-workspace live agents (anyone who has a fresh presence record for that workspace), regardless of role.
|
|
83
|
-
- `live` = `true` if at least one candidate is present.
|
|
84
|
-
- `workspace` argument: a `ws:<uuid>` workspace id or a filesystem path (resolved via the same derivation presence uses). Defaults to cwd.
|
|
85
|
-
|
|
86
|
-
**When to use it:** call `h2a_conductor` before acting in a workspace on behalf of another agent, to check whether a designated conductor is already live. If `conductor` is non-null, coordinate with them first rather than acting unilaterally.
|
|
87
|
-
|
|
88
|
-
### `/h2a conductor claim [--instance <self>] [workspace]`
|
|
89
|
-
|
|
90
|
-
Claim the conductor role for a workspace (WP-G1b — additive, reversible). Appends a `claim` event; returns the post-claim `conductorFor` result. The caller should be itself if it won (earliest live claimant wins; a later claimant is listed in candidates but does not displace the earlier one as long as it is still live).
|
|
91
|
-
|
|
92
|
-
CLI: `h2a conductor claim --instance <self> [--workspace <id|path>] [--root <path>]`
|
|
93
|
-
MCP: `h2a_conductor_claim { instance, workspaceId|workspacePath }`
|
|
94
|
-
|
|
95
|
-
Exit 1 if `--instance` is missing.
|
|
96
|
-
|
|
97
|
-
### `/h2a conductor release [--instance <self>] [workspace]`
|
|
98
|
-
|
|
99
|
-
Release the conductor claim for a workspace (WP-G1b — additive, reversible). Appends a `release` event; returns the post-release `conductorFor` result (conductor is the next live claimant, or null if no other claimant is live).
|
|
100
|
-
|
|
101
|
-
CLI: `h2a conductor release --instance <self> [--workspace <id|path>] [--root <path>]`
|
|
102
|
-
MCP: `h2a_conductor_release { instance, workspaceId|workspacePath }`
|
|
103
|
-
|
|
104
|
-
Exit 1 if `--instance` is missing.
|
|
105
|
-
|
|
106
|
-
### `/h2a conductor-launch-check [workspace] [--idle-ms <ms>]`
|
|
107
|
-
|
|
108
|
-
**DRY-RUN (D3).** Polls `track workspace-activity` and returns a recommendation to launch a conductor if work is durably stalled and no conductor is live.
|
|
109
|
-
|
|
110
|
-
**h2a does NOT spawn anything.** A `recommendation === "launch"` result is purely advisory. The actual launch is **parked** pending a spawn-policy decision and remote-trigger support.
|
|
111
|
-
|
|
112
|
-
CLI: `h2a conductor-launch-check [--workspace <id|path>] [--root <path>] [--idle-ms <ms>]`
|
|
113
|
-
MCP: `h2a_conductor_launch_check { workspaceId|workspacePath, idleMs? }`
|
|
114
|
-
|
|
115
|
-
Return shape: `{ workspaceId, trackAvailable, conductor, conductorLive, pending, stalled, recommendation, reason, suggestedHosts? }`
|
|
116
|
-
|
|
117
|
-
- `recommendation` is `"launch"` when: no conductor is live AND track reports at least one stalled item.
|
|
118
|
-
- `suggestedHosts` = `["claude", "codex", "agy"]` (user preference order) when `recommendation === "launch"`.
|
|
119
|
-
- `trackAvailable: false` when `track` is not installed or errors — graceful, `recommendation` stays `"none"` (no false positives).
|
|
120
|
-
- `--idle-ms` is the stall threshold passed to `track workspace-activity` (default 86400000 = 24h).
|
|
121
|
-
|
|
122
|
-
A one-liner stderr note is emitted when `recommendation === "launch"` reminding callers this is a DRY-RUN.
|
|
123
|
-
|
|
124
|
-
### `/h2a conductor-launch [workspace] [--idle-ms <ms>] [--confirm] [--remote <instance>] [--instance <self>]`
|
|
125
|
-
|
|
126
|
-
**D3 EMISSION.** When `conductorLaunchCheck` returns `recommendation="launch"`, emits a `conductor-launch-request` envelope to a live remote agent.
|
|
127
|
-
|
|
128
|
-
**h2a NEVER spawns a process.** It only puts a request envelope in the remote's inbox; the remote agent executes the actual spawn.
|
|
129
|
-
|
|
130
|
-
**Gates (both must pass to emit):**
|
|
131
|
-
1. **Human confirmation:** without `--confirm`, only preview the request (`action: "would-emit"`). With `--confirm`, emit + record the marker.
|
|
132
|
-
2. **Cap/cooldown:** at most 1 emission per 30 minutes per workspace (`action: "cooldown"` if too recent).
|
|
133
|
-
|
|
134
|
-
`--instance <self>` is required with `--confirm` (identifies the sender/signer).
|
|
135
|
-
|
|
136
|
-
**Host preference in the request:** `["claude", "codex", "agy"]`.
|
|
137
|
-
|
|
138
|
-
CLI: `h2a conductor-launch [--workspace <id|path>] [--root <path>] [--idle-ms <ms>] [--confirm] [--remote <instance>] [--instance <self>]`
|
|
139
|
-
MCP: `h2a_conductor_launch { workspaceId|workspacePath, idleMs?, confirm?, remote?, instance? }`
|
|
140
|
-
|
|
141
|
-
Return shape (all cases exit 0 except user errors):
|
|
142
|
-
- `{ action: "none", reason, ...check }` — recommendation is not "launch".
|
|
143
|
-
- `{ action: "cooldown", reason, lastSpawnAt }` — cooldown not elapsed.
|
|
144
|
-
- `{ action: "would-emit", request, note }` — preview (no --confirm).
|
|
145
|
-
- `{ action: "no-remote", reason }` — no live remote agent found (--confirm but no remote).
|
|
146
|
-
- `{ action: "emitted", to, request }` — emitted + marker recorded.
|
|
147
|
-
|
|
148
|
-
### `/h2a send <peer> "<text>"`
|
|
149
|
-
|
|
150
|
-
Compose and route an envelope to a named peer.
|
|
151
|
-
|
|
152
|
-
**Resolve-before-send rule (0.59.0+):** Always resolve the peer to its LIVE full id (`host:label:uuid12`) via `h2a_discover_sessions` BEFORE sending. A bare `host:label` sent to an ambiguous target (>1 live agent sharing that alias) or a phantom target (0 live, 0 registered) is now **REFUSED** by `h2a_inbox put` / `h2a` CLI with exit 1. Never invent a sub-label. The safe pattern is: discover → pick the exact live `host:label:uuid12` → send to that. A bare alias is only acceptable for a dormant/wake-drop or exactly 1 live match (the tool surfaces the live candidate in `liveCandidate`).
|
|
153
|
-
|
|
154
|
-
Steps:
|
|
155
|
-
|
|
156
|
-
1. **Resolve the target + check liveness FIRST (`h2a_discover_sessions`).** Pick the addressing form (see "Identity & addressing"):
|
|
157
|
-
- target is a **specific live agent** → use its **full perennial id** `host:slug:uuid12` from discover (NOT the bare `host:label`, which is ambiguous when several agents share a workspace);
|
|
158
|
-
- target is a **role/channel or a known-dormant peer** → use the **channel** form `host:label`.
|
|
159
|
-
- If the user names a peer by PURPOSE/role, call `h2a_discover_sessions` with `{ scope: "<purpose>" }`. If the user names a peer by FRIENDLY NAME, call `h2a_discover_sessions` with `{ name: "<substring>" }`. NEVER grep the registry for a name: instance ids are workspace-derived (`host:slug(workspace):uuid`) so a text search misses. If several match, list and ask; if none, the agent hasn't advertised that scope/name.
|
|
160
|
-
- If `<peer>` is missing, list discover and ask the user to pick.
|
|
161
|
-
2. If `"<text>"` is missing, prompt the user for the content.
|
|
162
|
-
3. Compose an `H2AEnvelope` JSON:
|
|
163
|
-
```json
|
|
164
|
-
{
|
|
165
|
-
"protocol": "sentropic.h2a",
|
|
166
|
-
"version": "0.1",
|
|
167
|
-
"id": "env:<epoch-ms>:<4hex>",
|
|
168
|
-
"type": "event",
|
|
169
|
-
"actor": {
|
|
170
|
-
"instance": "<this-agent-instance>",
|
|
171
|
-
"role": "<this-agent-role-or-AGENTS>",
|
|
172
|
-
"scope": "<shared-scope-or-default>"
|
|
173
|
-
},
|
|
174
|
-
"body": { "kind": "message", "text": "<text>" },
|
|
175
|
-
"createdAt": "<ISO-8601-now>"
|
|
176
|
-
}
|
|
177
|
-
```
|
|
178
|
-
4. **Hard rule: the recipient MUST be host-qualified (`<host>:<label>`, e.g. `claude:radar-immobilier`). A bare label (e.g. `radar-immobilier`) is rejected — the same label can live on several hosts (claude, codex, …), so a bare label is ambiguous and routes to an orphan inbox nobody reads.**
|
|
179
|
-
|
|
180
|
-
Call `h2a_inbox` with `{ action: "put", instance: "<peer>", envelope }`.
|
|
181
|
-
|
|
182
|
-
**Conversation threading (optional, lightweight):** To continue an existing back-and-forth as a thread, add two top-level fields to the envelope JSON before putting it:
|
|
183
|
-
- `"threadId": "<id>"` — reuse the `threadId` from the peer's previous envelope, or mint a fresh one as `thr:<epoch-ms>:<4hex>` to start a new thread.
|
|
184
|
-
- `"replyTo": "<prev-envelope-id>"` — the `id` of the envelope you are replying to.
|
|
185
|
-
|
|
186
|
-
To reconstruct the ordered fil of a thread (for supervision or before opening a formal negotiation):
|
|
187
|
-
```sh
|
|
188
|
-
h2a thread --id <threadId> --instance <self-instance> --root <root>
|
|
189
|
-
```
|
|
190
|
-
This returns the envelopes (from your inbox + outbox) that share that `threadId`, sorted ascending by `createdAt`, deduped. No new store — storage is derived on the fly.
|
|
191
|
-
|
|
192
|
-
5. **Report honestly per the target's liveness** (h2a writes the inbox unconditionally — it does NOT yet error on a dead target, so YOU must say which it was):
|
|
193
|
-
- target was **live** in discover → *"Delivered to `<peer>` (live) — push fires if subscribed."*
|
|
194
|
-
- target was **NOT live** → *"`<peer>` is dormant — envelope deposited for its wake (no live session; it will only see this once woken)."* Never claim "Delivered" to a dormant/unknown peer.
|
|
195
|
-
|
|
196
|
-
For richer payloads (file pointer, deliverable, status update), set `body.kind` to a category and add the relevant fields; ask the user if ambiguous.
|
|
197
|
-
|
|
198
|
-
### `/h2a receive`
|
|
199
|
-
|
|
200
|
-
Read this agent's inbox and react to whatever is new.
|
|
201
|
-
|
|
202
|
-
Steps:
|
|
203
|
-
|
|
204
|
-
1. Call `h2a_inbox` with `{ action: "read", instance: "<this-agent-instance>" }`.
|
|
205
|
-
2. For each envelope, print: sender (`actor.instance`), `body.kind`, a short summary of the content, and the envelope id.
|
|
206
|
-
3. Ask the user what to do with each (reply via `/h2a send`, mark read by calling `h2a_inbox` with `action: "pop"`, or ignore).
|
|
207
|
-
4. If a `notifications/h2a` message with `topic: inbox.envelope_arrived` was just observed in the JSON-RPC stream, react immediately rather than waiting for the user to type `/h2a receive`.
|
|
208
|
-
|
|
209
|
-
**Pop after processing (hygiene rule):** Once you have acted on an envelope, call `h2a_inbox` with `{ action: "pop", instance: "<this-agent-instance>", envelopeId: "<id>" }` to remove it from the inbox. `read` is non-destructive — an un-popped envelope resurfaces on every subsequent poll and masks genuinely new arrivals. Pop as soon as the envelope is handled, not just when explicitly instructed.
|
|
210
|
-
|
|
211
|
-
### `/h2a negotiate <verb> ...`
|
|
212
|
-
|
|
213
|
-
Drive a step of the h2a negotiation lifecycle. The subverb is one of:
|
|
214
|
-
|
|
215
|
-
- `/h2a negotiate open <id> <scope> <parties> "<subject>"` — call `h2a_open_negotiation` with a fresh `H2ANegotiationRecord`.
|
|
216
|
-
- `/h2a negotiate offer <id> <artifact-json>` — call `h2a_offer`.
|
|
217
|
-
- `/h2a negotiate counter <id> <artifact-json>` — call `h2a_counteroffer`.
|
|
218
|
-
- `/h2a negotiate sign <id> <artifact-json> [--key <pem-path>]` — call `h2a_sign` (the private key PEM path defaults to `<root>/keys/<instance>.key.pem` from `h2a keys generate`).
|
|
219
|
-
- `/h2a negotiate stabilize <id>` — call `h2a_stabilize` once the quorum is signed.
|
|
220
|
-
- `/h2a negotiate journal <id>` — print the journal entries.
|
|
221
|
-
|
|
222
|
-
For each verb, validate the required arguments, surface any tool error verbatim, and print a one-line confirmation with the latest journal entry id.
|
|
223
|
-
|
|
224
|
-
### `/h2a model "<situation>"`
|
|
225
|
-
|
|
226
|
-
Propose a **tailored h2a model** for a free-form organization or situation (e.g. *"a hospital coordinating with insurers and a regulator"*, *"a 3-team scaled-agile delivery with AI agents"*). This is an **advisory mapping**, not a protocol action — it emits a design, it does not write to the store.
|
|
227
|
-
|
|
228
|
-
Method (follow it faithfully — do not invent vocabulary):
|
|
229
|
-
|
|
230
|
-
1. **Ground in the canonical model first.** Read `VOCABULARY.md` for the frozen roles (`PRINCIPAL`, `EXECUTIF`, `CONDUCTOR`, `AGENTS`, `CONTROL`, `MANDATAIRE`) and substrate (`SCOPE`, `CONTRACT`, `POLICY`, `ENGAGEMENT`, `MANDATE`, `SLOT`, `BINDING`, `NEGOTIATION`, `AUTHORITY`), and skim `evaluations/README.md` (the common grid) plus the closest existing use-case in `evaluations/` (A enterprise, B ecosystem, C government, D 15-conductors, E agentic squad). Reuse their patterns; do not coin new roles or artifacts.
|
|
231
|
-
2. **Map the situation** against the common grid: actors→roles, scopes, authority/mandate/signature, CONTRACT vs ENGAGEMENT vs POLICY, obligations/rights/clauses, controls, escalations, audit, deadlocks/precedence, gaps.
|
|
232
|
-
3. **Respect the invariants** (these are load-bearing):
|
|
233
|
-
- A `SCOPE` never signs; a **mandated INSTANCE** signs for a party/scope.
|
|
234
|
-
- `ENGAGEMENT` *has* a scope — it is **not** the scope. Name both.
|
|
235
|
-
- Anything that must be *owned* needs a `PRINCIPAL` (e.g. architecture ownership) — `CONTROL` only audits/vetoes, it owns nothing.
|
|
236
|
-
- `POLICY` is a durable rule (standalone *or* a clause of a CONTRACT); prefer expressing rules as engagement clauses unless they are cross-cutting/imposed.
|
|
237
|
-
- Delegated AI agents are `AGENTS` (or `SUBAGENTS`, parent-addressed) via `MANDATE`+`BINDING`, default **execution-only / non-signing**.
|
|
238
|
-
- `MANDATAIRE` presents/records, never judges; escalation targets the scope's competent authority.
|
|
239
|
-
4. **Output**, mirroring the `evaluations/*.md` structure:
|
|
240
|
-
- a **Mermaid diagram** of roles/scopes/contract flows;
|
|
241
|
-
- a **mapping table** (real element → h2a construct → note);
|
|
242
|
-
- **contracts vs policies**, a multi-actor case, **gaps**, and a one-paragraph **compatibility hypothesis**;
|
|
243
|
-
- the **nearest built-in profile** id (`A_ENTERPRISE` / `B_ECOSYSTEM` / `C_GOVERNMENT_CITIZEN` / `D_SAFE`) and how the situation differs from it.
|
|
244
|
-
5. **Offer to persist**: ask whether to save the proposal as a new `evaluations/<slug>.md` (same format) for review. Only write the file if the user agrees.
|
|
245
|
-
|
|
246
|
-
Keep it a proposal: surface assumptions and the genuine design forks (e.g. one scope with co-principals vs sub-scopes) rather than silently deciding them.
|
|
247
|
-
|
|
248
|
-
### `/h2a disconnect`
|
|
249
|
-
|
|
250
|
-
Cleanly close the current session.
|
|
251
|
-
|
|
252
|
-
Steps:
|
|
253
|
-
|
|
254
|
-
1. Call `h2a_session_close` with `{ sessionId, state: "closed" }`.
|
|
255
|
-
2. Confirm.
|
|
256
|
-
|
|
257
|
-
This is rarely needed manually — the session auto-closes when this CLI process exits, via the mcp-serve shutdown hook (DEC-051). Use it if the user wants to release the slot before exiting.
|
|
258
|
-
|
|
259
|
-
### `/h2a help`
|
|
260
|
-
|
|
261
|
-
Print the command map at the top of this file. Concise, no extra prose.
|
|
262
|
-
|
|
263
|
-
---
|
|
264
|
-
|
|
265
|
-
## Keepalive (optional, launcher-side)
|
|
266
|
-
|
|
267
|
-
When the launcher or remote infrastructure runs `h2a keepalive [--root <path>] [--interval <ms>]`, it acts as an external presence prober: it lists the live tmux panes via `tmux list-panes -aF '#{pane_id}'` and refreshes the `heartbeatAt` of every presence file whose `launchContext.tmux.pane` is still alive. This keeps pane-alive agents visible on the bus even if the host suspends the MCP child process's heartbeat interval. The `--once` flag does a single pass (useful for testing and scripting); without it, the prober loops on an unref'd interval. h2a works without it — keepalive is purely additive.
|
|
268
|
-
|
|
269
|
-
---
|
|
270
|
-
|
|
271
|
-
## Identity & addressing (DEC-114/116 — read before sending)
|
|
272
|
-
|
|
273
|
-
There are **two addressable forms**; pick deliberately:
|
|
274
|
-
|
|
275
|
-
- **Agent (perennial, specific):** `host:slug(label):uuid12` — e.g.
|
|
276
|
-
`claude:sentropic:cbf32fe0800b`. This is YOUR identity (resolved by `h2a
|
|
277
|
-
connect`, reclaimed per `(host, workspace)`) and how you address **one specific
|
|
278
|
-
live agent**. Get a peer's full id from `/h2a discover` — never guess the uuid.
|
|
279
|
-
- **Channel (role / alias):** `host:label` — e.g. `claude:sentropic-scale`. The
|
|
280
|
-
bare `host:label` form is a **named mailbox/alias**, not a specific agent; use
|
|
281
|
-
it for a role, a known-dormant peer you want to leave a message for, or a wake
|
|
282
|
-
drop. A perennial agent also reads its own `host:label` alias inbox (dedup), so
|
|
283
|
-
channel messages reach whichever agent adopts that label.
|
|
284
|
-
|
|
285
|
-
**Resolution rule — discover, never grep:** To reach a peer by PURPOSE/role, filter `h2a_discover_sessions` on `scope` (the canonical purpose key). To reach a peer by FRIENDLY NAME, filter on `name` (case-insensitive substring match on `session.name`). NEVER grep the registry file for a free-text name: instance ids are workspace-derived (`host:slug(workspace):uuid`), so a name grep misses. If several sessions match, list them and pick/ask; if none match, the agent hasn't advertised that scope/name yet.
|
|
286
|
-
|
|
287
|
-
Consequences to respect:
|
|
288
|
-
- **Addressing is case-insensitive; the label is slugified** (0.40.0+). The handle
|
|
289
|
-
is canonicalized as `lower(host):slugify(label)[:lower(uuid)]`, so `claude:matchID`
|
|
290
|
-
≡ `claude:matchid` — both reach the one inbox. The canonical channel for a label
|
|
291
|
-
is therefore `host:slugify(label)` (lowercased, `[a-z0-9._-]`), **not** the raw
|
|
292
|
-
display case. Don't tell a peer to address you by a mixed-case label; it resolves
|
|
293
|
-
the same either way. (Pre-0.40.0 deposits in a raw mis-cased dir are still read.)
|
|
294
|
-
- **One perennial id per `(host, workspace)`** — several *concurrent sessions* of
|
|
295
|
-
the same agent share that id and its inbox (they are distinguishable in
|
|
296
|
-
`/h2a discover` by `sessionId`, but inbox delivery is per-agent, not
|
|
297
|
-
per-session). To reach "whoever is working in project X", address the agent id;
|
|
298
|
-
there is no per-session inbox today.
|
|
299
|
-
- **Liveness is not enforced on send** — `h2a_inbox put` writes even to a dead
|
|
300
|
-
target. Always `/h2a discover` first and report truthfully (see `/h2a send`):
|
|
301
|
-
*delivered (live)* vs *deposited for wake (dormant)*.
|
|
302
|
-
- **`recipientLive:false` / "dormant" ≠ "not working"** — liveness means only
|
|
303
|
-
"has a fresh `mcp-serve` presence session", i.e. *reachable by a push now*. An
|
|
304
|
-
agent doing real work **headless** (e.g. `codex exec`, a one-shot review) runs
|
|
305
|
-
with **no presence session** and so shows as not-live while it is busy. **Never
|
|
306
|
-
relaunch, reassign, or duplicate a task just because a peer reads as not-live.**
|
|
307
|
-
Before assuming a peer is idle: check its `workStatus` (`working|blocked|…` in
|
|
308
|
-
discover/`h2a status`, if it sets one), look for a recent delivery/report from
|
|
309
|
-
it, or ask the human — do not infer "free" from "not-live". Liveness gates
|
|
310
|
-
*delivery*, not *work in progress*.
|
|
311
|
-
|
|
312
|
-
## Defaults and conventions
|
|
313
|
-
|
|
314
|
-
- **Auto-connect (recommended)**: register the MCP server with `mcp-serve --auto-open --host <h>` so a session opens at host startup (EVO-6/DEC-105); `/h2a disconnect` leaves early. `/h2a connect` stays available for manual/explicit connect.
|
|
315
|
-
|
|
316
|
-
- **Shared root**: same `<root>/.h2a/` for every cooperating CLI. If the user has not declared one, look for `<cwd>/.h2a/`, then `~/h2a-workspace/.h2a`, ask if neither exists.
|
|
317
|
-
- **Instance id**: the **perennial** `host:slug(label):uuid12` resolved by `h2a connect` (reclaimed per `(host, workspace)`) — do NOT hand-mint `host:workspace-leaf`; that bare form is the channel alias.
|
|
318
|
-
- **Subscriptions**: when opening a session, subscribe to all four canonical notification topics (`presence.peer_joined`, `presence.peer_left`, `inbox.envelope_arrived`, `negotiation.event_appended`) unless the user narrows the scope.
|
|
319
|
-
- **JSON-RPC notifications**: `notifications/h2a` messages arrive on stdout interleaved with tool responses. They have no `id` field and use `method: "notifications/h2a"`. React to them in real time rather than polling.
|
|
320
|
-
|
|
321
|
-
## Failure modes
|
|
322
|
-
|
|
323
|
-
- Tool returns `{ error: ... }` → surface the error verbatim, stop the current subcommand.
|
|
324
|
-
- `h2a` binary missing → install instruction + stop.
|
|
325
|
-
- Root not initialized → suggest `/h2a connect`.
|
|
326
|
-
- Session not open → suggest `/h2a connect` (do not silently bypass).
|
|
327
|
-
- Peer not in `h2a_discover_sessions` → name it, suggest checking the spelling or that the peer ran `/h2a connect` against the same root.
|
|
328
|
-
|
|
329
|
-
## Related commands shipped by `@sentropic/h2a-cli`
|
|
330
|
-
|
|
331
|
-
These can be invoked directly from the shell at any time, outside the slash-command flow:
|
|
332
|
-
|
|
333
|
-
- `h2a doctor [--root <path>]` — quick health probe.
|
|
334
|
-
- `h2a sessions [--root <path>]` — same listing as `/h2a discover` but from the shell.
|
|
335
|
-
- `h2a status [--root <path>] [--scope <s>] [--instance <i>]` — inventory of connected sessions split **direct** (local mcp-serve heartbeat) vs **indirect** (mirrored in from a remote/sidecar), with counts.
|
|
336
|
-
- `h2a keys generate --instance <id>` — produce an ed25519 PEM keypair.
|
|
337
|
-
- `h2a install-skills --host <claude|codex|gemini|agy>` — re-install or update this skill on another host. *(For **agy**/Antigravity the skill is written to the shared `~/.gemini/commands/h2a.toml`; the command then prints an `importHint` — run `agy plugin import gemini` (then `agy plugin enable h2a`) to pull it into agy. DEC-096/101.)*
|
|
338
|
-
|
|
339
|
-
**Operational surfaces** (also shell-invocable; matching `h2a_*` MCP tools where noted):
|
|
340
|
-
|
|
341
|
-
- `h2a nhi report|inventory|attest|offboard|export` — Non-Human-Identity posture / inventory / signed attestation / coordinated offboard / SPIFFE-bundle export (`h2a_nhi_*`, DEC-087..090/094).
|
|
342
|
-
- `h2a blockage raise|list|resolve` — the peer blockage feedback loop, distinct from the drumbeat and from escalation (`h2a_blockage_*`, DEC-092). Subscribed sessions get `peer.blocked`/`peer.unblocked` pushes.
|
|
343
|
-
- `h2a drumbeat record|scan|clear|escalations|watch` — anti-stall relance daemon + escalation-to-PRINCIPAL (DEC-086/091/095). Gov D2/D4 (0.64.0): a claimed conductor owns its workspace's relances — peers defer on fresh stalls (relanceCount=0); a failsafe lets a peer step in if the conductor leaves an agent stuck (relanceCount>=1, preventing workspace freeze). Cross-workspace relances emit a CoI advisory (warn, not blocked). Both behaviors are opt-in and default-allow: pass `--instance <self>` to `h2a drumbeat watch` to activate them.
|
|
344
|
-
- `h2a sysml verify --json <env> --public-key <pem>` — verify a SysML-v2 ref embedded in a signed envelope (commit-trust + content-integrity, DEC-099).
|
|
345
|
-
- `h2a host setup|status|plugin --host <codex|claude|gemini|agy>` — render the per-host MCP config / stop-hook glue (DEC-093/096).
|