borgmcp 3.6.3 → 3.8.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.
@@ -1,12 +1,3 @@
1
- /**
2
- * gh#docs-site — SOURCE-OF-TRUTH tool manifest.
3
- *
4
- * The single canonical list of borg_* MCP tool definitions. The runtime and
5
- * documentation consumers use the same pure-data list.
6
- *
7
- * PURE DATA — no imports, no side effects — so documentation builds do not pull
8
- * in the client's MCP runtime dependencies.
9
- */
10
1
  export interface ToolManifestEntry {
11
2
  name: string;
12
3
  description: string;
@@ -1 +1 @@
1
- {"version":3,"file":"tool-manifest.d.ts","sourceRoot":"","sources":["../src/tool-manifest.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AACH,MAAM,WAAW,iBAAiB;IAChC,IAAI,EAAE,MAAM,CAAC;IACb,WAAW,EAAE,MAAM,CAAC;IACpB,WAAW,EAAE;QACX,IAAI,EAAE,MAAM,CAAC;QACb,UAAU,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAC;QAChC,QAAQ,CAAC,EAAE,MAAM,EAAE,CAAC;QACpB,KAAK,CAAC,EAAE,KAAK,CAAC;YAAE,QAAQ,EAAE,MAAM,EAAE,CAAA;SAAE,CAAC,CAAC;KACvC,CAAC;CACH;AAED,eAAO,MAAM,aAAa,EAAE,iBAAiB,EA0kB5C,CAAC"}
1
+ {"version":3,"file":"tool-manifest.d.ts","sourceRoot":"","sources":["../src/tool-manifest.ts"],"names":[],"mappings":"AAWA,MAAM,WAAW,iBAAiB;IAChC,IAAI,EAAE,MAAM,CAAC;IACb,WAAW,EAAE,MAAM,CAAC;IACpB,WAAW,EAAE;QACX,IAAI,EAAE,MAAM,CAAC;QACb,UAAU,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAC;QAChC,QAAQ,CAAC,EAAE,MAAM,EAAE,CAAC;QACpB,KAAK,CAAC,EAAE,KAAK,CAAC;YAAE,QAAQ,EAAE,MAAM,EAAE,CAAA;SAAE,CAAC,CAAC;KACvC,CAAC;CACH;AAED,eAAO,MAAM,aAAa,EAAE,iBAAiB,EA0kB5C,CAAC"}
@@ -1,3 +1,13 @@
1
+ /**
2
+ * gh#docs-site — SOURCE-OF-TRUTH tool manifest.
3
+ *
4
+ * The single canonical list of borg_* MCP tool definitions. The runtime and
5
+ * documentation consumers use the same pure-data list.
6
+ *
7
+ * CONTRACT-BACKED DATA — imports only published scalar contract constants, with
8
+ * no client runtime side effects.
9
+ */
10
+ import { DECISION_TEXT_MAX_BYTES } from 'borgmcp-shared/protocol';
1
11
  export const TOOL_MANIFEST = [
2
12
  {
3
13
  name: 'borg_regen',
@@ -97,7 +107,7 @@ export const TOOL_MANIFEST = [
97
107
  },
98
108
  {
99
109
  name: 'borg_docs',
100
- description: 'Look up the Borg MCP documentation. Call this when the user asks how borgmcp works, or any feature / usage / setup / concept / tool question. Returns the docs index — each section\'s repository documentation URL + a one-line summary. Pass `topic` (e.g. "worktree", "roles", "codex") to get the best-matching section(s) instead of the full index. Then WebFetch the returned URL to read the page — borg_docs returns the index only, it does not fetch the page for you.',
110
+ description: 'Look up the Borg MCP documentation. Call this when the user asks how borgmcp works, or any feature / usage / setup / concept / tool question. Returns the docs index — each section\'s documentation URL + a one-line summary. Pass `topic` (e.g. "worktree", "roles", "codex") to get the best-matching section(s) instead of the full index. Then WebFetch the returned URL to read the page — borg_docs returns the index only, it does not fetch the page for you.',
101
111
  inputSchema: {
102
112
  type: 'object',
103
113
  properties: {
@@ -219,11 +229,11 @@ export const TOOL_MANIFEST = [
219
229
  },
220
230
  decision: {
221
231
  type: 'string',
222
- description: 'The ratified decision text. Max 2000 chars.',
232
+ description: `The ratified decision text. Max ${DECISION_TEXT_MAX_BYTES} UTF-8 bytes (bytes, not characters).`,
223
233
  },
224
234
  rationale: {
225
235
  type: 'string',
226
- description: 'Optional why. Max 2000 chars.',
236
+ description: `Optional why. Max ${DECISION_TEXT_MAX_BYTES} UTF-8 bytes (bytes, not characters).`,
227
237
  },
228
238
  },
229
239
  },
@@ -465,7 +475,7 @@ export const TOOL_MANIFEST = [
465
475
  },
466
476
  {
467
477
  name: 'borg_list-drones',
468
- description: 'List every drone in a cube when this local client has a live read, write, or manage grant. Returns id, label, role_id, agent_kind, last_seen, advisory reported model, working repository, and wake_path_alert_class. Role labels affect workflow only and grant no server permission.',
478
+ description: 'List every drone in a cube when this local client has a live read, write, or manage grant. Returns id, label, role_id, agent_kind, last_seen, advisory reported model, working repository home assignment for implementation work, and wake_path_alert_class. Route repository-specific implementation work to the drone homed in that repository; drones do not take implementation work outside their home repository. Repository homing and role labels grant no server permission, and the server does not enforce repository homing.',
469
479
  inputSchema: {
470
480
  type: 'object',
471
481
  properties: {
@@ -1 +1 @@
1
- {"version":3,"file":"tool-manifest.js","sourceRoot":"","sources":["../src/tool-manifest.ts"],"names":[],"mappings":"AAoBA,MAAM,CAAC,MAAM,aAAa,GAAwB;IAC1C;QACE,IAAI,EAAE,YAAY;QAClB,WAAW,EACT,wEAAwE;YACxE,qFAAqF;YACrF,uFAAuF;YACvF,qFAAqF;YACrF,sCAAsC;YACtC,sFAAsF;YACtF,8EAA8E;YAC9E,yFAAyF;YACzF,iHAAiH;QACnH,WAAW,EAAE;YACX,IAAI,EAAE,QAAQ;YACd,UAAU,EAAE;gBACV,KAAK,EAAE;oBACL,IAAI,EAAE,QAAQ;oBACd,WAAW,EACT,uQAAuQ;iBAC1Q;gBACD,IAAI,EAAE;oBACJ,IAAI,EAAE,QAAQ;oBACd,IAAI,EAAE,CAAC,MAAM,EAAE,MAAM,CAAC;oBACtB,WAAW,EACT,6MAA6M;iBAChN;gBACD,KAAK,EAAE;oBACL,IAAI,EAAE,QAAQ;oBACd,SAAS,EAAE,CAAC;oBACZ,SAAS,EAAE,GAAG;oBACd,OAAO,EAAE,kCAAkC;oBAC3C,WAAW,EACT,qKAAqK;iBACxK;aACF;YACD,QAAQ,EAAE,EAAE;SACb;KACF;IACD;QACE,IAA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V,IAAI,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE,WAAW,EAAE,mDAAmD,EAAE;gBAC1F,SAAS,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE,WAAW,EAAE,mEAAmE,EAAE;aAChH;YACD,QAAQ,EAAE,CAAC,MAAM,CAAC;SACnB;KACF;IACD;QACE,IAAI,EAAE,oBAAoB;QAC1B,WAAW,EAAE,iNAAiN;QAC9N,WAAW,EAAE;YACX,IAAI,EAAE,QAAQ;YACd,UAAU,EAAE;gBACV,IAAI,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE,WAAW,EAAE,4BAA4B,EAAE;aACpE;YACD,QAAQ,EAAE,CAAC,MAAM,CAAC;SACnB;KACF;CACR,CAAC"}
@@ -0,0 +1,125 @@
1
+ # Inbox Monitor Invariants
2
+
3
+ This document records the load-bearing security and liveness invariants for the
4
+ Claude Code inbox Monitor. OpenCode uses HTTP entry injection, and Codex uses
5
+ its app-server bridge; neither uses this Monitor.
6
+
7
+ ## Wake-Path Failure Modes
8
+
9
+ The cube's wake path turns a durable log entry into an agent session that
10
+ processes it. For Claude Code, the local hop from the inbox file to the agent
11
+ harness is a `tail -F`-style Monitor. That middle hop is where coordination
12
+ delivery becomes a local-process correctness problem rather than a transport
13
+ problem.
14
+
15
+ The following failure classes are distinct even when the current health probe
16
+ ultimately reports more than one of them as a missing `tail` process:
17
+
18
+ | Class | Description | Current detection or closure |
19
+ |---|---|---|
20
+ | **Monitor absent** | No process tails the inbox file. Entries can reach disk, but no local event source wakes the drone. | `checkInboxMonitorHealthy()` in `src/stream-status.ts:56-89` reports the wake path broken when `pgrep` confirms that no process follows the inbox. The warning is fail-loud only when the probe can make that determination. |
21
+ | **Monitor registered but inert** | A Monitor task is registered in the harness, but its underlying process exits immediately. The task looks armed while no `tail -F` process fans out events. | The realpath-aware entry guard in `src/inbox-monitor.ts:1033-1056` prevents the npm-bin symlink failure. The built-binary symlink test in `__tests__/inbox-monitor.test.ts:767-843` proves that the shipped process stays alive. The process probe also observes the resulting absence of `tail`; it does not make the entry guard or its end-to-end pin redundant because detection runs only when the client is queried, after immediate wake delivery has already failed. |
22
+ | **Monitor holder or tail wedged** | A process exists but is not delivering appended bytes. Process presence alone would incorrectly look healthy. | The holder heartbeat upgrades process presence to a liveness signal in `src/stream-status.ts:56-110`. `src/inbox-monitor.ts:981-1014` detects sustained un-emitted inbox growth and respawns its own `tail` from the last delivered offset. A `tail` error or exit releases the heartbeat and PID state at `:959-975`, so a dead child does not leave a healthy-looking holder behind. |
23
+
24
+ The distinction between **Monitor absent** and **Monitor registered but inert**
25
+ is load-bearing. The entry-guard regression did not fail to register a Monitor;
26
+ it made the registered command exit successfully without starting `main()`.
27
+ Coverage that only checks whether orchestration created a task cannot observe
28
+ that shipped-binary no-op class.
29
+
30
+ ## Bin Entry Guard Must Resolve the npm Shim
31
+
32
+ **Invariant:** the `main()` entry guard at `src/inbox-monitor.ts:1055-1056`
33
+ uses `isEntryInvocation(process.argv[1], import.meta.url)`. The helper at
34
+ `:1045-1051` calls `realpathSync(argv1)` before comparing it with
35
+ `fileURLToPath(importMetaUrl)`. The raw
36
+ `process.argv[1] === fileURLToPath(import.meta.url)` test must not return.
37
+ The realpath call remains inside a `try`/`catch` with a safe-default `false` for
38
+ errors such as a broken symlink, missing file, permission failure, or symlink
39
+ loop.
40
+
41
+ **Why load-bearing:** drones installed with `npm install -g borgmcp` launch the
42
+ compiled `dist/inbox-monitor.js` through the `borg-inbox-monitor` npm bin shim.
43
+ With raw equality, `argv[1]` is the shim's symlink path while
44
+ `fileURLToPath(import.meta.url)` is the module's realpath. They never match,
45
+ `main()` never runs, and the binary exits 0 silently. The Claude Code harness
46
+ then has a Monitor task that appears armed but is inert, so the drone loses its
47
+ immediate wake path without a launch error.
48
+
49
+ **Change shapes that silently weaken it:**
50
+
51
+ - Dropping `realpathSync`, or resolving only one side of the comparison,
52
+ recreates the npm-shim mismatch.
53
+ - Removing the `try`/`catch` turns a safe non-entry result into an entry-point
54
+ crash.
55
+ - Removing the exported helper discards the focused unit pin.
56
+ - Dropping the built-binary symlink-spawn test as redundant leaves only pure
57
+ helper coverage, which cannot observe whether the shipped binary silently
58
+ exits before starting `tail`.
59
+
60
+ **Verification:** `__tests__/inbox-monitor.test.ts:712-765` pins the helper's
61
+ realpath-aware behavior. The end-to-end test at `:767-843` rebuilds the current
62
+ `dist/`, invokes `dist/inbox-monitor.js` through a temporary symlink,
63
+ and asserts that the process and its `tail` child survive the 600 ms early-exit
64
+ window. Both layers are required because the regression class is "shipped
65
+ binary silently no-ops," not merely "the helper returns the wrong Boolean."
66
+
67
+ ## Worktree-Local State and Conservative Legacy Migration
68
+
69
+ **Invariant:** supported Claude Monitor invocations keep PID, heartbeat,
70
+ temporary-claim, and mutation-guard state only beneath the exact canonical
71
+ `<worktree>/.borgmcp/inbox-monitor` root. `ensureMonitorStateDir()` at
72
+ `src/inbox-monitor.ts:336-416` canonicalizes the worktree before creating
73
+ children, rejects a symlinked `.borgmcp` or `inbox-monitor` ancestor, and
74
+ revalidates the resolved root around preparation. The state root is mode
75
+ `0700`; lock, heartbeat, mutation, and ignore files are created mode `0600`.
76
+ The local `*` `.gitignore` keeps all runtime state out of Git without changing
77
+ a tracked project ignore rule. A pre-existing marker is accepted only when it
78
+ is a real regular file with Borg's exact `*\n` bytes, mode `0600`, and, where
79
+ the platform exposes it, the current process UID. A foreign marker, including
80
+ exact contents at a foreign mode, fails loud before the marker or root mode is
81
+ changed; an absent marker is created only with a newly created root.
82
+
83
+ **Modern lock mutation rule:** the current-format PID claim is
84
+ hardlink-create atomic (`src/inbox-monitor.ts:651-675`). A short-lived,
85
+ hardlink-created mutation guard is acquired before any legacy inspection,
86
+ spans modern stale or wedge reaping and the current-lock claim, and spans the
87
+ final legacy revalidation before `tail` starts (`:625-648`, `:831-878`).
88
+ `removeIfContent` is deliberately verify-then-unlink rather than an atomic
89
+ compare-and-swap; modern code calls it only while the guard serializes modern
90
+ contenders. A guard that survives a crashed startup fails closed. After
91
+ confirming its process has stopped, the operator may remove that worktree-local
92
+ guard and re-arm. PID and nonce pairing remains mandatory for heartbeat-based
93
+ wedge recovery (`:268-289`), preventing PID reuse from authorizing a reap.
94
+
95
+ **Cross-version migration rule:** modern code never unlinks, replaces, or
96
+ garbage-collects an extant inbox-adjacent legacy `.monitor.pid` or
97
+ `.monitor.heartbeat`. A proven live legacy PID wins and the modern Monitor
98
+ yields. A stale, malformed, heartbeat-only, or unreadable legacy artifact
99
+ blocks modern startup with an actionable cleanup error; the operator must
100
+ confirm the old Monitor has stopped, remove the legacy artifacts, then re-arm
101
+ (`src/inbox-monitor.ts:572-648`, `:840-872`). This intentionally prefers a
102
+ failed-visible arm over a dual tail or deletion of a successor's live lock. The
103
+ migration boundary assumes no new legacy binary is launched after upgrade;
104
+ already-running legacy holders remain protected.
105
+
106
+ **Why load-bearing:** a workspace-only sandbox must never follow a
107
+ repository-controlled `.borgmcp` symlink into an external writable path, and a
108
+ user-space implementation cannot manufacture a portable atomic
109
+ unlink-if-content operation for a legacy binary that does not participate in
110
+ modern serialization. Treating either gap as harmless could escape the
111
+ promised workspace containment or make a valid old Monitor lose its sole
112
+ liveness lock.
113
+
114
+ **Verification:** `__tests__/inbox-monitor.test.ts:85-303` pins canonical
115
+ worktree placement, symlinked-parent rejection with zero external writes,
116
+ `0700`/`0600` modes, Git-clean state, read-only inbox operation, and foreign
117
+ ignore rejection without mutation. The migration tests at `:425-493` pin live
118
+ legacy precedence, blocked stale artifacts, the modern mutation guard, and a
119
+ deterministic old-successor insertion at the former legacy read-to-claim gap.
120
+ The built-binary tests at `:845-1045` prove state remains worktree-local and a
121
+ stale legacy artifact exits non-zero with an operator cleanup message while
122
+ remaining on disk. `__tests__/gc-orphan-inboxes.test.ts:142-163` pins that
123
+ garbage collection reaps worktree-root state but leaves legacy sidecars for
124
+ explicit cleanup; `src/gc-orphan-inboxes.ts:83-113` also treats every live
125
+ legacy signal as a deletion veto.
@@ -1,42 +1,42 @@
1
1
  # Self-Hosted Server
2
2
 
3
- Install and initialize the server in the human operator's terminal:
3
+ Use the interactive client setup in the human operator's terminal. It offers
4
+ the exact server version compatible with the installed client and initializes
5
+ the server without starting it:
4
6
 
5
7
  ```bash
6
- npm install -g borgmcp-server
7
- borg server setup
8
+ borg setup
8
9
  borg server start
9
10
  ```
10
11
 
11
- The client owns the `borg server` facade. It forwards commands and renders
12
- verified server evidence. It does not infer a checkout, activate an artifact,
13
- create a service, or claim a build identity by itself. The server owns artifact
14
- verification, activation, data and identity preservation, runtime build
15
- identity, rollback, and explicit Linux/macOS service adapters. The server
16
- executable remains the direct foreground authority.
12
+ See the [Get Started guide](https://borgmcp.ai/get-started/) for the complete
13
+ installation sequence.
14
+
15
+ The client owns the `borg server` facade and the client-side `cube init` flow.
16
+ Other facade commands execute the separately installed `borgmcp-server` with
17
+ the terminal attached, so the server renders its own evidence. The client does
18
+ not infer a checkout, activate an artifact, create a service, or claim a build
19
+ identity by itself. The server owns artifact verification, activation, data and
20
+ identity preservation, runtime build identity, rollback, and explicit
21
+ Linux/macOS service adapters. The server executable remains the direct
22
+ foreground authority.
17
23
 
18
24
  `borg server start` and `borg-mcp-server start` are foreground commands. They
19
25
  must never imply that a daemon, LaunchAgent, or systemd service was installed.
20
26
  Ctrl-C stops the foreground process. Managed persistence is a separate explicit
21
27
  handoff.
22
28
 
23
- The available lifecycle facade commands are:
29
+ Use installed help for the command set and exact options for your version:
24
30
 
25
31
  ```text
26
- Usage: borg server <command> [arguments]
27
-
28
- Commands:
29
- setup Prepare local server identity and data; does not start the server.
30
- start Start the verified server in the foreground.
31
- stop Stop the managed local server.
32
- status Report verified runtime evidence.
33
- update Verify and activate a local server artifact.
34
- invite Create a single-use invitation in an interactive terminal.
35
- cube init Initialize this Git repository's cube; does not create a drone.
36
-
37
- Run borg server <command> --help for server command options.
32
+ borg server --help
33
+ borg server <command> --help
38
34
  ```
39
35
 
36
+ The [server operations](https://borgmcp.ai/docs/run-server/) and
37
+ [self-hosting](https://borgmcp.ai/docs/self-hosting/) guides cover lifecycle,
38
+ network, backup, and recovery tasks.
39
+
40
40
  `borg server cube init --help` derives accepted template names from the pinned
41
41
  shared release. Relevant options include:
42
42
 
@@ -92,11 +92,12 @@ borg assimilate
92
92
  ```
93
93
 
94
94
  Setup provisions the first same-machine owner credential directly, so this flow
95
- does not ask for an invitation. For another client or device, run `borg server
96
- invite` in the server operator's interactive terminal. On the intended recipient,
97
- run `borg assimilate --host <server> --enroll` and enter the single-use invitation
98
- at the labeled hidden prompt. Never put an invitation in argv, environment
99
- variables, logs, or diagnostics.
95
+ does not ask for an invitation. For another client or device, follow the
96
+ [trust and provisioning guide](https://github.com/Byte-Ventures/borg-mcp-server/blob/main/docs/trust-and-provisioning.md):
97
+ mint a single-use invitation, enroll the recipient, grant that enrolled client
98
+ explicit access to the intended cube, then rerun assimilation. Enrollment alone
99
+ grants no cube access. Never put an invitation in argv, environment variables,
100
+ logs, or diagnostics.
100
101
 
101
102
  For explicit invitation enrollment, the client generates a 256-bit credential
102
103
  and UUID retry key and persists the exact tuple as `PENDING` in the 0600
@@ -151,7 +152,9 @@ being redirected.
151
152
 
152
153
  ## Agent Launch State
153
154
 
154
- Borg tools are inactive unless the agent session was launched with `borg`.
155
+ Borg tools are normally inactive unless the agent session was launched with
156
+ `borg`. Setting `BORG_SESSION=1` is a supported power-user activation override;
157
+ it does not grant server access or change authorization.
155
158
  For Claude Code and Codex, `BORG_DISABLE_LAUNCH_REMINDER` is a presence-based
156
159
  local opt-out for launch orientation messaging; setting it does not activate
157
160
  Borg tools or change server authorization. OpenCode has no plain-launch reminder;
@@ -216,20 +219,11 @@ noncanonical worktrees heal when Borg next launches or assimilates them.
216
219
 
217
220
  `borg doctor` performs the same bin-owner and version checks without changing
218
221
  state. It inventories managed hook files and verifies the OpenCode orientation
219
- plugin against its borgmcp version marker and generated behavior,
220
- and reports status-specific recovery: reinstall a missing bin, correct PATH for
221
- the wrong package or version, run `borg update --yes` for stale managed hooks,
222
- repair a named invalid configuration before rerunning update, or run
223
- `borg update --yes` to install a missing or outdated OpenCode plugin. The plugin API is
224
- empirically bound to OpenCode 1.18.15 with `@opencode-ai/plugin` 1.17.18; that
225
- SDK uses the path/query/body options shape for history reads and prompt
226
- submission, not the newer flat v2 call shape. At that bound, `TextPart.metadata`
227
- exists, persists through history reads, compaction, and process reload, and is
228
- not rendered in the TUI or supplied to the model. The health gate treats OpenCode
229
- as configured only when `~/.config/opencode/opencode.json` contains a local
230
- `mcp.borg` entry with `type: "local"`. That path and shape were exercised by the
231
- 3.2.0 config-refresh live proof (PR #390) and are part of the OpenCode 1.18.15
232
- compatibility gate.
222
+ plugin against its borgmcp version marker and generated behavior. It reports
223
+ status-specific recovery: reinstall a missing bin, correct PATH for the wrong
224
+ package or version, run `borg update --yes` for stale managed hooks, repair a
225
+ named invalid configuration before rerunning update, or run `borg update --yes`
226
+ to install a missing or outdated OpenCode plugin.
233
227
 
234
228
  `borg server update` remains the server-runtime-only command. It verifies and
235
229
  activates the server artifact but deliberately does not rewrite the global
@@ -260,18 +254,24 @@ The default discovery endpoint is `https://127.0.0.1:7091`. Explicit `--host` va
260
254
 
261
255
  ## Recovery commands
262
256
 
263
- - No saved or rejected enrollment: generate a single-use invitation with
264
- `borg server invite`, then run `borg assimilate --host <server> --enroll` from
265
- the intended recipient's interactive terminal.
257
+ - No saved enrollment: generate a single-use invitation with `borg server
258
+ invite`, then run `borg assimilate --host <server> --enroll` from the intended
259
+ recipient's interactive terminal. After enrollment, the operator must grant
260
+ that client access to the intended cube; then rerun `borg assimilate --host
261
+ <server>`.
266
262
  - Rejected or expired invitation: keep the server running and mint a replacement
267
263
  invitation with `borg server invite`, then rerun `borg assimilate --host
268
- <server> --enroll` with the replacement invitation.
264
+ <server> --enroll` with the replacement invitation. After enrollment, grant
265
+ cube access and rerun assimilation without `--enroll`.
269
266
  - Revoked or superseded local session: run `borg reset-local-connection`, ask the
270
267
  operator for a new invitation from `borg server invite`, then run `borg
271
- assimilate --host <server> --enroll` with the server still running.
272
- - Unloadable local seat: run `borg reset-local-connection --host <server>` to clear
273
- ONLY this worktree's saved local seat, then rerun `borg assimilate --host
274
- <server>` with the server still running.
268
+ assimilate --host <server> --enroll` with the server still running. After
269
+ enrollment, grant cube access and rerun assimilation without `--enroll`.
270
+ - A valid saved connection that cannot be hydrated for the selected host: run
271
+ `borg reset-local-connection --host <server>` to clear only this worktree's
272
+ saved connection, then rerun `borg assimilate --host <server>` with the server
273
+ still running. A malformed private store fails closed and is not reset by this
274
+ command; preserve the store and the exact error for diagnosis.
275
275
  - Unreachable server: start or restart it with `borg server start`, then
276
276
  rerun `borg assimilate --host <server>`.
277
277
  - Trust mismatch after an intentional server re-initialization: verify the
@@ -282,9 +282,3 @@ The default discovery endpoint is `https://127.0.0.1:7091`. Explicit `--host` va
282
282
  - Unusable project name: rerun with `--cube-name <name>`.
283
283
  - Incompatible response: verify compatible client and server versions, then
284
284
  retry the same endpoint.
285
-
286
- ## Release status
287
-
288
- This client candidate pins published `borgmcp-shared@0.10.1`. Its release remains
289
- coupled to a server artifact rebuilt against the same shared version, with both
290
- artifacts required to pass the complete process-level local dogfood gate.
package/docs/RELEASING.md CHANGED
@@ -69,16 +69,17 @@ Before preparing a candidate, independently verify:
69
69
  ### Clean-environment rig lifecycle
70
70
 
71
71
  Every clean-environment verification rig has an explicit identity and an
72
- explicit end-of-life. Keep filesystem workspaces under the seat's disposable
73
- `~/.borg/scratch/<seat>/` root, and give each workspace a name beginning with
74
- `borg-rig-` followed by the seat, purpose, and a unique suffix. Before the
75
- first command that can create files, anchor the rig as its own npm project:
72
+ explicit end-of-life. Run it from a Borg-launched session and keep filesystem
73
+ workspaces under the exact disposable scratch root Borg exports. Give each
74
+ workspace a name beginning with `borg-rig-` followed by its owner, purpose, and
75
+ a unique suffix. Before the first command that can create files, anchor the rig
76
+ as its own npm project:
76
77
 
77
78
  ```sh
78
- BORG_SEAT_LABEL="${BORG_SEAT_LABEL:?set the seat label}"
79
- BORG_SCRATCH_ROOT="${BORG_SCRATCH_ROOT:-$HOME/.borg/scratch/$BORG_SEAT_LABEL}"
79
+ BORG_SCRATCH_ROOT="${BORG_LAUNCH_SCRATCH:?run from a Borg-launched session}"
80
+ RIG_OWNER="$(basename "$BORG_SCRATCH_ROOT")"
80
81
  RIG_NONCE="${RIG_NONCE:-$(date +%Y%m%d%H%M%S)-$$}"
81
- RIG_ID="borg-rig-${BORG_SEAT_LABEL}-release-${RIG_NONCE}"
82
+ RIG_ID="borg-rig-${RIG_OWNER}-release-${RIG_NONCE}"
82
83
  RIG_ROOT="$BORG_SCRATCH_ROOT/$RIG_ID"
83
84
  mkdir -p "$RIG_ROOT"
84
85
  printf '%s\n' '{"private":true}' > "$RIG_ROOT/package.json"
@@ -87,8 +88,8 @@ printf '%s\n' '{"private":true}' > "$RIG_ROOT/package.json"
87
88
  The manifest anchor is required before any `npm install`, `npm update`, or
88
89
  other npm command. Without it, npm can walk up from an empty scratch directory
89
90
  and write the operator's `package.json` instead of creating project-local
90
- state. The committed `release:exercise` follows this rule for its temporary
91
- consumer; other QA scripts and manual rigs must do the same.
91
+ state. In a source checkout, the committed `release:exercise` follows this rule
92
+ for its temporary consumer; other QA scripts and manual rigs must do the same.
92
93
 
93
94
  The system temporary root is shared with the whole machine, so an unbounded
94
95
  listing there is not an inspectable cleanup check. Bound that leg by the
@@ -124,22 +125,16 @@ touch "$TEMP_SCAN_START"
124
125
  ```
125
126
 
126
127
  Container-backed rigs use the same `RIG_ID` as the container name and carry
127
- both labels below. `--rm` is preferred; a runtime without automatic removal
128
- must remove the exact `RIG_ID` in its cleanup path and retain the labels for a
129
- bounded sweep:
128
+ both labels below. Register exact-target cleanup before launching the rig:
130
129
 
131
130
  ```sh
132
- RIG_IMAGE="${RIG_IMAGE:?set the rig image}"
133
- docker run --rm \
134
- --name "$RIG_ID" \
135
- --label borg-rig=1 \
136
- --label "borg-rig-owner=$BORG_SEAT_LABEL" \
137
- "$RIG_IMAGE"
138
- ```
139
-
140
- Register the exact-target cleanup before launching the rig:
131
+ list_owned_rig_containers() {
132
+ docker container ls --all \
133
+ --filter label=borg-rig=1 \
134
+ --filter "label=borg-rig-owner=${RIG_OWNER:?}" \
135
+ --format '{{.ID}}\t{{.Names}}\t{{.Status}}'
136
+ }
141
137
 
142
- ```sh
143
138
  cleanup_done=0
144
139
  cleanup() {
145
140
  [ "$cleanup_done" -eq 0 ] || return
@@ -147,6 +142,9 @@ cleanup() {
147
142
  trap - EXIT HUP INT TERM
148
143
  docker container rm --force "$RIG_ID" >/dev/null 2>&1 || true
149
144
  rm -rf -- "$RIG_ROOT"
145
+ list_owned_rig_containers
146
+ find "$BORG_SCRATCH_ROOT" -mindepth 1 -print
147
+ find "$BORG_SCRATCH_ROOT" -name 'borg-rig-*' -print
150
148
  if [ -e "$TEMP_SCAN_START" ]; then
151
149
  touch "$TEMP_SCAN_END"
152
150
  list_recent_owned_temp_rigs
@@ -159,34 +157,49 @@ trap 'exit 130' INT
159
157
  trap 'exit 143' TERM
160
158
  ```
161
159
 
162
- List before starting and after cleanup. The filters distinguish this seat's
163
- rigs from unrelated containers on a shared host:
160
+ List containers and scratch paths before starting. The filters distinguish this
161
+ session's rigs from unrelated containers on a shared host:
164
162
 
165
163
  ```sh
166
- docker container ls --all \
167
- --filter label=borg-rig=1 \
168
- --filter "label=borg-rig-owner=${BORG_SEAT_LABEL:?}" \
169
- --format '{{.ID}}\t{{.Names}}\t{{.Status}}'
164
+ list_owned_rig_containers
170
165
  find "$BORG_SCRATCH_ROOT" -mindepth 1 -print
171
166
  find "$BORG_SCRATCH_ROOT" -name 'borg-rig-*' -print
172
167
  ```
173
168
 
169
+ Only after the cleanup traps and pre-launch listings are in place, launch a
170
+ container-backed rig. `--rm` is preferred; a runtime without automatic removal
171
+ must remove the exact `RIG_ID` in its cleanup path and retain the labels for a
172
+ bounded sweep:
173
+
174
+ ```sh
175
+ RIG_IMAGE="${RIG_IMAGE:?set the rig image}"
176
+ docker run --rm \
177
+ --name "$RIG_ID" \
178
+ --label borg-rig=1 \
179
+ --label "borg-rig-owner=$RIG_OWNER" \
180
+ "$RIG_IMAGE"
181
+ ```
182
+
174
183
  The unfiltered filesystem listings expose legacy names as well as conforming
175
- rigs. The bounded temporary-directory function covers tools that use `mkdtemp`
176
- instead of the seat scratch root. Run the container and scratch listings before
177
- launch and again from the cleanup path; the temporary-directory function runs
178
- after cleanup, between the start and end markers. Inspect its results and do
179
- not remove unrelated temporary files.
184
+ rigs. The bounded temporary-directory function reports same-user directories
185
+ created during the run window, including unrelated work; it does not establish
186
+ which process owns them. The cleanup path runs the container and scratch
187
+ listings after removing this rig, then runs the bounded temporary-directory
188
+ listing between the start and end markers. Inspect and report its results. If a
189
+ rig creates an exact system-temporary path, record that path when it is created
190
+ and remove that exact path during cleanup; never remove a path solely because
191
+ the bounded listing found it.
180
192
 
181
193
  Register cleanup before launching any process, run it on success and failure,
182
- and do not deliver a verdict until the container listing, both scratch listings,
183
- and the bounded temporary-directory listing show no rig owned by the seat from
184
- this run. For a non-`--rm` container runtime,
194
+ and do not deliver a verdict until the container listing and both scratch
195
+ listings show no rig owned by this run, every exact system-temporary path
196
+ recorded by the rig has been removed, and the bounded temporary-directory
197
+ listing has been inspected and reported. For a non-`--rm` container runtime,
185
198
  remove only the named rig or the same owner label; never prune unrelated
186
199
  containers. A completed verification
187
200
  therefore implies zero running or stopped rig containers and no rig workspace
188
- created by this run left in either the seat scratch root or the system temporary
189
- directory.
201
+ created by this run left in either the session scratch root or any exact
202
+ system-temporary path the rig recorded.
190
203
 
191
204
  ### Pre-tag composed exercise
192
205
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "borgmcp",
3
- "version": "3.6.3",
3
+ "version": "3.8.0",
4
4
  "description": "Coordinate AI coding agents in shared cubes. Works with Claude Code, Codex, and OpenCode.",
5
5
  "type": "module",
6
6
  "main": "./dist/index.js",