wicked-crew 0.6.0 → 0.7.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (117) hide show
  1. package/README.md +103 -0
  2. package/dist/api/audit.d.ts +13 -0
  3. package/dist/api/audit.d.ts.map +1 -1
  4. package/dist/api/audit.js +18 -2
  5. package/dist/api/audit.js.map +1 -1
  6. package/dist/api/endpoint-manifest-live.d.ts +29 -0
  7. package/dist/api/endpoint-manifest-live.d.ts.map +1 -0
  8. package/dist/api/endpoint-manifest-live.js +72 -0
  9. package/dist/api/endpoint-manifest-live.js.map +1 -0
  10. package/dist/api/endpoint-manifest.d.ts +107 -0
  11. package/dist/api/endpoint-manifest.d.ts.map +1 -0
  12. package/dist/api/endpoint-manifest.js +108 -0
  13. package/dist/api/endpoint-manifest.js.map +1 -0
  14. package/dist/api/guidance-index.d.ts +39 -0
  15. package/dist/api/guidance-index.d.ts.map +1 -0
  16. package/dist/api/guidance-index.js +67 -0
  17. package/dist/api/guidance-index.js.map +1 -0
  18. package/dist/api/open-path.d.ts +16 -0
  19. package/dist/api/open-path.d.ts.map +1 -1
  20. package/dist/api/open-path.js +22 -0
  21. package/dist/api/open-path.js.map +1 -1
  22. package/dist/api/requirements.d.ts +7 -0
  23. package/dist/api/requirements.d.ts.map +1 -1
  24. package/dist/api/requirements.js +23 -2
  25. package/dist/api/requirements.js.map +1 -1
  26. package/dist/api/retry-index.d.ts +30 -0
  27. package/dist/api/retry-index.d.ts.map +1 -0
  28. package/dist/api/retry-index.js +45 -0
  29. package/dist/api/retry-index.js.map +1 -0
  30. package/dist/api/routes.d.ts +53 -1
  31. package/dist/api/routes.d.ts.map +1 -1
  32. package/dist/api/routes.js +399 -30
  33. package/dist/api/routes.js.map +1 -1
  34. package/dist/api/run-files.d.ts +63 -0
  35. package/dist/api/run-files.d.ts.map +1 -0
  36. package/dist/api/run-files.js +271 -0
  37. package/dist/api/run-files.js.map +1 -0
  38. package/dist/api/server.d.ts +79 -0
  39. package/dist/api/server.d.ts.map +1 -1
  40. package/dist/api/server.js +183 -8
  41. package/dist/api/server.js.map +1 -1
  42. package/dist/api/stall-watchdog.d.ts +62 -0
  43. package/dist/api/stall-watchdog.d.ts.map +1 -0
  44. package/dist/api/stall-watchdog.js +138 -0
  45. package/dist/api/stall-watchdog.js.map +1 -0
  46. package/dist/cli/index.js +89 -15
  47. package/dist/cli/index.js.map +1 -1
  48. package/dist/core/adapter.d.ts +36 -10
  49. package/dist/core/adapter.d.ts.map +1 -1
  50. package/dist/core/adapter.js +245 -31
  51. package/dist/core/adapter.js.map +1 -1
  52. package/dist/core/bridge-reaper.d.ts +134 -0
  53. package/dist/core/bridge-reaper.d.ts.map +1 -0
  54. package/dist/core/bridge-reaper.js +286 -0
  55. package/dist/core/bridge-reaper.js.map +1 -0
  56. package/dist/core/deliver.d.ts +118 -0
  57. package/dist/core/deliver.d.ts.map +1 -0
  58. package/dist/core/deliver.js +241 -0
  59. package/dist/core/deliver.js.map +1 -0
  60. package/dist/core/deliverable-floor.d.ts +155 -0
  61. package/dist/core/deliverable-floor.d.ts.map +1 -0
  62. package/dist/core/deliverable-floor.js +248 -0
  63. package/dist/core/deliverable-floor.js.map +1 -0
  64. package/dist/core/exec.d.ts +2 -0
  65. package/dist/core/exec.d.ts.map +1 -1
  66. package/dist/core/exec.js.map +1 -1
  67. package/dist/core/types.d.ts +79 -1
  68. package/dist/core/types.d.ts.map +1 -1
  69. package/dist/core/types.js +3 -0
  70. package/dist/core/types.js.map +1 -1
  71. package/dist/interactive/bridge-pool.d.ts +52 -0
  72. package/dist/interactive/bridge-pool.d.ts.map +1 -1
  73. package/dist/interactive/bridge-pool.js +93 -12
  74. package/dist/interactive/bridge-pool.js.map +1 -1
  75. package/dist/interactive/chat-events.d.ts +207 -0
  76. package/dist/interactive/chat-events.d.ts.map +1 -0
  77. package/dist/interactive/chat-events.js +769 -0
  78. package/dist/interactive/chat-events.js.map +1 -0
  79. package/dist/interactive/demo-events.d.ts +283 -0
  80. package/dist/interactive/demo-events.d.ts.map +1 -0
  81. package/dist/interactive/demo-events.js +889 -0
  82. package/dist/interactive/demo-events.js.map +1 -0
  83. package/dist/interactive/draft-events.d.ts +87 -7
  84. package/dist/interactive/draft-events.d.ts.map +1 -1
  85. package/dist/interactive/draft-events.js +352 -49
  86. package/dist/interactive/draft-events.js.map +1 -1
  87. package/dist/interactive/edit-events.d.ts +25 -2
  88. package/dist/interactive/edit-events.d.ts.map +1 -1
  89. package/dist/interactive/edit-events.js +88 -9
  90. package/dist/interactive/edit-events.js.map +1 -1
  91. package/dist/interactive/repo-snapshot.d.ts +100 -0
  92. package/dist/interactive/repo-snapshot.d.ts.map +1 -0
  93. package/dist/interactive/repo-snapshot.js +289 -0
  94. package/dist/interactive/repo-snapshot.js.map +1 -0
  95. package/dist/projects/graph-paths.d.ts +122 -0
  96. package/dist/projects/graph-paths.d.ts.map +1 -0
  97. package/dist/projects/graph-paths.js +175 -0
  98. package/dist/projects/graph-paths.js.map +1 -0
  99. package/dist/projects/graph.d.ts +191 -0
  100. package/dist/projects/graph.d.ts.map +1 -0
  101. package/dist/projects/graph.js +829 -0
  102. package/dist/projects/graph.js.map +1 -0
  103. package/dist/projects/routes.d.ts +17 -0
  104. package/dist/projects/routes.d.ts.map +1 -1
  105. package/dist/projects/routes.js +139 -0
  106. package/dist/projects/routes.js.map +1 -1
  107. package/dist/qe/ledger.d.ts +3 -2
  108. package/dist/qe/ledger.d.ts.map +1 -1
  109. package/dist/qe/ledger.js +5 -4
  110. package/dist/qe/ledger.js.map +1 -1
  111. package/dist/studio/assets/index-D-BFUYnY.js +530 -0
  112. package/dist/studio/assets/index-D6S9zUtO.css +32 -0
  113. package/dist/studio/index.html +5 -3
  114. package/endpoint-manifest.json +624 -0
  115. package/package.json +8 -5
  116. package/dist/studio/assets/index-CCwXa1cn.js +0 -428
  117. package/dist/studio/assets/index-HWxo0h41.css +0 -32
@@ -0,0 +1,271 @@
1
+ // GET /runs/:id/files + GET /runs/:id/diff machinery (DES-FEEDBACK-002 CREW-1).
2
+ //
3
+ // The studio's in-app file & diff viewer cannot read the daemon host's filesystem, so the daemon
4
+ // serves the bytes — which is exactly why every path is contained FIRST against the same root set
5
+ // `POST /open` validates (`allowedRootsFor` + `isInsideRoot`, open-path.ts), every payload is
6
+ // capped, and git runs through `execCapped` with argv arrays only (never a shell string) and
7
+ // `--no-ext-diff` (a configured external diff driver must never execute here). Both routes are
8
+ // read-only by construction: `fs` reads and `git diff`/`git status` — zero write capability, a
9
+ // strictly smaller threat surface than `/open` handing the path to an OS opener.
10
+ import { promises as fsp } from 'node:fs';
11
+ import { execCapped, ExecOutputTooLarge } from '../core/exec.js';
12
+ /** File-content cap (DES-FEEDBACK-002 §3.3): past this, `content` holds the first 512 KB and
13
+ * `truncated: true` — the studio renders a labeled truncation banner, never a silent amputation. */
14
+ export const FILE_CONTENT_CAP_BYTES = 512 * 1024;
15
+ /** Binary sniff window: a NUL byte in the first 8 KB ⇒ `binary: true`, `content: ""` — the studio
16
+ * falls back to the external-open affordance rather than rendering mojibake. */
17
+ export const BINARY_SNIFF_BYTES = 8 * 1024;
18
+ /** Diff output cap (§3.3): past this the diff is cut at 1 MB and `truncated: true`. */
19
+ export const DIFF_OUTPUT_CAP_BYTES = 1024 * 1024;
20
+ /** The target exists but is not a regular file (directory, socket, …) — the route's 400, distinct
21
+ * from ENOENT's 404. Serving directory listings is explicitly out of scope (§3.3). */
22
+ export class NotARegularFileError extends Error {
23
+ path;
24
+ constructor(path) {
25
+ super(`not a regular file: ${path}`);
26
+ this.path = path;
27
+ this.name = 'NotARegularFileError';
28
+ }
29
+ }
30
+ /**
31
+ * Read at most `FILE_CONTENT_CAP_BYTES` of `target`. The open-then-fstat order (not stat-then-open)
32
+ * closes the classic swap race: the size and the bytes come from the SAME open file description.
33
+ * Callers must have contained `target` already — this function does filesystem work only.
34
+ */
35
+ export async function readFileCapped(target) {
36
+ const fh = await fsp.open(target, 'r');
37
+ try {
38
+ const st = await fh.stat();
39
+ if (!st.isFile())
40
+ throw new NotARegularFileError(target);
41
+ const size = st.size;
42
+ const toRead = Math.min(size, FILE_CONTENT_CAP_BYTES);
43
+ const buf = Buffer.alloc(toRead);
44
+ let off = 0;
45
+ while (off < toRead) {
46
+ const { bytesRead } = await fh.read(buf, off, toRead - off, off);
47
+ if (bytesRead === 0)
48
+ break; // file shrank underneath us — serve what exists
49
+ off += bytesRead;
50
+ }
51
+ const got = buf.subarray(0, off);
52
+ if (got.subarray(0, Math.min(off, BINARY_SNIFF_BYTES)).includes(0)) {
53
+ return { content: '', size, truncated: false, binary: true };
54
+ }
55
+ return { content: got.toString('utf8'), size, truncated: size > FILE_CONTENT_CAP_BYTES, binary: false };
56
+ }
57
+ finally {
58
+ await fh.close();
59
+ }
60
+ }
61
+ const GIT_TIMEOUT_MS = 10_000;
62
+ // ── Diff base (DES-UX-001 §8.1, CREW-UX-1) ─────────────────────────────────────────────────────
63
+ /** `?base=merge-base` — the one non-ref literal: diff against `git merge-base <default-branch>
64
+ * HEAD`, i.e. the run branch's fork point, so committed run work is visible (§8.1). */
65
+ export const MERGE_BASE_LITERAL = 'merge-base';
66
+ /** `base` is not a plain ref — a flag, a path, a revision range, a separator. Rejected BEFORE any
67
+ * git process sees it: the query parameter is a diff baseline, never a command surface (§8.1). */
68
+ export class InvalidDiffBaseError extends Error {
69
+ base;
70
+ constructor(base) {
71
+ super('`base` must be a plain git ref (branch, tag, or commit id) — ' +
72
+ 'flags, paths, revision ranges, and separators are rejected');
73
+ this.base = base;
74
+ this.name = 'InvalidDiffBaseError';
75
+ }
76
+ }
77
+ /** `base` is well-formed but does not resolve to a commit inside the run's repo — containment:
78
+ * a ref from another repo (or thin air) is a 400, never a git error surfaced as a 500. */
79
+ export class UnresolvableDiffBaseError extends Error {
80
+ base;
81
+ constructor(base, detail) {
82
+ super(`unresolvable \`base\`: ${detail}`);
83
+ this.base = base;
84
+ this.name = 'UnresolvableDiffBaseError';
85
+ }
86
+ }
87
+ /** A plain ref: git's own charset for the safe subset — alphanumeric start (excludes `-flag`,
88
+ * `.hidden`, `/abs/path`), then word/dot/slash/dash. `..` (ranges AND traversal), `~`/`^`/`@{}`
89
+ * (rev operators), `:`, whitespace, and `;` are all outside the charset or explicitly banned. */
90
+ const PLAIN_REF_RE = /^[A-Za-z0-9][A-Za-z0-9._/-]{0,255}$/;
91
+ export function isPlainRef(base) {
92
+ return PLAIN_REF_RE.test(base) && !base.includes('..') && !base.endsWith('/');
93
+ }
94
+ /** One contained git read: argv array (never a shell string), capped, cwd-scoped to the run's
95
+ * workdir. Returns trimmed stdout, or `null` ONLY when git ran to completion and answered "no"
96
+ * (unresolvable ref, no merge base, …) — a plain non-zero exit. Operational failures are never
97
+ * `null`: ENOENT (git missing), "not a git repository", a timed-out/killed process (`killed`/
98
+ * `signal` set), and output-cap overflow all rethrow, so they surface as the route's 500 rather
99
+ * than masquerading as a 400 "unresolvable base" (Copilot, #307). */
100
+ async function gitQuery(workdir, args) {
101
+ try {
102
+ const { stdout } = await execCapped('git', args, { timeout: GIT_TIMEOUT_MS, cwd: workdir });
103
+ return stdout.trim();
104
+ }
105
+ catch (err) {
106
+ if (err.code === 'ENOENT')
107
+ throw err;
108
+ if (err instanceof ExecOutputTooLarge)
109
+ throw err;
110
+ const proc = err;
111
+ if (proc.killed === true || (proc.signal !== undefined && proc.signal !== null))
112
+ throw err;
113
+ const msg = err instanceof Error ? err.message : String(err);
114
+ if (msg.toLowerCase().includes('not a git repository'))
115
+ throw err;
116
+ return null;
117
+ }
118
+ }
119
+ /** SHA shapes rev-parse may emit (SHA-1 today, SHA-256 repos exist). Anything else is treated as
120
+ * "did not resolve" — the resolved value is what reaches `git diff`, never the caller's text. */
121
+ const COMMIT_SHA_RE = /^[0-9a-f]{40,64}$/;
122
+ /**
123
+ * Resolve `?base=` to a commit SHA inside the run's repo, or throw the route's named 400s.
124
+ * Two accepted spellings (§8.1): the literal `merge-base` → `git merge-base <default-branch>
125
+ * HEAD`; or a plain ref that `git rev-parse --verify` resolves IN THIS repo. Everything git
126
+ * ultimately diffs against is the resolved SHA — the raw parameter never reaches `git diff`,
127
+ * and `--end-of-options` keeps even a validated ref from ever parsing as a flag.
128
+ */
129
+ async function resolveDiffBase(workdir, base) {
130
+ if (base === MERGE_BASE_LITERAL) {
131
+ // Default branch: origin's HEAD when the repo has one, else local main/master.
132
+ let branch = null;
133
+ const symref = await gitQuery(workdir, ['symbolic-ref', '--quiet', 'refs/remotes/origin/HEAD']);
134
+ if (symref !== null && symref.startsWith('refs/remotes/')) {
135
+ branch = symref.slice('refs/remotes/'.length);
136
+ }
137
+ else {
138
+ for (const cand of ['main', 'master']) {
139
+ if ((await gitQuery(workdir, ['rev-parse', '--verify', `refs/heads/${cand}`])) !== null) {
140
+ branch = cand;
141
+ break;
142
+ }
143
+ }
144
+ }
145
+ if (branch === null) {
146
+ throw new UnresolvableDiffBaseError(base, 'no default branch found in this repo to merge-base against');
147
+ }
148
+ const sha = await gitQuery(workdir, ['merge-base', '--end-of-options', branch, 'HEAD']);
149
+ if (sha === null || !COMMIT_SHA_RE.test(sha)) {
150
+ throw new UnresolvableDiffBaseError(base, `no merge base between ${branch} and HEAD`);
151
+ }
152
+ return sha;
153
+ }
154
+ if (!isPlainRef(base))
155
+ throw new InvalidDiffBaseError(base);
156
+ const sha = await gitQuery(workdir, [
157
+ 'rev-parse',
158
+ '--verify',
159
+ '--end-of-options',
160
+ `${base}^{commit}`,
161
+ ]);
162
+ if (sha === null || !COMMIT_SHA_RE.test(sha)) {
163
+ throw new UnresolvableDiffBaseError(base, `ref does not resolve inside the run's repo: ${base}`);
164
+ }
165
+ return sha;
166
+ }
167
+ /** Git's ways of saying "there is nothing here to diff" — a real answer (`diff: ""`), not an
168
+ * error. Mirrors the git-history route's tolerance (routes.ts): a workdir that is not a repo, or
169
+ * a repo with no commits yet (`HEAD` unresolvable — every file is untracked and the untracked
170
+ * pass still runs for the commit-less case). */
171
+ function isEmptyDiffAnswer(msg) {
172
+ // Case-insensitive on the repo check: `git log` says "fatal: not a git repository" but
173
+ // `git diff` says "warning: Not a git repository. Use --no-index …" — measured, not assumed.
174
+ const lower = msg.toLowerCase();
175
+ return (lower.includes('not a git repository') ||
176
+ msg.includes('does not have any commits') ||
177
+ msg.includes("ambiguous argument 'HEAD'") ||
178
+ msg.includes('unknown revision'));
179
+ }
180
+ /**
181
+ * The run's worktree diff against `base` (default HEAD) — staged + unstaged in one answer — with
182
+ * untracked files appended as `git diff --no-index /dev/null <file>` all-addition hunks (§3.3: a
183
+ * run's *created* files must diff as additions rather than vanish). `relPath`, when given, narrows
184
+ * both passes to that one file; it is always a single argv element after `--` (the open-path rule
185
+ * — no shell string is ever composed). The literal `/dev/null` is git's own cross-platform
186
+ * null-device spelling (git special-cases it, including on Windows).
187
+ *
188
+ * `base` (CREW-UX-1, DES-UX-001 §8.1): the literal `merge-base` diffs from the run branch's fork
189
+ * point off the default branch — committed run work becomes visible; a plain ref diffs from that
190
+ * ref, resolved inside this repo first (`resolveDiffBase` — the raw parameter never reaches
191
+ * `git diff`). Throws `InvalidDiffBaseError` / `UnresolvableDiffBaseError` for the route's 400s.
192
+ */
193
+ export async function worktreeDiff(workdir, relPath, base) {
194
+ const limit = relPath === undefined ? [] : ['--', relPath];
195
+ let out = '';
196
+ // Resolve the baseline BEFORE any diff pass: a bad `base` must 400 without partial output.
197
+ let baseRev = 'HEAD';
198
+ if (base !== undefined && base.length > 0) {
199
+ try {
200
+ baseRev = await resolveDiffBase(workdir, base);
201
+ }
202
+ catch (err) {
203
+ if (err.code === 'ENOENT')
204
+ throw err; // git missing — 500
205
+ const msg = err instanceof Error ? err.message : String(err);
206
+ // The route's standing tolerance: a non-repo workdir answers an empty diff for any
207
+ // WELL-FORMED base — a malformed base has already thrown InvalidDiffBaseError above,
208
+ // and that 400 wins over the tolerance (Copilot, #307).
209
+ if (msg.toLowerCase().includes('not a git repository'))
210
+ return { diff: '', truncated: false };
211
+ throw err;
212
+ }
213
+ }
214
+ // Tracked changes (staged + unstaged, plus committed-since-base when a base was resolved):
215
+ // diff the worktree against the baseline.
216
+ try {
217
+ const { stdout } = await execCapped('git', ['diff', '--no-color', '--no-ext-diff', baseRev, ...limit], { timeout: GIT_TIMEOUT_MS, cwd: workdir });
218
+ out = stdout;
219
+ }
220
+ catch (err) {
221
+ if (err.code === 'ENOENT')
222
+ throw err; // git missing — the route's 500
223
+ const msg = err instanceof Error ? err.message : String(err);
224
+ if (msg.toLowerCase().includes('not a git repository'))
225
+ return { diff: '', truncated: false };
226
+ if (!isEmptyDiffAnswer(msg))
227
+ throw err;
228
+ // No commits yet: tracked diff is vacuously empty; fall through to the untracked pass.
229
+ }
230
+ // Untracked files → all-addition hunks. `-z` (NUL separators, no quoting) + `-uall` (individual
231
+ // files, never a collapsed `?? dir/` entry that --no-index could not diff).
232
+ const { stdout: statusOut } = await execCapped('git', ['status', '--porcelain', '-z', '-uall', ...limit], { timeout: GIT_TIMEOUT_MS, cwd: workdir });
233
+ const untracked = statusOut
234
+ .split('\0')
235
+ .filter((entry) => entry.startsWith('?? '))
236
+ .map((entry) => entry.slice(3));
237
+ for (const file of untracked) {
238
+ // Cap is in BYTES; `out.length` counts UTF-16 code units. `>=`: exactly-at-cap is
239
+ // already done — spawning one more git only to discard its output is waste (Copilot, #305).
240
+ if (Buffer.byteLength(out, 'utf8') >= DIFF_OUTPUT_CAP_BYTES)
241
+ break;
242
+ try {
243
+ const { stdout } = await execCapped('git', ['diff', '--no-color', '--no-ext-diff', '--no-index', '--', '/dev/null', file], { timeout: GIT_TIMEOUT_MS, cwd: workdir });
244
+ out += stdout;
245
+ }
246
+ catch (err) {
247
+ // `--no-index` exits 1 WHEN THE FILES DIFFER — which is every hit here. The diff is still
248
+ // on stdout; only a stdout-less failure is a real error.
249
+ const stdout = err.stdout;
250
+ if (typeof stdout === 'string' && stdout.length > 0)
251
+ out += stdout;
252
+ else if (err.code === 'ENOENT')
253
+ throw err;
254
+ else
255
+ throw err;
256
+ }
257
+ }
258
+ // Byte-accurate cap (Copilot, #305): `slice` on the string counts UTF-16 code units, which
259
+ // under-enforces for non-ASCII diffs. Cut on the UTF-8 byte buffer, then back off any
260
+ // incomplete trailing multibyte sequence — decoding a torn tail yields U+FFFD, which
261
+ // re-encodes LARGER and would breach the cap by a byte.
262
+ const outBytes = Buffer.from(out, 'utf8');
263
+ if (outBytes.byteLength > DIFF_OUTPUT_CAP_BYTES) {
264
+ let end = DIFF_OUTPUT_CAP_BYTES;
265
+ while (end > 0 && (outBytes[end] & 0xc0) === 0x80)
266
+ end--; // land on a sequence boundary
267
+ return { diff: outBytes.subarray(0, end).toString('utf8'), truncated: true };
268
+ }
269
+ return { diff: out, truncated: false };
270
+ }
271
+ //# sourceMappingURL=run-files.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"run-files.js","sourceRoot":"","sources":["../../src/api/run-files.ts"],"names":[],"mappings":"AAAA,gFAAgF;AAChF,EAAE;AACF,iGAAiG;AACjG,kGAAkG;AAClG,8FAA8F;AAC9F,6FAA6F;AAC7F,+FAA+F;AAC/F,+FAA+F;AAC/F,iFAAiF;AAEjF,OAAO,EAAE,QAAQ,IAAI,GAAG,EAAE,MAAM,SAAS,CAAC;AAC1C,OAAO,EAAE,UAAU,EAAE,kBAAkB,EAAE,MAAM,iBAAiB,CAAC;AAEjE;qGACqG;AACrG,MAAM,CAAC,MAAM,sBAAsB,GAAG,GAAG,GAAG,IAAI,CAAC;AAEjD;iFACiF;AACjF,MAAM,CAAC,MAAM,kBAAkB,GAAG,CAAC,GAAG,IAAI,CAAC;AAE3C,uFAAuF;AACvF,MAAM,CAAC,MAAM,qBAAqB,GAAG,IAAI,GAAG,IAAI,CAAC;AAUjD;uFACuF;AACvF,MAAM,OAAO,oBAAqB,SAAQ,KAAK;IACxB;IAArB,YAAqB,IAAY;QAC/B,KAAK,CAAC,uBAAuB,IAAI,EAAE,CAAC,CAAC;QADlB,SAAI,GAAJ,IAAI,CAAQ;QAE/B,IAAI,C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AA8B;QACzF,OAAO,EAAE,IAAI,EAAE,QAAQ,CAAC,QAAQ,CAAC,CAAC,EAAE,GAAG,CAAC,CAAC,QAAQ,CAAC,MAAM,CAAC,EAAE,SAAS,EAAE,IAAI,EAAE,CAAC;IAC/E,CAAC;IACD,OAAO,EAAE,IAAI,EAAE,GAAG,EAAE,SAAS,EAAE,KAAK,EAAE,CAAC;AACzC,CAAC"}
@@ -71,6 +71,69 @@ export interface CreateServerOptions {
71
71
  editDir?: string;
72
72
  /** Seat roster override (JSON array); omit for the production council roster. */
73
73
  clisJson?: string;
74
+ /** Docs-root resolver override (tests); default = per-project `interactiveRoot` setting.
75
+ * Used ONLY as the demo-kind gate (CREW-UX-9) — demo docs' step feedback belongs to the
76
+ * demo seam. */
77
+ resolveDocsRoot?: (projectId: string | undefined) => string;
78
+ };
79
+ /**
80
+ * Opt-in governed answering of wicked-interactive DEMO docs (CREW-UX-9 — video generation's
81
+ * missing brain, the retired assist agent's Step 8). When enabled, a durable subscriber
82
+ * answers `wicked.interactive.doc.created` (kind:demo) with a governed `interactive-demo`
83
+ * run that authors `demo.spec.mjs`, installs it into the doc workspace, and ends in
84
+ * `wicked.interactive.demo.requested` — the model-free service then records the video
85
+ * (Playwright + ffmpeg) and lands the storyboard version itself. Step feedback on a demo doc
86
+ * (`feedback.processed`, manifest kind demo) is answered by RE-authoring the spec and
87
+ * re-emitting demo.requested (assist SKILL.md Step 8c). When absent (the default), demo docs
88
+ * keep their "Learning …" placeholder — the pre-CREW-UX-9 state.
89
+ */
90
+ interactiveDemoEvents?: {
91
+ enabled: boolean;
92
+ /** Bus db path; omit for wicked-bus's own default resolution (honors WICKED_BUS_DATA_DIR). */
93
+ dbPath?: string;
94
+ /** Poll cadence, ms (tests shorten it). */
95
+ pollIntervalMs?: number;
96
+ /** Heartbeat narration cadence, ms (default 15000). */
97
+ heartbeatMs?: number;
98
+ /** Durable replay-dedup ledger path (default ~/.wicked-crew/interactive-demo-ledger.json). */
99
+ ledgerPath?: string;
100
+ /** Where governed workers write specs (default ~/.wicked-crew/interactive-demos). */
101
+ demoDir?: string;
102
+ /** Seat roster override (JSON array); omit for the production council roster. */
103
+ clisJson?: string;
104
+ /** Docs-root resolver override (tests); default = per-project `interactiveRoot` setting. */
105
+ resolveDocsRoot?: (projectId: string | undefined) => string;
106
+ };
107
+ /**
108
+ * Opt-in governed answering of wicked-interactive's conversational ITERATION asks
109
+ * (CREW-UX-5, the doc thread's plain send). When enabled, a durable subscriber answers
110
+ * `wicked.interactive.chat.posted` (role:user, existing kind:source doc, not an in-flight
111
+ * doc, not a feedback-batch echo) with a governed `interactive-chat` run —
112
+ * understand-the-ask → revise — that ends in `wicked.interactive.draft.completed` (the
113
+ * service lands the revised full HTML as a generated version). Asks on a busy doc queue
114
+ * FIFO per doc. When absent (the default), the topic goes unanswered — the pre-CREW-UX-5
115
+ * state.
116
+ */
117
+ interactiveChatEvents?: {
118
+ enabled: boolean;
119
+ /** Bus db path; omit for wicked-bus's own default resolution (honors WICKED_BUS_DATA_DIR). */
120
+ dbPath?: string;
121
+ /** Poll cadence, ms (tests shorten it). */
122
+ pollIntervalMs?: number;
123
+ /** Heartbeat narration cadence, ms (default 15000). */
124
+ heartbeatMs?: number;
125
+ /** Durable replay-dedup ledger path (default ~/.wicked-crew/interactive-chat-ledger.json). */
126
+ ledgerPath?: string;
127
+ /** Where head snapshots land and workers write revisions (default ~/.wicked-crew/interactive-chats). */
128
+ chatDir?: string;
129
+ /** Seat roster override (JSON array); omit for the production council roster. */
130
+ clisJson?: string;
131
+ /** Queue-drain sweep cadence, ms (tests shorten it). */
132
+ queueSweepMs?: number;
133
+ /** Post-completion landing-gate timeout, ms (tests shorten it). */
134
+ landingGateMs?: number;
135
+ /** Docs-root resolver override (tests); default = per-project `interactiveRoot` setting. */
136
+ resolveDocsRoot?: (projectId: string | undefined) => string;
74
137
  };
75
138
  /**
76
139
  * The project bus seam (DES-PROJECT-001 §4/§5.2). DEFAULT-ON, unlike the opt-in seams
@@ -117,6 +180,22 @@ export interface CreateServerOptions {
117
180
  intervalMs?: number;
118
181
  timeoutMs?: number;
119
182
  };
183
+ /**
184
+ * The worker stall watchdog (crew#287): DETECTION ONLY. For every run whose engine status is
185
+ * `executing`, the daemon tracks the last CoreEvent observed on its own relay (any frame for
186
+ * that run, `unitOutputDelta` included); silence past `workerStallMinutes` (setting, default
187
+ * 15) broadcasts ONE synthetic `{ type: "workerStalled", session, ord?, quietForMs }` frame
188
+ * on /ws per quiet period and logs at warn. Any new event re-arms. The run is never killed
189
+ * or mutated — the operator decides. `enabled` defaults to ON in the daemon and OFF under a
190
+ * test runner (VITEST / NODE_ENV=test), the seat-health-probe posture.
191
+ */
192
+ stallWatchdog?: {
193
+ enabled?: boolean;
194
+ /** Sweep cadence, ms (default 30 s; tests shorten it). */
195
+ sweepIntervalMs?: number;
196
+ /** Threshold override, minutes — bypasses the settings read (tests). */
197
+ stallMinutes?: number;
198
+ };
120
199
  }
121
200
  export declare function createServer(adapter: CoreAdapter, options?: CreateServerOptions): Promise<ReturnType<typeof Fastify>>;
122
201
  export interface StartedServer {
@@ -1 +1 @@
1
- {"version":3,"file":"server.d.ts","sourceRoot":"","sources":["../../src/api/server.ts"],"names":[],"mappings":"AAAA,OAAO,OAAO,MAAM,SAAS,CAAC;AAS9B,OAAO,EAAkC,KAAK,WAAW,EAAE,MAAM,WAAW,CAAC;AAW7E,OAAO,EAAE,WAAW,EAAE,MAAM,oBAAoB,CAAC;AAUjD;;;;;;GAMG;AACH,wBAAgB,iBAAiB,IAAI,MAAM,CAE1C;AAED,MAAM,WAAW,mBAAmB;IAClC,+EAA+E;IAC/E,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB;;;;;OAKG;IACH,YAAY,CAAC,EAAE;QACb,OAAO,EAAE,OAAO,CAAC;QACjB,iEAAiE;QACjE,MAAM,CAAC,EAAE,MAAM,CAAC;QAChB,2CAA2C;QAC3C,cAAc,CAAC,EAAE,MAAM,CAAC;KACzB,CAAC;IACF;;;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