@sideboard-ai/core 0.1.349 → 0.1.350

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 (78) hide show
  1. package/dist/{abletime-CGFJZB7L.js → abletime-TX7BTTR2.js} +5 -5
  2. package/dist/{abletime-3HRWLQZJ.js → abletime-URSRZW7P.js} +4 -4
  3. package/dist/{abletime-oauth-QNJQLHR4.js → abletime-oauth-QS3WPSCC.js} +3 -3
  4. package/dist/{abletime-oauth-JQDSH5OL.js → abletime-oauth-SL3NMNEC.js} +4 -4
  5. package/dist/{abletime-rest-TANL5TMY.js → abletime-rest-GGQLUO55.js} +3 -3
  6. package/dist/{abletime-rest-UQA2CRZN.js → abletime-rest-JZU6JJCV.js} +4 -4
  7. package/dist/agents/acp-runner.cjs +491 -0
  8. package/dist/agents/acp-runner.d.cts +46 -0
  9. package/dist/agents/acp-runner.d.ts +46 -0
  10. package/dist/agents/acp-runner.js +323 -0
  11. package/dist/{agents-DMPBFF3F.js → agents-P5QIV24I.js} +37 -7
  12. package/dist/{agents-AZ2PV6XP.js → agents-RGAV5OHD.js} +42 -11
  13. package/dist/{app-settings-SNOPJ7P5.js → app-settings-IA7ZZKWQ.js} +2 -2
  14. package/dist/{app-settings-PPIMYJKS.js → app-settings-XILTSD6L.js} +1 -1
  15. package/dist/{chunk-Q4I6KDOL.js → chunk-2MESZ5XR.js} +60 -39
  16. package/dist/{chunk-RUIHNWRV.js → chunk-37ZBEBP6.js} +6 -6
  17. package/dist/{chunk-WHMLMCPU.js → chunk-5AHWUJRT.js} +1925 -1722
  18. package/dist/{chunk-7B2OUQON.js → chunk-5TCMXEYL.js} +48 -3
  19. package/dist/{chunk-FDYMVJFU.js → chunk-5WF54R3B.js} +5 -5
  20. package/dist/{chunk-PVCECFJK.js → chunk-7ZD4OK6G.js} +1 -1
  21. package/dist/{chunk-RYPD7XWV.js → chunk-B4EFQTMP.js} +5 -5
  22. package/dist/chunk-BF6INES4.js +144 -0
  23. package/dist/{chunk-IVRWRYTH.js → chunk-BZK62VPT.js} +2 -2
  24. package/dist/{chunk-AJMERXZP.js → chunk-CCWQ65VD.js} +2 -2
  25. package/dist/{chunk-62ALWH3T.js → chunk-DL4OHDBV.js} +3 -3
  26. package/dist/{chunk-CATTIFSP.js → chunk-EZ2MUWNW.js} +3 -3
  27. package/dist/{chunk-4NXGVJA6.js → chunk-F4RFFE2H.js} +48 -3
  28. package/dist/{chunk-E77SRVVO.js → chunk-FCKTBE26.js} +1 -1
  29. package/dist/{chunk-3DBL2C45.js → chunk-FQ3JYUKI.js} +2 -2
  30. package/dist/{chunk-CEQ4Z32M.js → chunk-J4EA5SHF.js} +3 -3
  31. package/dist/{chunk-MHSBF3SO.js → chunk-LFSTOECH.js} +3 -3
  32. package/dist/{chunk-OHUAAX3O.js → chunk-M45WGODR.js} +2 -2
  33. package/dist/{chunk-MVFFLU5V.js → chunk-MANERA6F.js} +12 -5
  34. package/dist/{chunk-ZXI5DR5S.js → chunk-NDEVAA34.js} +1624 -1487
  35. package/dist/{chunk-UJMCTGV7.js → chunk-PXSWVZIL.js} +2 -2
  36. package/dist/{chunk-6RIPZ73M.js → chunk-SMSD6U3N.js} +3 -1
  37. package/dist/{chunk-RPHH4FNK.js → chunk-TCEUNSLX.js} +3 -1
  38. package/dist/chunk-TRMPDDVL.js +232 -0
  39. package/dist/{chunk-6WMNIX2U.js → chunk-UFUAIVNV.js} +9 -5
  40. package/dist/{chunk-QHXZKHUL.js → chunk-VHQ6OG3U.js} +2 -2
  41. package/dist/{chunk-WWU4SYZR.js → chunk-VL6F2KRE.js} +5 -1
  42. package/dist/{chunk-IRFBD6GU.js → chunk-W5GHFT7E.js} +71 -47
  43. package/dist/{chunk-5FUAOU3G.js → chunk-WB3G2LQO.js} +1 -1
  44. package/dist/{chunk-JCYGQKER.js → chunk-WFX4ZVSZ.js} +1 -1
  45. package/dist/{chunk-F7WP2U5I.js → chunk-WJURGCBR.js} +1 -1
  46. package/dist/chunk-YE7Z5WH3.js +142 -0
  47. package/dist/{chunk-ROXM6QZV.js → chunk-ZBSEJIOV.js} +12 -5
  48. package/dist/{conductor-NHC6X74J.js → conductor-HVOGBK63.js} +6 -5
  49. package/dist/{conductor-65VPUPOW.js → conductor-VGCXUUG6.js} +7 -6
  50. package/dist/connected-teams-2YDE2EZ2.js +1 -1
  51. package/dist/{coordinator-prompt-5GZWIVSY.js → coordinator-prompt-DPO7L2JO.js} +5 -5
  52. package/dist/{coordinator-prompt-R2PURZL3.js → coordinator-prompt-E736TJBS.js} +4 -4
  53. package/dist/{global-workspace-64KC7PST.js → global-workspace-4RDPAOTT.js} +5 -5
  54. package/dist/{global-workspace-UEECLWSX.js → global-workspace-TG2TVLUF.js} +4 -4
  55. package/dist/index.cjs +1600 -929
  56. package/dist/index.d.cts +132 -891
  57. package/dist/index.d.ts +132 -891
  58. package/dist/index.js +433 -207
  59. package/dist/{linear-PKYJH4WK.js → linear-E3BX5PX5.js} +2 -2
  60. package/dist/{linear-MIJO6DCV.js → linear-WG23LBCX.js} +3 -3
  61. package/dist/{linear-list-JPQ27RXG.js → linear-list-OINZWVV5.js} +1 -1
  62. package/dist/{linear-list-N57PR6JM.js → linear-list-VU47BNUV.js} +1 -1
  63. package/dist/mcp/run-stdio.cjs +1097 -720
  64. package/dist/mcp/run-stdio.js +32 -24
  65. package/dist/{optional-cli-4GTEDEYJ.js → optional-cli-K6HX2X5O.js} +4 -3
  66. package/dist/{optional-cli-RPJIQBDX.js → optional-cli-SA3EQYML.js} +6 -5
  67. package/dist/{orchestrator-Y5PYSMR6.js → orchestrator-3I2FLEZL.js} +17 -15
  68. package/dist/{orchestrator-I5G5A5BV.js → orchestrator-QDHZ56LA.js} +11 -10
  69. package/dist/thread-CJRchYLj.d.cts +856 -0
  70. package/dist/thread-CJRchYLj.d.ts +856 -0
  71. package/dist/{thread-store-HZ4U4OXB.js → thread-store-4YTOV2HL.js} +3 -3
  72. package/dist/{thread-store-QKNU5CHM.js → thread-store-LME2ICZP.js} +2 -2
  73. package/dist/{workspaces-6TIM2TM2.js → workspaces-4PA24IX6.js} +4 -4
  74. package/dist/{workspaces-I2EHNTFE.js → workspaces-6TMYV4N2.js} +5 -5
  75. package/dist/{worktree-7JFYDNUX.js → worktree-4ATMCYIE.js} +3 -3
  76. package/dist/{worktree-M2GJGK2P.js → worktree-DA6SKIU5.js} +4 -4
  77. package/package.json +3 -3
  78. /package/dist/{chunk-XOEKCE6L.js → chunk-OHXNGBC4.js} +0 -0
@@ -2,11 +2,11 @@ import {
2
2
  OPTIONAL_SERVICES,
3
3
  isOptionalServiceId,
4
4
  optionalServiceSpec
5
- } from "./chunk-IVRWRYTH.js";
5
+ } from "./chunk-BZK62VPT.js";
6
6
  import {
7
7
  installNpmGlobalPackage,
8
8
  whichOnPath
9
- } from "./chunk-4NXGVJA6.js";
9
+ } from "./chunk-F4RFFE2H.js";
10
10
  import {
11
11
  enrichPathWithNpmGlobalBin
12
12
  } from "./chunk-R4W4VQJZ.js";
@@ -9,7 +9,7 @@ import {
9
9
  isOrchestratorCapableAgent,
10
10
  normalizeThinkingEffort,
11
11
  updateAdvancedSettings
12
- } from "./chunk-WWU4SYZR.js";
12
+ } from "./chunk-VL6F2KRE.js";
13
13
  import {
14
14
  writePrivateFile
15
15
  } from "./chunk-NSTQ6QKD.js";
@@ -1647,6 +1647,7 @@ function normalizeThread(raw) {
1647
1647
  return {
1648
1648
  ...raw,
1649
1649
  model: raw.model ?? null,
1650
+ acpHarness: raw.acpHarness === "gemini" || raw.acpHarness === "copilot" ? raw.acpHarness : void 0,
1650
1651
  effort: resolveThreadEffort(raw),
1651
1652
  fast: Boolean(raw.fast),
1652
1653
  planMode: Boolean(raw.planMode),
@@ -1735,6 +1736,7 @@ function createEmptyThread(partial) {
1735
1736
  worktreePath: partial.worktreePath,
1736
1737
  repoPath: partial.repoPath,
1737
1738
  agent: partial.agent,
1739
+ ...partial.acpHarness === "gemini" || partial.acpHarness === "copilot" ? { acpHarness: partial.acpHarness } : {},
1738
1740
  lastError: null,
1739
1741
  agentPid: null,
1740
1742
  agentPidStartedAt: null,
@@ -10,7 +10,7 @@ import {
10
10
  isOrchestratorCapableAgent,
11
11
  normalizeThinkingEffort,
12
12
  updateAdvancedSettings
13
- } from "./chunk-6WMNIX2U.js";
13
+ } from "./chunk-UFUAIVNV.js";
14
14
  import {
15
15
  writePrivateFile
16
16
  } from "./chunk-JT7R45JB.js";
@@ -1666,6 +1666,7 @@ function normalizeThread(raw) {
1666
1666
  return {
1667
1667
  ...raw,
1668
1668
  model: raw.model ?? null,
1669
+ acpHarness: raw.acpHarness === "gemini" || raw.acpHarness === "copilot" ? raw.acpHarness : void 0,
1669
1670
  effort: resolveThreadEffort(raw),
1670
1671
  fast: Boolean(raw.fast),
1671
1672
  planMode: Boolean(raw.planMode),
@@ -1754,6 +1755,7 @@ function createEmptyThread(partial) {
1754
1755
  worktreePath: partial.worktreePath,
1755
1756
  repoPath: partial.repoPath,
1756
1757
  agent: partial.agent,
1758
+ ...partial.acpHarness === "gemini" || partial.acpHarness === "copilot" ? { acpHarness: partial.acpHarness } : {},
1757
1759
  lastError: null,
1758
1760
  agentPid: null,
1759
1761
  agentPidStartedAt: null,
@@ -0,0 +1,232 @@
1
+ // src/agents/acp-protocol.ts
2
+ var ACP_PROTOCOL_VERSION = 1;
3
+ var ACP_REPLAY_CHAR_BUDGET = 16e3;
4
+ var PLAN_READ_TOOL_KINDS = /* @__PURE__ */ new Set(["read", "search", "think"]);
5
+ function acpStdioServerFromEntry(name, entry) {
6
+ const trimmed = name.trim();
7
+ if (!trimmed) return null;
8
+ const type = typeof entry.type === "string" ? entry.type : "";
9
+ if (type === "http" || type === "sse" || typeof entry.url === "string") return null;
10
+ const command = typeof entry.command === "string" ? entry.command.trim() : "";
11
+ if (!command) return null;
12
+ const args = Array.isArray(entry.args) ? entry.args.filter((item) => typeof item === "string") : [];
13
+ const env = [];
14
+ const rawEnv = entry.env;
15
+ if (rawEnv && typeof rawEnv === "object" && !Array.isArray(rawEnv)) {
16
+ for (const [key, value] of Object.entries(rawEnv)) {
17
+ if (key === "ELECTRON_RUN_AS_NODE" || typeof value !== "string") continue;
18
+ env.push({ name: key, value });
19
+ }
20
+ }
21
+ return { name: trimmed, command, args, env };
22
+ }
23
+ function acpUserStdioServers(entries, taken) {
24
+ const out = [];
25
+ for (const [name, entry] of Object.entries(entries)) {
26
+ if (taken.has(name.trim())) continue;
27
+ const server = acpStdioServerFromEntry(name, entry);
28
+ if (server) out.push(server);
29
+ }
30
+ return out;
31
+ }
32
+ function toAcpMcpServers(servers) {
33
+ return servers.map((server) => ({
34
+ name: server.name,
35
+ command: server.command,
36
+ args: server.args ?? [],
37
+ env: Object.entries(server.env ?? {}).map(([name, value]) => ({ name, value }))
38
+ }));
39
+ }
40
+ function acpSessionOpenPlan(input) {
41
+ if (input.loadSession && input.sessionId?.trim()) return "load";
42
+ return "new";
43
+ }
44
+ function acpPriorTranscript(messages) {
45
+ const rows = [];
46
+ for (const message of messages) {
47
+ if (message.role !== "user" && message.role !== "agent" && message.role !== "summary") {
48
+ continue;
49
+ }
50
+ const text = message.text?.trim() ?? "";
51
+ if (!text) continue;
52
+ rows.push({ role: message.role, text });
53
+ }
54
+ const last = rows[rows.length - 1];
55
+ if (last?.role === "user") rows.pop();
56
+ return rows;
57
+ }
58
+ function buildAcpReplayPrompt(prior, prompt) {
59
+ if (prior.length === 0) return prompt;
60
+ const lines = prior.map((turn) => {
61
+ const who = turn.role === "user" ? "User" : turn.role === "agent" ? "Assistant" : "Note";
62
+ return `${who}:
63
+ ${turn.text}`;
64
+ });
65
+ let body = lines.join("\n\n");
66
+ if (body.length > ACP_REPLAY_CHAR_BUDGET) {
67
+ body = `\u2026(earlier turns omitted)
68
+
69
+ ${body.slice(body.length - ACP_REPLAY_CHAR_BUDGET)}`;
70
+ }
71
+ return [
72
+ "Previous conversation (this harness cannot load a saved session, so Sideboard replayed the transcript):",
73
+ body,
74
+ "Current request:",
75
+ prompt
76
+ ].join("\n\n");
77
+ }
78
+ function selectAcpPermissionOption(options, mode, toolKind) {
79
+ const allowAlways = options.find((option) => option.kind === "allow_always");
80
+ const allowOnce = options.find((option) => option.kind === "allow_once");
81
+ const rejectOnce = options.find((option) => option.kind === "reject_once");
82
+ const rejectAlways = options.find((option) => option.kind === "reject_always");
83
+ if (mode === "plan") {
84
+ if (toolKind && PLAN_READ_TOOL_KINDS.has(toolKind)) {
85
+ const allow2 = allowOnce ?? allowAlways;
86
+ if (allow2) return { outcome: "selected", optionId: allow2.optionId };
87
+ }
88
+ const reject2 = rejectOnce ?? rejectAlways;
89
+ if (reject2) return { outcome: "selected", optionId: reject2.optionId };
90
+ return { outcome: "cancelled" };
91
+ }
92
+ if (mode === "full") {
93
+ const allow2 = allowAlways ?? allowOnce;
94
+ if (allow2) return { outcome: "selected", optionId: allow2.optionId };
95
+ }
96
+ const allow = allowOnce ?? allowAlways;
97
+ if (allow) return { outcome: "selected", optionId: allow.optionId };
98
+ const reject = rejectOnce ?? rejectAlways;
99
+ if (reject) return { outcome: "selected", optionId: reject.optionId };
100
+ return { outcome: "cancelled" };
101
+ }
102
+ function clip(text, max = 8e3) {
103
+ if (text.length <= max) return text;
104
+ return `${text.slice(0, max)}
105
+ \u2026(${text.length - max} more characters)`;
106
+ }
107
+ function blockToText(block) {
108
+ if (!block || typeof block !== "object") return "";
109
+ const record = block;
110
+ if (record.type === "text" && typeof record.text === "string") return record.text;
111
+ if (typeof record.path === "string" && (record.type === "diff" || record.type === "resource")) {
112
+ return record.path;
113
+ }
114
+ return "";
115
+ }
116
+ function acpContentToText(content) {
117
+ if (typeof content === "string") return content;
118
+ const blocks = Array.isArray(content) ? content : content ? [content] : [];
119
+ return blocks.map(blockToText).filter(Boolean).join("\n");
120
+ }
121
+ function asRecord(value) {
122
+ if (!value || typeof value !== "object" || Array.isArray(value)) return null;
123
+ return value;
124
+ }
125
+ function num(value) {
126
+ return typeof value === "number" && Number.isFinite(value) ? value : null;
127
+ }
128
+ function acpUsageFromUnknown(value) {
129
+ const record = asRecord(value);
130
+ if (!record) return null;
131
+ const input = num(record.inputTokens ?? record.input_tokens);
132
+ const output = num(record.outputTokens ?? record.output_tokens);
133
+ if (input == null && output == null) return null;
134
+ const cacheRead = num(record.cacheReadTokens ?? record.cachedReadTokens ?? record.cached_read_tokens);
135
+ const cacheWrite = num(
136
+ record.cacheWriteTokens ?? record.cachedWriteTokens ?? record.cached_write_tokens
137
+ );
138
+ return {
139
+ inputTokens: input ?? 0,
140
+ outputTokens: output ?? 0,
141
+ ...cacheRead != null ? { cacheReadTokens: cacheRead } : {},
142
+ ...cacheWrite != null ? { cacheWriteTokens: cacheWrite } : {}
143
+ };
144
+ }
145
+ function toolInput(raw) {
146
+ const record = asRecord(raw);
147
+ return record ?? void 0;
148
+ }
149
+ function sessionUpdateToEvents(params) {
150
+ const root = asRecord(params);
151
+ const update = asRecord(root?.update) ?? root;
152
+ if (!update) return [];
153
+ const kind = typeof update.sessionUpdate === "string" ? update.sessionUpdate : "";
154
+ if (kind === "user_message_chunk") return [];
155
+ if (kind === "agent_message_chunk") {
156
+ const text = acpContentToText(update.content);
157
+ return text ? [{ type: "stdout", data: text }] : [];
158
+ }
159
+ if (kind === "agent_thought_chunk") {
160
+ const text = acpContentToText(update.content);
161
+ return text ? [{ type: "thinking", data: text }] : [];
162
+ }
163
+ if (kind === "plan") {
164
+ const entries = Array.isArray(update.entries) ? update.entries : [];
165
+ const text = entries.map((entry) => {
166
+ const record = asRecord(entry);
167
+ return typeof record?.content === "string" ? record.content : "";
168
+ }).filter(Boolean).join("\n");
169
+ return text ? [{ type: "thinking", data: text }] : [];
170
+ }
171
+ if (kind === "tool_call" || kind === "tool_call_update") {
172
+ const id = typeof update.toolCallId === "string" ? update.toolCallId : "";
173
+ if (!id) return [];
174
+ const name = typeof update.title === "string" && update.title || typeof update.kind === "string" && update.kind || "tool";
175
+ const status = typeof update.status === "string" ? update.status : "";
176
+ const content = clip(acpContentToText(update.content ?? update.rawOutput));
177
+ const events = [];
178
+ if (kind === "tool_call") {
179
+ events.push({
180
+ type: "tool_use",
181
+ id,
182
+ name,
183
+ ...toolInput(update.rawInput) ? { input: toolInput(update.rawInput) } : {}
184
+ });
185
+ }
186
+ if (status === "completed" || status === "failed" || kind === "tool_call_update" && content) {
187
+ events.push({
188
+ type: "tool_result",
189
+ id,
190
+ ...content ? { content } : {},
191
+ isError: status === "failed",
192
+ partial: status !== "completed" && status !== "failed"
193
+ });
194
+ }
195
+ return events;
196
+ }
197
+ return [];
198
+ }
199
+ var AGENT_EVENT_TYPES = /* @__PURE__ */ new Set([
200
+ "stdout",
201
+ "stderr",
202
+ "session_id",
203
+ "thinking",
204
+ "tool_use",
205
+ "tool_result",
206
+ "usage",
207
+ "exit"
208
+ ]);
209
+ function parseAcpRunnerLine(line) {
210
+ const trimmed = line.trim();
211
+ if (!trimmed.startsWith("{")) return null;
212
+ try {
213
+ const parsed = JSON.parse(trimmed);
214
+ if (typeof parsed.type !== "string" || !AGENT_EVENT_TYPES.has(parsed.type)) return null;
215
+ return parsed;
216
+ } catch {
217
+ return null;
218
+ }
219
+ }
220
+
221
+ export {
222
+ ACP_PROTOCOL_VERSION,
223
+ acpUserStdioServers,
224
+ toAcpMcpServers,
225
+ acpSessionOpenPlan,
226
+ acpPriorTranscript,
227
+ buildAcpReplayPrompt,
228
+ selectAcpPermissionOption,
229
+ acpUsageFromUnknown,
230
+ sessionUpdateToEvents,
231
+ parseAcpRunnerLine
232
+ };
@@ -1,3 +1,7 @@
1
+ import {
2
+ chmodOwnerOnly,
3
+ writePrivateFile
4
+ } from "./chunk-JT7R45JB.js";
1
5
  import {
2
6
  stripNestedElectronEnv
3
7
  } from "./chunk-4TR3HZFT.js";
@@ -12,10 +16,6 @@ import {
12
16
  withRemovedAccount,
13
17
  withSelectedAccount
14
18
  } from "./chunk-KI45T4DI.js";
15
- import {
16
- chmodOwnerOnly,
17
- writePrivateFile
18
- } from "./chunk-JT7R45JB.js";
19
19
  import {
20
20
  appDataDir
21
21
  } from "./chunk-H4UEFJRI.js";
@@ -1076,7 +1076,8 @@ var DEFAULT_AGENTS = /* @__PURE__ */ new Set([
1076
1076
  "codex",
1077
1077
  "opencode",
1078
1078
  "brightsy",
1079
- "cursor"
1079
+ "cursor",
1080
+ "acp"
1080
1081
  ]);
1081
1082
  var GITHUB_GIT_AUTH_MODES = ["auto", "gh", "ssh", "token"];
1082
1083
  var FOLLOW_UP_BEHAVIORS = ["steer", "queue"];
@@ -1426,6 +1427,7 @@ function normalizeDefaults(raw) {
1426
1427
  if (typeof source.agent === "string" && DEFAULT_AGENTS.has(source.agent)) {
1427
1428
  out.agent = source.agent;
1428
1429
  }
1430
+ if (source.acpHarness === "gemini" || source.acpHarness === "copilot") out.acpHarness = source.acpHarness;
1429
1431
  if (typeof source.model === "string") {
1430
1432
  const model = source.model.trim();
1431
1433
  if (model) out.model = model;
@@ -2134,6 +2136,8 @@ function updateDefaultsSettings(patch) {
2134
2136
  defaults.agent = patch.agent;
2135
2137
  }
2136
2138
  }
2139
+ if (patch.acpHarness === "gemini" || patch.acpHarness === "copilot") defaults.acpHarness = patch.acpHarness;
2140
+ else if ("acpHarness" in patch) delete defaults.acpHarness;
2137
2141
  if ("model" in patch) {
2138
2142
  if (patch.model == null || patch.model.trim() === "") {
2139
2143
  delete defaults.model;
@@ -23,11 +23,11 @@ import {
23
23
  normalizeTakenSlug,
24
24
  normalizeWorktreePath,
25
25
  takenSlugsFromThread
26
- } from "./chunk-6RIPZ73M.js";
26
+ } from "./chunk-SMSD6U3N.js";
27
27
  import {
28
28
  getGithubGitAuthMode,
29
29
  getGithubPat
30
- } from "./chunk-WWU4SYZR.js";
30
+ } from "./chunk-VL6F2KRE.js";
31
31
  import {
32
32
  worktreesRoot
33
33
  } from "./chunk-WOU343SI.js";
@@ -821,7 +821,8 @@ var DEFAULT_AGENTS = /* @__PURE__ */ new Set([
821
821
  "codex",
822
822
  "opencode",
823
823
  "brightsy",
824
- "cursor"
824
+ "cursor",
825
+ "acp"
825
826
  ]);
826
827
  var GITHUB_GIT_AUTH_MODES = ["auto", "gh", "ssh", "token"];
827
828
  var FOLLOW_UP_BEHAVIORS = ["steer", "queue"];
@@ -1171,6 +1172,7 @@ function normalizeDefaults(raw) {
1171
1172
  if (typeof source.agent === "string" && DEFAULT_AGENTS.has(source.agent)) {
1172
1173
  out.agent = source.agent;
1173
1174
  }
1175
+ if (source.acpHarness === "gemini" || source.acpHarness === "copilot") out.acpHarness = source.acpHarness;
1174
1176
  if (typeof source.model === "string") {
1175
1177
  const model = source.model.trim();
1176
1178
  if (model) out.model = model;
@@ -1879,6 +1881,8 @@ function updateDefaultsSettings(patch) {
1879
1881
  defaults.agent = patch.agent;
1880
1882
  }
1881
1883
  }
1884
+ if (patch.acpHarness === "gemini" || patch.acpHarness === "copilot") defaults.acpHarness = patch.acpHarness;
1885
+ else if ("acpHarness" in patch) delete defaults.acpHarness;
1882
1886
  if ("model" in patch) {
1883
1887
  if (patch.model == null || patch.model.trim() === "") {
1884
1888
  delete defaults.model;