nolo-cli 0.254.0-alpha.1 → 0.256.0-alpha.1

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 (150) hide show
  1. package/{_executeModel-OMDET3E2.js → _executeModel-E2LL7FPO.js} +44 -43
  2. package/{action-4MADDU52.js → action-C6IQAKN4.js} +5 -5
  3. package/{addContentAction-MT4BECXT.js → addContentAction-53364YDW.js} +8 -8
  4. package/{addDialogAgentAction-ZZTJ5GBD.js → addDialogAgentAction-U5DD5EN5.js} +7 -7
  5. package/{agentDeleteCommand-5WXEECFH.js → agentDeleteCommand-ORNRRKJO.js} +59 -58
  6. package/{agentEmailCommands-3QWBB2JL.js → agentEmailCommands-2ALVFOD5.js} +60 -59
  7. package/{agentListCommands-WTEF5RKJ.js → agentListCommands-6I4NQPR4.js} +26 -25
  8. package/{agentMachineCommands-DP44GKA6.js → agentMachineCommands-PNHTIJ6A.js} +22 -21
  9. package/{agentRecordCommands-4I7P34GJ.js → agentRecordCommands-BEZPBYBM.js} +59 -58
  10. package/{agentRunCommand-VAKWFXJV.js → agentRunCommand-2T72V5KY.js} +63 -59
  11. package/{agentRunControl-5ABAIBQT.js → agentRunControl-3TIVJ3SR.js} +3 -2
  12. package/{agentRuntimeLocal-IO3GGTCJ.js → agentRuntimeLocal-3MAEFYSB.js} +18 -17
  13. package/{agentSlice-5ZSVWJHV.js → agentSlice-KOQXUPKT.js} +9 -9
  14. package/{appDeleteCommands-ZQ4ZEKTC.js → appDeleteCommands-IIOP3CZU.js} +24 -23
  15. package/{appDeployCommands-4XT7PFW5.js → appDeployCommands-S5ZNB7MA.js} +24 -23
  16. package/{appDeployStatusCommands-5RVMRYQW.js → appDeployStatusCommands-MQIGLK3T.js} +24 -23
  17. package/{appGetCommands-VH5W3RFK.js → appGetCommands-XFX4E3KR.js} +24 -23
  18. package/{appListCommands-TAHZLAL3.js → appListCommands-QR7LT4AK.js} +24 -23
  19. package/{authCommand-HBO5G6RL.js → authCommand-HKSXJT3J.js} +4 -4
  20. package/{builtinSkillRegistry-66PEOD4Y.js → builtinSkillRegistry-FVEEO4U2.js} +3 -3
  21. package/{chromeOpsCommands-AA555ANS.js → chromeOpsCommands-4UIKH26F.js} +1 -1
  22. package/{chunk-D3WOFN6N.js → chunk-223KZUJ6.js} +1 -1
  23. package/{chunk-4Z7Q4QZF.js → chunk-2RZBFJEG.js} +1014 -43
  24. package/{chunk-AX63ZU2W.js → chunk-3GGVFHWI.js} +4 -4
  25. package/{chunk-2RCMFPUZ.js → chunk-46FETNLF.js} +2 -2
  26. package/{chunk-CO6E7YK6.js → chunk-5P3PPQVP.js} +1 -1
  27. package/{chunk-KWARDHBI.js → chunk-6N4IKMTH.js} +37 -2
  28. package/{chunk-M7GMJBQJ.js → chunk-6VEO7Z3Y.js} +3 -3
  29. package/{chunk-2VYX3ZCR.js → chunk-6VNBJ7GI.js} +5 -5
  30. package/{chunk-MICGEDCN.js → chunk-7B55IVLF.js} +107 -27
  31. package/{chunk-GK772DEV.js → chunk-7BIJFGKS.js} +3 -3
  32. package/{chunk-3SEBCWLD.js → chunk-7EUJ65PF.js} +2057 -223
  33. package/{chunk-25BDZGD7.js → chunk-7JMBQ7YU.js} +2 -2
  34. package/{chunk-4GWNEPY6.js → chunk-7PTWFSZZ.js} +1 -1
  35. package/{chunk-CIAV4WK2.js → chunk-7WHCIA5V.js} +2 -2
  36. package/{chunk-KR4W72OK.js → chunk-ADUCBH4M.js} +45 -25
  37. package/{chunk-53UOBNTI.js → chunk-ADYWV732.js} +8 -8
  38. package/{chunk-WLHUANWZ.js → chunk-AIFQKNPP.js} +1 -1
  39. package/{chunk-GFXPPQZN.js → chunk-AKBNCTPY.js} +1 -1
  40. package/{chunk-3272HU62.js → chunk-APQBEIOQ.js} +1 -1
  41. package/{chunk-MW3XUUYS.js → chunk-APXC3SQO.js} +6 -6
  42. package/{chunk-52M4RYVP.js → chunk-BB76X6O4.js} +1 -1
  43. package/{chunk-HEUHCHAR.js → chunk-BD22OFDQ.js} +3 -3
  44. package/{chunk-ZAKWT4XQ.js → chunk-BD5YJJLJ.js} +3 -3
  45. package/{chunk-SID2TFMV.js → chunk-BXGU6274.js} +104 -55
  46. package/{chunk-SCY2O7CU.js → chunk-BZMDWGQQ.js} +2 -2
  47. package/{chunk-QV32GSVO.js → chunk-C63KMRJE.js} +1 -1
  48. package/{chunk-JKO32CCL.js → chunk-CBIGMWMI.js} +1 -1
  49. package/{chunk-JP2BH4NC.js → chunk-CEKRIR22.js} +1 -1
  50. package/{chunk-MR72IIX5.js → chunk-CVDJUPBN.js} +4 -4
  51. package/{chunk-6AJIU6OC.js → chunk-DCTQJDDQ.js} +3 -3
  52. package/{chunk-HS4JGZQH.js → chunk-DWES4SXY.js} +1 -1
  53. package/{chunk-D4CUS6NT.js → chunk-E4HBZDV6.js} +3 -3
  54. package/{chunk-2G3XMM3O.js → chunk-EXD7S7QW.js} +41 -5
  55. package/{chunk-YGDYYFRX.js → chunk-GYX6XTAI.js} +3 -5
  56. package/{chunk-VYRTLHIT.js → chunk-HDKMVYNJ.js} +1 -1
  57. package/chunk-HEVRQGGH.js +106 -0
  58. package/{chunk-4CL6QIQZ.js → chunk-HPDLPEUG.js} +2 -2
  59. package/{chunk-7STRX24O.js → chunk-IZHENZQ5.js} +8 -7
  60. package/{chunk-IGK4OXAO.js → chunk-JAGD4PSH.js} +499 -7
  61. package/{chunk-MCQXBKC6.js → chunk-JGVWHUYK.js} +2 -2
  62. package/{chunk-5UYDG6HP.js → chunk-JOJH3KWV.js} +26 -15
  63. package/{chunk-Z2ZCKNKX.js → chunk-JW6OURKM.js} +261 -228
  64. package/{chunk-VZCBYCHV.js → chunk-KG27JIG4.js} +2 -2
  65. package/{chunk-PTY2VZM5.js → chunk-KO5GO2BC.js} +6 -8
  66. package/{chunk-TA2JQUWA.js → chunk-KO5PFS74.js} +156 -1767
  67. package/{chunk-YW5L3XOO.js → chunk-LJ6WIQZO.js} +10 -10
  68. package/{chunk-OLS2J3WE.js → chunk-LLUBUHNT.js} +1 -1
  69. package/{chunk-IDCGMZLC.js → chunk-MD7O2NN2.js} +9 -9
  70. package/{chunk-XWR2YD4L.js → chunk-MLK3FEXG.js} +1 -1
  71. package/{chunk-KQBGXCKM.js → chunk-MNFUKRRU.js} +3 -3
  72. package/{chunk-YYHWEVBI.js → chunk-MUDMYJCM.js} +2 -2
  73. package/{chunk-NEDBPW44.js → chunk-NRUYSNSZ.js} +2 -2
  74. package/{chunk-UHW6SCVK.js → chunk-NUHQO3RB.js} +1 -1
  75. package/{chunk-CYGFNMCH.js → chunk-OKAXQFON.js} +1 -1
  76. package/{chunk-P4JX7YMQ.js → chunk-ONTHDYFU.js} +22 -2
  77. package/{chunk-PR25J652.js → chunk-PNBQ5JTA.js} +1 -1
  78. package/{chunk-K4LLTJUO.js → chunk-Q2MPKE4B.js} +5 -105
  79. package/{chunk-OMIXG25B.js → chunk-QGFLVQ6E.js} +1 -1
  80. package/{chunk-WMMKHEGQ.js → chunk-R3FZHW4Q.js} +12 -12
  81. package/{chunk-KZAT2M2V.js → chunk-RIWKZT7E.js} +22 -0
  82. package/{chunk-FRC2DNTN.js → chunk-RQKTCHQM.js} +1 -1
  83. package/{chunk-OWXOXKH7.js → chunk-SCAC3NM5.js} +2 -2
  84. package/{chunk-NXNHG3QT.js → chunk-SIHOY5YI.js} +21 -10
  85. package/{chunk-HKPIFK7F.js → chunk-TF427WGH.js} +5 -5
  86. package/{chunk-NMGG3NUB.js → chunk-U6QNVOR5.js} +1 -1
  87. package/{chunk-6WI4PFPP.js → chunk-V6S5OZSP.js} +68 -54
  88. package/{chunk-AIHNB5QH.js → chunk-VQR2ACSC.js} +6 -4
  89. package/{chunk-GJKEOBCV.js → chunk-WFEWP352.js} +10 -10
  90. package/{chunk-HEQJ5XND.js → chunk-WS36XPJD.js} +2 -2
  91. package/{chunk-MRYKRL2V.js → chunk-WSLL7VV4.js} +2 -2
  92. package/{dialogUsageCommand-3JMINURR.js → chunk-Y2TCTNUD.js} +19 -12
  93. package/{chunk-DNY33GGQ.js → chunk-YN23INFZ.js} +1 -1
  94. package/{chunk-5HUO7SEX.js → chunk-YQLAFJRQ.js} +1 -1
  95. package/{chunk-EG3JTV7H.js → chunk-Z3JZ2R5F.js} +2 -2
  96. package/{chunk-VPSPVLCM.js → chunk-ZMJMHXYX.js} +3 -3
  97. package/{chunk-W4S5FQWQ.js → chunk-ZTHAJU3O.js} +1 -1
  98. package/{cliAgentConfigHelpers-FKBPFPKR.js → cliAgentConfigHelpers-BXHQ3PXP.js} +2 -2
  99. package/{cliLocalAgentRecordReader-2WBUVRVD.js → cliLocalAgentRecordReader-Q6677YID.js} +22 -21
  100. package/{commandRegistry-DONNI3FW.js → commandRegistry-RNYUOKUE.js} +82 -78
  101. package/{contentThunks-THSXC6WQ.js → contentThunks-ZDBDDZP3.js} +20 -20
  102. package/{cooldownCommands-PT5L4LNB.js → cooldownCommands-Y4ZQQ35D.js} +1 -1
  103. package/{createAgentAutomationAction-WNQOJ4DG.js → createAgentAutomationAction-HEZ3G5L4.js} +20 -20
  104. package/{createDialogAction-YORDQFFC.js → createDialogAction-DK62W5VA.js} +21 -21
  105. package/{createPageAction-2S7V5OCW.js → createPageAction-W6NXHVKO.js} +21 -21
  106. package/{dbSlice-HXFRXGI3.js → dbSlice-RWPSVHBC.js} +7 -7
  107. package/{deleteFile-QDSZVTUJ.js → deleteFile-ECU6FU5C.js} +5 -5
  108. package/{dialogCommands-MEH4CVRL.js → dialogCommands-Z24IDINY.js} +28 -25
  109. package/{dialogNotifyCommand-JKYVSR6K.js → dialogNotifyCommand-IASQGEMW.js} +3 -3
  110. package/{dialogSlice-JOICDGQU.js → dialogSlice-62GISS77.js} +18 -18
  111. package/dialogTraceCommand-FDINAIZ6.js +961 -0
  112. package/dialogUsageCommand-WJ3U6KZU.js +27 -0
  113. package/{docCreateCommands-MVAYVGQ5.js → docCreateCommands-SXA4TMGJ.js} +23 -22
  114. package/{docDeleteCommands-TKXPRA3O.js → docDeleteCommands-ELXSZK3F.js} +24 -23
  115. package/{docReadCommands-MR2YKCZP.js → docReadCommands-DFLAQPI4.js} +23 -22
  116. package/{docStore-NKVLWCXX.js → docStore-UWF2PMCB.js} +8 -8
  117. package/{docUpdateCommands-VJ6A6F7F.js → docUpdateCommands-KB6M5HUH.js} +23 -22
  118. package/{handleSendMessageAction-SNNYOQ4P.js → handleSendMessageAction-ZV6OQPQG.js} +32 -32
  119. package/{hostCredentialCreate-SDQUFL23.js → hostCredentialCreate-3IA5IJFG.js} +59 -58
  120. package/index.js +7 -7
  121. package/{localRuntimeAdapter-JHYH5ZIR.js → localRuntimeAdapter-SSG5ORLZ.js} +58 -57
  122. package/{machineCommands-BXSBRM7L.js → machineCommands-ECFQMLHA.js} +59 -58
  123. package/{machineWsRunDispatch-KEXSHGSD.js → machineWsRunDispatch-7PROH7E7.js} +59 -58
  124. package/{mcpLocalAuthorizeCommand-Y3SOZFXT.js → mcpLocalAuthorizeCommand-RBXJDE6J.js} +2 -2
  125. package/{memberThunks-ZXEUM6DH.js → memberThunks-43B7UYC5.js} +9 -9
  126. package/package.json +1 -1
  127. package/{projectArchive-FDYE7VNC.js → projectArchive-JN43WW4E.js} +21 -21
  128. package/{read-T5WPCAY7.js → read-KG6INYUT.js} +5 -5
  129. package/{readDocTool-DW4DCRQG.js → readDocTool-N3GA52JR.js} +1 -1
  130. package/{readlineWorkspace-ME2C64XI.js → readlineWorkspace-D6EUSB2Q.js} +684 -874
  131. package/{removeDialogAgentAction-MXJEB77K.js → removeDialogAgentAction-EEVSOQOJ.js} +9 -9
  132. package/{runAgentClientLoop-UAGXVYW5.js → runAgentClientLoop-FEZTSUSJ.js} +51 -40
  133. package/{secretCommands-BXAQEOES.js → secretCommands-53NZFD4T.js} +2 -2
  134. package/{setDialogExtraReferencesAction-BILVMHM7.js → setDialogExtraReferencesAction-DNO5POHA.js} +8 -8
  135. package/{setPrimaryDialogAgentAction-CUBBWACR.js → setPrimaryDialogAgentAction-QABBEO4C.js} +9 -9
  136. package/{settingThunks-BRBBAGEK.js → settingThunks-DVKG4X4S.js} +10 -10
  137. package/{skillDiscovery-MDDKPTW3.js → skillDiscovery-5GEGWJ6N.js} +3 -3
  138. package/{spaceCommands-K4HHG7OO.js → spaceCommands-4ACQQNZL.js} +70 -25
  139. package/{streamAgentChatTurn-RZUB6JTH.js → streamAgentChatTurn-I425SVYJ.js} +62 -50
  140. package/{switchDialogAgentAction-SSI2CSNE.js → switchDialogAgentAction-KYWJSGOO.js} +7 -7
  141. package/{tableCommands-C3P2HHKK.js → tableCommands-EFA754RE.js} +2 -2
  142. package/{tools-23F5EEVM.js → tools-WBPFTSMK.js} +36 -35
  143. package/{tuiRestart-7IKI6JZK.js → tuiRestart-VN5F4GYU.js} +4 -3
  144. package/tuiSummaryLlmCaller-HROLGN4F.js +1 -1
  145. package/{updateCommands-BZ4YDHNM.js → updateCommands-VQEBBIGO.js} +3 -3
  146. package/{updateDialogTitleAction-TJWT4LXL.js → updateDialogTitleAction-VB5DTVXV.js} +20 -20
  147. package/{usageCommand-HVCMX7BG.js → usageCommand-WI6SQOPB.js} +1 -1
  148. package/{usageRebuildCommand-VMPIZ2ME.js → usageRebuildCommand-WQRLLZAT.js} +2 -2
  149. package/{windowsSelfUpdate-4BAXX7C3.js → windowsSelfUpdate-ZEZKGX4M.js} +2 -2
  150. package/lib-62SWPXNF.js +0 -21042
@@ -3,10 +3,24 @@ import {
3
3
  } from "./chunk-KZ4A7EIV.js";
4
4
  import {
5
5
  performServerProxyFetchWithRetry
6
- } from "./chunk-MW3XUUYS.js";
6
+ } from "./chunk-APXC3SQO.js";
7
7
  import {
8
8
  fetchServerSyncedCredential
9
- } from "./chunk-IDCGMZLC.js";
9
+ } from "./chunk-MD7O2NN2.js";
10
+ import {
11
+ selectCurrentServer
12
+ } from "./chunk-BZMDWGQQ.js";
13
+ import {
14
+ resolveUserAuthorityServer
15
+ } from "./chunk-HPDLPEUG.js";
16
+ import {
17
+ googleSessionRequestToken,
18
+ googleSessionServer,
19
+ isGoogleAuthoritySession
20
+ } from "./chunk-HDKMVYNJ.js";
21
+ import {
22
+ getSessionSnapshotForState
23
+ } from "./chunk-PXYBUFDB.js";
10
24
  import {
11
25
  buildIdentityBlock,
12
26
  buildPlatformStaticContextLayers,
@@ -15,7 +29,7 @@ import {
15
29
  compileContextLayers,
16
30
  detectDispatchIntentFromMessages,
17
31
  resolveToolGuidedSections
18
- } from "./chunk-SID2TFMV.js";
32
+ } from "./chunk-BXGU6274.js";
19
33
  import {
20
34
  convertMessagesToResponsesInput,
21
35
  getUsageRequestOptions,
@@ -32,25 +46,26 @@ import {
32
46
  import {
33
47
  isGpt62DeveloperPrefixModel,
34
48
  usesCodexDeveloperPrefix
35
- } from "./chunk-CIAV4WK2.js";
49
+ } from "./chunk-7WHCIA5V.js";
36
50
  import {
37
51
  createFileCredentialBroker
38
52
  } from "./chunk-E6A5NHDH.js";
39
53
  import {
40
54
  MEMORY_USE_GUIDANCE,
41
55
  buildUserResponseLanguageContext
42
- } from "./chunk-YGDYYFRX.js";
56
+ } from "./chunk-GYX6XTAI.js";
43
57
  import {
44
58
  wrapHistoricalSummaryWithReplayGuard
45
59
  } from "./chunk-2SXN7LAY.js";
46
60
  import {
47
61
  buildSkillGuidancePromptBlock
48
- } from "./chunk-Z2ZCKNKX.js";
62
+ } from "./chunk-JW6OURKM.js";
49
63
  import {
50
64
  canonicalizeToolNames
51
65
  } from "./chunk-YLAHYLDQ.js";
52
66
  import {
53
- API_ENDPOINTS
67
+ API_ENDPOINTS,
68
+ normalizeKnownServerOrigin
54
69
  } from "./chunk-LCBAMY2M.js";
55
70
  import {
56
71
  toErrorMessage
@@ -78,6 +93,7 @@ import {
78
93
  asOptionalTrimmedString
79
94
  } from "./chunk-G3SUCT4W.js";
80
95
  import {
96
+ isLoopbackHostname,
81
97
  isLoopbackUrl
82
98
  } from "./chunk-4SN6J65J.js";
83
99
  import {
@@ -250,6 +266,7 @@ ${mainPrompt}` : "";
250
266
  // 安全透传:两者缺省均为 undefined,resolveToolGuidedSections 不追加任何文本,
251
267
  // 因此未接线调用方拿到的 prompt 与既往逐字相同。
252
268
  callerModel: options.callerModel,
269
+ callerIsPoolTop: options.callerIsPoolTop,
253
270
  externalAgentCount: options.externalAgentCount
254
271
  });
255
272
  const {
@@ -289,6 +306,7 @@ ${wrapHistoricalSummaryWithReplayGuard(contexts.dialogSummary)}` : "";
289
306
  { id: "agent-orchestration", owner: "platform", cacheScope: "session", content: toolSections.agentOrchestration },
290
307
  { id: "agent-collaboration", owner: "platform", cacheScope: "session", content: toolSections.agentCollaboration },
291
308
  { id: "web-access", owner: "platform", cacheScope: "session", content: toolSections.webAccess },
309
+ { id: "platform-risk-control", owner: "platform", cacheScope: "session", content: toolSections.platformRiskControl },
292
310
  { id: "menu-usage", owner: "platform", cacheScope: "session", content: toolSections.menuUsage },
293
311
  { id: "show-interaction", owner: "platform", cacheScope: "session", content: toolSections.showInteraction },
294
312
  { id: "clarification-mode", owner: "platform", cacheScope: "session", content: clarifyingSection },
@@ -1276,6 +1294,479 @@ function sanitizeOutboundBody(body) {
1276
1294
  return next;
1277
1295
  }
1278
1296
 
1297
+ // packages/core/redactUrlUserinfo.ts
1298
+ var REDACTED_USERINFO = "[REDACTED]@";
1299
+ var REDACTED = "[REDACTED]";
1300
+ var SPECIAL_SCHEMES = /* @__PURE__ */ new Set(["http", "https", "ws", "wss", "ftp"]);
1301
+ var MAX_SCHEME_CHARS = 8;
1302
+ var isTabOrNewline = (char) => char === " " || char === "\n" || char === "\r";
1303
+ var isAsciiAlpha = (char) => char >= "a" && char <= "z" || char >= "A" && char <= "Z";
1304
+ var isSchemeChar = (char) => isAsciiAlpha(char) || char >= "0" && char <= "9" || char === "+" || char === "-" || char === ".";
1305
+ var isPrecededBySchemeWord = (text, idx) => {
1306
+ let index = idx - 1;
1307
+ if (index < 0 || !isSchemeChar(text[index])) return false;
1308
+ while (index > 0 && isSchemeChar(text[index - 1])) index -= 1;
1309
+ return isAsciiAlpha(text[index]);
1310
+ };
1311
+ var matchSpecialSchemeBeforeColon = (text, colonIdx) => {
1312
+ let chars = "";
1313
+ let index = colonIdx - 1;
1314
+ while (index >= 0 && chars.length < 5) {
1315
+ const char = text[index];
1316
+ if (isTabOrNewline(char)) {
1317
+ index -= 1;
1318
+ continue;
1319
+ }
1320
+ if (!isAsciiAlpha(char)) break;
1321
+ chars = char.toLowerCase() + chars;
1322
+ if (SPECIAL_SCHEMES.has(chars) && !isPrecededBySchemeWord(text, index)) return true;
1323
+ index -= 1;
1324
+ }
1325
+ return false;
1326
+ };
1327
+ var isFullSpecialSchemeBeforeColon = (text, colonIdx) => {
1328
+ let index = colonIdx - 1;
1329
+ let chars = "";
1330
+ while (index >= 0 && chars.length <= MAX_SCHEME_CHARS) {
1331
+ const char = text[index];
1332
+ if (isTabOrNewline(char)) {
1333
+ index -= 1;
1334
+ continue;
1335
+ }
1336
+ if (!isSchemeChar(char)) break;
1337
+ chars = char.toLowerCase() + chars;
1338
+ index -= 1;
1339
+ }
1340
+ if (chars.length > MAX_SCHEME_CHARS) return false;
1341
+ if (!isAsciiAlpha(chars[0] ?? "")) return false;
1342
+ return SPECIAL_SCHEMES.has(chars);
1343
+ };
1344
+ var hasValidSchemeBeforeColon = (text, colonIdx) => {
1345
+ let index = colonIdx - 1;
1346
+ let sawAlpha = false;
1347
+ while (index >= 0) {
1348
+ const char = text[index];
1349
+ if (isTabOrNewline(char)) {
1350
+ index -= 1;
1351
+ continue;
1352
+ }
1353
+ if (!isSchemeChar(char)) break;
1354
+ if (isAsciiAlpha(char)) sawAlpha = true;
1355
+ index -= 1;
1356
+ }
1357
+ return sawAlpha;
1358
+ };
1359
+ var matchDoubleSlashAfterColon = (text, colonIdx) => {
1360
+ let index = colonIdx + 1;
1361
+ let slashes = 0;
1362
+ while (index < text.length && slashes < 2) {
1363
+ const char = text[index];
1364
+ if (isTabOrNewline(char)) {
1365
+ index += 1;
1366
+ continue;
1367
+ }
1368
+ if (char === "/") {
1369
+ slashes += 1;
1370
+ index += 1;
1371
+ continue;
1372
+ }
1373
+ return -1;
1374
+ }
1375
+ return slashes === 2 ? index : -1;
1376
+ };
1377
+ var skipSpecialAuthorityPrefix = (text, colonIdx) => {
1378
+ let index = colonIdx + 1;
1379
+ while (index < text.length) {
1380
+ const char = text[index];
1381
+ if (char === "/" || char === "\\" || isTabOrNewline(char)) index += 1;
1382
+ else break;
1383
+ }
1384
+ return index;
1385
+ };
1386
+ var authorityCandidates = (text, colonIdx) => {
1387
+ const fullSchemeIsSpecial = isFullSpecialSchemeBeforeColon(text, colonIdx);
1388
+ if (!fullSchemeIsSpecial && !hasValidSchemeBeforeColon(text, colonIdx)) return [];
1389
+ const candidates = [];
1390
+ const afterSlashes = matchDoubleSlashAfterColon(text, colonIdx);
1391
+ if (!fullSchemeIsSpecial && afterSlashes !== -1) {
1392
+ candidates.push({ start: afterSlashes, isSpecial: false });
1393
+ }
1394
+ if (fullSchemeIsSpecial || matchSpecialSchemeBeforeColon(text, colonIdx)) {
1395
+ candidates.push({ start: skipSpecialAuthorityPrefix(text, colonIdx), isSpecial: true });
1396
+ }
1397
+ return candidates;
1398
+ };
1399
+ var findNextStop = (text, from, includeBackslash) => {
1400
+ for (let index = from; index < text.length; index += 1) {
1401
+ const char = text[index];
1402
+ if (char === "/" || char === "?" || char === "#" || includeBackslash && char === "\\") {
1403
+ return index;
1404
+ }
1405
+ }
1406
+ return text.length;
1407
+ };
1408
+ var hasNonIgnoredChar = (text, start, end) => {
1409
+ for (let index = start; index < end; index += 1) {
1410
+ if (!isTabOrNewline(text[index])) return true;
1411
+ }
1412
+ return false;
1413
+ };
1414
+ function redactUrlUserinfo(text) {
1415
+ const lastAtInText = text.lastIndexOf("@");
1416
+ if (lastAtInText === -1 || !text.includes(":")) return text;
1417
+ let output = "";
1418
+ let cursor = 0;
1419
+ let scanFrom = 0;
1420
+ let nextAt = -1;
1421
+ let nextSpecialStop = -1;
1422
+ let nextNonSpecialStop = -1;
1423
+ while (scanFrom < lastAtInText) {
1424
+ const colonIdx = text.indexOf(":", scanFrom);
1425
+ if (colonIdx === -1 || colonIdx >= lastAtInText) break;
1426
+ scanFrom = colonIdx + 1;
1427
+ const candidates = authorityCandidates(text, colonIdx);
1428
+ if (candidates.length === 0) continue;
1429
+ let authorityStart = -1;
1430
+ let authorityEnd = -1;
1431
+ for (const candidate of candidates) {
1432
+ if (nextAt < candidate.start) {
1433
+ nextAt = text.indexOf("@", candidate.start);
1434
+ if (nextAt === -1) break;
1435
+ }
1436
+ const end = candidate.isSpecial ? nextSpecialStop < candidate.start ? nextSpecialStop = findNextStop(text, candidate.start, true) : nextSpecialStop : nextNonSpecialStop < candidate.start ? nextNonSpecialStop = findNextStop(text, candidate.start, false) : nextNonSpecialStop;
1437
+ if (nextAt >= end) continue;
1438
+ authorityStart = candidate.start;
1439
+ authorityEnd = end;
1440
+ break;
1441
+ }
1442
+ if (authorityStart === -1) {
1443
+ if (nextAt === -1) break;
1444
+ continue;
1445
+ }
1446
+ const lastAt = text.lastIndexOf("@", authorityEnd - 1);
1447
+ if (lastAt <= authorityStart) continue;
1448
+ if (!hasNonIgnoredChar(text, authorityStart, lastAt)) continue;
1449
+ if (text.slice(authorityStart, lastAt) === "[REDACTED]") {
1450
+ scanFrom = lastAt + 1;
1451
+ continue;
1452
+ }
1453
+ output += `${text.slice(cursor, authorityStart)}${REDACTED_USERINFO}`;
1454
+ cursor = lastAt + 1;
1455
+ scanFrom = cursor;
1456
+ }
1457
+ return cursor === 0 ? text : output + text.slice(cursor);
1458
+ }
1459
+ function redactUrlQueryAndFragment(text) {
1460
+ if (!text.includes(":") || !text.includes("?") && !text.includes("#")) return text;
1461
+ let output = "";
1462
+ let cursor = 0;
1463
+ let scanFrom = 0;
1464
+ while (scanFrom < text.length) {
1465
+ const colonIdx = text.indexOf(":", scanFrom);
1466
+ if (colonIdx === -1) break;
1467
+ scanFrom = colonIdx + 1;
1468
+ let urlStart = -1;
1469
+ for (const candidate of authorityCandidates(text, colonIdx)) {
1470
+ if (urlStart === -1 || candidate.start < urlStart) urlStart = candidate.start;
1471
+ }
1472
+ if (urlStart === -1 && hasValidSchemeBeforeColon(text, colonIdx)) urlStart = colonIdx + 1;
1473
+ if (urlStart === -1) continue;
1474
+ if (urlStart < cursor) continue;
1475
+ let marker = -1;
1476
+ for (let index = urlStart; index < text.length; index += 1) {
1477
+ const char = text[index];
1478
+ if (char === "?" || char === "#") {
1479
+ marker = index;
1480
+ break;
1481
+ }
1482
+ }
1483
+ if (marker === -1) break;
1484
+ output += `${text.slice(cursor, marker)}${text[marker]}${REDACTED}`;
1485
+ cursor = text.length;
1486
+ scanFrom = text.length;
1487
+ }
1488
+ return cursor === 0 ? text : output + text.slice(cursor);
1489
+ }
1490
+
1491
+ // packages/ai/agent/toolErrorReport.ts
1492
+ var TOOL_ERROR_REPORT_PATH = "/api/diagnostics/tool-errors";
1493
+ var REPORT_TIMEOUT_MS = 3e3;
1494
+ var MAX_INFLIGHT_REPORTS = 1;
1495
+ var MAX_DEDUPE_ENTRIES = 100;
1496
+ var MESSAGE_MAX_CHARS = 1e3;
1497
+ var STACK_MAX_CHARS = 4e3;
1498
+ var ERROR_CLASS_MAX_CHARS = 120;
1499
+ var IDENTIFIER_MAX_CHARS = 200;
1500
+ var TOOL_ERROR_REPORT_MAX_BODY_BYTES = 16 * 1024;
1501
+ var CONTROL_CHARS_PATTERN = /[\u0000-\u0008\u000b\u000c\u000e-\u001f\u007f]/g;
1502
+ var REDACTED2 = "[REDACTED]";
1503
+ var TOOL_ERROR_REPORT_ALLOWED_FIELDS = [
1504
+ "dialogId",
1505
+ "callId",
1506
+ "toolName",
1507
+ "errorClass",
1508
+ "message",
1509
+ "stack",
1510
+ "clientVersion"
1511
+ ];
1512
+ var dedupeKeys = /* @__PURE__ */ new Map();
1513
+ var inflightReports = 0;
1514
+ var sanitizedBoundedString = (value, maxChars) => {
1515
+ if (typeof value !== "string") return void 0;
1516
+ const cleaned = sanitizeToolErrorText(value).trim();
1517
+ if (!cleaned) return void 0;
1518
+ return cleaned.length > maxChars ? cleaned.slice(0, maxChars) : cleaned;
1519
+ };
1520
+ function sanitizeToolErrorText(input) {
1521
+ if (typeof input !== "string" || !input) return "";
1522
+ let text = input;
1523
+ text = text.replace(CONTROL_CHARS_PATTERN, "");
1524
+ text = redactUrlUserinfo(text);
1525
+ text = redactUrlQueryAndFragment(text);
1526
+ text = text.replace(
1527
+ /([?&](?:access[_-]?token|refresh[_-]?token|api[_-]?key|apikey|token|secret|password|sig|signature|key)=)[^&\s"'<>[\]]+/gi,
1528
+ (_match, prefix) => `${prefix}${REDACTED2}`
1529
+ );
1530
+ text = text.replace(
1531
+ /\b(bearer)\s+[A-Za-z0-9._~+/=-]{4,}/gi,
1532
+ (_match, scheme) => `${scheme} ${REDACTED2}`
1533
+ );
1534
+ text = text.replace(
1535
+ /\beyJ[A-Za-z0-9_-]{4,}\.[A-Za-z0-9_-]{4,}\.[A-Za-z0-9_-]{4,}\b/g,
1536
+ REDACTED2
1537
+ );
1538
+ text = text.replace(
1539
+ /((?:api[_-]?key|apikey|access[_-]?token|refresh[_-]?token|token|password|secret|authorization)["']?\s*[:=]\s*)("?)([^\s"',;}\][]+)/gi,
1540
+ (_match, prefix, quote) => `${prefix}${quote}${REDACTED2}`
1541
+ );
1542
+ text = text.replace(/\bsk-[A-Za-z0-9_-]{12,}/g, REDACTED2);
1543
+ return text;
1544
+ }
1545
+ var resolveErrorClass = (error) => {
1546
+ if (error && typeof error === "object") {
1547
+ const record = error;
1548
+ const name = sanitizedBoundedString(record.name, ERROR_CLASS_MAX_CHARS) ?? sanitizedBoundedString(record.constructor?.name, ERROR_CLASS_MAX_CHARS);
1549
+ if (name) return name;
1550
+ return "Error";
1551
+ }
1552
+ return "Error";
1553
+ };
1554
+ var resolveErrorMessage = (error, errorClass) => {
1555
+ const raw = error && typeof error === "object" ? error.message : error;
1556
+ const text = typeof raw === "string" ? raw : raw === void 0 || raw === null ? "" : String(raw);
1557
+ const sanitized = sanitizeToolErrorText(text).trim();
1558
+ const bounded = sanitized.length > MESSAGE_MAX_CHARS ? sanitized.slice(0, MESSAGE_MAX_CHARS) : sanitized;
1559
+ return bounded || errorClass;
1560
+ };
1561
+ var resolveStack = (error) => {
1562
+ if (!error || typeof error !== "object") return void 0;
1563
+ const stack = error.stack;
1564
+ if (typeof stack !== "string") return void 0;
1565
+ const sanitized = sanitizeToolErrorText(stack).trim();
1566
+ if (!sanitized) return void 0;
1567
+ return sanitized.length > STACK_MAX_CHARS ? sanitized.slice(0, STACK_MAX_CHARS) : sanitized;
1568
+ };
1569
+ function buildToolErrorReportPayload(input) {
1570
+ const dialogId = sanitizedBoundedString(input.dialogId, IDENTIFIER_MAX_CHARS);
1571
+ const callId = sanitizedBoundedString(input.callId, IDENTIFIER_MAX_CHARS);
1572
+ const toolName = sanitizedBoundedString(input.toolName, IDENTIFIER_MAX_CHARS);
1573
+ if (!dialogId || !callId || !toolName) return null;
1574
+ const errorClass = resolveErrorClass(input.error);
1575
+ const message = sanitizeToolErrorText(resolveErrorMessage(input.error, errorClass)) || errorClass;
1576
+ const stack = resolveStack(input.error);
1577
+ return {
1578
+ dialogId,
1579
+ callId,
1580
+ toolName,
1581
+ errorClass,
1582
+ message,
1583
+ ...stack ? { stack } : {}
1584
+ };
1585
+ }
1586
+ var pickAllowedFields = (payload) => {
1587
+ const out = {};
1588
+ for (const field of TOOL_ERROR_REPORT_ALLOWED_FIELDS) {
1589
+ const value = payload[field];
1590
+ if (typeof value === "string" && value) out[field] = value;
1591
+ }
1592
+ return out;
1593
+ };
1594
+ var truncateToUtf8Bytes = (value, maxBytes) => {
1595
+ if (maxBytes <= 0) return "";
1596
+ const encoder = new TextEncoder();
1597
+ if (encoder.encode(value).length <= maxBytes) return value;
1598
+ let used = 0;
1599
+ let out = "";
1600
+ for (const char of value) {
1601
+ const size = encoder.encode(char).length;
1602
+ if (used + size > maxBytes) break;
1603
+ used += size;
1604
+ out += char;
1605
+ }
1606
+ return out;
1607
+ };
1608
+ var utf8ByteLength = (value) => new TextEncoder().encode(value).length;
1609
+ var buildBoundedBody = (fields) => {
1610
+ const withoutStack = { ...fields };
1611
+ delete withoutStack.stack;
1612
+ const attempts = fields.stack ? [fields, withoutStack] : [withoutStack];
1613
+ for (const attempt of attempts) {
1614
+ const serialized = JSON.stringify(attempt);
1615
+ if (utf8ByteLength(serialized) <= TOOL_ERROR_REPORT_MAX_BODY_BYTES) return serialized;
1616
+ }
1617
+ const base = { ...withoutStack, message: "" };
1618
+ const budgetForMessage = TOOL_ERROR_REPORT_MAX_BODY_BYTES - utf8ByteLength(JSON.stringify(base));
1619
+ if (budgetForMessage > 0) {
1620
+ const shrunk = truncateToUtf8Bytes(withoutStack.message ?? "", budgetForMessage);
1621
+ if (shrunk) {
1622
+ const serialized = JSON.stringify({ ...withoutStack, message: shrunk });
1623
+ if (utf8ByteLength(serialized) <= TOOL_ERROR_REPORT_MAX_BODY_BYTES) return serialized;
1624
+ }
1625
+ }
1626
+ const fallback = JSON.stringify({
1627
+ ...withoutStack,
1628
+ message: withoutStack.errorClass ?? ""
1629
+ });
1630
+ return utf8ByteLength(fallback) <= TOOL_ERROR_REPORT_MAX_BODY_BYTES ? fallback : null;
1631
+ };
1632
+ function resolveSafeReportOrigin(value) {
1633
+ if (typeof value !== "string" || !value.trim()) return null;
1634
+ let url;
1635
+ try {
1636
+ url = new URL(value.trim());
1637
+ } catch {
1638
+ return null;
1639
+ }
1640
+ if (url.protocol !== "https:" && url.protocol !== "http:") return null;
1641
+ if (url.username || url.password) return null;
1642
+ if (url.search || url.hash) return null;
1643
+ if (url.pathname !== "/" && url.pathname !== "") return null;
1644
+ if (url.protocol === "http:" && !isLoopbackHostname(url.hostname)) return null;
1645
+ return url.origin;
1646
+ }
1647
+ var collectConfiguredOrigins = (state) => {
1648
+ const origins = /* @__PURE__ */ new Set();
1649
+ const push = (value) => {
1650
+ const normalized = normalizeKnownServerOrigin(value);
1651
+ if (normalized) origins.add(normalized);
1652
+ };
1653
+ push(state?.settings?.currentServer);
1654
+ const syncServers = state?.settings?.syncServers;
1655
+ if (Array.isArray(syncServers)) syncServers.forEach(push);
1656
+ const registry = state?.settings?.userAuthorityRegistry;
1657
+ if (registry && typeof registry === "object") {
1658
+ for (const entry of Object.values(registry)) {
1659
+ if (typeof entry === "string") {
1660
+ push(entry);
1661
+ continue;
1662
+ }
1663
+ if (entry && typeof entry === "object") {
1664
+ const record = entry;
1665
+ push(record.authorityServer);
1666
+ push(record.homeServer);
1667
+ push(record.primaryServer);
1668
+ }
1669
+ }
1670
+ }
1671
+ return origins;
1672
+ };
1673
+ function resolveToolErrorReportTarget(state) {
1674
+ if (!state || typeof state !== "object") return null;
1675
+ const snapshot = getSessionSnapshotForState(state);
1676
+ const activeAccountId = typeof snapshot?.activeAccountId === "string" ? snapshot.activeAccountId.trim() : "";
1677
+ const rawToken = typeof snapshot?.activeToken === "string" ? snapshot.activeToken.trim() : "";
1678
+ if (!activeAccountId || !rawToken) return null;
1679
+ const configuredOrigins = collectConfiguredOrigins(state);
1680
+ if (isGoogleAuthoritySession(rawToken)) {
1681
+ const sameOrigin = resolveSafeReportOrigin(googleSessionServer(rawToken));
1682
+ if (!sameOrigin) return null;
1683
+ return { baseUrl: sameOrigin, token: rawToken };
1684
+ }
1685
+ const authorityServer = resolveUserAuthorityServer({
1686
+ ownerUserId: activeAccountId,
1687
+ registry: state?.settings?.userAuthorityRegistry ?? null
1688
+ });
1689
+ const authorityOrigin = resolveSafeReportOrigin(authorityServer);
1690
+ const currentOrigin = resolveSafeReportOrigin(selectCurrentServer(state));
1691
+ const authorityKnown = typeof authorityServer === "string" && authorityServer.trim().length > 0;
1692
+ const candidate = authorityKnown ? authorityOrigin : currentOrigin;
1693
+ if (!candidate) return null;
1694
+ if (!configuredOrigins.has(candidate)) return null;
1695
+ return { baseUrl: candidate, token: rawToken };
1696
+ }
1697
+ var dedupeKeyOf = (payload) => `${payload.dialogId}|${payload.callId}|${payload.toolName}|${payload.errorClass}`;
1698
+ var rememberDedupeKey = (key) => {
1699
+ dedupeKeys.set(key, true);
1700
+ while (dedupeKeys.size > MAX_DEDUPE_ENTRIES) {
1701
+ const oldest = dedupeKeys.keys().next();
1702
+ if (oldest.done) break;
1703
+ dedupeKeys.delete(oldest.value);
1704
+ }
1705
+ };
1706
+ async function reportToolError(args) {
1707
+ const key = dedupeKeyOf(args.payload);
1708
+ if (dedupeKeys.has(key)) return false;
1709
+ if (inflightReports >= MAX_INFLIGHT_REPORTS) return false;
1710
+ const baseUrl = resolveSafeReportOrigin(args.baseUrl);
1711
+ if (!baseUrl) return false;
1712
+ const requestUrl = `${baseUrl}${TOOL_ERROR_REPORT_PATH}`;
1713
+ let requestToken;
1714
+ try {
1715
+ requestToken = googleSessionRequestToken(args.token, requestUrl);
1716
+ } catch {
1717
+ return false;
1718
+ }
1719
+ if (!requestToken) return false;
1720
+ if (typeof AbortController !== "function") return false;
1721
+ const timeoutMs = typeof args.timeoutMs === "number" && args.timeoutMs > 0 ? args.timeoutMs : REPORT_TIMEOUT_MS;
1722
+ rememberDedupeKey(key);
1723
+ inflightReports += 1;
1724
+ const controller = new AbortController();
1725
+ const timer = setTimeout(() => {
1726
+ try {
1727
+ controller.abort();
1728
+ } catch {
1729
+ }
1730
+ }, timeoutMs);
1731
+ try {
1732
+ const fetchImpl = args.fetchImpl ?? (typeof fetch === "function" ? fetch : void 0);
1733
+ if (!fetchImpl) return false;
1734
+ const body = buildBoundedBody(pickAllowedFields(args.payload));
1735
+ if (!body) return false;
1736
+ const response = await fetchImpl(requestUrl, {
1737
+ method: "POST",
1738
+ headers: {
1739
+ "Content-Type": "application/json",
1740
+ Authorization: `Bearer ${requestToken}`
1741
+ },
1742
+ body,
1743
+ // 不跟随重定向:避免把 Authorization 带到别处。
1744
+ redirect: "error",
1745
+ credentials: "omit",
1746
+ signal: controller.signal
1747
+ });
1748
+ return response?.ok === true;
1749
+ } catch {
1750
+ return false;
1751
+ } finally {
1752
+ clearTimeout(timer);
1753
+ inflightReports -= 1;
1754
+ }
1755
+ }
1756
+ var isBrowserRuntime = () => typeof window !== "undefined" && typeof document !== "undefined";
1757
+ function reportToolExecutionErrorInBackground(args) {
1758
+ try {
1759
+ if (!isBrowserRuntime()) return;
1760
+ const payload = buildToolErrorReportPayload(args);
1761
+ if (!payload) return;
1762
+ const target = resolveToolErrorReportTarget(args.thunkApi?.getState?.());
1763
+ if (!target) return;
1764
+ void reportToolError({ ...target, payload }).catch(() => {
1765
+ });
1766
+ } catch {
1767
+ }
1768
+ }
1769
+
1279
1770
  // packages/ai/tools/stripModelConfirmationFlags.ts
1280
1771
  var CONFIRMATION_INPUT_KEYS = {
1281
1772
  knowledge_capture_requires_confirmation: "__confirmedKnowledgeCapture",
@@ -1325,6 +1816,7 @@ export {
1325
1816
  updateResponsesConversationState,
1326
1817
  isResponsesConversationStateRejection,
1327
1818
  generateRequestBody,
1819
+ reportToolExecutionErrorInBackground,
1328
1820
  CONFIRMATION_INPUT_KEYS,
1329
1821
  stripModelToolArgs,
1330
1822
  DirectApiKeyResolutionError,
@@ -1,11 +1,11 @@
1
1
  import {
2
2
  toolRegistry
3
- } from "./chunk-TA2JQUWA.js";
3
+ } from "./chunk-KO5PFS74.js";
4
4
  import {
5
5
  INLINE_IMAGE_MAX_BYTES,
6
6
  INLINE_IMAGE_TOTAL_MAX_BYTES,
7
7
  runtime_default
8
- } from "./chunk-MICGEDCN.js";
8
+ } from "./chunk-7B55IVLF.js";
9
9
  import {
10
10
  canonicalizeToolNames
11
11
  } from "./chunk-YLAHYLDQ.js";
@@ -243,7 +243,7 @@ var sessionStrings = {
243
243
  " /compact Compact current dialog and fork a new one",
244
244
  " /context Show workspace context and next actions",
245
245
  " /credits Show session usage and platform credits (/credits debug for diagnostics)",
246
- " /tools Show individual tool results from this session",
246
+ " /tools [last] Show individual tool results (session, or latest turn)",
247
247
  " /cd <path> Change the working directory (takes effect on the next turn)",
248
248
  " /runtime <mode> Use auto, local, or server runtime",
249
249
  " /agents Pick an agent interactively (/agents <name> to switch, list, builtin)",
@@ -288,7 +288,7 @@ var sessionStrings = {
288
288
  " /compact \u538B\u7F29\u5F53\u524D\u5BF9\u8BDD\u5E76\u5206\u53C9\u51FA\u65B0\u5BF9\u8BDD",
289
289
  " /context \u67E5\u770B\u5DE5\u4F5C\u533A\u4E0A\u4E0B\u6587\u4E0E\u540E\u7EED\u64CD\u4F5C",
290
290
  " /credits \u67E5\u770B\u672C\u6B21\u4F1A\u8BDD\u7528\u91CF\u4E0E\u5E73\u53F0\u79EF\u5206\uFF08/credits debug \u67E5\u770B\u94FE\u8DEF\u8BCA\u65AD\uFF09",
291
- " /tools \u5C55\u5F00\u672C\u6B21\u4F1A\u8BDD\u7684\u9010\u6761\u5DE5\u5177\u8BE6\u60C5",
291
+ " /tools [last] \u5C55\u5F00\u9010\u6761\u5DE5\u5177\u8BE6\u60C5\uFF08\u5168\u90E8\u4F1A\u8BDD\u8BB0\u5F55\uFF0C\u6216\u6700\u8FD1\u4E00\u8F6E\uFF09",
292
292
  " /cd <path> \u5207\u6362\u5DE5\u4F5C\u76EE\u5F55\uFF08\u4E0B\u4E2A turn \u751F\u6548\uFF09",
293
293
  " /runtime <mode> \u5207\u6362 runtime\uFF1Aauto\u3001local\u3001server",
294
294
  " /agents \u4EA4\u4E92\u5F0F\u9009\u62E9\u667A\u80FD\u4F53\uFF08/agents <name> \u76F4\u63A5\u5207\u6362\uFF0Clist \u5217\u8868\uFF0Cbuiltin \u5185\u7F6E\uFF09",
@@ -467,6 +467,22 @@ var toolStrings = {
467
467
  en: "[nolo] Tool execution location: unknown",
468
468
  zh: "[nolo] \u5DE5\u5177\u6267\u884C\u4F4D\u7F6E\uFF1A\u672A\u77E5"
469
469
  },
470
+ runGroupHeader: {
471
+ en: "{0} commands (\u2713 {0}{1})",
472
+ zh: "\u8FDE\u7EED\u6267\u884C {0} \u6761\u547D\u4EE4\uFF08\u2713 {0}{1}\uFF09"
473
+ },
474
+ runGroupCollapsed: {
475
+ en: "{0} earlier collapsed (/tools for details)",
476
+ zh: "\u5DF2\u6298\u53E0\u524D {0} \u6761\uFF08/tools \u67E5\u770B\u5B8C\u6574\u547D\u4EE4\uFF09"
477
+ },
478
+ runGroupFinal: {
479
+ en: "{0} commands (\u2713 {0}{1} \xB7 /tools for details)",
480
+ zh: "\u672C\u8F6E\u6267\u884C {0} \u6761\u547D\u4EE4\uFF08\u2713 {0}{1} \xB7 /tools \u67E5\u770B\u8BE6\u60C5\uFF09"
481
+ },
482
+ runGroupTiming: {
483
+ en: ", {0}",
484
+ zh: "\uFF0C\u8017\u65F6 {0}"
485
+ },
470
486
  exploreSummary: {
471
487
  en: "Explored {0} \xB7 {1}",
472
488
  zh: "\u5DF2\u63A2\u67E5 {0} \u9879 \xB7 {1}"
@@ -2973,9 +2989,8 @@ var TOOL_FAMILY_OVERRIDES = {
2973
2989
  notifyUser: TOOL_FAMILIES.interaction,
2974
2990
  captureVisualState: TOOL_FAMILIES.capture,
2975
2991
  loadSkill: TOOL_FAMILIES.skill,
2976
- // 名字不切出已知系列词的两个注册工具(`weread*` / `toolquery`):它们是
2977
- // 读书网关与工具查询,属于读取族;精确钉住以免退到兜底 🔧。
2978
- wereadGateway: TOOL_FAMILIES.read,
2992
+ // 名字不切出已知系列词的工具(`toolquery`):它是工具查询,属于读取族;
2993
+ // 精确钉住以免退到兜底 🔧。
2979
2994
  toolquery: TOOL_FAMILIES.read
2980
2995
  };
2981
2996
  function toolNameWords(name) {
@@ -3030,14 +3045,14 @@ var TOOL_FAMILY_RULES = [
3030
3045
  { id: "delete", family: TOOL_FAMILIES.delete, test: startsWithWord("delete", "remove") },
3031
3046
  // 写入类:write* / edit* / apply* / create* / update* / import* / export* / convert* / translate*
3032
3047
  { id: "write", family: TOOL_FAMILIES.write, test: startsWithWord("write", "edit", "apply", "create", "update", "import", "export", "convert", "translate") },
3033
- // 读取/查询类:read* / query*(含 wereadGateway、toolquery 这类带 query/read 的名字)
3048
+ // 读取/查询类:read* / query*(含 toolquery 这类带 query/read 的名字)
3034
3049
  { id: "read", family: TOOL_FAMILIES.read, test: hasWord("read", "query") },
3035
3050
  // 列表类:list*(空间、对话、用户空间)
3036
3051
  { id: "list", family: TOOL_FAMILIES.list, test: startsWithWord("list") },
3037
3052
  // 搜索类:search_workspace / search_all_spaces / searchDialogMessages …
3038
3053
  { id: "search", family: TOOL_FAMILIES.search, test: hasWord("search") },
3039
- // 抓取类:fetchWebpage / surfWeather
3040
- { id: "fetch", family: TOOL_FAMILIES.fetch, test: startsWithWord("fetch", "surf") },
3054
+ // 抓取类:fetchWebpage
3055
+ { id: "fetch", family: TOOL_FAMILIES.fetch, test: startsWithWord("fetch") },
3041
3056
  // 执行类:exec_shell / executeSql(shell 与本地诊断命令)
3042
3057
  { id: "run", family: TOOL_FAMILIES.run, test: startsWithWord("exec", "execute", "run") }
3043
3058
  ];
@@ -3521,13 +3536,9 @@ var COMMAND_DESCRIPTIONS = {
3521
3536
  en: "Evaluate JS in a tab, user-approved per call (--tab <id> --expr <js> [--await] [--timeout-ms N]) (Compatibility alias of `nolo browser eval`)",
3522
3537
  zh: "\u5728\u6807\u7B7E\u9875\u4E2D\u6267\u884C JS\uFF0C\u6BCF\u6B21\u8C03\u7528\u9700\u7528\u6237\u6279\u51C6\uFF08--tab <id> --expr <js> [--await] [--timeout-ms N]\uFF09\uFF08`nolo browser eval` \u7684\u517C\u5BB9\u522B\u540D\uFF09"
3523
3538
  },
3524
- "ci cancel": {
3525
- en: "Cancel an alpha deploy job",
3526
- zh: "\u53D6\u6D88 alpha \u90E8\u7F72\u4EFB\u52A1"
3527
- },
3528
- "ci status": {
3529
- en: "Show recent nolo-ci deploy jobs (alpha / main)",
3530
- zh: "\u67E5\u770B\u6700\u8FD1\u7684 nolo-ci \u90E8\u7F72\u4EFB\u52A1\uFF08alpha / main\uFF09"
3539
+ "dialog trace": {
3540
+ en: "Trace one dialog: messages, token usage and subagent runs (--json)",
3541
+ zh: "\u8FFD\u8E2A\u5355\u4E2A\u5BF9\u8BDD\uFF1A\u6D88\u606F\u3001token \u7528\u91CF\u4E0E\u5B50\u4EE3\u7406\u8FD0\u884C\u8BB0\u5F55\uFF08--json\uFF09"
3531
3542
  },
3532
3543
  "dialog usage": {
3533
3544
  en: "Show dialog tokens, recorded duration and speed by basis",