@cotal-ai/cli 0.9.1 → 0.10.1
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/command.d.ts +12 -3
- package/dist/command.d.ts.map +1 -1
- package/dist/command.js +58 -11
- package/dist/command.js.map +1 -1
- package/dist/commands/agents.d.ts +64 -0
- package/dist/commands/agents.d.ts.map +1 -0
- package/dist/commands/agents.js +83 -0
- package/dist/commands/agents.js.map +1 -0
- package/dist/commands/channels.d.ts +2 -1
- package/dist/commands/channels.d.ts.map +1 -1
- package/dist/commands/channels.js +3 -16
- package/dist/commands/channels.js.map +1 -1
- package/dist/commands/completion.d.ts +6 -5
- package/dist/commands/completion.d.ts.map +1 -1
- package/dist/commands/completion.js +37 -14
- package/dist/commands/completion.js.map +1 -1
- package/dist/commands/console.d.ts +2 -1
- package/dist/commands/console.d.ts.map +1 -1
- package/dist/commands/console.js +2 -12
- package/dist/commands/console.js.map +1 -1
- package/dist/commands/down.d.ts +3 -2
- package/dist/commands/down.d.ts.map +1 -1
- package/dist/commands/down.js +42 -16
- package/dist/commands/down.js.map +1 -1
- package/dist/commands/ext.d.ts +18 -0
- package/dist/commands/ext.d.ts.map +1 -0
- package/dist/commands/ext.js +220 -0
- package/dist/commands/ext.js.map +1 -0
- package/dist/commands/feedback.d.ts +2 -2
- package/dist/commands/feedback.d.ts.map +1 -1
- package/dist/commands/feedback.js +4 -283
- package/dist/commands/feedback.js.map +1 -1
- package/dist/commands/history.d.ts +2 -1
- package/dist/commands/history.d.ts.map +1 -1
- package/dist/commands/history.js +3 -13
- package/dist/commands/history.js.map +1 -1
- package/dist/commands/join.d.ts +2 -1
- package/dist/commands/join.d.ts.map +1 -1
- package/dist/commands/join.js +2 -18
- package/dist/commands/join.js.map +1 -1
- package/dist/commands/meshes.d.ts +2 -1
- package/dist/commands/meshes.d.ts.map +1 -1
- package/dist/commands/meshes.js +1 -1
- package/dist/commands/meshes.js.map +1 -1
- package/dist/commands/mint.d.ts +2 -1
- package/dist/commands/mint.d.ts.map +1 -1
- package/dist/commands/mint.js +3 -14
- package/dist/commands/mint.js.map +1 -1
- package/dist/commands/models.d.ts +29 -0
- package/dist/commands/models.d.ts.map +1 -0
- package/dist/commands/models.js +54 -0
- package/dist/commands/models.js.map +1 -0
- package/dist/commands/personas.d.ts +2 -2
- package/dist/commands/personas.d.ts.map +1 -1
- package/dist/commands/personas.js +23 -20
- package/dist/commands/personas.js.map +1 -1
- package/dist/commands/send.d.ts +2 -2
- package/dist/commands/send.d.ts.map +1 -1
- package/dist/commands/send.js +21 -24
- package/dist/commands/send.js.map +1 -1
- package/dist/commands/setup.d.ts +30 -8
- package/dist/commands/setup.d.ts.map +1 -1
- package/dist/commands/setup.js +151 -316
- package/dist/commands/setup.js.map +1 -1
- package/dist/commands/spawn.d.ts +122 -2
- package/dist/commands/spawn.d.ts.map +1 -1
- package/dist/commands/spawn.js +156 -49
- package/dist/commands/spawn.js.map +1 -1
- package/dist/commands/status.d.ts +15 -0
- package/dist/commands/status.d.ts.map +1 -0
- package/dist/commands/status.js +172 -0
- package/dist/commands/status.js.map +1 -0
- package/dist/commands/topology.d.ts +2 -1
- package/dist/commands/topology.d.ts.map +1 -1
- package/dist/commands/topology.js +4 -8
- package/dist/commands/topology.js.map +1 -1
- package/dist/commands/up.d.ts +9 -4
- package/dist/commands/up.d.ts.map +1 -1
- package/dist/commands/up.js +96 -56
- package/dist/commands/up.js.map +1 -1
- package/dist/commands/use.d.ts +2 -2
- package/dist/commands/use.d.ts.map +1 -1
- package/dist/commands/use.js +2 -2
- package/dist/commands/use.js.map +1 -1
- package/dist/ext-loader.d.ts +13 -0
- package/dist/ext-loader.d.ts.map +1 -0
- package/dist/ext-loader.js +121 -0
- package/dist/ext-loader.js.map +1 -0
- package/dist/index.d.ts +3 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +219 -67
- package/dist/index.js.map +1 -1
- package/dist/lib/attach-client.d.ts +20 -0
- package/dist/lib/attach-client.d.ts.map +1 -0
- package/dist/lib/attach-client.js +218 -0
- package/dist/lib/attach-client.js.map +1 -0
- package/dist/lib/completion.d.ts +8 -0
- package/dist/lib/completion.d.ts.map +1 -0
- package/dist/lib/completion.js +66 -0
- package/dist/lib/completion.js.map +1 -0
- package/dist/lib/connect.d.ts +1 -73
- package/dist/lib/connect.d.ts.map +1 -1
- package/dist/lib/connect.js +4 -90
- package/dist/lib/connect.js.map +1 -1
- package/dist/lib/control.d.ts +34 -0
- package/dist/lib/control.d.ts.map +1 -0
- package/dist/lib/control.js +65 -0
- package/dist/lib/control.js.map +1 -0
- package/dist/lib/delivery-proc.d.ts +2 -0
- package/dist/lib/delivery-proc.d.ts.map +1 -1
- package/dist/lib/manager-proc.d.ts +5 -13
- package/dist/lib/manager-proc.d.ts.map +1 -1
- package/dist/lib/manager-proc.js +3 -42
- package/dist/lib/manager-proc.js.map +1 -1
- package/dist/lib/manifest/apply.d.ts.map +1 -1
- package/dist/lib/manifest/apply.js +5 -0
- package/dist/lib/manifest/apply.js.map +1 -1
- package/dist/lib/manifest/live.d.ts.map +1 -1
- package/dist/lib/manifest/live.js +4 -1
- package/dist/lib/manifest/live.js.map +1 -1
- package/dist/lib/manifest/model.d.ts +2 -0
- package/dist/lib/manifest/model.d.ts.map +1 -1
- package/dist/lib/manifest/prepare.d.ts +2 -1
- package/dist/lib/manifest/prepare.d.ts.map +1 -1
- package/dist/lib/manifest/prepare.js +3 -1
- package/dist/lib/manifest/prepare.js.map +1 -1
- package/dist/lib/manifest/resolve.js +1 -0
- package/dist/lib/manifest/resolve.js.map +1 -1
- package/dist/lib/manifest/schema.d.ts +2 -0
- package/dist/lib/manifest/schema.d.ts.map +1 -1
- package/dist/lib/manifest/schema.js +3 -2
- package/dist/lib/manifest/schema.js.map +1 -1
- package/dist/lib/self-exec.d.ts +7 -2
- package/dist/lib/self-exec.d.ts.map +1 -1
- package/dist/lib/self-exec.js +14 -3
- package/dist/lib/self-exec.js.map +1 -1
- package/dist/lib/status.d.ts +8 -4
- package/dist/lib/status.d.ts.map +1 -1
- package/dist/lib/status.js +42 -9
- package/dist/lib/status.js.map +1 -1
- package/dist/ui.d.ts +1 -12
- package/dist/ui.d.ts.map +1 -1
- package/dist/ui.js +4 -12
- package/dist/ui.js.map +1 -1
- package/package.json +8 -6
- package/dist/commands/demo.d.ts +0 -2
- package/dist/commands/demo.d.ts.map +0 -1
- package/dist/commands/demo.js +0 -163
- package/dist/commands/demo.js.map +0 -1
- package/dist/commands/web.d.ts +0 -32
- package/dist/commands/web.d.ts.map +0 -1
- package/dist/commands/web.js +0 -307
- package/dist/commands/web.js.map +0 -1
- package/dist/web/app.js +0 -823
- package/dist/web/graph.html +0 -207
- package/dist/web/graph.js +0 -528
- package/dist/web/index.html +0 -350
package/dist/index.js
CHANGED
|
@@ -1,14 +1,16 @@
|
|
|
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,
|
|
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 {
|
|
10
|
-
import {
|
|
11
|
-
import {
|
|
10
|
+
import { spawn, spawnComplete, spawnFlags } from "./commands/spawn.js";
|
|
11
|
+
import { attach, attachFlags, managedAgentComplete, ps, psFlags, stop, stopFlags } from "./commands/agents.js";
|
|
12
|
+
import { models, modelsComplete, modelsFlags } from "./commands/models.js";
|
|
13
|
+
import { c } from "./ui.js";
|
|
12
14
|
import { personas, personasComplete } from "./commands/personas.js";
|
|
13
15
|
import { completion, completionComplete, complete } from "./commands/completion.js";
|
|
14
16
|
import { mint } from "./commands/mint.js";
|
|
@@ -16,38 +18,84 @@ import { channels } from "./commands/channels.js";
|
|
|
16
18
|
import { history } from "./commands/history.js";
|
|
17
19
|
import { feedback } from "./commands/feedback.js";
|
|
18
20
|
import { send, sendComplete } from "./commands/send.js";
|
|
21
|
+
import { ext } from "./commands/ext.js";
|
|
19
22
|
import { topology } from "./commands/topology.js";
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
*
|
|
23
|
-
* and are composed at a
|
|
23
|
+
import { status, statusFlags } from "./commands/status.js";
|
|
24
|
+
/** The minimal mesh CLI: thin NATS clients (up/join/console), plus `spawn` — an agent launch
|
|
25
|
+
* (foreground or --detach) that reuses the connector's launch recipe. Self-registers on import;
|
|
26
|
+
* heavier surfaces (the manager daemon, delivery) register the same way and are composed at a
|
|
27
|
+
* root. Flags are DECLARED (here or co-located with the command) — the dispatcher parses them,
|
|
28
|
+
* generates each command's help/usage/completion, and hands `run` the parsed args. Groups follow
|
|
29
|
+
* the user's mental model (Setup · Mesh · Messaging · Agents · Observe), and the array is ordered
|
|
30
|
+
* by group — the help listing renders groups in first-seen order. */
|
|
24
31
|
const baseCommands = [
|
|
32
|
+
// ---- Setup --------------------------------------------------------------------------------
|
|
25
33
|
{
|
|
26
34
|
kind: "command",
|
|
27
35
|
name: "setup",
|
|
28
36
|
group: "Setup",
|
|
29
|
-
summary: "guided setup
|
|
37
|
+
summary: "guided setup (configure-only: installs + seeds, launches nothing) — --yes non-interactive, --full to redo",
|
|
38
|
+
flags: setupFlags,
|
|
30
39
|
run: setup,
|
|
31
40
|
},
|
|
32
41
|
{
|
|
33
42
|
kind: "command",
|
|
34
|
-
name: "
|
|
43
|
+
name: "ext",
|
|
35
44
|
group: "Setup",
|
|
36
|
-
summary: "
|
|
37
|
-
|
|
45
|
+
summary: "operator-installed CLI extensions — add an npm package's commands to this CLI",
|
|
46
|
+
usage: "ext <add <npm-package> | remove <name> | list>",
|
|
47
|
+
positionals: "<add <npm-package> | remove <name> | list>",
|
|
48
|
+
run: ext,
|
|
38
49
|
},
|
|
50
|
+
{
|
|
51
|
+
kind: "command",
|
|
52
|
+
name: "completion",
|
|
53
|
+
group: "Setup",
|
|
54
|
+
summary: "shell completion — print a stub or install it persistently",
|
|
55
|
+
usage: "completion <bash|zsh|fish|powershell | install [shell]>",
|
|
56
|
+
positionals: "<bash|zsh|fish|powershell | install [shell]>",
|
|
57
|
+
run: completion,
|
|
58
|
+
complete: completionComplete,
|
|
59
|
+
},
|
|
60
|
+
{
|
|
61
|
+
kind: "command",
|
|
62
|
+
name: "__complete",
|
|
63
|
+
group: "Setup",
|
|
64
|
+
summary: "(internal) emit completion candidates for the current command line",
|
|
65
|
+
rawArgs: true,
|
|
66
|
+
positionals: "<words…>",
|
|
67
|
+
run: complete,
|
|
68
|
+
},
|
|
69
|
+
// ---- Mesh ---------------------------------------------------------------------------------
|
|
39
70
|
{
|
|
40
71
|
kind: "command",
|
|
41
72
|
name: "up",
|
|
42
73
|
group: "Mesh",
|
|
43
|
-
summary: "start a local nats-server
|
|
74
|
+
summary: "start a local mesh (nats-server + JetStream, JWT auth by default) — or `-f <cotal.yaml>` for a whole manifest",
|
|
75
|
+
flags: [
|
|
76
|
+
{ name: "server", type: "string", value: "<url>", description: "listen URL override" },
|
|
77
|
+
{ name: "host", type: "string", value: "<host>", description: "bind host override" },
|
|
78
|
+
{ name: "space", type: "string", value: "<s>", description: "space name (default: the folder's)" },
|
|
79
|
+
{ name: "store-dir", type: "string", value: "<dir>", description: "JetStream store directory" },
|
|
80
|
+
{ name: "channels", type: "string", value: "<a,b>", description: "channels to pre-create" },
|
|
81
|
+
{ name: "open", type: "boolean", description: "unauthenticated dev mesh (no JWT/ACLs)" },
|
|
82
|
+
{ name: "detach", type: "boolean", description: "run in the background (stop with `cotal down`)" },
|
|
83
|
+
{ name: "runtime", type: "string", value: "<pty|tmux|cmux>", description: "with -f: override the manifest's runtime" },
|
|
84
|
+
{ name: "file", type: "string", short: "f", value: "<cotal.yaml>", description: "launch a whole mesh from a manifest" },
|
|
85
|
+
{ name: "dry-run", type: "boolean", description: "with -f: print the plan, mutate nothing" },
|
|
86
|
+
],
|
|
44
87
|
run: up,
|
|
45
88
|
},
|
|
46
89
|
{
|
|
47
90
|
kind: "command",
|
|
48
91
|
name: "down",
|
|
49
92
|
group: "Mesh",
|
|
50
|
-
summary: "stop a background mesh
|
|
93
|
+
summary: "stop a background mesh — or `-f <cotal.yaml>` / `--run <id>` to tear down a `spawn -f` deploy",
|
|
94
|
+
flags: [
|
|
95
|
+
{ name: "file", type: "string", short: "f", value: "<cotal.yaml>", description: "tear down this manifest's deploy" },
|
|
96
|
+
{ name: "run", type: "string", value: "<id>", description: "tear down one `spawn -f` run by id" },
|
|
97
|
+
{ name: "dry-run", type: "boolean", description: "print the plan, mutate nothing" },
|
|
98
|
+
],
|
|
51
99
|
run: down,
|
|
52
100
|
},
|
|
53
101
|
{
|
|
@@ -57,11 +105,20 @@ const baseCommands = [
|
|
|
57
105
|
summary: "list the running meshes (a `*` marks the `current` default a bare spawn joins)",
|
|
58
106
|
run: meshes,
|
|
59
107
|
},
|
|
108
|
+
{
|
|
109
|
+
kind: "command",
|
|
110
|
+
name: "status",
|
|
111
|
+
group: "Mesh",
|
|
112
|
+
summary: "detailed read-only status for setup, local processes, recorded meshes, and the selected live mesh",
|
|
113
|
+
flags: statusFlags,
|
|
114
|
+
run: status,
|
|
115
|
+
},
|
|
60
116
|
{
|
|
61
117
|
kind: "command",
|
|
62
118
|
name: "use",
|
|
63
119
|
group: "Mesh",
|
|
64
|
-
summary: "set the default mesh for a bare `cotal spawn` when several are running
|
|
120
|
+
summary: "set the default mesh for a bare `cotal spawn` when several are running",
|
|
121
|
+
positionals: "<space>",
|
|
65
122
|
run: use,
|
|
66
123
|
complete: useComplete,
|
|
67
124
|
},
|
|
@@ -70,109 +127,204 @@ const baseCommands = [
|
|
|
70
127
|
name: "join",
|
|
71
128
|
group: "Mesh",
|
|
72
129
|
summary: "join a space (interactive) — --space <s> --name <n> [--role <r>]",
|
|
130
|
+
flags: [
|
|
131
|
+
...targetFlags,
|
|
132
|
+
{ name: "name", type: "string", value: "<n>", description: "your presence name" },
|
|
133
|
+
{ name: "role", type: "string", value: "<r>", description: "your role" },
|
|
134
|
+
{ name: "channel", type: "string", value: "<c>", description: "channel to join" },
|
|
135
|
+
{ name: "kind", type: "string", value: "<k>", description: "endpoint kind" },
|
|
136
|
+
{ name: "link", type: "string", value: "<url>", description: "join link" },
|
|
137
|
+
{ name: "token", type: "string", value: "<t>", description: "join token" },
|
|
138
|
+
{ name: "tls", type: "boolean", description: "connect over TLS" },
|
|
139
|
+
],
|
|
73
140
|
run: join,
|
|
74
141
|
},
|
|
75
142
|
{
|
|
76
143
|
kind: "command",
|
|
77
|
-
name: "
|
|
144
|
+
name: "mint",
|
|
78
145
|
group: "Mesh",
|
|
79
|
-
summary: "
|
|
146
|
+
summary: "mint a creds file for a space (auth mode); --signer emits a stripped account-signing file",
|
|
147
|
+
positionals: "<name>",
|
|
148
|
+
flags: [
|
|
149
|
+
{ name: "profile", type: "string", value: "<agent|observer|admin>", description: "cred profile (default agent)" },
|
|
150
|
+
{ name: "out", type: "string", value: "<path>", description: "output path (default .cotal/auth/creds/<name>.creds)" },
|
|
151
|
+
{ name: "signer", type: "boolean", description: "emit a stripped account-signing file instead" },
|
|
152
|
+
{ name: "force", type: "boolean", description: "with --signer: overwrite an existing file" },
|
|
153
|
+
{ name: "allow-subscribe", type: "string", value: "<a,b>", description: "read ACL override (comma-separated)" },
|
|
154
|
+
{ name: "allow-publish", type: "string", value: "<a,b>", description: "post ACL override (comma-separated)" },
|
|
155
|
+
],
|
|
156
|
+
run: mint,
|
|
157
|
+
},
|
|
158
|
+
{
|
|
159
|
+
kind: "command",
|
|
160
|
+
name: "topology",
|
|
161
|
+
group: "Mesh",
|
|
162
|
+
summary: "validate + view a mesh manifest's access graph (read-only)",
|
|
163
|
+
positionals: "<view>",
|
|
164
|
+
flags: [{ name: "file", type: "string", short: "f", value: "<cotal.yaml>", description: "the manifest to inspect" }],
|
|
165
|
+
run: topology,
|
|
166
|
+
},
|
|
167
|
+
// ---- Messaging ----------------------------------------------------------------------------
|
|
168
|
+
{
|
|
169
|
+
kind: "command",
|
|
170
|
+
name: "send",
|
|
171
|
+
group: "Messaging",
|
|
172
|
+
summary: "send one message, then exit — dm a peer, msg a channel, or ask a role",
|
|
80
173
|
usage: 'send <dm <agent> | msg <channel> | ask <role>> "<text>" [--space <s>] [--server <url>] [--creds <path>]',
|
|
174
|
+
positionals: '<dm <agent> | msg <channel> | ask <role>> "<text>"',
|
|
175
|
+
flags: [...targetFlags],
|
|
81
176
|
run: send,
|
|
82
177
|
complete: sendComplete,
|
|
83
178
|
},
|
|
84
179
|
{
|
|
85
180
|
kind: "command",
|
|
86
|
-
name: "
|
|
87
|
-
group: "
|
|
88
|
-
summary: "
|
|
89
|
-
|
|
181
|
+
name: "channels",
|
|
182
|
+
group: "Messaging",
|
|
183
|
+
summary: "inspect/set the channel registry (replay policy, description, instructions)",
|
|
184
|
+
usage: "channels <list | set <name> [--replay|--no-replay] [--desc <s>] [--instructions <s>] | default --replay|--no-replay>",
|
|
185
|
+
positionals: "<list | set <name> | default>",
|
|
186
|
+
flags: [
|
|
187
|
+
...targetFlags,
|
|
188
|
+
{ name: "replay", type: "boolean", description: "set/default: replay history to new joiners" },
|
|
189
|
+
{ name: "no-replay", type: "boolean", description: "set/default: don't replay history" },
|
|
190
|
+
{ name: "window", type: "string", value: "<n>", description: "set: replay window size" },
|
|
191
|
+
{ name: "desc", type: "string", value: "<s>", description: "set: one-line channel description" },
|
|
192
|
+
{ name: "instructions", type: "string", value: "<s>", description: "set: instructions shown to joiners" },
|
|
193
|
+
],
|
|
194
|
+
run: channels,
|
|
90
195
|
},
|
|
91
196
|
{
|
|
92
197
|
kind: "command",
|
|
93
|
-
name: "
|
|
94
|
-
group: "
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
198
|
+
name: "history",
|
|
199
|
+
group: "Messaging",
|
|
200
|
+
summary: "clear retained message history",
|
|
201
|
+
usage: "history clear --force [--dms] [--space <s>]",
|
|
202
|
+
positionals: "<clear>",
|
|
203
|
+
flags: [
|
|
204
|
+
...targetFlags,
|
|
205
|
+
{ name: "dms", type: "boolean", description: "also clear DM history" },
|
|
206
|
+
{ name: "force", type: "boolean", description: "required — clear without prompting" },
|
|
207
|
+
],
|
|
208
|
+
run: history,
|
|
100
209
|
},
|
|
101
210
|
{
|
|
102
211
|
kind: "command",
|
|
103
|
-
name: "
|
|
104
|
-
group: "
|
|
105
|
-
summary:
|
|
106
|
-
|
|
212
|
+
name: "feedback",
|
|
213
|
+
group: "Messaging",
|
|
214
|
+
summary: 'send feedback to the Cotal developers — feedback "<summary>" [--type <t>] [--email <e>]',
|
|
215
|
+
positionals: '"<summary>"',
|
|
216
|
+
flags: [
|
|
217
|
+
{ name: "type", type: "string", value: "<t>", description: "bug | idea | friction | praise | other" },
|
|
218
|
+
{ name: "details", type: "string", value: "<text>", description: "longer free-form details" },
|
|
219
|
+
{ name: "severity", type: "string", value: "<s>", description: "low | medium | high" },
|
|
220
|
+
{ name: "area", type: "string", value: "<a>", description: "the part of Cotal this concerns" },
|
|
221
|
+
{ name: "email", type: "string", value: "<e>", description: "contact email (required on the keyless public path)" },
|
|
222
|
+
{ name: "name", type: "string", value: "<n>", description: "your name (optional)" },
|
|
223
|
+
{ name: "url", type: "string", value: "<url>", description: "intake URL override" },
|
|
224
|
+
{ name: "key", type: "string", value: "<k>", description: "feedback key (default: COTAL_FEEDBACK_KEY)" },
|
|
225
|
+
],
|
|
226
|
+
run: feedback,
|
|
107
227
|
},
|
|
228
|
+
// ---- Agents -------------------------------------------------------------------------------
|
|
108
229
|
{
|
|
109
230
|
kind: "command",
|
|
110
231
|
name: "spawn",
|
|
111
232
|
group: "Agents",
|
|
112
|
-
summary: "launch an agent
|
|
233
|
+
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",
|
|
234
|
+
positionals: "[<persona>]",
|
|
235
|
+
flags: spawnFlags,
|
|
113
236
|
run: spawn,
|
|
114
237
|
complete: spawnComplete,
|
|
115
238
|
},
|
|
116
239
|
{
|
|
117
240
|
kind: "command",
|
|
118
|
-
name: "
|
|
241
|
+
name: "models",
|
|
119
242
|
group: "Agents",
|
|
120
|
-
summary: "list
|
|
121
|
-
|
|
122
|
-
|
|
243
|
+
summary: "list connector model catalogs and variants from the manager",
|
|
244
|
+
flags: modelsFlags,
|
|
245
|
+
run: models,
|
|
246
|
+
complete: modelsComplete,
|
|
123
247
|
},
|
|
124
248
|
{
|
|
125
249
|
kind: "command",
|
|
126
|
-
name: "
|
|
250
|
+
name: "start",
|
|
127
251
|
group: "Agents",
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
252
|
+
// Tombstone (stage 2a): the verb is gone, the ability moved. Errors with the replacement —
|
|
253
|
+
// never a silent alias (no fallbacks). Hidden: not part of the surface, just a signpost.
|
|
254
|
+
hidden: true,
|
|
255
|
+
rawArgs: true,
|
|
256
|
+
positionals: "…",
|
|
257
|
+
summary: "(removed) `cotal start` was merged into `cotal spawn --detach`",
|
|
258
|
+
run: async () => {
|
|
259
|
+
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)"));
|
|
260
|
+
process.exit(1);
|
|
261
|
+
},
|
|
131
262
|
},
|
|
132
263
|
{
|
|
133
264
|
kind: "command",
|
|
134
|
-
name: "
|
|
265
|
+
name: "stop",
|
|
135
266
|
group: "Agents",
|
|
136
|
-
summary: "
|
|
137
|
-
|
|
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,
|
|
267
|
+
summary: "ask the manager to stop an agent — --name <n>",
|
|
268
|
+
flags: stopFlags,
|
|
269
|
+
run: stop,
|
|
270
|
+
complete: managedAgentComplete,
|
|
145
271
|
},
|
|
146
272
|
{
|
|
147
273
|
kind: "command",
|
|
148
|
-
name: "
|
|
149
|
-
group: "
|
|
150
|
-
summary: "
|
|
151
|
-
|
|
274
|
+
name: "ps",
|
|
275
|
+
group: "Agents",
|
|
276
|
+
summary: "list managed agents + their mesh status",
|
|
277
|
+
flags: psFlags,
|
|
278
|
+
run: ps,
|
|
152
279
|
},
|
|
153
280
|
{
|
|
154
281
|
kind: "command",
|
|
155
|
-
name: "
|
|
156
|
-
group: "
|
|
157
|
-
summary: "
|
|
158
|
-
|
|
282
|
+
name: "attach",
|
|
283
|
+
group: "Agents",
|
|
284
|
+
summary: "stream + drive an agent's terminal (pty runtime) — --name <n>",
|
|
285
|
+
flags: attachFlags,
|
|
286
|
+
run: attach,
|
|
287
|
+
complete: managedAgentComplete,
|
|
159
288
|
},
|
|
160
289
|
{
|
|
161
290
|
kind: "command",
|
|
162
|
-
name: "
|
|
163
|
-
group: "
|
|
164
|
-
summary: "
|
|
165
|
-
|
|
291
|
+
name: "personas",
|
|
292
|
+
group: "Agents",
|
|
293
|
+
summary: "list/manage local personas (.cotal/agents)",
|
|
294
|
+
usage: "personas <list [-v] [--running] | show <name> | edit <name> | new <name> (--prompt <t>|--from <f>) [--role <r>] [--model <m>] | rm <name> --force>",
|
|
295
|
+
positionals: "<list | show <name> | edit <name> | new <name> | rm <name>>",
|
|
296
|
+
flags: [
|
|
297
|
+
...targetFlags,
|
|
298
|
+
{ name: "role", type: "string", value: "<r>", description: "new: the persona's role" },
|
|
299
|
+
{ name: "model", type: "string", value: "<m>", description: "new: the persona's model" },
|
|
300
|
+
{ name: "prompt", type: "string", value: "<t>", description: "new: the persona's prompt text" },
|
|
301
|
+
{ name: "from", type: "string", value: "<f>", description: "new: seed the prompt from a file" },
|
|
302
|
+
{ name: "verbose", type: "boolean", short: "v", description: "list: include role/model/description" },
|
|
303
|
+
{ name: "running", type: "boolean", description: "list: mark personas live on the mesh" },
|
|
304
|
+
{ name: "force", type: "boolean", description: "rm: required — delete without prompting" },
|
|
305
|
+
],
|
|
306
|
+
run: personas,
|
|
307
|
+
complete: personasComplete,
|
|
166
308
|
},
|
|
309
|
+
// ---- Observe ------------------------------------------------------------------------------
|
|
167
310
|
{
|
|
168
311
|
kind: "command",
|
|
169
|
-
name: "
|
|
170
|
-
group: "
|
|
171
|
-
summary:
|
|
172
|
-
|
|
312
|
+
name: "console",
|
|
313
|
+
group: "Observe",
|
|
314
|
+
summary: "live protocol view for a space — lazygit-style TUI, or a line stream on --plain",
|
|
315
|
+
flags: [...targetFlags, { name: "plain", type: "boolean", description: "line stream instead of the TUI" }],
|
|
316
|
+
run: console_,
|
|
173
317
|
},
|
|
318
|
+
// `web` (dashboard) moved out to the `cotal-web` extension package (stage 4) — installed via
|
|
319
|
+
// `cotal ext add`, it self-registers here and appears in this same surface.
|
|
174
320
|
];
|
|
175
321
|
registry.register(...baseCommands);
|
|
176
322
|
export { runCli } from "./command.js";
|
|
177
323
|
export { c, statusBadge } from "./ui.js";
|
|
324
|
+
// The full spawn grammar, for the composition root's launch-parity smoke (grammar ⊆ start-op ⊆ MCP).
|
|
325
|
+
export { spawnFlags } from "./commands/spawn.js";
|
|
326
|
+
// The launch-client timeout + the manifest launch client, for the same smoke: every launch door
|
|
327
|
+
// must outlive the manager's readiness wait (#159 B1).
|
|
328
|
+
export { START_TIMEOUT_MS } from "./lib/control.js";
|
|
329
|
+
export { launchAgent } from "./lib/manifest/live.js";
|
|
178
330
|
//# sourceMappingURL=index.js.map
|
package/dist/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAgB,MAAM,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ach 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"}
|