nolo-cli 0.246.0-alpha.1 → 0.247.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 (152) hide show
  1. package/{_executeModel-5FOV5A3C.js → _executeModel-GIFVXKDT.js} +35 -35
  2. package/{accountResolver-QETKNC7T.js → accountResolver-NGICIMEE.js} +1 -1
  3. package/{action-R2EIXR7I.js → action-WZTKEF5H.js} +5 -5
  4. package/{addContentAction-W6JVLQ6H.js → addContentAction-MLI6GOBV.js} +8 -8
  5. package/{addDialogAgentAction-LVNKMXKZ.js → addDialogAgentAction-ARGQM22H.js} +7 -7
  6. package/{agentDeleteCommand-EKGFL4M7.js → agentDeleteCommand-MEJNOUQB.js} +53 -53
  7. package/{agentEmailCommands-YHEW42IW.js → agentEmailCommands-RBQXQLVY.js} +53 -53
  8. package/{agentListCommands-CVYNO54Q.js → agentListCommands-U436UABA.js} +15 -15
  9. package/{agentMachineCommands-2XWZXMAN.js → agentMachineCommands-R6WKJ622.js} +11 -11
  10. package/{agentPullCommand-QQQZSC6S.js → agentPullCommand-4EQZYHU4.js} +1 -1
  11. package/{agentRecordCommands-25R5YL5N.js → agentRecordCommands-5MAINXNS.js} +52 -52
  12. package/{agentRunCommand-TW4YOXIV.js → agentRunCommand-DNBAO4PN.js} +52 -52
  13. package/{agentRunControl-CSMSJFFB.js → agentRunControl-RN2P6AOD.js} +2 -2
  14. package/{agentRuntimeLocal-NC6CTZED.js → agentRuntimeLocal-4Y47ZSIP.js} +7 -7
  15. package/{agentSlice-6V2DXM4I.js → agentSlice-ZGMOH6TE.js} +8 -8
  16. package/{appDeleteCommands-LH7LQ6IZ.js → appDeleteCommands-KTYELLHJ.js} +12 -12
  17. package/{appDeployCommands-HLXUS5WI.js → appDeployCommands-HH4ZVRIS.js} +12 -12
  18. package/{appDeployStatusCommands-6IGCM32K.js → appDeployStatusCommands-KSIDBUL2.js} +12 -12
  19. package/{appGetCommands-G7PYU6CW.js → appGetCommands-N5E5L24Z.js} +12 -12
  20. package/{appListCommands-YWFISFO3.js → appListCommands-7QC63Y6R.js} +12 -12
  21. package/{authCommand-PVZ45QRO.js → authCommand-3C3RN4OU.js} +7 -7
  22. package/{authCommands-6AUYO65N.js → authCommands-ZMVEDCQD.js} +3 -3
  23. package/{builtinSkillRegistry-K7XDZWQJ.js → builtinSkillRegistry-VRCMQ77Q.js} +1 -1
  24. package/{chromeCommands-S7AW3AOD.js → chromeCommands-O4IIKTBD.js} +1 -1
  25. package/{chromeOpsCommands-TBPM6MR4.js → chromeOpsCommands-NZITLHWO.js} +3 -3
  26. package/{chunk-ZMRPZPEZ.js → chunk-2BKNICGK.js} +1 -1
  27. package/{chunk-3Z7YM7RQ.js → chunk-3DJJ4CFG.js} +4 -4
  28. package/{chunk-Y7N45DS6.js → chunk-3UPWX4NA.js} +3 -3
  29. package/{chunk-O72CE7QS.js → chunk-45L3GRIE.js} +171 -55
  30. package/{chunk-QIVE5WJE.js → chunk-4IQN6FWY.js} +1 -1
  31. package/{chunk-MU2PJQ4K.js → chunk-6CXQ3YNJ.js} +10 -10
  32. package/{chunk-AKKID57M.js → chunk-6MTVACLN.js} +47 -10
  33. package/{chunk-XGWRH3OF.js → chunk-6TVYUQRM.js} +22 -6
  34. package/{chunk-QOURTDZL.js → chunk-6XVPMGXK.js} +1 -1
  35. package/{chunk-MEDPR36J.js → chunk-73PZD7JZ.js} +2 -2
  36. package/{chunk-R7PFDD5L.js → chunk-7IEJYF7U.js} +4 -4
  37. package/{chunk-2TIH3JQK.js → chunk-ABG4QNBR.js} +371 -49
  38. package/{chunk-VEVLLBFK.js → chunk-ADOOL3PG.js} +1 -1
  39. package/{chunk-XKV53E4E.js → chunk-AEZBAFC6.js} +21 -6
  40. package/{chunk-AVSZ6PBM.js → chunk-ARFCL53U.js} +3 -3
  41. package/{chunk-MECW2HJG.js → chunk-BAH3BAUZ.js} +4 -4
  42. package/{chunk-LELADM5Q.js → chunk-BFKJ2RS3.js} +1 -1
  43. package/{chunk-56O2J2Y4.js → chunk-BVEDT6DM.js} +2 -2
  44. package/{chunk-IFWXH7LH.js → chunk-CD64YXRB.js} +1 -1
  45. package/{chunk-EQZZASCD.js → chunk-CIGCTSBF.js} +1 -1
  46. package/{chunk-X3XNXLHF.js → chunk-CIUZXD5D.js} +2 -2
  47. package/{chunk-TB5KTLNB.js → chunk-CTIEJRTP.js} +25 -1
  48. package/{chunk-DLT2DN4M.js → chunk-D25ONVOH.js} +1 -1
  49. package/{chunk-OGZE6BZG.js → chunk-E5RYFR7E.js} +29 -16
  50. package/{chunk-2YGBI2XB.js → chunk-FE7G6DSP.js} +11 -1
  51. package/{chunk-RXTZB2DH.js → chunk-FFFKAOJN.js} +1 -1
  52. package/{chunk-PUNGLYNR.js → chunk-FTWAOKFU.js} +29 -29
  53. package/{chunk-YRIRQSEP.js → chunk-HCCQEMTK.js} +9 -9
  54. package/{chunk-PDAXMBLW.js → chunk-HZDK56EK.js} +7 -7
  55. package/{chunk-7VNVB4OY.js → chunk-IIOSZAJX.js} +2 -2
  56. package/{chunk-UJUDZCJ7.js → chunk-IJZC2KIJ.js} +1 -1
  57. package/{chunk-2DWSICJH.js → chunk-ITBX27W6.js} +1 -1
  58. package/{chunk-X5QZF3ZS.js → chunk-J2VIGDJN.js} +3 -3
  59. package/{chunk-WPXDXATD.js → chunk-JEWMQR6J.js} +1 -1
  60. package/{chunk-KMDHRVS7.js → chunk-JFRJEPFI.js} +2 -2
  61. package/{chunk-RC3ZT4AH.js → chunk-JU7VN4LF.js} +6 -6
  62. package/{chunk-TGFFUUVC.js → chunk-K4CHT35N.js} +102 -61
  63. package/{chunk-ZYKJBRZ3.js → chunk-K7VIXYTZ.js} +1 -3
  64. package/{chunk-5QX6DBZP.js → chunk-KLAMJNKQ.js} +2 -2
  65. package/{chunk-JRRDP7EB.js → chunk-KXOPLLFP.js} +16 -0
  66. package/{chunk-XOZNL36S.js → chunk-KZ5OD2MO.js} +2 -2
  67. package/{chunk-IOIWS357.js → chunk-LMGFVH65.js} +10 -10
  68. package/{chunk-76HAJUOJ.js → chunk-MTM4LRVG.js} +2 -2
  69. package/{chunk-XWJXQLQB.js → chunk-N74XL3NI.js} +6 -6
  70. package/{chunk-QRZZV4NY.js → chunk-OAZP4TSA.js} +1 -1
  71. package/{chunk-E4BAGLDK.js → chunk-ODBYGVO2.js} +4 -4
  72. package/{chunk-SESKIWB4.js → chunk-OLGFIQN2.js} +1 -1
  73. package/{chunk-F26GAEH3.js → chunk-OYUMJMC5.js} +5 -0
  74. package/{chunk-4TVOZGOS.js → chunk-PBPXXMWZ.js} +1 -1
  75. package/{chunk-NYLA6SRJ.js → chunk-QMNVV3YM.js} +8 -8
  76. package/{chunk-T23G6PXQ.js → chunk-RHBD22LV.js} +1 -1
  77. package/{chunk-UTGHPMQL.js → chunk-RR3MB26M.js} +2 -2
  78. package/{chunk-7GZY6HB7.js → chunk-S4UP27EG.js} +2 -2
  79. package/{chunk-KC2QVCI7.js → chunk-SPU3L3OR.js} +5 -4
  80. package/{chunk-QLUYDJST.js → chunk-TMRJGSK2.js} +1 -1
  81. package/{chunk-UAIHKQIA.js → chunk-U6RD332P.js} +18 -2
  82. package/{chunk-KB5RQRSJ.js → chunk-UF6J7NXV.js} +1 -1
  83. package/{chunk-EQ7LQZ6U.js → chunk-UOUMPHS5.js} +1 -0
  84. package/{chunk-CJQBWHNM.js → chunk-V4IYI3SB.js} +2 -2
  85. package/{chunk-EXZBHOTV.js → chunk-VKCPKCSS.js} +4 -4
  86. package/{chunk-2BSLGODA.js → chunk-W6T4FNZP.js} +1 -1
  87. package/{chunk-FMYNIAI6.js → chunk-WQDTSK5U.js} +2 -2
  88. package/{chunk-QE5WJFUT.js → chunk-X22AUZKL.js} +9 -9
  89. package/{chunk-2IPR4PBB.js → chunk-X3OZ655T.js} +2 -2
  90. package/{chunk-VX5ABJWX.js → chunk-XCA4WHX5.js} +1 -1
  91. package/{chunk-LC5CVWP2.js → chunk-XJSEST7D.js} +3 -3
  92. package/{chunk-TIZSX3UY.js → chunk-XSRSAU3O.js} +3 -3
  93. package/{chunk-TCQ27BXD.js → chunk-Y4NPF2UN.js} +3 -3
  94. package/{chunk-VHXADZ32.js → chunk-YDRRGVT5.js} +1 -1
  95. package/{chunk-PPIQDGJT.js → chunk-YFW4H6DL.js} +20 -20
  96. package/{chunk-5PASH2MB.js → chunk-YHNUDTU4.js} +4 -3
  97. package/{chunk-WBSJAIZP.js → chunk-YJPK35HB.js} +5 -0
  98. package/{chunk-EJYSKGP2.js → chunk-Z7KE4K3H.js} +2 -2
  99. package/{chunk-5VVP7DW3.js → chunk-ZM5AZTQG.js} +2 -2
  100. package/{cliLocalAgentRecordReader-P2DQNSEC.js → cliLocalAgentRecordReader-LWMGOH3X.js} +9 -9
  101. package/{commandRegistry-LDTVFRZB.js → commandRegistry-ZZUPMMTU.js} +86 -86
  102. package/{contentThunks-7NW3FSQG.js → contentThunks-SPXTX5U2.js} +14 -14
  103. package/{cooldownCommands-QL6DWGVU.js → cooldownCommands-TIFCHCUN.js} +1 -1
  104. package/{createAgentAutomationAction-TGVXPVGN.js → createAgentAutomationAction-KUQKCOXB.js} +14 -14
  105. package/{createDialogAction-RJHKOVR6.js → createDialogAction-HJN5U3XS.js} +15 -15
  106. package/{createPageAction-ITSOI5CP.js → createPageAction-ZAHRDOAU.js} +15 -15
  107. package/{db-6NRZLEW2.js → db-CMUTP3W5.js} +2 -2
  108. package/{dbSlice-5MQ3ELID.js → dbSlice-656PMWR2.js} +7 -7
  109. package/{deleteFile-VCCHS72Y.js → deleteFile-ZCQESEEQ.js} +5 -5
  110. package/{dialogCommands-NL4R34MT.js → dialogCommands-2JL3C5A3.js} +16 -16
  111. package/{dialogSlice-Q7G57NZU.js → dialogSlice-BXIERQHO.js} +12 -12
  112. package/{dialogUsageCommand-BZPKR3DW.js → dialogUsageCommand-6RW2FY6K.js} +1 -1
  113. package/{docCreateCommands-ZBB6DEY3.js → docCreateCommands-CZOVKJM5.js} +11 -11
  114. package/{docDeleteCommands-2Z5BTK3R.js → docDeleteCommands-WOVJXKOC.js} +12 -12
  115. package/{docReadCommands-GQIS4TGE.js → docReadCommands-ZHBKTJLT.js} +11 -11
  116. package/{docStore-623WNKKR.js → docStore-FZ75HWP2.js} +8 -8
  117. package/{docUpdateCommands-NZ7B235E.js → docUpdateCommands-UYXQNOU7.js} +11 -11
  118. package/{handleSendMessageAction-JR7DIXB3.js → handleSendMessageAction-KP6GGBFY.js} +26 -26
  119. package/{hostCredentialCreate-TNV4AR2P.js → hostCredentialCreate-6UGOSRDR.js} +52 -52
  120. package/index.js +8 -8
  121. package/{localDialogRead-3T2KMCRC.js → localDialogRead-CIOTQM5T.js} +1 -1
  122. package/{localRuntimeAdapter-AE5LKWC7.js → localRuntimeAdapter-R25LKDEH.js} +50 -50
  123. package/{localRuntimeAuthority-7DKIT7UH.js → localRuntimeAuthority-TYHQCTZN.js} +2 -2
  124. package/{localRuntimeDb-5WZ4RJJO.js → localRuntimeDb-BO7IVWAZ.js} +1 -1
  125. package/{machineCommands-Q62F6WLR.js → machineCommands-CNIN7M4X.js} +51 -51
  126. package/{machineWsRunDispatch-N23VJDOE.js → machineWsRunDispatch-GLJGQSXX.js} +51 -51
  127. package/{mcpLocalAuthorizeCommand-DA6DT6B6.js → mcpLocalAuthorizeCommand-TI656UWC.js} +4 -4
  128. package/{memberThunks-KC3WJGL3.js → memberThunks-JFYC4Z5L.js} +9 -9
  129. package/package.json +1 -1
  130. package/{projectArchive-SJ72VBM2.js → projectArchive-NU2Z5HOR.js} +15 -15
  131. package/{read-T7VU2IMO.js → read-BRZHXUJ6.js} +5 -5
  132. package/{readDocTool-BPQ3QJSD.js → readDocTool-N7RVFQEE.js} +1 -1
  133. package/{readlineWorkspace-YCPJTRW5.js → readlineWorkspace-RZCJAWF7.js} +586 -216
  134. package/{removeDialogAgentAction-FEUUVMYC.js → removeDialogAgentAction-J7XU7OUX.js} +9 -9
  135. package/{runAgentClientLoop-4Y6A5RP2.js → runAgentClientLoop-O2GRCGRZ.js} +33 -33
  136. package/{runtimeDoctorCommands-XQD4MN4I.js → runtimeDoctorCommands-RDRJXMXC.js} +2 -2
  137. package/{secretCommands-LH7QTJO2.js → secretCommands-2FEMRUFM.js} +2 -2
  138. package/{setDialogExtraReferencesAction-JSTQJPXL.js → setDialogExtraReferencesAction-Q4V2ZZW2.js} +8 -8
  139. package/{setPrimaryDialogAgentAction-Z2BQE3IY.js → setPrimaryDialogAgentAction-742H5S6T.js} +9 -9
  140. package/{settingThunks-VP3E3JRQ.js → settingThunks-T4FXSV6M.js} +11 -11
  141. package/{spaceCommands-DT7C6IJY.js → spaceCommands-C4UE2TNV.js} +11 -11
  142. package/{streamAgentChatTurn-CO345TNB.js → streamAgentChatTurn-OWDJMU5E.js} +36 -36
  143. package/{switchDialogAgentAction-G7XVAOGH.js → switchDialogAgentAction-HLDLHRRA.js} +7 -7
  144. package/{tableCommands-UHEA5QNL.js → tableCommands-44GC4N6J.js} +2 -2
  145. package/{tools-DYRSY7A7.js → tools-O7SGGVA3.js} +29 -29
  146. package/{tuiRestart-3J7LRMPR.js → tuiRestart-EOGC2BYY.js} +3 -3
  147. package/{tuiSummaryLlmCaller-2J6NG53N.js → tuiSummaryLlmCaller-TM5BU73J.js} +2 -2
  148. package/{updateCommands-5OYND6EF.js → updateCommands-FBYA5WVG.js} +3 -3
  149. package/{updateDialogTitleAction-SHVYVWSO.js → updateDialogTitleAction-EXSZGTLL.js} +14 -14
  150. package/{usageCommand-SK7JTEPC.js → usageCommand-L4OFWXEU.js} +2 -2
  151. package/{usageRebuildCommand-DF3HUP6F.js → usageRebuildCommand-7JR33UHS.js} +2 -2
  152. package/{windowsSelfUpdate-HIYNL3VR.js → windowsSelfUpdate-M4V77OUB.js} +2 -2
@@ -62,7 +62,7 @@ import {
62
62
  hashStablePrefixContent,
63
63
  resolveResponseGuidelines,
64
64
  resolveToolGuidedSections
65
- } from "./chunk-EJYSKGP2.js";
65
+ } from "./chunk-Z7KE4K3H.js";
66
66
  import {
67
67
  BRIDGE_STREAM_MAX_CHARS,
68
68
  CLI_NOLO_WORKSPACE_TOOL_NAMES,
@@ -77,7 +77,7 @@ import {
77
77
  parseNoloWorkspaceToolArguments,
78
78
  readTextStreamUpToChars,
79
79
  resolveNoloDialogInput
80
- } from "./chunk-2DWSICJH.js";
80
+ } from "./chunk-ITBX27W6.js";
81
81
  import {
82
82
  classifyUnparsableToolArgs,
83
83
  collectStablePromptPrefix,
@@ -142,7 +142,7 @@ import {
142
142
  } from "./chunk-WFGNWWJI.js";
143
143
  import {
144
144
  isAgentSkillDisabled
145
- } from "./chunk-VHXADZ32.js";
145
+ } from "./chunk-YDRRGVT5.js";
146
146
  import {
147
147
  buildDialogFallbackTitleFromUserInput
148
148
  } from "./chunk-2MBTWINN.js";
@@ -222,8 +222,9 @@ import {
222
222
  spillLargeToolOutput,
223
223
  spillToolOutput,
224
224
  toProcessTaskView,
225
- truncateToolOutput
226
- } from "./chunk-TB5KTLNB.js";
225
+ truncateToolOutput,
226
+ workspaceChildEnv
227
+ } from "./chunk-CTIEJRTP.js";
227
228
  import {
228
229
  estimateTokenCount
229
230
  } from "./chunk-PSCNXBYA.js";
@@ -14840,13 +14841,13 @@ async function invokeCapability(capabilityOrName, input, ctx = {}) {
14840
14841
  }
14841
14842
 
14842
14843
  // packages/agent-runtime/localWorkspaceTools.ts
14843
- import { existsSync as existsSync3 } from "node:fs";
14844
+ import { existsSync as existsSync2 } from "node:fs";
14844
14845
  import { createHash as createHash3 } from "node:crypto";
14845
14846
 
14846
14847
  // packages/agent-runtime/agentsMd.ts
14847
- import { existsSync, readFileSync } from "node:fs";
14848
- import { resolve } from "node:path";
14849
- var AGENTS_MD_MAX_BYTES = 8192;
14848
+ import { readFileSync, realpathSync, statSync } from "node:fs";
14849
+ import { isAbsolute, relative, resolve, sep } from "node:path";
14850
+ var AGENTS_MD_MAX_BYTES = 16 * 1024;
14850
14851
  var AGENTS_MD_MARKER_RESERVE_BYTES = 512;
14851
14852
  var AGENTS_MD_CANDIDATES = ["AGENTS.md", "CLAUDE.md"];
14852
14853
  function truncateAgentsMdContent(content, maxBytes = AGENTS_MD_MAX_BYTES) {
@@ -14888,7 +14889,7 @@ var AGENTS_MD_SUMMARY_PRIORITY_KEYWORDS = [
14888
14889
  "\u5220\u9664",
14889
14890
  "\u6D3E\u53D1"
14890
14891
  ];
14891
- var AGENTS_MD_SUMMARY_POINTER_INSTRUCTION = "\u7528 readFile \u8BFB\u5168\u6587\uFF1A%REL%\uFF08cwd\uFF09/ %PATH%\n\u4EC5\u7D22\u5F15\uFF1A\u63D0\u4EA4/\u8BC4\u5BA1\u95E8\u7981\u3001worktree \u9694\u79BB\u3001\u6D4B\u8BD5/typecheck\u3001\u6587\u6863\u843D\u4F4D\u3001\u5220\u9664\u3001push/\u53D1\u5E03\u524D\uFF0C**\u5FC5\u987B\u5148 readFile \u8BFB\u5168\u6587\u518D\u6267\u884C**\u3002\n\u8DEF\u5F84\uFF1A%REL% \u76F8\u5BF9 cwd\uFF1Bmachine:<id>/\u6C99\u76D2\u6267\u884C\u9762 cwd \u7531\u5176\u51B3\u5B9A\uFF0C\u8BFB\u4E0D\u5230\u8BA9\u5BBF\u4E3B\u6CE8\u5165\u6216\u7528\u7EDD\u5BF9\u8DEF\u5F84\u3002";
14892
+ var AGENTS_MD_SUMMARY_POINTER_INSTRUCTION = "\u7528 readFile \u8BFB\u5168\u6587\uFF1A%REL%\uFF08cwd\uFF09/ %PATH%\n\u4EC5\u7D22\u5F15\uFF08\u672A\u6CE8\u5165\u5168\u6587\uFF09\uFF1A\u63D0\u4EA4/\u8BC4\u5BA1\u95E8\u7981\u3001worktree \u9694\u79BB\u3001\u6D4B\u8BD5/typecheck\u3001\u6587\u6863\u843D\u4F4D\u3001\u5220\u9664\u3001push/\u53D1\u5E03\u524D\uFF0C**\u5FC5\u987B\u5148 readFile \u8BFB\u5168\u6587\u518D\u6267\u884C**\u3002\n\u8DEF\u5F84\uFF1A%REL% \u76F8\u5BF9 cwd\uFF1Bmachine:<id>/\u6C99\u76D2\u6267\u884C\u9762 cwd \u7531\u5176\u51B3\u5B9A\uFF0C\u8BFB\u4E0D\u5230\u8BA9\u5BBF\u4E3B\u6CE8\u5165\u6216\u7528\u7EDD\u5BF9\u8DEF\u5F84\u3002";
14892
14893
  var AGENTS_MD_SUMMARY_DELETE_REFERENCE = "- \u5220\u9664/\u4E0D\u53EF\u9006\u64CD\u4F5C\uFF1A\u9075\u5B88\u7CFB\u7EDF\u63D0\u793A\u7684\u5220\u9664\u7EA2\u7EBF\uFF08\u5148\u5448\u73B0\u5B8C\u6574\u5F85\u5220\u6E05\u5355\u5E76\u83B7\u7528\u6237\u660E\u786E\u786E\u8BA4\uFF0C\u7981\u6B62\u5148\u5220\u540E\u62A5\u3001\u7981\u6B62\u6A21\u7CCA\u5B9A\u4F4D\uFF09\uFF0C\u4ED3\u5E93\u82E5\u6709\u9644\u52A0\u5220\u9664\u89C4\u5219\u89C1\u5B8C\u6574\u6587\u4EF6\u3002";
14893
14894
  var clipToChars = (text2, maxChars) => text2.length <= maxChars ? text2 : `${text2.slice(0, maxChars).trimEnd()}\u2026`;
14894
14895
  var parseAgentsMdItem = (body) => {
@@ -15045,11 +15046,21 @@ ${entry.line}`;
15045
15046
  return rendered;
15046
15047
  };
15047
15048
  function readAgentsMdLayerFromDisk(cwd) {
15049
+ if (!cwd) return null;
15050
+ let root;
15051
+ try {
15052
+ root = realpathSync(cwd);
15053
+ } catch {
15054
+ return null;
15055
+ }
15048
15056
  for (const name of AGENTS_MD_CANDIDATES) {
15049
15057
  const filePath = resolve(cwd, name);
15050
- if (!existsSync(filePath)) continue;
15051
15058
  try {
15052
- const raw = readFileSync(filePath, "utf8");
15059
+ const target = realpathSync(resolve(root, name));
15060
+ const targetRelative = relative(root, target);
15061
+ if (targetRelative === ".." || targetRelative.startsWith(`..${sep}`) || isAbsolute(targetRelative)) continue;
15062
+ if (!statSync(target).isFile()) continue;
15063
+ const raw = readFileSync(target, "utf8");
15053
15064
  const content = raw.trim();
15054
15065
  if (!content) continue;
15055
15066
  const totalBytes = Buffer.byteLength(raw, "utf8");
@@ -15088,20 +15099,20 @@ ${marker}`, name);
15088
15099
 
15089
15100
  // packages/agent-runtime/visualRenderer.node.ts
15090
15101
  import { createRequire } from "node:module";
15091
- import { existsSync as existsSync2 } from "node:fs";
15102
+ import { existsSync } from "node:fs";
15092
15103
  import { realpath, stat, readFile } from "node:fs/promises";
15093
- import { isAbsolute, relative, win32 } from "node:path";
15104
+ import { isAbsolute as isAbsolute2, relative as relative2, win32 } from "node:path";
15094
15105
  import { fileURLToPath, pathToFileURL } from "node:url";
15095
15106
  import { lookup as lookup2 } from "node:dns/promises";
15096
15107
  import { isIP } from "node:net";
15097
15108
  function isVisualPathOutside(rel) {
15098
- return rel === ".." || /^\.\.[\\/]/.test(rel) || isAbsolute(rel) || win32.isAbsolute(rel);
15109
+ return rel === ".." || /^\.\.[\\/]/.test(rel) || isAbsolute2(rel) || win32.isAbsolute(rel);
15099
15110
  }
15100
15111
  async function validateVisualUrl(input, workspaceRoot) {
15101
15112
  const url = new URL(input);
15102
15113
  if (url.protocol === "file:") {
15103
15114
  const [root, path] = await Promise.all([realpath(workspaceRoot), realpath(fileURLToPath(url))]);
15104
- const rel = relative(root, path);
15115
+ const rel = relative2(root, path);
15105
15116
  if (isVisualPathOutside(rel)) throw new Error("Renderer file URL is outside workspaceRoot.");
15106
15117
  if (!(await stat(path)).isFile()) throw new Error("Renderer file URL must point to a file, not a directory.");
15107
15118
  return pathToFileURL(path);
@@ -15159,7 +15170,7 @@ function visualRendererCapability() {
15159
15170
  if (process.env.NOLO_VISUAL_RENDERER_DISABLED === "1") return { available: false, reasonCode: "disabled", reason: "Platform renderer disabled by NOLO_VISUAL_RENDERER_DISABLED=1 on this runtime host." };
15160
15171
  try {
15161
15172
  const { chromium } = require2("playwright");
15162
- const executablePath = [chromium.executablePath(), resolveExecutableOnPath("google-chrome"), resolveExecutableOnPath("chromium"), resolveExecutableOnPath("chromium-browser")].find((path) => !!path && existsSync2(path));
15173
+ const executablePath = [chromium.executablePath(), resolveExecutableOnPath("google-chrome"), resolveExecutableOnPath("chromium"), resolveExecutableOnPath("chromium-browser")].find((path) => !!path && existsSync(path));
15163
15174
  if (!executablePath) return { available: false, reasonCode: "missing-browser", reason: "No Chromium renderer installed. Install Playwright Chromium (playwright install chromium) or system Chromium/Google Chrome on the runtime host." };
15164
15175
  return { available: true, chromium, executablePath };
15165
15176
  } catch {
@@ -15175,10 +15186,10 @@ async function renderVisualPage(args2) {
15175
15186
  if (typeof args2.persistScreenshot !== "function") {
15176
15187
  throw new Error("renderVisualPage: persistScreenshot is required (expected a function that stores the PNG bytes)");
15177
15188
  }
15178
- if (!isAbsolute(args2.workspaceRoot)) {
15189
+ if (!isAbsolute2(args2.workspaceRoot)) {
15179
15190
  throw new Error("renderVisualPage: workspaceRoot must be an absolute path");
15180
15191
  }
15181
- if (!isAbsolute(args2.screenshotPath) || !relative(args2.workspaceRoot, args2.screenshotPath) || isVisualPathOutside(relative(args2.workspaceRoot, args2.screenshotPath))) {
15192
+ if (!isAbsolute2(args2.screenshotPath) || !relative2(args2.workspaceRoot, args2.screenshotPath) || isVisualPathOutside(relative2(args2.workspaceRoot, args2.screenshotPath))) {
15182
15193
  throw new Error("renderVisualPage: screenshotPath must be a file path inside workspaceRoot");
15183
15194
  }
15184
15195
  if (args2.timeoutMs !== void 0 && (typeof args2.timeoutMs !== "number" || !Number.isFinite(args2.timeoutMs) || args2.timeoutMs <= 0)) {
@@ -15406,7 +15417,17 @@ function createHostWindowCapture(options = {}) {
15406
15417
  return {
15407
15418
  ...image,
15408
15419
  content: `${formatImageSummary({ kind: "screenshot", ...image.imageSummary })}
15409
- \u6765\u6E90\uFF1A\u5BBF\u4E3B portal \u5168\u5C4F/\u4EA4\u4E92\u9009\u62E9\u7ED3\u679C\uFF1Bportal \u672A\u63D0\u4F9B\u5E94\u7528/\u7A97\u53E3\u8EAB\u4EFD\uFF0C\u65E0\u6CD5\u786E\u8BA4\u7A97\u53E3\u540D\u3002`
15420
+ \u6765\u6E90\uFF1A\u5BBF\u4E3B portal \u5168\u5C4F/\u4EA4\u4E92\u9009\u62E9\u7ED3\u679C\uFF1Bportal \u672A\u63D0\u4F9B\u5E94\u7528/\u7A97\u53E3\u8EAB\u4EFD\uFF0C\u65E0\u6CD5\u786E\u8BA4\u7A97\u53E3\u540D\u3002`,
15421
+ metadata: {
15422
+ path: image.imageSummary.path,
15423
+ imageArtifacts: [{
15424
+ path: image.imageSummary.path,
15425
+ kind: "screenshot",
15426
+ width: image.imageSummary.width,
15427
+ height: image.imageSummary.height,
15428
+ bytes: image.imageSummary.bytes
15429
+ }]
15430
+ }
15410
15431
  };
15411
15432
  } finally {
15412
15433
  active--;
@@ -15435,7 +15456,7 @@ var captureHostWindow = createHostWindowCapture();
15435
15456
  // packages/agent-runtime/localWorkspaceTools.ts
15436
15457
  import { lstat as lstat2, readdir as readdir2, readFile as readFile4, realpath as realpath3, stat as stat4 } from "node:fs/promises";
15437
15458
  import { homedir } from "node:os";
15438
- import { dirname as dirname2, relative as relative4, resolve as resolve5, sep as sep2 } from "node:path";
15459
+ import { dirname as dirname2, relative as relative5, resolve as resolve5, sep as sep3 } from "node:path";
15439
15460
  import { spawn as spawnChildProcess2 } from "node:child_process";
15440
15461
 
15441
15462
  // packages/agent-runtime/runResultReadProjection.ts
@@ -15518,7 +15539,7 @@ function isLineRangeCovered(request3, covered) {
15518
15539
 
15519
15540
  // packages/agent-runtime/fileTextSearch.ts
15520
15541
  import { readdir, readFile as readFile3, stat as stat3 } from "node:fs/promises";
15521
- import { basename as basename2, relative as relative2, resolve as resolve3 } from "node:path";
15542
+ import { basename as basename2, relative as relative3, resolve as resolve3 } from "node:path";
15522
15543
  import { spawn as spawnChildProcess } from "node:child_process";
15523
15544
 
15524
15545
  // packages/agent-runtime/gitignore.ts
@@ -15558,7 +15579,7 @@ async function hasRootGitignore(workspaceRoot) {
15558
15579
 
15559
15580
  // packages/agent-runtime/fileTextSearch.ts
15560
15581
  var normalizePath = (value) => value.replaceAll("\\", "/");
15561
- var pathFor = (root, file, absolute = false) => absolute ? normalizePath(file) : normalizePath(relative2(root, file) || basename2(file));
15582
+ var pathFor = (root, file, absolute = false) => absolute ? normalizePath(file) : normalizePath(relative3(root, file) || basename2(file));
15562
15583
  var COMMAND_LIMIT_HEADROOM = 1;
15563
15584
  var MAX_SEARCH_FILE_BYTES = 8 * 1024 * 1024;
15564
15585
  var MAX_SEARCH_LINE_CHARS = 2e3;
@@ -16470,10 +16491,10 @@ function filterDeclaredWorkspaceToolNames(args2) {
16470
16491
  // packages/agent-runtime/workspacePathGuard.ts
16471
16492
  import { constants as fsConstants } from "node:fs";
16472
16493
  import { lstat, mkdir, open, readlink, realpath as realpath2 } from "node:fs/promises";
16473
- import { basename as basename3, dirname, isAbsolute as isAbsolute2, join as join2, relative as relative3, resolve as resolve4, sep } from "node:path";
16494
+ import { basename as basename3, dirname, isAbsolute as isAbsolute3, join as join2, relative as relative4, resolve as resolve4, sep as sep2 } from "node:path";
16474
16495
  function isPathInsideRoot(root, targetPath) {
16475
- const rel = relative3(resolve4(root), resolve4(targetPath));
16476
- return rel === "" || rel !== ".." && !rel.startsWith(`..${sep}`) && !isAbsolute2(rel);
16496
+ const rel = relative4(resolve4(root), resolve4(targetPath));
16497
+ return rel === "" || rel !== ".." && !rel.startsWith(`..${sep2}`) && !isAbsolute3(rel);
16477
16498
  }
16478
16499
  function isNotFoundError(error) {
16479
16500
  const code = error?.code;
@@ -16560,7 +16581,7 @@ async function resolveOpenedFilePath(handle) {
16560
16581
  for (const root of FD_LINK_ROOTS) {
16561
16582
  try {
16562
16583
  const linked = await readlink(`${root}/${handle.fd}`);
16563
- if (isAbsolute2(linked)) return linked.replace(/ \(deleted\)$/, "");
16584
+ if (isAbsolute3(linked)) return linked.replace(/ \(deleted\)$/, "");
16564
16585
  } catch {
16565
16586
  }
16566
16587
  }
@@ -16850,12 +16871,12 @@ function parseWorkspaceToolArguments(raw) {
16850
16871
  }
16851
16872
  }
16852
16873
  function normalizeWorkspaceRelativePath(args2) {
16853
- const relativePath = relative4(args2.workspaceRoot, args2.targetPath);
16874
+ const relativePath = relative5(args2.workspaceRoot, args2.targetPath);
16854
16875
  return relativePath || ".";
16855
16876
  }
16856
16877
  function isPathInsideWorkspace(args2) {
16857
- const relativePath = relative4(args2.workspaceRoot, args2.targetPath);
16858
- return relativePath === "" || !relativePath.startsWith("..") && !relativePath.includes(`..${sep2}`);
16878
+ const relativePath = relative5(args2.workspaceRoot, args2.targetPath);
16879
+ return relativePath === "" || !relativePath.startsWith("..") && !relativePath.includes(`..${sep3}`);
16859
16880
  }
16860
16881
  var PATH_FIELD_ALIASES = ["path", "file_path", "filePath", "filename", "file", "target_file", "targetFile", "file_to_read", "fileToRead", "target_path", "read_path", "path_to_read", "pathToRead"];
16861
16882
  var OLD_TEXT_FIELD_ALIASES = ["oldText", "old_string", "oldString", "search", "search_string", "find", "match"];
@@ -17116,7 +17137,7 @@ function resolveRipgrepBinary(env = process.env) {
17116
17137
  const fromEnv = asOptionalTrimmedString(env.NOLO_BUNDLED_RG);
17117
17138
  if (fromEnv) {
17118
17139
  try {
17119
- if (existsSync3(fromEnv)) return fromEnv;
17140
+ if (existsSync2(fromEnv)) return fromEnv;
17120
17141
  } catch {
17121
17142
  }
17122
17143
  }
@@ -17620,7 +17641,7 @@ async function listWorkspaceEntries(args2) {
17620
17641
  if (truncated) break;
17621
17642
  const absolutePath = resolve5(dirPath, name);
17622
17643
  const info = await stat4(absolutePath);
17623
- const relativePath = relative4(args2.dirPath, absolutePath) || ".";
17644
+ const relativePath = relative5(args2.dirPath, absolutePath) || ".";
17624
17645
  const isDirectory = info.isDirectory();
17625
17646
  entries.push(isDirectory ? `${relativePath}/` : relativePath);
17626
17647
  if (args2.maxResults && entries.length >= args2.maxResults) {
@@ -17925,7 +17946,14 @@ async function captureVisualStateTool(args2) {
17925
17946
  script: null,
17926
17947
  args: [],
17927
17948
  compatibilityVersion: 2,
17928
- compatibilityNote: "Platform rendering replaces workspace scripts; script/args/stdoutTail no longer describe a subprocess. Existing page metrics and path fields are retained."
17949
+ compatibilityNote: "Platform rendering replaces workspace scripts; script/args/stdoutTail no longer describe a subprocess. Existing page metrics and path fields are retained.",
17950
+ imageArtifacts: [{
17951
+ path: screenshotPath,
17952
+ kind: "screenshot",
17953
+ width: image.imageSummary.width,
17954
+ height: image.imageSummary.height,
17955
+ bytes: image.imageSummary.bytes
17956
+ }]
17929
17957
  }
17930
17958
  };
17931
17959
  } catch (error) {
@@ -18028,6 +18056,7 @@ async function launchProcessTool(args2) {
18028
18056
  const detached = process.platform !== "win32";
18029
18057
  const proc = spawnChildProcess2(cmdArgs[0] ?? "", cmdArgs.slice(1), {
18030
18058
  cwd: resolve5(args2.workspaceRoot),
18059
+ env: workspaceChildEnv(),
18031
18060
  stdio: ["ignore", "pipe", "pipe"],
18032
18061
  detached,
18033
18062
  windowsHide: true
@@ -18373,12 +18402,25 @@ function createLocalWorkspaceToolExecutors(args2) {
18373
18402
  });
18374
18403
  return await readLocalImage(absolutePath);
18375
18404
  } catch (error) {
18376
- throw new Error(`read_image: failed to read ${JSON.stringify(path)}: ${error instanceof Error ? error.message : String(error)}`);
18405
+ const inner = (error instanceof Error ? error.message : String(error)).replace(/^read_image:\s*/i, "");
18406
+ throw new Error(`read_image: failed to read ${JSON.stringify(path)}: ${inner}`);
18377
18407
  }
18378
18408
  }));
18379
18409
  return {
18380
18410
  content: results2.map((result4) => result4.content).join("\n"),
18381
- images: results2.flatMap((result4) => result4.images ?? [])
18411
+ images: results2.flatMap((result4) => result4.images ?? []),
18412
+ metadata: {
18413
+ paths: imagePaths,
18414
+ count: imagePaths.length,
18415
+ ...imagePaths.length === 1 ? { path: imagePaths[0] } : {},
18416
+ imageArtifacts: results2.map((result4) => ({
18417
+ path: result4.imageSummary.path,
18418
+ kind: "image",
18419
+ width: result4.imageSummary.width,
18420
+ height: result4.imageSummary.height,
18421
+ bytes: result4.imageSummary.bytes
18422
+ }))
18423
+ }
18382
18424
  };
18383
18425
  },
18384
18426
  readFile: Object.assign((call) => readFileTool({
@@ -18890,6 +18932,78 @@ function emitLoopEvent(boundary, event, bridge) {
18890
18932
  function clip(value, max4 = 240) {
18891
18933
  return clipCompactText(value, max4);
18892
18934
  }
18935
+ var IMAGE_ARTIFACT_TOOL_NAMES = /* @__PURE__ */ new Set([
18936
+ "read_image",
18937
+ "captureVisualState",
18938
+ "browser_screenshot",
18939
+ "captureHostWindow"
18940
+ ]);
18941
+ function sanitizeArtifactPath(raw) {
18942
+ if (typeof raw !== "string") return void 0;
18943
+ const trimmed = raw.trim();
18944
+ if (!trimmed || /[\u0000-\u001f\u007f]/.test(trimmed)) return void 0;
18945
+ if (/^(?:https?|data|javascript):/i.test(trimmed)) return void 0;
18946
+ return trimmed;
18947
+ }
18948
+ function normalizeStructuredImageArtifact(raw, defaultKind) {
18949
+ if (!raw || typeof raw !== "object") return void 0;
18950
+ const item = raw;
18951
+ const path = sanitizeArtifactPath(item.path);
18952
+ if (!path) return void 0;
18953
+ const kind = item.kind === "image" || item.kind === "screenshot" ? item.kind : defaultKind;
18954
+ return {
18955
+ path,
18956
+ kind,
18957
+ ...typeof item.width === "number" && Number.isFinite(item.width) && item.width > 0 ? { width: item.width } : {},
18958
+ ...typeof item.height === "number" && Number.isFinite(item.height) && item.height > 0 ? { height: item.height } : {},
18959
+ ...typeof item.bytes === "number" && Number.isFinite(item.bytes) && item.bytes > 0 ? { bytes: item.bytes } : {}
18960
+ };
18961
+ }
18962
+ function extractToolImageArtifacts(toolName, toolResult) {
18963
+ if (!IMAGE_ARTIFACT_TOOL_NAMES.has(toolName)) return void 0;
18964
+ const metadata = toolResult.metadata;
18965
+ if (!metadata || typeof metadata !== "object") return void 0;
18966
+ if (metadata.ok === false || metadata.imageDelivered === false || metadata.cancelled === true || metadata.failed === true) {
18967
+ return void 0;
18968
+ }
18969
+ const defaultKind = toolName === "read_image" ? "image" : "screenshot";
18970
+ const byPath = /* @__PURE__ */ new Map();
18971
+ const add2 = (candidate) => {
18972
+ const path = sanitizeArtifactPath(candidate.path);
18973
+ if (!path) return;
18974
+ const kind = candidate.kind ?? defaultKind;
18975
+ const existing = byPath.get(path);
18976
+ if (!existing) {
18977
+ byPath.set(path, {
18978
+ path,
18979
+ kind,
18980
+ ...candidate.width !== void 0 ? { width: candidate.width } : {},
18981
+ ...candidate.height !== void 0 ? { height: candidate.height } : {},
18982
+ ...candidate.bytes !== void 0 ? { bytes: candidate.bytes } : {}
18983
+ });
18984
+ return;
18985
+ }
18986
+ if (existing.width === void 0 && candidate.width !== void 0) existing.width = candidate.width;
18987
+ if (existing.height === void 0 && candidate.height !== void 0) existing.height = candidate.height;
18988
+ if (existing.bytes === void 0 && candidate.bytes !== void 0) existing.bytes = candidate.bytes;
18989
+ };
18990
+ if (Array.isArray(metadata.imageArtifacts)) {
18991
+ for (const entry of metadata.imageArtifacts) {
18992
+ const normalized = normalizeStructuredImageArtifact(entry, defaultKind);
18993
+ if (normalized) add2(normalized);
18994
+ }
18995
+ return byPath.size > 0 ? Array.from(byPath.values()) : void 0;
18996
+ }
18997
+ if (Array.isArray(metadata.paths)) {
18998
+ for (const item of metadata.paths) {
18999
+ if (typeof item === "string") add2({ path: item });
19000
+ }
19001
+ }
19002
+ if (typeof metadata.screenshotPath === "string") add2({ path: metadata.screenshotPath });
19003
+ if (typeof metadata.savedTo === "string") add2({ path: metadata.savedTo });
19004
+ if (typeof metadata.path === "string") add2({ path: metadata.path });
19005
+ return byPath.size > 0 ? Array.from(byPath.values()) : void 0;
19006
+ }
18893
19007
  function projectSafeToolObservationMetadata(metadata) {
18894
19008
  if (!metadata || typeof metadata !== "object") return void 0;
18895
19009
  const safe = {};
@@ -19188,6 +19302,7 @@ ${toolResult.content}` : toolResult.content,
19188
19302
  const finishedAt = Date.now();
19189
19303
  const summary = summarizeToolResult(toolResult.content, toolResult.metadata);
19190
19304
  const safeMetadata = projectSafeToolObservationMetadata(toolResult.metadata);
19305
+ const imageArtifacts = extractToolImageArtifacts(toolName, toolResult);
19191
19306
  loopTiming.mark("toolExecute", round);
19192
19307
  emitLoopEvent(
19193
19308
  boundary,
@@ -19210,7 +19325,8 @@ ${toolResult.content}` : toolResult.content,
19210
19325
  elapsedMs: Math.max(0, finishedAt - startedAt),
19211
19326
  ...summary ? { summary } : {},
19212
19327
  ...typeof toolResult.content === "string" ? { content: toolResult.content } : {},
19213
- metadata: toolResult.metadata
19328
+ metadata: toolResult.metadata,
19329
+ ...imageArtifacts ? { imageArtifacts } : {}
19214
19330
  }
19215
19331
  );
19216
19332
  } catch (error) {
@@ -23718,7 +23834,7 @@ async function saveCliPendingUserMessages(args2) {
23718
23834
  if (ops.length) await args2.store.batch(ops);
23719
23835
  }
23720
23836
  async function readCliPendingUserMessages(store, dialogId) {
23721
- const { readDialogMessageRecords } = await import("./cliLocalAgentRecordReader-P2DQNSEC.js");
23837
+ const { readDialogMessageRecords } = await import("./cliLocalAgentRecordReader-LWMGOH3X.js");
23722
23838
  const rows = await readDialogMessageRecords({ store, dialogId });
23723
23839
  const uncertain = rows.filter(({ record: record2 }) => record2.metadata?.cliBatchPhase === "requested" && !record2.metadata?.cliBatchResolution);
23724
23840
  const recovery = uncertain.length ? {
@@ -23825,7 +23941,7 @@ async function runNoloWorkspaceCliTool(call, args2) {
23825
23941
  cmd,
23826
23942
  stdout: "pipe",
23827
23943
  stderr: "pipe",
23828
- env: call.name === "listAgents" ? { ...process.env, ...args2.env, NOLO_PLANNING_CALLER: JSON.stringify(args2.planningCaller ?? {}) } : args2.env
23944
+ env: workspaceChildEnv(call.name === "listAgents" ? { ...process.env, ...args2.env, NOLO_PLANNING_CALLER: JSON.stringify(args2.planningCaller ?? {}) } : args2.env)
23829
23945
  });
23830
23946
  const [stdout, stderr, exitCode] = await Promise.all([
23831
23947
  readNoloProcessStream(proc.stdout),
@@ -24020,7 +24136,7 @@ function buildLoadSkillExecutor(args2) {
24020
24136
  const { resolveSkillByName } = await import("./skillDiscovery-MDDKPTW3.js");
24021
24137
  const resolved = resolveSkillByName(args2.cwd, name);
24022
24138
  if (!resolved) {
24023
- const { resolveBuiltinSkillByName } = await import("./builtinSkillRegistry-K7XDZWQJ.js");
24139
+ const { resolveBuiltinSkillByName } = await import("./builtinSkillRegistry-VRCMQ77Q.js");
24024
24140
  const builtin = resolveBuiltinSkillByName(name);
24025
24141
  if (builtin) {
24026
24142
  const denied = await rejectDisabledBuiltin(args2.agentSkillSource, builtin.slug, name, args2.resolveAgentSkillSource);
@@ -24099,7 +24215,7 @@ async function loadPreciseSkill(cwd, parsed, agentSkillSource, resolveAgentSkill
24099
24215
  if (!nonEmpty(parsed.slug) || has2("projectBinding") || has2("relativePath")) {
24100
24216
  return reject("builtin requires only an exact slug.");
24101
24217
  }
24102
- const { listBuiltinSkills } = await import("./builtinSkillRegistry-K7XDZWQJ.js");
24218
+ const { listBuiltinSkills } = await import("./builtinSkillRegistry-VRCMQ77Q.js");
24103
24219
  const builtin = listBuiltinSkills().find((entry) => entry.slug === parsed.slug);
24104
24220
  if (!builtin) return reject("builtin slug not found.");
24105
24221
  const denied = await rejectDisabledBuiltin(agentSkillSource, builtin.slug, builtin.slug, resolveAgentSkillSource);
@@ -24124,28 +24240,28 @@ ${builtin.content}`,
24124
24240
  return reject("project requires projectBinding and relativePath only.");
24125
24241
  }
24126
24242
  try {
24127
- const { realpathSync, statSync, readFileSync: readFileSync2 } = await import("node:fs");
24128
- const { resolve: resolve7, relative: relative6, isAbsolute: isAbsolute5, basename: basename4, sep: sep3 } = await import("node:path");
24243
+ const { realpathSync: realpathSync2, statSync: statSync2, readFileSync: readFileSync2 } = await import("node:fs");
24244
+ const { resolve: resolve7, relative: relative7, isAbsolute: isAbsolute6, basename: basename4, sep: sep4 } = await import("node:path");
24129
24245
  const inside = (root, target) => {
24130
- const rel = relative6(root, target);
24131
- return rel !== "" && rel !== ".." && !rel.startsWith(`..${sep3}`) && !isAbsolute5(rel);
24246
+ const rel = relative7(root, target);
24247
+ return rel !== "" && rel !== ".." && !rel.startsWith(`..${sep4}`) && !isAbsolute6(rel);
24132
24248
  };
24133
- const realCwd = realpathSync(cwd);
24134
- if (!isAbsolute5(parsed.projectBinding) || realpathSync(parsed.projectBinding) !== realCwd) {
24249
+ const realCwd = realpathSync2(cwd);
24250
+ if (!isAbsolute6(parsed.projectBinding) || realpathSync2(parsed.projectBinding) !== realCwd) {
24135
24251
  return reject("projectBinding does not match the authorized cwd.");
24136
24252
  }
24137
- if (isAbsolute5(parsed.relativePath) || basename4(parsed.relativePath) !== "SKILL.md") {
24253
+ if (isAbsolute6(parsed.relativePath) || basename4(parsed.relativePath) !== "SKILL.md") {
24138
24254
  return reject("relativePath must reference a project SKILL.md.");
24139
24255
  }
24140
24256
  const skillsRoot = resolve7(realCwd, ".agents", "skills");
24141
24257
  const candidate = resolve7(realCwd, parsed.relativePath);
24142
24258
  if (!inside(skillsRoot, candidate)) return reject("path is outside cwd/.agents/skills/.");
24143
- const realRoot = realpathSync(skillsRoot);
24144
- const realPath = realpathSync(candidate);
24259
+ const realRoot = realpathSync2(skillsRoot);
24260
+ const realPath = realpathSync2(candidate);
24145
24261
  if (realRoot !== skillsRoot || !inside(realRoot, realPath) || basename4(realPath) !== "SKILL.md") {
24146
24262
  return reject("skill path escapes cwd/.agents/skills/ or is not SKILL.md.");
24147
24263
  }
24148
- if (!statSync(realPath).isFile()) return reject("SKILL.md is not a file.");
24264
+ if (!statSync2(realPath).isFile()) return reject("SKILL.md is not a file.");
24149
24265
  const body = readFileSync2(realPath, "utf8");
24150
24266
  return {
24151
24267
  content: `Skill "${parsed.relativePath}" loaded inline. Follow its instructions.
@@ -24737,17 +24853,17 @@ function createDevinProvider(options) {
24737
24853
  }
24738
24854
 
24739
24855
  // packages/agent-runtime/executionLeaseValidation.ts
24740
- import { isAbsolute as isAbsolute4, relative as relative5, resolve as resolve6 } from "node:path";
24856
+ import { isAbsolute as isAbsolute5, relative as relative6, resolve as resolve6 } from "node:path";
24741
24857
  function withinRoot(root, child) {
24742
- if (!isAbsolute4(root) || !isAbsolute4(child)) return false;
24858
+ if (!isAbsolute5(root) || !isAbsolute5(child)) return false;
24743
24859
  const canonicalRoot = resolve6(root);
24744
24860
  const canonicalChild = resolve6(child);
24745
- const suffix = relative5(canonicalRoot, canonicalChild);
24746
- return suffix === "" || suffix !== ".." && !suffix.startsWith("../") && !suffix.startsWith("..\\") && !isAbsolute4(suffix);
24861
+ const suffix = relative6(canonicalRoot, canonicalChild);
24862
+ return suffix === "" || suffix !== ".." && !suffix.startsWith("../") && !suffix.startsWith("..\\") && !isAbsolute5(suffix);
24747
24863
  }
24748
24864
  function subsetOf(allowed, actual) {
24749
24865
  return actual.every(
24750
- (root) => isAbsolute4(root) && allowed.some((parent) => withinRoot(parent, root))
24866
+ (root) => isAbsolute5(root) && allowed.some((parent) => withinRoot(parent, root))
24751
24867
  );
24752
24868
  }
24753
24869
  function validateConfiguredRootExecutionLease(ticket, lease) {
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  authRoutes
3
- } from "./chunk-F26GAEH3.js";
3
+ } from "./chunk-OYUMJMC5.js";
4
4
  import {
5
5
  BUILTIN_DIALOG_LLM_FALLBACK_MODEL,
6
6
  BUILTIN_SUMMARY_LLM_CONFIG
@@ -5,7 +5,7 @@ import {
5
5
  inlineImageUrlsForCustomProvider,
6
6
  prepareTools,
7
7
  shouldInlineImageUrlsForAgent
8
- } from "./chunk-7VNVB4OY.js";
8
+ } from "./chunk-IIOSZAJX.js";
9
9
  import {
10
10
  CONFIRMATION_INPUT_KEYS,
11
11
  INVALID_TOOL_ARGS_REPLACEMENT,
@@ -14,11 +14,11 @@ import {
14
14
  performFetchRequest,
15
15
  sanitizeOutboundMessages,
16
16
  stripModelToolArgs
17
- } from "./chunk-EXZBHOTV.js";
17
+ } from "./chunk-VKCPKCSS.js";
18
18
  import {
19
19
  findToolExecutor,
20
20
  toolDefinitionsByName
21
- } from "./chunk-PUNGLYNR.js";
21
+ } from "./chunk-FTWAOKFU.js";
22
22
  import {
23
23
  createSSEParser,
24
24
  createToolRunId,
@@ -27,7 +27,7 @@ import {
27
27
  toolRunSetPending,
28
28
  toolRunStarted,
29
29
  toolRunSucceeded
30
- } from "./chunk-IOIWS357.js";
30
+ } from "./chunk-LMGFVH65.js";
31
31
  import {
32
32
  addToolMessage,
33
33
  messageStreamEnd,
@@ -35,16 +35,16 @@ import {
35
35
  toast,
36
36
  toolResultNeedsUserConfirmation,
37
37
  updateToolMessage
38
- } from "./chunk-PPIQDGJT.js";
38
+ } from "./chunk-YFW4H6DL.js";
39
39
  import {
40
40
  streamAgentChatTurn
41
- } from "./chunk-XWJXQLQB.js";
41
+ } from "./chunk-N74XL3NI.js";
42
42
  import {
43
43
  getCurrentSpaceId
44
- } from "./chunk-RXTZB2DH.js";
44
+ } from "./chunk-FFFKAOJN.js";
45
45
  import {
46
46
  write
47
- } from "./chunk-PDAXMBLW.js";
47
+ } from "./chunk-HZDK56EK.js";
48
48
  import {
49
49
  addActiveController,
50
50
  getActiveDialogKey,
@@ -56,10 +56,10 @@ import {
56
56
  } from "./chunk-RD3QLZQV.js";
57
57
  import {
58
58
  selectCurrentServer
59
- } from "./chunk-76HAJUOJ.js";
59
+ } from "./chunk-MTM4LRVG.js";
60
60
  import {
61
61
  createAsyncThunk
62
- } from "./chunk-QOURTDZL.js";
62
+ } from "./chunk-6XVPMGXK.js";
63
63
  import {
64
64
  selectIdentityToken
65
65
  } from "./chunk-PXYBUFDB.js";