jinzd-ai-cli 0.4.253 → 0.4.255

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 (33) hide show
  1. package/dist/{batch-TPW2SM6G.js → batch-OWBKG6XZ.js} +2 -2
  2. package/dist/{chunk-P5JUXUBS.js → chunk-2UZ23L5P.js} +2 -2
  3. package/dist/{chunk-SC6FMQLH.js → chunk-3WKUKMBG.js} +3 -3
  4. package/dist/{chunk-YWG5KKSL.js → chunk-7QWFFLKV.js} +3 -3
  5. package/dist/{chunk-RPYNPLIE.js → chunk-B42HK6GL.js} +1 -1
  6. package/dist/{chunk-UMW33EEH.js → chunk-CU5ZNAIX.js} +1 -1
  7. package/dist/{chunk-Q4KBR2SG.js → chunk-FOC2YWOF.js} +1 -1
  8. package/dist/{chunk-OWCEONX7.js → chunk-IRSNREEO.js} +1 -1
  9. package/dist/{chunk-BZNTSGLQ.js → chunk-PSP4W2MG.js} +15 -7
  10. package/dist/{chunk-YMHARKR6.js → chunk-SMIQ6CBX.js} +1 -1
  11. package/dist/{chunk-M2QHKPRA.js → chunk-SVWIUNOA.js} +1 -1
  12. package/dist/{chunk-ABMMKA5S.js → chunk-U6OV523Y.js} +1 -1
  13. package/dist/{chunk-USG3ASQ2.js → chunk-X2V76VPG.js} +1 -1
  14. package/dist/{chunk-2JHYZUQE.js → chunk-YJ7VL7VL.js} +1 -1
  15. package/dist/{ci-DYTVVEBO.js → ci-V5GVGYZO.js} +4 -4
  16. package/dist/{ci-format-QTSA6FJJ.js → ci-format-CTGDLJTS.js} +2 -2
  17. package/dist/{constants-7KSDW6RF.js → constants-LJRYL7IN.js} +1 -1
  18. package/dist/{doctor-cli-ZOIMXV4C.js → doctor-cli-GOM2GQUK.js} +4 -4
  19. package/dist/electron-server.js +17 -9
  20. package/dist/{hub-6L2UCZAU.js → hub-4EEDUJED.js} +1 -1
  21. package/dist/index.js +116 -112
  22. package/dist/{persistent-memory-HQKE5X7Z.js → persistent-memory-DMN76UB5.js} +2 -2
  23. package/dist/{persistent-memory-QOT2TQCT.js → persistent-memory-EEAGHDFR.js} +2 -2
  24. package/dist/{pr-HMOXDXWR.js → pr-Q74YHWN2.js} +4 -4
  25. package/dist/{run-tests-RSYTYFZF.js → run-tests-ADZQ2JWI.js} +2 -2
  26. package/dist/{run-tests-JVQU3RAN.js → run-tests-N3ES4YMU.js} +2 -2
  27. package/dist/{server-O2YQGG72.js → server-HUWVPJKQ.js} +5 -5
  28. package/dist/{server-VOIG5VKM.js → server-PMEZ3HDO.js} +11 -11
  29. package/dist/{task-orchestrator-PLP3INNN.js → task-orchestrator-KLCN25OY.js} +5 -5
  30. package/dist/{usage-3EQUVK37.js → usage-MNMRX5OE.js} +2 -2
  31. package/dist/web/client/api.js +41 -0
  32. package/dist/web/client/app.js +9 -35
  33. package/package.json +2 -1
@@ -1,9 +1,9 @@
1
1
  #!/usr/bin/env node
2
2
  import {
3
3
  ConfigManager
4
- } from "./chunk-OWCEONX7.js";
4
+ } from "./chunk-IRSNREEO.js";
5
5
  import "./chunk-5ULLIOVC.js";
6
- import "./chunk-M2QHKPRA.js";
6
+ import "./chunk-SVWIUNOA.js";
7
7
  import {
8
8
  atomicWriteFileSync
9
9
  } from "./chunk-IW3Q7AE5.js";
@@ -1,7 +1,7 @@
1
1
  #!/usr/bin/env node
2
2
  import {
3
3
  truncateForPersist
4
- } from "./chunk-BZNTSGLQ.js";
4
+ } from "./chunk-PSP4W2MG.js";
5
5
  import {
6
6
  APP_NAME,
7
7
  CONFIG_DIR_NAME,
@@ -11,7 +11,7 @@ import {
11
11
  MCP_PROTOCOL_VERSION,
12
12
  MCP_TOOL_PREFIX,
13
13
  VERSION
14
- } from "./chunk-M2QHKPRA.js";
14
+ } from "./chunk-SVWIUNOA.js";
15
15
  import {
16
16
  atomicWriteFileSync
17
17
  } from "./chunk-IW3Q7AE5.js";
@@ -4,7 +4,7 @@ import {
4
4
  } from "./chunk-ZRBGH245.js";
5
5
  import {
6
6
  ConfigManager
7
- } from "./chunk-OWCEONX7.js";
7
+ } from "./chunk-IRSNREEO.js";
8
8
  import {
9
9
  getActivePluginAssets,
10
10
  getPendingHookTrust,
@@ -14,7 +14,7 @@ import {
14
14
  listHooks,
15
15
  listInstalledPlugins,
16
16
  resetStats
17
- } from "./chunk-Q4KBR2SG.js";
17
+ } from "./chunk-FOC2YWOF.js";
18
18
  import {
19
19
  getGitRoot
20
20
  } from "./chunk-HOSJZMQS.js";
@@ -26,7 +26,7 @@ import {
26
26
  MCP_PROJECT_CONFIG_NAME,
27
27
  MEMORY_FILE_NAME,
28
28
  VERSION
29
- } from "./chunk-M2QHKPRA.js";
29
+ } from "./chunk-SVWIUNOA.js";
30
30
 
31
31
  // src/diagnostics/doctor-report.ts
32
32
  import { existsSync as existsSync3, statSync as statSync2 } from "fs";
@@ -2,7 +2,7 @@
2
2
  import {
3
3
  evaluateCiGate,
4
4
  normalizeCiThresholds
5
- } from "./chunk-YMHARKR6.js";
5
+ } from "./chunk-SMIQ6CBX.js";
6
6
  import {
7
7
  buildReviewPrompt,
8
8
  buildSecurityReviewPrompt,
@@ -13,10 +13,10 @@ import {
13
13
  } from "./chunk-ZRBGH245.js";
14
14
  import {
15
15
  ConfigManager
16
- } from "./chunk-OWCEONX7.js";
16
+ } from "./chunk-IRSNREEO.js";
17
17
  import {
18
18
  VERSION
19
- } from "./chunk-M2QHKPRA.js";
19
+ } from "./chunk-SVWIUNOA.js";
20
20
 
21
21
  // src/cli/ci.ts
22
22
  import { execFileSync } from "child_process";
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  TEST_TIMEOUT
3
- } from "./chunk-UMW33EEH.js";
3
+ } from "./chunk-CU5ZNAIX.js";
4
4
 
5
5
  // src/tools/builtin/run-tests.ts
6
6
  import { execSync, spawnSync } from "child_process";
@@ -1,5 +1,5 @@
1
1
  // src/core/constants.ts
2
- var VERSION = "0.4.253";
2
+ var VERSION = "0.4.255";
3
3
  var APP_NAME = "ai-cli";
4
4
  var CONFIG_DIR_NAME = ".aicli";
5
5
  var CONFIG_FILE_NAME = "config.json";
@@ -2,7 +2,7 @@
2
2
  import {
3
3
  CONFIG_DIR_NAME,
4
4
  PLUGINS_DIR_NAME
5
- } from "./chunk-M2QHKPRA.js";
5
+ } from "./chunk-SVWIUNOA.js";
6
6
  import {
7
7
  atomicWriteFileSync
8
8
  } from "./chunk-IW3Q7AE5.js";
@@ -8,7 +8,7 @@ import {
8
8
  CONFIG_FILE_NAME,
9
9
  HISTORY_DIR_NAME,
10
10
  PLUGINS_DIR_NAME
11
- } from "./chunk-M2QHKPRA.js";
11
+ } from "./chunk-SVWIUNOA.js";
12
12
  import {
13
13
  atomicWriteFileSync
14
14
  } from "./chunk-IW3Q7AE5.js";
@@ -7,7 +7,7 @@ import {
7
7
  searchPersistentMemories,
8
8
  touchMemoryReferences,
9
9
  updateMemoryEntry
10
- } from "./chunk-USG3ASQ2.js";
10
+ } from "./chunk-X2V76VPG.js";
11
11
  import {
12
12
  indexProject
13
13
  } from "./chunk-GLSR2NR3.js";
@@ -23,7 +23,7 @@ import {
23
23
  runHook,
24
24
  runLifecycleHooks,
25
25
  runTool
26
- } from "./chunk-Q4KBR2SG.js";
26
+ } from "./chunk-FOC2YWOF.js";
27
27
  import {
28
28
  buildTruncatedArgumentsError,
29
29
  getDangerLevel,
@@ -40,14 +40,14 @@ import {
40
40
  } from "./chunk-4BKXL7SM.js";
41
41
  import {
42
42
  runTestsTool
43
- } from "./chunk-ABMMKA5S.js";
43
+ } from "./chunk-U6OV523Y.js";
44
44
  import {
45
45
  CONFIG_DIR_NAME,
46
46
  DEFAULT_MAX_TOOL_OUTPUT_CHARS_CAP,
47
47
  SUBAGENT_ALLOWED_TOOLS,
48
48
  SUBAGENT_DEFAULT_MAX_ROUNDS,
49
49
  SUBAGENT_MAX_ROUNDS_LIMIT
50
- } from "./chunk-M2QHKPRA.js";
50
+ } from "./chunk-SVWIUNOA.js";
51
51
  import {
52
52
  loadChatIndex,
53
53
  searchChatMemory
@@ -163,6 +163,16 @@ function startEvictionTimer() {
163
163
  }
164
164
  }, 6e4).unref();
165
165
  }
166
+ function buildWrappedCommand(command, id, isWindows) {
167
+ const markerStart = `AICLI_MARKER_START:${id}`;
168
+ const markerEnd = `AICLI_MARKER_END:${id}`;
169
+ if (!isWindows) {
170
+ return `echo "${markerStart}"; ${command}; echo "${markerEnd}:$?"`;
171
+ }
172
+ const inner = `${WIN_UTF8_PREAMBLE} Write-Output "${markerStart}"; ${command}; $__ok = $?; $__ec = $LASTEXITCODE; $__code = if ($__ok) { 0 } elseif ($null -ne $__ec -and $__ec -ne 0) { $__ec } else { 1 }; Write-Output "${markerEnd}:$__code"`;
173
+ const b64 = Buffer.from(inner, "utf-8").toString("base64");
174
+ return `Invoke-Expression ([System.Text.Encoding]::UTF8.GetString([System.Convert]::FromBase64String('${b64}')))`;
175
+ }
166
176
  async function execInPool(sessionKey, command, timeout, cwd, abortSignal) {
167
177
  let entry = pool.get(sessionKey);
168
178
  if (!entry || entry.proc.exitCode !== null || entry.cwd !== cwd) {
@@ -179,9 +189,7 @@ async function execInPool(sessionKey, command, timeout, cwd, abortSignal) {
179
189
  entry.lastUsed = Date.now();
180
190
  startEvictionTimer();
181
191
  const id = `${Date.now().toString(36)}_${Math.random().toString(36).slice(2, 8)}`;
182
- const markerStart = `AICLI_MARKER_START:${id}`;
183
- const markerEnd = `AICLI_MARKER_END:${id}`;
184
- const wrappedCmd = IS_WINDOWS2 ? `${WIN_UTF8_PREAMBLE} echo "${markerStart}"; ${command}; echo "${markerEnd}:0"` : `echo "${markerStart}"; ${command}; echo "${markerEnd}:$?"`;
192
+ const wrappedCmd = buildWrappedCommand(command, id, IS_WINDOWS2);
185
193
  return new Promise((resolve7) => {
186
194
  let stdout = "";
187
195
  let stderr = "";
@@ -1,7 +1,7 @@
1
1
  #!/usr/bin/env node
2
2
  import {
3
3
  VERSION
4
- } from "./chunk-M2QHKPRA.js";
4
+ } from "./chunk-SVWIUNOA.js";
5
5
 
6
6
  // src/cli/ci-format.ts
7
7
  var DEFAULT_CI_THRESHOLDS = {
@@ -1,7 +1,7 @@
1
1
  #!/usr/bin/env node
2
2
 
3
3
  // src/core/constants.ts
4
- var VERSION = "0.4.253";
4
+ var VERSION = "0.4.255";
5
5
  var APP_NAME = "ai-cli";
6
6
  var CONFIG_DIR_NAME = ".aicli";
7
7
  var CONFIG_FILE_NAME = "config.json";
@@ -1,7 +1,7 @@
1
1
  #!/usr/bin/env node
2
2
  import {
3
3
  TEST_TIMEOUT
4
- } from "./chunk-M2QHKPRA.js";
4
+ } from "./chunk-SVWIUNOA.js";
5
5
 
6
6
  // src/tools/builtin/run-tests.ts
7
7
  import { execSync, spawnSync } from "child_process";
@@ -6,7 +6,7 @@ import {
6
6
  MEMORY_FILE_NAME,
7
7
  MEMORY_MAX_CHARS,
8
8
  MEMORY_STORE_FILE_NAME
9
- } from "./chunk-M2QHKPRA.js";
9
+ } from "./chunk-SVWIUNOA.js";
10
10
  import {
11
11
  DEFAULT_PATTERNS,
12
12
  redactString
@@ -6,7 +6,7 @@ import {
6
6
  MEMORY_FILE_NAME,
7
7
  MEMORY_MAX_CHARS,
8
8
  MEMORY_STORE_FILE_NAME
9
- } from "./chunk-UMW33EEH.js";
9
+ } from "./chunk-CU5ZNAIX.js";
10
10
  import {
11
11
  atomicWriteFileSync
12
12
  } from "./chunk-6BUTA5VW.js";
@@ -3,14 +3,14 @@ import {
3
3
  CI_COMMENT_MARKER,
4
4
  countSeverity,
5
5
  runCi
6
- } from "./chunk-YWG5KKSL.js";
7
- import "./chunk-YMHARKR6.js";
6
+ } from "./chunk-7QWFFLKV.js";
7
+ import "./chunk-SMIQ6CBX.js";
8
8
  import "./chunk-HLWUDRBO.js";
9
9
  import "./chunk-ZRBGH245.js";
10
- import "./chunk-OWCEONX7.js";
10
+ import "./chunk-IRSNREEO.js";
11
11
  import "./chunk-PSXIVQ3N.js";
12
12
  import "./chunk-5ULLIOVC.js";
13
- import "./chunk-M2QHKPRA.js";
13
+ import "./chunk-SVWIUNOA.js";
14
14
  import "./chunk-IW3Q7AE5.js";
15
15
  export {
16
16
  CI_COMMENT_MARKER,
@@ -6,8 +6,8 @@ import {
6
6
  formatCiResult,
7
7
  formatCiSarif,
8
8
  normalizeCiThresholds
9
- } from "./chunk-YMHARKR6.js";
10
- import "./chunk-M2QHKPRA.js";
9
+ } from "./chunk-SMIQ6CBX.js";
10
+ import "./chunk-SVWIUNOA.js";
11
11
  export {
12
12
  DEFAULT_CI_THRESHOLDS,
13
13
  detectCiGateSignals,
@@ -38,7 +38,7 @@ import {
38
38
  TEST_TIMEOUT,
39
39
  VERSION,
40
40
  buildUserIdentityPrompt
41
- } from "./chunk-M2QHKPRA.js";
41
+ } from "./chunk-SVWIUNOA.js";
42
42
  export {
43
43
  AGENTIC_BEHAVIOR_GUIDELINE,
44
44
  APP_NAME,
@@ -2,14 +2,14 @@
2
2
  import {
3
3
  formatDoctorReport,
4
4
  runDoctorCli
5
- } from "./chunk-SC6FMQLH.js";
5
+ } from "./chunk-3WKUKMBG.js";
6
6
  import "./chunk-ZRBGH245.js";
7
- import "./chunk-OWCEONX7.js";
8
- import "./chunk-Q4KBR2SG.js";
7
+ import "./chunk-IRSNREEO.js";
8
+ import "./chunk-FOC2YWOF.js";
9
9
  import "./chunk-PSXIVQ3N.js";
10
10
  import "./chunk-5ULLIOVC.js";
11
11
  import "./chunk-HOSJZMQS.js";
12
- import "./chunk-M2QHKPRA.js";
12
+ import "./chunk-SVWIUNOA.js";
13
13
  import "./chunk-IW3Q7AE5.js";
14
14
  export {
15
15
  formatDoctorReport,
@@ -34,14 +34,14 @@ import {
34
34
  touchMemoryReferences,
35
35
  updateMemoryApproval,
36
36
  updateMemoryEntry
37
- } from "./chunk-2JHYZUQE.js";
37
+ } from "./chunk-YJ7VL7VL.js";
38
38
  import {
39
39
  redactJson,
40
40
  scanString
41
41
  } from "./chunk-YVTASHS5.js";
42
42
  import {
43
43
  runTestsTool
44
- } from "./chunk-RPYNPLIE.js";
44
+ } from "./chunk-B42HK6GL.js";
45
45
  import {
46
46
  AGENTIC_BEHAVIOR_GUIDELINE,
47
47
  APP_NAME,
@@ -73,7 +73,7 @@ import {
73
73
  SUBAGENT_MAX_ROUNDS_LIMIT,
74
74
  VERSION,
75
75
  buildUserIdentityPrompt
76
- } from "./chunk-UMW33EEH.js";
76
+ } from "./chunk-CU5ZNAIX.js";
77
77
  import {
78
78
  hasSemanticIndex,
79
79
  semanticSearch
@@ -4997,6 +4997,16 @@ function startEvictionTimer() {
4997
4997
  }
4998
4998
  }, 6e4).unref();
4999
4999
  }
5000
+ function buildWrappedCommand(command, id, isWindows) {
5001
+ const markerStart = `AICLI_MARKER_START:${id}`;
5002
+ const markerEnd = `AICLI_MARKER_END:${id}`;
5003
+ if (!isWindows) {
5004
+ return `echo "${markerStart}"; ${command}; echo "${markerEnd}:$?"`;
5005
+ }
5006
+ const inner = `${WIN_UTF8_PREAMBLE} Write-Output "${markerStart}"; ${command}; $__ok = $?; $__ec = $LASTEXITCODE; $__code = if ($__ok) { 0 } elseif ($null -ne $__ec -and $__ec -ne 0) { $__ec } else { 1 }; Write-Output "${markerEnd}:$__code"`;
5007
+ const b64 = Buffer.from(inner, "utf-8").toString("base64");
5008
+ return `Invoke-Expression ([System.Text.Encoding]::UTF8.GetString([System.Convert]::FromBase64String('${b64}')))`;
5009
+ }
5000
5010
  async function execInPool(sessionKey, command, timeout, cwd, abortSignal) {
5001
5011
  let entry = pool.get(sessionKey);
5002
5012
  if (!entry || entry.proc.exitCode !== null || entry.cwd !== cwd) {
@@ -5013,9 +5023,7 @@ async function execInPool(sessionKey, command, timeout, cwd, abortSignal) {
5013
5023
  entry.lastUsed = Date.now();
5014
5024
  startEvictionTimer();
5015
5025
  const id = `${Date.now().toString(36)}_${Math.random().toString(36).slice(2, 8)}`;
5016
- const markerStart = `AICLI_MARKER_START:${id}`;
5017
- const markerEnd = `AICLI_MARKER_END:${id}`;
5018
- const wrappedCmd = IS_WINDOWS2 ? `${WIN_UTF8_PREAMBLE} echo "${markerStart}"; ${command}; echo "${markerEnd}:0"` : `echo "${markerStart}"; ${command}; echo "${markerEnd}:$?"`;
5026
+ const wrappedCmd = buildWrappedCommand(command, id, IS_WINDOWS2);
5019
5027
  return new Promise((resolve11) => {
5020
5028
  let stdout = "";
5021
5029
  let stderr = "";
@@ -15205,7 +15213,7 @@ Cache: write=${cacheCreate} read=${cacheRead}` : "";
15205
15213
  Cost: ${formatCost(cost)}` : "";
15206
15214
  let memoryLine = "";
15207
15215
  try {
15208
- const { countPendingMemories } = await import("./persistent-memory-QOT2TQCT.js");
15216
+ const { countPendingMemories } = await import("./persistent-memory-EEAGHDFR.js");
15209
15217
  const pending = countPendingMemories(ctx.config.getConfigDir());
15210
15218
  if (pending > 0) memoryLine = `
15211
15219
  Memory: \u26A0 ${pending} pending approval \u2014 see the Memory panel or /memory`;
@@ -16014,7 +16022,7 @@ async function handleSecurityReview(args, ctx) {
16014
16022
  async function handleTest(args, ctx) {
16015
16023
  ctx.send({ type: "info", message: "\u{1F9EA} Running tests..." });
16016
16024
  try {
16017
- const { executeTests } = await import("./run-tests-JVQU3RAN.js");
16025
+ const { executeTests } = await import("./run-tests-N3ES4YMU.js");
16018
16026
  const argStr = args.join(" ").trim();
16019
16027
  let testArgs = {};
16020
16028
  if (argStr) {
@@ -16278,7 +16286,7 @@ async function handleMemory(args, ctx) {
16278
16286
  ctx.handleMemoryManage(sub, args[1], sub === "expire" ? args[2] : void 0);
16279
16287
  } else if (sub === "export") {
16280
16288
  if (args[1] === "md") {
16281
- const { exportMemoryEntries: exportMemoryEntries2 } = await import("./persistent-memory-QOT2TQCT.js");
16289
+ const { exportMemoryEntries: exportMemoryEntries2 } = await import("./persistent-memory-EEAGHDFR.js");
16282
16290
  ctx.send({
16283
16291
  type: "export_data",
16284
16292
  format: "md",
@@ -154,7 +154,7 @@ ${content}`);
154
154
  }
155
155
  }
156
156
  async function runTaskMode(config, providers, configManager, topic) {
157
- const { TaskOrchestrator } = await import("./task-orchestrator-PLP3INNN.js");
157
+ const { TaskOrchestrator } = await import("./task-orchestrator-KLCN25OY.js");
158
158
  const orchestrator = new TaskOrchestrator(config, providers, configManager);
159
159
  let interrupted = false;
160
160
  const onSigint = () => {