@cotal-ai/manager 0.167.0 → 0.168.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.
@@ -0,0 +1,125 @@
1
+ import { type Presence } from "@cotal-ai/core";
2
+ import type { ManagedAgent, FreeSlotCause } from "./manager.js";
3
+ import type { RetirementHold, TeardownTarget } from "./retirement.js";
4
+ import type { AttachEndReason } from "./session/index.js";
5
+ /** What holds the spawn ceiling's slots, as {@link Manager.occupancy} counts it (#906). */
6
+ export type Occupancy = {
7
+ managed: number;
8
+ reserved: number;
9
+ cooling: number;
10
+ launching: number;
11
+ used: number;
12
+ nextCoolingMs?: number;
13
+ };
14
+ /** Current manager-owned lifecycle operations used while allocating and releasing names. */
15
+ export interface NamesCapacityDeps {
16
+ userMode(): boolean;
17
+ authEnabled(): boolean;
18
+ maintenanceActive(): boolean;
19
+ roster(): readonly Presence[];
20
+ agentFor(name: string): ManagedAgent | undefined;
21
+ hasAgent(name: string): boolean;
22
+ removeAgent(name: string): void;
23
+ managedCount(): number;
24
+ predecessor(name: string): {
25
+ principal: string;
26
+ lifecycleUid: string;
27
+ } | undefined;
28
+ hasRetirementHold(name: string): boolean;
29
+ holdRetirement(name: string, hold: RetirementHold): void;
30
+ endSessionsForTarget(name: string, lifecycleUid: string, reason: AttachEndReason): void;
31
+ logSeatReaped: (agent: ManagedAgent, cause: FreeSlotCause) => void;
32
+ recordContinuityAtStop: (agent: ManagedAgent, boundary: string) => void;
33
+ releasedSeatPending: (agent: ManagedAgent) => boolean;
34
+ dropSeatRecord: (agent: ManagedAgent) => void;
35
+ failSeatTurns: (name: string, lifecycleUid: string) => void;
36
+ teardownTarget: (agent: ManagedAgent) => TeardownTarget;
37
+ dropInlineSnapshot: (name: string, lifecycleUid: string) => boolean;
38
+ trackDeprovision: (target: TeardownTarget) => void;
39
+ }
40
+ /** Allocation reservations, numbered-name history and cooling occupancy for one manager. */
41
+ export declare class NamesCapacity {
42
+ private readonly deps;
43
+ /** Names whose spawn is in flight (reserved synchronously before the provision await) - counted
44
+ * toward the ceiling (once per name, see {@link Manager.occupancy}) so two concurrent same-name
45
+ * spawns can't both pass the gate (P4a). Each name carries the OWNER its launch was admitted
46
+ * for, so the per-owner ceiling ({@link Manager.ownerSeats}) counts a launch from the moment it
47
+ * is reserved; a cap read only off `agents` would let a burst of concurrent spawns overshoot it,
48
+ * because none of them has a seat yet when the next one checks. */
49
+ private readonly reserved;
50
+ /** Reserved names whose launch already put its seat in `agents`. The name stays reserved until
51
+ * the launch settles, so no other spawn can take it, but the ceiling counts that seat through
52
+ * `agents` and, if it frees young, its cooling stamp, never through the reservation (#906). */
53
+ private readonly reservedLive;
54
+ /** Every numbered name {@link uniqueName} has issued. A suffix carries nothing but arrival order,
55
+ * so reissuing a freed one would give a later principal the name an earlier one posted under, and
56
+ * a reader of that name could not tell the two apart (#382). Never pruned in-process: one string
57
+ * per numbered spawn. */
58
+ private readonly issuedNumberedNames;
59
+ /** Expiry stamps (`startedAt + MIN_LIFETIME`) for slots that freed while still young - a
60
+ * count-only, lazily-pruned recycle floor (P4c). Pruned + summed into the ceiling gate. */
61
+ private cooling;
62
+ constructor(deps: NamesCapacityDeps);
63
+ reserve(name: string, owner: string): void;
64
+ placed(name: string): void;
65
+ release(name: string): void;
66
+ isReserved(name: string): boolean;
67
+ get reservedCount(): number;
68
+ numberedIssued(name: string): boolean;
69
+ rememberNumbered(name: string): void;
70
+ ownerReservations(owner: string): number;
71
+ /** Agent names become `.cotal/agents/<name>.md` paths and mesh identities, so they must be bare
72
+ * tokens, never a path - blocks traversal / arbitrary writes from a model-supplied name. In user
73
+ * mode the name is ALSO the actor, which is a narrower alphabet still; {@link spawnNameError}
74
+ * holds both halves so this door and the auto-numbering that feeds it cannot disagree. */
75
+ nameError(name: string): string | undefined;
76
+ /** The roster's LIVE occupant names (status !== offline) - occupants this manager may NOT manage
77
+ * (a foreground `cotal spawn`, a connector session, ANOTHER manager's agent). Allocating over any
78
+ * of them mints a sibling the broker/auth then refuses to admit, surfacing as the 30s launch-
79
+ * uncertain black hole. */
80
+ liveRosterNames(): Set<string>;
81
+ /** THE single name-liveness predicate both the hard-pinned collision refuse and
82
+ * uniqueName's numbering consult, so they can never drift: a name is taken if this manager
83
+ * reserves/manages/retires it OR a roster-live occupant already holds it. Pass a pre-built
84
+ * {@link liveRosterNames} set when checking many names in one allocation. */
85
+ nameInUse(name: string, live?: Set<string>): boolean;
86
+ /** First free name in the series `base`, `base_2`, `base_3`, … - checked against live slots,
87
+ * in-flight (reserved) slots, names held pending retirement, AND the live mesh roster. The
88
+ * roster check covers occupants this manager does not manage (a foreground `cotal spawn`, a
89
+ * connector session, another manager's agent): allocating their name would mint a sibling the
90
+ * broker/auth then refuses to admit, surfacing as a 30s launch-uncertain black hole instead of
91
+ * the auto-number the join path gives. Presence is ADVISORY (SPEC §6) - this is an availability
92
+ * choice at allocation, never an authority check (the broker still enforces): a stale
93
+ * still-live-looking row only costs a numbered suffix, and a missed freshly-joined occupant is
94
+ * still refused downstream exactly as before. Offline rows do NOT occupy - a properly retired
95
+ * name stays reusable. A row this manager itself confirmed retired (its alias, principal, and
96
+ * lifecycleUid all matching a {@link confirmedRetiredPredecessors} entry) does not occupy
97
+ * either, even while its advisory presence record ages out. A numbered name is never reissued
98
+ * ({@link issuedNumberedNames}), even after its holder retired. The requested base is exempt
99
+ * from that history: it is the persona's own name, which stays reusable even when it once came
100
+ * out of another persona's numbering. */
101
+ uniqueName(base: string, unavailable?: ReadonlySet<string>): string;
102
+ /** Drop a live agent's slot. When `floor` is set and the agent died young (lived less than
103
+ * MIN_LIFETIME), push a cooling stamp so the freed slot still counts toward the ceiling until it
104
+ * expires - flooring the RECYCLE, not the call, so both free paths (despawn + exit/reap) are
105
+ * covered (P4c). Floor self + own-child despawn and natural exit; NEVER admin despawn (operator
106
+ * emergency-kill stays unthrottled) and NEVER the reserved-rollback path (no cold-start paid). */
107
+ freeSlot(a: ManagedAgent, floor: boolean, cause: FreeSlotCause, acceptedBeforeFence?: boolean): void;
108
+ /** Prune expired cooling stamps (drop those at/before now) and return the live count - the
109
+ * recycle floor's contribution to the ceiling (P4c). Lazy: pruned only when the gate consults it. */
110
+ coolingCount(): number;
111
+ /** What holds the ceiling's slots, one count per seat (#906). A launching seat sits in `reserved`
112
+ * from accept until its launch settles, in `agents` once its process exists, and in `cooling`
113
+ * if it then frees young, so a reservation stops counting once it reaches `agents`. `managed` is
114
+ * what this manager's `ps` lists, `reserved` is the accepted launches that have no process yet,
115
+ * and `launching` is every unsettled launch that still holds a slot through `reserved` or
116
+ * `agents`. A launch whose seat already freed holds no slot but its cooling stamp, so its
117
+ * failure can free nothing. */
118
+ occupancy(): Occupancy;
119
+ occupancyText(o: Occupancy): string;
120
+ /** The capacity refusal states the split it enforces and whether waiting can free a slot: a
121
+ * cooling slot frees at a known time, an unsettled launch frees one only if it fails, and a
122
+ * managed seat frees one only when it is stopped. */
123
+ capacityRefusal(o: Occupancy): string;
124
+ }
125
+ //# sourceMappingURL=names-capacity.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"names-capacity.d.ts","sourceRoot":"","sources":["../src/names-capacity.ts"],"names":[],"mappings":"AACA,OAAO,EAAsF,KAAK,QAAQ,EAAE,MAAM,gBAAgB,CAAC;AAEnI,OAAO,KAAK,EAAE,YAAY,EAAE,aAAa,EAAE,MAAM,cAAc,CAAC;AAChE,OAAO,KAAK,EAAE,cAAc,EAAE,cAAc,EAAE,MAAM,iBAAiB,CAAC;AACtE,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,oBAAoB,CAAC;AAQ1D,2FAA2F;AAC3F,MAAM,MAAM,SAAS,GAAG;IAAE,OAAO,EAAE,MAAM,CAAC;IAAC,QAAQ,EAAE,MAAM,CAAC;IAAC,OAAO,EAAE,MAAM,CAAC;IAAC,SAAS,EAAE,MAAM,CAAC;IAAC,IAAI,EAAE,MAAM,CAAC;IAAC,aAAa,CAAC,EAAE,MAAM,CAAA;CAAE,CA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Aa,GAAG,MAAM;IAS9E;;;;uGAImG;IACnG,QAAQ,CAAC,CAAC,EAAE,YAAY,EAAE,KAAK,EAAE,OAAO,EAAE,KAAK,EAAE,aAAa,EAAE,mBAAmB,UAAQ,GAAG,IAAI;IA0DlG;0GACsG;IACtG,YAAY,IAAI,MAAM;IAMtB;;;;;;oCAMgC;IAChC,SAAS,IAAI,SAAS;IAoBtB,aAAa,CAAC,CAAC,EAAE,SAAS,GAAG,MAAM;IAInC;;0DAEsD;IACtD,eAAe,CAAC,CAAC,EAAE,SAAS,GAAG,MAAM;CAQtC"}
@@ -0,0 +1,236 @@
1
+ import { rmSync } from "node:fs";
2
+ import { DEV_OWNER, firstFreeName, managedRetirementOpId, parsePrincipalKey, spawnNameError } from "@cotal-ai/core";
3
+ import { MAX_AGENTS } from "./resume.js";
4
+ /** Minimum slot lifetime for rate-flooring (P4c). A slot freed (by despawn OR natural exit/reap)
5
+ * before living this long leaves a cooling stamp that still counts toward the ceiling until it
6
+ * expires - so churn (spawn↔despawn or spawn↔fast-exit) can't outrun the concurrency bound. */
7
+ const MIN_LIFETIME = 10_000;
8
+ /** The SPEC 13.6 end reason a live attach session gets when this cause frees its seat. The causes
9
+ * that free the slot in the same step that saw the seat's own process exit report `process-exit`.
10
+ * A failed recovery frees it later, after its own stop, so it reports `target-despawn` with every
11
+ * manager stop. */
12
+ const FREE_SLOT_ATTACH_END = {
13
+ "process-exit": "process-exit",
14
+ "pi-crash-loop": "process-exit",
15
+ "supervise-crash-loop": "process-exit",
16
+ "inline-snapshot-changed": "process-exit",
17
+ "pi-recovery-failed": "target-despawn",
18
+ "supervise-recovery-failed": "target-despawn",
19
+ "session-bind-failed": "target-despawn",
20
+ "resume-session-rebind-failed": "target-despawn",
21
+ "carried-fork-refused": "target-despawn",
22
+ "resume-custody-unrecorded": "target-despawn",
23
+ "supervise-record-failed": "target-despawn",
24
+ };
25
+ /** Allocation reservations, numbered-name history and cooling occupancy for one manager. */
26
+ export class NamesCapacity {
27
+ deps;
28
+ /** Names whose spawn is in flight (reserved synchronously before the provision await) - counted
29
+ * toward the ceiling (once per name, see {@link Manager.occupancy}) so two concurrent same-name
30
+ * spawns can't both pass the gate (P4a). Each name carries the OWNER its launch was admitted
31
+ * for, so the per-owner ceiling ({@link Manager.ownerSeats}) counts a launch from the moment it
32
+ * is reserved; a cap read only off `agents` would let a burst of concurrent spawns overshoot it,
33
+ * because none of them has a seat yet when the next one checks. */
34
+ reserved = new Map();
35
+ /** Reserved names whose launch already put its seat in `agents`. The name stays reserved until
36
+ * the launch settles, so no other spawn can take it, but the ceiling counts that seat through
37
+ * `agents` and, if it frees young, its cooling stamp, never through the reservation (#906). */
38
+ reservedLive = new Set();
39
+ /** Every numbered name {@link uniqueName} has issued. A suffix carries nothing but arrival order,
40
+ * so reissuing a freed one would give a later principal the name an earlier one posted under, and
41
+ * a reader of that name could not tell the two apart (#382). Never pruned in-process: one string
42
+ * per numbered spawn. */
43
+ issuedNumberedNames = new Set();
44
+ /** Expiry stamps (`startedAt + MIN_LIFETIME`) for slots that freed while still young - a
45
+ * count-only, lazily-pruned recycle floor (P4c). Pruned + summed into the ceiling gate. */
46
+ cooling = [];
47
+ constructor(deps) {
48
+ this.deps = deps;
49
+ }
50
+ reserve(name, owner) { this.reserved.set(name, owner); }
51
+ placed(name) { this.reservedLive.add(name); }
52
+ release(name) { this.reserved.delete(name); this.reservedLive.delete(name); }
53
+ isReserved(name) { return this.reserved.has(name); }
54
+ get reservedCount() { return this.reserved.size; }
55
+ numberedIssued(name) { return this.issuedNumberedNames.has(name); }
56
+ rememberNumbered(name) { this.issuedNumberedNames.add(name); }
57
+ ownerReservations(owner) {
58
+ let count = 0;
59
+ for (const [name, reservedFor] of this.reserved)
60
+ if (reservedFor === owner && !this.reservedLive.has(name))
61
+ count++;
62
+ return count;
63
+ }
64
+ /** Agent names become `.cotal/agents/<name>.md` paths and mesh identities, so they must be bare
65
+ * tokens, never a path - blocks traversal / arbitrary writes from a model-supplied name. In user
66
+ * mode the name is ALSO the actor, which is a narrower alphabet still; {@link spawnNameError}
67
+ * holds both halves so this door and the auto-numbering that feeds it cannot disagree. */
68
+ nameError(name) {
69
+ return spawnNameError(name, { userMode: this.deps.userMode() });
70
+ }
71
+ /** The roster's LIVE occupant names (status !== offline) - occupants this manager may NOT manage
72
+ * (a foreground `cotal spawn`, a connector session, ANOTHER manager's agent). Allocating over any
73
+ * of them mints a sibling the broker/auth then refuses to admit, surfacing as the 30s launch-
74
+ * uncertain black hole. */
75
+ liveRosterNames() {
76
+ const live = new Set();
77
+ for (const p of this.deps.roster()) {
78
+ if (p.status === "offline")
79
+ continue;
80
+ const predecessor = this.deps.predecessor(p.card.name);
81
+ if (predecessor !== undefined && predecessor.principal === p.card.id && predecessor.lifecycleUid === p.lifecycleUid)
82
+ continue;
83
+ live.add(p.card.name);
84
+ }
85
+ return live;
86
+ }
87
+ /** THE single name-liveness predicate both the hard-pinned collision refuse and
88
+ * uniqueName's numbering consult, so they can never drift: a name is taken if this manager
89
+ * reserves/manages/retires it OR a roster-live occupant already holds it. Pass a pre-built
90
+ * {@link liveRosterNames} set when checking many names in one allocation. */
91
+ nameInUse(name, live = this.liveRosterNames()) {
92
+ return this.deps.hasAgent(name) || this.reserved.has(name) || this.deps.hasRetirementHold(name) || live.has(name);
93
+ }
94
+ /** First free name in the series `base`, `base_2`, `base_3`, … - checked against live slots,
95
+ * in-flight (reserved) slots, names held pending retirement, AND the live mesh roster. The
96
+ * roster check covers occupants this manager does not manage (a foreground `cotal spawn`, a
97
+ * connector session, another manager's agent): allocating their name would mint a sibling the
98
+ * broker/auth then refuses to admit, surfacing as a 30s launch-uncertain black hole instead of
99
+ * the auto-number the join path gives. Presence is ADVISORY (SPEC §6) - this is an availability
100
+ * choice at allocation, never an authority check (the broker still enforces): a stale
101
+ * still-live-looking row only costs a numbered suffix, and a missed freshly-joined occupant is
102
+ * still refused downstream exactly as before. Offline rows do NOT occupy - a properly retired
103
+ * name stays reusable. A row this manager itself confirmed retired (its alias, principal, and
104
+ * lifecycleUid all matching a {@link confirmedRetiredPredecessors} entry) does not occupy
105
+ * either, even while its advisory presence record ages out. A numbered name is never reissued
106
+ * ({@link issuedNumberedNames}), even after its holder retired. The requested base is exempt
107
+ * from that history: it is the persona's own name, which stays reusable even when it once came
108
+ * out of another persona's numbering. */
109
+ uniqueName(base, unavailable = new Set()) {
110
+ const live = this.liveRosterNames();
111
+ // The cap belongs to user mode alone: only there is the numbered name the actor. Static and open
112
+ // mode key the actor on the minted nkey, so a numbered name there has no length to fit.
113
+ const name = firstFreeName(base, (n) => unavailable.has(n) || this.nameInUse(n, live) || (n !== base && this.issuedNumberedNames.has(n)), this.deps.userMode() ? { actorBound: true } : undefined);
114
+ return name;
115
+ }
116
+ /** Drop a live agent's slot. When `floor` is set and the agent died young (lived less than
117
+ * MIN_LIFETIME), push a cooling stamp so the freed slot still counts toward the ceiling until it
118
+ * expires - flooring the RECYCLE, not the call, so both free paths (despawn + exit/reap) are
119
+ * covered (P4c). Floor self + own-child despawn and natural exit; NEVER admin despawn (operator
120
+ * emergency-kill stays unthrottled) and NEVER the reserved-rollback path (no cold-start paid). */
121
+ freeSlot(a, floor, cause, acceptedBeforeFence = false) {
122
+ if (this.deps.agentFor(a.name) !== a)
123
+ return; // already freed (exit raced despawn, etc.)
124
+ // The terminalizing latch also covers exit/reap paths that never rode stopHandle.
125
+ this.deps.logSeatReaped(a, cause);
126
+ a.terminalizing = true;
127
+ this.deps.removeAgent(a.name);
128
+ this.deps.recordContinuityAtStop(a, "stop");
129
+ if (a.restart?.sessionStatePath)
130
+ rmSync(a.restart.sessionStatePath, { force: true });
131
+ // A released seat's record is the next manager's only pointer to it. It stays until the
132
+ // retirement is confirmed. Dropping it here let a refused retirement leave the lifecycle active
133
+ // with nothing left for that manager to adopt.
134
+ if (!this.deps.releasedSeatPending(a))
135
+ this.deps.dropSeatRecord(a);
136
+ if (a.seatHome)
137
+ rmSync(a.seatHome, { recursive: true, force: true });
138
+ // End any live §13.6 attach session bound to THIS incarnation with the reason its cause names.
139
+ // Fires once per agent on every free path (despawn / self-stop / reap / exit) via the `agents`
140
+ // guard above; a no-op when no plane or no live session for the target.
141
+ this.deps.endSessionsForTarget(a.name, a.lifecycleUid, typeof cause === "string" ? FREE_SLOT_ATTACH_END[cause] : "target-despawn");
142
+ // The turn relay's reap hook: every pending turn addressed to THIS incarnation is stamped
143
+ // with the death, and its deadline terminal carries it as `agentDownAt`. The addressee is gone
144
+ // and no successor may answer for it; the terminal is still the deadline's, not a new reason.
145
+ this.deps.failSeatTurns(a.name, a.lifecycleUid);
146
+ if (floor && Date.now() - a.startedAt < MIN_LIFETIME)
147
+ this.cooling.push(a.startedAt + MIN_LIFETIME);
148
+ // The departed agent's own custody reference rides the teardown: the exit that freed this slot
149
+ // is usually the seat ending, but a stop that could not prove the process gone leaves one the
150
+ // terminal must still address before it frees the alias.
151
+ const target = this.deps.teardownTarget(a);
152
+ // On a USER mesh the name is RESERVED PENDING RETIREMENT - despawn started this
153
+ // lifecycle's FULL teardown (footprint + standing-authority revoke + the auth-side retirement),
154
+ // and the alias frees only when all of it completes (not the retirement alone). The detached
155
+ // deprovision below drives it; a failed revoke or an unreachable rail keeps the name held,
156
+ // re-driven by a retry. Gate on userMode BY
157
+ // CONSTRUCTION (NEW-1): a static-auth mint has no user-mode lifecycle head to retire, so the
158
+ // reservation + rail request simply don't apply there (the incidental nkey-parse used to mask
159
+ // this, but the intent is "user mode only", not "any principal-shaped id").
160
+ if (this.deps.userMode()) {
161
+ const p = parsePrincipalKey(a.id);
162
+ if (p)
163
+ this.deps.holdRetirement(a.name, { opId: managedRetirementOpId(a.lifecycleUid), owner: p.owner, actor: p.actor, target, startedAt: Date.now() });
164
+ }
165
+ else if (this.deps.authEnabled()) {
166
+ // A STATIC lifecycle now also holds its name pending its own terminal (the
167
+ // static retirement the detached deprovision below drives) - the alias frees only when the
168
+ // gate+head terminal completes, exactly the user-mode discipline. The wire principal is the
169
+ // incarnation-unique nkey; owner is the dev owner.
170
+ this.deps.holdRetirement(a.name, { opId: managedRetirementOpId(a.lifecycleUid), owner: DEV_OWNER, actor: a.id, target, startedAt: Date.now() });
171
+ }
172
+ // Auth mode: tear down the departed agent's minted broker footprint + creds file (#159 B2). The
173
+ // process is already gone, so this must never block the slot free or throw into the caller - it runs
174
+ // detached, and a failure is logged loudly (never swallowed), not retried. The `agents` guard above
175
+ // makes this fire exactly once per agent across every free path (despawn / self-stop / reap / exit).
176
+ if (!a.suppressCleanup && (this.deps.maintenanceActive() || acceptedBeforeFence)) {
177
+ // An inline seat's snapshot goes with the seat on every mesh. An open mesh runs no teardown
178
+ // below, and a preservation cut suppresses this, so a resumed seat still finds its snapshot.
179
+ // Settled means the file is gone or the seat never had one. A removal that failed is left to
180
+ // the teardown, which retries it and reports what it could not remove.
181
+ if (a.launch.source.kind !== "inline" || this.deps.dropInlineSnapshot(a.name, a.lifecycleUid))
182
+ target.snapshotSettled = true;
183
+ this.deps.trackDeprovision(target);
184
+ }
185
+ }
186
+ /** Prune expired cooling stamps (drop those at/before now) and return the live count - the
187
+ * recycle floor's contribution to the ceiling (P4c). Lazy: pruned only when the gate consults it. */
188
+ coolingCount() {
189
+ const now = Date.now();
190
+ this.cooling = this.cooling.filter((stamp) => stamp > now);
191
+ return this.cooling.length;
192
+ }
193
+ /** What holds the ceiling's slots, one count per seat (#906). A launching seat sits in `reserved`
194
+ * from accept until its launch settles, in `agents` once its process exists, and in `cooling`
195
+ * if it then frees young, so a reservation stops counting once it reaches `agents`. `managed` is
196
+ * what this manager's `ps` lists, `reserved` is the accepted launches that have no process yet,
197
+ * and `launching` is every unsettled launch that still holds a slot through `reserved` or
198
+ * `agents`. A launch whose seat already freed holds no slot but its cooling stamp, so its
199
+ * failure can free nothing. */
200
+ occupancy() {
201
+ const cooling = this.coolingCount();
202
+ let reserved = 0;
203
+ let launching = 0;
204
+ for (const name of this.reserved.keys()) {
205
+ const placed = this.reservedLive.has(name);
206
+ if (!placed)
207
+ reserved++;
208
+ if (!placed || this.deps.hasAgent(name))
209
+ launching++;
210
+ }
211
+ const managed = this.deps.managedCount();
212
+ return {
213
+ managed,
214
+ reserved,
215
+ cooling,
216
+ launching,
217
+ used: managed + reserved + cooling,
218
+ nextCoolingMs: cooling ? Math.min(...this.cooling) - Date.now() : undefined,
219
+ };
220
+ }
221
+ occupancyText(o) {
222
+ return `${o.used} of ${MAX_AGENTS} slots: ${o.managed} managed, ${o.reserved} reserved, ${o.cooling} cooling`;
223
+ }
224
+ /** The capacity refusal states the split it enforces and whether waiting can free a slot: a
225
+ * cooling slot frees at a known time, an unsettled launch frees one only if it fails, and a
226
+ * managed seat frees one only when it is stopped. */
227
+ capacityRefusal(o) {
228
+ const remedy = o.nextCoolingMs !== undefined
229
+ ? `waiting frees a cooling slot in ${Math.ceil(o.nextCoolingMs / 1000)}s, or despawn one`
230
+ : o.launching
231
+ ? `waiting frees a slot only if an unsettled launch fails (${o.launching} pending); otherwise despawn one`
232
+ : "waiting frees no slot; despawn one";
233
+ return `at capacity (${this.occupancyText(o)}); ${remedy}`;
234
+ }
235
+ }
236
+ //# sourceMappingURL=names-capacity.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"names-capacity.js","sourceRoot":"","sources":["../src/names-capacity.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,EAAE,MAAM,SAAS,CAAC;AACjC,OAAO,EAAE,SAAS,EAAE,aAAa,EAAE,qBAAqB,EAAE,iBAAiB,EAAE,cAAc,EAAiB,MAAM,gBAAgB,CAAC;AACnI,OAAO,EAAE,UAAU,EAAE,MAAM,aAAa,CAAC;AAMzC;;gGAEgG;AAChG,MAAM,YAAY,GAAG,MAAM,CAAC;AAK5B;;;oBAGoB;AACpB,MAAM,oBAAoB,GAAuE;IAC/F,cAAc,EAAE,cAAc;IAC9B,eAAe,EAAE,cAAc;IAC/B,sBAAsB,EAAE,cAAc;IACtC,yBAAyB,EAAE,cAAc;IACzC,oBAAoB,EAAE,gBAAgB;IACt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C,SAAS;SAC5E,CAAC;IACJ,CAAC;IAED,aAAa,CAAC,CAAY;QACxB,OAAO,GAAG,CAAC,CAAC,IAAI,OAAO,UAAU,WAAW,CAAC,CAAC,OAAO,aAAa,CAAC,CAAC,QAAQ,cAAc,CAAC,CAAC,OAAO,UAAU,CAAC;IAChH,CAAC;IAED;;0DAEsD;IACtD,eAAe,CAAC,CAAY;QAC1B,MAAM,MAAM,GAAG,CAAC,CAAC,aAAa,KAAK,SAAS;YAC1C,CAAC,CAAC,mCAAmC,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC,aAAa,GAAG,IAAI,CAAC,mBAAmB;YACzF,CAAC,CAAC,CAAC,CAAC,SAAS;gBACX,CAAC,CAAC,2DAA2D,CAAC,CAAC,SAAS,kCAAkC;gBAC1G,CAAC,CAAC,oCAAoC,CAAC;QAC3C,OAAO,gBAAgB,IAAI,CAAC,aAAa,CAAC,CAAC,CAAC,MAAM,MAAM,EAAE,CAAC;IAC7D,CAAC;CACF"}
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@cotal-ai/manager",
3
3
  "description": "Cotal agent supervisor: spawns and manages mesh nodes via a pluggable runtime (pty/tmux/cmux/orca/herdr).",
4
- "version": "0.167.0",
4
+ "version": "0.168.0",
5
5
  "license": "Apache-2.0",
6
6
  "repository": {
7
7
  "type": "git",
@@ -19,9 +19,9 @@
19
19
  },
20
20
  "dependencies": {
21
21
  "@clack/prompts": "^1.0.0",
22
- "@cotal-ai/core": "0.167.0",
23
- "@cotal-ai/seat": "0.167.0",
24
- "@cotal-ai/workspace": "0.167.0",
22
+ "@cotal-ai/core": "0.168.0",
23
+ "@cotal-ai/seat": "0.168.0",
24
+ "@cotal-ai/workspace": "0.168.0",
25
25
  "@lydell/node-pty": "1.2.0-beta.12",
26
26
  "@nats-io/jetstream": "3.4.0",
27
27
  "@nats-io/kv": "3.4.0",
@@ -37,14 +37,14 @@
37
37
  "zod": "^4.4.3"
38
38
  },
39
39
  "devDependencies": {
40
- "@cotal-ai/auth": "0.167.0",
41
- "@cotal-ai/connector-claude-code": "0.167.0",
42
- "@cotal-ai/connector-codex": "0.167.0",
43
- "@cotal-ai/connector-core": "0.167.0",
44
- "@cotal-ai/connector-hermes": "0.167.0",
45
- "@cotal-ai/connector-opencode": "0.167.0",
46
- "@cotal-ai/delivery": "0.167.0",
47
- "@cotal-ai/runtime": "0.167.0",
40
+ "@cotal-ai/auth": "0.168.0",
41
+ "@cotal-ai/connector-claude-code": "0.168.0",
42
+ "@cotal-ai/connector-codex": "0.168.0",
43
+ "@cotal-ai/connector-core": "0.168.0",
44
+ "@cotal-ai/connector-hermes": "0.168.0",
45
+ "@cotal-ai/connector-opencode": "0.168.0",
46
+ "@cotal-ai/delivery": "0.168.0",
47
+ "@cotal-ai/runtime": "0.168.0",
48
48
  "@cotal-ai/smoke-kit": "0.0.0",
49
49
  "@modelcontextprotocol/sdk": "1.29.0",
50
50
  "@types/ws": "^8.18.1",