@sideboard-ai/core 0.1.342 → 0.1.344

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 (27) hide show
  1. package/dist/{agents-LNZ465IM.js → agents-7CHZO3K3.js} +2 -2
  2. package/dist/{agents-7DCNOMFP.js → agents-FI62PUSY.js} +2 -2
  3. package/dist/{chunk-5HUR77ZH.js → chunk-5IMXA563.js} +140 -72
  4. package/dist/{chunk-LDJT3TLN.js → chunk-6N4W2MJ2.js} +2 -2
  5. package/dist/{chunk-DZF25KTX.js → chunk-AX7SUDTC.js} +147 -77
  6. package/dist/{chunk-DEQLDEYR.js → chunk-BD7KUYJA.js} +2 -2
  7. package/dist/{chunk-2BLJ726H.js → chunk-HRHF6N6S.js} +1 -0
  8. package/dist/{chunk-5BFEHSHO.js → chunk-J3BQHHDZ.js} +1 -0
  9. package/dist/{chunk-S3DTEGMK.js → chunk-TW63CYUA.js} +2 -2
  10. package/dist/{chunk-NGIGRAZB.js → chunk-YNKVGJE5.js} +2 -2
  11. package/dist/{conductor-4SWJM5FS.js → conductor-3A2TNWUW.js} +2 -2
  12. package/dist/{conductor-Q433HU77.js → conductor-H56XPSX4.js} +2 -2
  13. package/dist/{coordinator-prompt-5QHWCO7V.js → coordinator-prompt-2YQGOA6Y.js} +1 -1
  14. package/dist/{coordinator-prompt-Z7PPP45X.js → coordinator-prompt-7QALNDIV.js} +1 -1
  15. package/dist/{global-workspace-DL4K4K7O.js → global-workspace-HM2RKBCT.js} +1 -1
  16. package/dist/{global-workspace-VDCZMFCZ.js → global-workspace-YRPM6JLZ.js} +1 -1
  17. package/dist/index.cjs +142 -68
  18. package/dist/index.d.cts +6 -2
  19. package/dist/index.d.ts +6 -2
  20. package/dist/index.js +11 -7
  21. package/dist/mcp/run-stdio.cjs +138 -68
  22. package/dist/mcp/run-stdio.js +4 -4
  23. package/dist/{orchestrator-HIWWPWL5.js → orchestrator-DGH2UMPW.js} +4 -4
  24. package/dist/{orchestrator-BPCM4OP3.js → orchestrator-OWO6LQ5U.js} +4 -4
  25. package/dist/{workspaces-MX4W4SSB.js → workspaces-SSYKQUAU.js} +1 -1
  26. package/dist/{workspaces-EIIHHH4S.js → workspaces-V6IIBSKA.js} +1 -1
  27. package/package.json +1 -1
@@ -21,7 +21,7 @@ import {
21
21
  parseSessionQuotaResetAt,
22
22
  planModeTurnInstruction,
23
23
  resolveQuotaFallbackAgent
24
- } from "./chunk-LDJT3TLN.js";
24
+ } from "./chunk-6N4W2MJ2.js";
25
25
  import {
26
26
  applyWorktreePkgCacheEnv,
27
27
  buildBrightsySessionSeed,
@@ -56,7 +56,7 @@ import {
56
56
  worktreeDevProcessKey,
57
57
  worktreeRunProcessKey,
58
58
  worktreeSetupProcessKey
59
- } from "./chunk-NGIGRAZB.js";
59
+ } from "./chunk-YNKVGJE5.js";
60
60
  import {
61
61
  applyAgentEvent,
62
62
  clipAgentEventForPaint,
@@ -101,7 +101,7 @@ import {
101
101
  stageAbsolutePathsAsAttachments,
102
102
  stageBuffersAsAttachments,
103
103
  syncWorkspacesFromThreads
104
- } from "./chunk-2BLJ726H.js";
104
+ } from "./chunk-HRHF6N6S.js";
105
105
  import {
106
106
  addPrStackLayer,
107
107
  allocateTeamSlug,
@@ -527,9 +527,9 @@ async function spawnAgentTurn(thread, input, onEvent) {
527
527
  `Cannot spawn ${thread.agent}: thread ${thread.id} has no worktreePath`
528
528
  );
529
529
  }
530
- const { isGlobalThread: isGlobalThread2 } = await import("./global-workspace-VDCZMFCZ.js");
530
+ const { isGlobalThread: isGlobalThread2 } = await import("./global-workspace-YRPM6JLZ.js");
531
531
  if (isGlobalThread2(thread)) {
532
- const { ensureGlobalCoordinatorCwd: ensureGlobalCoordinatorCwd2 } = await import("./coordinator-prompt-5QHWCO7V.js");
532
+ const { ensureGlobalCoordinatorCwd: ensureGlobalCoordinatorCwd2 } = await import("./coordinator-prompt-2YQGOA6Y.js");
533
533
  ensureGlobalCoordinatorCwd2(
534
534
  isOrchestratorThread(thread) ? { orchestratorThreadId: thread.id } : void 0
535
535
  );
@@ -3469,7 +3469,7 @@ async function createThread(input, _onSetupLine) {
3469
3469
  return readThread(thread.id) ?? thread;
3470
3470
  }
3471
3471
  async function listLinearIssues(agent, repoPath) {
3472
- const { getAdapter: getAdapter2 } = await import("./agents-7DCNOMFP.js");
3472
+ const { getAdapter: getAdapter2 } = await import("./agents-FI62PUSY.js");
3473
3473
  await requireAgent(agent, { requireLinear: true });
3474
3474
  const adapter = getAdapter2(agent);
3475
3475
  if (!adapter.listLinearIssues) {
@@ -4252,7 +4252,7 @@ async function adoptThread(input) {
4252
4252
  messages: input.messages ?? []
4253
4253
  });
4254
4254
  writeThread(thread);
4255
- const { addWorkspace: addWorkspace2 } = await import("./workspaces-MX4W4SSB.js");
4255
+ const { addWorkspace: addWorkspace2 } = await import("./workspaces-SSYKQUAU.js");
4256
4256
  await addWorkspace2(repoPath);
4257
4257
  const { ensureWorktreeSideboardIgnored } = await import("./worktree-exclude-YQBN43QD.js");
4258
4258
  await ensureWorktreeSideboardIgnored(input.worktreePath);
@@ -6253,49 +6253,6 @@ function expandComposerPrompt(worktreePath, prompt, opts) {
6253
6253
  };
6254
6254
  }
6255
6255
 
6256
- // src/composer/agent-has-replied.ts
6257
- function joinSteerPrompt(base, addition) {
6258
- const next = addition.trim();
6259
- if (!next) return base;
6260
- const head = base.replace(/\s+$/, "");
6261
- if (!head) return next;
6262
- return `${head}
6263
- ${next}`;
6264
- }
6265
- function messagesWithRewrittenUserPrompt(messages, from, to) {
6266
- if (from === to) return null;
6267
- const next = messages.slice();
6268
- for (let i = next.length - 1; i >= 0; i--) {
6269
- const message = next[i];
6270
- if (!message || message.origin === "continue" || message.role === "summary") continue;
6271
- if (message.role !== "user") continue;
6272
- if (message.text !== from) return null;
6273
- next[i] = { ...message, text: to };
6274
- return next;
6275
- }
6276
- return null;
6277
- }
6278
- function trailingUnansweredUserText(messages) {
6279
- for (let i = messages.length - 1; i >= 0; i--) {
6280
- const message = messages[i];
6281
- if (!message || message.origin === "continue" || message.role === "summary") continue;
6282
- if (message.role === "agent") {
6283
- const text3 = (message.text ?? "").trim();
6284
- if (text3 || (message.parts?.length ?? 0) > 0) return null;
6285
- continue;
6286
- }
6287
- if (message.role === "user") return message.text;
6288
- }
6289
- return null;
6290
- }
6291
- function livePartsShowAgentReply(parts) {
6292
- for (const part of parts) {
6293
- if (part.type === "tool") return true;
6294
- if ((part.type === "text" || part.type === "thinking") && part.text.trim()) return true;
6295
- }
6296
- return false;
6297
- }
6298
-
6299
6256
  // src/composer/consume-attachments.ts
6300
6257
  function consumeComposerAttachments(thread) {
6301
6258
  return {
@@ -6306,6 +6263,22 @@ function consumeComposerAttachments(thread) {
6306
6263
  function takePendingTurnAttachments(thread) {
6307
6264
  return [...thread.pendingTurnAttachments ?? []];
6308
6265
  }
6266
+ function mergeTurnAttachments(base, extra) {
6267
+ const next = [];
6268
+ const seen = /* @__PURE__ */ new Set();
6269
+ for (const att of [...base ?? [], ...extra ?? []]) {
6270
+ if (seen.has(att.id)) continue;
6271
+ seen.add(att.id);
6272
+ next.push(att);
6273
+ }
6274
+ return next;
6275
+ }
6276
+ function sameTurnAttachments(a, b) {
6277
+ const left = a ?? [];
6278
+ const right = b ?? [];
6279
+ if (left.length !== right.length) return false;
6280
+ return left.every((att, i) => att.id === right[i]?.id);
6281
+ }
6309
6282
  function alignQueueAttachments(queueLength, existing) {
6310
6283
  const next = (existing ?? []).slice(0, queueLength).map((slot) => [...slot ?? []]);
6311
6284
  while (next.length < queueLength) next.push([]);
@@ -6348,15 +6321,95 @@ function shiftQueuedItem(queue, queueAttachments) {
6348
6321
  };
6349
6322
  }
6350
6323
 
6324
+ // src/composer/agent-has-replied.ts
6325
+ function joinSteerPrompt(base, addition) {
6326
+ const next = addition.trim();
6327
+ if (!next) return base;
6328
+ const head = base.replace(/\s+$/, "");
6329
+ if (!head) return next;
6330
+ return `${head}
6331
+ ${next}`;
6332
+ }
6333
+ function messagesWithRewrittenUserPrompt(messages, from, to, attachments) {
6334
+ const extra = attachments ?? [];
6335
+ if (from === to && extra.length === 0) return null;
6336
+ const next = messages.slice();
6337
+ for (let i = next.length - 1; i >= 0; i--) {
6338
+ const message = next[i];
6339
+ if (!message || message.origin === "continue" || message.role === "summary") continue;
6340
+ if (message.role !== "user") continue;
6341
+ if (message.text !== from) return null;
6342
+ const merged = mergeTurnAttachments(message.attachments, extra);
6343
+ if (from === to && merged.length === (message.attachments?.length ?? 0)) return null;
6344
+ next[i] = {
6345
+ ...message,
6346
+ text: to,
6347
+ ...merged.length > 0 ? { attachments: merged } : {}
6348
+ };
6349
+ return next;
6350
+ }
6351
+ return null;
6352
+ }
6353
+ function trailingUnansweredUserText(messages) {
6354
+ for (let i = messages.length - 1; i >= 0; i--) {
6355
+ const message = messages[i];
6356
+ if (!message || message.origin === "continue" || message.role === "summary") continue;
6357
+ if (message.role === "agent") {
6358
+ const text3 = (message.text ?? "").trim();
6359
+ if (text3 || (message.parts?.length ?? 0) > 0) return null;
6360
+ continue;
6361
+ }
6362
+ if (message.role === "user") return message.text;
6363
+ }
6364
+ return null;
6365
+ }
6366
+ function livePartsShowAgentReply(parts) {
6367
+ for (const part of parts) {
6368
+ if (part.type === "tool") return true;
6369
+ if ((part.type === "text" || part.type === "thinking") && part.text.trim()) return true;
6370
+ }
6371
+ return false;
6372
+ }
6373
+
6351
6374
  // src/orchestrator/enqueue-thread-send.ts
6352
6375
  function resolveSendFollowUp(thread, requested) {
6353
6376
  if (requested === "steer" || requested === "queue") return requested;
6354
6377
  return isOrchestratorThread(thread) ? followUpBehavior() : "queue";
6355
6378
  }
6356
- function rewriteTrailingUserPrompt(threadId, from, to) {
6379
+ function beginOpenSteerDraft(text3) {
6380
+ return { text: text3, spawned: false, attachments: [] };
6381
+ }
6382
+ function seedOpenSteerAttachments(draft, sent) {
6383
+ if (!draft) return [...sent ?? []];
6384
+ draft.attachments = mergeTurnAttachments(sent, draft.attachments);
6385
+ return draft.attachments ?? [];
6386
+ }
6387
+ function openSteerTurnAttachments(draft, fallback, autoContinue) {
6388
+ if (autoContinue) return [];
6389
+ return [...draft?.attachments ?? fallback];
6390
+ }
6391
+ function promptAfterJoinedSteer(input) {
6392
+ if (input.draft) input.draft.spawned = true;
6393
+ return promptForJoinedSteer({
6394
+ threadId: input.threadId,
6395
+ promptText: input.promptText,
6396
+ latestPrompt: input.draft?.text ?? input.promptText,
6397
+ agentPrompt: input.agentPrompt,
6398
+ expandedPrompt: input.expandedPrompt,
6399
+ worktreePath: input.worktreePath,
6400
+ attachments: input.expandedAttachments,
6401
+ latestAttachments: openSteerTurnAttachments(
6402
+ input.draft,
6403
+ input.expandedAttachments,
6404
+ input.autoContinue
6405
+ ),
6406
+ gitForge: input.gitForge
6407
+ });
6408
+ }
6409
+ function rewriteTrailingUserPrompt(threadId, from, to, attachments) {
6357
6410
  const thread = readThread(threadId);
6358
6411
  if (!thread) return;
6359
- const messages = messagesWithRewrittenUserPrompt(thread.messages, from, to);
6412
+ const messages = messagesWithRewrittenUserPrompt(thread.messages, from, to, attachments);
6360
6413
  if (!messages) return;
6361
6414
  updateThread(threadId, { messages });
6362
6415
  }
@@ -6371,12 +6424,18 @@ function reuseJoinedUserBubble(reused, threadId, messages, promptText) {
6371
6424
  return false;
6372
6425
  }
6373
6426
  function promptForJoinedSteer(input) {
6374
- if (input.latestPrompt === input.promptText) return input.agentPrompt;
6375
- rewriteTrailingUserPrompt(input.threadId, input.promptText, input.latestPrompt);
6427
+ const latestAttachments = input.latestAttachments ?? input.attachments;
6428
+ const textSame = input.latestPrompt === input.promptText;
6429
+ if (textSame && sameTurnAttachments(input.attachments, latestAttachments)) {
6430
+ return input.agentPrompt;
6431
+ }
6432
+ if (!textSame) {
6433
+ rewriteTrailingUserPrompt(input.threadId, input.promptText, input.latestPrompt);
6434
+ }
6376
6435
  const { agentPrompt: expandedLatest } = expandComposerPrompt(
6377
6436
  input.worktreePath,
6378
6437
  expandCanonicalGitRequest(input.latestPrompt, { forge: input.gitForge }),
6379
- { attachments: input.attachments }
6438
+ { attachments: latestAttachments }
6380
6439
  );
6381
6440
  return input.expandedPrompt && input.agentPrompt.endsWith(input.expandedPrompt) ? input.agentPrompt.slice(0, -input.expandedPrompt.length) + expandedLatest : `${input.agentPrompt}
6382
6441
 
@@ -6412,7 +6471,13 @@ async function enqueueThreadSend(host, threadRef, prompt, opts) {
6412
6471
  const combined = joinSteerPrompt(unanswered, prompt);
6413
6472
  if (draft && !draft.spawned) {
6414
6473
  draft.text = combined;
6415
- rewriteTrailingUserPrompt(current.id, unanswered, combined);
6474
+ if (consumed.consumed.length > 0) {
6475
+ draft.attachments = mergeTurnAttachments(draft.attachments, consumed.consumed);
6476
+ }
6477
+ rewriteTrailingUserPrompt(current.id, unanswered, combined, consumed.consumed);
6478
+ if (explicit === void 0 && consumed.consumed.length > 0) {
6479
+ updateThread(current.id, { attachments: consumed.attachments });
6480
+ }
6416
6481
  } else {
6417
6482
  const queue = current.queue.slice();
6418
6483
  queue[0] = combined;
@@ -6434,8 +6499,13 @@ async function enqueueThreadSend(host, threadRef, prompt, opts) {
6434
6499
  }
6435
6500
  const promptToQueue = unanswered != null ? joinSteerPrompt(unanswered, prompt) : prompt;
6436
6501
  if (unanswered != null) {
6437
- if (draft) draft.text = promptToQueue;
6438
- rewriteTrailingUserPrompt(current.id, unanswered, promptToQueue);
6502
+ if (draft) {
6503
+ draft.text = promptToQueue;
6504
+ if (consumed.consumed.length > 0) {
6505
+ draft.attachments = mergeTurnAttachments(draft.attachments, consumed.consumed);
6506
+ }
6507
+ }
6508
+ rewriteTrailingUserPrompt(current.id, unanswered, promptToQueue, consumed.consumed);
6439
6509
  host.reusedUserPrompt.add(current.id);
6440
6510
  }
6441
6511
  const queued = appendQueuedItem(
@@ -6807,7 +6877,7 @@ function formatProcessGuideDirective(opts) {
6807
6877
  hasInstallSkill ? "- After merge-from-main / lockfile change, or a hung `pnpm install`: follow `.claude/skills/worktree-install/SKILL.md` (`/worktree-install`). Use the worktree-local store Sideboard already set; do not share `~/.pnpm-store` across concurrent worktrees." : null,
6808
6878
  "- If this same shape of work will happen again, write `.claude/skills/<kebab-name>/SKILL.md` in this worktree (Claude Code project skill; Sideboard `/name`, Claude Code, and `attach` all load it). Not under `.sideboard/skills/`. Point Codex/OpenCode at it from `AGENTS.md`.",
6809
6879
  hasReviewSkill ? "- Merge-readiness notes go in `.claude/skills/review/SKILL.md` (edit it; do not create another review skill)." : "- Merge-readiness notes go in `.context/review.md` (copied from `.sideboard/review.md` when that file exists). Do not create a review skill.",
6810
- "- Skip a guide for a one-off. If a matching skill exists, follow it. Same miss twice \u2192 edit the skill, do not patch around it."
6880
+ !!worktree && existsSync12(join13(worktree, ".claude/skills/skill-improver/SKILL.md")) ? "- Skip a guide for a one-off. If a matching skill exists, follow it. A miss that will recur (you made it twice, or a person told you the rule) \u2192 follow `.claude/skills/skill-improver/SKILL.md` (`/skill-improver`): one sentence in the skill that owns it, in this change. Do not patch around it." : "- Skip a guide for a one-off. If a matching skill exists, follow it. Same miss twice \u2192 edit the skill, do not patch around it."
6811
6881
  ].filter(Boolean).join("\n");
6812
6882
  }
6813
6883
  function formatLongRunningDirective(opts) {
@@ -7807,11 +7877,11 @@ function realDeps() {
7807
7877
  parentIdForThread,
7808
7878
  designatedId: designatedOrchestratorId,
7809
7879
  send: async (threadId, prompt) => {
7810
- const { getOrchestrator: getOrchestrator2 } = await import("./orchestrator-HIWWPWL5.js");
7880
+ const { getOrchestrator: getOrchestrator2 } = await import("./orchestrator-DGH2UMPW.js");
7811
7881
  await getOrchestrator2().send(threadId, prompt, { followUp: "queue" });
7812
7882
  },
7813
7883
  startOrchestration: async (prompt) => {
7814
- const { startOrchestration: startOrchestration2 } = await import("./orchestrator-HIWWPWL5.js");
7884
+ const { startOrchestration: startOrchestration2 } = await import("./orchestrator-DGH2UMPW.js");
7815
7885
  const defaults = resolveOrchestratorDefaults();
7816
7886
  await startOrchestration2({
7817
7887
  goal: prompt,
@@ -7838,7 +7908,7 @@ function formatScheduledPrompt(name, prompt) {
7838
7908
  ${prompt}`;
7839
7909
  }
7840
7910
  async function defaultDeps() {
7841
- const { getOrchestrator: getOrchestrator2, startOrchestration: startOrchestration2 } = await import("./orchestrator-HIWWPWL5.js");
7911
+ const { getOrchestrator: getOrchestrator2, startOrchestration: startOrchestration2 } = await import("./orchestrator-DGH2UMPW.js");
7842
7912
  const orch = getOrchestrator2();
7843
7913
  return {
7844
7914
  findThread: (id) => findThreadByRef(id),
@@ -8817,10 +8887,7 @@ var Orchestrator = class {
8817
8887
  this.emit({ type: "status_changed", threadId, status: "running" });
8818
8888
  this.emit({ type: "turn_started", threadId, prompt });
8819
8889
  try {
8820
- this.openSteerPrompt.set(threadId, {
8821
- text: typeof prompt === "string" ? prompt : "",
8822
- spawned: false
8823
- });
8890
+ this.openSteerPrompt.set(threadId, beginOpenSteerDraft(typeof prompt === "string" ? prompt : ""));
8824
8891
  try {
8825
8892
  const baseline = await captureTurnBaseline(thread.worktreePath);
8826
8893
  if (baseline) this.turnBaselines.set(threadId, baseline);
@@ -8850,13 +8917,14 @@ var Orchestrator = class {
8850
8917
  const autoContinue = isJobContinuePrompt(promptText) || promptText.startsWith("The previous agent process ended before it finished.");
8851
8918
  const parked = takePendingTurnAttachments(thread);
8852
8919
  const sentAttachments = !autoContinue && parked.length > 0 ? parked : void 0;
8920
+ const turnAttachments = seedOpenSteerAttachments(this.openSteerPrompt.get(threadId), sentAttachments);
8853
8921
  if (!autoContinue) clearAgentBlock(threadId);
8854
8922
  const shown = this.requireThread(threadId).messages;
8855
8923
  if (!reuseJoinedUserBubble(this.reusedUserPrompt, threadId, shown, promptText)) {
8856
8924
  appendMessage(threadId, {
8857
8925
  role: "user",
8858
8926
  text: promptText,
8859
- ...sentAttachments ? { attachments: sentAttachments } : {},
8927
+ ...turnAttachments.length > 0 ? { attachments: turnAttachments } : {},
8860
8928
  ...autoContinue ? { origin: "continue" } : {},
8861
8929
  ts: (/* @__PURE__ */ new Date()).toISOString()
8862
8930
  });
@@ -8886,11 +8954,12 @@ var Orchestrator = class {
8886
8954
  thread = this.requireThread(threadId);
8887
8955
  const turnOrigin = thread.worktreePath?.trim() ? await resolveOriginRemote(thread.worktreePath).catch(() => null) : null;
8888
8956
  const gitPrompt = expandCanonicalGitRequest(promptText, { forge: turnOrigin?.forge });
8957
+ const expandedAttachments = openSteerTurnAttachments(this.openSteerPrompt.get(threadId), turnAttachments, autoContinue);
8889
8958
  const { agentPrompt: expandedPrompt } = expandComposerPrompt(
8890
8959
  thread.worktreePath,
8891
8960
  gitPrompt,
8892
8961
  {
8893
- attachments: autoContinue ? [] : sentAttachments ?? []
8962
+ attachments: expandedAttachments
8894
8963
  }
8895
8964
  );
8896
8965
  const slackInbound = /^(Slack DM|Slack @mention)(?:\n|$)/.test(
@@ -9058,16 +9127,15 @@ ${formatEnvReminder(projectNameForRepoPath(thread.repoPath || thread.worktreePat
9058
9127
  ].filter(Boolean).join("\n\n---\n\n");
9059
9128
  const stderrTail = [];
9060
9129
  traceTurn("runTurn.beforeSpawn", { threadId, agent: fresh.agent });
9061
- const steerDraft = this.openSteerPrompt.get(threadId);
9062
- if (steerDraft) steerDraft.spawned = true;
9063
- const promptForAgent = promptForJoinedSteer({
9130
+ const promptForAgent = promptAfterJoinedSteer({
9131
+ draft: this.openSteerPrompt.get(threadId),
9132
+ autoContinue,
9133
+ expandedAttachments,
9064
9134
  threadId,
9065
9135
  promptText,
9066
- latestPrompt: steerDraft?.text ?? promptText,
9067
9136
  agentPrompt,
9068
9137
  expandedPrompt,
9069
9138
  worktreePath: fresh.worktreePath,
9070
- attachments: autoContinue ? [] : sentAttachments ?? [],
9071
9139
  gitForge: turnOrigin?.forge
9072
9140
  });
9073
9141
  const handle = await spawnAgentTurn(
@@ -10935,18 +11003,20 @@ export {
10935
11003
  discoverSkills,
10936
11004
  readSkillBody,
10937
11005
  expandComposerPrompt,
10938
- joinSteerPrompt,
10939
- messagesWithRewrittenUserPrompt,
10940
- trailingUnansweredUserText,
10941
- livePartsShowAgentReply,
10942
11006
  consumeComposerAttachments,
10943
11007
  takePendingTurnAttachments,
11008
+ mergeTurnAttachments,
11009
+ sameTurnAttachments,
10944
11010
  alignQueueAttachments,
10945
11011
  appendQueuedItem,
10946
11012
  prependQueuedItem,
10947
11013
  removeQueuedItem,
10948
11014
  moveQueuedItemToFront,
10949
11015
  shiftQueuedItem,
11016
+ joinSteerPrompt,
11017
+ messagesWithRewrittenUserPrompt,
11018
+ trailingUnansweredUserText,
11019
+ livePartsShowAgentReply,
10950
11020
  resolveSendFollowUp,
10951
11021
  formatCursorGitDirective,
10952
11022
  formatEntireGitDirective,
@@ -11,7 +11,7 @@ import {
11
11
  isGlobalThread,
12
12
  isOrchestratorThread,
13
13
  isSlackCoordinatorThread
14
- } from "./chunk-5BFEHSHO.js";
14
+ } from "./chunk-J3BQHHDZ.js";
15
15
  import {
16
16
  mergeAgentGitAuthEnv,
17
17
  resolveAgentGitAuthEnv
@@ -1737,7 +1737,7 @@ var PORT_RANGE_SIZE = 10;
1737
1737
  var RECLAIM_RETRY_DELAY_MS = 40;
1738
1738
  var RECLAIM_TRIES = 8;
1739
1739
  async function killReclaimable(ports, worktreePath, signal) {
1740
- const { killListenersOnPorts: killListenersOnPorts2, killStaleWorktreeListeners: killStaleWorktreeListeners2 } = await import("./conductor-4SWJM5FS.js");
1740
+ const { killListenersOnPorts: killListenersOnPorts2, killStaleWorktreeListeners: killStaleWorktreeListeners2 } = await import("./conductor-3A2TNWUW.js");
1741
1741
  if (worktreePath) killStaleWorktreeListeners2(ports, worktreePath, signal);
1742
1742
  else killListenersOnPorts2(ports);
1743
1743
  }
@@ -437,6 +437,7 @@ var COORDINATOR_TOOL_PLAYBOOK = [
437
437
  "- Recurring multi-item / fan-out: if the child worktree has `.claude/skills/graph-engineering/SKILL.md`, tell the worker to follow it (`/graph-engineering`). Judge first; state on disk; grow the rulebook; do not patch three threads.",
438
438
  "- Recurring shapes: have the worktree agent write `.claude/skills/<kebab-name>/SKILL.md` (commit it) so later threads and native Claude Code / attach see it. Merge-review sentences go in `.claude/skills/review/SKILL.md` when that skill already exists; otherwise `.context/review.md` (do not create a review skill). Do not use `.sideboard/skills/` (that folder only). Codex/OpenCode: one line in AGENTS.md pointing at that file.",
439
439
  "- One-offs: no guide. Same miss across threads: edit the existing skill or `.context/review.md`, then rerun the batch \u2014 do not patch three threads.",
440
+ "- A miss that will recur (the worker made it twice, or a person told them the rule): if the worktree has `.claude/skills/skill-improver/SKILL.md`, tell the worker to follow it (`/skill-improver`) in that turn \u2014 one sentence in the skill that owns it, in the same change. The worker who heard it writes it down; no Sideboard tool hands that chat to a later run.",
440
441
  "Human-only (do not attempt): ready-for-review land (confirm_land), purge_chat.",
441
442
  "Chat links in replies: when mentioning a chat/thread for the user, include a markdown link `[Title](sideboard://chat/<id>)` using the full id (or the link field from create_workspace / list_chats). Sideboard renders these as clickable opens.",
442
443
  "Bash / Read / etc: allowed for (1) inspecting target worktrees / registered repo paths from MCP, and (2) greenfield setup under ~/sideboard/repos (git clone, gh repo create, git init+remote). Never git init/clone *inside* this synthetic home cwd \u2014 emptiness here is expected, not a bug."
@@ -392,6 +392,7 @@ var COORDINATOR_TOOL_PLAYBOOK = [
392
392
  "- Recurring multi-item / fan-out: if the child worktree has `.claude/skills/graph-engineering/SKILL.md`, tell the worker to follow it (`/graph-engineering`). Judge first; state on disk; grow the rulebook; do not patch three threads.",
393
393
  "- Recurring shapes: have the worktree agent write `.claude/skills/<kebab-name>/SKILL.md` (commit it) so later threads and native Claude Code / attach see it. Merge-review sentences go in `.claude/skills/review/SKILL.md` when that skill already exists; otherwise `.context/review.md` (do not create a review skill). Do not use `.sideboard/skills/` (that folder only). Codex/OpenCode: one line in AGENTS.md pointing at that file.",
394
394
  "- One-offs: no guide. Same miss across threads: edit the existing skill or `.context/review.md`, then rerun the batch \u2014 do not patch three threads.",
395
+ "- A miss that will recur (the worker made it twice, or a person told them the rule): if the worktree has `.claude/skills/skill-improver/SKILL.md`, tell the worker to follow it (`/skill-improver`) in that turn \u2014 one sentence in the skill that owns it, in the same change. The worker who heard it writes it down; no Sideboard tool hands that chat to a later run.",
395
396
  "Human-only (do not attempt): ready-for-review land (confirm_land), purge_chat.",
396
397
  "Chat links in replies: when mentioning a chat/thread for the user, include a markdown link `[Title](sideboard://chat/<id>)` using the full id (or the link field from create_workspace / list_chats). Sideboard renders these as clickable opens.",
397
398
  "Bash / Read / etc: allowed for (1) inspecting target worktrees / registered repo paths from MCP, and (2) greenfield setup under ~/sideboard/repos (git clone, gh repo create, git init+remote). Never git init/clone *inside* this synthetic home cwd \u2014 emptiness here is expected, not a bug."
@@ -12,7 +12,7 @@ import {
12
12
  } from "./chunk-ORO4ENZR.js";
13
13
  import {
14
14
  isOrchestratorThread
15
- } from "./chunk-5BFEHSHO.js";
15
+ } from "./chunk-J3BQHHDZ.js";
16
16
  import {
17
17
  codexUnattendedGitConfigArgs,
18
18
  mergeAgentGitAuthEnv,
@@ -2978,7 +2978,7 @@ var claudeAdapter = {
2978
2978
  );
2979
2979
  }
2980
2980
  const mode = permissionMode(thread);
2981
- const { isOrchestratorThread: isOrchestratorThread2 } = await import("./global-workspace-DL4K4K7O.js");
2981
+ const { isOrchestratorThread: isOrchestratorThread2 } = await import("./global-workspace-HM2RKBCT.js");
2982
2982
  const isOrchestrator = isOrchestratorThread2(thread);
2983
2983
  const rpc = worktreeAgentRpc(isOrchestrator);
2984
2984
  const injectedServers = await buildInjectedMcpServers({
@@ -8,7 +8,7 @@ import {
8
8
  isGlobalThread,
9
9
  isOrchestratorThread,
10
10
  isSlackCoordinatorThread
11
- } from "./chunk-2BLJ726H.js";
11
+ } from "./chunk-HRHF6N6S.js";
12
12
  import {
13
13
  mergeAgentGitAuthEnv,
14
14
  resolveAgentGitAuthEnv
@@ -1705,7 +1705,7 @@ var PORT_RANGE_SIZE = 10;
1705
1705
  var RECLAIM_RETRY_DELAY_MS = 40;
1706
1706
  var RECLAIM_TRIES = 8;
1707
1707
  async function killReclaimable(ports, worktreePath, signal) {
1708
- const { killListenersOnPorts: killListenersOnPorts2, killStaleWorktreeListeners: killStaleWorktreeListeners2 } = await import("./conductor-Q433HU77.js");
1708
+ const { killListenersOnPorts: killListenersOnPorts2, killStaleWorktreeListeners: killStaleWorktreeListeners2 } = await import("./conductor-H56XPSX4.js");
1709
1709
  if (worktreePath) killStaleWorktreeListeners2(ports, worktreePath, signal);
1710
1710
  else killListenersOnPorts2(ports);
1711
1711
  }
@@ -34,9 +34,9 @@ import {
34
34
  tryReservePort,
35
35
  tryReservePorts,
36
36
  worktreeRunPortsPath
37
- } from "./chunk-DEQLDEYR.js";
37
+ } from "./chunk-BD7KUYJA.js";
38
38
  import "./chunk-ORO4ENZR.js";
39
- import "./chunk-5BFEHSHO.js";
39
+ import "./chunk-J3BQHHDZ.js";
40
40
  import "./chunk-RTZO2YJC.js";
41
41
  import "./chunk-N2WW62LF.js";
42
42
  import "./chunk-GK7H3SY7.js";
@@ -32,9 +32,9 @@ import {
32
32
  tryReservePort,
33
33
  tryReservePorts,
34
34
  worktreeRunPortsPath
35
- } from "./chunk-NGIGRAZB.js";
35
+ } from "./chunk-YNKVGJE5.js";
36
36
  import "./chunk-BIM24I3O.js";
37
- import "./chunk-2BLJ726H.js";
37
+ import "./chunk-HRHF6N6S.js";
38
38
  import "./chunk-G3UV3GXJ.js";
39
39
  import "./chunk-JX3OWNOT.js";
40
40
  import "./chunk-BMRJNRQK.js";
@@ -7,7 +7,7 @@ import {
7
7
  enrichWorkspacesWithGithub,
8
8
  ensureGlobalCoordinatorCwd,
9
9
  formatWorkspaceInventory
10
- } from "./chunk-2BLJ726H.js";
10
+ } from "./chunk-HRHF6N6S.js";
11
11
  import "./chunk-G3UV3GXJ.js";
12
12
  import "./chunk-JX3OWNOT.js";
13
13
  import "./chunk-BMRJNRQK.js";
@@ -9,7 +9,7 @@ import {
9
9
  enrichWorkspacesWithGithub,
10
10
  ensureGlobalCoordinatorCwd,
11
11
  formatWorkspaceInventory
12
- } from "./chunk-5BFEHSHO.js";
12
+ } from "./chunk-J3BQHHDZ.js";
13
13
  import "./chunk-RTZO2YJC.js";
14
14
  import "./chunk-N2WW62LF.js";
15
15
  import "./chunk-GK7H3SY7.js";
@@ -20,7 +20,7 @@ import {
20
20
  remoteCoordinatorSourceRef,
21
21
  slackCoordinatorSourceRef,
22
22
  takenTeamSlugsForOrchestration
23
- } from "./chunk-5BFEHSHO.js";
23
+ } from "./chunk-J3BQHHDZ.js";
24
24
  import "./chunk-RTZO2YJC.js";
25
25
  import "./chunk-N2WW62LF.js";
26
26
  import "./chunk-GK7H3SY7.js";
@@ -18,7 +18,7 @@ import {
18
18
  remoteCoordinatorSourceRef,
19
19
  slackCoordinatorSourceRef,
20
20
  takenTeamSlugsForOrchestration
21
- } from "./chunk-2BLJ726H.js";
21
+ } from "./chunk-HRHF6N6S.js";
22
22
  import "./chunk-G3UV3GXJ.js";
23
23
  import "./chunk-JX3OWNOT.js";
24
24
  import "./chunk-BMRJNRQK.js";