@bridge_gpt/mcp-server 0.2.68 → 0.2.70

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 (166) hide show
  1. package/README.md +226 -320
  2. package/build/agent-launchers/claude-executor-adapter.js +17 -4
  3. package/build/agents.generated.js +4 -4
  4. package/build/artifact-diff.js +110 -0
  5. package/build/bin-entrypoint.js +36 -0
  6. package/build/bridge-permissions.js +650 -98
  7. package/build/check-update-cli.js +74 -0
  8. package/build/claude-review-workflow-drift.js +3 -3
  9. package/build/claude-settings.js +84 -2
  10. package/build/cli-help.js +7 -1
  11. package/build/codex-bridge-profile.js +1 -1
  12. package/build/codex-home.js +9 -1
  13. package/build/codex-launcher-pin.js +598 -0
  14. package/build/commands.generated.js +8 -8
  15. package/build/conductor/bridge-api-client.js +598 -19
  16. package/build/conductor/bring-up-facts.js +9 -9
  17. package/build/conductor/doctor.js +466 -18
  18. package/build/conductor/epic-child-continuation.js +54 -3
  19. package/build/conductor/epic-implementer-cli.js +132 -34
  20. package/build/conductor/epic-runtime.js +2 -2
  21. package/build/conductor/epic-state.js +1 -1
  22. package/build/conductor/hook-runtime-qualification.js +1 -1
  23. package/build/conductor/install-doctor.js +4 -2
  24. package/build/conductor/launch-need-probes.js +337 -0
  25. package/build/conductor/local-merge.js +241 -56
  26. package/build/conductor/merge-credential.js +172 -0
  27. package/build/conductor/merge-execution-eligibility.js +1 -1
  28. package/build/conductor/merged-child-check.js +95 -0
  29. package/build/conductor/plan-trim.js +30 -0
  30. package/build/conductor/pr-ci-producer.js +1 -1
  31. package/build/conductor/readiness-cli.js +11 -6
  32. package/build/conductor/readiness-prerequisites.js +41 -0
  33. package/build/conductor/readiness-sections.js +345 -55
  34. package/build/conductor/readiness.js +99 -87
  35. package/build/conductor/recovery-cli.js +606 -21
  36. package/build/conductor/recovery-operations.js +306 -7
  37. package/build/conductor/repair-contract.js +47 -2
  38. package/build/conductor/repository-workflow-remedy.js +8 -6
  39. package/build/conductor/stored-merge-credential.js +76 -0
  40. package/build/conductor/stored-merge-token-probe.js +28 -0
  41. package/build/conductor/temporary-plan.js +50 -0
  42. package/build/conductor/wait-run-cli.js +759 -0
  43. package/build/conductor/worker-database-doctor-inspector.js +49 -0
  44. package/build/conductor-bin.js +2 -2
  45. package/build/conductor-claude-hook-bin.js +2 -2
  46. package/build/conductor-claude-hook-removed-stub-bin.js +2 -5
  47. package/build/conductor-removed-stub-bin.js +2 -5
  48. package/build/connect-github-api.js +33 -14
  49. package/build/credential-store.js +356 -13
  50. package/build/docs.generated.js +27 -14
  51. package/build/doctor.js +203 -38
  52. package/build/drive-epic-help.js +212 -0
  53. package/build/drive-epic.js +1840 -373
  54. package/build/epic-ci-workflow-drift.js +77 -0
  55. package/build/epic-ci-workflow-install.js +183 -0
  56. package/build/epic-ci-workflow.js +157 -0
  57. package/build/epic-contract-context.js +326 -0
  58. package/build/epic-implementer-bin.js +131 -120
  59. package/build/epic-implementer-claude-hook-bin.js +2 -2
  60. package/build/escalation-reachability.js +134 -0
  61. package/build/executor/cleanup-report.js +99 -0
  62. package/build/executor/cli.js +12 -1
  63. package/build/executor/completion-contract.js +68 -11
  64. package/build/executor/completion-supervision.js +99 -0
  65. package/build/executor/delivery-outcome.js +179 -0
  66. package/build/executor/deps.js +3 -0
  67. package/build/executor/env.js +71 -0
  68. package/build/executor/failure-reason-codes.js +126 -0
  69. package/build/executor/heartbeat.js +38 -0
  70. package/build/executor/http-client.js +115 -4
  71. package/build/executor/integration-job.js +298 -5
  72. package/build/executor/job-errors.js +36 -6
  73. package/build/executor/job-runner.js +720 -36
  74. package/build/executor/likely-tests.js +36 -2
  75. package/build/executor/merge-job.js +145 -2
  76. package/build/executor/observation.js +73 -4
  77. package/build/executor/permissions.js +193 -97
  78. package/build/executor/preflight.js +14 -3
  79. package/build/executor/process-containment.js +28 -2
  80. package/build/executor/prompt-spec.js +50 -5
  81. package/build/executor/rebase-finalization.js +38 -3
  82. package/build/executor/reconcile-overlap-job.js +35 -7
  83. package/build/executor/required-work-ledger.js +236 -81
  84. package/build/executor/resume-pre-spawn.js +38 -1
  85. package/build/executor/runner.js +91 -3
  86. package/build/executor/test-clock.js +8 -0
  87. package/build/executor/types.js +37 -2
  88. package/build/executor/worker-cli-launcher.js +259 -0
  89. package/build/executor/worker-command.js +41 -4
  90. package/build/executor/worker-database-target.js +91 -0
  91. package/build/executor/worker-database.js +908 -0
  92. package/build/executor/worker-finalization.js +106 -0
  93. package/build/executor/worker-guard-hook.js +203 -0
  94. package/build/executor/worker-resources.js +47 -0
  95. package/build/executor/worker-verification-guidance.js +15 -2
  96. package/build/executor/worktree.js +303 -15
  97. package/build/executor-launch.js +11 -1
  98. package/build/generated-assets-doctor.js +9 -1
  99. package/build/generated-assets-health.js +13 -4
  100. package/build/generated-assets-legacy.js +39 -0
  101. package/build/generated-assets-paths.js +12 -1
  102. package/build/generated-assets-repair.js +4 -1
  103. package/build/generated-assets-test-support.js +12 -0
  104. package/build/github-remote.js +33 -0
  105. package/build/github-sign-in.js +62 -0
  106. package/build/index.js +1214 -465
  107. package/build/init.js +39 -1
  108. package/build/install-bridge-conductor-gate.js +78 -0
  109. package/build/install-bridge-conductor-setup.js +413 -0
  110. package/build/install-bridge-conductor.js +1226 -267
  111. package/build/install-bridge.js +629 -350
  112. package/build/launcher-config-inspection.js +184 -19
  113. package/build/mcp-host-targets.js +4 -0
  114. package/build/mcp-identity.js +7 -0
  115. package/build/mcp-install-state.js +8 -2
  116. package/build/merge-pull-request.js +6 -0
  117. package/build/merge-workflow-install.js +763 -345
  118. package/build/phase-result-artifacts.js +75 -20
  119. package/build/pipeline-orchestrator.js +247 -4
  120. package/build/pipelines.generated.js +35 -35
  121. package/build/plan-discovery.js +15 -2
  122. package/build/plan-execution-ledger.js +306 -17
  123. package/build/plan-phase-routing.js +48 -13
  124. package/build/plane/cli.js +105 -51
  125. package/build/plane/defaults.js +3 -0
  126. package/build/plane/plane-freshness.js +294 -0
  127. package/build/plane/schema-compatibility.js +137 -0
  128. package/build/plane/shutdown-deps.js +38 -0
  129. package/build/plane/shutdown.js +83 -8
  130. package/build/plane/terminal-run-cleanup.js +303 -0
  131. package/build/printed-remedy-commands.js +26 -4
  132. package/build/readiness-check.js +6 -2
  133. package/build/readiness-prerequisites.generated.js +532 -0
  134. package/build/readme.generated.js +1 -1
  135. package/build/session-upgrade-notice.js +86 -0
  136. package/build/setup-epic.js +400 -30
  137. package/build/shared-resources.generated.js +5 -0
  138. package/build/start-tickets.js +43 -15
  139. package/build/test-command-detection.js +247 -0
  140. package/build/test-command-validation.js +73 -0
  141. package/build/testing-config-client.js +150 -0
  142. package/build/ticket-delivery-artifacts.js +258 -0
  143. package/build/ticket-delivery-enrollment.js +306 -0
  144. package/build/ticket-delivery.js +205 -0
  145. package/build/ticket-review-summary.js +14 -0
  146. package/build/tool-call-advisory.js +162 -0
  147. package/build/tool-surface-gating.js +28 -89
  148. package/build/update-check.js +97 -16
  149. package/build/update-status.js +61 -71
  150. package/build/upgrade-advice.js +15 -11
  151. package/build/upgrade-cli.js +360 -20
  152. package/build/v2-readiness-requirements.js +552 -0
  153. package/build/version.generated.js +3 -3
  154. package/build/worker-guard-hook-bin.js +2 -2
  155. package/build/worktree-core.js +22 -7
  156. package/docs/BRIDGE-DIRECTORY-README.md +48 -0
  157. package/docs/EPIC-IMPLEMENTER-INSTALL.md +12 -867
  158. package/docs/EPIC-IMPLEMENTER.md +104 -63
  159. package/docs/epic-implementer/getting-started.md +131 -0
  160. package/docs/epic-implementer/self-hosting.md +133 -0
  161. package/package.json +3 -3
  162. package/pipelines/idea-to-ticket.json +1 -1
  163. package/pipelines/implement-ticket.json +8 -8
  164. package/pipelines/review-ticket.json +2 -2
  165. package/design-assets/favicon/favicon-32x32.png +0 -0
  166. package/design-assets/just-logo-rough-draft.png +0 -0
@@ -4,18 +4,16 @@ The **Epic Implementer** drives a multi-ticket epic from an approved plan to
4
4
  `done`. It dispatches each child ticket to an agent, watches CI and review, merges
5
5
  each child PR, and re-indexes the repository after each merge.
6
6
 
7
- > **Naming.** The Epic Implementer used to be called the "Conductor". It was
8
- > renamed in BAPI-1077 to BAPI-1083, BAPI-1190, BAPI-1232, and BAPI-1233. A few
9
- > real identifiers still carry the old name and are spelled as-is below: the
10
- > `--conductor` flag on `start-tickets`, the `install conductor` subcommand, the
11
- > `mcp_server/src/conductor/` source directory, and two retired `conductor` bins.
7
+ > **Names.** A few real identifiers still carry an older product name and are
8
+ > spelled as-is below: the `start-tickets --conductor` flag, the
9
+ > `install conductor` subcommand, and `.conductor/` paths.
12
10
 
13
11
  It has two parts. Keep them apart when you read this guide:
14
12
 
15
13
  | Part | What it is | Opt-in? |
16
14
  | --- | --- | --- |
17
15
  | **The v2 engine** | A server-side **reconciler** plus a local **executor**. This is what drives an epic. | No. It runs for every epic run. |
18
- | **The observability layer** | A local event ledger, Claude Code lifecycle hooks, optional git hooks, and a supervisor tab for `start-tickets --conductor` runs. | Yes, per run, with `--conductor`. |
16
+ | **The observability layer** | A local event ledger, Claude Code lifecycle hooks, optional git hooks, and a supervisor tab for `start-tickets --conductor` runs. | Yes, per run, with `start-tickets --conductor`. |
19
17
 
20
18
  For the everyday `start-tickets` flags, see
21
19
  [README → CLI Subcommands](../README.md#cli-subcommands).
@@ -48,7 +46,7 @@ server's readiness report and routes to exactly one path. You never choose
48
46
  between engines.
49
47
 
50
48
  ```
51
- npx -y @bridge_gpt/mcp-server drive-epic BAPI-405 \
49
+ npx -y @bridge_gpt/mcp-server drive-epic PROJ-123 \
52
50
  --plan-file docs/tmp/epic-plans/<slug>/epic-plan.dag.json
53
51
  ```
54
52
 
@@ -58,7 +56,7 @@ Run it from a Git checkout of the target repository. In one command it:
58
56
  A check that fails here creates nothing.
59
57
  2. Validates the plan with the server's real validator, then creates and approves
60
58
  the run (it delegates this to `setup-epic`).
61
- 3. Starts a **run-scoped executor** for the run in the background (BAPI-1279). It
59
+ 3. Starts a **run-scoped executor** for the run in the background. It
62
60
  claims only that run's jobs, logs to `.bridge/executors/<run>.log`, and exits by
63
61
  itself when the run is `done` or `abandoned`. Re-running `drive-epic` for the
64
62
  same live run never starts a second one.
@@ -90,7 +88,6 @@ attach, and `1` for refuse or stop.
90
88
  | `--policy-file <path>` | The **complete** run policy, applied when the run is created. |
91
89
  | `--review-policy <src>` | The review policy for this run only: `repository_policy`, `verdict_protocol`, `native_review_decision`, or `none`. Omit it and the server stamps `repository_policy` at first approval for a new feature-branch run. `verdict_protocol` (AI review) is an explicit opt-in. An already-approved run with no stored policy is unchanged and still resolves to `verdict_protocol`. |
92
90
  | `--replace-policy` | Allow replacing a live run's stored policy with `--policy-file`. |
93
- | `--launch-profile <name>` | Use a host-local launch profile approved by `install conductor --launch-profile <name>`. `BAPI_EPIC_LAUNCH_PROFILE` selects one too; the flag wins. |
94
91
  | `--base-url <url>` | Explicit Bridge API target. It must agree with a profile. |
95
92
  | `--dry-run`, `--json` | Read-only preview (see above). |
96
93
 
@@ -131,7 +128,7 @@ branch.
131
128
  |---|---|
132
129
  | The epic branch on a plan with 2 or more nodes | *nothing* — it is the default |
133
130
  | Your own branch name, or a branch for a single-node plan | `--feature-branch <name>` |
134
- | Direct-to-base (the pre-BAPI-1009 behavior) | `--into-base` |
131
+ | Direct-to-base (children target the base branch) | `--into-base` |
135
132
 
136
133
  A single-node plan keeps the base branch by default. `--feature-branch` and
137
134
  `--into-base` together are a parse error.
@@ -173,7 +170,7 @@ host or a manual recovery:
173
170
  npx -y @bridge_gpt/mcp-server executor --repo <name> --epic-run-id <id>
174
171
  ```
175
172
 
176
- - **A claim scope is required** (BAPI-1026). Pass exactly one of
173
+ - **A claim scope is required.** Pass exactly one of
177
174
  `--epic-run-id <id>` (repeatable) or `--repo-wide`. With neither, the executor
178
175
  refuses to start.
179
176
  - **A base URL is required.** Pass `--base-url` or set `BAPI_BASE_URL`. The
@@ -185,22 +182,7 @@ npx -y @bridge_gpt/mcp-server executor --repo <name> --epic-run-id <id>
185
182
  systemd (Linux) user unit so an executor survives a reboot. For the guided,
186
183
  consented setup, use `install conductor` instead.
187
184
 
188
- > **Running against a local Bridge API server? Do not use `npx`.** The published
189
- > package often lags the server's source. A newer server can send a `prompt_spec`
190
- > the older executor rejects (`ContractError.Prompt ... unsupported placeholder`).
191
- > Build and run the local tree so both come from the same commit:
192
- >
193
- > ```
194
- > cd mcp_server && npm run build
195
- > node mcp_server/build/index.js executor --repo <name> --epic-run-id <id>
196
- > ```
197
-
198
- **The plane.** `plane up|status|down` brings up a whole local stack in one
199
- command: the Bridge API server, the dead-man observer, the reconciler worker, and
200
- scoped executor lanes. It is for operators who run the Bridge API server
201
- themselves, and it runs executors from that checkout's `mcp_server/build/`.
202
- `drive-epic` starts or attaches to a plane on its own when `BAPI_BASE_URL` names
203
- the local plane endpoint.
185
+ Owners who run their own Bridge server have extra steps. Run `npx -y @bridge_gpt/mcp-server drive-epic --help-advanced` to read them.
204
186
 
205
187
  ## The CI gate
206
188
 
@@ -218,7 +200,7 @@ neither `required_checks` nor `no_ci_gate`:
218
200
  passes without CI.
219
201
  3. Otherwise nothing is stamped.
220
202
 
221
- **With a confirmed gate profile (BAPI-1390)** the stamp follows the profile
203
+ **With a confirmed gate profile** the stamp follows the profile
222
204
  instead, and always records `gate_profile_revision` and a `gate_profile_snapshot`
223
205
  that later profile edits never change:
224
206
 
@@ -242,7 +224,7 @@ run being admitted never count.
242
224
  | Admission reason | Meaning | Remedy |
243
225
  |---|---|---|
244
226
  | `provider_check_unseen` | The named check never reported in that window | Make the check report on the default branch once, or edit the gate profile |
245
- | `provider_evidence_unavailable` | The walk could not finish (rate limit, permission, truncation, moving head) | Retry readiness; escalate to Bridge operations if it persists |
227
+ | `provider_evidence_unavailable` | The walk could not finish (rate limit, permission, truncation, moving head) | Retry readiness; email info@bridgegpt.ai if it persists |
246
228
  | `local_command_unqualified` | No current passing executor qualification for the profile's revision and command digests | Qualify the local commands, then retry |
247
229
  | `migration_guard_unset` | Root `alembic.ini` present and no confirmed member marked as the migration guard | Mark a confirmed check or command as `migration_guard` |
248
230
 
@@ -303,8 +285,8 @@ Paths are relative to the repository root.
303
285
  {
304
286
  "plan_version": 1,
305
287
  "nodes": [
306
- { "ticket_key": "BAPI-405", "status": "planned", "depends_on": [],
307
- "touched_files": ["api/routes/jira_api.py"] }
288
+ { "ticket_key": "PROJ-123", "status": "planned", "depends_on": [],
289
+ "touched_files": ["src/example/service.py"] }
308
290
  ],
309
291
  "edges": []
310
292
  }
@@ -328,6 +310,8 @@ or not the node declared `touched_files`.
328
310
  - `notifications --repo <repo> --run <epic-key|run-id> [--follow]` prints the
329
311
  run's notification feed.
330
312
  - `epic-implementer epic-status --epic-key <KEY>` prints a read-only health summary.
313
+ - `epic-implementer wait-run --epic-run-id <id> [--since <token>]` waits, read-only,
314
+ until the run's observable state changes (see [Waiting between passes](#waiting-between-passes-wait-run)).
331
315
 
332
316
  Both MCP tools need the `epic_implementer` profile group (see
333
317
  [MCP profile](#mcp-profile)).
@@ -345,6 +329,7 @@ Both MCP tools need the `epic_implementer` profile group (see
345
329
  | `adopt-current-head-and-unpark --ticket-key <key>` | Recover a ticket parked by a PR-head change: adopt the current head and unpark. |
346
330
  | `continue-child --ticket-key <key> [--reason <text>]` | Continue a parked child's current attempt without a reset. |
347
331
  | `continuation-receipt --ticket-key <key> [--request-id <id>]` | Read-only: whether a continuation request committed. |
332
+ | `wait-run [--ticket-key <key>] [--since <token>] [--timeout <seconds>]` | Read-only: wait until the run's observable state changes. Not a verb; changes nothing. |
348
333
  | `resume-ci --ticket-key <key>` | Resume a child parked on a CI stop once CI is green. |
349
334
  | `dispatch-remediation --ticket-key <key> --context-file <path>` | Queue a repair job carrying your notes (at most 16384 bytes). |
350
335
  | `merge-child --pr <number>` | Merge the run's child PR through the shared merge service. |
@@ -356,8 +341,31 @@ Most verbs accept `--json`. A replay that changes nothing prints
356
341
  `committed: false` and exits `0`. A refusal carries the server's closed code, such
357
342
  as `TICKET_NOT_IN_RUN`.
358
343
 
344
+ ### Waiting between passes: `wait-run`
345
+
346
+ `epic-implementer wait-run --epic-run-id <id> [--ticket-key <key>] [--since <token>] [--timeout <seconds>] [--json]`
347
+ is a CLI-only, read-only wait. It reads only `GET /jira/epic-runs/runs/{id}/state`,
348
+ using the same shared credential resolver as the verbs, and writes nothing. The
349
+ window defaults to 110 seconds; a larger value is clamped to 240.
350
+
351
+ | Outcome | Meaning | Exit |
352
+ | --- | --- | --- |
353
+ | `changed` | The run's stable state moved. Within one window it lists up to 20 `{ticket_key, field, from, to}` changes (`truncated: true` when more were dropped). | `0` |
354
+ | `changed` + `baseline: "since"` | The first read already differed from `--since`. It carries no field history: the token says *that* something changed, not what. | `0` |
355
+ | `terminal` | The run is `done` or `abandoned`. This outranks a token mismatch. | `0` |
356
+ | `pending` | `WAIT_WINDOW_ELAPSED` (nothing moved) or `UPSTREAM_TRANSIENT` (three reads in a row failed). Run it again. | `0` |
357
+ | failure | Bad arguments, a credential gap, a `401`/`403`/`404`/other `4xx`, a malformed response, or a `--ticket-key` that names no ticket in the run. One line on stderr, nothing on stdout. | `1` |
358
+
359
+ Every successful result carries a `v1:` `token`. Pass it back as `--since`, with
360
+ the same run and the same `--ticket-key`. A well-formed token from another run or
361
+ selector simply reports `changed`. Before any read succeeds, `token` is the
362
+ supplied `--since` (or `null`) and `run_status` is `null`. The token ignores
363
+ reconciler clocks, heartbeats, and row versions, so a tick alone never reports a
364
+ change. wait-run reports the latest observable state, not event history: always
365
+ run a fresh full pass before choosing an action.
366
+
359
367
  **Check prerequisites.** `epic-implementer readiness` is a read-only advisory
360
- report of every prerequisite (install, doctor, plane preflight, and server), each
368
+ report of every prerequisite (install, doctor, and server), each
361
369
  with one named fix. It never runs a fix and always exits `0`.
362
370
  `epic-implementer doctor` reports local health read-only.
363
371
 
@@ -384,7 +392,7 @@ register only when `BRIDGE_MCP_PROFILE` includes the `epic_implementer` group (o
384
392
  BRIDGE_MCP_PROFILE=core,epic_implementer
385
393
  ```
386
394
 
387
- The old `conductor` profile token is retired and ignored. `epic-implementer
395
+ The old profile token is retired and ignored. `epic-implementer
388
396
  doctor` flags it.
389
397
 
390
398
  ## Binaries
@@ -392,18 +400,18 @@ doctor` flags it.
392
400
  | Bin | Purpose |
393
401
  | --- | --- |
394
402
  | `epic-implementer` | The CLI: the recovery verbs above, `readiness`, `doctor`, `epic-status`, `approve-plan`, `install-git-hooks`, and the observability-layer ledger commands (`emit-event`, `supervise`, `send-message`, `check-messages`, `purge`, `git-hook`, `file-scope-guard`). |
395
- | `epic-implementer-claude-hook` | The Claude Code lifecycle hook for `--conductor` runs. |
396
- | `conductor`, `conductor-claude-hook` | Retired names (renamed by BAPI-1080). They print a fixed migration message and exit `1`. |
403
+ | `epic-implementer-claude-hook` | The Claude Code lifecycle hook for `start-tickets --conductor` runs. |
404
+ | `conductor`, `conductor-claude-hook` | Retired names. They print a fixed migration message and exit `1`. |
397
405
 
398
406
  The same CLI is available as the `epic-implementer` subcommand:
399
407
  `npx -y @bridge_gpt/mcp-server epic-implementer <command>`.
400
408
 
401
- ## Environment-variable names and the legacy-name refusal (BAPI-1190)
409
+ ## Environment-variable names and the legacy-name refusal
402
410
 
403
411
  Every Epic Implementer environment variable uses the `BAPI_EPIC_IMPLEMENTER_`
404
412
  prefix. The worker Node path is `EPIC_IMPLEMENTER_NODE_PATH`. These replaced the
405
- old names by a plain token swap: `CONDUCTOR` became `EPIC_IMPLEMENTER` and the
406
- rest stayed the same. For example, the run-id variable is now
413
+ old `BAPI_CONDUCTOR_*` and `CONDUCTOR_*` names with the matching
414
+ `BAPI_EPIC_IMPLEMENTER_*` and `EPIC_IMPLEMENTER_*` names; the rest stayed the same. For example, the run-id variable is now
407
415
  `BAPI_EPIC_IMPLEMENTER_RUN_ID`. There are no aliases and no dual reads.
408
416
 
409
417
  The three dead-man variables that the Python worker reads were renamed the same
@@ -418,12 +426,10 @@ way: `EPIC_IMPLEMENTER_DEAD_MAN_ONLY`, `EPIC_IMPLEMENTER_DEADMAN_CHANNEL_TYPE`,
418
426
  |---|---|
419
427
  | MCP server (bare startup) and every `npx @bridge_gpt/mcp-server <subcommand>` | stderr diagnostic, exit `1`, before any spawn, network call, ledger open, or file write |
420
428
  | `epic-implementer` bin | stderr diagnostic, exit `1`, before argv reaches the CLI |
421
- | `plane up` preflight | refused as the first check, before anything starts |
422
429
  | `epic-implementer-claude-hook` bin | same stderr diagnostic, **exit `0`**, no ledger event |
423
- | Bridge API `worker.py` (dead-man names only) | refuses at boot |
424
430
 
425
431
  The hook exits `0` because a hook must never block the Claude tool loop. The two
426
- retired `conductor` bins are not guarded; they already fail with a fixed message.
432
+ retired bins are not guarded; they already fail with a fixed message.
427
433
 
428
434
  The diagnostic lists **every** offending key, sorted, in one message, with its
429
435
  successor, a "retired — remove it" note, or generic advice for an unknown name. It
@@ -440,10 +446,10 @@ versions and the offending **key names only**.
440
446
  The executor's worker-environment filter also strips both prefixes and both
441
447
  node-path spellings, so an old name never reaches a worker it spawns.
442
448
 
443
- ## Observability layer (`--conductor`, opt-in, BAPI-394)
449
+ ## Observability layer (`start-tickets --conductor`, opt-in)
444
450
 
445
451
  This layer is **off by default**. It is separate from the v2 engine and never
446
- decides a transition. Without `--conductor`, `start-tickets` produces no
452
+ decides a transition. Without `start-tickets --conductor`, `start-tickets` produces no
447
453
  `BAPI_EPIC_IMPLEMENTER_*` env, supervisor tab, or message-relay prompt.
448
454
 
449
455
  With `start-tickets --conductor`, a run mints one `run_id`, writes a `run.started`
@@ -467,7 +473,7 @@ with `BAPI_EPIC_IMPLEMENTER_ENABLE_PRE_TOOL_USE=1`.
467
473
  Inspect the stream with `epic-implementer doctor`. See also
468
474
  [README → Environment Variables](../README.md#environment-variables).
469
475
 
470
- ## `epic-implementer install-git-hooks` (BAPI-395)
476
+ ## `epic-implementer install-git-hooks`
471
477
 
472
478
  Installs local git hooks that emit git events into the local ledger:
473
479
 
@@ -488,7 +494,7 @@ committed ref updates).
488
494
  Missing hooks do **not** block anything. `epic-implementer doctor` reports hook
489
495
  state read-only, and the reconciler drives CI polling and gates either way.
490
496
 
491
- ### Durable hook installation (BAPI-1290)
497
+ ### Durable hook installation
492
498
 
493
499
  A managed hook embeds one absolute entry path and runs it on every commit for as
494
500
  long as the hook exists. So the installer embeds only a **qualified persistent
@@ -519,7 +525,7 @@ read-only:
519
525
  |---|---|
520
526
  | The entry is not inside the prunable `_npx` cache | `ephemeral-cache` |
521
527
  | The canonical entry is a regular `build/epic-implementer-bin.js` | `missing` |
522
- | It is not the retired `conductor-bin.js` name | `legacy-name` |
528
+ | It is not a retired entry name | `legacy-name` |
523
529
  | It sits at `…/node_modules/@bridge_gpt/mcp-server/build/`, and the adjacent `package.json` has that `name`, a compatible `version` (`>=0.2.0 <1.0.0`), and `bin.epic-implementer` → `./build/epic-implementer-bin.js` | `unqualified-runtime` |
524
530
  | The platform is macOS or Linux | `unqualified-runtime` |
525
531
  | `node` from PATH launches the entry's private probe within 15 seconds | `node-unavailable` / `unknown` |
@@ -553,8 +559,8 @@ atomically over the target. A hook edited in the meantime is left alone
553
559
  (`native-unavailable`) is **unavailable**. The raw embedded path appears only in
554
560
  `--json` output (`embedded_bin_path`).
555
561
 
556
- **Repairing old cache-backed hooks.** Hooks installed from `npx` before BAPI-1290
557
- point into the npx cache. Install persistently (`npm i -g @bridge_gpt/mcp-server`),
562
+ **Repairing old cache-backed hooks.** Hooks installed from `npx` before durable
563
+ hook installation point into the npx cache. Install persistently (`npm i -g @bridge_gpt/mcp-server`),
558
564
  then re-run `epic-implementer install-git-hooks` (or `install conductor` and
559
565
  accept the local-observability consent). The managed block is replaced in place.
560
566
 
@@ -568,9 +574,8 @@ never depends on hooks.
568
574
 
569
575
  ## Supervisor config
570
576
 
571
- > **These are not config fields.** They used to be `conductor_done_gate` and
572
- > `conductor_auto_merge_enabled` on the generic config-field route. BAPI-438 moved
573
- > them to dedicated supervisor endpoints. Setting them through
577
+ > **These are not config fields.** They used to be set through the generic
578
+ > config-field route. They now have dedicated supervisor endpoints. Setting them through
574
579
  > `PUT /jira/config-field/...` returns **HTTP 400 "Invalid config field"**, which
575
580
  > is correct.
576
581
 
@@ -585,11 +590,11 @@ Swap `…/defaults/` for `…/runs/{epic_key}/…` to scope a setting to one epi
585
590
  matching `GET` returns the effective value with a `source` of `epic`,
586
591
  `project_default`, or `none` (nothing configured; fails closed).
587
592
 
588
- Since BAPI-1288 every project-default write is protected. Removing a configured
593
+ Every project-default write is protected. Removing a configured
589
594
  requirement needs a preview (`POST …/defaults/preview/`) and the exact approval it
590
595
  returns. Turning `auto_merge_enabled` **on**, or dropping a required
591
596
  `merge_approval_required`, on the project default is refused
592
- (`409 NON_RELAXABLE`); ask Bridge support.
597
+ (`409 NON_RELAXABLE`); email info@bridgegpt.ai.
593
598
 
594
599
  ### `done_gate_config`
595
600
 
@@ -640,7 +645,7 @@ results are `merge.dry_run`, `merge.attempted`, `merge.succeeded`,
640
645
  `merge.failed` (retryable), and `merge.pending_approval` (waits for a human).
641
646
  **`merge.succeeded` is the only terminal merge event.**
642
647
 
643
- **Who performs the write (BAPI-832).** GitHub's merge endpoint needs
648
+ **Who performs the write.** GitHub's merge endpoint needs
644
649
  `contents: write`, and the Bridge GPT App is `contents: read`. So two paths merge
645
650
  with the operator's local `gh` session instead of the App token:
646
651
 
@@ -653,7 +658,7 @@ The mode is `merge_execution` on the supervisor config (`local` by default,
653
658
  `server` when the App holds `contents: write`). A caller that dies mid-merge is
654
659
  recovered by lease expiry; a retry reports `already_merged` if the merge landed.
655
660
 
656
- ## Worker ledger hardening (BAPI-527)
661
+ ## Worker ledger hardening
657
662
 
658
663
  This section applies to the observability layer. It keeps a worker's own ledger
659
664
  calls reliable. It is not a completion backstop.
@@ -705,14 +710,33 @@ or a missing `BAPI_EPIC_IMPLEMENTER_CLI_FILE`, returns the
705
710
  Run `epic-implementer likely-tests --base <sha>` with the executor's immutable,
706
711
  full 40-character comparison commit, after committing and before the first push.
707
712
  Fallback: `npx -y -p @bridge_gpt/mcp-server epic-implementer likely-tests --base <sha>`.
708
- Refresh after additional commits. Map references through the repository's declared
709
- targeted runner; references are data, never commands.
710
-
711
- This local read-only command returns zero even on invalid input or discovery failure.
712
- Stdout contains only one reference per line; stderr contains fixed advisory notes.
713
- Recent failures come first, then explicit `.bridge/verification-hints.json` pins,
714
- then sorted tracked tests containing literal changed-path/import references.
715
- Exact duplicates are removed before the 100-reference output limit.
713
+ Run either alone and keep stderr and the exit status visible. Refresh after
714
+ additional commits. Map references through the repository's declared targeted
715
+ runner; references are data, never commands.
716
+
717
+ This local read-only command returns `1` with a distinct bounded note on stderr
718
+ for invalid arguments (`invalid_arguments`), for git discovery that could not run
719
+ (`git_unavailable`), and for an internal discovery failure (including a failed
720
+ import). A failure never prints the `empty` note. A successful discovery returns
721
+ `0` and stays advisory: `empty`, `hints_missing`, `truncated`, and
722
+ `data_unavailable` are notes, not failures. A success that prints no reference
723
+ always prints the `empty` note once, so empty stdout with no `empty` note means
724
+ the command did not run. Stdout contains only one reference per line; stderr
725
+ contains fixed advisory notes.
726
+ Recent failures come first, then the sorted test files named in the worker's
727
+ declared touched files, then explicit `.bridge/verification-hints.json` pins, then
728
+ sorted tracked tests containing literal changed-path/import references. Exact
729
+ duplicates are removed before the 100-reference output limit; omitted candidates
730
+ raise the `truncated` note.
731
+
732
+ Declared files come from `BAPI_EPIC_IMPLEMENTER_DECLARED_TOUCHED_FILES_JSON`. An
733
+ entry is admitted only when it is a test file and exists in the worktree; a missing
734
+ accepted candidate raises `skipped_entries`, and malformed JSON raises
735
+ `data_unavailable`. When the variable is absent or blank the command is silent about
736
+ it. Ordinary `implement` and `ci_fix` workers do not currently receive this variable,
737
+ so for them declared files add nothing. Worker payloads are unchanged here; the
738
+ epic-owner server-payload follow-up is pending (no identifier exists in version-controlled
739
+ planning material yet).
716
740
 
717
741
  The optional worker-worktree `.conductor/recently-failed-tests.json` is
718
742
  `{"version":1,"tests":["most-recent-first reference"],"truncated":false}`. Child 3
@@ -726,3 +750,20 @@ file, 16 MiB scanned text, 10,000 sorted candidates, 10 seconds per Git subproce
726
750
  and 4 MiB Git output. Missing recent failures are silent. Disclose unavailable,
727
751
  malformed, unreadable, truncated, or unmappable coverage in the existing handoff.
728
752
  Retain available targeted verification; do not run a whole suite as fallback.
753
+
754
+ ### Worktree git-exclude provisioning
755
+
756
+ The executor writes `.claude/settings.local.json` and `.conductor/` into the shared
757
+ common `info/exclude` before any worktree lock, recently-failed file, or pre-spawn
758
+ verification (`provisionWorktreeSettingsExclude`, called at the start of the
759
+ reserved-spawn workflow against the executor clone). The writer keeps existing
760
+ content verbatim, appends only absent canonical lines, and publishes through a
761
+ uniquely named temporary file plus rename.
762
+
763
+ - **Detection:** a failure produces a bounded `excludeWarning` line in the executor's
764
+ error log (a category plus the worktree path, nothing else).
765
+ - **Containment:** the job continues. The deny layer's own exclude call is an
766
+ idempotent second attempt, and the existing dirty-worktree refusal in pre-spawn
767
+ verification is unchanged.
768
+ - **Remediation:** the warning tells the operator to inspect the worktree before
769
+ trusting its staged changes.
@@ -0,0 +1,131 @@
1
+ # Run your first epic with the Epic Implementer
2
+
3
+ The Epic Implementer takes a planned epic, hands each child ticket to an agent on your computer, waits for CI and review, and merges each child pull request into an `epic/<EPIC>` branch. A person merges the final pull request into your default branch.
4
+
5
+ You do four things, in this order: install, set up, define the epic, launch it. The same steps work with Bridge's own ticket storage and with Jira.
6
+
7
+ In every command below, `npx -y @bridge_gpt/mcp-server` is the launcher. Keep the `-y`; without it, `npx` stops to ask before it installs the package.
8
+
9
+ ## Prerequisites
10
+
11
+ Setup checks every item below for you, fixes what it can, and prints the one step it cannot fix. Read this list only when setup reports an item. Each bullet gives the item's name, its id, what it means, and the fix.
12
+
13
+ - **Unattended posture (Setup page)** (`server.unattended-posture`) — Bridge allows unattended runs for this repository. Fix: Turn on **Allow unattended Epic Implementer runs** on the repository Setup page, or launch with `--attended`.
14
+ - **Resolved merge mode** (`server.resolved-merge-mode`) — Bridge knows how child pull requests will be merged (your computer, a machine token, or GitHub Actions). Fix: Run `npx -y @bridge_gpt/mcp-server install conductor`; it fixes what it can and prints the one step it cannot.
15
+ - **Provider repository** (`server.provider-repository`) — Bridge knows the GitHub `owner/name` of this repository. Fix: Run `npx -y @bridge_gpt/mcp-server connect-github`, then run setup again.
16
+ - **Supervisor setup** (`server.supervisor-setup`) — The repository has a stored supervisor record. Fix: Run `npx -y @bridge_gpt/mcp-server install conductor`; it fixes what it can and prints the one step it cannot.
17
+ - **Supervisor configuration** (`server.supervisor-config`) — The supervisor record is complete: the test gate and the safe defaults are stored. Fix: Run `npx -y @bridge_gpt/mcp-server install conductor`; it fixes what it can and prints the one step it cannot.
18
+ - **Supervisor required CI checks** (`server.supervisor-required-checks`) — The CI checks a child pull request must pass before it merges are stored. Fix: Run setup and confirm the gate it proposes, or name a check with `--required-check <name>`.
19
+ - **Review policy** (`server.review-policy`) — The review policy for child pull requests is known. AI review is an opt-in choice by the repository admin. Fix: Nothing is needed unless you want AI review. Choose a policy at launch with `--review-policy`.
20
+ - **GitHub App credentials** (`server.github-credentials`) — Bridge's GitHub App is connected and can read this repository. Fix: Run `npx -y @bridge_gpt/mcp-server connect-github`, then run setup again.
21
+ - **GitHub App actions permission** (`server.github-actions-permission`) — The GitHub App may start workflow runs. Only needed when merges go through GitHub Actions. Fix: Accept the updated permission on the GitHub App's installation page, then run setup again.
22
+ - **Merge workflow eligibility** (`server.merge-execution-workflow`) — The merge workflow file is on the default branch and current. Only needed when merges go through GitHub Actions. Fix: Run `npx -y @bridge_gpt/mcp-server install conductor --merge-workflow --codeowner <@org/team|@user>`, merge the pull request it opens, then run setup again.
23
+ - **Merge branch policy** (`server.merge-execution-branch-policy`) — The default branch rules let the merge workflow do its job. Only needed when merges go through GitHub Actions. Fix: Adjust the branch rule or ruleset as setup describes, then run setup again.
24
+ - **Executor server observation** (`server.executor-readiness`) — Bridge has seen a heartbeat from an executor for this repository. Before your first run this can be missing: `drive-epic` starts the executor for each run. Fix: Launch the epic with `npx -y @bridge_gpt/mcp-server drive-epic <EPIC>`.
25
+ - **Review workflow protocol** (`server.review-workflow`) — The review workflow on the default branch matches the review policy. Only needed with AI review. Fix: Run setup; it names the workflow change to make.
26
+ - **Conductor CI migration guard** (`server.conductor-ci-workflow`) — The CI workflow file `epic-implementer-ci.yml` is on the default branch and runs the migration guard where needed. Fix: Run setup, merge the setup pull request it opens, then run setup again.
27
+ - **Escalation channel (webhook or email)** (`server.unattended-notify-default`) — Bridge has somewhere to send an escalation: a verified notify webhook, or your account email. Fix: Declare a notify webhook, or verify your account email.
28
+ - **Repository workflow readiness** (`server.repository-workflow-readiness`) — The CI and review workflows are confirmed on the default branch. Fix: Run setup, merge the setup pull request, then run setup again.
29
+ - **Workflows at indexed commit** (`server.indexed-workflows`) — The repository index includes the workflow files on the default branch. Fix: Merge the setup pull request, then run setup again. It starts the re-index and reports this item as pending until the index reaches that commit.
30
+ - **Known test command** (`server.test-command`) — Bridge knows the command that runs this repository's tests. Fix: Run setup and give the test command when it asks, or run the learn step.
31
+ - **Service availability** (`server.service-availability`) — Bridge could read this repository's readiness from the server. Fix: Retry in a few minutes. If it keeps failing, email info@bridgegpt.ai.
32
+ - **Claude login** (`install.claude-login`) — Claude Code is signed in on this computer. Fix: Run `claude` and sign in, then run setup again.
33
+ - **Repository identity** (`install.identity`) — Bridge knows which repository this folder is. Fix: Run setup from the repository root, or pass `--repo <name>`.
34
+ - **Bridge API credential** (`install.credential`) — A Bridge API key is stored for this repository. Fix: Run `npx -y @bridge_gpt/mcp-server install`.
35
+ - **Server connectivity** (`install.connectivity`) — This computer can reach the Bridge server. Fix: Check your network and any `BAPI_BASE_URL` setting, then run setup again.
36
+ - **Bootstrap config fields** (`install.bootstrap`) — The repository's Bridge configuration fields are filled in. Fix: Run `npx -y @bridge_gpt/mcp-server install`.
37
+ - **Integration credentials** (`install.integrations`) — The integration credentials this repository uses, such as Jira or GitHub, are stored. Fix: Run `npx -y @bridge_gpt/mcp-server install`.
38
+ - **GitHub connection** (`install.github`) — Bridge's GitHub App is connected to this repository. Fix: Run `npx -y @bridge_gpt/mcp-server connect-github`.
39
+ - **Repository indexing** (`install.indexing`) — The repository has been indexed by Bridge. Fix: Run `/parse-repository`, or let setup queue the index.
40
+ - **Conductor event ledger** (`conductor.ledger`) — The local Epic Implementer event ledger can be read. Fix: Run `npx -y @bridge_gpt/mcp-server epic-implementer doctor` and follow what it prints.
41
+ - **Conductor git hooks** (`conductor.git-hooks`) — Optional: the git hooks that feed the local event ledger are installed. Fix: Run `npx -y @bridge_gpt/mcp-server epic-implementer install-git-hooks`.
42
+ - **Epic Implementer MCP profile** (`conductor.mcp-profile`) — The `epic_implementer` tool profile is on in your MCP host. Fix: Let setup add it (it asks first), then restart your MCP client.
43
+ - **GitHub CLI availability** (`conductor.gh-cli`) — The GitHub CLI (`gh`) is installed and signed in. Fix: Install `gh` and run `gh auth login`.
44
+ - **Configured merge credential** (`conductor.merge-credential`) — A GitHub token for merging child pull requests is available on this computer. Fix: Let setup store one (it asks first), or set `GITHUB_MERGE_TOKEN`.
45
+ - **Native ledger binding** (`conductor.native-ledger`) — The ledger's native component loads on this computer. Fix: Run `npx -y @bridge_gpt/mcp-server epic-implementer doctor` and follow what it prints.
46
+ - **Worker MCP registration form** (`conductor.mcp-registration-form`) — Workers register the Bridge tools in the form the executor expects. Fix: Run `npx -y @bridge_gpt/mcp-server epic-implementer doctor` and follow what it prints.
47
+ - **Expected Node engine** (`conductor.node-engine`) — The Node.js version meets the package's engine range. Fix: Install a supported Node.js (18 or newer; 20 or newer for the git hooks).
48
+ - **Deny-layer enforcement** (`conductor.deny-enforcement`) — Claude Code enforces the permission denials that keep workers inside the repository. Fix: Run `npx -y @bridge_gpt/mcp-server epic-implementer doctor` to see why the check could not confirm it.
49
+ - **Claude login** (`conductor.claude-login`) — Claude Code is signed in for the workers. Fix: Run `claude` and sign in, then run setup again.
50
+ - **Merge credential capability** (`conductor.merge-credential-capability`) — The merge token can push to the repository and read pull requests. Fix: Replace the token (setup offers to), then run setup again.
51
+ - **Worktree preparation** (`conductor.worktree-preparation`) — The executor's clone can keep its working files out of git (`.git/info/exclude` exists or can be written). Fix: Make `.git/info/exclude` writable in this clone.
52
+ - **Supervisor gate profile** (`conductor.install-section-supervisor-gate-profile`) — The repository's test gate profile is stored and valid. Fix: Run `npx -y @bridge_gpt/mcp-server install conductor`; it fixes what it can and prints the one step it cannot.
53
+ - **Supervisor required CI checks** (`conductor.install-section-supervisor-required-checks`) — The required CI checks in the gate match checks the provider reports. Fix: Run `npx -y @bridge_gpt/mcp-server install conductor`; it fixes what it can and prints the one step it cannot.
54
+ - **Supervisor review-policy alignment** (`conductor.install-section-supervisor-review-alignment`) — The review policy and the review workflow agree. Fix: Run `npx -y @bridge_gpt/mcp-server install conductor`; it fixes what it can and prints the one step it cannot.
55
+ - **GitHub App actions permission** (`conductor.install-section-github-actions-permission`) — The GitHub App may start workflow runs. Only needed when merges go through GitHub Actions. Fix: Accept the updated permission on the GitHub App's installation page.
56
+ - **Merge execution eligibility** (`conductor.install-section-merge-execution-eligibility`) — This repository can use GitHub Actions merges. Only needed for that merge mode. Fix: Run `npx -y @bridge_gpt/mcp-server install conductor --merge-workflow --codeowner <@org/team|@user>` and merge its pull request.
57
+ - **Epic Implementer MCP profile token** (`conductor.install-section-epic-implementer-profile-token`) — The Bridge key used by the Epic Implementer tool profile is stored. Fix: Run `npx -y @bridge_gpt/mcp-server install conductor`; it fixes what it can and prints the one step it cannot.
58
+ - **Conductor hook targets** (`conductor.install-section-conductor-hook-targets`) — The git hook targets are in place for this clone. Fix: Run `npx -y @bridge_gpt/mcp-server epic-implementer install-git-hooks`.
59
+ - **GitHub Actions merge: local observation prerequisites** (`conductor.install-section-gh-actions-merge-auth`) — This computer can observe GitHub Actions merges. Only needed for that merge mode. Fix: Sign in with `gh auth login` and rerun setup.
60
+ - **GitHub Actions merge: capability observability** (`conductor.install-section-gh-actions-merge-observable`) — Bridge can observe the outcome of GitHub Actions merges. Only needed for that merge mode. Fix: Rerun setup and follow the step it prints.
61
+ - **Epic Implementer ledger loadability** (`conductor.install-section-epic-implementer-ledger-loadability`) — The local ledger can be loaded by the tools that read it. Fix: Run `npx -y @bridge_gpt/mcp-server epic-implementer doctor` and follow what it prints.
62
+ - **Launch evidence** (`server.admission-evidence`) — Bridge has the evidence it needs to admit a launch. Fix: Run setup, then launch again.
63
+ - **Launch evidence: unattended consent** (`server.admission-unattended-consent`) — Launch check: unattended runs are allowed. Fix: Turn on **Allow unattended Epic Implementer runs** on the Setup page, or launch with `--attended`.
64
+ - **Launch evidence: notification destination** (`server.admission-notify-webhook`) — Launch check: an escalation destination is verified. Fix: Declare a notify webhook, or verify your account email.
65
+ - **Launch evidence: repository workflows** (`server.admission-repository-readiness`) — Launch check: the CI and review workflows are confirmed. Fix: Run setup, merge the setup pull request, then run setup again.
66
+ - **Launch evidence: required CI checks** (`server.admission-required-checks`) — Launch check: the required CI checks are stored. Fix: Run `npx -y @bridge_gpt/mcp-server install conductor`; it fixes what it can and prints the one step it cannot.
67
+ - **Launch evidence: indexed repository** (`server.admission-index-provenance`) — Launch check: the index reaches the commit that holds the workflows. Fix: Merge the setup pull request, then run setup again.
68
+ - **Repository test gate** (`server.gate-profile`) — The repository's test gate is stored. Fix: Run `npx -y @bridge_gpt/mcp-server install conductor`; it fixes what it can and prints the one step it cannot.
69
+ - **Repository test gate warnings** (`server.gate-profile-warnings`) — The stored test gate has no unresolved warnings. Fix: Read the warnings setup prints and confirm or edit the gate.
70
+ - **Effective review mode** (`server.effective-review-mode`) — Bridge shows which review mode child pull requests will use. Fix: Choose a review policy at launch with `--review-policy` if you want a different one.
71
+ - **Epic branch CI** (`server.epic-branch-ci-decision`) — Someone has decided whether CI runs on pull requests into the epic branch. Fix: Run setup and answer the epic-branch CI question, or pass `--epic-branch-ci-decision include|decline`.
72
+ - **Epic branch CI coverage** (`server.epic-branch-ci-coverage-warning`) — Your CI covers pull requests into the epic branch. Fix: Add `epic/**` to the branches your CI workflow runs on.
73
+ - **Additional readiness diagnostics** (`server.diagnostics`) — Extra readiness diagnostics from the server are clear. Fix: Read the diagnostic text; each names its own fix.
74
+ - **Command versions** (`conductor.command-drift`) — The installed Epic Implementer commands match this package's version. Fix: Run `npx -y @bridge_gpt/mcp-server install` to refresh them.
75
+ - **Escalation delivery** (`escalation-reachability`) — An escalation can actually be delivered. Fix: Verify your account email or fix the webhook, then run setup again.
76
+
77
+ ## 1. Install
78
+
79
+ Run this once per project. Skip it when Bridge is already installed.
80
+
81
+ ```bash
82
+ npx -y @bridge_gpt/mcp-server install
83
+ ```
84
+
85
+ It writes this guide to `docs/install/epic-implementer-install.md` in your project. Run it again any time to refresh that file.
86
+
87
+ ## 2. Set up
88
+
89
+ Run this once per repository, from the repository root, in your own terminal:
90
+
91
+ ```bash
92
+ npx -y @bridge_gpt/mcp-server install conductor
93
+ ```
94
+
95
+ `install-bridge conductor` is the same command with another spelling. Setup checks everything first (read-only), fixes only what is missing, checks again, and ends with one verdict: "Ready for your first epic" or "Not ready: N steps left", with the fix for each step. It asks before anything that writes, and without a terminal every question is a "no".
96
+
97
+ When setup reports that its setup pull request is waiting, it prints `merge the setup PR` with the pull request's address. Merge that pull request, then run setup again. Setup starts the re-index, and reports the item as pending ("indexing is running; re-run setup when it finishes", or "indexing was queued; re-run setup when it finishes") until the index reaches the merged commit. Run setup again until it says "Ready for your first epic".
98
+
99
+ ## 3. Define the epic
100
+
101
+ In Claude Code, run:
102
+
103
+ ```text
104
+ /define-tickets
105
+ ```
106
+
107
+ It writes real child ticket keys, `epic-plan.dag.json`, and `epic-plan.meta.json`, then hands off to `/drive-epic-run`. The meta file is how the launch finds the plan from the epic key.
108
+
109
+ ## 4. Launch
110
+
111
+ In Claude Code, run:
112
+
113
+ ```text
114
+ /drive-epic-run <EPIC> [<plan path>]
115
+ ```
116
+
117
+ It previews the launch, asks you once, creates the run through `drive-epic`, and drives the run to the end. From a shell, run the same launch yourself:
118
+
119
+ ```bash
120
+ npx -y @bridge_gpt/mcp-server drive-epic <EPIC>
121
+ ```
122
+
123
+ Add `--dry-run` for a read-only preview, or `--attended` to opt out of unattended merging. `drive-epic --help` lists the common options, and `drive-epic --help-advanced` lists the rest.
124
+
125
+ ## Advanced: the planner
126
+
127
+ `/plan-epic` is the advanced planner. It writes placeholder `TBD-N` keys instead of real ones. You create the child tickets yourself, run `emit-epic-implementer-bundle finalize` to replace the placeholders and write the plan files, then run `/drive-epic-run`. Planning never creates or approves a run.
128
+
129
+ ## If something goes wrong
130
+
131
+ Every refusal names the missing item and its fix, and creates nothing. Run setup again after you fix an item. For a read-only report of every item, run `npx -y @bridge_gpt/mcp-server epic-implementer readiness --json`. If you are stuck, email info@bridgegpt.ai.