@sideboard-ai/core 0.1.41 → 0.1.43
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 +14 -5
- package/dist/agents/cursor-runner.js +14 -5
- package/dist/{agents-T6XHC5OV.js → agents-T3EA7GZV.js} +3 -2
- package/dist/{app-settings-RSKDEMUI.js → app-settings-ZKVZHJPQ.js} +6 -1
- package/dist/chunk-77WWLBCI.js +50 -0
- package/dist/{chunk-VA2U5EQH.js → chunk-7PCTK4WO.js} +1 -1
- package/dist/{chunk-WD35X6U5.js → chunk-AGU52GTV.js} +50 -19
- package/dist/{chunk-5UIKSPDD.js → chunk-ENSD62HW.js} +12 -0
- package/dist/{chunk-YZ23S32T.js → chunk-FSIK442J.js} +35 -1
- package/dist/{chunk-44LYDJFB.js → chunk-FUCEOJFO.js} +2 -2
- package/dist/{chunk-SX2R2PCE.js → chunk-VC7NORFX.js} +5 -5
- package/dist/{chunk-6TZSJMXF.js → chunk-X6P2QVRJ.js} +4 -3
- package/dist/{chunk-UPMGXM4X.js → chunk-Z2BQMXVM.js} +1 -1
- package/dist/{coordinator-prompt-FAILHO4J.js → coordinator-prompt-BHXBQRPM.js} +4 -3
- package/dist/{global-workspace-4GVWSCEX.js → global-workspace-SNN45OCN.js} +5 -4
- package/dist/index.cjs +146 -5
- package/dist/index.d.cts +74 -5
- package/dist/index.d.ts +74 -5
- package/dist/index.js +28 -8
- package/dist/mcp/run-stdio.cjs +99 -5
- package/dist/mcp/run-stdio.js +9 -8
- package/dist/{thread-store-WPLT3IXM.js → thread-store-EHROA3VZ.js} +4 -1
- package/dist/{workspaces-Z7CSL4O6.js → workspaces-AUYIJ64Z.js} +6 -5
- package/dist/{worktree-M3DTPYBW.js → worktree-N4PRV4V3.js} +3 -2
- package/package.json +1 -1
|
@@ -152,13 +152,19 @@ function emit(event) {
|
|
|
152
152
|
process.stdout.write(`${JSON.stringify(event)}
|
|
153
153
|
`);
|
|
154
154
|
}
|
|
155
|
-
function modelSelection(model,
|
|
155
|
+
function modelSelection(model, opts) {
|
|
156
156
|
const raw = model && model.trim() || "";
|
|
157
157
|
const id = !raw || raw.toLowerCase() === "auto" || raw.toLowerCase() === "default" ? "default" : raw;
|
|
158
|
-
|
|
159
|
-
|
|
158
|
+
const params = [];
|
|
159
|
+
const effort = (opts.effort ?? "").trim().toLowerCase();
|
|
160
|
+
const normalized = effort === "normal" ? "medium" : effort === "low" || effort === "medium" || effort === "high" || effort === "xhigh" || effort === "max" ? effort : "";
|
|
161
|
+
if (normalized) {
|
|
162
|
+
params.push({ id: "effort", value: normalized });
|
|
160
163
|
}
|
|
161
|
-
|
|
164
|
+
if (opts.fast) {
|
|
165
|
+
params.push({ id: "fast", value: "true" });
|
|
166
|
+
}
|
|
167
|
+
return params.length > 0 ? { id, params } : { id };
|
|
162
168
|
}
|
|
163
169
|
function localAgentStore() {
|
|
164
170
|
const root = (0, import_node_path4.join)(appDataDir(), "cursor-sdk-store");
|
|
@@ -193,7 +199,10 @@ async function main() {
|
|
|
193
199
|
return 1;
|
|
194
200
|
}
|
|
195
201
|
const apiKey = (req.apiKey || process.env.CURSOR_API_KEY || "").trim() || void 0;
|
|
196
|
-
const model = modelSelection(req.model,
|
|
202
|
+
const model = modelSelection(req.model, {
|
|
203
|
+
effort: req.effort,
|
|
204
|
+
fast: Boolean(req.fast)
|
|
205
|
+
});
|
|
197
206
|
const mode = req.planMode ? "plan" : "agent";
|
|
198
207
|
const store = localAgentStore();
|
|
199
208
|
const local = { cwd: req.cwd, store };
|
|
@@ -16,13 +16,19 @@ function emit(event) {
|
|
|
16
16
|
process.stdout.write(`${JSON.stringify(event)}
|
|
17
17
|
`);
|
|
18
18
|
}
|
|
19
|
-
function modelSelection(model,
|
|
19
|
+
function modelSelection(model, opts) {
|
|
20
20
|
const raw = model && model.trim() || "";
|
|
21
21
|
const id = !raw || raw.toLowerCase() === "auto" || raw.toLowerCase() === "default" ? "default" : raw;
|
|
22
|
-
|
|
23
|
-
|
|
22
|
+
const params = [];
|
|
23
|
+
const effort = (opts.effort ?? "").trim().toLowerCase();
|
|
24
|
+
const normalized = effort === "normal" ? "medium" : effort === "low" || effort === "medium" || effort === "high" || effort === "xhigh" || effort === "max" ? effort : "";
|
|
25
|
+
if (normalized) {
|
|
26
|
+
params.push({ id: "effort", value: normalized });
|
|
24
27
|
}
|
|
25
|
-
|
|
28
|
+
if (opts.fast) {
|
|
29
|
+
params.push({ id: "fast", value: "true" });
|
|
30
|
+
}
|
|
31
|
+
return params.length > 0 ? { id, params } : { id };
|
|
26
32
|
}
|
|
27
33
|
function localAgentStore() {
|
|
28
34
|
const root = join(appDataDir(), "cursor-sdk-store");
|
|
@@ -57,7 +63,10 @@ async function main() {
|
|
|
57
63
|
return 1;
|
|
58
64
|
}
|
|
59
65
|
const apiKey = (req.apiKey || process.env.CURSOR_API_KEY || "").trim() || void 0;
|
|
60
|
-
const model = modelSelection(req.model,
|
|
66
|
+
const model = modelSelection(req.model, {
|
|
67
|
+
effort: req.effort,
|
|
68
|
+
fast: Boolean(req.fast)
|
|
69
|
+
});
|
|
61
70
|
const mode = req.planMode ? "plan" : "agent";
|
|
62
71
|
const store = localAgentStore();
|
|
63
72
|
const local = { cwd: req.cwd, store };
|
|
@@ -21,13 +21,14 @@ import {
|
|
|
21
21
|
opencodeAdapter,
|
|
22
22
|
permissionMode,
|
|
23
23
|
resolveCursorModelId
|
|
24
|
-
} from "./chunk-
|
|
24
|
+
} from "./chunk-VC7NORFX.js";
|
|
25
25
|
import "./chunk-ILQK4P5R.js";
|
|
26
26
|
import {
|
|
27
27
|
cursorSdkMessageToEvents,
|
|
28
28
|
parseCursorRunnerLine
|
|
29
29
|
} from "./chunk-PU27NUO4.js";
|
|
30
|
-
import "./chunk-
|
|
30
|
+
import "./chunk-FSIK442J.js";
|
|
31
|
+
import "./chunk-77WWLBCI.js";
|
|
31
32
|
import "./chunk-M37RITA6.js";
|
|
32
33
|
import {
|
|
33
34
|
ensureAgentPath
|
|
@@ -14,6 +14,8 @@ import {
|
|
|
14
14
|
claudeUserSettingsPath,
|
|
15
15
|
deleteBranchOnPurgeEnabled,
|
|
16
16
|
getDefaultAgent,
|
|
17
|
+
getDefaultEffort,
|
|
18
|
+
getDefaultFast,
|
|
17
19
|
getDefaultModel,
|
|
18
20
|
getIssueSource,
|
|
19
21
|
getLinearApiKey,
|
|
@@ -31,7 +33,8 @@ import {
|
|
|
31
33
|
updateClaudeSettings,
|
|
32
34
|
updateDefaultsSettings,
|
|
33
35
|
updateIntegrationsSettings
|
|
34
|
-
} from "./chunk-
|
|
36
|
+
} from "./chunk-FSIK442J.js";
|
|
37
|
+
import "./chunk-77WWLBCI.js";
|
|
35
38
|
import "./chunk-M37RITA6.js";
|
|
36
39
|
export {
|
|
37
40
|
HARNESS_ENV_KEYS,
|
|
@@ -49,6 +52,8 @@ export {
|
|
|
49
52
|
claudeUserSettingsPath,
|
|
50
53
|
deleteBranchOnPurgeEnabled,
|
|
51
54
|
getDefaultAgent,
|
|
55
|
+
getDefaultEffort,
|
|
56
|
+
getDefaultFast,
|
|
52
57
|
getDefaultModel,
|
|
53
58
|
getIssueSource,
|
|
54
59
|
getLinearApiKey,
|
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
// src/types/thinking-effort.ts
|
|
2
|
+
var THINKING_EFFORTS = [
|
|
3
|
+
"low",
|
|
4
|
+
"medium",
|
|
5
|
+
"high",
|
|
6
|
+
"xhigh",
|
|
7
|
+
"max"
|
|
8
|
+
];
|
|
9
|
+
var EFFORT_SET = new Set(THINKING_EFFORTS);
|
|
10
|
+
function normalizeThinkingEffort(value) {
|
|
11
|
+
if (typeof value !== "string") return null;
|
|
12
|
+
const v = value.trim().toLowerCase();
|
|
13
|
+
if (v === "normal") return "medium";
|
|
14
|
+
if (EFFORT_SET.has(v)) return v;
|
|
15
|
+
return null;
|
|
16
|
+
}
|
|
17
|
+
function isThinkingEffort(value) {
|
|
18
|
+
return typeof value === "string" && EFFORT_SET.has(value.trim().toLowerCase());
|
|
19
|
+
}
|
|
20
|
+
function nextThinkingEffort(current) {
|
|
21
|
+
const i = THINKING_EFFORTS.indexOf(current);
|
|
22
|
+
return THINKING_EFFORTS[(i + 1) % THINKING_EFFORTS.length];
|
|
23
|
+
}
|
|
24
|
+
function thinkingEffortBars(effort) {
|
|
25
|
+
const i = THINKING_EFFORTS.indexOf(effort);
|
|
26
|
+
return i >= 0 ? i + 1 : 3;
|
|
27
|
+
}
|
|
28
|
+
function thinkingEffortLabel(effort) {
|
|
29
|
+
switch (effort) {
|
|
30
|
+
case "low":
|
|
31
|
+
return "Low";
|
|
32
|
+
case "medium":
|
|
33
|
+
return "Medium";
|
|
34
|
+
case "high":
|
|
35
|
+
return "High";
|
|
36
|
+
case "xhigh":
|
|
37
|
+
return "Extra High";
|
|
38
|
+
case "max":
|
|
39
|
+
return "Max";
|
|
40
|
+
}
|
|
41
|
+
}
|
|
42
|
+
|
|
43
|
+
export {
|
|
44
|
+
THINKING_EFFORTS,
|
|
45
|
+
normalizeThinkingEffort,
|
|
46
|
+
isThinkingEffort,
|
|
47
|
+
nextThinkingEffort,
|
|
48
|
+
thinkingEffortBars,
|
|
49
|
+
thinkingEffortLabel
|
|
50
|
+
};
|
|
@@ -3,7 +3,7 @@ import {
|
|
|
3
3
|
ensureWorkspace,
|
|
4
4
|
removeWorkspace,
|
|
5
5
|
syncWorkspacesFromThreads
|
|
6
|
-
} from "./chunk-
|
|
6
|
+
} from "./chunk-FUCEOJFO.js";
|
|
7
7
|
import {
|
|
8
8
|
GLOBAL_WORKSPACE_ID,
|
|
9
9
|
createGlobalChat,
|
|
@@ -13,19 +13,19 @@ import {
|
|
|
13
13
|
isGlobalThread,
|
|
14
14
|
isOrchestratorThread,
|
|
15
15
|
orchestratorSessionPoisonedByBuiltins
|
|
16
|
-
} from "./chunk-
|
|
16
|
+
} from "./chunk-X6P2QVRJ.js";
|
|
17
17
|
import {
|
|
18
18
|
coordinatorSystemPrompt,
|
|
19
19
|
coordinatorTurnReminder,
|
|
20
20
|
enrichWorkspacesWithGithub,
|
|
21
21
|
ensureGlobalCoordinatorCwd
|
|
22
|
-
} from "./chunk-
|
|
22
|
+
} from "./chunk-Z2BQMXVM.js";
|
|
23
23
|
import {
|
|
24
24
|
PLAN_MODE_INSTRUCTION,
|
|
25
25
|
allAdapters,
|
|
26
26
|
getAdapter,
|
|
27
27
|
parseBrightsyCliLine
|
|
28
|
-
} from "./chunk-
|
|
28
|
+
} from "./chunk-VC7NORFX.js";
|
|
29
29
|
import {
|
|
30
30
|
fallbackTurnFailDetail,
|
|
31
31
|
formatTurnExitError,
|
|
@@ -40,7 +40,7 @@ import {
|
|
|
40
40
|
loadAppSettings,
|
|
41
41
|
resolveEffectiveIssueSource,
|
|
42
42
|
updateAdvancedSettings
|
|
43
|
-
} from "./chunk-
|
|
43
|
+
} from "./chunk-FSIK442J.js";
|
|
44
44
|
import {
|
|
45
45
|
allocateTeamName,
|
|
46
46
|
allocateTeamSlug,
|
|
@@ -71,7 +71,7 @@ import {
|
|
|
71
71
|
takenSlugsFromThread,
|
|
72
72
|
threadDisplayLabel,
|
|
73
73
|
worktreeNameFromPath
|
|
74
|
-
} from "./chunk-
|
|
74
|
+
} from "./chunk-7PCTK4WO.js";
|
|
75
75
|
import {
|
|
76
76
|
appendMessage,
|
|
77
77
|
createEmptyThread,
|
|
@@ -83,7 +83,7 @@ import {
|
|
|
83
83
|
updateThread,
|
|
84
84
|
withThreadLock,
|
|
85
85
|
writeThread
|
|
86
|
-
} from "./chunk-
|
|
86
|
+
} from "./chunk-ENSD62HW.js";
|
|
87
87
|
import {
|
|
88
88
|
loadRepoSettings,
|
|
89
89
|
loadWorkspaceSettings,
|
|
@@ -459,9 +459,9 @@ async function spawnAgentTurn(thread, input, onEvent) {
|
|
|
459
459
|
`Cannot spawn ${thread.agent}: thread ${thread.id} has no worktreePath`
|
|
460
460
|
);
|
|
461
461
|
}
|
|
462
|
-
const { isGlobalThread: isGlobalThread2 } = await import("./global-workspace-
|
|
462
|
+
const { isGlobalThread: isGlobalThread2 } = await import("./global-workspace-SNN45OCN.js");
|
|
463
463
|
if (isGlobalThread2(thread)) {
|
|
464
|
-
const { ensureGlobalCoordinatorCwd: ensureGlobalCoordinatorCwd2 } = await import("./coordinator-prompt-
|
|
464
|
+
const { ensureGlobalCoordinatorCwd: ensureGlobalCoordinatorCwd2 } = await import("./coordinator-prompt-BHXBQRPM.js");
|
|
465
465
|
ensureGlobalCoordinatorCwd2();
|
|
466
466
|
}
|
|
467
467
|
const adapter = getAdapter(thread.agent);
|
|
@@ -631,6 +631,31 @@ function formatWorktreeDirective(thread, opts) {
|
|
|
631
631
|
"- Prefer a draft PR first: `gh pr create --draft -R <origin-owner/name>` (or update via `gh pr edit -R \u2026`) once the change set is coherent. Resolve `<origin-owner/name>` with `git remote get-url origin` in this worktree \u2014 never from `upstream`. Mark ready for review only when asked. Title/body must reflect the change purpose, not the worktree name."
|
|
632
632
|
);
|
|
633
633
|
}
|
|
634
|
+
lines.push("");
|
|
635
|
+
lines.push(
|
|
636
|
+
"Short git requests from the Sideboard UI are complete instructions \u2014 expand them using the rules above without asking for clarification:"
|
|
637
|
+
);
|
|
638
|
+
lines.push(
|
|
639
|
+
'- "Commit and push." \u2192 commit any uncommitted work with a purpose-stating message, then push to origin (updates an existing PR if one is linked).'
|
|
640
|
+
);
|
|
641
|
+
lines.push(
|
|
642
|
+
'- "Commit, push, and open a draft PR." \u2192 commit, push, then create a draft PR with `gh pr create --draft -R \u2026` (title/body from the change purpose).'
|
|
643
|
+
);
|
|
644
|
+
lines.push(
|
|
645
|
+
'- "Commit, push, and open a PR in the browser." \u2192 commit, push, then `gh pr create --web -R \u2026`.'
|
|
646
|
+
);
|
|
647
|
+
lines.push(
|
|
648
|
+
'- "Fix CI: <name>." \u2192 investigate that failing check, fix it, commit, and push.'
|
|
649
|
+
);
|
|
650
|
+
lines.push(
|
|
651
|
+
'- "Update the branch." / "Fix merge conflicts." \u2192 sync with the PR base (merge or rebase), resolve conflicts carefully, commit, and push until the PR is mergeable.'
|
|
652
|
+
);
|
|
653
|
+
lines.push(
|
|
654
|
+
'- "Address review comments." \u2192 read PR review feedback, make the requested changes, commit, and push.'
|
|
655
|
+
);
|
|
656
|
+
lines.push(
|
|
657
|
+
'- "Merge PR." \u2192 merge this thread\'s open pull request with `gh pr merge` (respect repo defaults / squash vs merge); do not force-push main/master.'
|
|
658
|
+
);
|
|
634
659
|
return lines.join("\n");
|
|
635
660
|
}
|
|
636
661
|
function formatArtifactDirective() {
|
|
@@ -2585,6 +2610,7 @@ async function createThread(input, onSetupLine) {
|
|
|
2585
2610
|
agent: input.agent,
|
|
2586
2611
|
autonomy: input.autonomy ?? "default",
|
|
2587
2612
|
model: input.model ?? null,
|
|
2613
|
+
effort: input.effort ?? "high",
|
|
2588
2614
|
fast: Boolean(input.fast),
|
|
2589
2615
|
planMode: Boolean(input.planMode),
|
|
2590
2616
|
attachments: input.attachments ?? [],
|
|
@@ -2614,7 +2640,7 @@ async function createThread(input, onSetupLine) {
|
|
|
2614
2640
|
return readThread(thread.id) ?? thread;
|
|
2615
2641
|
}
|
|
2616
2642
|
async function listLinearIssues(agent, repoPath) {
|
|
2617
|
-
const { getAdapter: getAdapter2 } = await import("./agents-
|
|
2643
|
+
const { getAdapter: getAdapter2 } = await import("./agents-T3EA7GZV.js");
|
|
2618
2644
|
await requireAgent(agent, { requireLinear: true });
|
|
2619
2645
|
const adapter = getAdapter2(agent);
|
|
2620
2646
|
if (!adapter.listLinearIssues) {
|
|
@@ -2695,7 +2721,8 @@ function createChatTab(input) {
|
|
|
2695
2721
|
...binding,
|
|
2696
2722
|
agent: input.agent ?? from.agent,
|
|
2697
2723
|
model: input.model !== void 0 ? input.model : input.agent && input.agent !== from.agent ? null : from.model,
|
|
2698
|
-
|
|
2724
|
+
effort: input.effort !== void 0 ? input.effort : from.effort,
|
|
2725
|
+
fast: input.fast !== void 0 ? Boolean(input.fast) : from.fast,
|
|
2699
2726
|
planMode: from.planMode,
|
|
2700
2727
|
autonomy: input.autonomy ?? from.autonomy,
|
|
2701
2728
|
attachments: input.attachments ?? [],
|
|
@@ -2734,6 +2761,7 @@ async function forkThreadWorktree(input, onSetupLine) {
|
|
|
2734
2761
|
agent: input.agent ?? from.agent,
|
|
2735
2762
|
autonomy: from.autonomy,
|
|
2736
2763
|
model: from.model,
|
|
2764
|
+
effort: from.effort,
|
|
2737
2765
|
fast: from.fast,
|
|
2738
2766
|
planMode: from.planMode,
|
|
2739
2767
|
title: input.title?.trim() || void 0,
|
|
@@ -2834,7 +2862,7 @@ async function adoptThread(input) {
|
|
|
2834
2862
|
messages: input.messages ?? []
|
|
2835
2863
|
});
|
|
2836
2864
|
writeThread(thread);
|
|
2837
|
-
const { ensureWorkspace: ensureWorkspace2 } = await import("./workspaces-
|
|
2865
|
+
const { ensureWorkspace: ensureWorkspace2 } = await import("./workspaces-AUYIJ64Z.js");
|
|
2838
2866
|
await ensureWorkspace2(repoPath);
|
|
2839
2867
|
return thread;
|
|
2840
2868
|
}
|
|
@@ -3393,7 +3421,7 @@ var Orchestrator = class {
|
|
|
3393
3421
|
orphans: orphans.map((o) => ({ path: o.path, repoPath: o.repoPath }))
|
|
3394
3422
|
});
|
|
3395
3423
|
}
|
|
3396
|
-
const { autoCleanupOrphansEnabled } = await import("./app-settings-
|
|
3424
|
+
const { autoCleanupOrphansEnabled } = await import("./app-settings-ZKVZHJPQ.js");
|
|
3397
3425
|
if (autoCleanupOrphansEnabled() && shouldRunWorktreeCleanup() && orphans.length > 0) {
|
|
3398
3426
|
await cleanupOrphanWorktrees({ repoPaths });
|
|
3399
3427
|
}
|
|
@@ -3420,7 +3448,7 @@ var Orchestrator = class {
|
|
|
3420
3448
|
});
|
|
3421
3449
|
});
|
|
3422
3450
|
this.emit({ type: "status_changed", threadId: thread.id, status: thread.status });
|
|
3423
|
-
const { autoRunAfterSetupEnabled } = await import("./app-settings-
|
|
3451
|
+
const { autoRunAfterSetupEnabled } = await import("./app-settings-ZKVZHJPQ.js");
|
|
3424
3452
|
if (autoRunAfterSetupEnabled()) {
|
|
3425
3453
|
try {
|
|
3426
3454
|
await this.startDev(thread.id);
|
|
@@ -3666,7 +3694,7 @@ var Orchestrator = class {
|
|
|
3666
3694
|
});
|
|
3667
3695
|
const artifactDirective = isBrightsy ? null : formatArtifactDirective();
|
|
3668
3696
|
const settings = loadWorkspaceSettings(fresh.worktreePath, fresh.repoPath);
|
|
3669
|
-
const { autoRenameBranchEnabled } = await import("./app-settings-
|
|
3697
|
+
const { autoRenameBranchEnabled } = await import("./app-settings-ZKVZHJPQ.js");
|
|
3670
3698
|
const renameBranchDirective = !isBrightsy && !isOrchestration && autoRenameBranchEnabled() ? formatRenameBranchDirective(fresh, {
|
|
3671
3699
|
customPrompt: settings?.prompts?.renameBranch
|
|
3672
3700
|
}) : null;
|
|
@@ -4276,6 +4304,7 @@ var Orchestrator = class {
|
|
|
4276
4304
|
const thread = this.requireThread(threadRef);
|
|
4277
4305
|
const next = {};
|
|
4278
4306
|
if (patch.autonomy !== void 0) next.autonomy = patch.autonomy;
|
|
4307
|
+
if (patch.effort !== void 0) next.effort = patch.effort;
|
|
4279
4308
|
if (patch.fast !== void 0) next.fast = patch.fast;
|
|
4280
4309
|
if (patch.planMode !== void 0) next.planMode = patch.planMode;
|
|
4281
4310
|
if (patch.model !== void 0) next.model = patch.model;
|
|
@@ -4377,7 +4406,7 @@ var Orchestrator = class {
|
|
|
4377
4406
|
await runArchiveScript(thread.repoPath, thread.worktreePath);
|
|
4378
4407
|
} catch {
|
|
4379
4408
|
}
|
|
4380
|
-
const { deleteBranchOnPurgeEnabled } = await import("./app-settings-
|
|
4409
|
+
const { deleteBranchOnPurgeEnabled } = await import("./app-settings-ZKVZHJPQ.js");
|
|
4381
4410
|
const deleteBranch = opts?.deleteBranch ?? deleteBranchOnPurgeEnabled();
|
|
4382
4411
|
await removeWorktree(thread.repoPath, thread.worktreePath, {
|
|
4383
4412
|
deleteBranch: deleteBranch ? thread.branchName : void 0
|
|
@@ -4396,7 +4425,7 @@ var Orchestrator = class {
|
|
|
4396
4425
|
return setStatus(thread.id, "idle");
|
|
4397
4426
|
}
|
|
4398
4427
|
if (!existsSync11(thread.worktreePath)) {
|
|
4399
|
-
const { createThreadWorktree: createThreadWorktree2 } = await import("./worktree-
|
|
4428
|
+
const { createThreadWorktree: createThreadWorktree2 } = await import("./worktree-N4PRV4V3.js");
|
|
4400
4429
|
const { execa: execa6 } = await import("execa");
|
|
4401
4430
|
const slug = thread.worktreePath.split("/").pop();
|
|
4402
4431
|
const dest = thread.worktreePath;
|
|
@@ -4453,6 +4482,7 @@ async function startOrchestration(opts) {
|
|
|
4453
4482
|
agent: opts.agent,
|
|
4454
4483
|
autonomy: opts.autonomy,
|
|
4455
4484
|
model: opts.model,
|
|
4485
|
+
effort: opts.effort,
|
|
4456
4486
|
fast: opts.fast,
|
|
4457
4487
|
planMode: opts.planMode,
|
|
4458
4488
|
attachments: opts.attachments
|
|
@@ -4470,6 +4500,7 @@ async function startOrchestration(opts) {
|
|
|
4470
4500
|
title,
|
|
4471
4501
|
autonomy: opts.autonomy,
|
|
4472
4502
|
model: opts.model,
|
|
4503
|
+
effort: opts.effort,
|
|
4473
4504
|
fast: opts.fast,
|
|
4474
4505
|
planMode: opts.planMode,
|
|
4475
4506
|
attachments: opts.attachments
|
|
@@ -4479,7 +4510,7 @@ async function startOrchestration(opts) {
|
|
|
4479
4510
|
sourceRef: "default",
|
|
4480
4511
|
...createOpts
|
|
4481
4512
|
}).catch(async () => {
|
|
4482
|
-
const { resolveDefaultBranch: resolveDefaultBranch2, resolveRepoRoot: resolveRepoRoot2 } = await import("./worktree-
|
|
4513
|
+
const { resolveDefaultBranch: resolveDefaultBranch2, resolveRepoRoot: resolveRepoRoot2 } = await import("./worktree-N4PRV4V3.js");
|
|
4483
4514
|
const repo = await resolveRepoRoot2(repoPath);
|
|
4484
4515
|
const def = await resolveDefaultBranch2(repo);
|
|
4485
4516
|
return createThread({
|
|
@@ -4489,7 +4520,7 @@ async function startOrchestration(opts) {
|
|
|
4489
4520
|
repoPath: repo
|
|
4490
4521
|
});
|
|
4491
4522
|
});
|
|
4492
|
-
const { updateThread: upd } = await import("./thread-store-
|
|
4523
|
+
const { updateThread: upd } = await import("./thread-store-EHROA3VZ.js");
|
|
4493
4524
|
const updated = upd(thread.id, {
|
|
4494
4525
|
sourceType: "orchestration",
|
|
4495
4526
|
sourceRef: goal
|
|
@@ -1,3 +1,6 @@
|
|
|
1
|
+
import {
|
|
2
|
+
normalizeThinkingEffort
|
|
3
|
+
} from "./chunk-77WWLBCI.js";
|
|
1
4
|
import {
|
|
2
5
|
threadFilePath,
|
|
3
6
|
threadLockPath,
|
|
@@ -18,10 +21,17 @@ import lockfile from "proper-lockfile";
|
|
|
18
21
|
function nowIso() {
|
|
19
22
|
return (/* @__PURE__ */ new Date()).toISOString();
|
|
20
23
|
}
|
|
24
|
+
function resolveThreadEffort(raw) {
|
|
25
|
+
const fromField = normalizeThinkingEffort(raw.effort);
|
|
26
|
+
if (fromField) return fromField;
|
|
27
|
+
if (raw.fast) return "low";
|
|
28
|
+
return "high";
|
|
29
|
+
}
|
|
21
30
|
function normalizeThread(raw) {
|
|
22
31
|
return {
|
|
23
32
|
...raw,
|
|
24
33
|
model: raw.model ?? null,
|
|
34
|
+
effort: resolveThreadEffort(raw),
|
|
25
35
|
fast: Boolean(raw.fast),
|
|
26
36
|
planMode: Boolean(raw.planMode),
|
|
27
37
|
autonomy: raw.autonomy ?? "default",
|
|
@@ -40,6 +50,7 @@ function createEmptyThread(partial) {
|
|
|
40
50
|
sessionId: partial.sessionId ?? null,
|
|
41
51
|
autonomy: partial.autonomy ?? "default",
|
|
42
52
|
model: partial.model ?? null,
|
|
53
|
+
effort: partial.effort ?? "high",
|
|
43
54
|
fast: partial.fast ?? false,
|
|
44
55
|
planMode: partial.planMode ?? false,
|
|
45
56
|
sourceIsFork: partial.sourceIsFork ?? false,
|
|
@@ -142,6 +153,7 @@ function findThreadByRef(ref) {
|
|
|
142
153
|
}
|
|
143
154
|
|
|
144
155
|
export {
|
|
156
|
+
resolveThreadEffort,
|
|
145
157
|
normalizeThread,
|
|
146
158
|
createEmptyThread,
|
|
147
159
|
withThreadLock,
|
|
@@ -1,3 +1,6 @@
|
|
|
1
|
+
import {
|
|
2
|
+
normalizeThinkingEffort
|
|
3
|
+
} from "./chunk-77WWLBCI.js";
|
|
1
4
|
import {
|
|
2
5
|
appDataDir
|
|
3
6
|
} from "./chunk-M37RITA6.js";
|
|
@@ -82,6 +85,12 @@ function normalizeDefaults(raw) {
|
|
|
82
85
|
const model = source.model.trim();
|
|
83
86
|
if (model) out.model = model;
|
|
84
87
|
}
|
|
88
|
+
if (normalizeThinkingEffort(source.effort)) {
|
|
89
|
+
out.effort = normalizeThinkingEffort(source.effort);
|
|
90
|
+
}
|
|
91
|
+
if (typeof source.fast === "boolean") {
|
|
92
|
+
out.fast = source.fast;
|
|
93
|
+
}
|
|
85
94
|
return out;
|
|
86
95
|
}
|
|
87
96
|
function normalizeAdvanced(raw) {
|
|
@@ -268,6 +277,21 @@ function updateDefaultsSettings(patch) {
|
|
|
268
277
|
defaults.model = patch.model.trim();
|
|
269
278
|
}
|
|
270
279
|
}
|
|
280
|
+
if ("effort" in patch) {
|
|
281
|
+
if (patch.effort == null) {
|
|
282
|
+
delete defaults.effort;
|
|
283
|
+
} else {
|
|
284
|
+
const effort = normalizeThinkingEffort(patch.effort);
|
|
285
|
+
if (effort) defaults.effort = effort;
|
|
286
|
+
}
|
|
287
|
+
}
|
|
288
|
+
if ("fast" in patch) {
|
|
289
|
+
if (patch.fast == null) {
|
|
290
|
+
delete defaults.fast;
|
|
291
|
+
} else {
|
|
292
|
+
defaults.fast = Boolean(patch.fast);
|
|
293
|
+
}
|
|
294
|
+
}
|
|
271
295
|
return saveAppSettings({ ...current, defaults });
|
|
272
296
|
}
|
|
273
297
|
function getDefaultAgent(settings = loadAppSettings()) {
|
|
@@ -277,10 +301,18 @@ function getDefaultModel(settings = loadAppSettings()) {
|
|
|
277
301
|
const model = settings.defaults.model?.trim();
|
|
278
302
|
return model || null;
|
|
279
303
|
}
|
|
304
|
+
function getDefaultEffort(settings = loadAppSettings()) {
|
|
305
|
+
return normalizeThinkingEffort(settings.defaults.effort) ?? "high";
|
|
306
|
+
}
|
|
307
|
+
function getDefaultFast(settings = loadAppSettings()) {
|
|
308
|
+
return settings.defaults.fast === true;
|
|
309
|
+
}
|
|
280
310
|
function resolveThreadDefaults(settings = loadAppSettings()) {
|
|
281
311
|
return {
|
|
282
312
|
agent: getDefaultAgent(settings),
|
|
283
|
-
model: getDefaultModel(settings)
|
|
313
|
+
model: getDefaultModel(settings),
|
|
314
|
+
effort: getDefaultEffort(settings),
|
|
315
|
+
fast: getDefaultFast(settings)
|
|
284
316
|
};
|
|
285
317
|
}
|
|
286
318
|
function isLinearConnected(settings = loadAppSettings()) {
|
|
@@ -411,6 +443,8 @@ export {
|
|
|
411
443
|
updateDefaultsSettings,
|
|
412
444
|
getDefaultAgent,
|
|
413
445
|
getDefaultModel,
|
|
446
|
+
getDefaultEffort,
|
|
447
|
+
getDefaultFast,
|
|
414
448
|
resolveThreadDefaults,
|
|
415
449
|
isLinearConnected,
|
|
416
450
|
getIssueSource,
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import {
|
|
2
2
|
isGlobalRepoPath
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-X6P2QVRJ.js";
|
|
4
4
|
import {
|
|
5
5
|
ensureGhPreferOrigin,
|
|
6
6
|
resolveRepoRoot
|
|
7
|
-
} from "./chunk-
|
|
7
|
+
} from "./chunk-7PCTK4WO.js";
|
|
8
8
|
import {
|
|
9
9
|
appDataDir
|
|
10
10
|
} from "./chunk-M37RITA6.js";
|
|
@@ -15,7 +15,7 @@ import {
|
|
|
15
15
|
claudeChromeEnabled,
|
|
16
16
|
loadAppSettings,
|
|
17
17
|
resolveClaudeExecutable
|
|
18
|
-
} from "./chunk-
|
|
18
|
+
} from "./chunk-FSIK442J.js";
|
|
19
19
|
import {
|
|
20
20
|
ensureAgentPath,
|
|
21
21
|
run
|
|
@@ -798,7 +798,7 @@ var claudeAdapter = {
|
|
|
798
798
|
);
|
|
799
799
|
}
|
|
800
800
|
const mode = permissionMode(thread);
|
|
801
|
-
const { isOrchestratorThread } = await import("./global-workspace-
|
|
801
|
+
const { isOrchestratorThread } = await import("./global-workspace-SNN45OCN.js");
|
|
802
802
|
const isOrchestrator = isOrchestratorThread(thread);
|
|
803
803
|
const injectedServers = await buildInjectedMcpServers({
|
|
804
804
|
includeSideboard: true,
|
|
@@ -851,9 +851,8 @@ var claudeAdapter = {
|
|
|
851
851
|
if (thread.model) {
|
|
852
852
|
args.push("--model", thread.model);
|
|
853
853
|
}
|
|
854
|
-
|
|
855
|
-
|
|
856
|
-
}
|
|
854
|
+
const effort = thread.effort ?? (thread.fast ? "low" : "high");
|
|
855
|
+
args.push("--effort", effort);
|
|
857
856
|
if (sessionId) {
|
|
858
857
|
args.push("--resume", sessionId);
|
|
859
858
|
}
|
|
@@ -1344,6 +1343,7 @@ var cursorAdapter = {
|
|
|
1344
1343
|
cwd: thread.worktreePath,
|
|
1345
1344
|
agentId,
|
|
1346
1345
|
model: thread.model,
|
|
1346
|
+
effort: thread.effort,
|
|
1347
1347
|
fast: thread.fast,
|
|
1348
1348
|
planMode: thread.planMode,
|
|
1349
1349
|
apiKey
|
|
@@ -1,17 +1,17 @@
|
|
|
1
1
|
import {
|
|
2
2
|
ensureGlobalCoordinatorCwd
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-Z2BQMXVM.js";
|
|
4
4
|
import {
|
|
5
5
|
allocateTeamName,
|
|
6
6
|
takenSlugsFromThread,
|
|
7
7
|
teamSlugFromName
|
|
8
|
-
} from "./chunk-
|
|
8
|
+
} from "./chunk-7PCTK4WO.js";
|
|
9
9
|
import {
|
|
10
10
|
createEmptyThread,
|
|
11
11
|
listThreads,
|
|
12
12
|
updateThread,
|
|
13
13
|
writeThread
|
|
14
|
-
} from "./chunk-
|
|
14
|
+
} from "./chunk-ENSD62HW.js";
|
|
15
15
|
import {
|
|
16
16
|
globalAgentCwd
|
|
17
17
|
} from "./chunk-M37RITA6.js";
|
|
@@ -122,6 +122,7 @@ function createGlobalChat(opts) {
|
|
|
122
122
|
agent: opts.agent,
|
|
123
123
|
autonomy: opts.autonomy ?? "default",
|
|
124
124
|
model: opts.model ?? null,
|
|
125
|
+
effort: opts.effort ?? "high",
|
|
125
126
|
fast: Boolean(opts.fast),
|
|
126
127
|
planMode: Boolean(opts.planMode),
|
|
127
128
|
attachments: opts.attachments ?? [],
|
|
@@ -6,9 +6,10 @@ import {
|
|
|
6
6
|
enrichWorkspacesWithGithub,
|
|
7
7
|
ensureGlobalCoordinatorCwd,
|
|
8
8
|
formatWorkspaceInventory
|
|
9
|
-
} from "./chunk-
|
|
10
|
-
import "./chunk-
|
|
11
|
-
import "./chunk-
|
|
9
|
+
} from "./chunk-Z2BQMXVM.js";
|
|
10
|
+
import "./chunk-7PCTK4WO.js";
|
|
11
|
+
import "./chunk-ENSD62HW.js";
|
|
12
|
+
import "./chunk-77WWLBCI.js";
|
|
12
13
|
import "./chunk-M37RITA6.js";
|
|
13
14
|
import "./chunk-AJ6ROGD7.js";
|
|
14
15
|
export {
|
|
@@ -11,10 +11,11 @@ import {
|
|
|
11
11
|
orchestrationTitleNeedsSoccerNickname,
|
|
12
12
|
orchestratorSessionPoisonedByBuiltins,
|
|
13
13
|
takenTeamSlugsForOrchestration
|
|
14
|
-
} from "./chunk-
|
|
15
|
-
import "./chunk-
|
|
16
|
-
import "./chunk-
|
|
17
|
-
import "./chunk-
|
|
14
|
+
} from "./chunk-X6P2QVRJ.js";
|
|
15
|
+
import "./chunk-Z2BQMXVM.js";
|
|
16
|
+
import "./chunk-7PCTK4WO.js";
|
|
17
|
+
import "./chunk-ENSD62HW.js";
|
|
18
|
+
import "./chunk-77WWLBCI.js";
|
|
18
19
|
import {
|
|
19
20
|
globalAgentCwd
|
|
20
21
|
} from "./chunk-M37RITA6.js";
|