You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
| Background Work |`extensions/background-work.ts`| Worker state transitions, protocol semantics, pre-flight task docs, synthetic status artifacts, heartbeat dedup. |
20
+
| Worker Lifecycle |`extensions/worker-lifecycle.ts`| Pure status transitions and lifecycle selectors: review/respawn/harvest eligibility, dock-terminal age, and prune disposition. |
21
+
| Background Work |`extensions/background-work.ts`| Protocol payload shaping, pre-flight task docs, synthetic status artifacts, and heartbeat artifact dedup. |
21
22
| Worker Review |`extensions/worker-review.ts`| Shared Worker + Artifact projection: state, result artifact, summary, recommendations, and status-card text. |
22
23
| Worker Conflicts |`extensions/worker-conflicts.ts`| Edited-file overlap detection across workers; warning text for dock, dashboard, and promote confirmation. |
| Worker Change Review |`extensions/worker-change-review.ts`| One review operation over a deterministic change set: built-in diff, Hunk fallback, comment disposition, and worker-only comment delivery. It cannot promote or mount artifacts. |
26
+
| Hunk Diff Review |`extensions/worker-diff-review.ts`| Hunk process adapter: availability, exact patch extraction, launch, comment harvesting, and comment formatting. |
| Parent Runtime |`extensions/parent-runtime.ts`| Parent-only worker watch/dock startup and teardown. The parent owns cache refresh, reconciliation, harvest, tmux status, and dock animation. |
39
+
| Worker Runtime |`extensions/worker-runtime.ts`| Worker-only guardrail/protocol registration plus heartbeat lifecycle. The worker owns protocol tools, nudges, shell fallback, event capture, and allowed child spawning. |
40
+
| Docket Views |`extensions/docket-views/`| Artifact/file viewers, shared layout primitives, and router/verdict action type boundaries. Runtime state is not imported into views. |
41
+
| Docket Keymap |`extensions/docket-keymap.ts`| Normalized physical-key bindings, conflict checking, and shared card/footer/help hint rendering for interactive views. |
34
42
35
43
## Worker lifecycle
36
44
@@ -42,6 +50,8 @@ Each module owns its data, its interface, and its tests. Adapters at the seam ta
42
50
6. Worker calls `docket_done` / `docket_fail` → state goes terminal → row enters `ready` / `failed` until evicted (`worker.dockIdleHideMinutes`) or pruned (`worker.pruneAfterHours`). When the prune sweep removes a terminal worker that never got a verdict (its id is absent from the decision ledger), it records a `worker_evicted_unreviewed` event first so the debt is counted before the record is gone.
43
51
7. If the worker *process* dies, `remain-on-exit` keeps the dead pane. The dock's harvest sweep (`isPaneHarvestCandidate` → `WorkerStore.harvestPaneTail`) captures the last 200 lines to `pane-tail.txt`, kills the window, and stamps `paneCapturedAt` on the status so the probe never repeats. The tail surfaces as a `terminal tail` artifact in review and as the last lines on the failed verdict card. Workers in a terminal state whose pane is still alive (a protocol `docket_fail` with pi still running) are left untouched so you can keep chatting with them.
44
52
53
+
For a ready worker, the verdict card can open the deterministic change-set artifact directly or ask Hunk to annotate its exact patch. `Worker Change Review` owns the fallback to the built-in diff and comment send/copy/ignore handling. Only a successful send returns `comments-sent`; `Worker Verdict` then records the chat decision and advances the queue.
54
+
45
55
## Worker protocol
46
56
47
57
One contract for every kind. The MD body of a kind extends the universal guardrails; it does not replace them.
Copy file name to clipboardExpand all lines: docs/configuration.md
+1-2Lines changed: 1 addition & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -73,7 +73,6 @@ Evidence bundles are bundle-first: by default `/docket save` writes a determinis
73
73
|`worker.pruneAfterHours`| 24 | auto-prune `ended` worker dirs after this many hours; 0 disables. |
74
74
|`worker.tmuxStatusLine`| false | write a compact summary to `docket-workers`' `status-right`. |
75
75
|`worker.captureTerminal`| false | enable `tmux pipe-pane` to `<worker-dir>/pane.log` per worker. |
76
-
|`worker.autoRespawn`| false | reserved; today `/docket respawn` is manual. |
77
76
|`worker.autoEmbedSummary`| false | when true, append a short summary (outcome + 1-line summary + up to 5 recommended bullets) to the parent session as a worker reaches `ready`. Default false keeps the parent JSONL fully manual — the inbox card still surfaces the ready worker; nothing is auto-injected. |
78
77
|`worker.parentSeedPolicy`|`none`| default parent-seed policy for `/docket spawn` when neither `--seed`/`--fresh` nor the kind sets one. `"none"` (default) spawns fresh workers with no parent context; `"full"` seeds the worker with the parent session JSONL (reuses prompt cache prefix but inherits full parent context). Use as a project-wide escape hatch when most workers need parent context. |
79
78
|`worker.guardrailsPath`| bundled | absolute or cwd-relative path to a guardrail file appended to every worker prompt. |
@@ -96,7 +95,7 @@ Bundled kinds (`default`, `scout`, `patcher`) live in `extensions/worker-kinds/`
96
95
|`name`| — | required; kebab-case slug used by `--as`|
97
96
|`description`| — | one-line shown in `/docket kinds`|
98
97
|`model`| parent | optional model override (`provider/model` string) |
|`read_only`| false | when true, appendix tells the worker not to edit files |
101
100
|`default_worktree`| true | spawn this kind in a detached worktree by default |
102
101
|`parent_seed`|`none`|`none` for a fresh worker; `full` to seed the worker session with the parent's JSONL (reuses prompt cache prefix but inherits full parent context — use only when the worker needs it). Per-spawn `--seed`/`--fresh` flags override. |
Copy file name to clipboardExpand all lines: extensions/docket-config.ts
-3Lines changed: 0 additions & 3 deletions
Original file line number
Diff line number
Diff line change
@@ -20,8 +20,6 @@ export type DocketWorkerConfig = {
20
20
tmuxStatusLine?: boolean;
21
21
/** When true, every spawned worker also runs tmux pipe-pane to <worker-dir>/pane.log for post-hoc debug. */
22
22
captureTerminal?: boolean;
23
-
/** When true, /docket offers to re-window orphan workers when the shared tmux session is gone but their dirs are still live. */
24
-
autoRespawn?: boolean;
25
23
/** Default parent-seed policy when neither `--seed`/`--fresh` nor the kind sets one. `"none"` (default) spawns fresh workers; `"full"` seeds the worker with the parent session JSONL. */
26
24
parentSeedPolicy?: "full"|"none";
27
25
/** When true, a short summary message is appended to the parent session when a worker reaches ready. Default false: nothing enters the parent JSONL automatically — the inbox card still surfaces the ready worker. */
0 commit comments