@sideboard-ai/core 0.1.103 → 0.1.109
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.
- package/dist/agents/cursor-runner.js +2 -2
- package/dist/{agents-UT5GCJH3.js → agents-XB332VUJ.js} +5 -5
- package/dist/{agents-XZBAKBO2.js → agents-YIMHDI46.js} +8 -8
- package/dist/{app-settings-VDJK2BZ2.js → app-settings-EBCVMFF6.js} +3 -1
- package/dist/{app-settings-EKJM2344.js → app-settings-IYSSVZHH.js} +4 -2
- package/dist/{chunk-XHZJJWLI.js → chunk-4LKD3PGO.js} +11 -1
- package/dist/{chunk-TLPJHLLM.js → chunk-4TR3HZFT.js} +1 -1
- package/dist/{chunk-HHLZWO7U.js → chunk-756EO4GK.js} +7 -7
- package/dist/{chunk-LANDJIAI.js → chunk-AY2EQI2P.js} +16 -13
- package/dist/{chunk-DHAGMJIK.js → chunk-EW7COXYE.js} +1 -1
- package/dist/{chunk-27MCESES.js → chunk-FBV6NK62.js} +2 -2
- package/dist/{chunk-ETMRBJKA.js → chunk-I2OJ2YSP.js} +10 -17
- package/dist/{chunk-WA3DVVWG.js → chunk-JVIW55KT.js} +1 -1
- package/dist/{chunk-H6LP57EF.js → chunk-KKHDPV45.js} +17 -16
- package/dist/chunk-LTPX5N6K.js +6991 -0
- package/dist/{chunk-WSYCND2U.js → chunk-NE4TOOKS.js} +11 -1
- package/dist/{chunk-ND6AO7C5.js → chunk-OQDIYVDD.js} +2 -2
- package/dist/chunk-Q6B3NRCT.js +7335 -0
- package/dist/{chunk-OW34MVDN.js → chunk-TROJ3PVH.js} +3 -3
- package/dist/{chunk-YJADJH5U.js → chunk-VRTKGKUW.js} +10 -17
- package/dist/{chunk-HUKCGRAT.js → chunk-WD2TARQS.js} +7 -2
- package/dist/{coordinator-prompt-UWHSD65V.js → coordinator-prompt-JKOU6BWV.js} +4 -4
- package/dist/{coordinator-prompt-3DFZRMXE.js → coordinator-prompt-V66BYTUV.js} +3 -3
- package/dist/{global-workspace-UR4E3CCG.js → global-workspace-NCTBE7G7.js} +5 -5
- package/dist/{global-workspace-KJQS5S2C.js → global-workspace-WBQWQQQY.js} +4 -4
- package/dist/index.cjs +11716 -10808
- package/dist/index.d.cts +162 -35
- package/dist/index.d.ts +162 -35
- package/dist/index.js +774 -7046
- package/dist/mcp/run-stdio.cjs +14582 -13657
- package/dist/mcp/run-stdio.js +400 -6706
- package/dist/orchestrator-6W7EKSPO.js +32 -0
- package/dist/orchestrator-JVGVPKLI.js +31 -0
- package/dist/{workspaces-NTIVI6DI.js → workspaces-I3554R3F.js} +5 -5
- package/dist/{workspaces-TKJXPNV4.js → workspaces-SUBEDSGB.js} +6 -6
- package/dist/{worktree-PEUPFAKL.js → worktree-2UWO7VEK.js} +3 -3
- package/dist/{worktree-NKWN5ZTS.js → worktree-7H6HB6GW.js} +2 -2
- package/package.json +2 -1
|
@@ -2,12 +2,12 @@
|
|
|
2
2
|
|
|
3
3
|
import {
|
|
4
4
|
ensureGlobalCoordinatorCwd
|
|
5
|
-
} from "./chunk-
|
|
5
|
+
} from "./chunk-VRTKGKUW.js";
|
|
6
6
|
import {
|
|
7
7
|
allocateTeamName,
|
|
8
8
|
takenSlugsFromThread,
|
|
9
9
|
teamSlugFromName
|
|
10
|
-
} from "./chunk-
|
|
10
|
+
} from "./chunk-JVIW55KT.js";
|
|
11
11
|
import {
|
|
12
12
|
createEmptyThread,
|
|
13
13
|
listThreads,
|
|
@@ -17,7 +17,7 @@ import {
|
|
|
17
17
|
import {
|
|
18
18
|
resolveNewThreadOptions,
|
|
19
19
|
resolveThreadDefaults
|
|
20
|
-
} from "./chunk-
|
|
20
|
+
} from "./chunk-NE4TOOKS.js";
|
|
21
21
|
import {
|
|
22
22
|
globalAgentCwd
|
|
23
23
|
} from "./chunk-BD2ICC4D.js";
|
|
@@ -2,10 +2,10 @@
|
|
|
2
2
|
|
|
3
3
|
import {
|
|
4
4
|
resolveGithubRepoSlug
|
|
5
|
-
} from "./chunk-
|
|
5
|
+
} from "./chunk-JVIW55KT.js";
|
|
6
6
|
import {
|
|
7
7
|
resolveThreadDefaults
|
|
8
|
-
} from "./chunk-
|
|
8
|
+
} from "./chunk-NE4TOOKS.js";
|
|
9
9
|
import {
|
|
10
10
|
globalAgentCwd,
|
|
11
11
|
sideboardReposDir
|
|
@@ -54,7 +54,8 @@ var COORDINATOR_TOOL_PLAYBOOK = [
|
|
|
54
54
|
"- list_models \u2014 only when you need a specific model (rare); otherwise omit model so Account defaults apply",
|
|
55
55
|
"- list_threads / get_thread \u2014 fleet status (what is going on)",
|
|
56
56
|
"- ask_user \u2014 composer multiple-choice only when blocked on a concrete choice (approach fork, which API). Never for hellos, check-ins, or invented \u201Cwhat should we do?\u201D menus \u2014 reply in chat. Explain options first, description on every option, then wait.",
|
|
57
|
-
"- set_caffeinate \u2014 keep this Mac awake across turns (macOS caffeinate). Turn on for Slack / away-from-keyboard work
|
|
57
|
+
"- set_caffeinate \u2014 keep this Mac awake across turns (macOS caffeinate). Turn on for Slack / away-from-keyboard work, overnight schedules, or when the user will be away. Turn OFF when they say they are done, wrapping up, going to sleep, or no longer need the machine awake. Closing this chat also releases it.",
|
|
58
|
+
"- list_schedules / create_schedule / update_schedule / delete_schedule / run_schedule \u2014 local jobs that send a prompt to an orchestration chat (threadId or self) or start a new Global chat (omit threadId). One-shot `at`, interval `every` (15m/1h/6h/1d), or 5-field `cron`. Recurring jobs without threadId open a new chat each run. Jobs fire only while Sideboard.app is running; sleep skips until wake. Overnight/unattended runs: ask the user to enable Settings \u2192 Advanced \u2192 Caffeinate while schedules are enabled, or call set_caffeinate.",
|
|
58
59
|
"Workspaces:",
|
|
59
60
|
"- add_workspace / remove_workspace \u2014 register or unregister a git repo",
|
|
60
61
|
"Worktree threads (chats):",
|
|
@@ -70,14 +71,14 @@ var COORDINATOR_TOOL_PLAYBOOK = [
|
|
|
70
71
|
"- list_run_scripts / run_dev_script / stop_dev_script \u2014 start/stop named run scripts",
|
|
71
72
|
"Inspect / review / PRs:",
|
|
72
73
|
"- get_diff \u2014 compact diff summary",
|
|
73
|
-
'- request_review \u2014 open a Review chat tab on a worktree thread (attaches .
|
|
74
|
+
'- request_review \u2014 open a Review chat tab on a worktree thread (attaches .claude/skills/review/SKILL.md when present, else seeds that skill / local guidelines; sends "Review changes in this workspace."); then wait_for_turn (loop while stillRunning) / get_turn_result on the returned id',
|
|
74
75
|
"- ask_git \u2014 commit & push, open a draft PR, resolve conflicts, or merge. When the worktree is clean, Sideboard pushes / opens the PR itself. When dirty, it queues the worktree agent \u2014 then wait_for_turn (loop while stillRunning). Prefer this over paraphrasing.",
|
|
75
76
|
'- Merge (`ask_git` action=merge / send_to_thread "Merge PR.") only when the user explicitly asked to merge that PR. Do not merge because the work looks done, CI is green, or a typical flow includes it.',
|
|
76
77
|
'- Or send_to_thread with those exact phrases: "Commit and push.", "Commit, push, and open a draft PR.", "Merge the remote branch (main) into your branch and resolve conflicts. Then, commit and push your changes.", "Merge PR." (draft PRs: `gh pr create --draft -R <origin-owner/name>` using the workspace `github:` slug \u2014 never upstream). Never run git/gh from this orchestration cwd, and never merge the PR yourself.',
|
|
77
78
|
"Process guides:",
|
|
78
79
|
"- 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.",
|
|
79
|
-
"- 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. Do not use `.sideboard/skills
|
|
80
|
-
"- One-offs: no guide. Same miss across threads: edit the skill or `.
|
|
80
|
+
"- 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` (create it \u2014 that is allowed). Do not use `.sideboard/skills/` (that folder only). Codex/OpenCode: one line in AGENTS.md pointing at that file.",
|
|
81
|
+
"- One-offs: no guide. Same miss across threads: edit the skill or `.claude/skills/review/SKILL.md`, then rerun the batch \u2014 do not patch three threads.",
|
|
81
82
|
"Human-only (do not attempt): ready-for-review land (confirm_land), purge_thread.",
|
|
82
83
|
"Thread links in replies: when mentioning a chat/thread for the user, include a markdown link `[Title](sideboard://thread/<id>)` using the full id (or the link field from create_thread / list_threads). Sideboard renders these as clickable opens.",
|
|
83
84
|
"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."
|
|
@@ -98,19 +99,11 @@ function coordinatorTurnReminder(opts) {
|
|
|
98
99
|
const goal = opts.goal?.trim();
|
|
99
100
|
return [
|
|
100
101
|
"Sideboard Orchestration (mandatory):",
|
|
101
|
-
"- You oversee
|
|
102
|
-
|
|
103
|
-
"- Registered workspaces / child threads are the fleet you manage via Sideboard MCP.",
|
|
104
|
-
`- YOUR orchestration thread id is ${opts.parentId}`,
|
|
105
|
-
`- Always pass parentThreadId="${opts.parentId}" on create_thread (never invent or reuse another uuid).`,
|
|
106
|
-
`- Or omit parentThreadId \u2014 Sideboard MCP already binds children to ${opts.parentId}.`,
|
|
102
|
+
"- You oversee worktree agents from a synthetic empty cwd (not a git repo). Follow AGENTS.md / CLAUDE.md.",
|
|
103
|
+
`- YOUR orchestration thread id is ${opts.parentId} \u2014 pass parentThreadId="${opts.parentId}" on create_thread, or omit it.`,
|
|
107
104
|
goal ? `- Goal / title: ${goal}` : null,
|
|
108
105
|
accountDefaultsPlaybookLine(),
|
|
109
|
-
|
|
110
|
-
"- Existing repo: create_thread on a repoPath \u2192 send_to_thread \u2192 wait_for_turn. If stillRunning, the child is working (progress is tools/thinking) \u2014 wait_for_turn again; do not ping it. If status is error, lastError/text is the failure \u2014 adapt (switch agent, tell the user). Commit/push/draft PR with ask_git on the child, then wait_for_turn \u2014 never git/gh from this cwd. Call ask_git merge only if the user explicitly asked to merge.",
|
|
111
|
-
"- New repo: Bash (clone or gh repo create under ~/sideboard/repos/<name>) \u2192 add_workspace \u2192 create_thread \u2192 send_to_thread \u2192 wait_for_turn (loop while stillRunning) \u2192 ask_git create-draft.",
|
|
112
|
-
"- When naming threads for the user, link them as `[Title](sideboard://thread/<id>)`.",
|
|
113
|
-
"- If they will wait on Slack or leave the Mac, call set_caffeinate enabled=true. When they say they are done / wrapping up / going to sleep, call set_caffeinate enabled=false. Closing this chat also turns it off."
|
|
106
|
+
"- Status: list_threads. Link chats as `[Title](sideboard://thread/<id>)`. Merge only if the user asked."
|
|
114
107
|
].filter(Boolean).join("\n");
|
|
115
108
|
}
|
|
116
109
|
function ensureGlobalCoordinatorCwd(opts) {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import {
|
|
2
2
|
isElectronLikeCommand,
|
|
3
3
|
wrapElectronAsNodeLaunch
|
|
4
|
-
} from "./chunk-
|
|
4
|
+
} from "./chunk-4TR3HZFT.js";
|
|
5
5
|
import {
|
|
6
6
|
run
|
|
7
7
|
} from "./chunk-LGXBYZZA.js";
|
|
@@ -94,6 +94,8 @@ function summarizeTurnStderr(tail, maxChars = 500) {
|
|
|
94
94
|
if (tail.length === 0) return "";
|
|
95
95
|
const cursorStartup = [...tail].reverse().find((line) => /cursor startup failed:/i.test(line));
|
|
96
96
|
if (cursorStartup) return clipStderr(cursorStartup, maxChars);
|
|
97
|
+
const cursorRunFailed = [...tail].reverse().find((line) => /^cursor run failed\b/i.test(line.trim()));
|
|
98
|
+
if (cursorRunFailed) return clipStderr(cursorRunFailed, maxChars);
|
|
97
99
|
if (tail.some(looksLikeNestedElectronCrash)) return NESTED_ELECTRON_SUMMARY;
|
|
98
100
|
if (tail.some(looksLikeHomebrewLibuvCrash)) return HOMEBREW_LIBUV_SUMMARY;
|
|
99
101
|
if (tail.some(
|
|
@@ -124,7 +126,7 @@ function looksLikeRetryableRunnerCrash(text) {
|
|
|
124
126
|
const lower = text.trim().toLowerCase();
|
|
125
127
|
if (/cannot find (?:package|module)|err_module_not_found/.test(lower)) return false;
|
|
126
128
|
if (!lower) return true;
|
|
127
|
-
return /uv_run|spineventloopinternal|libuv|homebrew node \+ shared libuv|hascustomhostobject|electroninitializeicuandstartnode|nested chromium|truncated crash dump|sig(?:segv|abrt|ill)|segmentation fault|illegal instruction|fatal error/.test(
|
|
129
|
+
return /uv_run|spineventloopinternal|libuv|homebrew node \+ shared libuv|hascustomhostobject|electroninitializeicuandstartnode|nested chromium|truncated crash dump|connection stalled|sig(?:segv|abrt|ill)|segmentation fault|illegal instruction|fatal error/.test(
|
|
128
130
|
lower
|
|
129
131
|
);
|
|
130
132
|
}
|
|
@@ -182,6 +184,9 @@ function humanizeAgentFailDetail(detail) {
|
|
|
182
184
|
if (/corrupt local agent checkpoint|missing root blob|truncated crash dump/.test(lower)) {
|
|
183
185
|
return `${raw} \u2014 retry the turn (Sideboard will start a fresh Cursor session).`;
|
|
184
186
|
}
|
|
187
|
+
if (/connection stalled/.test(lower)) {
|
|
188
|
+
return /retry the turn/i.test(raw) ? raw : `${raw} \u2014 retry the turn (Sideboard will start a fresh Cursor session).`;
|
|
189
|
+
}
|
|
185
190
|
return raw;
|
|
186
191
|
}
|
|
187
192
|
function turnFailChatText(opts) {
|
|
@@ -7,11 +7,11 @@ import {
|
|
|
7
7
|
enrichWorkspacesWithGithub,
|
|
8
8
|
ensureGlobalCoordinatorCwd,
|
|
9
9
|
formatWorkspaceInventory
|
|
10
|
-
} from "./chunk-
|
|
11
|
-
import "./chunk-
|
|
10
|
+
} from "./chunk-I2OJ2YSP.js";
|
|
11
|
+
import "./chunk-EW7COXYE.js";
|
|
12
12
|
import "./chunk-FKOIHGKV.js";
|
|
13
|
-
import "./chunk-
|
|
14
|
-
import "./chunk-
|
|
13
|
+
import "./chunk-4LKD3PGO.js";
|
|
14
|
+
import "./chunk-4TR3HZFT.js";
|
|
15
15
|
import "./chunk-JT7R45JB.js";
|
|
16
16
|
import "./chunk-KGSVLZV6.js";
|
|
17
17
|
import "./chunk-77WWLBCI.js";
|
|
@@ -9,11 +9,11 @@ import {
|
|
|
9
9
|
enrichWorkspacesWithGithub,
|
|
10
10
|
ensureGlobalCoordinatorCwd,
|
|
11
11
|
formatWorkspaceInventory
|
|
12
|
-
} from "./chunk-
|
|
13
|
-
import "./chunk-
|
|
12
|
+
} from "./chunk-VRTKGKUW.js";
|
|
13
|
+
import "./chunk-JVIW55KT.js";
|
|
14
14
|
import "./chunk-B3SJXYIJ.js";
|
|
15
15
|
import "./chunk-P3BQ5DOL.js";
|
|
16
|
-
import "./chunk-
|
|
16
|
+
import "./chunk-NE4TOOKS.js";
|
|
17
17
|
import "./chunk-NSTQ6QKD.js";
|
|
18
18
|
import "./chunk-KGZBYWZ3.js";
|
|
19
19
|
import "./chunk-BD2ICC4D.js";
|
|
@@ -15,12 +15,12 @@ import {
|
|
|
15
15
|
orchestratorSessionPoisonedByBuiltins,
|
|
16
16
|
slackCoordinatorSourceRef,
|
|
17
17
|
takenTeamSlugsForOrchestration
|
|
18
|
-
} from "./chunk-
|
|
19
|
-
import "./chunk-
|
|
20
|
-
import "./chunk-
|
|
18
|
+
} from "./chunk-756EO4GK.js";
|
|
19
|
+
import "./chunk-I2OJ2YSP.js";
|
|
20
|
+
import "./chunk-EW7COXYE.js";
|
|
21
21
|
import "./chunk-FKOIHGKV.js";
|
|
22
|
-
import "./chunk-
|
|
23
|
-
import "./chunk-
|
|
22
|
+
import "./chunk-4LKD3PGO.js";
|
|
23
|
+
import "./chunk-4TR3HZFT.js";
|
|
24
24
|
import "./chunk-JT7R45JB.js";
|
|
25
25
|
import "./chunk-KGSVLZV6.js";
|
|
26
26
|
import "./chunk-77WWLBCI.js";
|
|
@@ -17,12 +17,12 @@ import {
|
|
|
17
17
|
orchestratorSessionPoisonedByBuiltins,
|
|
18
18
|
slackCoordinatorSourceRef,
|
|
19
19
|
takenTeamSlugsForOrchestration
|
|
20
|
-
} from "./chunk-
|
|
21
|
-
import "./chunk-
|
|
22
|
-
import "./chunk-
|
|
20
|
+
} from "./chunk-TROJ3PVH.js";
|
|
21
|
+
import "./chunk-VRTKGKUW.js";
|
|
22
|
+
import "./chunk-JVIW55KT.js";
|
|
23
23
|
import "./chunk-B3SJXYIJ.js";
|
|
24
24
|
import "./chunk-P3BQ5DOL.js";
|
|
25
|
-
import "./chunk-
|
|
25
|
+
import "./chunk-NE4TOOKS.js";
|
|
26
26
|
import "./chunk-NSTQ6QKD.js";
|
|
27
27
|
import "./chunk-KGZBYWZ3.js";
|
|
28
28
|
import {
|