@sideboard-ai/core 0.1.52 → 0.1.56
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.cjs +126 -11
- package/dist/agents/cursor-runner.js +45 -6
- package/dist/{agents-YKSS6VBO.js → agents-2YYWW723.js} +3 -3
- package/dist/{agents-ON6RKKND.js → agents-AQFEFKBL.js} +2 -2
- package/dist/{app-settings-LZP632KI.js → app-settings-2LQNRTBE.js} +3 -1
- package/dist/{app-settings-7XVDQJ7F.js → app-settings-73DI4B6T.js} +3 -1
- package/dist/{chunk-J5JTEJ5O.js → chunk-3WJAUKIL.js} +89 -7
- package/dist/{chunk-GNML24AW.js → chunk-5DMYULLC.js} +1 -1
- package/dist/{chunk-D3METLRW.js → chunk-7F454EE2.js} +96 -14
- package/dist/{chunk-6QTZVJ7A.js → chunk-C3J4GDW4.js} +188 -24
- package/dist/{chunk-HBJSHRY2.js → chunk-C4BCC5X5.js} +17 -1
- package/dist/{chunk-T5QQVXK3.js → chunk-DIOF73S2.js} +17 -1
- package/dist/{chunk-UEAHMGHW.js → chunk-DQJ5D42H.js} +16 -2
- package/dist/{chunk-YOWIYAVA.js → chunk-EBWEKG52.js} +36 -11
- package/dist/{chunk-XX5BB7NV.js → chunk-S42XDFKF.js} +36 -11
- package/dist/{chunk-LRLKJM3O.js → chunk-UA5NDAHL.js} +16 -2
- package/dist/{chunk-YDXQ72MD.js → chunk-V2DUTUNC.js} +1 -1
- package/dist/{coordinator-prompt-S6JZD5EF.js → coordinator-prompt-ICF36NUQ.js} +2 -1
- package/dist/{coordinator-prompt-6FXVTSFN.js → coordinator-prompt-RBKUNRPR.js} +2 -1
- package/dist/{global-workspace-EV4G2WMQ.js → global-workspace-667XLBW6.js} +3 -2
- package/dist/{global-workspace-MSX2K27Y.js → global-workspace-S7VLWPWG.js} +3 -2
- package/dist/index.cjs +395 -61
- package/dist/index.d.cts +25 -2
- package/dist/index.d.ts +25 -2
- package/dist/index.js +164 -43
- package/dist/mcp/run-stdio.cjs +389 -57
- package/dist/mcp/run-stdio.js +164 -44
- package/dist/{workspaces-AYTBR6KQ.js → workspaces-FPJJXXAE.js} +4 -3
- package/dist/{workspaces-3RQQZQRO.js → workspaces-LYIDE2VR.js} +4 -3
- package/package.json +1 -1
package/dist/mcp/run-stdio.js
CHANGED
|
@@ -10,34 +10,25 @@ import {
|
|
|
10
10
|
isSessionQuotaLimit,
|
|
11
11
|
listModelsForAgent,
|
|
12
12
|
looksLikeAgentFailureMessage,
|
|
13
|
+
looksLikeInvalidAgentSession,
|
|
13
14
|
parseBrightsyCliLine,
|
|
14
15
|
parseSessionQuotaResetAt,
|
|
15
16
|
pushTurnStderr,
|
|
16
17
|
resolveQuotaFallbackAgent,
|
|
17
18
|
summarizeTurnStderr
|
|
18
|
-
} from "../chunk-
|
|
19
|
+
} from "../chunk-C3J4GDW4.js";
|
|
19
20
|
import "../chunk-H6GGDLYS.js";
|
|
20
21
|
import {
|
|
21
22
|
addWorkspace,
|
|
22
23
|
ensureWorkspace,
|
|
23
24
|
removeWorkspace,
|
|
24
25
|
syncWorkspacesFromThreads
|
|
25
|
-
} from "../chunk-
|
|
26
|
+
} from "../chunk-V2DUTUNC.js";
|
|
26
27
|
import {
|
|
27
28
|
extractPresentedPlan,
|
|
28
29
|
readPlanFile,
|
|
29
30
|
writePlanFile
|
|
30
31
|
} from "../chunk-N5PM7HGQ.js";
|
|
31
|
-
import {
|
|
32
|
-
childEnvWithAppSettings,
|
|
33
|
-
getLinearApiKey,
|
|
34
|
-
isLinearConnected,
|
|
35
|
-
loadAppSettings,
|
|
36
|
-
orchestrationQuotaFallbackAgent,
|
|
37
|
-
orchestrationQuotaOnLimit,
|
|
38
|
-
resolveEffectiveIssueSource,
|
|
39
|
-
updateAdvancedSettings
|
|
40
|
-
} from "../chunk-HBJSHRY2.js";
|
|
41
32
|
import {
|
|
42
33
|
GLOBAL_WORKSPACE_ID,
|
|
43
34
|
healOrchestrationSoccerTitles,
|
|
@@ -46,7 +37,7 @@ import {
|
|
|
46
37
|
isGlobalThread,
|
|
47
38
|
isOrchestratorThread,
|
|
48
39
|
orchestratorSessionPoisonedByBuiltins
|
|
49
|
-
} from "../chunk-
|
|
40
|
+
} from "../chunk-EBWEKG52.js";
|
|
50
41
|
import {
|
|
51
42
|
assertOrchestratorCapableAgent
|
|
52
43
|
} from "../chunk-S2LL5HA4.js";
|
|
@@ -55,7 +46,7 @@ import {
|
|
|
55
46
|
coordinatorTurnReminder,
|
|
56
47
|
enrichWorkspacesWithGithub,
|
|
57
48
|
ensureGlobalCoordinatorCwd
|
|
58
|
-
} from "../chunk-
|
|
49
|
+
} from "../chunk-DQJ5D42H.js";
|
|
59
50
|
import {
|
|
60
51
|
addPrStackLayer,
|
|
61
52
|
allocateTeamName,
|
|
@@ -116,6 +107,17 @@ import {
|
|
|
116
107
|
git,
|
|
117
108
|
run
|
|
118
109
|
} from "../chunk-ZNM4MAN4.js";
|
|
110
|
+
import {
|
|
111
|
+
childEnvWithAppSettings,
|
|
112
|
+
getLinearApiKey,
|
|
113
|
+
isLinearConnected,
|
|
114
|
+
loadAppSettings,
|
|
115
|
+
orchestrationQuotaFallbackAgent,
|
|
116
|
+
orchestrationQuotaOnLimit,
|
|
117
|
+
resolveEffectiveIssueSource,
|
|
118
|
+
resolveNewThreadOptions,
|
|
119
|
+
updateAdvancedSettings
|
|
120
|
+
} from "../chunk-C4BCC5X5.js";
|
|
119
121
|
import "../chunk-KGZBYWZ3.js";
|
|
120
122
|
import {
|
|
121
123
|
loadRepoSettings,
|
|
@@ -310,9 +312,25 @@ function applyAgentEvent(parts, event) {
|
|
|
310
312
|
];
|
|
311
313
|
}
|
|
312
314
|
if (event.type === "tool_result") {
|
|
313
|
-
const
|
|
314
|
-
|
|
315
|
-
|
|
315
|
+
const existing = parts.findIndex((p) => p.type === "tool" && p.id === event.id);
|
|
316
|
+
const fromResult = parseDiffStat(event.content);
|
|
317
|
+
if (existing < 0) {
|
|
318
|
+
return [
|
|
319
|
+
...parts,
|
|
320
|
+
{
|
|
321
|
+
type: "tool",
|
|
322
|
+
id: event.id,
|
|
323
|
+
name: "tool",
|
|
324
|
+
description: "tool",
|
|
325
|
+
status: event.isError ? "error" : "done",
|
|
326
|
+
result: event.content,
|
|
327
|
+
...fromResult.additions != null ? { additions: fromResult.additions } : {},
|
|
328
|
+
...fromResult.deletions != null ? { deletions: fromResult.deletions } : {}
|
|
329
|
+
}
|
|
330
|
+
];
|
|
331
|
+
}
|
|
332
|
+
return parts.map((p, i) => {
|
|
333
|
+
if (i !== existing || p.type !== "tool") return p;
|
|
316
334
|
return {
|
|
317
335
|
...p,
|
|
318
336
|
status: event.isError ? "error" : "done",
|
|
@@ -321,7 +339,6 @@ function applyAgentEvent(parts, event) {
|
|
|
321
339
|
...fromResult.deletions != null ? { deletions: fromResult.deletions } : {}
|
|
322
340
|
};
|
|
323
341
|
});
|
|
324
|
-
return next;
|
|
325
342
|
}
|
|
326
343
|
return parts;
|
|
327
344
|
}
|
|
@@ -375,9 +392,9 @@ async function spawnAgentTurn(thread, input, onEvent) {
|
|
|
375
392
|
`Cannot spawn ${thread.agent}: thread ${thread.id} has no worktreePath`
|
|
376
393
|
);
|
|
377
394
|
}
|
|
378
|
-
const { isGlobalThread: isGlobalThread2 } = await import("../global-workspace-
|
|
395
|
+
const { isGlobalThread: isGlobalThread2 } = await import("../global-workspace-667XLBW6.js");
|
|
379
396
|
if (isGlobalThread2(thread)) {
|
|
380
|
-
const { ensureGlobalCoordinatorCwd: ensureGlobalCoordinatorCwd2 } = await import("../coordinator-prompt-
|
|
397
|
+
const { ensureGlobalCoordinatorCwd: ensureGlobalCoordinatorCwd2 } = await import("../coordinator-prompt-RBKUNRPR.js");
|
|
381
398
|
ensureGlobalCoordinatorCwd2();
|
|
382
399
|
}
|
|
383
400
|
if (isOrchestratorThread(thread)) {
|
|
@@ -1102,7 +1119,13 @@ async function requireAgent(agent, opts) {
|
|
|
1102
1119
|
|
|
1103
1120
|
// src/threads/create.ts
|
|
1104
1121
|
async function createThread(input, _onSetupLine) {
|
|
1105
|
-
|
|
1122
|
+
const resolved = resolveNewThreadOptions({
|
|
1123
|
+
agent: input.agent,
|
|
1124
|
+
model: input.model,
|
|
1125
|
+
effort: input.effort,
|
|
1126
|
+
fast: input.fast
|
|
1127
|
+
});
|
|
1128
|
+
await requireAgent(resolved.agent);
|
|
1106
1129
|
const repoPath = await resolveRepoRoot(input.repoPath);
|
|
1107
1130
|
if (!existsSync5(repoPath)) {
|
|
1108
1131
|
throw new Error(`Repo not found: ${repoPath}`);
|
|
@@ -1145,11 +1168,11 @@ async function createThread(input, _onSetupLine) {
|
|
|
1145
1168
|
branchName,
|
|
1146
1169
|
worktreePath,
|
|
1147
1170
|
repoPath,
|
|
1148
|
-
agent:
|
|
1171
|
+
agent: resolved.agent,
|
|
1149
1172
|
autonomy: input.autonomy ?? "default",
|
|
1150
|
-
model:
|
|
1151
|
-
effort:
|
|
1152
|
-
fast:
|
|
1173
|
+
model: resolved.model,
|
|
1174
|
+
effort: resolved.effort,
|
|
1175
|
+
fast: resolved.fast,
|
|
1153
1176
|
planMode: Boolean(input.planMode),
|
|
1154
1177
|
attachments: input.attachments ?? [],
|
|
1155
1178
|
sourceIsFork,
|
|
@@ -1162,7 +1185,7 @@ async function createThread(input, _onSetupLine) {
|
|
|
1162
1185
|
return readThread(thread.id) ?? thread;
|
|
1163
1186
|
}
|
|
1164
1187
|
async function listLinearIssues(agent, repoPath) {
|
|
1165
|
-
const { getAdapter: getAdapter2 } = await import("../agents-
|
|
1188
|
+
const { getAdapter: getAdapter2 } = await import("../agents-AQFEFKBL.js");
|
|
1166
1189
|
await requireAgent(agent, { requireLinear: true });
|
|
1167
1190
|
const adapter = getAdapter2(agent);
|
|
1168
1191
|
if (!adapter.listLinearIssues) {
|
|
@@ -2024,7 +2047,7 @@ async function adoptThread(input) {
|
|
|
2024
2047
|
messages: input.messages ?? []
|
|
2025
2048
|
});
|
|
2026
2049
|
writeThread(thread);
|
|
2027
|
-
const { ensureWorkspace: ensureWorkspace2 } = await import("../workspaces-
|
|
2050
|
+
const { ensureWorkspace: ensureWorkspace2 } = await import("../workspaces-LYIDE2VR.js");
|
|
2028
2051
|
await ensureWorkspace2(repoPath);
|
|
2029
2052
|
return thread;
|
|
2030
2053
|
}
|
|
@@ -3911,7 +3934,7 @@ var Orchestrator = class {
|
|
|
3911
3934
|
orphans: orphans.map((o) => ({ path: o.path, repoPath: o.repoPath }))
|
|
3912
3935
|
});
|
|
3913
3936
|
}
|
|
3914
|
-
const { autoCleanupOrphansEnabled } = await import("../app-settings-
|
|
3937
|
+
const { autoCleanupOrphansEnabled } = await import("../app-settings-73DI4B6T.js");
|
|
3915
3938
|
if (autoCleanupOrphansEnabled() && shouldRunWorktreeCleanup() && orphans.length > 0) {
|
|
3916
3939
|
await cleanupOrphanWorktrees({ repoPaths });
|
|
3917
3940
|
}
|
|
@@ -4037,21 +4060,30 @@ var Orchestrator = class {
|
|
|
4037
4060
|
return findThreadByRef(idOrRef) ?? readThread(idOrRef);
|
|
4038
4061
|
}
|
|
4039
4062
|
async createThread(input) {
|
|
4040
|
-
|
|
4063
|
+
const thread = await createThread(input);
|
|
4041
4064
|
this.emit({ type: "status_changed", threadId: thread.id, status: thread.status });
|
|
4042
|
-
|
|
4043
|
-
|
|
4065
|
+
void this.finishCreateThread(thread.id, input.prompt?.trim() || void 0);
|
|
4066
|
+
return thread;
|
|
4067
|
+
}
|
|
4068
|
+
async finishCreateThread(threadId, prompt) {
|
|
4069
|
+
await this.runSetupAfterCreate(threadId);
|
|
4070
|
+
const { autoRunAfterSetupEnabled } = await import("../app-settings-73DI4B6T.js");
|
|
4044
4071
|
if (autoRunAfterSetupEnabled()) {
|
|
4045
4072
|
try {
|
|
4046
|
-
await this.startDev(
|
|
4073
|
+
await this.startDev(threadId);
|
|
4047
4074
|
} catch {
|
|
4048
4075
|
}
|
|
4049
4076
|
}
|
|
4050
|
-
const prompt = input.prompt?.trim();
|
|
4051
4077
|
if (prompt) {
|
|
4052
|
-
|
|
4078
|
+
try {
|
|
4079
|
+
await this.send(threadId, prompt);
|
|
4080
|
+
} catch (err) {
|
|
4081
|
+
const message = err instanceof Error ? err.message : String(err);
|
|
4082
|
+
updateThread(threadId, {
|
|
4083
|
+
lastError: `First prompt failed: ${message}`
|
|
4084
|
+
});
|
|
4085
|
+
}
|
|
4053
4086
|
}
|
|
4054
|
-
return thread;
|
|
4055
4087
|
}
|
|
4056
4088
|
/** Run workspace setup after a new worktree is created (no-op if none configured). */
|
|
4057
4089
|
async runSetupAfterCreate(threadId) {
|
|
@@ -4067,7 +4099,7 @@ var Orchestrator = class {
|
|
|
4067
4099
|
}
|
|
4068
4100
|
}
|
|
4069
4101
|
listWorkspaces() {
|
|
4070
|
-
const fromThreads = listThreads({ includeArchived:
|
|
4102
|
+
const fromThreads = listThreads({ includeArchived: true }).map((t) => t.repoPath);
|
|
4071
4103
|
return syncWorkspacesFromThreads(fromThreads);
|
|
4072
4104
|
}
|
|
4073
4105
|
async addWorkspace(repoPath) {
|
|
@@ -4301,7 +4333,7 @@ var Orchestrator = class {
|
|
|
4301
4333
|
});
|
|
4302
4334
|
const artifactDirective = isBrightsy ? null : formatArtifactDirective();
|
|
4303
4335
|
const settings = loadWorkspaceSettings(fresh.worktreePath, fresh.repoPath);
|
|
4304
|
-
const { autoRenameBranchEnabled } = await import("../app-settings-
|
|
4336
|
+
const { autoRenameBranchEnabled } = await import("../app-settings-73DI4B6T.js");
|
|
4305
4337
|
const renameBranchDirective = !isBrightsy && !isOrchestration && autoRenameBranchEnabled() ? formatRenameBranchDirective(fresh, {
|
|
4306
4338
|
customPrompt: settings?.prompts?.renameBranch
|
|
4307
4339
|
}) : null;
|
|
@@ -4397,8 +4429,73 @@ var Orchestrator = class {
|
|
|
4397
4429
|
}
|
|
4398
4430
|
}
|
|
4399
4431
|
}
|
|
4400
|
-
|
|
4401
|
-
|
|
4432
|
+
let lastStderr = summarizeTurnStderr(stderrTail);
|
|
4433
|
+
let detail = lastStderr || (exitCode !== 0 ? fallbackTurnFailDetail(assistantText) : "");
|
|
4434
|
+
if (exitCode !== 0 && !assistantText && parts.length === 0 && !this.stoppedTurns.has(threadId) && looksLikeInvalidAgentSession(detail) && this.requireThread(threadId).sessionId && this.requireThread(threadId).agent !== "cursor" && this.requireThread(threadId).agent !== "brightsy") {
|
|
4435
|
+
updateThread(threadId, { sessionId: null });
|
|
4436
|
+
pushTurnStderr(
|
|
4437
|
+
stderrTail,
|
|
4438
|
+
"Agent session missing \u2014 starting a fresh session"
|
|
4439
|
+
);
|
|
4440
|
+
this.emit({
|
|
4441
|
+
type: "turn_output",
|
|
4442
|
+
threadId,
|
|
4443
|
+
event: {
|
|
4444
|
+
type: "stderr",
|
|
4445
|
+
data: "Agent session missing \u2014 starting a fresh session"
|
|
4446
|
+
}
|
|
4447
|
+
});
|
|
4448
|
+
const retryThread = this.requireThread(threadId);
|
|
4449
|
+
const prior = retryThread.messages.slice(0, -1);
|
|
4450
|
+
const retrySeed = buildSessionSeed(prior);
|
|
4451
|
+
const retryInstructions = retryThread.agent === "claude" ? null : formatAgentInstructions(
|
|
4452
|
+
loadAgentInstructions(retryThread.worktreePath, retryThread.agent)
|
|
4453
|
+
);
|
|
4454
|
+
const retryPrefix = [
|
|
4455
|
+
coordinatorDirective,
|
|
4456
|
+
worktreeDirective,
|
|
4457
|
+
artifactDirective,
|
|
4458
|
+
renameBranchDirective,
|
|
4459
|
+
retryInstructions,
|
|
4460
|
+
retrySeed
|
|
4461
|
+
].filter(Boolean).join("\n\n---\n\n");
|
|
4462
|
+
const retryHandle = await spawnAgentTurn(
|
|
4463
|
+
retryThread,
|
|
4464
|
+
{ cachedPrefix: retryPrefix, prompt: agentPrompt },
|
|
4465
|
+
(event) => {
|
|
4466
|
+
this.emit({ type: "turn_output", threadId, event });
|
|
4467
|
+
if (event.type === "session_id") {
|
|
4468
|
+
updateThread(threadId, { sessionId: event.data });
|
|
4469
|
+
}
|
|
4470
|
+
if (event.type === "stderr" && typeof event.data === "string") {
|
|
4471
|
+
pushTurnStderr(stderrTail, event.data);
|
|
4472
|
+
}
|
|
4473
|
+
}
|
|
4474
|
+
);
|
|
4475
|
+
this.activeTurns.set(threadId, retryHandle);
|
|
4476
|
+
if (typeof retryHandle.pid === "number" && retryHandle.pid > 0) {
|
|
4477
|
+
updateThread(threadId, { agentPid: retryHandle.pid });
|
|
4478
|
+
}
|
|
4479
|
+
this.processes.set(`${threadId}:agent`, {
|
|
4480
|
+
kind: "agent",
|
|
4481
|
+
pid: retryHandle.pid,
|
|
4482
|
+
startedAt: (/* @__PURE__ */ new Date()).toISOString(),
|
|
4483
|
+
kill: retryHandle.kill
|
|
4484
|
+
});
|
|
4485
|
+
if (this.stoppedTurns.has(threadId)) {
|
|
4486
|
+
retryHandle.kill();
|
|
4487
|
+
}
|
|
4488
|
+
const retryResult = await retryHandle.done;
|
|
4489
|
+
if (retryResult.sessionId) {
|
|
4490
|
+
updateThread(threadId, { sessionId: retryResult.sessionId });
|
|
4491
|
+
}
|
|
4492
|
+
assistantText = retryResult.assistantText.trim();
|
|
4493
|
+
parts = retryResult.parts;
|
|
4494
|
+
usage = retryResult.usage ?? void 0;
|
|
4495
|
+
exitCode = retryResult.exitCode;
|
|
4496
|
+
lastStderr = summarizeTurnStderr(stderrTail);
|
|
4497
|
+
detail = lastStderr || (exitCode !== 0 ? fallbackTurnFailDetail(assistantText) : "");
|
|
4498
|
+
}
|
|
4402
4499
|
let chatText = assistantText;
|
|
4403
4500
|
if (exitCode !== 0 && !chatText && looksLikeAgentFailureMessage(detail)) {
|
|
4404
4501
|
chatText = humanizeAgentFailDetail(detail);
|
|
@@ -5102,7 +5199,15 @@ var Orchestrator = class {
|
|
|
5102
5199
|
}
|
|
5103
5200
|
await removeWorktree(thread.repoPath, thread.worktreePath);
|
|
5104
5201
|
}
|
|
5105
|
-
|
|
5202
|
+
const archived = setStatus(thread.id, "archived");
|
|
5203
|
+
if (thread.repoPath && !isGlobalRepoPath(thread.repoPath)) {
|
|
5204
|
+
try {
|
|
5205
|
+
const { ensureWorkspace: ensureWorkspace2 } = await import("../workspaces-LYIDE2VR.js");
|
|
5206
|
+
await ensureWorkspace2(thread.repoPath);
|
|
5207
|
+
} catch {
|
|
5208
|
+
}
|
|
5209
|
+
}
|
|
5210
|
+
return archived;
|
|
5106
5211
|
}
|
|
5107
5212
|
async purge(threadRef, opts) {
|
|
5108
5213
|
const thread = this.requireThread(threadRef);
|
|
@@ -5118,7 +5223,7 @@ var Orchestrator = class {
|
|
|
5118
5223
|
await runArchiveScript(thread.repoPath, thread.worktreePath);
|
|
5119
5224
|
} catch {
|
|
5120
5225
|
}
|
|
5121
|
-
const { deleteBranchOnPurgeEnabled } = await import("../app-settings-
|
|
5226
|
+
const { deleteBranchOnPurgeEnabled } = await import("../app-settings-73DI4B6T.js");
|
|
5122
5227
|
const deleteBranch = opts?.deleteBranch ?? deleteBranchOnPurgeEnabled();
|
|
5123
5228
|
await removeWorktree(thread.repoPath, thread.worktreePath, {
|
|
5124
5229
|
deleteBranch: deleteBranch ? thread.branchName : void 0
|
|
@@ -5510,13 +5615,19 @@ async function startMcpServer() {
|
|
|
5510
5615
|
return { content: [{ type: "text", text: JSON.stringify(payload) }] };
|
|
5511
5616
|
}
|
|
5512
5617
|
);
|
|
5618
|
+
const { resolveNewThreadOptions: resolveNewThreadOptions2, resolveThreadDefaults } = await import("../app-settings-73DI4B6T.js");
|
|
5619
|
+
const accountDefaults = resolveThreadDefaults();
|
|
5620
|
+
const accountDefaultsHint = `Account defaults: agent=${accountDefaults.agent}, model=${accountDefaults.model?.trim() || "Auto"}, effort=${accountDefaults.effort}`;
|
|
5513
5621
|
server.tool(
|
|
5514
5622
|
"create_thread",
|
|
5515
|
-
|
|
5623
|
+
`Create a new worktree thread (chat) from branch, pr, or ticket. Pass repoPath from list_workspaces and parentThreadId when spawning from an orchestrator. Prefer omitting agent/model so Sideboard applies ${accountDefaultsHint}. Then use send_to_thread to chat.`,
|
|
5516
5624
|
{
|
|
5517
5625
|
sourceType: z.enum(["branch", "pr", "ticket"]),
|
|
5518
5626
|
sourceRef: z.string(),
|
|
5519
|
-
agent: z.enum(["claude", "codex", "opencode", "brightsy", "cursor"]),
|
|
5627
|
+
agent: z.enum(["claude", "codex", "opencode", "brightsy", "cursor"]).optional().describe(`Omit to use Account default agent (${accountDefaults.agent})`),
|
|
5628
|
+
model: z.string().nullable().optional().describe(
|
|
5629
|
+
`Usually omit to use Account default model (${accountDefaults.model?.trim() || "Auto"}). Pass null only to force Auto / agent-default.`
|
|
5630
|
+
),
|
|
5520
5631
|
repoPath: z.string(),
|
|
5521
5632
|
title: z.string().optional(),
|
|
5522
5633
|
parentThreadId: z.string().optional()
|
|
@@ -5536,10 +5647,17 @@ async function startMcpServer() {
|
|
|
5536
5647
|
};
|
|
5537
5648
|
}
|
|
5538
5649
|
}
|
|
5650
|
+
const opts = resolveNewThreadOptions2({
|
|
5651
|
+
agent: args.agent,
|
|
5652
|
+
model: args.model
|
|
5653
|
+
});
|
|
5539
5654
|
const thread = await orch.createThread({
|
|
5540
5655
|
sourceType: args.sourceType,
|
|
5541
5656
|
sourceRef: args.sourceRef,
|
|
5542
|
-
agent:
|
|
5657
|
+
agent: opts.agent,
|
|
5658
|
+
model: opts.model,
|
|
5659
|
+
effort: opts.effort,
|
|
5660
|
+
fast: opts.fast,
|
|
5543
5661
|
repoPath: args.repoPath,
|
|
5544
5662
|
title: args.title,
|
|
5545
5663
|
parentThreadId: args.parentThreadId ?? null
|
|
@@ -5553,6 +5671,8 @@ async function startMcpServer() {
|
|
|
5553
5671
|
title: thread.title,
|
|
5554
5672
|
branchName: thread.branchName,
|
|
5555
5673
|
worktreePath: thread.worktreePath,
|
|
5674
|
+
agent: thread.agent,
|
|
5675
|
+
model: thread.model,
|
|
5556
5676
|
status: thread.status,
|
|
5557
5677
|
link: `sideboard://thread/${thread.id}`
|
|
5558
5678
|
})
|
|
@@ -4,10 +4,11 @@ import {
|
|
|
4
4
|
listWorkspaces,
|
|
5
5
|
removeWorkspace,
|
|
6
6
|
syncWorkspacesFromThreads
|
|
7
|
-
} from "./chunk-
|
|
8
|
-
import "./chunk-
|
|
7
|
+
} from "./chunk-5DMYULLC.js";
|
|
8
|
+
import "./chunk-S42XDFKF.js";
|
|
9
9
|
import "./chunk-GI7E5733.js";
|
|
10
|
-
import "./chunk-
|
|
10
|
+
import "./chunk-UA5NDAHL.js";
|
|
11
|
+
import "./chunk-DIOF73S2.js";
|
|
11
12
|
import "./chunk-DZFH2KLT.js";
|
|
12
13
|
import "./chunk-FKOIHGKV.js";
|
|
13
14
|
import "./chunk-TSRXOSVD.js";
|
|
@@ -6,14 +6,15 @@ import {
|
|
|
6
6
|
listWorkspaces,
|
|
7
7
|
removeWorkspace,
|
|
8
8
|
syncWorkspacesFromThreads
|
|
9
|
-
} from "./chunk-
|
|
10
|
-
import "./chunk-
|
|
9
|
+
} from "./chunk-V2DUTUNC.js";
|
|
10
|
+
import "./chunk-EBWEKG52.js";
|
|
11
11
|
import "./chunk-S2LL5HA4.js";
|
|
12
|
-
import "./chunk-
|
|
12
|
+
import "./chunk-DQJ5D42H.js";
|
|
13
13
|
import "./chunk-XOU6HNQJ.js";
|
|
14
14
|
import "./chunk-B3SJXYIJ.js";
|
|
15
15
|
import "./chunk-HLEX5AQ6.js";
|
|
16
16
|
import "./chunk-ZNM4MAN4.js";
|
|
17
|
+
import "./chunk-C4BCC5X5.js";
|
|
17
18
|
import "./chunk-KGZBYWZ3.js";
|
|
18
19
|
import "./chunk-7MV3RXSC.js";
|
|
19
20
|
export {
|