jinzd-ai-cli 0.4.305 → 0.4.307

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 (32) hide show
  1. package/dist/{batch-OX27K4GG.js → batch-HMADXNOD.js} +2 -2
  2. package/dist/{chunk-UFK5CTBU.js → chunk-3CKJOTVM.js} +3 -3
  3. package/dist/{chunk-4DH5LZR5.js → chunk-3TBXHLSC.js} +1 -1
  4. package/dist/{chunk-I6RATYRF.js → chunk-4W6VDVQU.js} +1 -1
  5. package/dist/{chunk-Q4DAKI7I.js → chunk-5GQL4TSZ.js} +1 -1
  6. package/dist/{chunk-3ZABGT3S.js → chunk-AHL6KOGM.js} +1 -1
  7. package/dist/{chunk-NFLE34QG.js → chunk-AQF6IXSR.js} +1 -1
  8. package/dist/{chunk-YPOWDFOV.js → chunk-CIM2PV2F.js} +1 -1
  9. package/dist/{chunk-SZ4226XY.js → chunk-KRCYR46A.js} +1 -1
  10. package/dist/{chunk-IPUTC5EX.js → chunk-L2RJPVHV.js} +142 -16
  11. package/dist/{chunk-AXKERUXH.js → chunk-NQJSPMY2.js} +3 -3
  12. package/dist/{chunk-PA4C452B.js → chunk-SJFZPS65.js} +3 -1
  13. package/dist/{chunk-NBYSFFCO.js → chunk-VAV2IJ3R.js} +3 -1
  14. package/dist/{chunk-GOIDKTBE.js → chunk-YFDQIUQ3.js} +7 -7
  15. package/dist/{ci-IIMLOXFH.js → ci-QD2Q7NWY.js} +4 -4
  16. package/dist/{ci-format-FMBJC3EY.js → ci-format-42XIZO5P.js} +2 -2
  17. package/dist/{constants-55QQ3RYE.js → constants-5CMEFZQB.js} +3 -1
  18. package/dist/{constants-7NVAPQVR.js → constants-NMASHFDL.js} +3 -1
  19. package/dist/{doctor-cli-ZHZ2XOF3.js → doctor-cli-IOVSHBDI.js} +4 -4
  20. package/dist/electron-server.js +148 -22
  21. package/dist/{hub-MF53NIM2.js → hub-ZLF6GMQD.js} +1 -1
  22. package/dist/index.js +18 -18
  23. package/dist/{persistent-memory-LCOKUDTM.js → persistent-memory-GJE7HKVK.js} +2 -2
  24. package/dist/{persistent-memory-NACQW2VB.js → persistent-memory-MBSBTBGY.js} +2 -2
  25. package/dist/{pr-NHWE5FW7.js → pr-SXRW24JG.js} +4 -4
  26. package/dist/{run-tests-ZG5X25BJ.js → run-tests-EQCAMFQE.js} +2 -2
  27. package/dist/{run-tests-EUPJLDXS.js → run-tests-V3N7YV3P.js} +2 -2
  28. package/dist/{server-PG7QCH53.js → server-GGEO7SA2.js} +13 -13
  29. package/dist/{server-PNYRE3AL.js → server-MO3EU2XD.js} +5 -5
  30. package/dist/{task-orchestrator-WAJTCE6D.js → task-orchestrator-JGEEQ2OE.js} +5 -5
  31. package/dist/{usage-DOES3DOS.js → usage-B7RIAPPT.js} +2 -2
  32. package/package.json +1 -1
@@ -50,7 +50,7 @@ import {
50
50
  touchMemoryReferences,
51
51
  updateMemoryApproval,
52
52
  updateMemoryEntry
53
- } from "./chunk-YPOWDFOV.js";
53
+ } from "./chunk-CIM2PV2F.js";
54
54
  import {
55
55
  DEFAULT_PATTERNS,
56
56
  redactJson,
@@ -66,7 +66,7 @@ import {
66
66
  } from "./chunk-CGLYJRFA.js";
67
67
  import {
68
68
  runTestsTool
69
- } from "./chunk-SZ4226XY.js";
69
+ } from "./chunk-KRCYR46A.js";
70
70
  import {
71
71
  AGENTIC_BEHAVIOR_GUIDELINE,
72
72
  APP_NAME,
@@ -84,6 +84,7 @@ import {
84
84
  DESCRIPTION,
85
85
  DEV_STATE_FILE_NAME,
86
86
  HISTORY_DIR_NAME,
87
+ MAX_GLOB_MATCHES,
87
88
  MCP_CALL_TIMEOUT,
88
89
  MCP_CONNECT_TIMEOUT,
89
90
  MCP_PROJECT_CONFIG_NAME,
@@ -100,7 +101,7 @@ import {
100
101
  SUBAGENT_MAX_ROUNDS_LIMIT,
101
102
  VERSION,
102
103
  buildUserIdentityPrompt
103
- } from "./chunk-PA4C452B.js";
104
+ } from "./chunk-SJFZPS65.js";
104
105
 
105
106
  // src/web/server.ts
106
107
  import express from "express";
@@ -6152,7 +6153,8 @@ Important rules:
6152
6153
  4. To delete directories, use Remove-Item -Recurse (the system will automatically optimize to a more reliable method).
6153
6154
  5. IMPORTANT: On Windows, "curl" is an alias for Invoke-WebRequest and does NOT support curl flags like -s, -X, -H. Use Invoke-RestMethod instead for HTTP requests. Example: Invoke-RestMethod -Uri "http://localhost:3000/api/health" -Method Get
6154
6155
  6. NEVER run long-running / never-exiting commands through bash \u2014 they block until timeout. This includes starting an Android emulator (emulator -avd X), streaming logs (adb logcat), and dev servers (node server.js, npm run dev, metro / react-native start). Use the 'task_create' tool to run these in the background, then poll status with short bash calls (e.g. adb shell getprop sys.boot_completed).
6155
- 7. CRITICAL \u2014 this is PowerShell, NOT bash: \\ is NOT an escape character. Writing \\" inside a double-quoted string CLOSES the string and silently splits your command into fragments \u2014 it often still exits 0 with no output, so it looks like it worked when it did not. To escape a quote use \`" or "". For anything with nested quoting (especially ssh + psql -c "SELECT ..."), do NOT try to escape your way out: write the payload to a file with the 'write_file' tool, 'scp' it to the host, and run it with a single level of quoting (e.g. ssh host "psql -d db -f /tmp/x.sql").` : `Execute commands in ${SHELL2}.
6156
+ 7. CRITICAL \u2014 this is PowerShell, NOT bash: \\ is NOT an escape character. Writing \\" inside a double-quoted string CLOSES the string and silently splits your command into fragments \u2014 it often still exits 0 with no output, so it looks like it worked when it did not. To escape a quote use \`" or "". For anything with nested quoting (especially ssh + psql -c "SELECT ..."), do NOT try to escape your way out: write the payload to a file with the 'write_file' tool, 'scp' it to the host, and run it with a single level of quoting (e.g. ssh host "psql -d db -f /tmp/x.sql").
6157
+ 8. CRITICAL \u2014 running a program by its full path: a quoted string at the START of a statement is parsed as a string EXPRESSION, not a command. "C:\\path\\python.exe" -c "print(1)" is a SYNTAX ERROR. Put the call operator '&' in front: & "C:\\path\\python.exe" -c "print(1)" \u2014 or $py = "C:\\path\\python.exe"; & $py -c "print(1)". This applies to any quoted path used as a command, anywhere a statement starts (including after ';').` : `Execute commands in ${SHELL2}.
6156
6158
  Important rules:
6157
6159
  1. Each bash call runs in an independent subprocess; cd commands do not persist. To run in a specific directory, use the cwd parameter, or combine commands: e.g. "cd mydir && ls" or "mkdir -p mydir && touch mydir/file.txt".
6158
6160
  2. If a command fails (returns an error or non-zero exit code), stop immediately, report the error to the user, and do not retry the same or similar commands.
@@ -6407,6 +6409,116 @@ function detectPowerShellBackslashQuote(command) {
6407
6409
  }
6408
6410
  return false;
6409
6411
  }
6412
+ var PS_OPERATOR_WORDS = /* @__PURE__ */ new Set([
6413
+ "eq",
6414
+ "ne",
6415
+ "gt",
6416
+ "ge",
6417
+ "lt",
6418
+ "le",
6419
+ "ceq",
6420
+ "cne",
6421
+ "cgt",
6422
+ "cge",
6423
+ "clt",
6424
+ "cle",
6425
+ "ieq",
6426
+ "ine",
6427
+ "igt",
6428
+ "ige",
6429
+ "ilt",
6430
+ "ile",
6431
+ "like",
6432
+ "notlike",
6433
+ "match",
6434
+ "notmatch",
6435
+ "clike",
6436
+ "cnotlike",
6437
+ "cmatch",
6438
+ "cnotmatch",
6439
+ "ilike",
6440
+ "inotlike",
6441
+ "imatch",
6442
+ "inotmatch",
6443
+ "contains",
6444
+ "notcontains",
6445
+ "ccontains",
6446
+ "cnotcontains",
6447
+ "icontains",
6448
+ "inotcontains",
6449
+ "in",
6450
+ "notin",
6451
+ "cin",
6452
+ "cnotin",
6453
+ "iin",
6454
+ "inotin",
6455
+ "is",
6456
+ "isnot",
6457
+ "as",
6458
+ "and",
6459
+ "or",
6460
+ "not",
6461
+ "xor",
6462
+ "band",
6463
+ "bor",
6464
+ "bnot",
6465
+ "bxor",
6466
+ "shl",
6467
+ "shr",
6468
+ "join",
6469
+ "split",
6470
+ "replace",
6471
+ "csplit",
6472
+ "creplace",
6473
+ "isplit",
6474
+ "ireplace",
6475
+ "f"
6476
+ ]);
6477
+ function detectMissingCallOperator(command) {
6478
+ if (!IS_WINDOWS3) return false;
6479
+ let atStatementStart = true;
6480
+ let afterCallOperator = false;
6481
+ for (let i = 0; i < command.length; i++) {
6482
+ const ch = command[i];
6483
+ if (ch === " " || ch === " ") continue;
6484
+ if (ch === ";" || ch === "\n" || ch === "{" || ch === "(" || ch === "|" || ch === "&") {
6485
+ if (ch === "&") {
6486
+ const next = command.slice(i + 1).replace(/^[ \t]+/, "");
6487
+ afterCallOperator = !next.startsWith("&");
6488
+ } else {
6489
+ afterCallOperator = false;
6490
+ }
6491
+ atStatementStart = true;
6492
+ continue;
6493
+ }
6494
+ if (ch === "." && atStatementStart) {
6495
+ afterCallOperator = true;
6496
+ continue;
6497
+ }
6498
+ if ((ch === '"' || ch === "'") && atStatementStart && !afterCallOperator) {
6499
+ const quote = ch;
6500
+ let j = i + 1;
6501
+ while (j < command.length && command[j] !== quote) j++;
6502
+ if (j >= command.length) return false;
6503
+ const rest = command.slice(j + 1);
6504
+ const m = /^[ \t]+(\S+)/.exec(rest);
6505
+ if (m) {
6506
+ const token = m[1];
6507
+ if (/^[-]/.test(token)) {
6508
+ const word = token.slice(1).toLowerCase();
6509
+ if (PS_OPERATOR_WORDS.has(word)) return false;
6510
+ return true;
6511
+ }
6512
+ if (/^[+*%=<>|;)}\]]/.test(token)) return false;
6513
+ return true;
6514
+ }
6515
+ return false;
6516
+ }
6517
+ atStatementStart = false;
6518
+ afterCallOperator = false;
6519
+ }
6520
+ return false;
6521
+ }
6410
6522
  var BACKSLASH_QUOTE_SILENT_WARNING = `
6411
6523
 
6412
6524
  \u26A0 WARNING: this command contains \\" inside a double-quoted string, but PowerShell does NOT treat \\ as an escape \u2014 that quote CLOSED the string and the command was split into fragments. It exited 0 with no output because the outer program (e.g. ssh) still ran, but it very likely did NOT run what you intended. Do NOT assume this succeeded.
@@ -6487,6 +6599,11 @@ function buildErrorHint(command, stderr) {
6487
6599
  `Hint: PowerShell does NOT treat \\ as an escape character \u2014 the \\" in this command closed the double-quoted string and split the command into fragments. Escape quotes with \`" or "" instead. Better: avoid nested quoting entirely \u2014 write the payload to a file with 'write_file', 'scp' it over, and run it with one level of quoting (e.g. ssh host "psql -d <db> -f /tmp/x.sql").`
6488
6600
  );
6489
6601
  }
6602
+ if (detectMissingCallOperator(command) && /(ParserError|UnexpectedToken|Unexpected token|意外的标记|运算符后面提供|必须在)/i.test(stderr)) {
6603
+ hints.push(
6604
+ `Hint: in PowerShell a quoted string at the START of a statement is parsed as a string EXPRESSION, not as a command \u2014 so "C:\\path\\python.exe" -c "..." is a syntax error, not a quoting problem. Do NOT retry by removing the quotes, dropping the argument, or re-quoting it differently; all of those fail the same way. Fix: put the call operator '&' in front \u2014 \`& "C:\\path\\python.exe" -c "..."\` \u2014 or assign the path to a variable first (\`$py = "C:\\path\\python.exe"; & $py -c "..."\`).`
6605
+ );
6606
+ }
6490
6607
  return hints.length > 0 ? hints.map((h) => `\u{1F4A1} ${h}`).join("\n\n") : null;
6491
6608
  }
6492
6609
  function detectBlockingCommand(command) {
@@ -7031,7 +7148,7 @@ ${err.message}`;
7031
7148
  if (IMAGE_EXTENSIONS.has(ext)) {
7032
7149
  return `[Image file: ${filePath} (${ext})]
7033
7150
  read_file cannot return image content \u2014 tool results are text-only, so no tool can put an image into your context.
7034
- To have an image looked at, ask the USER to reference it from their input line with @${filePath} (they can use a glob for a batch, e.g. @dir/*.png, up to 20 at a time). A vision-capable model must be active, or the reference is rejected.
7151
+ To have an image looked at, ask the USER to reference it from their input line with @${filePath} (they can use a glob for a batch, e.g. @dir/*.png, up to ${MAX_GLOB_MATCHES} at a time). A vision-capable model must be active, or the reference is rejected.
7035
7152
  Do NOT claim you inspected this image \u2014 you have not seen it.`;
7036
7153
  }
7037
7154
  return `[Binary file: ${filePath} (${ext})]
@@ -8207,7 +8324,7 @@ var RuleBasedActionClassifier = class {
8207
8324
  var defaultActionClassifier = new RuleBasedActionClassifier();
8208
8325
 
8209
8326
  // src/tools/executor.ts
8210
- var PS_ERROR_RECORD_HEAD = /^(?:[\w.\-]+\s:\s)?(?:At line:\d+ char:\s*\d+|所在位置\s+行:\d+\s+字符:\s*\d+)\s*$/;
8327
+ var PS_ERROR_RECORD_HEAD = /^(?:[\w.\-]+\s:\s)?(?:At (?:line:\d+|\S+:\d+) char:\s*\d+|所在位置\s+(?:行|\S+):\d+\s+字符:\s*\d+)\s*$/;
8211
8328
  var ERROR_SIGNATURE = new RegExp(
8212
8329
  [
8213
8330
  // Python / .NET / Java: "OSError: …", "pkg.SomeException: …"
@@ -8223,11 +8340,22 @@ var ERROR_SIGNATURE = new RegExp(
8223
8340
  "i"
8224
8341
  );
8225
8342
  var PY_TRACEBACK_FRAME = /^\s*File ".*", line \d+/;
8343
+ function isPreviewNoise(line) {
8344
+ const t = line.trim();
8345
+ return /^(?:\[[^\]]+\]\s*)?Exit code \d+:$/.test(t) || // `formatFailureHeader()` 在拿不到退出码时打的那句 —— 与 "Exit code N:" 同类噪声。
8346
+ // 不过滤的话它会占掉第一个展示位:2026-09-05 实战里 `export_slides.ps1 | Select-Object
8347
+ // -First 3` 提前掐断管道被 PowerShell 报成失败,预览成了
8348
+ // 「Command failed before exit code could be determined: · …\slide-02.png」——
8349
+ // 两段都没用,而真正有信息的 `EXPORTED 25 slide(s)` 就在第二行、从没上屏。
8350
+ /^(?:\[[^\]]+\]\s*)?Command failed before exit code could be determined:$/.test(t) || /^Traceback \(most recent call last\):$/.test(t) || line.startsWith("[Command failed") || line.startsWith("\u{1F4A1} ") || t === "";
8351
+ }
8226
8352
  function buildErrorPreview(content) {
8227
8353
  const raw = content.split("\n").map((l) => l.replace(/\r+$/, ""));
8228
8354
  const undecorated = [];
8355
+ const decorationNeighbours = [];
8229
8356
  for (let i = 0; i < raw.length; i++) {
8230
8357
  if (PS_ERROR_RECORD_HEAD.test(raw[i])) {
8358
+ if (undecorated.length > 0) decorationNeighbours.push(undecorated[undecorated.length - 1]);
8231
8359
  i++;
8232
8360
  while (i < raw.length && /^\s*\+ /.test(raw[i])) i++;
8233
8361
  i--;
@@ -8235,14 +8363,7 @@ function buildErrorPreview(content) {
8235
8363
  }
8236
8364
  undecorated.push(raw[i]);
8237
8365
  }
8238
- const meaningful = undecorated.filter(
8239
- (l) => !/^(?:\[[^\]]+\]\s*)?Exit code \d+:$/.test(l.trim()) && // `formatFailureHeader()` 在拿不到退出码时打的那句 —— 与 "Exit code N:" 同类噪声。
8240
- // 不过滤的话它会占掉第一个展示位:2026-09-05 实战里 `export_slides.ps1 | Select-Object
8241
- // -First 3` 提前掐断管道被 PowerShell 报成失败,预览成了
8242
- // 「Command failed before exit code could be determined: · …\slide-02.png」——
8243
- // 两段都没用,而真正有信息的 `EXPORTED 25 slide(s)` 就在第二行、从没上屏。
8244
- !/^(?:\[[^\]]+\]\s*)?Command failed before exit code could be determined:$/.test(l.trim()) && !/^Traceback \(most recent call last\):$/.test(l.trim()) && !l.startsWith("[Command failed") && !l.startsWith("\u{1F4A1} ") && l.trim() !== ""
8245
- );
8366
+ const meaningful = undecorated.filter((l) => !isPreviewNoise(l));
8246
8367
  let primary = -1;
8247
8368
  for (let i = meaningful.length - 1; i >= 0; i--) {
8248
8369
  if (ERROR_SIGNATURE.test(meaningful[i])) {
@@ -8261,7 +8382,12 @@ function buildErrorPreview(content) {
8261
8382
  }
8262
8383
  previewLines = frame !== null ? [frame, meaningful[primary]] : [meaningful[primary]];
8263
8384
  } else {
8264
- previewLines = meaningful.length > 2 ? [meaningful[0], meaningful[meaningful.length - 1]] : meaningful.slice(0, 2);
8385
+ const neighbour = decorationNeighbours.find((l) => !isPreviewNoise(l));
8386
+ if (neighbour !== void 0) {
8387
+ previewLines = [neighbour];
8388
+ } else {
8389
+ previewLines = meaningful.length > 2 ? [meaningful[0], meaningful[meaningful.length - 1]] : meaningful.slice(0, 2);
8390
+ }
8265
8391
  }
8266
8392
  const preview = previewLines.map((l) => l.length > 160 ? l.slice(0, 160) + "\u2026" : l).join(" \xB7 ") || content.slice(0, 120);
8267
8393
  return preview.slice(0, 240);
@@ -17266,7 +17392,7 @@ Cache: write=${cacheCreate} read=${cacheRead}` : "";
17266
17392
  Cost: ${formatCost(cost)}` : "";
17267
17393
  let memoryLine = "";
17268
17394
  try {
17269
- const { countPendingMemories: countPendingMemories2 } = await import("./persistent-memory-LCOKUDTM.js");
17395
+ const { countPendingMemories: countPendingMemories2 } = await import("./persistent-memory-GJE7HKVK.js");
17270
17396
  const pending = countPendingMemories2(ctx.config.getConfigDir());
17271
17397
  if (pending > 0) memoryLine = `
17272
17398
  Memory: \u26A0 ${pending} pending approval \u2014 see the Memory panel or /memory`;
@@ -18254,7 +18380,7 @@ async function handleTest(args, ctx) {
18254
18380
  const isCommand = argStr.includes(" ") || /^(mvn|gradle|npm|pytest|cargo|go)\b/.test(argStr);
18255
18381
  testArgs = isCommand ? { command: argStr } : { filter: argStr };
18256
18382
  }
18257
- const runTests = ctx.runTests ?? (await import("./run-tests-EUPJLDXS.js")).executeTests;
18383
+ const runTests = ctx.runTests ?? (await import("./run-tests-V3N7YV3P.js")).executeTests;
18258
18384
  const report = await runTests(testArgs);
18259
18385
  ctx.send({ type: "info", message: report });
18260
18386
  } catch (err) {
@@ -18645,7 +18771,7 @@ async function handleMemory(args, ctx) {
18645
18771
  }
18646
18772
  if (intent.kind === "status") {
18647
18773
  const { getChatIndexStatus: getChatIndexStatus2 } = await import("./chat-index-DGUOUUQW.js");
18648
- const { listMemoryEntries: listMemoryEntries2, isMemoryExpired: isMemoryExpired2, formatMemoryForPrompt: formatMemoryForPrompt2 } = await import("./persistent-memory-LCOKUDTM.js");
18774
+ const { listMemoryEntries: listMemoryEntries2, isMemoryExpired: isMemoryExpired2, formatMemoryForPrompt: formatMemoryForPrompt2 } = await import("./persistent-memory-GJE7HKVK.js");
18649
18775
  const memories = listMemoryEntries2(configDir, { includeExpired: true, includeRejected: true });
18650
18776
  const injected = formatMemoryForPrompt2(configDir, process.cwd(), ctx.config.get("memory")?.maxChars);
18651
18777
  const view = buildMemoryStatusView({
@@ -18668,7 +18794,7 @@ async function handleMemory(args, ctx) {
18668
18794
  return;
18669
18795
  }
18670
18796
  if (intent.kind === "recall") {
18671
- const { searchPersistentMemories: searchPersistentMemories2, touchMemoryReferences: touchMemoryReferences2 } = await import("./persistent-memory-LCOKUDTM.js");
18797
+ const { searchPersistentMemories: searchPersistentMemories2, touchMemoryReferences: touchMemoryReferences2 } = await import("./persistent-memory-GJE7HKVK.js");
18672
18798
  const { searchChatMemory: searchChatMemory2 } = await import("./chat-index-DGUOUUQW.js");
18673
18799
  const persistentHits = searchPersistentMemories2(configDir, intent.query, process.cwd(), 3);
18674
18800
  if (persistentHits.length > 0) {
@@ -18789,7 +18915,7 @@ async function handleMemory(args, ctx) {
18789
18915
  ctx.handleMemoryManage(intent.action, args[1], intent.action === "expire" ? args[2] : void 0);
18790
18916
  } else if (intent.kind === "export") {
18791
18917
  if (args[1] === "md") {
18792
- const { exportMemoryEntries: exportMemoryEntries2 } = await import("./persistent-memory-LCOKUDTM.js");
18918
+ const { exportMemoryEntries: exportMemoryEntries2 } = await import("./persistent-memory-GJE7HKVK.js");
18793
18919
  ctx.send({
18794
18920
  type: "export_data",
18795
18921
  format: "md",
@@ -19794,7 +19920,7 @@ No tools match "${filter}".
19794
19920
  const { join: join29 } = await import("path");
19795
19921
  const { existsSync: existsSync33 } = await import("fs");
19796
19922
  const { getGitRoot: getGitRoot2 } = await import("./git-context-VNCA2GU7.js");
19797
- const { MCP_PROJECT_CONFIG_NAME: MCP_PROJECT_CONFIG_NAME2 } = await import("./constants-55QQ3RYE.js");
19923
+ const { MCP_PROJECT_CONFIG_NAME: MCP_PROJECT_CONFIG_NAME2 } = await import("./constants-5CMEFZQB.js");
19798
19924
  const { approveProject, hashMcpFile } = await import("./project-trust-MUG325AW.js");
19799
19925
  const cwd = process.cwd();
19800
19926
  const projectRoot = getGitRoot2(cwd) ?? cwd;
@@ -20713,7 +20839,7 @@ function createReviewCommands() {
20713
20839
  usage: "/test [command|filter]",
20714
20840
  async execute(args, ctx) {
20715
20841
  try {
20716
- const { executeTests } = await import("./run-tests-EUPJLDXS.js");
20842
+ const { executeTests } = await import("./run-tests-V3N7YV3P.js");
20717
20843
  const argStr = args.join(" ").trim();
20718
20844
  let testArgs = {};
20719
20845
  if (argStr) {
@@ -158,7 +158,7 @@ ${content}`);
158
158
  }
159
159
  }
160
160
  async function runTaskMode(config, providers, configManager, topic) {
161
- const { TaskOrchestrator } = await import("./task-orchestrator-WAJTCE6D.js");
161
+ const { TaskOrchestrator } = await import("./task-orchestrator-JGEEQ2OE.js");
162
162
  const orchestrator = new TaskOrchestrator(config, providers, configManager);
163
163
  let interrupted = false;
164
164
  const onSigint = () => {
package/dist/index.js CHANGED
@@ -24,7 +24,7 @@ import {
24
24
  setupProxy,
25
25
  snapshotFile,
26
26
  stripRoutingTags
27
- } from "./chunk-GOIDKTBE.js";
27
+ } from "./chunk-YFDQIUQ3.js";
28
28
  import {
29
29
  CostTracker,
30
30
  getPricing,
@@ -50,7 +50,7 @@ import {
50
50
  setMaxOutputCap,
51
51
  spawnAgentContext,
52
52
  undoStack
53
- } from "./chunk-IPUTC5EX.js";
53
+ } from "./chunk-L2RJPVHV.js";
54
54
  import "./chunk-HLWUDRBO.js";
55
55
  import {
56
56
  NO_THINKING,
@@ -63,7 +63,7 @@ import {
63
63
  countPendingMemories,
64
64
  detectStaleLegacyMarkdownEdit,
65
65
  formatMemoryForPrompt
66
- } from "./chunk-3ZABGT3S.js";
66
+ } from "./chunk-AHL6KOGM.js";
67
67
  import "./chunk-LF67HWWR.js";
68
68
  import "./chunk-XJOK5353.js";
69
69
  import "./chunk-WQ3OMEC4.js";
@@ -84,14 +84,14 @@ import {
84
84
  import {
85
85
  loadContextFiles,
86
86
  writeCrashLog
87
- } from "./chunk-AXKERUXH.js";
87
+ } from "./chunk-NQJSPMY2.js";
88
88
  import {
89
89
  getActivePluginAssets,
90
90
  getPendingHookTrust,
91
91
  installFlushOnExit,
92
92
  mergePluginHooks,
93
93
  runLifecycleHooks
94
- } from "./chunk-Q4DAKI7I.js";
94
+ } from "./chunk-5GQL4TSZ.js";
95
95
  import "./chunk-RS7SKYTS.js";
96
96
  import {
97
97
  ProviderRegistry,
@@ -99,7 +99,7 @@ import {
99
99
  } from "./chunk-VXEF2SWG.js";
100
100
  import {
101
101
  ConfigManager
102
- } from "./chunk-NFLE34QG.js";
102
+ } from "./chunk-AQF6IXSR.js";
103
103
  import {
104
104
  CONTENT_ONLY_STREAM_REMINDER,
105
105
  TEE_FINAL_USER_NUDGE,
@@ -133,7 +133,7 @@ import {
133
133
  } from "./chunk-IW3Q7AE5.js";
134
134
  import "./chunk-XNFIYS7G.js";
135
135
  import "./chunk-4BKXL7SM.js";
136
- import "./chunk-I6RATYRF.js";
136
+ import "./chunk-4W6VDVQU.js";
137
137
  import {
138
138
  AGENTIC_BEHAVIOR_GUIDELINE,
139
139
  AUTHOR,
@@ -144,13 +144,14 @@ import {
144
144
  DEFAULT_MAX_TOOL_ROUNDS,
145
145
  DESCRIPTION,
146
146
  DEV_STATE_FILE_NAME,
147
+ MAX_GLOB_MATCHES,
147
148
  MCP_PROJECT_CONFIG_NAME,
148
149
  PLAN_MODE_READONLY_TOOLS,
149
150
  PLAN_MODE_SYSTEM_ADDON,
150
151
  SKILLS_DIR_NAME,
151
152
  VERSION,
152
153
  buildUserIdentityPrompt
153
- } from "./chunk-NBYSFFCO.js";
154
+ } from "./chunk-VAV2IJ3R.js";
154
155
 
155
156
  // src/index.ts
156
157
  import { program } from "commander";
@@ -1102,7 +1103,6 @@ var IMAGE_MIME = {
1102
1103
  ".webp": "image/webp"
1103
1104
  };
1104
1105
  var MAX_IMAGE_BYTES = 10 * 1024 * 1024;
1105
- var MAX_GLOB_MATCHES = 30;
1106
1106
  function expandGlob(rawPath, cwd) {
1107
1107
  const pat = basename(rawPath);
1108
1108
  if (!/[*?]/.test(pat)) return { kind: "notglob" };
@@ -4062,7 +4062,7 @@ program.command("web").description("Start Web UI server with browser-based chat
4062
4062
  console.error("Error: Invalid port number. Must be between 1 and 65535.");
4063
4063
  process.exit(1);
4064
4064
  }
4065
- const { startWebServer } = await import("./server-PG7QCH53.js");
4065
+ const { startWebServer } = await import("./server-GGEO7SA2.js");
4066
4066
  await startWebServer({ port, host: options.host });
4067
4067
  });
4068
4068
  program.command("user [action] [username]").description("Manage Web UI users (list | create <name> | delete <name> | reset-password <name> | logout-all <name> | migrate <name>)").action(async (action, username) => {
@@ -4229,11 +4229,11 @@ program.command("sessions").description("List recent conversation sessions").opt
4229
4229
  console.log(footer + "\n");
4230
4230
  });
4231
4231
  program.command("usage").description("Show token + cost usage grouped by provider/model (cross-session)").option("--days <n>", "Only the last N days (inclusive of today)").option("--month <ym>", "Only a specific month, format YYYY-MM (e.g. 2026-06)").option("--json", "Output as JSON (for scripting)").action(async (options) => {
4232
- const { runUsageCli } = await import("./usage-DOES3DOS.js");
4232
+ const { runUsageCli } = await import("./usage-B7RIAPPT.js");
4233
4233
  await runUsageCli(options);
4234
4234
  });
4235
4235
  program.command("doctor").description("Health check: API keys, config, MCP, recent crashes, tool usage, disk usage").option("--json", "Output as JSON (for scripting)").option("--reset-stats", "Reset accumulated tool usage statistics").action(async (options) => {
4236
- const { runDoctorCli } = await import("./doctor-cli-ZHZ2XOF3.js");
4236
+ const { runDoctorCli } = await import("./doctor-cli-IOVSHBDI.js");
4237
4237
  const argv = process.argv.slice(2);
4238
4238
  await runDoctorCli({
4239
4239
  json: !!options.json || argv.includes("--json"),
@@ -4242,7 +4242,7 @@ program.command("doctor").description("Health check: API keys, config, MCP, rece
4242
4242
  });
4243
4243
  program.command("batch <action> [arg] [arg2]").description("Anthropic Message Batches: submit | list | status <id> | results <id> [out] | cancel <id>").option("--dry-run", "Parse and validate input without submitting (submit only)").action(async (action, arg, arg2, options) => {
4244
4244
  try {
4245
- const batch = await import("./batch-OX27K4GG.js");
4245
+ const batch = await import("./batch-HMADXNOD.js");
4246
4246
  switch (action) {
4247
4247
  case "submit":
4248
4248
  if (!arg) {
@@ -4285,7 +4285,7 @@ program.command("batch <action> [arg] [arg2]").description("Anthropic Message Ba
4285
4285
  }
4286
4286
  });
4287
4287
  program.command("mcp-serve").description("Start an MCP server over STDIO, exposing aicli's built-in tools to Claude Desktop / Cursor / other MCP clients").option("--allow-destructive", "Allow bash / run_interactive / task_create (always destructive in MCP mode)").option("--allow-outside-cwd", "Allow tool path arguments to escape the sandbox root \u2014 disabled by default").option("--tools <list>", "Comma-separated whitelist of tools to expose (default: all eligible tools)").option("--cwd <path>", "Working directory AND sandbox root (default: current directory)").action(async (options) => {
4288
- const { startMcpServer } = await import("./server-PNYRE3AL.js");
4288
+ const { startMcpServer } = await import("./server-MO3EU2XD.js");
4289
4289
  await startMcpServer({
4290
4290
  allowDestructive: !!options.allowDestructive,
4291
4291
  allowOutsideCwd: !!options.allowOutsideCwd,
@@ -4298,7 +4298,7 @@ program.command("pr <action> [target]").description("PR review helpers: review |
4298
4298
  console.error(`Unknown pr action: ${action}. Use review | security-review | summarize.`);
4299
4299
  process.exit(1);
4300
4300
  }
4301
- const { runPrCli } = await import("./pr-NHWE5FW7.js");
4301
+ const { runPrCli } = await import("./pr-SXRW24JG.js");
4302
4302
  const result = await runPrCli({
4303
4303
  action,
4304
4304
  target,
@@ -4318,8 +4318,8 @@ program.command("pr <action> [target]").description("PR review helpers: review |
4318
4318
  process.exit(result.exitCode);
4319
4319
  });
4320
4320
  program.command("ci").description("Headless PR review (code + security) \u2014 reads git/gh diff, optionally posts to PR. Designed for GitHub Actions.").option("--pr <num>", "PR number or URL; diff fetched via gh pr diff <value>", (v) => /^#?\d+$/.test(v) ? parseInt(v.replace(/^#/, ""), 10) : v).option("--base <ref>", "Base ref for git diff <ref>...HEAD (ignored when --pr set)").option("--post", "Post review as a PR comment (requires gh CLI + GH_TOKEN, needs --pr)").option("--no-update", "Always create a new comment instead of updating the previous aicli review").option("--skip-code", "Skip the code review section").option("--skip-security", "Skip the security review section").option("--detailed", "Use the detailed code-review prompt").option("--max-diff <n>", "Max diff chars sent to the model (default 30000)", (v) => parseInt(v, 10)).option("--provider <id>", "Override provider (default: config.defaultProvider)").option("--model <id>", "Override model").option("--dry-run", "Print result to stdout instead of posting (overrides --post)").option("--json", "Output a structured JSON report").option("--markdown", "Output Markdown report (default)").option("--sarif", "Output SARIF 2.1.0 for code scanning artifacts").option("--fail-on-security-high", "Fail when the security review contains HIGH/CRITICAL findings (default)").option("--no-fail-on-security-high", "Do not fail on security HIGH/CRITICAL findings").option("--fail-on-test-failure", "Fail when the report mentions test failures (default)").option("--no-fail-on-test-failure", "Do not fail on test failure findings").option("--fail-on-lint-failure", "Fail when the report mentions lint/typecheck failures (default)").option("--no-fail-on-lint-failure", "Do not fail on lint/typecheck failure findings").action(async (options) => {
4321
- const { runCi } = await import("./ci-IIMLOXFH.js");
4322
- const { formatCiResult } = await import("./ci-format-FMBJC3EY.js");
4321
+ const { runCi } = await import("./ci-QD2Q7NWY.js");
4322
+ const { formatCiResult } = await import("./ci-format-42XIZO5P.js");
4323
4323
  const formats = [options.json, options.markdown, options.sarif].filter(Boolean).length;
4324
4324
  if (formats > 1) {
4325
4325
  console.error("Choose only one output format: --json, --markdown, or --sarif.");
@@ -4478,7 +4478,7 @@ program.command("hub [topic]").description("Start multi-agent hub (discuss / bra
4478
4478
  config.get("customProviders"),
4479
4479
  config.getConfigDir()
4480
4480
  );
4481
- const { startHub } = await import("./hub-MF53NIM2.js");
4481
+ const { startHub } = await import("./hub-ZLF6GMQD.js");
4482
4482
  await startHub(
4483
4483
  {
4484
4484
  topic: topic ?? "",
@@ -27,11 +27,11 @@ import {
27
27
  touchMemoryReferences,
28
28
  updateMemoryApproval,
29
29
  updateMemoryEntry
30
- } from "./chunk-YPOWDFOV.js";
30
+ } from "./chunk-CIM2PV2F.js";
31
31
  import "./chunk-FSC6KEWU.js";
32
32
  import "./chunk-6BUTA5VW.js";
33
33
  import "./chunk-CGLYJRFA.js";
34
- import "./chunk-PA4C452B.js";
34
+ import "./chunk-SJFZPS65.js";
35
35
  export {
36
36
  addMemoryEntry,
37
37
  backupMemoryStore,
@@ -28,11 +28,11 @@ import {
28
28
  touchMemoryReferences,
29
29
  updateMemoryApproval,
30
30
  updateMemoryEntry
31
- } from "./chunk-3ZABGT3S.js";
31
+ } from "./chunk-AHL6KOGM.js";
32
32
  import "./chunk-3FEZSLGI.js";
33
33
  import "./chunk-HOSJZMQS.js";
34
34
  import "./chunk-IW3Q7AE5.js";
35
- import "./chunk-NBYSFFCO.js";
35
+ import "./chunk-VAV2IJ3R.js";
36
36
  export {
37
37
  addMemoryEntry,
38
38
  backupMemoryStore,
@@ -2,8 +2,8 @@
2
2
  import {
3
3
  countSeverity,
4
4
  runCi
5
- } from "./chunk-UFK5CTBU.js";
6
- import "./chunk-4DH5LZR5.js";
5
+ } from "./chunk-3CKJOTVM.js";
6
+ import "./chunk-3TBXHLSC.js";
7
7
  import {
8
8
  buildReviewPrompt,
9
9
  buildSecurityReviewPrompt,
@@ -17,13 +17,13 @@ import {
17
17
  } from "./chunk-VXEF2SWG.js";
18
18
  import {
19
19
  ConfigManager
20
- } from "./chunk-NFLE34QG.js";
20
+ } from "./chunk-AQF6IXSR.js";
21
21
  import "./chunk-MI4SFZGX.js";
22
22
  import "./chunk-TU3L3PW7.js";
23
23
  import "./chunk-IW3Q7AE5.js";
24
24
  import {
25
25
  VERSION
26
- } from "./chunk-NBYSFFCO.js";
26
+ } from "./chunk-VAV2IJ3R.js";
27
27
 
28
28
  // src/cli/pr.ts
29
29
  import { execFileSync } from "child_process";
@@ -2,8 +2,8 @@
2
2
  import {
3
3
  executeTests,
4
4
  runTestsTool
5
- } from "./chunk-I6RATYRF.js";
6
- import "./chunk-NBYSFFCO.js";
5
+ } from "./chunk-4W6VDVQU.js";
6
+ import "./chunk-VAV2IJ3R.js";
7
7
  export {
8
8
  executeTests,
9
9
  runTestsTool
@@ -1,8 +1,8 @@
1
1
  import {
2
2
  executeTests,
3
3
  runTestsTool
4
- } from "./chunk-SZ4226XY.js";
5
- import "./chunk-PA4C452B.js";
4
+ } from "./chunk-KRCYR46A.js";
5
+ import "./chunk-SJFZPS65.js";
6
6
  export {
7
7
  executeTests,
8
8
  runTestsTool