@wrongstack/cli 0.296.2 → 0.296.4

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 (61) hide show
  1. package/dist/boot/dispatch-webui.d.ts +1 -0
  2. package/dist/boot/dispatch-webui.d.ts.map +1 -1
  3. package/dist/boot/tui-session-resume.d.ts.map +1 -1
  4. package/dist/{chunk-IN4GXGYW.js → chunk-BQCAJ7FI.js} +2 -2
  5. package/dist/{chunk-IN4GXGYW.js.map → chunk-BQCAJ7FI.js.map} +2 -2
  6. package/dist/{chunk-X5DQTPXT.js → chunk-OI7GWJDS.js} +1048 -804
  7. package/dist/chunk-OI7GWJDS.js.map +7 -0
  8. package/dist/{cli-main-6AU6E4XZ.js → cli-main-TOAWVJDY.js} +197 -60
  9. package/dist/cli-main-TOAWVJDY.js.map +7 -0
  10. package/dist/cli-main-helpers.d.ts +1 -1
  11. package/dist/cli-main-helpers.d.ts.map +1 -1
  12. package/dist/cli-main.d.ts.map +1 -1
  13. package/dist/execute-deps.d.ts +1 -0
  14. package/dist/execute-deps.d.ts.map +1 -1
  15. package/dist/{execution-V26SE52F.js → execution-O7I5DYE6.js} +34 -8
  16. package/dist/execution-O7I5DYE6.js.map +7 -0
  17. package/dist/execution-storage-observability.d.ts.map +1 -1
  18. package/dist/execution.d.ts.map +1 -1
  19. package/dist/fleet/host-subagent-factory.d.ts.map +1 -1
  20. package/dist/{hq-BECGICEZ.js → hq-JUYKUNJX.js} +2 -2
  21. package/dist/hq-server/auth.d.ts +15 -4
  22. package/dist/hq-server/auth.d.ts.map +1 -1
  23. package/dist/hq-server/routes/auth-handlers.d.ts +6 -13
  24. package/dist/hq-server/routes/auth-handlers.d.ts.map +1 -1
  25. package/dist/hq-server/routes.d.ts +6 -4
  26. package/dist/hq-server/routes.d.ts.map +1 -1
  27. package/dist/hq-server/snapshot.d.ts +44 -0
  28. package/dist/hq-server/snapshot.d.ts.map +1 -1
  29. package/dist/hq-server/types.d.ts +22 -4
  30. package/dist/hq-server/types.d.ts.map +1 -1
  31. package/dist/hq-server/utils.d.ts +8 -0
  32. package/dist/hq-server/utils.d.ts.map +1 -1
  33. package/dist/hq-server/ws.d.ts +1 -1
  34. package/dist/hq-server/ws.d.ts.map +1 -1
  35. package/dist/{hq-server-FJOVOERO.js → hq-server-6AQ3BXZA.js} +2 -2
  36. package/dist/hq-server.d.ts +3 -3
  37. package/dist/hq-server.d.ts.map +1 -1
  38. package/dist/{hq-tunnel-YZLRONPV.js → hq-tunnel-RFKGC4HI.js} +8 -5
  39. package/dist/{hq-tunnel-YZLRONPV.js.map → hq-tunnel-RFKGC4HI.js.map} +2 -2
  40. package/dist/hq-tunnel.d.ts +1 -1
  41. package/dist/hq-tunnel.d.ts.map +1 -1
  42. package/dist/index.js +5 -5
  43. package/dist/{sdd-runtime-IKPROVV2.js → sdd-runtime-JG4EEKL6.js} +2 -2
  44. package/dist/services/sdd/task-manager.d.ts.map +1 -1
  45. package/dist/slash-commands/settings.d.ts.map +1 -1
  46. package/dist/{webui-server-G3TISUIY.js → webui-server-ZF5KVGC5.js} +3 -2
  47. package/dist/webui-server-ZF5KVGC5.js.map +7 -0
  48. package/dist/webui-server-options.d.ts +2 -0
  49. package/dist/webui-server-options.d.ts.map +1 -1
  50. package/dist/webui-server.d.ts.map +1 -1
  51. package/dist/wiring/sage.d.ts.map +1 -1
  52. package/dist/wiring/session.d.ts +3 -1
  53. package/dist/wiring/session.d.ts.map +1 -1
  54. package/package.json +22 -22
  55. package/dist/chunk-X5DQTPXT.js.map +0 -7
  56. package/dist/cli-main-6AU6E4XZ.js.map +0 -7
  57. package/dist/execution-V26SE52F.js.map +0 -7
  58. package/dist/webui-server-G3TISUIY.js.map +0 -7
  59. /package/dist/{hq-BECGICEZ.js.map → hq-JUYKUNJX.js.map} +0 -0
  60. /package/dist/{hq-server-FJOVOERO.js.map → hq-server-6AQ3BXZA.js.map} +0 -0
  61. /package/dist/{sdd-runtime-IKPROVV2.js.map → sdd-runtime-JG4EEKL6.js.map} +0 -0
@@ -29,7 +29,7 @@ import {
29
29
  getTaskProgress,
30
30
  matchTaskNode,
31
31
  sddState
32
- } from "./chunk-IN4GXGYW.js";
32
+ } from "./chunk-BQCAJ7FI.js";
33
33
  import {
34
34
  setupPlugins
35
35
  } from "./chunk-QUNHS6O3.js";
@@ -1569,12 +1569,7 @@ function positiveNumber(value) {
1569
1569
  function createTeardownEventRegistrar(events, teardownHandlers) {
1570
1570
  return (event, handler) => {
1571
1571
  events.on(event, handler);
1572
- teardownHandlers.push(
1573
- () => (
1574
- // biome-ignore lint/suspicious/noExplicitAny: dynamic event dispatcher signature
1575
- events.off(event, handler)
1576
- )
1577
- );
1572
+ teardownHandlers.push(() => events.off(event, handler));
1578
1573
  };
1579
1574
  }
1580
1575
  async function loadOnlineAgentsForPrompt(projectDir, skip) {
@@ -1587,7 +1582,7 @@ async function loadOnlineAgentsForPrompt(projectDir, skip) {
1587
1582
  }
1588
1583
  }
1589
1584
  async function getSddRuntimeStateForCli() {
1590
- const sdd = await import("./sdd-runtime-IKPROVV2.js");
1585
+ const sdd = await import("./sdd-runtime-JG4EEKL6.js");
1591
1586
  return {
1592
1587
  tracker: sdd.getTaskTracker(),
1593
1588
  builder: sdd.getActiveBuilder(),
@@ -17832,9 +17827,9 @@ function buildSecurityCommand(opts) {
17832
17827
  }
17833
17828
 
17834
17829
  // src/slash-commands/settings.ts
17835
- import { color as color44 } from "@wrongstack/core/utils";
17836
17830
  import { noOpVault as noOpVault9 } from "@wrongstack/core/security";
17837
17831
  import { resolveFleetChatVerbosity } from "@wrongstack/core/types";
17832
+ import { color as color44, toErrorMessage as toErrorMessage20 } from "@wrongstack/core/utils";
17838
17833
  import { getProcessRegistry } from "@wrongstack/tools";
17839
17834
 
17840
17835
  // src/utils/delay-format.ts
@@ -17845,7 +17840,6 @@ function formatDelay(ms) {
17845
17840
  }
17846
17841
 
17847
17842
  // src/slash-commands/settings.ts
17848
- import { toErrorMessage as toErrorMessage20 } from "@wrongstack/core/utils";
17849
17843
  function buildSettingsCommand(opts) {
17850
17844
  const help = [
17851
17845
  "Usage:",
@@ -17885,6 +17879,7 @@ function buildSettingsCommand(opts) {
17885
17879
  " /settings thinking-word <word> TUI status-chip word (single short word)",
17886
17880
  " /settings statusline minimum|detailed|no-color TUI statusline density",
17887
17881
  " /settings animation rainbow|wave|pulse|dots|breathe|cycle TUI working-chip animation",
17882
+ " /settings read-symbols on|off Include codebase-index symbols in read tool results",
17888
17883
  " /settings reasoning auto|on|off Reasoning mode (auto = provider default)",
17889
17884
  " /settings reasoning-effort none|minimal|low|medium|high|xhigh|max Reasoning effort",
17890
17885
  " /settings reasoning-preserve on|off Preserve thinking across turns",
@@ -17975,6 +17970,7 @@ function buildSettingsCommand(opts) {
17975
17970
  ` thinking word: ${color44.cyan(au?.thinkingWord ?? "thinking")} ${color44.dim("change: /settings thinking-word <word>")}`,
17976
17971
  ` statusline mode: ${color44.cyan(au?.statuslineMode ?? "detailed")} ${color44.dim("change: /settings statusline minimum|detailed|no-color")}`,
17977
17972
  ` animation style: ${color44.cyan(au?.animationStyle ?? "rainbow")} ${color44.dim("change: /settings animation rainbow|wave|pulse|dots|breathe|cycle")}`,
17973
+ ` read symbols: ${au?.readAdvancedMode === true ? color44.cyan("on") : color44.dim("off")} ${color44.dim("change: /settings read-symbols on|off")}`,
17978
17974
  ` reasoning mode: ${color44.cyan(reasoningMode)} ${color44.dim("change: /settings reasoning auto|on|off")}`,
17979
17975
  ` reasoning effort: ${color44.cyan(reasoningEffort)} ${color44.dim("change: /settings reasoning-effort <level>")}`,
17980
17976
  ` reasoning preserve: ${reasoningPreserve ? color44.cyan("on") : color44.dim("off")} ${color44.dim("change: /settings reasoning-preserve on|off")}`,
@@ -18042,14 +18038,18 @@ function buildSettingsCommand(opts) {
18042
18038
  hq.enabled = on;
18043
18039
  cfg.hq = hq;
18044
18040
  });
18045
- return { message: `${color44.green("\u2713")} HQ publishing \u2192 ${on ? color44.cyan("on") : color44.dim("off")}` };
18041
+ return {
18042
+ message: `${color44.green("\u2713")} HQ publishing \u2192 ${on ? color44.cyan("on") : color44.dim("off")}`
18043
+ };
18046
18044
  }
18047
18045
  if (sub === "hq-url") {
18048
18046
  const raw = rest.join(" ").trim();
18049
- if (!raw) return { message: `${color44.amber("Usage:")} /settings hq-url <http://host:3499>` };
18047
+ if (!raw)
18048
+ return { message: `${color44.amber("Usage:")} /settings hq-url <http://host:3499>` };
18050
18049
  try {
18051
18050
  const url = new URL(raw);
18052
- if (url.protocol !== "http:" && url.protocol !== "https:") throw new Error("bad protocol");
18051
+ if (url.protocol !== "http:" && url.protocol !== "https:")
18052
+ throw new Error("bad protocol");
18053
18053
  } catch {
18054
18054
  return { message: `${color44.red("Invalid URL")}: ${raw}` };
18055
18055
  }
@@ -18063,14 +18063,17 @@ function buildSettingsCommand(opts) {
18063
18063
  }
18064
18064
  if (sub === "hq-token") {
18065
18065
  const token = rest.join(" ").trim();
18066
- if (!token) return { message: `${color44.amber("Usage:")} /settings hq-token <client-token>` };
18066
+ if (!token)
18067
+ return { message: `${color44.amber("Usage:")} /settings hq-token <client-token>` };
18067
18068
  await persistConfigSetting({ ...persistDeps, forceGlobal: true }, (cfg) => {
18068
18069
  const hq = cfg.hq ?? {};
18069
18070
  hq.token = token;
18070
18071
  hq.enabled = true;
18071
18072
  cfg.hq = hq;
18072
18073
  });
18073
- return { message: `${color44.green("\u2713")} HQ token saved ${color44.dim("(active profile config)")}` };
18074
+ return {
18075
+ message: `${color44.green("\u2713")} HQ token saved ${color44.dim("(active profile config)")}`
18076
+ };
18074
18077
  }
18075
18078
  if (sub === "hq-raw") {
18076
18079
  const raw = (rest[0] ?? "").toLowerCase();
@@ -18083,7 +18086,9 @@ function buildSettingsCommand(opts) {
18083
18086
  hq.rawContent = on;
18084
18087
  cfg.hq = hq;
18085
18088
  });
18086
- return { message: `${color44.green("\u2713")} HQ raw content \u2192 ${on ? color44.cyan("on") : color44.dim("off")}` };
18089
+ return {
18090
+ message: `${color44.green("\u2713")} HQ raw content \u2192 ${on ? color44.cyan("on") : color44.dim("off")}`
18091
+ };
18087
18092
  }
18088
18093
  if (sub === "delay") {
18089
18094
  const raw = rest[0];
@@ -18323,7 +18328,10 @@ function buildSettingsCommand(opts) {
18323
18328
  const ms = Math.round(seconds * 1e3);
18324
18329
  await persistConfigSetting(persistDeps, (cfg) => {
18325
18330
  const cb = cfg.circuitBreaker;
18326
- cfg.circuitBreaker = { ...cb ?? {}, autoKillResetMs: ms };
18331
+ cfg.circuitBreaker = {
18332
+ ...cb ?? {},
18333
+ autoKillResetMs: ms
18334
+ };
18327
18335
  });
18328
18336
  getProcessRegistry().setBreakerConfig({ autoKillResetMs: ms });
18329
18337
  return {
@@ -18334,7 +18342,9 @@ function buildSettingsCommand(opts) {
18334
18342
  const raw = (rest[0] ?? "").toLowerCase();
18335
18343
  const modes = ["balanced", "frugal", "deep"];
18336
18344
  if (!modes.includes(raw)) {
18337
- return { message: `${color44.amber("Usage:")} /settings context-mode balanced|frugal|deep` };
18345
+ return {
18346
+ message: `${color44.amber("Usage:")} /settings context-mode balanced|frugal|deep`
18347
+ };
18338
18348
  }
18339
18349
  await persistConfigSetting(persistDeps, (cfg) => {
18340
18350
  const ctx = cfg.context ?? {};
@@ -18349,7 +18359,9 @@ function buildSettingsCommand(opts) {
18349
18359
  const raw = (rest[0] ?? "").toLowerCase();
18350
18360
  const strategies = ["hybrid", "intelligent", "selective"];
18351
18361
  if (!strategies.includes(raw)) {
18352
- return { message: `${color44.amber("Usage:")} /settings context-strategy hybrid|intelligent|selective` };
18362
+ return {
18363
+ message: `${color44.amber("Usage:")} /settings context-strategy hybrid|intelligent|selective`
18364
+ };
18353
18365
  }
18354
18366
  await persistConfigSetting(persistDeps, (cfg) => {
18355
18367
  const ctx = cfg.context ?? {};
@@ -18379,7 +18391,9 @@ function buildSettingsCommand(opts) {
18379
18391
  const raw = (rest[0] ?? "").toLowerCase();
18380
18392
  const tiers = ["off", "minimal", "light", "medium", "aggressive"];
18381
18393
  if (!tiers.includes(raw)) {
18382
- return { message: `${color44.amber("Usage:")} /settings token-saving off|minimal|light|medium|aggressive` };
18394
+ return {
18395
+ message: `${color44.amber("Usage:")} /settings token-saving off|minimal|light|medium|aggressive`
18396
+ };
18383
18397
  }
18384
18398
  await persistConfigSetting(persistDeps, (cfg) => {
18385
18399
  const feat = cfg.features ?? {};
@@ -18482,125 +18496,173 @@ function buildSettingsCommand(opts) {
18482
18496
  }
18483
18497
  if (sub === "mcp") {
18484
18498
  const raw = (rest[0] ?? "").toLowerCase();
18485
- if (!["on", "off"].includes(raw)) return { message: `${color44.amber("Usage:")} /settings mcp on|off` };
18499
+ if (!["on", "off"].includes(raw))
18500
+ return { message: `${color44.amber("Usage:")} /settings mcp on|off` };
18486
18501
  const on = raw === "on";
18487
18502
  await persistConfigSetting(persistDeps, (cfg) => {
18488
18503
  const feats = cfg.features ?? {};
18489
18504
  feats.mcp = on;
18490
18505
  cfg.features = feats;
18491
18506
  });
18492
- return { message: `${color44.green("\u2713")} MCP features \u2192 ${on ? color44.cyan("on") : color44.dim("off")} ${color44.dim("restart to apply")}` };
18507
+ return {
18508
+ message: `${color44.green("\u2713")} MCP features \u2192 ${on ? color44.cyan("on") : color44.dim("off")} ${color44.dim("restart to apply")}`
18509
+ };
18493
18510
  }
18494
18511
  if (sub === "plugins") {
18495
18512
  const raw = (rest[0] ?? "").toLowerCase();
18496
- if (!["on", "off"].includes(raw)) return { message: `${color44.amber("Usage:")} /settings plugins on|off` };
18513
+ if (!["on", "off"].includes(raw))
18514
+ return { message: `${color44.amber("Usage:")} /settings plugins on|off` };
18497
18515
  const on = raw === "on";
18498
18516
  await persistConfigSetting(persistDeps, (cfg) => {
18499
18517
  const feats = cfg.features ?? {};
18500
18518
  feats.plugins = on;
18501
18519
  cfg.features = feats;
18502
18520
  });
18503
- return { message: `${color44.green("\u2713")} Plugin features \u2192 ${on ? color44.cyan("on") : color44.dim("off")} ${color44.dim("restart to apply")}` };
18521
+ return {
18522
+ message: `${color44.green("\u2713")} Plugin features \u2192 ${on ? color44.cyan("on") : color44.dim("off")} ${color44.dim("restart to apply")}`
18523
+ };
18504
18524
  }
18505
18525
  if (sub === "memory") {
18506
18526
  const raw = (rest[0] ?? "").toLowerCase();
18507
- if (!["on", "off"].includes(raw)) return { message: `${color44.amber("Usage:")} /settings memory on|off` };
18527
+ if (!["on", "off"].includes(raw))
18528
+ return { message: `${color44.amber("Usage:")} /settings memory on|off` };
18508
18529
  const on = raw === "on";
18509
18530
  await persistConfigSetting(persistDeps, (cfg) => {
18510
18531
  const feats = cfg.features ?? {};
18511
18532
  feats.memory = on;
18512
18533
  cfg.features = feats;
18513
18534
  });
18514
- return { message: `${color44.green("\u2713")} Memory features \u2192 ${on ? color44.cyan("on") : color44.dim("off")} ${color44.dim("restart to apply")}` };
18535
+ return {
18536
+ message: `${color44.green("\u2713")} Memory features \u2192 ${on ? color44.cyan("on") : color44.dim("off")} ${color44.dim("restart to apply")}`
18537
+ };
18515
18538
  }
18516
18539
  if (sub === "skills") {
18517
18540
  const raw = (rest[0] ?? "").toLowerCase();
18518
- if (!["on", "off"].includes(raw)) return { message: `${color44.amber("Usage:")} /settings skills on|off` };
18541
+ if (!["on", "off"].includes(raw))
18542
+ return { message: `${color44.amber("Usage:")} /settings skills on|off` };
18519
18543
  const on = raw === "on";
18520
18544
  await persistConfigSetting(persistDeps, (cfg) => {
18521
18545
  const feats = cfg.features ?? {};
18522
18546
  feats.skills = on;
18523
18547
  cfg.features = feats;
18524
18548
  });
18525
- return { message: `${color44.green("\u2713")} Skills features \u2192 ${on ? color44.cyan("on") : color44.dim("off")} ${color44.dim("restart to apply")}` };
18549
+ return {
18550
+ message: `${color44.green("\u2713")} Skills features \u2192 ${on ? color44.cyan("on") : color44.dim("off")} ${color44.dim("restart to apply")}`
18551
+ };
18526
18552
  }
18527
18553
  if (sub === "models-registry") {
18528
18554
  const raw = (rest[0] ?? "").toLowerCase();
18529
- if (!["on", "off"].includes(raw)) return { message: `${color44.amber("Usage:")} /settings models-registry on|off` };
18555
+ if (!["on", "off"].includes(raw))
18556
+ return { message: `${color44.amber("Usage:")} /settings models-registry on|off` };
18530
18557
  const on = raw === "on";
18531
18558
  await persistConfigSetting(persistDeps, (cfg) => {
18532
18559
  const feats = cfg.features ?? {};
18533
18560
  feats.modelsRegistry = on;
18534
18561
  cfg.features = feats;
18535
18562
  });
18536
- return { message: `${color44.green("\u2713")} Models registry \u2192 ${on ? color44.cyan("on") : color44.dim("off")} ${color44.dim("restart to apply")}` };
18563
+ return {
18564
+ message: `${color44.green("\u2713")} Models registry \u2192 ${on ? color44.cyan("on") : color44.dim("off")} ${color44.dim("restart to apply")}`
18565
+ };
18537
18566
  }
18538
18567
  if (sub === "stream-fleet") {
18539
18568
  const raw = (rest[0] ?? "").toLowerCase();
18540
18569
  const mode = raw === "on" ? "full" : raw === "off" || raw === "full" ? raw : void 0;
18541
- if (!mode) return { message: `${color44.amber("Usage:")} /settings stream-fleet off|full (on = full)` };
18570
+ if (!mode)
18571
+ return {
18572
+ message: `${color44.amber("Usage:")} /settings stream-fleet off|full (on = full)`
18573
+ };
18542
18574
  await persistAutonomySetting(persistDeps, (autonomy) => {
18543
18575
  autonomy.fleetChatVerbosity = mode;
18544
18576
  });
18545
18577
  opts.fleetStreamController?.setMode(mode);
18546
18578
  const desc = mode === "full" ? "every subagent tool call and message in chat" : "subagent chat lines hidden (F2/F3 stay live)";
18547
- return { message: `${color44.green("\u2713")} fleet chat \u2192 ${color44.cyan(mode)} ${color44.dim(desc)}` };
18579
+ return {
18580
+ message: `${color44.green("\u2713")} fleet chat \u2192 ${color44.cyan(mode)} ${color44.dim(desc)}`
18581
+ };
18548
18582
  }
18549
18583
  if (sub === "chime") {
18550
18584
  const raw = (rest[0] ?? "").toLowerCase();
18551
- if (!["on", "off"].includes(raw)) return { message: `${color44.amber("Usage:")} /settings chime on|off` };
18585
+ if (!["on", "off"].includes(raw))
18586
+ return { message: `${color44.amber("Usage:")} /settings chime on|off` };
18552
18587
  const on = raw === "on";
18553
18588
  await persistAutonomySetting(persistDeps, (autonomy) => {
18554
18589
  autonomy.chime = on;
18555
18590
  });
18556
- return { message: `${color44.green("\u2713")} completion chime \u2192 ${on ? color44.cyan("on") : color44.dim("off")}` };
18591
+ return {
18592
+ message: `${color44.green("\u2713")} completion chime \u2192 ${on ? color44.cyan("on") : color44.dim("off")}`
18593
+ };
18557
18594
  }
18558
18595
  if (sub === "confirm-exit") {
18559
18596
  const raw = (rest[0] ?? "").toLowerCase();
18560
- if (!["on", "off"].includes(raw)) return { message: `${color44.amber("Usage:")} /settings confirm-exit on|off` };
18597
+ if (!["on", "off"].includes(raw))
18598
+ return { message: `${color44.amber("Usage:")} /settings confirm-exit on|off` };
18561
18599
  const on = raw === "on";
18562
18600
  await persistAutonomySetting(persistDeps, (autonomy) => {
18563
18601
  autonomy.confirmExit = on;
18564
18602
  });
18565
- return { message: `${color44.green("\u2713")} confirm before exit \u2192 ${on ? color44.cyan("on") : color44.dim("off")}` };
18603
+ return {
18604
+ message: `${color44.green("\u2713")} confirm before exit \u2192 ${on ? color44.cyan("on") : color44.dim("off")}`
18605
+ };
18566
18606
  }
18567
18607
  if (sub === "max-iterations") {
18568
18608
  const raw = rest[0];
18569
- if (raw === void 0) return { message: `${color44.amber("Usage:")} /settings max-iterations <n> ${color44.dim("(0 = default)")}` };
18609
+ if (raw === void 0)
18610
+ return {
18611
+ message: `${color44.amber("Usage:")} /settings max-iterations <n> ${color44.dim("(0 = default)")}`
18612
+ };
18570
18613
  const n = Number.parseInt(raw, 10);
18571
- if (Number.isNaN(n) || n < 0) return { message: `${color44.red("Invalid number")}: "${raw}". Enter a non-negative integer.` };
18614
+ if (Number.isNaN(n) || n < 0)
18615
+ return {
18616
+ message: `${color44.red("Invalid number")}: "${raw}". Enter a non-negative integer.`
18617
+ };
18572
18618
  await persistConfigSetting(persistDeps, (cfg) => {
18573
18619
  const tools = cfg.tools ?? {};
18574
18620
  tools.maxIterations = n;
18575
18621
  cfg.tools = tools;
18576
18622
  });
18577
- return { message: `${color44.green("\u2713")} max iterations \u2192 ${color44.cyan(n === 0 ? "default" : String(n))} ${color44.dim("agent pauses after this many iterations")}` };
18623
+ return {
18624
+ message: `${color44.green("\u2713")} max iterations \u2192 ${color44.cyan(n === 0 ? "default" : String(n))} ${color44.dim("agent pauses after this many iterations")}`
18625
+ };
18578
18626
  }
18579
18627
  if (sub === "auto-proceed-max-iterations") {
18580
18628
  const raw = rest[0];
18581
- if (raw === void 0) return { message: `${color44.amber("Usage:")} /settings auto-proceed-max-iterations <n> ${color44.dim("(0 = unlimited)")}` };
18629
+ if (raw === void 0)
18630
+ return {
18631
+ message: `${color44.amber("Usage:")} /settings auto-proceed-max-iterations <n> ${color44.dim("(0 = unlimited)")}`
18632
+ };
18582
18633
  const n = Number.parseInt(raw, 10);
18583
- if (Number.isNaN(n) || n < 0) return { message: `${color44.red("Invalid number")}: "${raw}". Enter a non-negative integer.` };
18634
+ if (Number.isNaN(n) || n < 0)
18635
+ return {
18636
+ message: `${color44.red("Invalid number")}: "${raw}". Enter a non-negative integer.`
18637
+ };
18584
18638
  await persistAutonomySetting(persistDeps, (autonomy) => {
18585
18639
  autonomy.autoProceedMaxIterations = n;
18586
18640
  });
18587
- return { message: `${color44.green("\u2713")} auto-proceed max iterations \u2192 ${color44.cyan(n === 0 ? "unlimited" : String(n))}` };
18641
+ return {
18642
+ message: `${color44.green("\u2713")} auto-proceed max iterations \u2192 ${color44.cyan(n === 0 ? "unlimited" : String(n))}`
18643
+ };
18588
18644
  }
18589
18645
  if (sub === "index-on-start") {
18590
18646
  const raw = (rest[0] ?? "").toLowerCase();
18591
- if (!["on", "off"].includes(raw)) return { message: `${color44.amber("Usage:")} /settings index-on-start on|off` };
18647
+ if (!["on", "off"].includes(raw))
18648
+ return { message: `${color44.amber("Usage:")} /settings index-on-start on|off` };
18592
18649
  const on = raw === "on";
18593
18650
  await persistConfigSetting(persistDeps, (cfg) => {
18594
18651
  const idx = cfg.indexing ?? {};
18595
18652
  idx.onSessionStart = on;
18596
18653
  cfg.indexing = idx;
18597
18654
  });
18598
- return { message: `${color44.green("\u2713")} index on session start \u2192 ${on ? color44.cyan("on") : color44.dim("off")} ${color44.dim("effective next session")}` };
18655
+ return {
18656
+ message: `${color44.green("\u2713")} index on session start \u2192 ${on ? color44.cyan("on") : color44.dim("off")} ${color44.dim("effective next session")}`
18657
+ };
18599
18658
  }
18600
18659
  if (sub === "log-level") {
18601
18660
  const raw = (rest[0] ?? "").toLowerCase();
18602
18661
  const levels = ["error", "warn", "info", "debug", "trace"];
18603
- if (!levels.includes(raw)) return { message: `${color44.amber("Usage:")} /settings log-level error|warn|info|debug|trace` };
18662
+ if (!levels.includes(raw))
18663
+ return {
18664
+ message: `${color44.amber("Usage:")} /settings log-level error|warn|info|debug|trace`
18665
+ };
18604
18666
  await persistConfigSetting(persistDeps, (cfg) => {
18605
18667
  const log = cfg.log ?? {};
18606
18668
  log.level = raw;
@@ -18611,18 +18673,27 @@ function buildSettingsCommand(opts) {
18611
18673
  if (sub === "audit-level") {
18612
18674
  const raw = (rest[0] ?? "").toLowerCase();
18613
18675
  const levels = ["minimal", "standard", "full"];
18614
- if (!levels.includes(raw)) return { message: `${color44.amber("Usage:")} /settings audit-level minimal|standard|full` };
18676
+ if (!levels.includes(raw))
18677
+ return {
18678
+ message: `${color44.amber("Usage:")} /settings audit-level minimal|standard|full`
18679
+ };
18615
18680
  await persistConfigSetting(persistDeps, (cfg) => {
18616
18681
  const sess = cfg.session ?? {};
18617
18682
  sess.auditLevel = raw;
18618
18683
  cfg.session = sess;
18619
18684
  });
18620
- return { message: `${color44.green("\u2713")} audit level \u2192 ${color44.cyan(raw)} ${color44.dim("restart to apply")}` };
18685
+ return {
18686
+ message: `${color44.green("\u2713")} audit level \u2192 ${color44.cyan(raw)} ${color44.dim("restart to apply")}`
18687
+ };
18621
18688
  }
18622
18689
  if (sub === "thinking-word") {
18623
18690
  const raw = rest.join(" ").trim();
18624
- if (!raw) return { message: `${color44.amber("Usage:")} /settings thinking-word <word> ${color44.dim('single short word, e.g. "thinking", "vibing", "cooking"')}` };
18625
- if (raw.length > 16) return { message: `${color44.red("Word too long")}: max 16 characters.` };
18691
+ if (!raw)
18692
+ return {
18693
+ message: `${color44.amber("Usage:")} /settings thinking-word <word> ${color44.dim('single short word, e.g. "thinking", "vibing", "cooking"')}`
18694
+ };
18695
+ if (raw.length > 16)
18696
+ return { message: `${color44.red("Word too long")}: max 16 characters.` };
18626
18697
  await persistAutonomySetting(persistDeps, (autonomy) => {
18627
18698
  autonomy.thinkingWord = raw;
18628
18699
  });
@@ -18631,23 +18702,45 @@ function buildSettingsCommand(opts) {
18631
18702
  if (sub === "statusline") {
18632
18703
  const raw = (rest[0] ?? "").toLowerCase();
18633
18704
  const modes = ["minimum", "detailed", "no-color"];
18634
- if (!modes.includes(raw)) return { message: `${color44.amber("Usage:")} /settings statusline minimum|detailed|no-color` };
18705
+ if (!modes.includes(raw))
18706
+ return {
18707
+ message: `${color44.amber("Usage:")} /settings statusline minimum|detailed|no-color`
18708
+ };
18635
18709
  await persistAutonomySetting(persistDeps, (autonomy) => {
18636
18710
  autonomy.statuslineMode = raw;
18637
18711
  });
18638
18712
  return { message: `${color44.green("\u2713")} statusline mode \u2192 ${color44.cyan(raw)}` };
18639
18713
  }
18714
+ if (sub === "read-symbols") {
18715
+ const raw = (rest[0] ?? "").toLowerCase();
18716
+ if (!["on", "off"].includes(raw)) {
18717
+ return { message: `${color44.amber("Usage:")} /settings read-symbols on|off` };
18718
+ }
18719
+ const on = raw === "on";
18720
+ await persistAutonomySetting(persistDeps, (autonomy) => {
18721
+ autonomy.readAdvancedMode = on;
18722
+ });
18723
+ if (opts.context?.meta) {
18724
+ opts.context.meta["tools.read.advancedMode"] = on;
18725
+ }
18726
+ return {
18727
+ message: `${color44.green("\u2713")} read symbols \u2192 ${on ? color44.cyan("on") : color44.dim("off")} ${color44.dim(on ? "codebase-index symbols will be included in read tool results" : "read tool returns file content only")}`
18728
+ };
18729
+ }
18640
18730
  if (sub === "animation") {
18641
18731
  const raw = (rest[0] ?? "").toLowerCase();
18642
18732
  const styles = ["rainbow", "wave", "pulse", "dots", "breathe", "cycle"];
18643
- if (!styles.includes(raw)) return { message: `${color44.amber("Usage:")} /settings animation rainbow|wave|pulse|dots|breathe|cycle` };
18733
+ if (!styles.includes(raw))
18734
+ return {
18735
+ message: `${color44.amber("Usage:")} /settings animation rainbow|wave|pulse|dots|breathe|cycle`
18736
+ };
18644
18737
  await persistAutonomySetting(persistDeps, (autonomy) => {
18645
18738
  autonomy.animationStyle = raw;
18646
18739
  });
18647
18740
  return { message: `${color44.green("\u2713")} animation style \u2192 ${color44.cyan(raw)}` };
18648
18741
  }
18649
18742
  return {
18650
- message: `${color44.red("Unknown setting")} "${sub}". ${unknownSubcommand(sub, ["delay", "mode", "hints", "debug-stream", "config-scope", "fs-access", "refine", "refine-delay", "refine-language", "refiner-provider", "refiner-model", "refiner-fallback-profile", "refiner-clear", "semver-part", "breaker", "breaker-timeout", "context-mode", "context-strategy", "context-auto-compact", "token-saving", "max-concurrent", "title-animation", "reasoning", "reasoning-effort", "reasoning-preserve", "cache-ttl", "stream-fleet", "chime", "confirm-exit", "mcp", "plugins", "memory", "skills", "models-registry", "max-iterations", "auto-proceed-max-iterations", "index-on-start", "log-level", "audit-level", "thinking-word", "statusline", "animation", "defaults"], "settings")}`
18743
+ message: `${color44.red("Unknown setting")} "${sub}". ${unknownSubcommand(sub, ["delay", "mode", "hints", "debug-stream", "config-scope", "fs-access", "refine", "refine-delay", "refine-language", "refiner-provider", "refiner-model", "refiner-fallback-profile", "refiner-clear", "semver-part", "breaker", "breaker-timeout", "context-mode", "context-strategy", "context-auto-compact", "token-saving", "max-concurrent", "title-animation", "reasoning", "reasoning-effort", "reasoning-preserve", "cache-ttl", "stream-fleet", "chime", "confirm-exit", "mcp", "plugins", "memory", "skills", "models-registry", "max-iterations", "auto-proceed-max-iterations", "index-on-start", "log-level", "audit-level", "thinking-word", "statusline", "animation", "read-symbols", "defaults"], "settings")}`
18651
18744
  };
18652
18745
  } catch (err) {
18653
18746
  return {
@@ -23197,6 +23290,16 @@ ${audienceMemory.map((text) => `- ${text}`).join("\n")}`
23197
23290
  subReasoningConfig = await resolveHostSubagentReasoningConfig(host.deps, id, model);
23198
23291
  },
23199
23292
  events,
23293
+ // Thread the leader's shared ProviderModelStatusTracker so the
23294
+ // subagent's fallback extension quarantines a (provider, model) pair
23295
+ // on the first 429 (rate-limit) failure instead of silently
23296
+ // reassigning the same doomed model on every concurrent spawn.
23297
+ // Without this dep, deps.statusTracker in fallback-model.ts is
23298
+ // undefined and every recordFailure / isAvailable call is a no-op,
23299
+ // so the waiting-room transition never fires along the subagent
23300
+ // dispatch path. The tracker is the same singleton the leader uses,
23301
+ // populated by brain-and-orchestration.ts into host.opts.statusTracker.
23302
+ ...host.opts.statusTracker ? { statusTracker: host.opts.statusTracker } : {},
23200
23303
  ...mergedConfig.fallbackStickiness?.primaryProbeInterval !== void 0 ? { primaryCooldownMs: mergedConfig.fallbackStickiness.primaryProbeInterval } : {},
23201
23304
  ...mergedConfig.fallbackStickiness?.stickyFallbackTurns !== void 0 ? { stickyFallbackTurns: mergedConfig.fallbackStickiness.stickyFallbackTurns } : {}
23202
23305
  })
@@ -27532,6 +27635,7 @@ function setupSage(deps) {
27532
27635
  maxCharsPerTool: cfg?.inject?.maxCharsPerTool,
27533
27636
  taskAware: cfg?.inject?.taskAware,
27534
27637
  minScore: cfg?.inject?.minScore,
27638
+ minImportance: cfg?.inject?.minImportance,
27535
27639
  repeatCooldownMs: cfg?.inject?.repeatCooldownMs,
27536
27640
  verifyOnMutation: cfg?.hygiene?.autoOnFileChange,
27537
27641
  triggers: cfg?.inject?.triggers,
@@ -28233,7 +28337,12 @@ async function setupSession(params) {
28233
28337
  const todosCheckpointPath = sessionScopedPath3(wpaths.projectSessions, sessionId, ".todos.json");
28234
28338
  if (resumeId) {
28235
28339
  try {
28236
- const restoredTodos = await loadTodosCheckpoint(todosCheckpointPath, eventsBus, traceId);
28340
+ const restoredTodos = await loadTodosCheckpoint(
28341
+ todosCheckpointPath,
28342
+ eventsBus,
28343
+ traceId,
28344
+ sessionId
28345
+ );
28237
28346
  if (restoredTodos && restoredTodos.length > 0) {
28238
28347
  context.state.replaceTodos(restoredTodos);
28239
28348
  renderer.writeInfo(
@@ -28243,14 +28352,39 @@ async function setupSession(params) {
28243
28352
  } catch {
28244
28353
  }
28245
28354
  }
28246
- const detachTodosCheckpointOnly = attachTodosCheckpoint(
28355
+ const checkpointWarning = loggerParam ? (msg) => loggerParam.warn(msg) : void 0;
28356
+ let checkpointSessionId = sessionId;
28357
+ let checkpointSessionsDir = wpaths.projectSessions;
28358
+ const attachCheckpoint = (targetSessionId, sessionsDir) => attachTodosCheckpoint(
28247
28359
  context.state,
28248
- todosCheckpointPath,
28249
- sessionId,
28360
+ sessionScopedPath3(sessionsDir, targetSessionId, ".todos.json"),
28361
+ targetSessionId,
28250
28362
  eventsBus,
28251
28363
  traceId,
28252
- loggerParam ? (msg) => loggerParam.warn(msg) : void 0
28364
+ checkpointWarning
28253
28365
  );
28366
+ let detachTodosCheckpointOnly = attachCheckpoint(sessionId, checkpointSessionsDir);
28367
+ let checkpointAttached = true;
28368
+ const detachCurrentCheckpoint = async () => {
28369
+ if (!checkpointAttached) return;
28370
+ checkpointAttached = false;
28371
+ await detachTodosCheckpointOnly();
28372
+ };
28373
+ let checkpointRebindTail = Promise.resolve();
28374
+ const rebindTodosCheckpoint = (nextSessionId, sessionsDir = wpaths.projectSessions) => {
28375
+ const transition = checkpointRebindTail.then(async () => {
28376
+ if (checkpointAttached && nextSessionId === checkpointSessionId && sessionsDir === checkpointSessionsDir) {
28377
+ return;
28378
+ }
28379
+ await detachCurrentCheckpoint();
28380
+ checkpointSessionId = nextSessionId;
28381
+ checkpointSessionsDir = sessionsDir;
28382
+ detachTodosCheckpointOnly = attachCheckpoint(nextSessionId, sessionsDir);
28383
+ checkpointAttached = true;
28384
+ });
28385
+ checkpointRebindTail = transition.catch(() => void 0);
28386
+ return transition;
28387
+ };
28254
28388
  const planPath = sessionScopedPath3(wpaths.projectSessions, sessionId, ".plan.json");
28255
28389
  context.state.setMeta("plan.path", planPath);
28256
28390
  const taskPath = sessionScopedPath3(wpaths.projectSessions, sessionId, ".tasks.json");
@@ -28260,7 +28394,8 @@ async function setupSession(params) {
28260
28394
  const detachTodosCheckpoint = async () => {
28261
28395
  detachSessionKanbanMirror();
28262
28396
  cacheLedger?.dispose();
28263
- await detachTodosCheckpointOnly();
28397
+ await checkpointRebindTail;
28398
+ await detachCurrentCheckpoint();
28264
28399
  };
28265
28400
  let dirState;
28266
28401
  if (resumeId) {
@@ -28299,6 +28434,7 @@ async function setupSession(params) {
28299
28434
  queueStore,
28300
28435
  planPath,
28301
28436
  detachTodosCheckpoint,
28437
+ rebindTodosCheckpoint,
28302
28438
  priorFleetState: dirState ?? void 0,
28303
28439
  restoredToolCalls,
28304
28440
  restoredEvents,
@@ -28939,7 +29075,7 @@ async function runInteractive(cliCtx) {
28939
29075
  onEvent: evOn
28940
29076
  });
28941
29077
  const savedProviderCfg = config.providers?.[config.provider];
28942
- const { execute } = await import("./execution-V26SE52F.js");
29078
+ const { execute } = await import("./execution-O7I5DYE6.js");
28943
29079
  const stopHeapWatchdog = startHeapWatchdog();
28944
29080
  teardownHandlers.push(() => {
28945
29081
  void stopHeapWatchdog();
@@ -28972,6 +29108,7 @@ async function runInteractive(cliCtx) {
28972
29108
  queueStore,
28973
29109
  context,
28974
29110
  detachTodosCheckpoint,
29111
+ rebindTodosCheckpoint: sessResult.rebindTodosCheckpoint,
28975
29112
  sessionStore,
28976
29113
  memoryStore,
28977
29114
  modeStore,
@@ -29123,4 +29260,4 @@ export {
29123
29260
  CLI_VERSION,
29124
29261
  runInteractive
29125
29262
  };
29126
- //# sourceMappingURL=cli-main-6AU6E4XZ.js.map
29263
+ //# sourceMappingURL=cli-main-TOAWVJDY.js.map