@cotal-ai/cli 0.9.1 → 0.10.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.
Files changed (130) hide show
  1. package/dist/command.d.ts +12 -3
  2. package/dist/command.d.ts.map +1 -1
  3. package/dist/command.js +58 -11
  4. package/dist/command.js.map +1 -1
  5. package/dist/commands/agents.d.ts +64 -0
  6. package/dist/commands/agents.d.ts.map +1 -0
  7. package/dist/commands/agents.js +83 -0
  8. package/dist/commands/agents.js.map +1 -0
  9. package/dist/commands/channels.d.ts +2 -1
  10. package/dist/commands/channels.d.ts.map +1 -1
  11. package/dist/commands/channels.js +3 -16
  12. package/dist/commands/channels.js.map +1 -1
  13. package/dist/commands/completion.d.ts +6 -5
  14. package/dist/commands/completion.d.ts.map +1 -1
  15. package/dist/commands/completion.js +37 -14
  16. package/dist/commands/completion.js.map +1 -1
  17. package/dist/commands/console.d.ts +2 -1
  18. package/dist/commands/console.d.ts.map +1 -1
  19. package/dist/commands/console.js +2 -12
  20. package/dist/commands/console.js.map +1 -1
  21. package/dist/commands/down.d.ts +3 -2
  22. package/dist/commands/down.d.ts.map +1 -1
  23. package/dist/commands/down.js +4 -12
  24. package/dist/commands/down.js.map +1 -1
  25. package/dist/commands/ext.d.ts +18 -0
  26. package/dist/commands/ext.d.ts.map +1 -0
  27. package/dist/commands/ext.js +220 -0
  28. package/dist/commands/ext.js.map +1 -0
  29. package/dist/commands/feedback.d.ts +2 -2
  30. package/dist/commands/feedback.d.ts.map +1 -1
  31. package/dist/commands/feedback.js +4 -283
  32. package/dist/commands/feedback.js.map +1 -1
  33. package/dist/commands/history.d.ts +2 -1
  34. package/dist/commands/history.d.ts.map +1 -1
  35. package/dist/commands/history.js +3 -13
  36. package/dist/commands/history.js.map +1 -1
  37. package/dist/commands/join.d.ts +2 -1
  38. package/dist/commands/join.d.ts.map +1 -1
  39. package/dist/commands/join.js +2 -18
  40. package/dist/commands/join.js.map +1 -1
  41. package/dist/commands/meshes.d.ts +2 -1
  42. package/dist/commands/meshes.d.ts.map +1 -1
  43. package/dist/commands/meshes.js +1 -1
  44. package/dist/commands/meshes.js.map +1 -1
  45. package/dist/commands/mint.d.ts +2 -1
  46. package/dist/commands/mint.d.ts.map +1 -1
  47. package/dist/commands/mint.js +3 -14
  48. package/dist/commands/mint.js.map +1 -1
  49. package/dist/commands/personas.d.ts +2 -2
  50. package/dist/commands/personas.d.ts.map +1 -1
  51. package/dist/commands/personas.js +23 -20
  52. package/dist/commands/personas.js.map +1 -1
  53. package/dist/commands/send.d.ts +2 -2
  54. package/dist/commands/send.d.ts.map +1 -1
  55. package/dist/commands/send.js +21 -24
  56. package/dist/commands/send.js.map +1 -1
  57. package/dist/commands/setup.d.ts +30 -8
  58. package/dist/commands/setup.d.ts.map +1 -1
  59. package/dist/commands/setup.js +151 -316
  60. package/dist/commands/setup.js.map +1 -1
  61. package/dist/commands/spawn.d.ts +117 -2
  62. package/dist/commands/spawn.d.ts.map +1 -1
  63. package/dist/commands/spawn.js +137 -48
  64. package/dist/commands/spawn.js.map +1 -1
  65. package/dist/commands/topology.d.ts +2 -1
  66. package/dist/commands/topology.d.ts.map +1 -1
  67. package/dist/commands/topology.js +4 -8
  68. package/dist/commands/topology.js.map +1 -1
  69. package/dist/commands/up.d.ts +9 -4
  70. package/dist/commands/up.d.ts.map +1 -1
  71. package/dist/commands/up.js +96 -56
  72. package/dist/commands/up.js.map +1 -1
  73. package/dist/commands/use.d.ts +2 -2
  74. package/dist/commands/use.d.ts.map +1 -1
  75. package/dist/commands/use.js +2 -2
  76. package/dist/commands/use.js.map +1 -1
  77. package/dist/ext-loader.d.ts +13 -0
  78. package/dist/ext-loader.d.ts.map +1 -0
  79. package/dist/ext-loader.js +121 -0
  80. package/dist/ext-loader.js.map +1 -0
  81. package/dist/index.d.ts +3 -0
  82. package/dist/index.d.ts.map +1 -1
  83. package/dist/index.js +203 -70
  84. package/dist/index.js.map +1 -1
  85. package/dist/lib/attach-client.d.ts +20 -0
  86. package/dist/lib/attach-client.d.ts.map +1 -0
  87. package/dist/lib/attach-client.js +218 -0
  88. package/dist/lib/attach-client.js.map +1 -0
  89. package/dist/lib/completion.d.ts +8 -0
  90. package/dist/lib/completion.d.ts.map +1 -0
  91. package/dist/lib/completion.js +66 -0
  92. package/dist/lib/completion.js.map +1 -0
  93. package/dist/lib/connect.d.ts +1 -73
  94. package/dist/lib/connect.d.ts.map +1 -1
  95. package/dist/lib/connect.js +4 -90
  96. package/dist/lib/connect.js.map +1 -1
  97. package/dist/lib/control.d.ts +34 -0
  98. package/dist/lib/control.d.ts.map +1 -0
  99. package/dist/lib/control.js +65 -0
  100. package/dist/lib/control.js.map +1 -0
  101. package/dist/lib/delivery-proc.d.ts +2 -0
  102. package/dist/lib/delivery-proc.d.ts.map +1 -1
  103. package/dist/lib/manager-proc.d.ts +5 -13
  104. package/dist/lib/manager-proc.d.ts.map +1 -1
  105. package/dist/lib/manager-proc.js +3 -42
  106. package/dist/lib/manager-proc.js.map +1 -1
  107. package/dist/lib/manifest/live.d.ts.map +1 -1
  108. package/dist/lib/manifest/live.js +4 -1
  109. package/dist/lib/manifest/live.js.map +1 -1
  110. package/dist/lib/status.d.ts +8 -4
  111. package/dist/lib/status.d.ts.map +1 -1
  112. package/dist/lib/status.js +21 -5
  113. package/dist/lib/status.js.map +1 -1
  114. package/dist/ui.d.ts +1 -12
  115. package/dist/ui.d.ts.map +1 -1
  116. package/dist/ui.js +4 -12
  117. package/dist/ui.js.map +1 -1
  118. package/package.json +8 -6
  119. package/dist/commands/demo.d.ts +0 -2
  120. package/dist/commands/demo.d.ts.map +0 -1
  121. package/dist/commands/demo.js +0 -163
  122. package/dist/commands/demo.js.map +0 -1
  123. package/dist/commands/web.d.ts +0 -32
  124. package/dist/commands/web.d.ts.map +0 -1
  125. package/dist/commands/web.js +0 -307
  126. package/dist/commands/web.js.map +0 -1
  127. package/dist/web/app.js +0 -823
  128. package/dist/web/graph.html +0 -207
  129. package/dist/web/graph.js +0 -528
  130. package/dist/web/index.html +0 -350
package/dist/index.js CHANGED
@@ -1,14 +1,15 @@
1
1
  import { registry } from "@cotal-ai/core";
2
+ import { targetFlags } from "@cotal-ai/workspace";
2
3
  import { up } from "./commands/up.js";
3
4
  import { down } from "./commands/down.js";
4
5
  import { use, useComplete } from "./commands/use.js";
5
6
  import { meshes } from "./commands/meshes.js";
6
- import { setup, go } from "./commands/setup.js";
7
+ import { setup, setupFlags } from "./commands/setup.js";
7
8
  import { join } from "./commands/join.js";
8
9
  import { console_ } from "./commands/console.js";
9
- import { demo } from "./commands/demo.js";
10
- import { web } from "./commands/web.js";
11
- import { spawn, spawnComplete } from "./commands/spawn.js";
10
+ import { spawn, spawnComplete, spawnFlags } from "./commands/spawn.js";
11
+ import { attach, attachFlags, managedAgentComplete, ps, psFlags, stop, stopFlags } from "./commands/agents.js";
12
+ import { c } from "./ui.js";
12
13
  import { personas, personasComplete } from "./commands/personas.js";
13
14
  import { completion, completionComplete, complete } from "./commands/completion.js";
14
15
  import { mint } from "./commands/mint.js";
@@ -16,38 +17,83 @@ import { channels } from "./commands/channels.js";
16
17
  import { history } from "./commands/history.js";
17
18
  import { feedback } from "./commands/feedback.js";
18
19
  import { send, sendComplete } from "./commands/send.js";
20
+ import { ext } from "./commands/ext.js";
19
21
  import { topology } from "./commands/topology.js";
20
- /** The minimal mesh CLI: thin NATS clients (up/join/console), plus `spawn` — a
21
- * foreground agent launch that reuses the connector's launch recipe. Self-registers
22
- * on import; heavier surfaces (the manager's control plane) register the same way
23
- * and are composed at a root. */
22
+ /** The minimal mesh CLI: thin NATS clients (up/join/console), plus `spawn` — an agent launch
23
+ * (foreground or --detach) that reuses the connector's launch recipe. Self-registers on import;
24
+ * heavier surfaces (the manager daemon, delivery) register the same way and are composed at a
25
+ * root. Flags are DECLARED (here or co-located with the command) — the dispatcher parses them,
26
+ * generates each command's help/usage/completion, and hands `run` the parsed args. Groups follow
27
+ * the user's mental model (Setup · Mesh · Messaging · Agents · Observe), and the array is ordered
28
+ * by group — the help listing renders groups in first-seen order. */
24
29
  const baseCommands = [
30
+ // ---- Setup --------------------------------------------------------------------------------
25
31
  {
26
32
  kind: "command",
27
33
  name: "setup",
28
34
  group: "Setup",
29
- summary: "guided setup first run walks you through it; --yes for non-interactive (agents/CI), --full to redo",
35
+ summary: "guided setup (configure-only: installs + seeds, launches nothing) --yes non-interactive, --full to redo",
36
+ flags: setupFlags,
30
37
  run: setup,
31
38
  },
32
39
  {
33
40
  kind: "command",
34
- name: "go",
41
+ name: "ext",
35
42
  group: "Setup",
36
- summary: "open or resume your session (mesh + web + manager + your cmux tabs); first run installs",
37
- run: go,
43
+ summary: "operator-installed CLI extensions add an npm package's commands to this CLI",
44
+ usage: "ext <add <npm-package> | remove <name> | list>",
45
+ positionals: "<add <npm-package> | remove <name> | list>",
46
+ run: ext,
38
47
  },
48
+ {
49
+ kind: "command",
50
+ name: "completion",
51
+ group: "Setup",
52
+ summary: "shell completion — print a stub or install it persistently",
53
+ usage: "completion <bash|zsh|fish|powershell | install [shell]>",
54
+ positionals: "<bash|zsh|fish|powershell | install [shell]>",
55
+ run: completion,
56
+ complete: completionComplete,
57
+ },
58
+ {
59
+ kind: "command",
60
+ name: "__complete",
61
+ group: "Setup",
62
+ summary: "(internal) emit completion candidates for the current command line",
63
+ rawArgs: true,
64
+ positionals: "<words…>",
65
+ run: complete,
66
+ },
67
+ // ---- Mesh ---------------------------------------------------------------------------------
39
68
  {
40
69
  kind: "command",
41
70
  name: "up",
42
71
  group: "Mesh",
43
- summary: "start a local nats-server (JetStream, JWT auth by default; --open for an unauthenticated dev mesh) — or `-f <cotal.yaml>` to launch a whole mesh from a manifest [--dry-run; --server/--host/--space/--runtime/--open override the file]",
72
+ summary: "start a local mesh (nats-server + JetStream, JWT auth by default) — or `-f <cotal.yaml>` for a whole manifest",
73
+ flags: [
74
+ { name: "server", type: "string", value: "<url>", description: "listen URL override" },
75
+ { name: "host", type: "string", value: "<host>", description: "bind host override" },
76
+ { name: "space", type: "string", value: "<s>", description: "space name (default: the folder's)" },
77
+ { name: "store-dir", type: "string", value: "<dir>", description: "JetStream store directory" },
78
+ { name: "channels", type: "string", value: "<a,b>", description: "channels to pre-create" },
79
+ { name: "open", type: "boolean", description: "unauthenticated dev mesh (no JWT/ACLs)" },
80
+ { name: "detach", type: "boolean", description: "run in the background (stop with `cotal down`)" },
81
+ { name: "runtime", type: "string", value: "<pty|tmux|cmux>", description: "with -f: override the manifest's runtime" },
82
+ { name: "file", type: "string", short: "f", value: "<cotal.yaml>", description: "launch a whole mesh from a manifest" },
83
+ { name: "dry-run", type: "boolean", description: "with -f: print the plan, mutate nothing" },
84
+ ],
44
85
  run: up,
45
86
  },
46
87
  {
47
88
  kind: "command",
48
89
  name: "down",
49
90
  group: "Mesh",
50
- summary: "stop a background mesh started with `up --detach` — or `-f <cotal.yaml>` / `--run <id>` for an ownership-scoped teardown of a `spawn -f` deploy [--dry-run] (run from its project — local only)",
91
+ summary: "stop a background mesh — or `-f <cotal.yaml>` / `--run <id>` to tear down a `spawn -f` deploy",
92
+ flags: [
93
+ { name: "file", type: "string", short: "f", value: "<cotal.yaml>", description: "tear down this manifest's deploy" },
94
+ { name: "run", type: "string", value: "<id>", description: "tear down one `spawn -f` run by id" },
95
+ { name: "dry-run", type: "boolean", description: "print the plan, mutate nothing" },
96
+ ],
51
97
  run: down,
52
98
  },
53
99
  {
@@ -61,7 +107,8 @@ const baseCommands = [
61
107
  kind: "command",
62
108
  name: "use",
63
109
  group: "Mesh",
64
- summary: "set the default mesh for a bare `cotal spawn` when several are running — use <space>",
110
+ summary: "set the default mesh for a bare `cotal spawn` when several are running",
111
+ positionals: "<space>",
65
112
  run: use,
66
113
  complete: useComplete,
67
114
  },
@@ -70,109 +117,195 @@ const baseCommands = [
70
117
  name: "join",
71
118
  group: "Mesh",
72
119
  summary: "join a space (interactive) — --space <s> --name <n> [--role <r>]",
120
+ flags: [
121
+ ...targetFlags,
122
+ { name: "name", type: "string", value: "<n>", description: "your presence name" },
123
+ { name: "role", type: "string", value: "<r>", description: "your role" },
124
+ { name: "channel", type: "string", value: "<c>", description: "channel to join" },
125
+ { name: "kind", type: "string", value: "<k>", description: "endpoint kind" },
126
+ { name: "link", type: "string", value: "<url>", description: "join link" },
127
+ { name: "token", type: "string", value: "<t>", description: "join token" },
128
+ { name: "tls", type: "boolean", description: "connect over TLS" },
129
+ ],
73
130
  run: join,
74
131
  },
75
132
  {
76
133
  kind: "command",
77
- name: "send",
134
+ name: "mint",
78
135
  group: "Mesh",
79
- summary: "send one message, then exit send <dm <agent> | msg <channel> | ask <role>> \"<text>\"",
136
+ summary: "mint a creds file for a space (auth mode); --signer emits a stripped account-signing file",
137
+ positionals: "<name>",
138
+ flags: [
139
+ { name: "profile", type: "string", value: "<agent|observer|admin>", description: "cred profile (default agent)" },
140
+ { name: "out", type: "string", value: "<path>", description: "output path (default .cotal/auth/creds/<name>.creds)" },
141
+ { name: "signer", type: "boolean", description: "emit a stripped account-signing file instead" },
142
+ { name: "force", type: "boolean", description: "with --signer: overwrite an existing file" },
143
+ { name: "allow-subscribe", type: "string", value: "<a,b>", description: "read ACL override (comma-separated)" },
144
+ { name: "allow-publish", type: "string", value: "<a,b>", description: "post ACL override (comma-separated)" },
145
+ ],
146
+ run: mint,
147
+ },
148
+ {
149
+ kind: "command",
150
+ name: "topology",
151
+ group: "Mesh",
152
+ summary: "validate + view a mesh manifest's access graph (read-only)",
153
+ positionals: "<view>",
154
+ flags: [{ name: "file", type: "string", short: "f", value: "<cotal.yaml>", description: "the manifest to inspect" }],
155
+ run: topology,
156
+ },
157
+ // ---- Messaging ----------------------------------------------------------------------------
158
+ {
159
+ kind: "command",
160
+ name: "send",
161
+ group: "Messaging",
162
+ summary: "send one message, then exit — dm a peer, msg a channel, or ask a role",
80
163
  usage: 'send <dm <agent> | msg <channel> | ask <role>> "<text>" [--space <s>] [--server <url>] [--creds <path>]',
164
+ positionals: '<dm <agent> | msg <channel> | ask <role>> "<text>"',
165
+ flags: [...targetFlags],
81
166
  run: send,
82
167
  complete: sendComplete,
83
168
  },
84
169
  {
85
170
  kind: "command",
86
- name: "console",
87
- group: "Mesh",
88
- summary: "live protocol view for a space — lazygit-style TUI, or a line stream on --plain — --space <s> [--plain]",
89
- run: console_,
171
+ name: "channels",
172
+ group: "Messaging",
173
+ summary: "inspect/set the channel registry (replay policy, description, instructions)",
174
+ usage: "channels <list | set <name> [--replay|--no-replay] [--desc <s>] [--instructions <s>] | default --replay|--no-replay>",
175
+ positionals: "<list | set <name> | default>",
176
+ flags: [
177
+ ...targetFlags,
178
+ { name: "replay", type: "boolean", description: "set/default: replay history to new joiners" },
179
+ { name: "no-replay", type: "boolean", description: "set/default: don't replay history" },
180
+ { name: "window", type: "string", value: "<n>", description: "set: replay window size" },
181
+ { name: "desc", type: "string", value: "<s>", description: "set: one-line channel description" },
182
+ { name: "instructions", type: "string", value: "<s>", description: "set: instructions shown to joiners" },
183
+ ],
184
+ run: channels,
90
185
  },
91
186
  {
92
187
  kind: "command",
93
- name: "demo",
94
- group: "Mesh",
95
- // A dev/test traffic generator (see docs/protocol-view.md) — runnable, but kept off the
96
- // top-level help so it doesn't clutter the user-facing surface.
97
- hidden: true,
98
- summary: "replay a scripted multi-agent trace (all message types) to exercise the console/web — --space <s> [--interval <ms>] [--once]",
99
- run: demo,
188
+ name: "history",
189
+ group: "Messaging",
190
+ summary: "clear retained message history",
191
+ usage: "history clear --force [--dms] [--space <s>]",
192
+ positionals: "<clear>",
193
+ flags: [
194
+ ...targetFlags,
195
+ { name: "dms", type: "boolean", description: "also clear DM history" },
196
+ { name: "force", type: "boolean", description: "required — clear without prompting" },
197
+ ],
198
+ run: history,
100
199
  },
101
200
  {
102
201
  kind: "command",
103
- name: "web",
104
- group: "Mesh",
105
- summary: "browser observability dashboard presence, channels, live feed --space <s> [--port <n>] [--no-open]",
106
- run: web,
202
+ name: "feedback",
203
+ group: "Messaging",
204
+ summary: 'send feedback to the Cotal developersfeedback "<summary>" [--type <t>] [--email <e>]',
205
+ positionals: '"<summary>"',
206
+ flags: [
207
+ { name: "type", type: "string", value: "<t>", description: "bug | idea | friction | praise | other" },
208
+ { name: "details", type: "string", value: "<text>", description: "longer free-form details" },
209
+ { name: "severity", type: "string", value: "<s>", description: "low | medium | high" },
210
+ { name: "area", type: "string", value: "<a>", description: "the part of Cotal this concerns" },
211
+ { name: "email", type: "string", value: "<e>", description: "contact email (required on the keyless public path)" },
212
+ { name: "name", type: "string", value: "<n>", description: "your name (optional)" },
213
+ { name: "url", type: "string", value: "<url>", description: "intake URL override" },
214
+ { name: "key", type: "string", value: "<k>", description: "feedback key (default: COTAL_FEEDBACK_KEY)" },
215
+ ],
216
+ run: feedback,
107
217
  },
218
+ // ---- Agents -------------------------------------------------------------------------------
108
219
  {
109
220
  kind: "command",
110
221
  name: "spawn",
111
222
  group: "Agents",
112
- summary: "launch an agent in this terminal from a file — spawn [<name-or-path>] (defaults to the `default` persona) | --name <n> --config <path> [--agent <a>] [--role <r>] [--resume <id>]",
223
+ summary: "launch an agent from a persona — spawn [<persona>] (defaults to COTAL_DEFAULT_PERSONA or `default`); --config accepts a persona name or path; foreground here, or --detach via the manager",
224
+ positionals: "[<persona>]",
225
+ flags: spawnFlags,
113
226
  run: spawn,
114
227
  complete: spawnComplete,
115
228
  },
116
229
  {
117
230
  kind: "command",
118
- name: "personas",
231
+ name: "start",
119
232
  group: "Agents",
120
- summary: "list/manage local personas (.cotal/agents) personas <list [-v] [--running] | show <name> | edit <name> | new <name> (--prompt <t>|--from <f>) [--role <r>] [--model <m>] | rm <name> --force>",
121
- run: personas,
122
- complete: personasComplete,
233
+ // Tombstone (stage 2a): the verb is gone, the ability moved. Errors with the replacement
234
+ // never a silent alias (no fallbacks). Hidden: not part of the surface, just a signpost.
235
+ hidden: true,
236
+ rawArgs: true,
237
+ positionals: "…",
238
+ summary: "(removed) `cotal start` was merged into `cotal spawn --detach`",
239
+ run: async () => {
240
+ console.error(c.red("✗ `cotal start` was merged into `cotal spawn --detach` — one launch grammar for foreground and detached (persona positional or --config; --name/--model/--cwd/--prompt/--subscribe/--allow-*/--share-tools all apply)"));
241
+ process.exit(1);
242
+ },
123
243
  },
124
244
  {
125
245
  kind: "command",
126
- name: "completion",
246
+ name: "stop",
127
247
  group: "Agents",
128
- summary: "shell completion completion <bash|zsh|fish|powershell | install [shell]>",
129
- run: completion,
130
- complete: completionComplete,
248
+ summary: "ask the manager to stop an agent — --name <n>",
249
+ flags: stopFlags,
250
+ run: stop,
251
+ complete: managedAgentComplete,
131
252
  },
132
253
  {
133
254
  kind: "command",
134
- name: "__complete",
255
+ name: "ps",
135
256
  group: "Agents",
136
- summary: "(internal) emit completion candidates for the current command line",
137
- run: complete,
138
- },
139
- {
140
- kind: "command",
141
- name: "mint",
142
- group: "Mesh",
143
- summary: "mint a creds file for a space (auth mode) — mint <name> --profile <agent|observer> [--out <path>]; --signer emits a stripped account-signing file (no operator key) for a containerized manager",
144
- run: mint,
145
- },
146
- {
147
- kind: "command",
148
- name: "topology",
149
- group: "Mesh",
150
- summary: "validate + view a mesh manifest's access graph — topology view -f <cotal.yaml> (read-only; mutates nothing)",
151
- run: topology,
257
+ summary: "list managed agents + their mesh status",
258
+ flags: psFlags,
259
+ run: ps,
152
260
  },
153
261
  {
154
262
  kind: "command",
155
- name: "channels",
156
- group: "Mesh",
157
- summary: "inspect/set channel registry channels <list | set <name> [--replay|--no-replay] [--desc <s>] [--instructions <s>] | default --replay|--no-replay>",
158
- run: channels,
263
+ name: "attach",
264
+ group: "Agents",
265
+ summary: "stream + drive an agent's terminal (pty runtime) --name <n>",
266
+ flags: attachFlags,
267
+ run: attach,
268
+ complete: managedAgentComplete,
159
269
  },
160
270
  {
161
271
  kind: "command",
162
- name: "history",
163
- group: "Mesh",
164
- summary: "clear retained message history — history clear --force [--dms] [--space <s>]",
165
- run: history,
272
+ name: "personas",
273
+ group: "Agents",
274
+ summary: "list/manage local personas (.cotal/agents)",
275
+ usage: "personas <list [-v] [--running] | show <name> | edit <name> | new <name> (--prompt <t>|--from <f>) [--role <r>] [--model <m>] | rm <name> --force>",
276
+ positionals: "<list | show <name> | edit <name> | new <name> | rm <name>>",
277
+ flags: [
278
+ ...targetFlags,
279
+ { name: "role", type: "string", value: "<r>", description: "new: the persona's role" },
280
+ { name: "model", type: "string", value: "<m>", description: "new: the persona's model" },
281
+ { name: "prompt", type: "string", value: "<t>", description: "new: the persona's prompt text" },
282
+ { name: "from", type: "string", value: "<f>", description: "new: seed the prompt from a file" },
283
+ { name: "verbose", type: "boolean", short: "v", description: "list: include role/model/description" },
284
+ { name: "running", type: "boolean", description: "list: mark personas live on the mesh" },
285
+ { name: "force", type: "boolean", description: "rm: required — delete without prompting" },
286
+ ],
287
+ run: personas,
288
+ complete: personasComplete,
166
289
  },
290
+ // ---- Observe ------------------------------------------------------------------------------
167
291
  {
168
292
  kind: "command",
169
- name: "feedback",
170
- group: "Mesh",
171
- summary: 'send feedback feedback "<summary>" [--type <t>] [--email <e>] or run the intake server: feedback --keys <keys.json> --creds <creds> [--port <n>]',
172
- run: feedback,
293
+ name: "console",
294
+ group: "Observe",
295
+ summary: "live protocol view for a space lazygit-style TUI, or a line stream on --plain",
296
+ flags: [...targetFlags, { name: "plain", type: "boolean", description: "line stream instead of the TUI" }],
297
+ run: console_,
173
298
  },
299
+ // `web` (dashboard) moved out to the `cotal-web` extension package (stage 4) — installed via
300
+ // `cotal ext add`, it self-registers here and appears in this same surface.
174
301
  ];
175
302
  registry.register(...baseCommands);
176
303
  export { runCli } from "./command.js";
177
304
  export { c, statusBadge } from "./ui.js";
305
+ // The full spawn grammar, for the composition root's launch-parity smoke (grammar ⊆ start-op ⊆ MCP).
306
+ export { spawnFlags } from "./commands/spawn.js";
307
+ // The launch-client timeout + the manifest launch client, for the same smoke: every launch door
308
+ // must outlive the manager's readiness wait (#159 B1).
309
+ export { START_TIMEOUT_MS } from "./lib/control.js";
310
+ export { launchAgent } from "./lib/manifest/live.js";
178
311
  //# sourceMapp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;YACzF,EAAE,IAAI,EAAE,OAAO,EAAE,IAAI,EAAE,SAAS,EAAE,WAAW,EAAE,yCAAyC,EAAE;SAC3F;QACD,GAAG,EAAE,QAAQ;QACb,QAAQ,EAAE,gBAAgB;KAC3B;IACD,8FAA8F;IAC9F;QACE,IAAI,EAAE,SAAS;QACf,IAAI,EAAE,SAAS;QACf,KAAK,EAAE,SAAS;QAChB,OAAO,EAAE,iFAAiF;QAC1F,KAAK,EAAE,CAAC,GAAG,WAAW,EAAE,EAAE,IAAI,EAAE,OAAO,EAAE,IAAI,EAAE,SAAS,EAAE,WAAW,EAAE,gCAAgC,EAAE,CAAC;QAC1G,GAAG,EAAE,QAAQ;KACd;IACD,6FAA6F;IAC7F,4EAA4E;CAC7E,CAAC;AAEF,QAAQ,CAAC,QAAQ,CAAC,GAAG,YAAY,CAAC,CAAC;AAEnC,OAAO,EAAE,MAAM,EAAE,MAAM,cAAc,CAAC;AACtC,OAAO,EAAE,CAAC,EAAE,WAAW,EAAE,MAAM,SAAS,CAAC;AACzC,qGAAqG;AACrG,OAAO,EAAE,UAAU,EAAE,MAAM,qBAAqB,CAAC;AACjD,gGAAgG;AAChG,uDAAuD;AACvD,OAAO,EAAE,gBAAgB,EAAE,MAAM,kBAAkB,CAAC;AACpD,OAAO,EAAE,WAAW,EAAE,MAAM,wBAAwB,CAAC"}
@@ -0,0 +1,20 @@
1
+ /**
2
+ * The detach key — Ctrl-] (0x1d) by default, as in telnet/ssh escape conventions. `COTAL_DETACH_KEY`
3
+ * rebinds it to another control key when Ctrl-] clashes with a keybinding inside the agent's TUI;
4
+ * accepts `ctrl-<char>` or `^<char>` (e.g. `ctrl-b`, `^_`). Read at point of use, per the repo's
5
+ * `COTAL_*` convention. An unparseable value — including a set-but-empty or whitespace-only one —
6
+ * throws (named), never silently falling back; the caller turns that into a loud exit. Only an
7
+ * unset var = the Ctrl-] default.
8
+ */
9
+ export declare function detachKey(): {
10
+ byte: number;
11
+ label: string;
12
+ overridden: boolean;
13
+ };
14
+ /**
15
+ * Drive a manager's attach endpoint from the terminal: raw-mode stdin streams to
16
+ * the PTY, PTY output streams to stdout, and SIGWINCH-style resizes are forwarded.
17
+ * The detach key (Ctrl-] by default, {@link detachKey}) detaches without killing the agent.
18
+ */
19
+ export declare function attachClient(url: string): Promise<void>;
20
+ //# sourceMappingURL=attach-client.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"attach-client.d.ts","sourceRoot":"","sources":["../../src/lib/attach-client.ts"],"names":[],"mappings":"AAGA;;;;;;;GAOG;AACH,wBAAgB,SAAS,IAAI;IAAE,IAAI,EAAE,MAAM,CAAC;IAAC,KAAK,EAAE,MAAM,CAAC;IAAC,UAAU,EAAE,OAAO,CAAA;CAAE,CAYhF;AAwDD;;;;GAIG;AACH,wBAAgB,YAAY,CAAC,GAAG,EAAE,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC,CAmIvD"}