@qqbrowser/openclaw-qbot 0.0.139 → 0.0.142

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 (1565) hide show
  1. package/dist/account-lookup-CW-_CL7y.js +1 -0
  2. package/dist/acp-cli-BaslDuk6.js +1 -0
  3. package/dist/acp-cli-f5-uI85a.js +1 -0
  4. package/dist/active-listener-Cce5tcPa.js +1 -0
  5. package/dist/active-listener-D8VOdVx3.js +1 -0
  6. package/dist/active-listener-DeKRt_UV.js +1 -0
  7. package/dist/active-listener-Dle9QX40.js +1 -0
  8. package/dist/agent-scope-DAWJwFfl.js +1 -0
  9. package/dist/agent-scope-DXZc3eNT.js +1 -0
  10. package/dist/agents-Bpp_F5In.js +1 -0
  11. package/dist/agents.config-B6LRG9eP.js +1 -0
  12. package/dist/agents.config-DfIJAGcd.js +1 -0
  13. package/dist/allow-from-B6dI7oz8.js +1 -0
  14. package/dist/allow-from-DEeVIPKS.js +1 -0
  15. package/dist/api-BeG0ObSq.js +1 -0
  16. package/dist/api-Dx8x1KTs.js +1 -0
  17. package/dist/api-key-rotation-BRt-vnRV.js +1 -0
  18. package/dist/api-key-rotation-CCH1wYVU.js +1 -0
  19. package/dist/api-key-rotation-D0QU-kQ9.js +1 -0
  20. package/dist/api-key-rotation-Di6QgXx7.js +1 -0
  21. package/dist/arg-split-BOqSMBuf.js +1 -0
  22. package/dist/arg-split-DE5RqDHq.js +1 -0
  23. package/dist/audio-preflight-B5o7P9qi.js +1 -0
  24. package/dist/audio-preflight-CxD7VCHW.js +1 -0
  25. package/dist/audio-preflight-DKSCBKRb.js +1 -0
  26. package/dist/audio-preflight-Dpk8-Bmk.js +1 -0
  27. package/dist/audio-transcription-runner-Bd1OZC6K.js +1 -0
  28. package/dist/audio-transcription-runner-D4Bp6MM7.js +1 -0
  29. package/dist/audio-transcription-runner-DPwmBYQj.js +1 -0
  30. package/dist/audio-transcription-runner-DSr6OIz1.js +1 -0
  31. package/dist/audit-C7RP7G_g.js +1 -0
  32. package/dist/audit-jkdcAUep.js +1 -0
  33. package/dist/audit-membership-runtime-BpRsMj5-.js +1 -0
  34. package/dist/audit-membership-runtime-BsfLZNBj.js +1 -0
  35. package/dist/audit-membership-runtime-DRHirRmx.js +1 -0
  36. package/dist/audit-membership-runtime-g0dEWJTp.js +1 -0
  37. package/dist/audit-membership-runtime-kdyToskD.js +1 -0
  38. package/dist/auth-choice-B7LSoXZ_.js +1 -0
  39. package/dist/auth-choice-CxMH4c-u.js +1 -0
  40. package/dist/auth-choice-DvTApGhx.js +1 -0
  41. package/dist/auth-choice-EQdNd7jO.js +1 -0
  42. package/dist/auth-choice-options-B3WQyS7I.js +1 -0
  43. package/dist/auth-choice-options-Dw14noox.js +1 -0
  44. package/dist/auth-choice-prompt-uegl56cf.js +1 -0
  45. package/dist/auth-choice-prompt-xYj13czb.js +1 -0
  46. package/dist/auth-choice.apply-helpers-B7S-PcH_.js +1 -0
  47. package/dist/auth-choice.apply-helpers-gaL-oSft.js +1 -0
  48. package/dist/auth-profiles-T8DuH3ax.js +1 -0
  49. package/dist/auth-token-9OTF1FmL.js +1 -0
  50. package/dist/auth-token-kGltuM6S.js +1 -0
  51. package/dist/banner-9u45RL26.js +1 -0
  52. package/dist/bonjour-discovery-CFZXPega.js +1 -0
  53. package/dist/bonjour-discovery-CjivQOxi.js +1 -0
  54. package/dist/boolean-Ch3DfXPy.js +1 -0
  55. package/dist/boolean-D15s2V33.js +1 -0
  56. package/dist/boolean-DypnRoRK.js +1 -0
  57. package/dist/brew-COcDl8CB.js +1 -0
  58. package/dist/brew-DDPm_HfE.js +1 -0
  59. package/dist/browser-cli-DQHE2iPY.js +1 -0
  60. package/dist/browser-cli-Dt0ds-an.js +1 -0
  61. package/dist/build-info.json +3 -3
  62. package/dist/bundled/boot-md/handler.js +1 -0
  63. package/dist/bundled/bootstrap-extra-files/handler.js +1 -0
  64. package/dist/bundled/command-logger/handler.js +1 -0
  65. package/dist/bundled/session-memory/handler.js +1 -0
  66. package/dist/call-B8Fb4_oh.js +1 -0
  67. package/dist/call-CqoMqP5b.js +1 -0
  68. package/dist/canvas-host/a2ui/.bundle.hash +1 -1
  69. package/dist/canvas-host/a2ui/a2ui.bundle.js +1705 -2
  70. package/dist/channel-account-context-BMPAMZEv.js +1 -0
  71. package/dist/channel-account-context-DAcarnqW.js +1 -0
  72. package/dist/channel-activity-B04WbrrK.js +1 -0
  73. package/dist/channel-activity-BBrgoad1.js +1 -0
  74. package/dist/channel-activity-CgbOWaay.js +1 -0
  75. package/dist/channel-activity-YIMhOAUo.js +1 -0
  76. package/dist/channel-activity-YjYNzCpJ.js +1 -0
  77. package/dist/channel-options-CEIzjOno.js +1 -0
  78. package/dist/channel-options-D2syI791.js +1 -0
  79. package/dist/channel-selection-BBeE1TmB.js +1 -0
  80. package/dist/channel-selection-CbNtbAEf.js +1 -0
  81. package/dist/channel-web-BrElpZAc.js +1 -0
  82. package/dist/channel-web-CxHbET4B.js +1 -0
  83. package/dist/channels/plugins/actions/discord.js +1 -0
  84. package/dist/channels/plugins/actions/signal.js +1 -0
  85. package/dist/channels/plugins/actions/telegram.js +1 -0
  86. package/dist/channels/plugins/agent-tools/whatsapp-login.js +1 -0
  87. package/dist/channels-cli-BmAJuuRs.js +1 -0
  88. package/dist/channels-cli-Dgosczr6.js +1 -0
  89. package/dist/channels-status-issues-8eFrGKyf.js +1 -0
  90. package/dist/channels-status-issues-PRgOT90w.js +1 -0
  91. package/dist/chat-envelope-Bznn2SoS.js +1 -0
  92. package/dist/chat-envelope-HVpKusFc.js +1 -0
  93. package/dist/clack-prompter-DBPdGdqp.js +1 -0
  94. package/dist/clack-prompter-Dq0aY6iM.js +1 -0
  95. package/dist/clawbot-cli-CgS7TkEx.js +1 -0
  96. package/dist/clawbot-cli-DZ2K0OTk.js +1 -0
  97. package/dist/cleanup-utils-BWm70DoD.js +1 -0
  98. package/dist/cleanup-utils-D-RhEX6F.js +1 -0
  99. package/dist/cli-BcnoCo4z.js +1 -0
  100. package/dist/cli-D8T2tphD.js +1 -0
  101. package/dist/cli-utils-BY7dLMFy.js +1 -0
  102. package/dist/cli-utils-BleB1eys.js +1 -0
  103. package/dist/clipboard-Bk8cviBt.js +1 -0
  104. package/dist/clipboard-CKT_VIkG.js +1 -0
  105. package/dist/cmd-argv-BBT5l8AV.js +1 -0
  106. package/dist/cmd-argv-Bh-KpaZ0.js +1 -0
  107. package/dist/command-format-BbDT1tlm.js +1 -0
  108. package/dist/command-format-CLxIPuLR.js +1 -0
  109. package/dist/command-options-BpOUDl2S.js +1 -0
  110. package/dist/command-options-Bq5nQxz6.js +1 -0
  111. package/dist/command-poll-backoff-BZLHYB2k.js +1 -0
  112. package/dist/command-poll-backoff-Cww_r-24.js +1 -0
  113. package/dist/command-poll-backoff-Df6cOQrX.js +1 -0
  114. package/dist/command-poll-backoff-endAPdwn.js +1 -0
  115. package/dist/command-registry-CfuXCRwV.js +1 -0
  116. package/dist/command-secret-targets-BVN3kiT9.js +1 -0
  117. package/dist/command-secret-targets-BlN-J_fA.js +1 -0
  118. package/dist/commands-CGpM84iR.js +1 -0
  119. package/dist/commands-Dy7duWlt.js +1 -0
  120. package/dist/commands-registry-B1x54ukc.js +1 -0
  121. package/dist/commands-registry-Cpl4QnG4.js +1 -0
  122. package/dist/commands-registry-D40KqYOm.js +1 -0
  123. package/dist/commands-registry-SeddSmFK.js +1 -0
  124. package/dist/compact-Dg66DXx_.js +1 -0
  125. package/dist/completion-cli-BZi4nuQb.js +1 -0
  126. package/dist/completion-cli-C40TWdsv.js +1 -0
  127. package/dist/config-BqW5S1xL.js +1 -0
  128. package/dist/config-D12ZLKqh.js +1 -0
  129. package/dist/config-cli-1ojSLwAj.js +1 -0
  130. package/dist/config-cli-CBte2b1h.js +1 -0
  131. package/dist/config-guard-BTNXbWoO.js +1 -0
  132. package/dist/config-guard-sYYx9zEF.js +1 -0
  133. package/dist/config-validation-C1La_IZU.js +1 -0
  134. package/dist/config-validation-DviYxW8Y.js +1 -0
  135. package/dist/configure-DJrNDEpR.js +1 -0
  136. package/dist/configure-kod4tmZa.js +1 -0
  137. package/dist/connection-auth-B_Uk6Vk8.js +1 -0
  138. package/dist/connection-auth-C8iru0UB.js +1 -0
  139. package/dist/context-window-guard-7crlatf9.js +1 -0
  140. package/dist/context-window-guard-CPChk363.js +1 -0
  141. package/dist/control-ui-assets-BIa0GGDg.js +1 -0
  142. package/dist/control-ui-assets-CTHGGgaX.js +1 -0
  143. package/dist/cron-cli-Dha16Lo-.js +1 -0
  144. package/dist/cron-cli-QHS2pKZ_.js +1 -0
  145. package/dist/daemon-cli-BuXTzSnU.js +1 -0
  146. package/dist/daemon-cli-DOTKuS7d.js +1 -0
  147. package/dist/daemon-cli.js +1 -0
  148. package/dist/daemon-install-C30rBssi.js +1 -0
  149. package/dist/daemon-install-HrqlOCrc.js +1 -0
  150. package/dist/daemon-install-plan.shared-CfA37Ut_.js +1 -0
  151. package/dist/daemon-install-plan.shared-Dx3DBXCG.js +1 -0
  152. package/dist/daemon-runtime-DHiDbRuC.js +1 -0
  153. package/dist/daemon-runtime-VcpeBRJV.js +1 -0
  154. package/dist/dangerous-name-matching-BOmvAibz.js +1 -0
  155. package/dist/dangerous-name-matching-DtllRqBD.js +1 -0
  156. package/dist/dangerous-tools-CFRYQJ6V.js +1 -0
  157. package/dist/dangerous-tools-oYCu5wfC.js +1 -0
  158. package/dist/deliver-56mQkDw3.js +1 -0
  159. package/dist/deliver-BFQ4Zx9z.js +1 -0
  160. package/dist/deliver-BHuhHfkH.js +1 -0
  161. package/dist/deliver-ClBkV2eD.js +1 -0
  162. package/dist/delivery-queue-CKbauSFq.js +1 -0
  163. package/dist/delivery-queue-nkPJu0fY.js +1 -0
  164. package/dist/device-pairing-CTFpaTrD.js +1 -0
  165. package/dist/device-pairing-QTK0dod3.js +1 -0
  166. package/dist/devices-cli-Ckxd0k0I.js +1 -0
  167. package/dist/devices-cli-Db36mBHq.js +1 -0
  168. package/dist/diagnostic-BrE4lMIf.js +1 -0
  169. package/dist/diagnostic-CDxNevIQ.js +1 -0
  170. package/dist/diagnostic-DOzHPnht.js +1 -0
  171. package/dist/diagnostic-DQq4Bwrs.js +1 -0
  172. package/dist/diagnostics-BgbeL9KE.js +1 -0
  173. package/dist/diagnostics-Cdctg9K_.js +1 -0
  174. package/dist/directory-cli-DDTaUkjW.js +1 -0
  175. package/dist/directory-cli-_gTFSHMW.js +1 -0
  176. package/dist/dns-cli--4PwtR2Y.js +1 -0
  177. package/dist/dns-cli-C4DwKquN.js +1 -0
  178. package/dist/docs-cli-Cdw9Iz9a.js +1 -0
  179. package/dist/docs-cli-ClD2UyX1.js +1 -0
  180. package/dist/doctor-completion-BJ6steqx.js +1 -0
  181. package/dist/doctor-completion-DMJhfrtC.js +1 -0
  182. package/dist/doctor-config-flow-D4F3mz4h.js +1 -0
  183. package/dist/doctor-config-flow-DnOyVZhQ.js +1 -0
  184. package/dist/enable-BhD84GhD.js +1 -0
  185. package/dist/enable-Ccf9wSM8.js +1 -0
  186. package/dist/entry-status-CCwwKO43.js +1 -0
  187. package/dist/entry-status-CoXkbJcX.js +1 -0
  188. package/dist/entry.js +1 -0
  189. package/dist/env-D7wNuBx1.js +1 -0
  190. package/dist/env-overrides-DHtB4kK3.js +1 -0
  191. package/dist/env-overrides-DXJbFrwI.js +1 -0
  192. package/dist/errors-6SQWM9dj.js +1 -0
  193. package/dist/errors-Bunti32V.js +1 -0
  194. package/dist/exec-B3eleY5O.js +1 -0
  195. package/dist/exec-DHqLtFYt.js +1 -0
  196. package/dist/exec-approvals-BXO9Cezj.js +1 -0
  197. package/dist/exec-approvals-BpBNEy6i.js +1 -0
  198. package/dist/exec-approvals-allowlist-CE3nYh0K.js +1 -0
  199. package/dist/exec-approvals-allowlist-D8mN7nxV.js +1 -0
  200. package/dist/exec-approvals-cli-CUcuN63y.js +1 -0
  201. package/dist/exec-approvals-cli-CxUGD08t.js +1 -0
  202. package/dist/exec-safe-bin-runtime-policy-Dt0GchLp.js +1 -0
  203. package/dist/exec-safe-bin-runtime-policy-dcCS_Adf.js +1 -0
  204. package/dist/fetch-B9tORjG8.js +1 -0
  205. package/dist/fetch-BJT3BrkJ.js +1 -0
  206. package/dist/fetch-B_wRifvZ.js +1 -0
  207. package/dist/fetch-Bn0mWg6a.js +1 -0
  208. package/dist/fetch-CQaNr5J1.js +1 -0
  209. package/dist/fetch-Ce-scEU-.js +1 -0
  210. package/dist/fetch-D0rZDHKO.js +1 -0
  211. package/dist/fetch-DHo17YmK.js +1 -0
  212. package/dist/fetch-Dh-apy46.js +1 -0
  213. package/dist/fetch-Dikjvc5M.js +1 -0
  214. package/dist/fetch-DsjPfQlp.js +1 -0
  215. package/dist/fetch-_g8lZ8K8.js +1 -0
  216. package/dist/fetch-guard-BrTtJw7h.js +1 -0
  217. package/dist/fetch-guard-D10s0raB.js +1 -0
  218. package/dist/fetch-guard-DPdY0NXR.js +1 -0
  219. package/dist/fetch-guard-cu7DGSRF.js +1 -0
  220. package/dist/fetch-hy0JKSsm.js +1 -0
  221. package/dist/fetch-timeout-CdYxWG9w.js +1 -0
  222. package/dist/fetch-timeout-Cj8_oAls.js +1 -0
  223. package/dist/fetch-timeout-DoOI_izT.js +1 -0
  224. package/dist/fetch-timeout-u8g99Ax0.js +1 -0
  225. package/dist/format-Bn1bwJKX.js +1 -0
  226. package/dist/format-Ce7I7s-k.js +1 -0
  227. package/dist/format-duration-C8AzNqKh.js +1 -0
  228. package/dist/format-duration-D5AMtmHa.js +1 -0
  229. package/dist/format-relative-B9pSIdGe.js +1 -0
  230. package/dist/format-relative-DkMjYy7z.js +1 -0
  231. package/dist/frontmatter-BkZkwkVO.js +1 -0
  232. package/dist/frontmatter-C7mzDNxd.js +1 -0
  233. package/dist/frontmatter-CzpfPBFl.js +1 -0
  234. package/dist/gateway-cli-CKu0FA7D.js +1 -0
  235. package/dist/gateway-cli-C_s9eMlC.js +1 -0
  236. package/dist/gateway-install-token-BCnuZeh1.js +1 -0
  237. package/dist/gateway-install-token-DiDvDPJQ.js +1 -0
  238. package/dist/gateway-rpc-iFvDyHYd.js +1 -0
  239. package/dist/gateway-rpc-tEEvY0kH.js +1 -0
  240. package/dist/github-copilot-token-C79yeDKS.js +1 -0
  241. package/dist/github-copilot-token-DGYAlOmV.js +1 -0
  242. package/dist/github-copilot-token-DePP-lIf.js +1 -0
  243. package/dist/github-copilot-token-wm6mbypz.js +1 -0
  244. package/dist/gmail-setup-utils-CYOH3zzx.js +1 -0
  245. package/dist/gmail-setup-utils-S-MyEGuj.js +1 -0
  246. package/dist/group-access-BHKVOhrj.js +1 -0
  247. package/dist/group-access-D2DOYMfr.js +1 -0
  248. package/dist/health-BgOggK9k.js +1 -0
  249. package/dist/health-PaRHFItm.js +1 -0
  250. package/dist/health-format-B1nj3Wfn.js +1 -0
  251. package/dist/health-format-VBr6LEpt.js +1 -0
  252. package/dist/heartbeat-visibility-BQ_esv2m.js +1 -0
  253. package/dist/heartbeat-visibility-q74UdY8O.js +1 -0
  254. package/dist/help-format-B4aEI7V9.js +1 -0
  255. package/dist/help-format-BRbF_INg.js +1 -0
  256. package/dist/helpers-COz1ghcB.js +1 -0
  257. package/dist/helpers-Cp8gcO6u.js +1 -0
  258. package/dist/hooks-cli-BzyzTNBx.js +1 -0
  259. package/dist/hooks-cli-CsBrScq0.js +1 -0
  260. package/dist/hooks-status-BHt-Xvh4.js +1 -0
  261. package/dist/hooks-status-CRJ4J0ZW.js +1 -0
  262. package/dist/image-BkWwI54C.js +1 -0
  263. package/dist/image-CcVQg-YN.js +1 -0
  264. package/dist/image-Cm1RUBqD.js +1 -0
  265. package/dist/image-DsoO5VP5.js +1 -0
  266. package/dist/index.js +1 -0
  267. package/dist/inspect-BKV-I1UE.js +1 -0
  268. package/dist/inspect-z59cgmYc.js +1 -0
  269. package/dist/install-safe-path-C6kc_8NW.js +1 -0
  270. package/dist/install-safe-path-iesxijn2.js +1 -0
  271. package/dist/installs-BNeI_oML.js +1 -0
  272. package/dist/installs-C1xQLuby.js +1 -0
  273. package/dist/ipv4-BOuNtoGn.js +1 -0
  274. package/dist/ipv4-CWdaEiVH.js +1 -0
  275. package/dist/ir-BF0M2kGp.js +1 -0
  276. package/dist/ir-D8Hh84ab.js +1 -0
  277. package/dist/ir-DBWscfBd.js +1 -0
  278. package/dist/ir-Dk7OQ4bA.js +1 -0
  279. package/dist/is-main-DG5ueqhF.js +1 -0
  280. package/dist/issue-format-BT7cQEt3.js +1 -0
  281. package/dist/issue-format-C_lNzrKa.js +1 -0
  282. package/dist/kill-tree-B3g7HrAO.js +1 -0
  283. package/dist/lifecycle-core-D9KNCvxY.js +1 -0
  284. package/dist/lifecycle-core-LM5UUUB1.js +1 -0
  285. package/dist/line/accounts.js +1 -0
  286. package/dist/line/send.js +1 -0
  287. package/dist/line/template-messages.js +1 -0
  288. package/dist/links-CBnmRP9D.js +1 -0
  289. package/dist/links-CySwdMcF.js +1 -0
  290. package/dist/llm-slug-generator.js +1 -0
  291. package/dist/load-options-BsOW74dp.js +1 -0
  292. package/dist/load-options-C7dLuybp.js +1 -0
  293. package/dist/load-options-DV4j6Aqb.js +1 -0
  294. package/dist/load-options-Dwt0CeEg.js +1 -0
  295. package/dist/local-roots-6waH0SZ0.js +1 -0
  296. package/dist/logger-5W0OocJW.js +1 -0
  297. package/dist/logger-Bl8URnrW.js +1 -0
  298. package/dist/logger-DwWqfo66.js +1 -0
  299. package/dist/logger-kQAOe3qp.js +1 -0
  300. package/dist/logging-Dqe9dxSX.js +1 -0
  301. package/dist/logging-tYw1NbJd.js +1 -0
  302. package/dist/login-BOlqRyr0.js +1 -0
  303. package/dist/login-CkWesqf_.js +1 -0
  304. package/dist/login-Do_NA1Je.js +1 -0
  305. package/dist/login-op9S8yqv.js +1 -0
  306. package/dist/login-qr-B6rxvoTS.js +1 -0
  307. package/dist/login-qr-BGH9zmhw.js +1 -0
  308. package/dist/login-qr-CiENvgog.js +1 -0
  309. package/dist/login-qr-DsV-lxFd.js +1 -0
  310. package/dist/login-qr-QcDMg23y.js +1 -0
  311. package/dist/logs-cli-B4eUg_87.js +1 -0
  312. package/dist/logs-cli-BA3Aso8a.js +1 -0
  313. package/dist/manager-4Y9fRgdw.js +1 -0
  314. package/dist/manager-C2YW7Hkq.js +1 -0
  315. package/dist/manager-Dtd_loL8.js +1 -0
  316. package/dist/manager-M1GKhLUC.js +1 -0
  317. package/dist/memory-cli-XaxtBQm1.js +1 -0
  318. package/dist/memory-cli-jhzJ3as7.js +1 -0
  319. package/dist/model-catalog-C1kpjR75.js +1 -0
  320. package/dist/model-catalog-COVzoZD9.js +1 -0
  321. package/dist/model-param-b-B0r2cPDw.js +1 -0
  322. package/dist/model-param-b-BqIr5rY5.js +1 -0
  323. package/dist/model-picker-D3ZSpr0i.js +1 -0
  324. package/dist/model-picker-bZNuI66U.js +1 -0
  325. package/dist/model-selection-B5JsBS9D.js +1 -0
  326. package/dist/model-selection-BlC_rXAN.js +1 -0
  327. package/dist/model-selection-vfhBuN9O.js +1 -0
  328. package/dist/models-C_Vg3Cty.js +1 -0
  329. package/dist/models-cli-CDZliTXq.js +1 -0
  330. package/dist/models-cli-bGr8jwAb.js +1 -0
  331. package/dist/models-config-CdMhNxKV.js +1 -0
  332. package/dist/models-config-_htt7eY5.js +1 -0
  333. package/dist/mutable-allowlist-detectors-C4rNVag8.js +1 -0
  334. package/dist/mutable-allowlist-detectors-CL0qe54J.js +1 -0
  335. package/dist/node-cli-5lYbDZ70.js +1 -0
  336. package/dist/node-cli-Br04Qmqo.js +1 -0
  337. package/dist/node-command-policy-CejeQemH.js +1 -0
  338. package/dist/node-command-policy-CqXhdnHh.js +1 -0
  339. package/dist/node-commands-8GBOiktk.js +1 -0
  340. package/dist/node-commands-DdkziOTx.js +1 -0
  341. package/dist/node-resolve-B3BJbmQX.js +1 -0
  342. package/dist/node-resolve-DLZf3-1V.js +1 -0
  343. package/dist/node-service-BRfrNp8l.js +1 -0
  344. package/dist/node-service-C0bl7jcZ.js +1 -0
  345. package/dist/node-shell-DyOfwHrh.js +1 -0
  346. package/dist/nodes-cli-8By8--bW.js +1 -0
  347. package/dist/nodes-cli-zq41EwJN.js +1 -0
  348. package/dist/nodes-screen-DECgxo6A.js +1 -0
  349. package/dist/note-D4GAwgha.js +1 -0
  350. package/dist/note-Dp-d_utk.js +1 -0
  351. package/dist/npm-pack-install-B23L-AtF.js +1 -0
  352. package/dist/npm-pack-install-C0te3Oap.js +1 -0
  353. package/dist/npm-resolution-BnJGLwhi.js +1 -0
  354. package/dist/npm-resolution-DWPloph4.js +1 -0
  355. package/dist/oauth-env-DAamJ1oz.js +1 -0
  356. package/dist/oauth-env-DSLBTWb1.js +1 -0
  357. package/dist/oauth-tls-preflight-BSBRDIfC.js +1 -0
  358. package/dist/oauth-tls-preflight-ByNjbUR5.js +1 -0
  359. package/dist/ollama-setup-BMEKWyIE.js +1 -0
  360. package/dist/ollama-setup-DlwS6Gl-.js +1 -0
  361. package/dist/onboard-B0BNCQaO.js +1 -0
  362. package/dist/onboard-CjVhdaiR.js +1 -0
  363. package/dist/onboard-channels-BMIOddLN.js +1 -0
  364. package/dist/onboard-channels-CZK_7xMR.js +1 -0
  365. package/dist/onboard-config-B7U20YRw.js +1 -0
  366. package/dist/onboard-config-DS9dUv8M.js +1 -0
  367. package/dist/onboard-custom-B03SlEHB.js +1 -0
  368. package/dist/onboard-custom-Bl0y8c-g.js +1 -0
  369. package/dist/onboard-helpers-PGl5bVPE.js +1 -0
  370. package/dist/onboard-helpers-zwybUJWu.js +1 -0
  371. package/dist/onboard-hooks-CERzXObm.js +1 -0
  372. package/dist/onboard-hooks-gQ3sxBNi.js +1 -0
  373. package/dist/onboard-provider-auth-flags-CqbipO7D.js +1 -0
  374. package/dist/onboard-provider-auth-flags-Dvwzdz37.js +1 -0
  375. package/dist/onboard-remote-BOpIRdDu.js +1 -0
  376. package/dist/onboard-remote-DPU-H_2O.js +1 -0
  377. package/dist/onboard-search-f2tJD4hg.js +1 -0
  378. package/dist/onboard-search-fslKKhyg.js +1 -0
  379. package/dist/onboard-skills-BMAJs6ly.js +1 -0
  380. package/dist/onboard-skills-CMSQc2Mm.js +1 -0
  381. package/dist/onboarding-B6ixWwgp.js +1 -0
  382. package/dist/onboarding-ouEqUuUr.js +1 -0
  383. package/dist/onboarding.finalize-Bgat5Npc.js +1 -0
  384. package/dist/onboarding.finalize-DsMVlTcH.js +1 -0
  385. package/dist/onboarding.gateway-config-BtLDJWJ2.js +1 -0
  386. package/dist/onboarding.gateway-config-y3pqsL9i.js +1 -0
  387. package/dist/onboarding.secret-input-BsBgh8Tc.js +1 -0
  388. package/dist/onboarding.secret-input-kO5OzYC7.js +1 -0
  389. package/dist/openai-codex-model-default-DuE2_wN7.js +1 -0
  390. package/dist/openai-codex-model-default-yVfRw-Mm.js +1 -0
  391. package/dist/openai-model-default-Bl8MHPb6.js +1 -0
  392. package/dist/openai-model-default-DJObMvLJ.js +1 -0
  393. package/dist/openclaw-exec-env-BWbOu_YC.js +1 -0
  394. package/dist/openclaw-root-CnsBf6ZU.js +1 -0
  395. package/dist/openclaw-root-D_0Q6--h.js +1 -0
  396. package/dist/outbound-BOSIEiEY.js +1 -0
  397. package/dist/outbound-BtUeDLjU.js +1 -0
  398. package/dist/outbound-Bx2Z2aYK.js +1 -0
  399. package/dist/outbound-Bz8bbrMI.js +1 -0
  400. package/dist/outbound-attachment-B7wMxwj6.js +1 -0
  401. package/dist/outbound-attachment-BgAe99RM.js +1 -0
  402. package/dist/outbound-attachment-Dds8xirj.js +1 -0
  403. package/dist/outbound-attachment-DqEKghQp.js +1 -0
  404. package/dist/pairing-cli-Bya9M-I_.js +1 -0
  405. package/dist/pairing-cli-D2JEhufv.js +1 -0
  406. package/dist/pairing-labels-BUU_-70B.js +1 -0
  407. package/dist/pairing-labels-D-kzQEL2.js +1 -0
  408. package/dist/pairing-store-BH-FTYkn.js +1 -0
  409. package/dist/pairing-store-Cg2UxreQ.js +1 -0
  410. package/dist/pairing-token-BjYBuREl.js +1 -0
  411. package/dist/pairing-token-DAR7V7FJ.js +1 -0
  412. package/dist/parse-duration-XTjMKl8s.js +1 -0
  413. package/dist/parse-finite-number-DqzUM-_s.js +1 -0
  414. package/dist/parse-finite-number-dBmDLLKL.js +1 -0
  415. package/dist/parse-log-line-CsYLg7Qu.js +1 -0
  416. package/dist/parse-log-line-NV-cipB_.js +1 -0
  417. package/dist/parse-port-Bv1Y9Wk5.js +1 -0
  418. package/dist/parse-port-JVwkxcZ8.js +1 -0
  419. package/dist/parse-timeout-DWSGfCkQ.js +1 -0
  420. package/dist/parse-timeout-Dx4QnVzo.js +1 -0
  421. package/dist/path-alias-guards-kY_ZbWs-.js +1 -0
  422. package/dist/path-alias-guards-mvyLCPlN.js +1 -0
  423. package/dist/path-env-BPd1Yd-i.js +1 -0
  424. package/dist/path-env-emdAQejM.js +1 -0
  425. package/dist/path-safety-BukYK8Kd.js +1 -0
  426. package/dist/path-safety-DaaMJFdt.js +1 -0
  427. package/dist/paths-B4IRk3wi.js +1 -0
  428. package/dist/paths-BfjJY2VL.js +1 -0
  429. package/dist/paths-BjD3T_xq.js +1 -0
  430. package/dist/paths-BpQOWYiT.js +1 -0
  431. package/dist/paths-CChBdtE8.js +1 -0
  432. package/dist/paths-CrCoPIVK.js +1 -0
  433. package/dist/paths-piJASC5k.js +1 -0
  434. package/dist/paths-yLEk_25I.js +1 -0
  435. package/dist/pi-embedded-BZSn84Bh.js +1 -0
  436. package/dist/pi-embedded-Dsz7p3MF.js +1 -0
  437. package/dist/pi-model-discovery-BbD1YJNx.js +1 -0
  438. package/dist/pi-model-discovery-CpjYoBQf.js +1 -0
  439. package/dist/pi-model-discovery-DeQdHV8O.js +1 -0
  440. package/dist/pi-model-discovery-Dps1PPWz.js +1 -0
  441. package/dist/pi-tools.before-tool-call.runtime-DseAq0gm.js +1 -0
  442. package/dist/pi-tools.before-tool-call.runtime-KKGILAuK.js +1 -0
  443. package/dist/pi-tools.before-tool-call.runtime-Pck2WdIO.js +1 -0
  444. package/dist/pi-tools.before-tool-call.runtime-ZzMJQ1BP.js +1 -0
  445. package/dist/pi-tools.policy-D40r0HmD.js +1 -0
  446. package/dist/plugin-auto-enable-DpVL6-ES.js +1 -0
  447. package/dist/plugin-auto-enable-NzmNh4oU.js +1 -0
  448. package/dist/plugin-install-plan-BobX0y9S.js +1 -0
  449. package/dist/plugin-install-plan-NvDGp0d8.js +1 -0
  450. package/dist/plugin-registry-C6dY-Et7.js +1 -0
  451. package/dist/plugin-registry-CIBiHZH1.js +1 -0
  452. package/dist/plugin-sdk/account-id.cjs +1 -0
  453. package/dist/plugin-sdk/account-id.js +1 -0
  454. package/dist/plugin-sdk/acpx.cjs +1 -0
  455. package/dist/plugin-sdk/acpx.js +1 -0
  456. package/dist/plugin-sdk/active-listener-BApFQlQn.js +1 -0
  457. package/dist/plugin-sdk/active-listener-BETopzG5.cjs +1 -0
  458. package/dist/plugin-sdk/active-listener-BEcmvyxh.cjs +1 -0
  459. package/dist/plugin-sdk/active-listener-BZPPbsNy.cjs +1 -0
  460. package/dist/plugin-sdk/active-listener-B_Mxemq7.cjs +1 -0
  461. package/dist/plugin-sdk/active-listener-BgW_qfd3.js +1 -0
  462. package/dist/plugin-sdk/active-listener-Coet66pF.cjs +1 -0
  463. package/dist/plugin-sdk/active-listener-CvML9qVF.js +1 -0
  464. package/dist/plugin-sdk/active-listener-DuO6KMXJ.js +1 -0
  465. package/dist/plugin-sdk/active-listener-DymzfmOG.cjs +1 -0
  466. package/dist/plugin-sdk/active-listener-ILBdBHMv.js +1 -0
  467. package/dist/plugin-sdk/active-listener-gRRIfN1q.js +1 -0
  468. package/dist/plugin-sdk/api-key-rotation-Bj1A9Slo.cjs +1 -0
  469. package/dist/plugin-sdk/api-key-rotation-CFPNzksf.cjs +1 -0
  470. package/dist/plugin-sdk/api-key-rotation-CXY0AyM1.js +1 -0
  471. package/dist/plugin-sdk/api-key-rotation-ClIwV8yq.js +1 -0
  472. package/dist/plugin-sdk/api-key-rotation-D5Nr1xl3.js +1 -0
  473. package/dist/plugin-sdk/api-key-rotation-DDCwA0KM.cjs +1 -0
  474. package/dist/plugin-sdk/api-key-rotation-DHMvXm70.cjs +1 -0
  475. package/dist/plugin-sdk/api-key-rotation-DaFFZfk5.js +1 -0
  476. package/dist/plugin-sdk/api-key-rotation-DcREl_0x.js +1 -0
  477. package/dist/plugin-sdk/api-key-rotation-X-5Fb7av.cjs +1 -0
  478. package/dist/plugin-sdk/api-key-rotation-_VfXYfHS.js +1 -0
  479. package/dist/plugin-sdk/api-key-rotation-wFUVOOfM.cjs +1 -0
  480. package/dist/plugin-sdk/audio-preflight-B1MP5_bc.cjs +1 -0
  481. package/dist/plugin-sdk/audio-preflight-BETx142T.cjs +1 -0
  482. package/dist/plugin-sdk/audio-preflight-BGRLhCLc.cjs +1 -0
  483. package/dist/plugin-sdk/audio-preflight-BNICfOY5.cjs +1 -0
  484. package/dist/plugin-sdk/audio-preflight-BV3Cav8M.js +1 -0
  485. package/dist/plugin-sdk/audio-preflight-BmO72Cqr.cjs +1 -0
  486. package/dist/plugin-sdk/audio-preflight-BpE8wFQc.js +1 -0
  487. package/dist/plugin-sdk/audio-preflight-CTAafaiH.js +1 -0
  488. package/dist/plugin-sdk/audio-preflight-D82aewIt.js +1 -0
  489. package/dist/plugin-sdk/audio-preflight-DmzxEaq3.cjs +1 -0
  490. package/dist/plugin-sdk/audio-preflight-DrSIYRnD.js +1 -0
  491. package/dist/plugin-sdk/audio-preflight-SZZoA2Ff.js +1 -0
  492. package/dist/plugin-sdk/audio-transcription-runner-B54MyF1_.js +1 -0
  493. package/dist/plugin-sdk/audio-transcription-runner-BIqM5H5q.js +1 -0
  494. package/dist/plugin-sdk/audio-transcription-runner-BLAxZL-U.js +1 -0
  495. package/dist/plugin-sdk/audio-transcription-runner-BVmaaA2k.js +1 -0
  496. package/dist/plugin-sdk/audio-transcription-runner-BdY-TMcc.js +1 -0
  497. package/dist/plugin-sdk/audio-transcription-runner-By3lSLub.cjs +1 -0
  498. package/dist/plugin-sdk/audio-transcription-runner-CH5CoZrF.cjs +1 -0
  499. package/dist/plugin-sdk/audio-transcription-runner-CMsp7bhn.cjs +1 -0
  500. package/dist/plugin-sdk/audio-transcription-runner-ClGibmMi.cjs +1 -0
  501. package/dist/plugin-sdk/audio-transcription-runner-QfEC19vE.cjs +1 -0
  502. package/dist/plugin-sdk/audio-transcription-runner-g7L0m-Z5.cjs +1 -0
  503. package/dist/plugin-sdk/audio-transcription-runner-pVTD93vq.js +1 -0
  504. package/dist/plugin-sdk/audit-membership-runtime-7LqcvqFo.js +1 -0
  505. package/dist/plugin-sdk/audit-membership-runtime-BQFUzFc0.cjs +1 -0
  506. package/dist/plugin-sdk/audit-membership-runtime-BYtdDX9G.cjs +1 -0
  507. package/dist/plugin-sdk/audit-membership-runtime-BzEtBUX6.cjs +1 -0
  508. package/dist/plugin-sdk/audit-membership-runtime-CBUmGrl4.js +1 -0
  509. package/dist/plugin-sdk/audit-membership-runtime-ChlVgt2y.js +1 -0
  510. package/dist/plugin-sdk/audit-membership-runtime-DLRX7LR0.js +1 -0
  511. package/dist/plugin-sdk/audit-membership-runtime-DbJW5X3L.cjs +1 -0
  512. package/dist/plugin-sdk/audit-membership-runtime-Du9LAxDa.cjs +1 -0
  513. package/dist/plugin-sdk/audit-membership-runtime-DylNnj1m.js +1 -0
  514. package/dist/plugin-sdk/audit-membership-runtime-voi5sPwF.js +1 -0
  515. package/dist/plugin-sdk/audit-membership-runtime-yWYvSpgZ.cjs +1 -0
  516. package/dist/plugin-sdk/bluebubbles.cjs +1 -0
  517. package/dist/plugin-sdk/bluebubbles.js +1 -0
  518. package/dist/plugin-sdk/channel-activity-BGK-Bj2_.cjs +1 -0
  519. package/dist/plugin-sdk/channel-activity-BRHvpV0C.js +1 -0
  520. package/dist/plugin-sdk/channel-activity-CKfWFchu.js +1 -0
  521. package/dist/plugin-sdk/channel-activity-CLUi31fX.cjs +1 -0
  522. package/dist/plugin-sdk/channel-activity-CVOp-PL4.cjs +1 -0
  523. package/dist/plugin-sdk/channel-activity-CgXnZ0GC.cjs +1 -0
  524. package/dist/plugin-sdk/channel-activity-CmYpOPAn.js +1 -0
  525. package/dist/plugin-sdk/channel-activity-CwaMf9qT.cjs +1 -0
  526. package/dist/plugin-sdk/channel-activity-D5D5tBWf.cjs +1 -0
  527. package/dist/plugin-sdk/channel-activity-D7tpmatp.js +1 -0
  528. package/dist/plugin-sdk/channel-activity-DpxSOlXF.js +1 -0
  529. package/dist/plugin-sdk/channel-activity-spvDzlTl.js +1 -0
  530. package/dist/plugin-sdk/channel-web-4ZQVqsrt.js +1 -0
  531. package/dist/plugin-sdk/channel-web-9zn1Itpg.cjs +1 -0
  532. package/dist/plugin-sdk/channel-web-BrB00HKH.js +1 -0
  533. package/dist/plugin-sdk/channel-web-DN5La-Ol.cjs +1 -0
  534. package/dist/plugin-sdk/command-poll-backoff-4910Mpwp.js +1 -0
  535. package/dist/plugin-sdk/command-poll-backoff-BLJZzV5W.cjs +1 -0
  536. package/dist/plugin-sdk/command-poll-backoff-CUNcN0dv.cjs +1 -0
  537. package/dist/plugin-sdk/command-poll-backoff-Cww_r-24.js +1 -0
  538. package/dist/plugin-sdk/command-poll-backoff-D0lJhquZ.js +1 -0
  539. package/dist/plugin-sdk/command-poll-backoff-Glwt3wHa.cjs +1 -0
  540. package/dist/plugin-sdk/commands-registry-5lStNoKW.cjs +1 -0
  541. package/dist/plugin-sdk/commands-registry-C8wnXqNa.cjs +1 -0
  542. package/dist/plugin-sdk/commands-registry-Cnr6PvIw.js +1 -0
  543. package/dist/plugin-sdk/commands-registry-CtYCWfuM.cjs +1 -0
  544. package/dist/plugin-sdk/commands-registry-D2gv242l.js +1 -0
  545. package/dist/plugin-sdk/commands-registry-DI2vPscP.js +1 -0
  546. package/dist/plugin-sdk/commands-registry-DcBvmwSU.js +1 -0
  547. package/dist/plugin-sdk/commands-registry-DkUhCIDk.cjs +1 -0
  548. package/dist/plugin-sdk/commands-registry-DsMbmie-.cjs +1 -0
  549. package/dist/plugin-sdk/commands-registry-MCsWR5Vf.js +1 -0
  550. package/dist/plugin-sdk/commands-registry-SHZVq_qf.cjs +1 -0
  551. package/dist/plugin-sdk/commands-registry-kRjFifgj.js +1 -0
  552. package/dist/plugin-sdk/common-B4iFXuoZ.cjs +1 -0
  553. package/dist/plugin-sdk/common-B6fDMl_i.js +1 -0
  554. package/dist/plugin-sdk/compat.cjs +1 -0
  555. package/dist/plugin-sdk/compat.js +1 -0
  556. package/dist/plugin-sdk/config-ByA2hluR.js +1 -0
  557. package/dist/plugin-sdk/config-rBz8C_Hi.cjs +1 -0
  558. package/dist/plugin-sdk/copilot-proxy.cjs +1 -0
  559. package/dist/plugin-sdk/copilot-proxy.js +1 -0
  560. package/dist/plugin-sdk/core.cjs +1 -0
  561. package/dist/plugin-sdk/core.js +1 -0
  562. package/dist/plugin-sdk/deliver-B0fB4hAV.js +1 -0
  563. package/dist/plugin-sdk/deliver-BOLmjIJ3.js +1 -0
  564. package/dist/plugin-sdk/deliver-BrfVwkYz.cjs +1 -0
  565. package/dist/plugin-sdk/deliver-C-tChWTI.cjs +1 -0
  566. package/dist/plugin-sdk/deliver-CjQPkWS-.cjs +1 -0
  567. package/dist/plugin-sdk/deliver-D1P0FNTu.js +1 -0
  568. package/dist/plugin-sdk/deliver-DCrO9mvv.cjs +1 -0
  569. package/dist/plugin-sdk/deliver-DQLekoj2.cjs +1 -0
  570. package/dist/plugin-sdk/deliver-DkfCVM78.js +1 -0
  571. package/dist/plugin-sdk/deliver-Dkh3lqXR.js +1 -0
  572. package/dist/plugin-sdk/deliver-DsFtXFyr.cjs +1 -0
  573. package/dist/plugin-sdk/deliver-vYe_sYOL.js +1 -0
  574. package/dist/plugin-sdk/device-pair.cjs +1 -0
  575. package/dist/plugin-sdk/device-pair.js +1 -0
  576. package/dist/plugin-sdk/diagnostic-8iX73nz_.cjs +1 -0
  577. package/dist/plugin-sdk/diagnostic-CLUtpxAp.js +1 -0
  578. package/dist/plugin-sdk/diagnostic-CVS4k9hh.cjs +1 -0
  579. package/dist/plugin-sdk/diagnostic-CkePwN5F.js +1 -0
  580. package/dist/plugin-sdk/diagnostic-Cu1PGj0E.cjs +1 -0
  581. package/dist/plugin-sdk/diagnostic-D0oCfBju.cjs +1 -0
  582. package/dist/plugin-sdk/diagnostic-D7A9cQYf.cjs +1 -0
  583. package/dist/plugin-sdk/diagnostic-DGLX0zXU.js +1 -0
  584. package/dist/plugin-sdk/diagnostic-DXscFT8t.cjs +1 -0
  585. package/dist/plugin-sdk/diagnostic-Efe4b81B.js +1 -0
  586. package/dist/plugin-sdk/diagnostic-EqHqw9xo.js +1 -0
  587. package/dist/plugin-sdk/diagnostic-vsjHZ_fY.js +1 -0
  588. package/dist/plugin-sdk/diagnostics-otel.cjs +1 -0
  589. package/dist/plugin-sdk/diagnostics-otel.js +1 -0
  590. package/dist/plugin-sdk/diffs.cjs +1 -0
  591. package/dist/plugin-sdk/diffs.js +1 -0
  592. package/dist/plugin-sdk/discord.cjs +1 -0
  593. package/dist/plugin-sdk/discord.js +1 -0
  594. package/dist/plugin-sdk/dispatch-5v3v8zzA.js +1 -0
  595. package/dist/plugin-sdk/dispatch-B6UbZCpL.cjs +1 -0
  596. package/dist/plugin-sdk/dispatch-BYlcmJ9u.js +1 -0
  597. package/dist/plugin-sdk/dispatch-C2YTqGlf.js +1 -0
  598. package/dist/plugin-sdk/dispatch-CNy3g9ma.cjs +1 -0
  599. package/dist/plugin-sdk/dispatch-DCSwqteL.js +1 -0
  600. package/dist/plugin-sdk/dispatch-DHbSBeFJ.js +1 -0
  601. package/dist/plugin-sdk/dispatch-DK5ub8qa.cjs +1 -0
  602. package/dist/plugin-sdk/dispatch-SWyfAZT0.cjs +1 -0
  603. package/dist/plugin-sdk/dispatch-mR2vLkGa.cjs +1 -0
  604. package/dist/plugin-sdk/feishu.cjs +1 -0
  605. package/dist/plugin-sdk/feishu.js +1 -0
  606. package/dist/plugin-sdk/fetch-7Iq9POda.js +1 -0
  607. package/dist/plugin-sdk/fetch-B1GR6-u4.js +1 -0
  608. package/dist/plugin-sdk/fetch-B27H-XCf.js +1 -0
  609. package/dist/plugin-sdk/fetch-BMYDLRWo.js +1 -0
  610. package/dist/plugin-sdk/fetch-BN9y3kTg.cjs +1 -0
  611. package/dist/plugin-sdk/fetch-BVEVk5YF.js +1 -0
  612. package/dist/plugin-sdk/fetch-BY6lVRlY.cjs +1 -0
  613. package/dist/plugin-sdk/fetch-Bi8krAaT.cjs +1 -0
  614. package/dist/plugin-sdk/fetch-BjXhwqrE.cjs +1 -0
  615. package/dist/plugin-sdk/fetch-BtZY623f.js +1 -0
  616. package/dist/plugin-sdk/fetch-C-HRWp5R.js +1 -0
  617. package/dist/plugin-sdk/fetch-C3LEMysf.js +1 -0
  618. package/dist/plugin-sdk/fetch-CCLWsYaQ.js +1 -0
  619. package/dist/plugin-sdk/fetch-CZewCAvu.cjs +1 -0
  620. package/dist/plugin-sdk/fetch-ClKErpni.cjs +1 -0
  621. package/dist/plugin-sdk/fetch-DBRI0sKI.js +1 -0
  622. package/dist/plugin-sdk/fetch-DQxuOB8o.cjs +1 -0
  623. package/dist/plugin-sdk/fetch-DUMEaqum.cjs +1 -0
  624. package/dist/plugin-sdk/fetch-DpwR_cJU.cjs +1 -0
  625. package/dist/plugin-sdk/fetch-J0IzopiJ.js +1 -0
  626. package/dist/plugin-sdk/fetch-guard-8I7EHbDM.cjs +1 -0
  627. package/dist/plugin-sdk/fetch-guard-CIJUkBIL.cjs +1 -0
  628. package/dist/plugin-sdk/fetch-guard-CY03i4gu.js +1 -0
  629. package/dist/plugin-sdk/fetch-guard-Cz-cgYmR.cjs +1 -0
  630. package/dist/plugin-sdk/fetch-guard-DB85MORy.cjs +1 -0
  631. package/dist/plugin-sdk/fetch-guard-DE9BslxX.js +1 -0
  632. package/dist/plugin-sdk/fetch-guard-DLNzldn9.cjs +1 -0
  633. package/dist/plugin-sdk/fetch-guard-DSvAbvSx.js +1 -0
  634. package/dist/plugin-sdk/fetch-guard-DXe8oqEE.js +1 -0
  635. package/dist/plugin-sdk/fetch-guard-DY9jpsXo.cjs +1 -0
  636. package/dist/plugin-sdk/fetch-guard-DbOZYxyN.js +1 -0
  637. package/dist/plugin-sdk/fetch-guard-_fifU0fX.js +1 -0
  638. package/dist/plugin-sdk/fetch-lw-aF17e.cjs +1 -0
  639. package/dist/plugin-sdk/fetch-timeout-6oZsqWxA.js +1 -0
  640. package/dist/plugin-sdk/fetch-timeout-BygUD0rd.cjs +1 -0
  641. package/dist/plugin-sdk/fetch-timeout-CLw1U7VS.js +1 -0
  642. package/dist/plugin-sdk/fetch-timeout-CX1w-9p4.cjs +1 -0
  643. package/dist/plugin-sdk/fetch-timeout-Coc9xyC3.cjs +1 -0
  644. package/dist/plugin-sdk/fetch-timeout-Cz6GuU_c.js +1 -0
  645. package/dist/plugin-sdk/fetch-timeout-DC8T2JCr.js +1 -0
  646. package/dist/plugin-sdk/fetch-timeout-DFDmks9T.cjs +1 -0
  647. package/dist/plugin-sdk/fetch-timeout-DkYpp08Q.js +1 -0
  648. package/dist/plugin-sdk/github-copilot-token-BHdMLLqf.cjs +1 -0
  649. package/dist/plugin-sdk/github-copilot-token-Bt4PduRB.js +1 -0
  650. package/dist/plugin-sdk/github-copilot-token-C1O2cBqk.cjs +1 -0
  651. package/dist/plugin-sdk/github-copilot-token-C1hiDugd.js +1 -0
  652. package/dist/plugin-sdk/github-copilot-token-C8j8_NjX.js +1 -0
  653. package/dist/plugin-sdk/github-copilot-token-CCrgp2py.cjs +1 -0
  654. package/dist/plugin-sdk/github-copilot-token-DoHgkI2r.cjs +1 -0
  655. package/dist/plugin-sdk/github-copilot-token-N8vnLZPw.js +1 -0
  656. package/dist/plugin-sdk/github-copilot-token-TMkfxxD2.cjs +1 -0
  657. package/dist/plugin-sdk/github-copilot-token-vKAKX6iE.js +1 -0
  658. package/dist/plugin-sdk/github-copilot-token-ylX_gawo.js +1 -0
  659. package/dist/plugin-sdk/github-copilot-token-zskwAEpd.cjs +1 -0
  660. package/dist/plugin-sdk/google-gemini-cli-auth.cjs +1 -0
  661. package/dist/plugin-sdk/google-gemini-cli-auth.js +1 -0
  662. package/dist/plugin-sdk/googlechat.cjs +1 -0
  663. package/dist/plugin-sdk/googlechat.js +1 -0
  664. package/dist/plugin-sdk/image-B6HEHWlJ.js +1 -0
  665. package/dist/plugin-sdk/image-Bte8cr4F.js +1 -0
  666. package/dist/plugin-sdk/image-BxafJgQ6.cjs +1 -0
  667. package/dist/plugin-sdk/image-CDI5SqeR.js +1 -0
  668. package/dist/plugin-sdk/image-CTgwucug.cjs +1 -0
  669. package/dist/plugin-sdk/image-CWnsS03L.js +1 -0
  670. package/dist/plugin-sdk/image-CoksjGBL.cjs +1 -0
  671. package/dist/plugin-sdk/image-CuOIoxl2.cjs +1 -0
  672. package/dist/plugin-sdk/image-DJyEMzkq.cjs +1 -0
  673. package/dist/plugin-sdk/image-DegWnAZU.cjs +1 -0
  674. package/dist/plugin-sdk/image-TCSQZpr6.js +1 -0
  675. package/dist/plugin-sdk/image-aG-5S1vd.js +1 -0
  676. package/dist/plugin-sdk/imessage.cjs +1 -0
  677. package/dist/plugin-sdk/imessage.js +1 -0
  678. package/dist/plugin-sdk/index.cjs +1 -0
  679. package/dist/plugin-sdk/index.js +1 -0
  680. package/dist/plugin-sdk/ir-8rDh7div.js +1 -0
  681. package/dist/plugin-sdk/ir-Bh6lKGdS.js +1 -0
  682. package/dist/plugin-sdk/ir-C3VNqnc2.cjs +1 -0
  683. package/dist/plugin-sdk/ir-CZOtKajq.cjs +1 -0
  684. package/dist/plugin-sdk/ir-CveCWs8q.cjs +1 -0
  685. package/dist/plugin-sdk/ir-DAxY-7c1.cjs +1 -0
  686. package/dist/plugin-sdk/ir-DSuLr2UE.cjs +1 -0
  687. package/dist/plugin-sdk/ir-DanxCjD-.cjs +1 -0
  688. package/dist/plugin-sdk/ir-Dgc6qZMX.js +1 -0
  689. package/dist/plugin-sdk/ir-OBi5zaEW.js +1 -0
  690. package/dist/plugin-sdk/ir-hQ6EW92h.js +1 -0
  691. package/dist/plugin-sdk/ir-ynWQeZD9.js +1 -0
  692. package/dist/plugin-sdk/irc.cjs +1 -0
  693. package/dist/plugin-sdk/irc.js +1 -0
  694. package/dist/plugin-sdk/keyed-async-queue.cjs +1 -0
  695. package/dist/plugin-sdk/keyed-async-queue.js +1 -0
  696. package/dist/plugin-sdk/line.cjs +1 -0
  697. package/dist/plugin-sdk/line.js +1 -0
  698. package/dist/plugin-sdk/llm-task.cjs +1 -0
  699. package/dist/plugin-sdk/llm-task.js +1 -0
  700. package/dist/plugin-sdk/load-options-B9Ss5YOO.js +1 -0
  701. package/dist/plugin-sdk/load-options-BOfn6Zgo.cjs +1 -0
  702. package/dist/plugin-sdk/load-options-BXvm8HVv.js +1 -0
  703. package/dist/plugin-sdk/load-options-Bb7u8yZz.cjs +1 -0
  704. package/dist/plugin-sdk/load-options-BcSg1ODN.js +1 -0
  705. package/dist/plugin-sdk/load-options-NqnXJ-Nh.cjs +1 -0
  706. package/dist/plugin-sdk/lobster.cjs +1 -0
  707. package/dist/plugin-sdk/lobster.js +1 -0
  708. package/dist/plugin-sdk/local-roots-5udQUs81.js +1 -0
  709. package/dist/plugin-sdk/local-roots-BmhNPIJm.cjs +1 -0
  710. package/dist/plugin-sdk/local-roots-C5UoE741.cjs +1 -0
  711. package/dist/plugin-sdk/local-roots-Ca8KoAAp.js +1 -0
  712. package/dist/plugin-sdk/local-roots-CeAYfmPb.cjs +1 -0
  713. package/dist/plugin-sdk/local-roots-Cu7YCpql.cjs +1 -0
  714. package/dist/plugin-sdk/local-roots-D0yN794S.js +1 -0
  715. package/dist/plugin-sdk/local-roots-D4i3H0UG.cjs +1 -0
  716. package/dist/plugin-sdk/local-roots-DGe-SRNu.js +1 -0
  717. package/dist/plugin-sdk/local-roots-bWA2msT0.js +1 -0
  718. package/dist/plugin-sdk/local-roots-tee85Q-1.js +1 -0
  719. package/dist/plugin-sdk/local-roots-wTkpE7go.cjs +1 -0
  720. package/dist/plugin-sdk/logger-6O6OsYBL.cjs +1 -0
  721. package/dist/plugin-sdk/logger-BlddiV_d.cjs +1 -0
  722. package/dist/plugin-sdk/logger-Bm93ZKOk.cjs +1 -0
  723. package/dist/plugin-sdk/logger-BtrWb0dj.js +1 -0
  724. package/dist/plugin-sdk/logger-C210xuWx.js +1 -0
  725. package/dist/plugin-sdk/logger-DJGHvDbX.js +1 -0
  726. package/dist/plugin-sdk/logger-DPlqYkRm.cjs +1 -0
  727. package/dist/plugin-sdk/logger-DUYnS-W3.cjs +1 -0
  728. package/dist/plugin-sdk/logger-DwWqfo66.js +1 -0
  729. package/dist/plugin-sdk/logger-vBDTZWl3.js +1 -0
  730. package/dist/plugin-sdk/login-B5IwNcl4.cjs +1 -0
  731. package/dist/plugin-sdk/login-BIbt7ZL_.js +1 -0
  732. package/dist/plugin-sdk/login-CxnDKwXC.js +1 -0
  733. package/dist/plugin-sdk/login-D5iTWowo.cjs +1 -0
  734. package/dist/plugin-sdk/login-DHE1rzB1.js +1 -0
  735. package/dist/plugin-sdk/login-DIPBcPQc.cjs +1 -0
  736. package/dist/plugin-sdk/login-DtDOozuU.js +1 -0
  737. package/dist/plugin-sdk/login-UrWNtI80.cjs +1 -0
  738. package/dist/plugin-sdk/login-VviMkBU2.js +1 -0
  739. package/dist/plugin-sdk/login-jQwwt6C-.js +1 -0
  740. package/dist/plugin-sdk/login-mGjCzJzb.cjs +1 -0
  741. package/dist/plugin-sdk/login-pZnnpj38.cjs +1 -0
  742. package/dist/plugin-sdk/login-qr-BexuTIDJ.cjs +1 -0
  743. package/dist/plugin-sdk/login-qr-C366Qlh-.cjs +1 -0
  744. package/dist/plugin-sdk/login-qr-CQY4ty0o.js +1 -0
  745. package/dist/plugin-sdk/login-qr-CSabEb-n.cjs +1 -0
  746. package/dist/plugin-sdk/login-qr-CUgNKijx.js +1 -0
  747. package/dist/plugin-sdk/login-qr-C_LEw1Bi.js +1 -0
  748. package/dist/plugin-sdk/login-qr-CcPvldsG.js +1 -0
  749. package/dist/plugin-sdk/login-qr-CnNGKwDR.cjs +1 -0
  750. package/dist/plugin-sdk/login-qr-DQm50pXk.js +1 -0
  751. package/dist/plugin-sdk/login-qr-DayvAWkx.js +1 -0
  752. package/dist/plugin-sdk/login-qr-eodIsL9V.cjs +1 -0
  753. package/dist/plugin-sdk/login-qr-yIJE7MmY.cjs +1 -0
  754. package/dist/plugin-sdk/manager-932XljTT.js +1 -0
  755. package/dist/plugin-sdk/manager-CGHd5p2T.js +1 -0
  756. package/dist/plugin-sdk/manager-CbGA_JDa.js +1 -0
  757. package/dist/plugin-sdk/manager-CdD7HaGW.cjs +1 -0
  758. package/dist/plugin-sdk/manager-CmAH_a7A.cjs +1 -0
  759. package/dist/plugin-sdk/manager-DIS4ywpb.cjs +1 -0
  760. package/dist/plugin-sdk/manager-DQ2C-2IU.cjs +1 -0
  761. package/dist/plugin-sdk/manager-DdvFnsT7.cjs +1 -0
  762. package/dist/plugin-sdk/manager-DfdDglld.js +1 -0
  763. package/dist/plugin-sdk/manager-MR9stU_p.js +1 -0
  764. package/dist/plugin-sdk/manager-WwW37IUu.js +1 -0
  765. package/dist/plugin-sdk/manager-gE9187gu.cjs +1 -0
  766. package/dist/plugin-sdk/matrix.cjs +1 -0
  767. package/dist/plugin-sdk/matrix.js +1 -0
  768. package/dist/plugin-sdk/mattermost.cjs +1 -0
  769. package/dist/plugin-sdk/mattermost.js +1 -0
  770. package/dist/plugin-sdk/memory-core.cjs +1 -0
  771. package/dist/plugin-sdk/memory-core.js +1 -0
  772. package/dist/plugin-sdk/minimax-portal-auth.cjs +1 -0
  773. package/dist/plugin-sdk/minimax-portal-auth.js +1 -0
  774. package/dist/plugin-sdk/model-auth-BpS4IWDi.cjs +1 -0
  775. package/dist/plugin-sdk/model-auth-BwajGuoF.cjs +1 -0
  776. package/dist/plugin-sdk/model-auth-C1YL9HcW.js +1 -0
  777. package/dist/plugin-sdk/model-auth-Cc-8H6Cu.js +1 -0
  778. package/dist/plugin-sdk/model-auth-Cw3fuhm_.js +1 -0
  779. package/dist/plugin-sdk/model-auth-CycDtQl-.js +1 -0
  780. package/dist/plugin-sdk/model-auth-D-7xiXhK.cjs +1 -0
  781. package/dist/plugin-sdk/model-auth-TFUxaK0f.cjs +1 -0
  782. package/dist/plugin-sdk/model-selection-BADTZM9n.cjs +1 -0
  783. package/dist/plugin-sdk/model-selection-DUAudCtL.js +1 -0
  784. package/dist/plugin-sdk/msteams.cjs +1 -0
  785. package/dist/plugin-sdk/msteams.js +1 -0
  786. package/dist/plugin-sdk/nextcloud-talk.cjs +1 -0
  787. package/dist/plugin-sdk/nextcloud-talk.js +1 -0
  788. package/dist/plugin-sdk/nostr.cjs +1 -0
  789. package/dist/plugin-sdk/nostr.js +1 -0
  790. package/dist/plugin-sdk/outbound-2Lo6mZEY.js +1 -0
  791. package/dist/plugin-sdk/outbound-9XFlZzaF.cjs +1 -0
  792. package/dist/plugin-sdk/outbound-BlWsUmjQ.js +1 -0
  793. package/dist/plugin-sdk/outbound-Bs2rUcWZ.cjs +1 -0
  794. package/dist/plugin-sdk/outbound-C18nEOFP.js +1 -0
  795. package/dist/plugin-sdk/outbound-CW3o4Eng.cjs +1 -0
  796. package/dist/plugin-sdk/outbound-CzsdW5sy.js +1 -0
  797. package/dist/plugin-sdk/outbound-DcP22VOo.cjs +1 -0
  798. package/dist/plugin-sdk/outbound-QhOJAEO8.cjs +1 -0
  799. package/dist/plugin-sdk/outbound-attachment-1pf06Oiu.cjs +1 -0
  800. package/dist/plugin-sdk/outbound-attachment-B8-ZVX2i.cjs +1 -0
  801. package/dist/plugin-sdk/outbound-attachment-BDwI_tn0.cjs +1 -0
  802. package/dist/plugin-sdk/outbound-attachment-BXhbJils.js +1 -0
  803. package/dist/plugin-sdk/outbound-attachment-Bgf1pCh8.js +1 -0
  804. package/dist/plugin-sdk/outbound-attachment-COgf85S8.cjs +1 -0
  805. package/dist/plugin-sdk/outbound-attachment-CfN9OvMC.js +1 -0
  806. package/dist/plugin-sdk/outbound-attachment-CftilZWd.js +1 -0
  807. package/dist/plugin-sdk/outbound-attachment-Cujprd6T.cjs +1 -0
  808. package/dist/plugin-sdk/outbound-attachment-CvSHb9ci.js +1 -0
  809. package/dist/plugin-sdk/outbound-attachment-DQYtdTUw.js +1 -0
  810. package/dist/plugin-sdk/outbound-attachment-FqWC0WJx.cjs +1 -0
  811. package/dist/plugin-sdk/outbound-dTvIiFIZ.js +1 -0
  812. package/dist/plugin-sdk/outbound-fZ1WJGfe.cjs +1 -0
  813. package/dist/plugin-sdk/outbound-oHoWYWxf.js +1 -0
  814. package/dist/plugin-sdk/paths-BPlgbwrb.cjs +1 -0
  815. package/dist/plugin-sdk/paths-Bcdg3ma0.cjs +1 -0
  816. package/dist/plugin-sdk/paths-BpQOWYiT.js +1 -0
  817. package/dist/plugin-sdk/paths-BvlJvmRS.cjs +1 -0
  818. package/dist/plugin-sdk/paths-CIcxeNL-.cjs +1 -0
  819. package/dist/plugin-sdk/paths-CXgWvWAM.js +1 -0
  820. package/dist/plugin-sdk/paths-Chp3zwtq.cjs +1 -0
  821. package/dist/plugin-sdk/paths-CnHSNSeR.js +1 -0
  822. package/dist/plugin-sdk/paths-Cqca1YmF.cjs +1 -0
  823. package/dist/plugin-sdk/paths-CtrEseGU.js +1 -0
  824. package/dist/plugin-sdk/paths-D55o_j8-.js +1 -0
  825. package/dist/plugin-sdk/paths-D90l3h_o.cjs +1 -0
  826. package/dist/plugin-sdk/paths-DaRoqzBQ.js +1 -0
  827. package/dist/plugin-sdk/paths-Dd7r1qlB.cjs +1 -0
  828. package/dist/plugin-sdk/paths-DhSjTRMz.js +1 -0
  829. package/dist/plugin-sdk/paths-Do0djuaj.js +1 -0
  830. package/dist/plugin-sdk/paths-J4JUiRsa.js +1 -0
  831. package/dist/plugin-sdk/paths-cBAF6Bj0.js +1 -0
  832. package/dist/plugin-sdk/paths-piJASC5k.js +1 -0
  833. package/dist/plugin-sdk/paths-rO4ehkyU.js +1 -0
  834. package/dist/plugin-sdk/pi-model-discovery-B9boErNZ.cjs +1 -0
  835. package/dist/plugin-sdk/pi-model-discovery-BJ8wTgFH.cjs +1 -0
  836. package/dist/plugin-sdk/pi-model-discovery-Bb2vCP6M.js +1 -0
  837. package/dist/plugin-sdk/pi-model-discovery-Bor7jHYd.js +1 -0
  838. package/dist/plugin-sdk/pi-model-discovery-BrTw1qE2.cjs +1 -0
  839. package/dist/plugin-sdk/pi-model-discovery-BuEMyAsU.js +1 -0
  840. package/dist/plugin-sdk/pi-model-discovery-CV9NTjC4.js +1 -0
  841. package/dist/plugin-sdk/pi-model-discovery-D5tLf04u.js +1 -0
  842. package/dist/plugin-sdk/pi-model-discovery-D5xlUS2J.cjs +1 -0
  843. package/dist/plugin-sdk/pi-model-discovery-DGoPUzBj.cjs +1 -0
  844. package/dist/plugin-sdk/pi-model-discovery-DMrqvV1O.cjs +1 -0
  845. package/dist/plugin-sdk/pi-model-discovery-DoY7qnlI.cjs +1 -0
  846. package/dist/plugin-sdk/pi-model-discovery-Dqq9Vm8o.js +1 -0
  847. package/dist/plugin-sdk/pi-model-discovery-zCuISPPq.js +1 -0
  848. package/dist/plugin-sdk/pi-tools.before-tool-call.runtime-4238P8NF.js +1 -0
  849. package/dist/plugin-sdk/pi-tools.before-tool-call.runtime-BEoqzgFe.cjs +1 -0
  850. package/dist/plugin-sdk/pi-tools.before-tool-call.runtime-BGPjibRD.js +1 -0
  851. package/dist/plugin-sdk/pi-tools.before-tool-call.runtime-BJ_amISU.cjs +1 -0
  852. package/dist/plugin-sdk/pi-tools.before-tool-call.runtime-BX2r_qPT.cjs +1 -0
  853. package/dist/plugin-sdk/pi-tools.before-tool-call.runtime-CGLHFxSr.js +1 -0
  854. package/dist/plugin-sdk/pi-tools.before-tool-call.runtime-CsNn_Lv8.js +1 -0
  855. package/dist/plugin-sdk/pi-tools.before-tool-call.runtime-CsiKBTHg.cjs +1 -0
  856. package/dist/plugin-sdk/pi-tools.before-tool-call.runtime-CuXQQk4F.cjs +1 -0
  857. package/dist/plugin-sdk/pi-tools.before-tool-call.runtime-DNatrz-3.cjs +1 -0
  858. package/dist/plugin-sdk/pi-tools.before-tool-call.runtime-PApjB0tY.js +1 -0
  859. package/dist/plugin-sdk/pi-tools.before-tool-call.runtime-xsXDBYNq.js +1 -0
  860. package/dist/plugin-sdk/polls-BuaJuIpV.cjs +1 -0
  861. package/dist/plugin-sdk/polls-CBAGZuJ6.js +1 -0
  862. package/dist/plugin-sdk/polls-CSKMbBIS.js +1 -0
  863. package/dist/plugin-sdk/polls-D0wY0FvT.cjs +1 -0
  864. package/dist/plugin-sdk/polls-PGxiE05J.js +1 -0
  865. package/dist/plugin-sdk/polls-yWqSCEP0.cjs +1 -0
  866. package/dist/plugin-sdk/proxy-env-B765haXA.js +1 -0
  867. package/dist/plugin-sdk/proxy-env-Bcl14j2_.cjs +1 -0
  868. package/dist/plugin-sdk/proxy-env-BlrHtJWH.js +1 -0
  869. package/dist/plugin-sdk/proxy-env-D48qBPAr.cjs +1 -0
  870. package/dist/plugin-sdk/proxy-env-DGzNnnJh.js +1 -0
  871. package/dist/plugin-sdk/proxy-env-DQoJjkWE.cjs +1 -0
  872. package/dist/plugin-sdk/proxy-env-DWw9TnOj.cjs +1 -0
  873. package/dist/plugin-sdk/proxy-env-MEjSyzTr.js +1 -0
  874. package/dist/plugin-sdk/proxy-env-a590sPAz.cjs +1 -0
  875. package/dist/plugin-sdk/proxy-env-k93igu7v.cjs +1 -0
  876. package/dist/plugin-sdk/proxy-env-m9eG3uZN.js +1 -0
  877. package/dist/plugin-sdk/proxy-env-t6hcaFqC.js +1 -0
  878. package/dist/plugin-sdk/proxy-fetch-B9aXJVe-.js +1 -0
  879. package/dist/plugin-sdk/proxy-fetch-BaA3JYgW.cjs +1 -0
  880. package/dist/plugin-sdk/proxy-fetch-BwXFVsHE.cjs +1 -0
  881. package/dist/plugin-sdk/proxy-fetch-BzcKzknk.cjs +1 -0
  882. package/dist/plugin-sdk/proxy-fetch-CYVChsKE.js +1 -0
  883. package/dist/plugin-sdk/proxy-fetch-ClOb2LUH.js +1 -0
  884. package/dist/plugin-sdk/proxy-fetch-DH7VIiBH.cjs +1 -0
  885. package/dist/plugin-sdk/proxy-fetch-DPOhfrou.cjs +1 -0
  886. package/dist/plugin-sdk/proxy-fetch-DXt2R_Z5.js +1 -0
  887. package/dist/plugin-sdk/proxy-fetch-Del551nu.js +1 -0
  888. package/dist/plugin-sdk/proxy-fetch-YCVHz7Rl.js +1 -0
  889. package/dist/plugin-sdk/proxy-fetch-qbrYAz8k.cjs +1 -0
  890. package/dist/plugin-sdk/pw-ai-B0_rvdfF.js +1 -0
  891. package/dist/plugin-sdk/pw-ai-BqdrA15F.js +1 -0
  892. package/dist/plugin-sdk/pw-ai-CDzxu5B3.js +1 -0
  893. package/dist/plugin-sdk/pw-ai-CJIogpwF.cjs +1 -0
  894. package/dist/plugin-sdk/pw-ai-CL_gU5PJ.cjs +1 -0
  895. package/dist/plugin-sdk/pw-ai-Ca4aZTaG.cjs +1 -0
  896. package/dist/plugin-sdk/pw-ai-CrfYxLI8.cjs +1 -0
  897. package/dist/plugin-sdk/pw-ai-DCiFlwP8.js +1 -0
  898. package/dist/plugin-sdk/pw-ai-DSqXNmNZ.js +1 -0
  899. package/dist/plugin-sdk/pw-ai-Dh55xTz1.cjs +1 -0
  900. package/dist/plugin-sdk/pw-ai-DxAvipyK.cjs +1 -0
  901. package/dist/plugin-sdk/pw-ai-U9nPHH-0.js +1 -0
  902. package/dist/plugin-sdk/qmd-manager-B3xNbdye.cjs +1 -0
  903. package/dist/plugin-sdk/qmd-manager-BMyDNBPi.js +1 -0
  904. package/dist/plugin-sdk/qmd-manager-BZhiv_zq.cjs +1 -0
  905. package/dist/plugin-sdk/qmd-manager-C3uVDbhW.js +1 -0
  906. package/dist/plugin-sdk/qmd-manager-CW46NrS-.cjs +1 -0
  907. package/dist/plugin-sdk/qmd-manager-C_e04BNg.js +1 -0
  908. package/dist/plugin-sdk/qmd-manager-CczVoslK.cjs +1 -0
  909. package/dist/plugin-sdk/qmd-manager-CzLKqPmR.js +1 -0
  910. package/dist/plugin-sdk/qmd-manager-DFh8b5N-.cjs +1 -0
  911. package/dist/plugin-sdk/qmd-manager-DXLfZZMI.js +1 -0
  912. package/dist/plugin-sdk/qmd-manager-FL9fAfNo.cjs +1 -0
  913. package/dist/plugin-sdk/qmd-manager-fWxbGqzk.js +1 -0
  914. package/dist/plugin-sdk/query-expansion-0zYzKrrd.cjs +1 -0
  915. package/dist/plugin-sdk/query-expansion-BYSjmpkV.cjs +1 -0
  916. package/dist/plugin-sdk/query-expansion-CAboqtWr.js +1 -0
  917. package/dist/plugin-sdk/query-expansion-C_DnhmUy.js +1 -0
  918. package/dist/plugin-sdk/query-expansion-Cb2vnF6y.js +1 -0
  919. package/dist/plugin-sdk/query-expansion-DCeqywxh.cjs +1 -0
  920. package/dist/plugin-sdk/query-expansion-DF4LMxRQ.js +1 -0
  921. package/dist/plugin-sdk/query-expansion-DKJkqmNM.cjs +1 -0
  922. package/dist/plugin-sdk/query-expansion-DO2CFW4z.cjs +1 -0
  923. package/dist/plugin-sdk/query-expansion-DyCDaZbL.js +1 -0
  924. package/dist/plugin-sdk/query-expansion-cpXCyoDy.cjs +1 -0
  925. package/dist/plugin-sdk/query-expansion-r_iXkNzt.js +1 -0
  926. package/dist/plugin-sdk/qwen-portal-auth.cjs +1 -0
  927. package/dist/plugin-sdk/qwen-portal-auth.js +1 -0
  928. package/dist/plugin-sdk/render-6fCdtAr6.cjs +1 -0
  929. package/dist/plugin-sdk/render-CBsnn-2A.js +1 -0
  930. package/dist/plugin-sdk/render-CzHaQB0d.cjs +1 -0
  931. package/dist/plugin-sdk/render-DGmfCIRG.js +1 -0
  932. package/dist/plugin-sdk/render-DhTJXP1U.js +1 -0
  933. package/dist/plugin-sdk/render-Djx15dPh.js +1 -0
  934. package/dist/plugin-sdk/render-DxBO2Blp.cjs +1 -0
  935. package/dist/plugin-sdk/render-g5VlmgpF.cjs +1 -0
  936. package/dist/plugin-sdk/reply-0zCEbT4w.cjs +1 -0
  937. package/dist/plugin-sdk/reply-D-f2bbXy.js +1 -0
  938. package/dist/plugin-sdk/resolve-outbound-target-CrQGbaua.js +1 -0
  939. package/dist/plugin-sdk/resolve-outbound-target-H7Q9HcfW.js +1 -0
  940. package/dist/plugin-sdk/resolve-outbound-target-MS6Xpp17.cjs +1 -0
  941. package/dist/plugin-sdk/resolve-outbound-target-cDxjy3TL.cjs +1 -0
  942. package/dist/plugin-sdk/send-3VNTSIhr.js +1 -0
  943. package/dist/plugin-sdk/send-61GHLNYP.cjs +1 -0
  944. package/dist/plugin-sdk/send-6q4owAw0.js +1 -0
  945. package/dist/plugin-sdk/send-A2s5sPTd.js +1 -0
  946. package/dist/plugin-sdk/send-B2qa7CSk.js +1 -0
  947. package/dist/plugin-sdk/send-B3aEYvqG.cjs +1 -0
  948. package/dist/plugin-sdk/send-BAoqP09M.cjs +1 -0
  949. package/dist/plugin-sdk/send-BNBJ4CF8.js +1 -0
  950. package/dist/plugin-sdk/send-BTE2rI1E.js +1 -0
  951. package/dist/plugin-sdk/send-BlWuQHYB.js +1 -0
  952. package/dist/plugin-sdk/send-Bnvt7ZUE.cjs +1 -0
  953. package/dist/plugin-sdk/send-Bq6Mqs9G.cjs +1 -0
  954. package/dist/plugin-sdk/send-Bq787fi_.js +1 -0
  955. package/dist/plugin-sdk/send-BrAHLYBR.js +1 -0
  956. package/dist/plugin-sdk/send-Bt2eFBk2.js +1 -0
  957. package/dist/plugin-sdk/send-C4ZFbUux.js +1 -0
  958. package/dist/plugin-sdk/send-C4cyMW4S.cjs +1 -0
  959. package/dist/plugin-sdk/send-C8f5H4XV.cjs +1 -0
  960. package/dist/plugin-sdk/send-CDwTrbgT.cjs +1 -0
  961. package/dist/plugin-sdk/send-CEfs0Fsr.js +1 -0
  962. package/dist/plugin-sdk/send-CFuJjCNB.cjs +1 -0
  963. package/dist/plugin-sdk/send-CJGLeSJ8.cjs +1 -0
  964. package/dist/plugin-sdk/send-CL0W7jLW.js +1 -0
  965. package/dist/plugin-sdk/send-CLl490Gb.cjs +1 -0
  966. package/dist/plugin-sdk/send-CQtITZ7k.cjs +1 -0
  967. package/dist/plugin-sdk/send-CSGh_GVr.cjs +1 -0
  968. package/dist/plugin-sdk/send-CicLiXB4.js +1 -0
  969. package/dist/plugin-sdk/send-Cm7bEwx-.cjs +1 -0
  970. package/dist/plugin-sdk/send-CmO9z2-b.js +1 -0
  971. package/dist/plugin-sdk/send-Co_Wy2kT.cjs +1 -0
  972. package/dist/plugin-sdk/send-Cox_iyYB.cjs +1 -0
  973. package/dist/plugin-sdk/send-CuX4LcJ3.cjs +1 -0
  974. package/dist/plugin-sdk/send-CxMiTtxI.cjs +1 -0
  975. package/dist/plugin-sdk/send-CyyzWwDr.js +1 -0
  976. package/dist/plugin-sdk/send-D-HZnehy.cjs +1 -0
  977. package/dist/plugin-sdk/send-D-qD7BCb.js +1 -0
  978. package/dist/plugin-sdk/send-D3imkSlz.cjs +1 -0
  979. package/dist/plugin-sdk/send-D5UwpCoU.cjs +1 -0
  980. package/dist/plugin-sdk/send-D75OGJco.js +1 -0
  981. package/dist/plugin-sdk/send-DB4i1kUy.cjs +1 -0
  982. package/dist/plugin-sdk/send-DBjzdBda.cjs +1 -0
  983. package/dist/plugin-sdk/send-DPgRTM8s.js +1 -0
  984. package/dist/plugin-sdk/send-DPpBLiL4.js +1 -0
  985. package/dist/plugin-sdk/send-DV_afQnj.cjs +1 -0
  986. package/dist/plugin-sdk/send-DWuChr46.js +1 -0
  987. package/dist/plugin-sdk/send-DZ4szmEa.cjs +1 -0
  988. package/dist/plugin-sdk/send-DZr98eqE.cjs +1 -0
  989. package/dist/plugin-sdk/send-D_1K0zmx.cjs +1 -0
  990. package/dist/plugin-sdk/send-DaLB9Lca.js +1 -0
  991. package/dist/plugin-sdk/send-De4qiprb.js +1 -0
  992. package/dist/plugin-sdk/send-DeU-T5ps.js +1 -0
  993. package/dist/plugin-sdk/send-DtjJM0LO.js +1 -0
  994. package/dist/plugin-sdk/send-DvDCmTQf.js +1 -0
  995. package/dist/plugin-sdk/send-EvcsiFBC.cjs +1 -0
  996. package/dist/plugin-sdk/send-GuISe9C82.js +1 -0
  997. package/dist/plugin-sdk/send-IoGcE0w2.js +1 -0
  998. package/dist/plugin-sdk/send-JVdUTsN1.cjs +1 -0
  999. package/dist/plugin-sdk/send-NpNVFRmY.js +1 -0
  1000. package/dist/plugin-sdk/send-XMOZsJcs.js +1 -0
  1001. package/dist/plugin-sdk/send-h--iKoQE.cjs +1 -0
  1002. package/dist/plugin-sdk/session-8BcB905y.cjs +1 -0
  1003. package/dist/plugin-sdk/session-B2oURX5K.js +1 -0
  1004. package/dist/plugin-sdk/session-BJhNqIOi.js +1 -0
  1005. package/dist/plugin-sdk/session-BRgGsw96.cjs +1 -0
  1006. package/dist/plugin-sdk/session-Be_7rXAz.js +1 -0
  1007. package/dist/plugin-sdk/session-C66IXbE-.js +1 -0
  1008. package/dist/plugin-sdk/session-CCYDbcyV.js +1 -0
  1009. package/dist/plugin-sdk/session-CHu3C2m0.cjs +1 -0
  1010. package/dist/plugin-sdk/session-DUlmK2IL.cjs +1 -0
  1011. package/dist/plugin-sdk/session-DxTRZTnu.js +1 -0
  1012. package/dist/plugin-sdk/session-DzhI0nj-.cjs +1 -0
  1013. package/dist/plugin-sdk/session-WRCBgAzG.cjs +1 -0
  1014. package/dist/plugin-sdk/sessions-DxXXAfdI.js +1 -0
  1015. package/dist/plugin-sdk/sessions-Dz5JUL8j.cjs +1 -0
  1016. package/dist/plugin-sdk/signal.cjs +1 -0
  1017. package/dist/plugin-sdk/signal.js +1 -0
  1018. package/dist/plugin-sdk/skill-commands-B4wI8ETo.cjs +1 -0
  1019. package/dist/plugin-sdk/skill-commands-BoTeA376.cjs +1 -0
  1020. package/dist/plugin-sdk/skill-commands-BwrYJu7Z.js +1 -0
  1021. package/dist/plugin-sdk/skill-commands-BzkMuA58.cjs +1 -0
  1022. package/dist/plugin-sdk/skill-commands-CIAf9cWN.cjs +1 -0
  1023. package/dist/plugin-sdk/skill-commands-CKc7JO_c.cjs +1 -0
  1024. package/dist/plugin-sdk/skill-commands-Cvb6oXym.js +1 -0
  1025. package/dist/plugin-sdk/skill-commands-DWDtyCtB.js +1 -0
  1026. package/dist/plugin-sdk/skill-commands-Hmuw0PPK.js +1 -0
  1027. package/dist/plugin-sdk/skill-commands-KyN0FGaC.cjs +1 -0
  1028. package/dist/plugin-sdk/skill-commands-KzwEqk5p.js +1 -0
  1029. package/dist/plugin-sdk/skill-commands-Ny38ZFIC.js +1 -0
  1030. package/dist/plugin-sdk/slack.cjs +1 -0
  1031. package/dist/plugin-sdk/slack.js +1 -0
  1032. package/dist/plugin-sdk/synology-chat.cjs +1 -0
  1033. package/dist/plugin-sdk/synology-chat.js +1 -0
  1034. package/dist/plugin-sdk/tables-BIDWwpX8.js +1 -0
  1035. package/dist/plugin-sdk/tables-Bk8lHaPx.cjs +1 -0
  1036. package/dist/plugin-sdk/tables-BlNIkMV8.js +1 -0
  1037. package/dist/plugin-sdk/tables-Bp0a2WRP.cjs +1 -0
  1038. package/dist/plugin-sdk/tables-BtVUf77b.cjs +1 -0
  1039. package/dist/plugin-sdk/tables-C4j5Bar_.js +1 -0
  1040. package/dist/plugin-sdk/tables-CZGtYzDC.cjs +1 -0
  1041. package/dist/plugin-sdk/tables-CnrHab5d.cjs +1 -0
  1042. package/dist/plugin-sdk/tables-DtslIPYw.js +1 -0
  1043. package/dist/plugin-sdk/tables-NrdtIJGp.cjs +1 -0
  1044. package/dist/plugin-sdk/tables-XYb3T-vE.js +1 -0
  1045. package/dist/plugin-sdk/tables-lbv-0tl3.js +1 -0
  1046. package/dist/plugin-sdk/target-errors-9cdJA1L2.cjs +1 -0
  1047. package/dist/plugin-sdk/target-errors-BEkhKWCq.cjs +1 -0
  1048. package/dist/plugin-sdk/target-errors-BZRN-lPd.js +1 -0
  1049. package/dist/plugin-sdk/target-errors-BrwqillR.cjs +1 -0
  1050. package/dist/plugin-sdk/target-errors-Buo5pfom.js +1 -0
  1051. package/dist/plugin-sdk/target-errors-CFzzcffg.js +1 -0
  1052. package/dist/plugin-sdk/target-errors-DFmK5loi.js +1 -0
  1053. package/dist/plugin-sdk/target-errors-DXqwykNX.js +1 -0
  1054. package/dist/plugin-sdk/target-errors-Dd6CopYF.cjs +1 -0
  1055. package/dist/plugin-sdk/target-errors-DeNJ10ks.cjs +1 -0
  1056. package/dist/plugin-sdk/targets-BSc11Uk8.cjs +1 -0
  1057. package/dist/plugin-sdk/targets-BSkiizml.js +1 -0
  1058. package/dist/plugin-sdk/targets-CBI0xqve.cjs +1 -0
  1059. package/dist/plugin-sdk/targets-CL5fYQi7.js +1 -0
  1060. package/dist/plugin-sdk/targets-CUZWrFrm.cjs +1 -0
  1061. package/dist/plugin-sdk/targets-CVEYTFPQ.js +1 -0
  1062. package/dist/plugin-sdk/targets-Co2R6K14.cjs +1 -0
  1063. package/dist/plugin-sdk/targets-CrkJkzil.js +1 -0
  1064. package/dist/plugin-sdk/targets-D-m7SV9x.cjs +1 -0
  1065. package/dist/plugin-sdk/targets-D8HTxbo4.js +1 -0
  1066. package/dist/plugin-sdk/targets-DcGNB9nk.cjs +1 -0
  1067. package/dist/plugin-sdk/targets-Dn9gDiEw.js +1 -0
  1068. package/dist/plugin-sdk/targets-X28mff4s.cjs +1 -0
  1069. package/dist/plugin-sdk/targets-uycXZ8vQ.js +1 -0
  1070. package/dist/plugin-sdk/telegram.cjs +1 -0
  1071. package/dist/plugin-sdk/telegram.js +1 -0
  1072. package/dist/plugin-sdk/test-utils.cjs +1 -0
  1073. package/dist/plugin-sdk/test-utils.js +1 -0
  1074. package/dist/plugin-sdk/tlon.cjs +1 -0
  1075. package/dist/plugin-sdk/tlon.js +1 -0
  1076. package/dist/plugin-sdk/tokens-AAdZjj0M.js +1 -0
  1077. package/dist/plugin-sdk/tokens-B20KNIDD.js +1 -0
  1078. package/dist/plugin-sdk/tokens-B8ys7Q2e.js +1 -0
  1079. package/dist/plugin-sdk/tokens-BPc1fcZ3.js +1 -0
  1080. package/dist/plugin-sdk/tokens-BqABmXSe.js +1 -0
  1081. package/dist/plugin-sdk/tokens-CXsPDJTr.cjs +1 -0
  1082. package/dist/plugin-sdk/tokens-CnB4dJmp.cjs +1 -0
  1083. package/dist/plugin-sdk/tokens-CytSl1X8.cjs +1 -0
  1084. package/dist/plugin-sdk/tokens-DgPZk2Uu.js +1 -0
  1085. package/dist/plugin-sdk/tokens-Dq2wDF3_.cjs +1 -0
  1086. package/dist/plugin-sdk/tokens-DtrljGtQ.cjs +1 -0
  1087. package/dist/plugin-sdk/tokens-g5KWvWhD.cjs +1 -0
  1088. package/dist/plugin-sdk/twitch.cjs +1 -0
  1089. package/dist/plugin-sdk/twitch.js +1 -0
  1090. package/dist/plugin-sdk/utils-BJtJR72k.js +1 -0
  1091. package/dist/plugin-sdk/utils-PPIvU9qw.cjs +1 -0
  1092. package/dist/plugin-sdk/voice-call.cjs +1 -0
  1093. package/dist/plugin-sdk/voice-call.js +1 -0
  1094. package/dist/plugin-sdk/web-B-QDcVRv.cjs +1 -0
  1095. package/dist/plugin-sdk/web-B2PwjHsu.cjs +1 -0
  1096. package/dist/plugin-sdk/web-BdnQzLgF.js +1 -0
  1097. package/dist/plugin-sdk/web-C9T7tf6w.js +1 -0
  1098. package/dist/plugin-sdk/web-CODD4ksc.cjs +1 -0
  1099. package/dist/plugin-sdk/web-CkdCvvR-.js +1 -0
  1100. package/dist/plugin-sdk/web-_tj8xNZE.js +1 -0
  1101. package/dist/plugin-sdk/web-pcTha_l7.cjs +1 -0
  1102. package/dist/plugin-sdk/weixin.cjs +1 -0
  1103. package/dist/plugin-sdk/weixin.js +1 -0
  1104. package/dist/plugin-sdk/whatsapp-actions-Bhz2j1uz.cjs +1 -0
  1105. package/dist/plugin-sdk/whatsapp-actions-Bm2UyRYg.cjs +1 -0
  1106. package/dist/plugin-sdk/whatsapp-actions-Bolz0jl5.js +1 -0
  1107. package/dist/plugin-sdk/whatsapp-actions-CJ3LDpaG.js +1 -0
  1108. package/dist/plugin-sdk/whatsapp-actions-CL1Gmkb0.js +1 -0
  1109. package/dist/plugin-sdk/whatsapp-actions-D-bZRT7s.js +1 -0
  1110. package/dist/plugin-sdk/whatsapp-actions-DSGTTE8M.cjs +1 -0
  1111. package/dist/plugin-sdk/whatsapp-actions-DjQxgMpW.cjs +1 -0
  1112. package/dist/plugin-sdk/whatsapp-actions-DrPBBi5t.cjs +1 -0
  1113. package/dist/plugin-sdk/whatsapp-actions-DtK657CZ.cjs +1 -0
  1114. package/dist/plugin-sdk/whatsapp-actions-Xwev51_N.js +1 -0
  1115. package/dist/plugin-sdk/whatsapp-actions-m7vLtNAA.js +1 -0
  1116. package/dist/plugin-sdk/whatsapp.cjs +1 -0
  1117. package/dist/plugin-sdk/whatsapp.js +1 -0
  1118. package/dist/plugin-sdk/zalo.cjs +1 -0
  1119. package/dist/plugin-sdk/zalo.js +1 -0
  1120. package/dist/plugin-sdk/zalouser.cjs +1 -0
  1121. package/dist/plugin-sdk/zalouser.js +1 -0
  1122. package/dist/plugins-CYLrFT4h.js +1 -0
  1123. package/dist/plugins-DNlgeTTc.js +1 -0
  1124. package/dist/plugins-cli-BbjMbzJU.js +1 -0
  1125. package/dist/plugins-cli-BiVMAr5T.js +1 -0
  1126. package/dist/polls-BIVz6a4F.js +1 -0
  1127. package/dist/polls-Bh5wc9-6.js +1 -0
  1128. package/dist/polls-C_XSFz3d.js +1 -0
  1129. package/dist/polls-DKJOFSzJ.js +1 -0
  1130. package/dist/ports-B0XdGTfS.js +1 -0
  1131. package/dist/ports-BR0PLRtq.js +1 -0
  1132. package/dist/probe-auth-BMA0yM94.js +1 -0
  1133. package/dist/probe-auth-VI96zmTK.js +1 -0
  1134. package/dist/profile-utils-CWmra1aY.js +1 -0
  1135. package/dist/program-BrAZTwFr.js +1 -0
  1136. package/dist/program-context-B9ydtPje.js +1 -0
  1137. package/dist/program-context-CH9p6anW.js +1 -0
  1138. package/dist/progress-LNttnI-y.js +1 -0
  1139. package/dist/progress-d1m2sqR1.js +1 -0
  1140. package/dist/prompt-select-styled-BeJNbzSa.js +1 -0
  1141. package/dist/prompt-select-styled-DIOWLjl0.js +1 -0
  1142. package/dist/prompt-style-BThRSQJR.js +1 -0
  1143. package/dist/prompt-style-CXKekIBY.js +1 -0
  1144. package/dist/prompts-CMzglboN.js +1 -0
  1145. package/dist/prompts-wv-lfVrJ.js +1 -0
  1146. package/dist/provider-auth-helpers-1lU43eTW.js +1 -0
  1147. package/dist/provider-auth-helpers-pBVCjBj9.js +1 -0
  1148. package/dist/provider-env-vars-D8p6Ohpj.js +1 -0
  1149. package/dist/provider-env-vars-Dt0Q29Su.js +1 -0
  1150. package/dist/proxy-env-BNhTHkd_.js +1 -0
  1151. package/dist/proxy-env-DcmW_urA.js +1 -0
  1152. package/dist/proxy-env-DrC3TIGh.js +1 -0
  1153. package/dist/proxy-env-FJr5nlvs.js +1 -0
  1154. package/dist/proxy-fetch-BADsUK4d.js +1 -0
  1155. package/dist/proxy-fetch-BZ9O8Dvj.js +1 -0
  1156. package/dist/proxy-fetch-DnjU1fEB.js +1 -0
  1157. package/dist/proxy-fetch-gWETR3cl.js +1 -0
  1158. package/dist/push-apns-BGUOmD5M.js +1 -0
  1159. package/dist/push-apns-B_a2MBJ4.js +1 -0
  1160. package/dist/pw-ai-C-Ffkwai.js +1 -0
  1161. package/dist/pw-ai-CV1H1Vrs.js +1 -0
  1162. package/dist/pw-ai-D_MB1lrR.js +1 -0
  1163. package/dist/pw-ai-_l9lVice.js +1 -0
  1164. package/dist/qmd-manager-C_e04BNg.js +1 -0
  1165. package/dist/qmd-manager-DSQ_mDCl.js +1 -0
  1166. package/dist/qmd-manager-DcBYbt_V.js +1 -0
  1167. package/dist/qmd-manager-NLI0R6kp.js +1 -0
  1168. package/dist/qr-cli-3aG6CB6K.js +1 -0
  1169. package/dist/qr-cli-fiJxD5M4.js +1 -0
  1170. package/dist/query-expansion-0OxEb1Io.js +1 -0
  1171. package/dist/query-expansion-BUUx_oWg.js +1 -0
  1172. package/dist/query-expansion-r_iXkNzt.js +1 -0
  1173. package/dist/reaction-level-DVPHL14p.js +1 -0
  1174. package/dist/reaction-message-id-BEEe7X3D.js +1 -0
  1175. package/dist/read-only-account-inspect-DBwAwB3_.js +1 -0
  1176. package/dist/redact-3_CiXMY6.js +1 -0
  1177. package/dist/redact-CnRxK70G.js +1 -0
  1178. package/dist/register.agent-CX78s_X9.js +1 -0
  1179. package/dist/register.agent-DLDKQENq.js +1 -0
  1180. package/dist/register.backup-DkFoTcuT.js +1 -0
  1181. package/dist/register.backup-PzF5rmeU.js +1 -0
  1182. package/dist/register.configure-BA5u9hT3.js +1 -0
  1183. package/dist/register.configure-BhPtf3Qo.js +1 -0
  1184. package/dist/register.maintenance-BhsBepKS.js +1 -0
  1185. package/dist/register.maintenance-r_MzNK3-.js +1 -0
  1186. package/dist/register.message-CTF--Z2a.js +1 -0
  1187. package/dist/register.message-jcZ875be.js +1 -0
  1188. package/dist/register.onboard-C3yL50_c.js +1 -0
  1189. package/dist/register.onboard-CNwnStUk.js +1 -0
  1190. package/dist/register.setup-BRJMzgfU.js +1 -0
  1191. package/dist/register.setup-BvsS-zgm.js +1 -0
  1192. package/dist/register.status-health-sessions-DVc__2pc.js +1 -0
  1193. package/dist/register.status-health-sessions-Dqmkw820.js +1 -0
  1194. package/dist/register.subclis-D-24j83X.js +1 -0
  1195. package/dist/registry-BptzrW8D.js +1 -0
  1196. package/dist/registry-hFAtCSWG.js +1 -0
  1197. package/dist/render-BXEUPIHe.js +1 -0
  1198. package/dist/render-CBsnn-2A.js +1 -0
  1199. package/dist/render-D8OWO2hT.js +1 -0
  1200. package/dist/render-DrrPmnMI.js +1 -0
  1201. package/dist/reply-l-Y47HP4.js +1 -0
  1202. package/dist/restart-CHXEHdSC.js +1 -0
  1203. package/dist/rpc-B3ReBNXG.js +1 -0
  1204. package/dist/rpc-DumDLalJ.js +1 -0
  1205. package/dist/run-main-B_YBE_TN.js +1 -0
  1206. package/dist/runtime-BC5Ep2pJ.js +1 -0
  1207. package/dist/runtime-Dlg2-Omq.js +1 -0
  1208. package/dist/runtime-guard-DFYBaYZS.js +1 -0
  1209. package/dist/runtime-guard-DX2Ie4ri.js +1 -0
  1210. package/dist/runtime-status-CqFBmdRd.js +1 -0
  1211. package/dist/runtime-status-DszMjvJK.js +1 -0
  1212. package/dist/runtime-web-tools-D8fms06-.js +1 -0
  1213. package/dist/runtime-web-tools-bz76ZaRc.js +1 -0
  1214. package/dist/sandbox-cli-BDorUBm-.js +1 -0
  1215. package/dist/sandbox-cli-Bq40R5Vs.js +1 -0
  1216. package/dist/scan-paths-C13EseXp.js +1 -0
  1217. package/dist/scan-paths-CWtvWW40.js +1 -0
  1218. package/dist/search-manager-Bp9x20r6.js +1 -0
  1219. package/dist/secret-file-C7JffiM_.js +1 -0
  1220. package/dist/secret-file-D60EFEOe.js +1 -0
  1221. package/dist/secret-file-DuWm26jS.js +1 -0
  1222. package/dist/secrets-cli-Bo6PC32U.js +1 -0
  1223. package/dist/secrets-cli-CoXJv3Jp.js +1 -0
  1224. package/dist/secure-random-D7JQgiK-.js +1 -0
  1225. package/dist/security-cli-CgZL2KKh.js +1 -0
  1226. package/dist/security-cli-DVOfhwAP.js +1 -0
  1227. package/dist/send-B7sHR38c2.js +1 -0
  1228. package/dist/send-Bx2Qr7VH.js +1 -0
  1229. package/dist/send-C-AP01PR.js +1 -0
  1230. package/dist/send-C1CJ-GHU.js +1 -0
  1231. package/dist/send-C48Y9SAq.js +1 -0
  1232. package/dist/send-CVplsJpw.js +1 -0
  1233. package/dist/send-CW81y5Wz.js +1 -0
  1234. package/dist/send-CYgHok1p.js +1 -0
  1235. package/dist/send-Cgd_VJHR.js +1 -0
  1236. package/dist/send-Chz0YMoJ.js +1 -0
  1237. package/dist/send-D9hVVn7p2.js +1 -0
  1238. package/dist/send-DKrzj_Ts.js +1 -0
  1239. package/dist/send-DRLSCwCk.js +1 -0
  1240. package/dist/send-DavpkzhH.js +1 -0
  1241. package/dist/send-DbeEC2a3.js +1 -0
  1242. package/dist/send-DkiKKUkt.js +1 -0
  1243. package/dist/send-DlfVd5mL.js +1 -0
  1244. package/dist/send-JYgM9Sm-2.js +1 -0
  1245. package/dist/send-hZFDcGLM.js +1 -0
  1246. package/dist/send-vthbs31u.js +1 -0
  1247. package/dist/server-DpyBukwA.js +1 -0
  1248. package/dist/server-IgiSKzXH.js +1 -0
  1249. package/dist/server-node-events-CFSY_-4t.js +1 -0
  1250. package/dist/server-node-events-ZFwmPwQ-.js +1 -0
  1251. package/dist/service-BtB9epJk.js +1 -0
  1252. package/dist/service-DZ9EbS15.js +1 -0
  1253. package/dist/session-C9TDmUS7.js +1 -0
  1254. package/dist/session-CUUGjiV3.js +1 -0
  1255. package/dist/session-DA-i5xQ-.js +1 -0
  1256. package/dist/session-bk3gFwO4.js +1 -0
  1257. package/dist/session-cost-usage-BgqKixv0.js +1 -0
  1258. package/dist/session-cost-usage-CHtVgnE8.js +1 -0
  1259. package/dist/session-key-C7F_iqYg.js +1 -0
  1260. package/dist/session-key-D3P0tf5P.js +1 -0
  1261. package/dist/session-utils-8acNlxwP.js +1 -0
  1262. package/dist/sessions-BsxT0V2m.js +1 -0
  1263. package/dist/shared-9x5sqYRb.js +1 -0
  1264. package/dist/shared-BKWhOp64.js +1 -0
  1265. package/dist/shared-GesXrZzd.js +1 -0
  1266. package/dist/skill-commands-BWW6mc6t.js +1 -0
  1267. package/dist/skill-commands-CSF6wVPU.js +1 -0
  1268. package/dist/skill-commands-Db232ZRp.js +1 -0
  1269. package/dist/skill-commands-HJHHZqt6.js +1 -0
  1270. package/dist/skill-scanner-CUUF3Fvo.js +1 -0
  1271. package/dist/skill-scanner-CkxXNioD.js +1 -0
  1272. package/dist/skills-CKTicUKS.js +1 -0
  1273. package/dist/skills-DHbOKEGc.js +1 -0
  1274. package/dist/skills-cli-9Ls94z5H.js +1 -0
  1275. package/dist/skills-cli-BY7OhJzj.js +1 -0
  1276. package/dist/skills-install-CIdGCXSy.js +1 -0
  1277. package/dist/skills-install-DIdiVt9Y.js +1 -0
  1278. package/dist/skills-status-BWIugRCz.js +1 -0
  1279. package/dist/skills-status-DswSl5aD.js +1 -0
  1280. package/dist/sqlite-CILF3z9U.js +1 -0
  1281. package/dist/stagger-DmFYysrJ.js +1 -0
  1282. package/dist/stagger-DxzgG2jd.js +1 -0
  1283. package/dist/status-C-9fSiMn.js +1 -0
  1284. package/dist/status-CeBGmSAz.js +1 -0
  1285. package/dist/status-DYqPF0rB.js +1 -0
  1286. package/dist/status-JIPeVrsc.js +1 -0
  1287. package/dist/status.update-B_8Gumuc.js +1 -0
  1288. package/dist/status.update-DoSzHu2F.js +1 -0
  1289. package/dist/string-normalization-BrUPaXaM.js +1 -0
  1290. package/dist/string-normalization-DJT5zuUF.js +1 -0
  1291. package/dist/subsystem-BLbY429l.js +1 -0
  1292. package/dist/subsystem-Bc2XrjUz.js +1 -0
  1293. package/dist/subsystem-C5XF2Fy5.js +1 -0
  1294. package/dist/system-cli-CeZfoVPN.js +1 -0
  1295. package/dist/system-cli-DZkTYB9d.js +1 -0
  1296. package/dist/system-run-command-BKfMiqQM.js +1 -0
  1297. package/dist/system-run-command-DEWnZE0r.js +1 -0
  1298. package/dist/systemd-D7odsu4K.js +1 -0
  1299. package/dist/systemd-DbevZh65.js +1 -0
  1300. package/dist/systemd-hints-C0DKDl35.js +1 -0
  1301. package/dist/systemd-hints-lXpMy-kY.js +1 -0
  1302. package/dist/systemd-linger-C2MJD6KG.js +1 -0
  1303. package/dist/systemd-linger-cWKbFNpu.js +1 -0
  1304. package/dist/table-CR7TFMew.js +1 -0
  1305. package/dist/table-CY440fI1.js +1 -0
  1306. package/dist/tables-Brc2lNcB.js +1 -0
  1307. package/dist/tables-CrXdLc_6.js +1 -0
  1308. package/dist/tables-Oieq7UbT.js +1 -0
  1309. package/dist/tables-btcG3yFT.js +1 -0
  1310. package/dist/target-errors-CRlevJJ5.js +1 -0
  1311. package/dist/target-errors-CgWAJOam.js +1 -0
  1312. package/dist/target-errors-CpKXh2RS.js +1 -0
  1313. package/dist/target-errors-a35Md15n.js +1 -0
  1314. package/dist/targets-4EaxWBal.js +1 -0
  1315. package/dist/targets-BJTo7bqu.js +1 -0
  1316. package/dist/targets-BYVMrXDf.js +1 -0
  1317. package/dist/targets-Bq6rS6-Z.js +1 -0
  1318. package/dist/targets-CL5fYQi7.js +1 -0
  1319. package/dist/targets-fozeWOOg.js +1 -0
  1320. package/dist/targets-m_41k_Mv.js +1 -0
  1321. package/dist/telegram/audit.js +1 -0
  1322. package/dist/text-format-CvrvBBre.js +1 -0
  1323. package/dist/text-format-DEWK6oCT.js +1 -0
  1324. package/dist/token-DnTmiyJu.js +1 -0
  1325. package/dist/tokens-B2fq-rL6.js +1 -0
  1326. package/dist/tokens-CL2fSjGl.js +1 -0
  1327. package/dist/tokens-DRM8vzJx.js +1 -0
  1328. package/dist/tokens-XGbQGn67.js +1 -0
  1329. package/dist/tool-display-DJDtttQg.js +1 -0
  1330. package/dist/tool-display-DjuSUUbH.js +1 -0
  1331. package/dist/tui-B506apla.js +1 -0
  1332. package/dist/tui-CJUkUxHb.js +1 -0
  1333. package/dist/tui-cli-BEdGHmhc.js +1 -0
  1334. package/dist/tui-cli-Cq_eXDAV.js +1 -0
  1335. package/dist/types.secrets-C-5U96pc.js +1 -0
  1336. package/dist/types.secrets-D4tbc3Wq.js +1 -0
  1337. package/dist/update-BGrxUIyz.js +1 -0
  1338. package/dist/update-CwTy5DPl.js +1 -0
  1339. package/dist/update-cli-BwBMOeP0.js +1 -0
  1340. package/dist/update-cli-YrBbmw4f.js +1 -0
  1341. package/dist/update-runner-BvtyRBD2.js +1 -0
  1342. package/dist/update-runner-DYamgo1V.js +1 -0
  1343. package/dist/usage-format-BWD8FJFL.js +1 -0
  1344. package/dist/usage-format-yPwal8Iz.js +1 -0
  1345. package/dist/utils-CGdo13HV.js +1 -0
  1346. package/dist/utils-D3t-vPka.js +1 -0
  1347. package/dist/utils-R-mFyVJi.js +1 -0
  1348. package/dist/utils-UGOV_184.js +1 -0
  1349. package/dist/version-q3SkUw2K.js +1 -0
  1350. package/dist/warning-filter.js +1 -0
  1351. package/dist/web-Cq3xWCaD.js +1 -0
  1352. package/dist/web-DwcxsgH0.js +1 -0
  1353. package/dist/webhooks-cli-CIeyainW.js +1 -0
  1354. package/dist/webhooks-cli-DSNAve_D.js +1 -0
  1355. package/dist/whatsapp-actions-B6gt1KeB.js +1 -0
  1356. package/dist/whatsapp-actions-DACoH7qd.js +1 -0
  1357. package/dist/whatsapp-actions-iQhIeMya.js +1 -0
  1358. package/dist/whatsapp-actions-tmjID75a.js +1 -0
  1359. package/dist/widearea-dns-BDx7vkV2.js +1 -0
  1360. package/dist/widearea-dns-BFjqKXu_.js +1 -0
  1361. package/dist/windows-spawn-7oINn5ao.js +1 -0
  1362. package/dist/windows-spawn-AB7ItGAE.js +1 -0
  1363. package/dist/with-timeout-WveKxvFV.js +1 -0
  1364. package/dist/with-timeout-c1CzdShT.js +1 -0
  1365. package/dist/workspace-B0ZQeHXg.js +1 -0
  1366. package/dist/workspace-C45T1Cxg.js +1 -0
  1367. package/dist/workspace-dirs-A8Vib9_B.js +1 -0
  1368. package/dist/workspace-dirs-BhF1Dzxt.js +1 -0
  1369. package/dist/workspace-xNEpaJvu.js +1 -0
  1370. package/dist/wsl-DHxB2Ew_.js +1 -0
  1371. package/dist/wsl-Ok7GaSJ6.js +1 -0
  1372. package/node_modules/@aws-sdk/client-bedrock-runtime/package.json +2 -2
  1373. package/node_modules/@aws-sdk/token-providers/package.json +1 -1
  1374. package/node_modules/@grammyjs/types/package.json +1 -1
  1375. package/node_modules/@line/bot-sdk/dist/channel-access-token/api/channelAccessTokenClient.js +49 -3
  1376. package/node_modules/@line/bot-sdk/dist/cjs/channel-access-token/api/channelAccessTokenClient.js +49 -3
  1377. package/node_modules/@line/bot-sdk/dist/cjs/client.js +636 -0
  1378. package/node_modules/@line/bot-sdk/dist/cjs/endpoints.js +7 -0
  1379. package/node_modules/@line/bot-sdk/dist/cjs/exceptions.js +15 -1
  1380. package/node_modules/@line/bot-sdk/dist/cjs/http-axios.js +2 -6
  1381. package/node_modules/@line/bot-sdk/dist/cjs/http-fetch.js +5 -13
  1382. package/node_modules/@line/bot-sdk/dist/cjs/index.js +3 -1
  1383. package/node_modules/@line/bot-sdk/dist/cjs/insight/api/insightClient.js +3 -0
  1384. package/node_modules/@line/bot-sdk/dist/cjs/liff/api/liffClient.js +3 -0
  1385. package/node_modules/@line/bot-sdk/dist/cjs/line-bot-client.factory.generated.js +66 -0
  1386. package/node_modules/@line/bot-sdk/dist/cjs/line-bot-client.generated.js +1999 -0
  1387. package/node_modules/@line/bot-sdk/dist/cjs/line-bot-client.js +61 -0
  1388. package/node_modules/@line/bot-sdk/dist/cjs/manage-audience/api/manageAudienceBlobClient.js +3 -0
  1389. package/node_modules/@line/bot-sdk/dist/cjs/manage-audience/api/manageAudienceClient.js +3 -0
  1390. package/node_modules/@line/bot-sdk/dist/cjs/messaging-api/api/messagingApiBlobClient.js +3 -0
  1391. package/node_modules/@line/bot-sdk/dist/cjs/messaging-api/api/messagingApiClient.js +3 -0
  1392. package/node_modules/@line/bot-sdk/dist/cjs/module/api/lineModuleClient.js +3 -0
  1393. package/node_modules/@line/bot-sdk/dist/cjs/module-attach/api/lineModuleAttachClient.js +3 -0
  1394. package/node_modules/@line/bot-sdk/dist/cjs/shop/api/shopClient.js +3 -0
  1395. package/node_modules/@line/bot-sdk/dist/cjs/utils.js +10 -0
  1396. package/node_modules/@line/bot-sdk/dist/cjs/version.js +1 -1
  1397. package/node_modules/@line/bot-sdk/dist/client.js +636 -0
  1398. package/node_modules/@line/bot-sdk/dist/endpoints.js +7 -0
  1399. package/node_modules/@line/bot-sdk/dist/exceptions.js +15 -1
  1400. package/node_modules/@line/bot-sdk/dist/http-axios.js +2 -6
  1401. package/node_modules/@line/bot-sdk/dist/http-fetch.js +5 -13
  1402. package/node_modules/@line/bot-sdk/dist/index.js +1 -0
  1403. package/node_modules/@line/bot-sdk/dist/insight/api/insightClient.js +3 -0
  1404. package/node_modules/@line/bot-sdk/dist/liff/api/liffClient.js +3 -0
  1405. package/node_modules/@line/bot-sdk/dist/line-bot-client.factory.generated.js +63 -0
  1406. package/node_modules/@line/bot-sdk/dist/line-bot-client.generated.js +1995 -0
  1407. package/node_modules/@line/bot-sdk/dist/line-bot-client.js +58 -0
  1408. package/node_modules/@line/bot-sdk/dist/manage-audience/api/manageAudienceBlobClient.js +3 -0
  1409. package/node_modules/@line/bot-sdk/dist/manage-audience/api/manageAudienceClient.js +3 -0
  1410. package/node_modules/@line/bot-sdk/dist/messaging-api/api/messagingApiBlobClient.js +3 -0
  1411. package/node_modules/@line/bot-sdk/dist/messaging-api/api/messagingApiClient.js +3 -0
  1412. package/node_modules/@line/bot-sdk/dist/module/api/lineModuleClient.js +3 -0
  1413. package/node_modules/@line/bot-sdk/dist/module-attach/api/lineModuleAttachClient.js +3 -0
  1414. package/node_modules/@line/bot-sdk/dist/shop/api/shopClient.js +3 -0
  1415. package/node_modules/@line/bot-sdk/dist/utils.js +9 -0
  1416. package/node_modules/@line/bot-sdk/dist/version.js +1 -1
  1417. package/node_modules/@line/bot-sdk/package.json +10 -7
  1418. package/node_modules/@mariozechner/clipboard-linux-x64-gnu/clipboard.linux-x64-gnu.node +0 -0
  1419. package/node_modules/@mariozechner/clipboard-linux-x64-gnu/package.json +25 -0
  1420. package/node_modules/@mariozechner/clipboard-linux-x64-musl/clipboard.linux-x64-musl.node +0 -0
  1421. package/node_modules/@mariozechner/clipboard-linux-x64-musl/package.json +25 -0
  1422. package/node_modules/@slack/bolt/dist/App.js +22 -30
  1423. package/node_modules/@slack/bolt/dist/Assistant.js +21 -37
  1424. package/node_modules/@slack/bolt/dist/CustomFunction.js +1 -43
  1425. package/node_modules/@slack/bolt/dist/context/create-function-complete.js +23 -0
  1426. package/node_modules/@slack/bolt/dist/context/create-function-fail.js +23 -0
  1427. package/node_modules/@slack/bolt/dist/context/create-respond.js +11 -0
  1428. package/node_modules/@slack/bolt/dist/context/create-say-stream.js +16 -0
  1429. package/node_modules/@slack/bolt/dist/context/create-say.js +17 -0
  1430. package/node_modules/@slack/bolt/dist/context/create-set-status.js +21 -0
  1431. package/node_modules/@slack/bolt/dist/context/index.js +16 -0
  1432. package/node_modules/@slack/bolt/dist/helpers.js +79 -3
  1433. package/node_modules/@slack/bolt/dist/index.js +10 -8
  1434. package/node_modules/@slack/bolt/dist/receivers/SocketModeReceiver.js +5 -1
  1435. package/node_modules/@slack/bolt/dist/types/events/index.js +0 -4
  1436. package/node_modules/@slack/bolt/package.json +7 -7
  1437. package/node_modules/@smithy/config-resolver/package.json +10 -11
  1438. package/node_modules/@smithy/core/dist-cjs/getSmithyContext.js +6 -0
  1439. package/node_modules/@smithy/core/dist-cjs/index.js +1 -1
  1440. package/node_modules/@smithy/core/dist-cjs/middleware-http-auth-scheme/getHttpAuthSchemeEndpointRuleSetPlugin.js +21 -0
  1441. package/node_modules/@smithy/core/dist-cjs/middleware-http-auth-scheme/getHttpAuthSchemePlugin.js +21 -0
  1442. package/node_modules/@smithy/core/dist-cjs/middleware-http-auth-scheme/httpAuthSchemeMiddleware.js +46 -0
  1443. package/node_modules/@smithy/core/dist-cjs/middleware-http-auth-scheme/index.js +6 -0
  1444. package/node_modules/@smithy/core/dist-cjs/middleware-http-auth-scheme/resolveAuthOptions.js +24 -0
  1445. package/node_modules/@smithy/core/dist-cjs/middleware-http-signing/getHttpSigningMiddleware.js +19 -0
  1446. package/node_modules/@smithy/core/dist-cjs/middleware-http-signing/httpSigningMiddleware.js +27 -0
  1447. package/node_modules/@smithy/core/dist-cjs/middleware-http-signing/index.js +5 -0
  1448. package/node_modules/@smithy/core/dist-cjs/normalizeProvider.js +10 -0
  1449. package/node_modules/@smithy/core/dist-cjs/pagination/createPaginator.js +44 -0
  1450. package/node_modules/@smithy/core/dist-cjs/request-builder/requestBuilder.js +5 -0
  1451. package/node_modules/@smithy/core/dist-cjs/setFeature.js +14 -0
  1452. package/node_modules/@smithy/core/dist-cjs/util-identity-and-auth/DefaultIdentityProviderConfig.js +17 -0
  1453. package/node_modules/@smithy/core/dist-cjs/util-identity-and-auth/httpAuthSchemes/httpApiKeyAuth.js +38 -0
  1454. package/node_modules/@smithy/core/dist-cjs/util-identity-and-auth/httpAuthSchemes/httpBearerAuth.js +15 -0
  1455. package/node_modules/@smithy/core/dist-cjs/util-identity-and-auth/httpAuthSchemes/index.js +6 -0
  1456. package/node_modules/@smithy/core/dist-cjs/util-identity-and-auth/httpAuthSchemes/noAuth.js +9 -0
  1457. package/node_modules/@smithy/core/dist-cjs/util-identity-and-auth/index.js +6 -0
  1458. package/node_modules/@smithy/core/dist-cjs/util-identity-and-auth/memoizeIdentityProvider.js +61 -0
  1459. package/node_modules/@smithy/core/package.json +15 -16
  1460. package/node_modules/@smithy/credential-provider-imds/package.json +9 -10
  1461. package/node_modules/@smithy/eventstream-codec/dist-cjs/index.js +13 -0
  1462. package/node_modules/@smithy/eventstream-codec/package.json +6 -7
  1463. package/node_modules/@smithy/eventstream-serde-browser/package.json +7 -8
  1464. package/node_modules/@smithy/eventstream-serde-config-resolver/package.json +7 -8
  1465. package/node_modules/@smithy/eventstream-serde-node/package.json +7 -8
  1466. package/node_modules/@smithy/eventstream-serde-universal/package.json +9 -10
  1467. package/node_modules/@smithy/fetch-http-handler/package.json +12 -13
  1468. package/node_modules/@smithy/hash-node/package.json +6 -7
  1469. package/node_modules/@smithy/invalid-dependency/package.json +6 -7
  1470. package/node_modules/@smithy/middleware-content-length/package.json +7 -8
  1471. package/node_modules/@smithy/middleware-endpoint/dist-cjs/index.js +2 -2
  1472. package/node_modules/@smithy/middleware-endpoint/package.json +13 -14
  1473. package/node_modules/@smithy/middleware-retry/dist-cjs/index.js +70 -29
  1474. package/node_modules/@smithy/middleware-retry/dist-es/index.js +5 -4
  1475. package/node_modules/@smithy/middleware-retry/dist-es/longPollMiddleware.js +15 -0
  1476. package/node_modules/@smithy/middleware-retry/dist-es/parseRetryAfterHeader.js +49 -0
  1477. package/node_modules/@smithy/middleware-retry/dist-es/{StandardRetryStrategy.js → retry-pre-sra-deprecated/StandardRetryStrategy.js} +1 -1
  1478. package/node_modules/@smithy/middleware-retry/dist-es/retryMiddleware.js +13 -20
  1479. package/node_modules/@smithy/middleware-retry/package.json +16 -16
  1480. package/node_modules/@smithy/middleware-serde/package.json +10 -11
  1481. package/node_modules/@smithy/middleware-stack/package.json +7 -8
  1482. package/node_modules/@smithy/node-config-provider/package.json +8 -9
  1483. package/node_modules/@smithy/node-http-handler/package.json +10 -11
  1484. package/node_modules/@smithy/property-provider/package.json +6 -7
  1485. package/node_modules/@smithy/protocol-http/package.json +6 -7
  1486. package/node_modules/@smithy/querystring-builder/package.json +6 -7
  1487. package/node_modules/@smithy/querystring-parser/package.json +6 -7
  1488. package/node_modules/@smithy/service-error-classification/package.json +6 -7
  1489. package/node_modules/@smithy/shared-ini-file-loader/package.json +7 -8
  1490. package/node_modules/@smithy/signature-v4/dist-cjs/index.js +13 -0
  1491. package/node_modules/@smithy/signature-v4/package.json +9 -10
  1492. package/node_modules/@smithy/smithy-client/dist-cjs/index.js +1 -1
  1493. package/node_modules/@smithy/smithy-client/package.json +14 -15
  1494. package/node_modules/@smithy/types/package.json +7 -8
  1495. package/node_modules/@smithy/url-parser/package.json +7 -8
  1496. package/node_modules/@smithy/util-defaults-mode-browser/package.json +8 -9
  1497. package/node_modules/@smithy/util-defaults-mode-node/package.json +11 -12
  1498. package/node_modules/@smithy/util-endpoints/package.json +9 -10
  1499. package/node_modules/@smithy/util-middleware/package.json +6 -7
  1500. package/node_modules/@smithy/util-retry/dist-cjs/index.js +123 -76
  1501. package/node_modules/@smithy/util-retry/dist-es/AdaptiveRetryStrategy.js +7 -4
  1502. package/node_modules/@smithy/util-retry/dist-es/ConfiguredRetryStrategy.js +2 -2
  1503. package/node_modules/@smithy/util-retry/dist-es/DefaultRateLimiter.js +24 -25
  1504. package/node_modules/@smithy/util-retry/dist-es/DefaultRetryBackoffStrategy.js +14 -0
  1505. package/node_modules/@smithy/util-retry/dist-es/DefaultRetryToken.js +25 -0
  1506. package/node_modules/@smithy/util-retry/dist-es/StandardRetryStrategy.js +39 -26
  1507. package/node_modules/@smithy/util-retry/dist-es/index.js +1 -0
  1508. package/node_modules/@smithy/util-retry/dist-es/retries-2026-config.js +18 -0
  1509. package/node_modules/@smithy/util-retry/package.json +10 -11
  1510. package/node_modules/@smithy/util-stream/package.json +12 -13
  1511. package/node_modules/@snazzah/davey-linux-x64-gnu/davey.linux-x64-gnu.node +0 -0
  1512. package/node_modules/@snazzah/davey-linux-x64-gnu/package.json +43 -0
  1513. package/node_modules/@snazzah/davey-linux-x64-musl/davey.linux-x64-musl.node +0 -0
  1514. package/node_modules/@snazzah/davey-linux-x64-musl/package.json +43 -0
  1515. package/node_modules/dotenv/lib/main.js +1 -1
  1516. package/node_modules/dotenv/package.json +1 -1
  1517. package/node_modules/dotenv/skills/dotenv/SKILL.md +32 -52
  1518. package/node_modules/dotenv/skills/dotenvx/SKILL.md +57 -273
  1519. package/node_modules/grammy/out/bot.js +1 -0
  1520. package/node_modules/grammy/out/context.js +35 -0
  1521. package/node_modules/grammy/out/convenience/keyboard.js +30 -2
  1522. package/node_modules/grammy/out/core/api.js +34 -0
  1523. package/node_modules/grammy/out/filter.js +6 -2
  1524. package/node_modules/grammy/out/web.mjs +58 -10
  1525. package/node_modules/grammy/package.json +2 -2
  1526. package/node_modules/lru-cache/dist/commonjs/diagnostics-channel.js +12 -0
  1527. package/node_modules/lru-cache/dist/commonjs/index.js +227 -130
  1528. package/node_modules/lru-cache/dist/commonjs/index.min.js +1 -1
  1529. package/node_modules/lru-cache/dist/esm/diagnostics-channel-esm.d.mts.map +1 -0
  1530. package/node_modules/lru-cache/dist/esm/diagnostics-channel.js +17 -0
  1531. package/node_modules/lru-cache/dist/esm/index.js +227 -130
  1532. package/node_modules/lru-cache/dist/esm/index.min.js +1 -1
  1533. package/node_modules/lru-cache/dist/esm/node/diagnostics-channel-node.d.mts.map +1 -0
  1534. package/node_modules/lru-cache/dist/esm/node/diagnostics-channel.js +8 -0
  1535. package/node_modules/lru-cache/dist/esm/node/index.js +1688 -0
  1536. package/node_modules/lru-cache/dist/esm/node/index.min.js +2 -0
  1537. package/node_modules/lru-cache/package.json +29 -9
  1538. package/node_modules/netmask/dist/netmask.js +58 -0
  1539. package/node_modules/netmask/dist/netmask4.js +189 -0
  1540. package/node_modules/netmask/dist/netmask6.js +187 -0
  1541. package/node_modules/netmask/package.json +15 -6
  1542. package/node_modules/path-expression-matcher/lib/pem.cjs +1 -1
  1543. package/node_modules/path-expression-matcher/lib/pem.d.cts +93 -0
  1544. package/node_modules/path-expression-matcher/lib/pem.min.js +1 -1
  1545. package/node_modules/path-expression-matcher/package.json +1 -1
  1546. package/node_modules/path-expression-matcher/src/ExpressionSet.js +189 -0
  1547. package/node_modules/path-expression-matcher/src/Matcher.js +50 -20
  1548. package/node_modules/path-expression-matcher/src/index.js +3 -2
  1549. package/node_modules/strnum/package.json +1 -1
  1550. package/package.json +1 -1
  1551. package/preset-config.json +12 -0
  1552. package/node_modules/@smithy/util-retry/dist-es/defaultRetryBackoffStrategy.js +0 -14
  1553. package/node_modules/@smithy/util-retry/dist-es/defaultRetryToken.js +0 -11
  1554. package/node_modules/netmask/CREDITS.md +0 -30
  1555. package/node_modules/netmask/lib/netmask.coffee +0 -167
  1556. package/node_modules/netmask/lib/netmask.js +0 -208
  1557. package/node_modules/strnum/.github/SECURITY.md +0 -5
  1558. package/node_modules/strnum/.vscode/launch.json +0 -25
  1559. package/node_modules/strnum/algo.stflow +0 -84
  1560. package/skills/sherpa-onnx-tts/bin/sherpa-onnx-tts +0 -178
  1561. /package/node_modules/@smithy/middleware-retry/dist-es/{AdaptiveRetryStrategy.js → retry-pre-sra-deprecated/AdaptiveRetryStrategy.js} +0 -0
  1562. /package/node_modules/@smithy/middleware-retry/dist-es/{defaultRetryQuota.js → retry-pre-sra-deprecated/defaultRetryQuota.js} +0 -0
  1563. /package/node_modules/@smithy/middleware-retry/dist-es/{delayDecider.js → retry-pre-sra-deprecated/delayDecider.js} +0 -0
  1564. /package/node_modules/@smithy/middleware-retry/dist-es/{retryDecider.js → retry-pre-sra-deprecated/retryDecider.js} +0 -0
  1565. /package/node_modules/@smithy/middleware-retry/dist-es/{types.js → retry-pre-sra-deprecated/types.js} +0 -0
@@ -3,3 +3,4 @@ import{J as e,O as t,_ as n,g as r,i,y as a}from"./logger-C210xuWx.js";import{c
3
3
  `);function wr(e){let t=e.trim().split(/\r?\n/).map(e=>e.trim()).filter(Boolean).at(-1);if(!t)throw Error(`Pinned write helper returned no identity`);let[n,r]=t.split(`|`),i=Number.parseInt(n??``,10),a=Number.parseInt(r??``,10);if(!Number.isFinite(i)||!Number.isFinite(a))throw Error(`Pinned write helper returned invalid identity: ${t}`);return{dev:i,ino:a}}async function Tr(e){let t=u(`python3`,[`-c`,Cr,e.rootPath,e.relativeParentPath,e.basename,e.mkdir?`1`:`0`,(e.mode||384).toString(8)],{stdio:[`pipe`,`pipe`,`pipe`]}),n=``,r=``;t.stdout.setEncoding?.(`utf8`),t.stderr.setEncoding?.(`utf8`),t.stdout.on(`data`,e=>{n+=e}),t.stderr.on(`data`,e=>{r+=e});let i=g(t,`close`);try{if(!t.stdin){let t=await Er(e);return await i.catch(()=>{}),t}if(e.input.kind===`buffer`){let n=e.input;await new Promise((e,r)=>{if(t.stdin.once(`error`,r),typeof n.data==`string`){t.stdin.end(n.data,n.encoding??`utf8`,()=>e());return}t.stdin.end(n.data,()=>e())})}else await _(e.input.stream,t.stdin);let[a,o]=await i;if(a!==0)throw Error(r.trim()||`Pinned write helper failed with code ${a??`null`} (${o??`?`})`);return wr(n)}catch(e){throw t.kill(`SIGKILL`),await i.catch(()=>{}),e}}async function Er(e){let t=e.relativeParentPath?l.join(e.rootPath,...e.relativeParentPath.split(`/`)):e.rootPath;e.mkdir&&await m.mkdir(t,{recursive:!0});let n=l.join(t,e.basename),r=l.join(t,`.${e.basename}.fallback.tmp`);if(e.input.kind===`buffer`)typeof e.input.data==`string`?await m.writeFile(r,e.input.data,{encoding:e.input.encoding??`utf8`,mode:e.mode}):await m.writeFile(r,e.input.data,{mode:e.mode});else{let t=await m.open(r,`w`,e.mode);try{await _(e.input.stream,t.createWriteStream())}finally{await t.close().catch(()=>{})}}await m.rename(r,n);let i=await m.stat(n);return{dev:i.dev,ino:i.ino}}var W=class extends Error{constructor(e,t,n){super(t,n),this.code=e,this.name=`SafeOpenError`}};const G=process.platform!==`win32`&&`O_NOFOLLOW`in f,Dr=f.O_RDONLY|(G?f.O_NOFOLLOW:0),Or=f.O_WRONLY|(G?f.O_NOFOLLOW:0),kr=f.O_WRONLY|f.O_CREAT|f.O_EXCL|(G?f.O_NOFOLLOW:0),Ar=f.O_RDWR|f.O_APPEND|(G?f.O_NOFOLLOW:0),jr=f.O_RDWR|f.O_APPEND|f.O_CREAT|f.O_EXCL|(G?f.O_NOFOLLOW:0),Mr=e=>e.endsWith(l.sep)?e:e+l.sep;async function Nr(e){let t=process.env.HOME||process.env.USERPROFILE||p.homedir();try{t=await m.realpath(t)}catch{}return c(e,{home:t})}async function K(e,t){try{if((await m.lstat(e)).isDirectory())throw new W(`not-file`,`not a file`)}catch(e){if(e instanceof W)throw e}let n;try{n=await m.open(e,Dr)}catch(e){throw w(e)?new W(`not-found`,`file not found`):Qe(e)?new W(`symlink`,`symlink open blocked`,{cause:e}):Ze(e,`EISDIR`)?new W(`not-file`,`not a file`):e}try{let[r,i]=await Promise.all([n.stat(),m.lstat(e)]);if(i.isSymbolicLink())throw new W(`symlink`,`symlink not allowed`);if(!r.isFile())throw new W(`not-file`,`not a file`);if(t?.rejectHardlinks&&r.nlink>1)throw new W(`invalid-path`,`hardlinked path not allowed`);if(!k(r,i))throw new W(`path-mismatch`,`path changed during read`);let a=await m.realpath(e),o=await m.stat(a);if(t?.rejectHardlinks&&o.nlink>1)throw new W(`invalid-path`,`hardlinked path not allowed`);if(!k(r,o))throw new W(`path-mismatch`,`path mismatch`);return{handle:n,realPath:a,stat:r}}catch(e){throw await n.close().catch(()=>{}),e instanceof W?e:w(e)?new W(`not-found`,`file not found`):e}}async function Pr(e){let t;try{t=await m.realpath(e.rootDir)}catch(e){throw w(e)?new W(`not-found`,`root dir not found`):e}let n=Mr(t),r=await Nr(e.relativePath),i=l.resolve(n,r);if(!T(n,i))throw new W(`outside-workspace`,`file is outside workspace root`);return{rootReal:t,rootWithSep:n,resolved:i}}async function Fr(e){let{rootWithSep:t,resolved:n}=await Pr(e),r;try{r=await K(n)}catch(e){throw e instanceof W?e.code===`not-found`?e:new W(`invalid-path`,`path is not a regular file under root`,{cause:e}):e}if(e.rejectHardlinks!==!1&&r.stat.nlink>1)throw await r.handle.close().catch(()=>{}),new W(`invalid-path`,`hardlinked path not allowed`);if(!T(t,r.realPath))throw await r.handle.close().catch(()=>{}),new W(`outside-workspace`,`file is outside workspace root`);return r}async function Ir(e){let t=await Fr({rootDir:e.rootDir,relativePath:e.relativePath,rejectHardlinks:e.rejectHardlinks});try{return await Br({opened:t,maxBytes:e.maxBytes})}finally{await t.handle.close().catch(()=>{})}}async function Lr(e){let t=l.resolve(e.rootDir),n=l.isAbsolute(e.filePath)?l.resolve(e.filePath):l.resolve(t,e.filePath);return await Ir({rootDir:t,relativePath:l.relative(t,n),rejectHardlinks:e.rejectHardlinks,maxBytes:e.maxBytes})}function Rr(e){let t=l.resolve(e.rootDir);return async n=>(await Lr({rootDir:t,filePath:n,rejectHardlinks:e.rejectHardlinks,maxBytes:e.maxBytes})).buffer}async function zr(e){let t=await K(e.filePath);try{return await Br({opened:t,maxBytes:e.maxBytes})}finally{await t.handle.close().catch(()=>{})}}async function Br(e){if(e.maxBytes!==void 0&&e.opened.stat.size>e.maxBytes)throw new W(`too-large`,`file exceeds limit of ${e.maxBytes} bytes (got ${e.opened.stat.size})`);return{buffer:await e.opened.handle.readFile(),realPath:e.opened.realPath,stat:e.opened.stat}}function q(e){i(`security: fs-safe write boundary warning (${e})`)}function Vr(e){let t=l.dirname(e),n=l.basename(e);return l.join(t,`.${n}.${process.pid}.${ne()}.tmp`)}async function Hr(e){let t=await m.open(e.tempPath,kr,e.mode);try{return typeof e.data==`string`?await t.writeFile(e.data,e.encoding??`utf8`):await t.writeFile(e.data),await t.stat()}finally{await t.close().catch(()=>{})}}async function J(e){let t=Mr(await m.realpath(e.rootDir)),n=await K(e.targetPath,{rejectHardlinks:!0});try{if(!k(n.stat,e.expectedIdentity))throw new W(`path-mismatch`,`path changed during write`);if(!T(t,n.realPath))throw new W(`outside-workspace`,`file is outside workspace root`)}finally{await n.handle.close().catch(()=>{})}}async function Ur(e,t){try{return await m.realpath(t)}catch(e){if(!w(e))throw e}let n=process.platform===`linux`?[`/proc/self/fd/${e.fd}`,`/dev/fd/${e.fd}`]:process.platform===`win32`?[]:[`/dev/fd/${e.fd}`];for(let e of n)try{return await m.realpath(e)}catch{}throw new W(`path-mismatch`,`unable to resolve opened file path`)}async function Wr(e){let{rootReal:t,rootWithSep:n,resolved:r}=await Pr(e);try{await Sr({absolutePath:r,rootPath:t,boundaryLabel:`root`})}catch(e){throw new W(`invalid-path`,`path alias escape blocked`,{cause:e})}e.mkdir!==!1&&await m.mkdir(l.dirname(r),{recursive:!0});let i=r;try{let e=await m.realpath(r);if(!T(n,e))throw new W(`outside-workspace`,`file is outside workspace root`);i=e}catch(e){if(e instanceof W||!w(e))throw e}let a=e.mode??384,o,s=!1,c=e.append?Ar:Or,u=e.append?jr:kr;try{try{o=await m.open(i,c,a)}catch(e){if(!w(e))throw e;o=await m.open(i,u,a),s=!0}}catch(e){throw w(e)?new W(`not-found`,`file not found`):Qe(e)?new W(`invalid-path`,`symlink open blocked`,{cause:e}):e}let d=null;try{let t=await o.stat();if(!t.isFile())throw new W(`invalid-path`,`path is not a regular file under root`);if(t.nlink>1)throw new W(`invalid-path`,`hardlinked path not allowed`);try{let e=await m.lstat(i);if(e.isSymbolicLink()||!e.isFile())throw new W(`invalid-path`,`path is not a regular file under root`);if(!k(t,e))throw new W(`path-mismatch`,`path changed during write`)}catch(e){if(!w(e))throw e}let r=await Ur(o,i);d=r;let a=await m.stat(r);if(!k(t,a))throw new W(`path-mismatch`,`path mismatch`);if(a.nlink>1)throw new W(`invalid-path`,`hardlinked path not allowed`);if(!T(n,r))throw new W(`outside-workspace`,`file is outside workspace root`);return e.append!==!0&&e.truncateExisting!==!1&&!s&&await o.truncate(0),{handle:o,createdForWrite:s,openedRealPath:r,openedStat:t}}catch(e){let t=s&&e instanceof W,n=d??i;throw await o.close().catch(()=>{}),t&&await m.rm(n,{force:!0}).catch(()=>{}),e}}async function Gr(e){let t=await Wr({rootDir:e.rootDir,relativePath:e.relativePath,mkdir:e.mkdir,truncateExisting:!1,append:!0});try{let n=``;if(e.prependNewlineIfNeeded===!0&&!t.createdForWrite&&t.openedStat.size>0&&(typeof e.data==`string`&&!e.data.startsWith(`
4
4
  `)||Buffer.isBuffer(e.data)&&e.data.length>0&&e.data[0]!==10)){let e=Buffer.alloc(1),{bytesRead:r}=await t.handle.read(e,0,1,t.openedStat.size-1);r===1&&e[0]!==10&&(n=`
5
5
  `)}if(typeof e.data==`string`){await t.handle.appendFile(`${n}${e.data}`,e.encoding??`utf8`);return}let r=n.length>0?Buffer.concat([Buffer.from(n,`utf8`),e.data]):e.data;await t.handle.appendFile(r)}finally{await t.handle.close().catch(()=>{})}}async function Kr(e){if(process.platform===`win32`){await Zr(e);return}let t=await Yr({rootDir:e.rootDir,relativePath:e.relativePath}),n=await Tr({rootPath:t.rootReal,relativeParentPath:t.relativeParentPath,basename:t.basename,mkdir:e.mkdir!==!1,mode:t.mode,input:{kind:`buffer`,data:e.data,encoding:e.encoding}}).catch(e=>{throw Xr(e)});try{await J({rootDir:e.rootDir,targetPath:t.targetPath,expectedIdentity:n})}catch(e){throw q(`post-write verification failed: ${String(e)}`),e}}async function qr(e){let t=await K(e.sourcePath,{rejectHardlinks:e.rejectSourceHardlinks});if(e.maxBytes!==void 0&&t.stat.size>e.maxBytes)throw await t.handle.close().catch(()=>{}),new W(`too-large`,`file exceeds limit of ${e.maxBytes} bytes (got ${t.stat.size})`);try{if(process.platform===`win32`){await Qr(e,t);return}let n=await Yr({rootDir:e.rootDir,relativePath:e.relativePath}),r=t.handle.createReadStream(),i=await Tr({rootPath:n.rootReal,relativeParentPath:n.relativeParentPath,basename:n.basename,mkdir:e.mkdir!==!1,mode:n.mode,input:{kind:`stream`,stream:r}}).catch(e=>{throw Xr(e)});try{await J({rootDir:e.rootDir,targetPath:n.targetPath,expectedIdentity:i})}catch(e){throw q(`post-copy verification failed: ${String(e)}`),e}}finally{await t.handle.close().catch(()=>{})}}async function Jr(e){await qr({sourcePath:e.sourcePath,rootDir:e.rootDir,relativePath:e.relativePath,mkdir:e.mkdir,rejectSourceHardlinks:!0})}async function Yr(e){let{rootReal:t,rootWithSep:n,resolved:r}=await Pr(e);try{await Sr({absolutePath:r,rootPath:t,boundaryLabel:`root`})}catch(e){throw new W(`invalid-path`,`path alias escape blocked`,{cause:e})}let i=l.relative(t,r);if(i.startsWith(`..`)||l.isAbsolute(i))throw new W(`outside-workspace`,`file is outside workspace root`);let a=i?i.split(l.sep).join(l.posix.sep):``,o=l.posix.basename(a);if(!o||o===`.`||o===`/`)throw new W(`invalid-path`,`invalid target path`);let s=384;try{let t=await Fr({rootDir:e.rootDir,relativePath:e.relativePath,rejectHardlinks:!0});try{if(s=t.stat.mode&511,!T(n,t.realPath))throw new W(`outside-workspace`,`file is outside workspace root`)}finally{await t.handle.close().catch(()=>{})}}catch(e){if(!(e instanceof W)||e.code!==`not-found`)throw e}return{rootReal:t,targetPath:r,relativeParentPath:l.posix.dirname(a)===`.`?``:l.posix.dirname(a),basename:o,mode:s||384}}function Xr(e){return e instanceof W?e:new W(`invalid-path`,`path is not a regular file under root`,{cause:e instanceof Error?e:void 0})}async function Zr(e){let t=await Wr({rootDir:e.rootDir,relativePath:e.relativePath,mkdir:e.mkdir,truncateExisting:!1}),n=t.openedRealPath,r=t.openedStat.mode&511;await t.handle.close().catch(()=>{});let i=null;try{i=Vr(n);let t=await Hr({tempPath:i,data:e.data,encoding:e.encoding,mode:r||384});await m.rename(i,n),i=null;try{await J({rootDir:e.rootDir,targetPath:n,expectedIdentity:t})}catch(e){throw q(`post-write verification failed: ${String(e)}`),e}}finally{i&&await m.rm(i,{force:!0}).catch(()=>{})}}async function Qr(e,t){let n=null,r=!1,i=!1,a=null,o=null,s=!1;try{n=await Wr({rootDir:e.rootDir,relativePath:e.relativePath,mkdir:e.mkdir,truncateExisting:!1});let c=n.openedRealPath,l=n.openedStat.mode&511;await n.handle.close().catch(()=>{}),i=!0,o=Vr(c),a=await m.open(o,kr,l||384);let u=t.handle.createReadStream(),d=a.createWriteStream();u.once(`close`,()=>{r=!0}),d.once(`close`,()=>{s=!0}),await import(`node:stream/promises`).then(({pipeline:e})=>e(u,d));let f=await m.stat(o);s||=(await a.close().catch(()=>{}),!0),a=null,await m.rename(o,c),o=null;try{await J({rootDir:e.rootDir,targetPath:c,expectedIdentity:f})}catch(e){throw q(`post-copy verification failed: ${String(e)}`),e}}catch(e){throw n?.createdForWrite&&await m.rm(n.openedRealPath,{force:!0}).catch(()=>{}),e}finally{o&&await m.rm(o,{force:!0}).catch(()=>{}),r||await t.handle.close().catch(()=>{}),a&&!s&&await a.close().catch(()=>{}),n&&!i&&await n.handle.close().catch(()=>{})}}const $r=6*1024*1024,ei=100*1024*1024;function ti(e){if(e){if(e.startsWith(`image/`))return`image`;if(e.startsWith(`audio/`))return`audio`;if(e.startsWith(`video/`))return`video`;if(e===`application/pdf`||e.startsWith(`text/`)||e.startsWith(`application/`))return`document`}}function ni(e){switch(e){case`image`:return $r;case`audio`:return 16777216;case`video`:return 16777216;case`document`:return ei;default:return ei}}const ri={"image/heic":`.heic`,"image/heif":`.heif`,"image/jpeg":`.jpg`,"image/png":`.png`,"image/webp":`.webp`,"image/gif":`.gif`,"audio/ogg":`.ogg`,"audio/mpeg":`.mp3`,"audio/wav":`.wav`,"audio/flac":`.flac`,"audio/aac":`.aac`,"audio/opus":`.opus`,"audio/x-m4a":`.m4a`,"audio/mp4":`.m4a`,"video/mp4":`.mp4`,"video/quicktime":`.mov`,"application/pdf":`.pdf`,"application/json":`.json`,"application/zip":`.zip`,"application/gzip":`.gz`,"application/x-tar":`.tar`,"application/x-7z-compressed":`.7z`,"application/vnd.rar":`.rar`,"application/msword":`.doc`,"application/vnd.ms-excel":`.xls`,"application/vnd.ms-powerpoint":`.ppt`,"application/vnd.openxmlformats-officedocument.wordprocessingml.document":`.docx`,"application/vnd.openxmlformats-officedocument.spreadsheetml.sheet":`.xlsx`,"application/vnd.openxmlformats-officedocument.presentationml.presentation":`.pptx`,"text/csv":`.csv`,"text/plain":`.txt`,"text/markdown":`.md`},ii={...Object.fromEntries(Object.entries(ri).map(([e,t])=>[t,e])),".jpeg":`image/jpeg`,".js":`text/javascript`},ai=new Set([`.aac`,`.caf`,`.flac`,`.m4a`,`.mp3`,`.oga`,`.ogg`,`.opus`,`.wav`]);function Y(e){if(e)return e.split(`;`)[0]?.trim().toLowerCase()||void 0}async function oi(e){if(e)try{return(await v(e))?.mime??void 0}catch{return}}function X(e){if(e){try{if(/^https?:\/\//i.test(e)){let t=new URL(e);return l.extname(t.pathname).toLowerCase()||void 0}}catch{}return l.extname(e).toLowerCase()||void 0}}function si(e){let t=X(e);return t?ai.has(t):!1}function ci(e){return ui(e)}function li(e){if(!e)return!0;let t=e.toLowerCase();return t===`application/octet-stream`||t===`application/zip`}async function ui(e){let t=X(e.filePath),n=t?ii[t]:void 0,r=Y(e.headerMime),i=await oi(e.buffer);if(i&&(!li(i)||!n))return i;if(n)return n;if(r&&!li(r))return r;if(i)return i;if(r)return r}function di(e){let t=Y(e);if(t)return ri[t]}function fi(e){return e.contentType?.toLowerCase()===`image/gif`?!0:X(e.fileName)===`.gif`}function pi(e){if(e)switch(e.toLowerCase()){case`jpg`:case`jpeg`:return`image/jpeg`;case`heic`:return`image/heic`;case`heif`:return`image/heif`;case`png`:return`image/png`;case`webp`:return`image/webp`;case`gif`:return`image/gif`;default:return}}function mi(e){return ti(Y(e))}function Z(e){try{return te(e).isFile()}catch{return!1}}function hi(e,t){if(e.includes(`/`)||e.includes(`\\`)||l.isAbsolute(e))return e;let n=(t.PATH??t.Path??process.env.PATH??process.env.Path??``).split(`;`).map(e=>e.trim()).filter(Boolean),r=l.extname(e).length>0,i=t.PATHEXT??t.Pathext??process.env.PATHEXT??process.env.Pathext??`.EXE;.CMD;.BAT;.COM`,a=r?[``]:i.split(`;`).map(e=>e.trim()).filter(Boolean).map(e=>e.startsWith(`.`)?e:`.${e}`);for(let t of n)for(let n of a)for(let r of[n,n.toLowerCase(),n.toUpperCase()]){let n=l.join(t,`${e}${r}`);if(Z(n))return n}return e}function gi(e){if(!Z(e))return null;try{let t=ee(e,`utf8`),n=[];for(let r of t.matchAll(/"([^"\r\n]*)"/g)){let t=(r[1]??``).match(/%~?dp0%?\s*[\\/]*(.*)$/i)?.[1]?.trim();if(!t)continue;let i=t.replace(/[\\/]+/g,l.sep).replace(/^[\\/]+/,``),a=l.resolve(l.dirname(e),i);Z(a)&&n.push(a)}return n.find(e=>{let t=l.basename(e).toLowerCase();return t!==`node.exe`&&t!==`node`})??null}catch{return null}}function _i(e,t){if(typeof t==`string`)return t.trim()||null;if(!t||typeof t!=`object`)return null;if(e){let n=t[e];if(typeof n==`string`&&n.trim())return n.trim()}for(let e of Object.values(t))if(typeof e==`string`&&e.trim())return e.trim();return null}function vi(e,t){if(!t)return null;let n=l.dirname(e),r=[l.resolve(n,`..`,t),l.resolve(n,`node_modules`,t)];for(let e of r){let n=l.join(e,`package.json`);if(Z(n))try{let r=_i(t,JSON.parse(ee(n,`utf8`)).bin);if(!r)continue;let i=l.resolve(e,r);if(Z(i))return i}catch{}}return null}function yi(e){let t=e.platform??process.platform,n=e.env??process.env,r=e.execPath??process.execPath;if(t!==`win32`)return{command:e.command,leadingArgv:[],resolution:`direct`};let i=hi(e.command,n),a=l.extname(i).toLowerCase();if(a===`.js`||a===`.cjs`||a===`.mjs`)return{command:r,leadingArgv:[i],resolution:`node-entrypoint`,windowsHide:!0};if(a===`.cmd`||a===`.bat`){let t=gi(i)??vi(i,e.packageName);return t?l.extname(t).toLowerCase()===`.exe`?{command:t,leadingArgv:[],resolution:`exe-entrypoint`,windowsHide:!0}:{command:r,leadingArgv:[t],resolution:`node-entrypoint`,windowsHide:!0}:{command:i,leadingArgv:[],resolution:`unresolved-wrapper`}}return{command:i,leadingArgv:[],resolution:`direct`}}function bi(e){if(e.candidate.resolution!==`unresolved-wrapper`)return{command:e.candidate.command,leadingArgv:e.candidate.leadingArgv,resolution:e.candidate.resolution,windowsHide:e.candidate.windowsHide};if(e.allowShellFallback!==!1)return{command:e.candidate.command,leadingArgv:[],resolution:`shell-fallback`,shell:!0};throw Error(`${l.basename(e.candidate.command)} wrapper resolved, but no executable/Node entrypoint could be resolved without shell execution.`)}function xi(e){return bi({candidate:yi(e),allowShellFallback:e.allowShellFallback})}function Si(e,t){return{command:e.command,argv:[...e.leadingArgv,...t],resolution:e.resolution,shell:e.shell,windowsHide:e.windowsHide}}function Q(e,t=process.env,n=()=>s(t,p.homedir)){let r=o(t,n),i=C(e??`main`);return l.join(r,`agents`,i,`sessions`)}function Ci(e,t=process.env,n=()=>s(t,p.homedir)){return Q(e,t,n)}function wi(e){return l.join(Q(e),`sessions.json`)}function Ti(e){let t=e.agentId?.trim(),n=e.storePath?.trim();if(n&&n!==`(multiple)`){let e=l.dirname(l.resolve(n));return t?{sessionsDir:e,agentId:t}:{sessionsDir:e}}if(t)return{agentId:t}}const Ei=/^[a-z0-9][a-z0-9._-]{0,127}$/i;function Di(e){let t=e.trim();if(!Ei.test(t))throw Error(`Invalid session ID: ${e}`);return t}function Oi(e){let t=e?.sessionsDir?.trim();return t?l.resolve(t):Q(e?.agentId)}function ki(e,t){let n=$(l.resolve(e))??l.resolve(e),r=$(t)??t,i=l.relative(n,r);if(!(!i||i.startsWith(`..`)||l.isAbsolute(i)))return l.resolve(n,i)}function Ai(e,t){let n=l.resolve(e);if(l.basename(n)!==`sessions`)return;let r=l.dirname(n),i=l.dirname(r);if(l.basename(i)!==`agents`)return;let a=l.dirname(i);return l.join(a,`agents`,C(t),`sessions`)}function ji(e){let t=l.normalize(l.resolve(e)).split(l.sep).filter(Boolean),n=t.lastIndexOf(`sessions`);return n<2||t[n-2]!==`agents`?null:{parts:t,sessionsIndex:n}}function Mi(e){let t=ji(e);if(!t)return;let{parts:n,sessionsIndex:r}=t;return n[r-1]||void 0}function Ni(e,t){let n=ji(e);if(!n)return;let{parts:r,sessionsIndex:i}=n,a=r[i-1];if(!a)return;let o=C(a);if(o!==a.toLowerCase()||o!==C(t))return;let s=r.slice(i+1);if(s.length!==1)return;let c=s[0];if(!(!c||c===`.`||c===`..`))return l.normalize(l.resolve(e))}function $(e){try{return d.realpathSync(e)}catch{return}}function Pi(e,t,n){let r=t.trim();if(!r)throw Error(`Session file path must not be empty`);let i=l.resolve(e),a=$(i)??i,o=l.isAbsolute(r)?$(r)??r:r,s=l.isAbsolute(o)?l.relative(a,o):o;if(s.startsWith(`..`)&&l.isAbsolute(o)){let e=e=>{let t=C(e),n=Ai(a,t);if(n){let e=ki(n,o);if(e)return e}return ki(Q(t),o)},t=n?.agentId?.trim();if(t){let n=e(t);if(n)return n}let r=Mi(o);if(r){let t=e(r);if(t)return t;let n=Ni(o,r);if(n)return n}}if(!s||s.startsWith(`..`)||l.isAbsolute(s))throw Error(`Session file path must be within sessions directory`);return l.resolve(a,s)}function Fi(e,t,n){let r=Di(e),i=typeof n==`string`?encodeURIComponent(n):typeof n==`number`?String(n):void 0;return Pi(t,i===void 0?`${r}.jsonl`:`${r}-topic-${i}.jsonl`)}function Ii(e,t,n){return Fi(e,Q(t),n)}function Li(e,t,n){let r=Oi(n),i=t?.sessionFile?.trim();if(i)try{return Pi(r,i,{agentId:n?.agentId})}catch{}return Fi(e,r)}function Ri(e,t){let n=C(t?.agentId??`main`);if(!e)return wi(n);if(e.includes(`{agentId}`)){let t=e.replaceAll(`{agentId}`,n);return t.startsWith(`~`)?l.resolve(c(t,{home:s(process.env,p.homedir),env:process.env,homedir:p.homedir})):l.resolve(t)}return e.startsWith(`~`)?l.resolve(c(e,{home:s(process.env,p.homedir),env:process.env,homedir:p.homedir})):l.resolve(e)}export{L as $,xr as A,je as At,H as B,xe as Bt,qr as C,ze as Ct,zr as D,Pe as Dt,Ir as E,Ce as Et,ir as F,Re as Ft,Mn as G,re as Gt,zn as H,b as Ht,nr as I,Ne as It,Pn as J,ce as Jt,Wn as K,ie as Kt,qn as L,Oe as Lt,vr as M,C as Mt,gr as N,ke as Nt,Jr as O,Fe as Ot,_r as P,Ae as Pt,R as Q,Un as R,de as Rt,Gr as S,Be as St,Fr as T,x as Tt,In as U,ae as Ut,Kn as V,ue as Vt,Gn as W,oe as Wt,M as X,Nn as Y,dn as Z,Y as _,Ke as _t,Fi as a,En as at,ti as b,He as bt,Si as c,on as ct,di as d,Wt as dt,F as et,X as f,Vt as ft,mi as g,Ye as gt,fi as h,T as ht,Ii as i,Sn as it,Sr as j,Me as jt,Kr as k,Le as kt,xi as l,Ut as lt,si as m,w as mt,Li as n,P as nt,Ci as o,wn as ot,pi as p,D as pt,Hn as q,y as qt,Ti as r,I as rt,Ri as s,an as st,wi as t,N as tt,ci as u,qt as ut,$r as v,Ge as vt,Rr as w,Ve as wt,W as x,Ue as xt,ni as y,We as yt,jn as z,be as zt};
6
+ //# sourceMappingURL=paths-D55o_j8-.js.map
@@ -3,3 +3,4 @@ const e=require(`./paths-Bcdg3ma0.cjs`),t=require(`./logger-DUYnS-W3.cjs`);let n
3
3
  `);function gr(e){let t=e.trim().split(/\r?\n/).map(e=>e.trim()).filter(Boolean).at(-1);if(!t)throw Error(`Pinned write helper returned no identity`);let[n,r]=t.split(`|`),i=Number.parseInt(n??``,10),a=Number.parseInt(r??``,10);if(!Number.isFinite(i)||!Number.isFinite(a))throw Error(`Pinned write helper returned invalid identity: ${t}`);return{dev:i,ino:a}}async function _r(e){let t=(0,c.spawn)(`python3`,[`-c`,hr,e.rootPath,e.relativeParentPath,e.basename,e.mkdir?`1`:`0`,(e.mode||384).toString(8)],{stdio:[`pipe`,`pipe`,`pipe`]}),n=``,r=``;t.stdout.setEncoding?.(`utf8`),t.stderr.setEncoding?.(`utf8`),t.stdout.on(`data`,e=>{n+=e}),t.stderr.on(`data`,e=>{r+=e});let i=(0,l.once)(t,`close`);try{if(!t.stdin){let t=await vr(e);return await i.catch(()=>{}),t}if(e.input.kind===`buffer`){let n=e.input;await new Promise((e,r)=>{if(t.stdin.once(`error`,r),typeof n.data==`string`){t.stdin.end(n.data,n.encoding??`utf8`,()=>e());return}t.stdin.end(n.data,()=>e())})}else await(0,u.pipeline)(e.input.stream,t.stdin);let[a,o]=await i;if(a!==0)throw Error(r.trim()||`Pinned write helper failed with code ${a??`null`} (${o??`?`})`);return gr(n)}catch(e){throw t.kill(`SIGKILL`),await i.catch(()=>{}),e}}async function vr(e){let t=e.relativeParentPath?n.default.join(e.rootPath,...e.relativeParentPath.split(`/`)):e.rootPath;e.mkdir&&await a.default.mkdir(t,{recursive:!0});let r=n.default.join(t,e.basename),i=n.default.join(t,`.${e.basename}.fallback.tmp`);if(e.input.kind===`buffer`)typeof e.input.data==`string`?await a.default.writeFile(i,e.input.data,{encoding:e.input.encoding??`utf8`,mode:e.mode}):await a.default.writeFile(i,e.input.data,{mode:e.mode});else{let t=await a.default.open(i,`w`,e.mode);try{await(0,u.pipeline)(e.input.stream,t.createWriteStream())}finally{await t.close().catch(()=>{})}}await a.default.rename(i,r);let o=await a.default.stat(r);return{dev:o.dev,ino:o.ino}}var H=class extends Error{constructor(e,t,n){super(t,n),this.code=e,this.name=`SafeOpenError`}};const U=process.platform!==`win32`&&`O_NOFOLLOW`in r.constants,yr=r.constants.O_RDONLY|(U?r.constants.O_NOFOLLOW:0),br=r.constants.O_WRONLY|(U?r.constants.O_NOFOLLOW:0),xr=r.constants.O_WRONLY|r.constants.O_CREAT|r.constants.O_EXCL|(U?r.constants.O_NOFOLLOW:0),Sr=r.constants.O_RDWR|r.constants.O_APPEND|(U?r.constants.O_NOFOLLOW:0),Cr=r.constants.O_RDWR|r.constants.O_APPEND|r.constants.O_CREAT|r.constants.O_EXCL|(U?r.constants.O_NOFOLLOW:0),wr=e=>e.endsWith(n.default.sep)?e:e+n.default.sep;async function Tr(t){let n=process.env.HOME||process.env.USERPROFILE||i.default.homedir();try{n=await a.default.realpath(n)}catch{}return e.l(t,{home:n})}async function W(e,t){try{if((await a.default.lstat(e)).isDirectory())throw new H(`not-file`,`not a file`)}catch(e){if(e instanceof H)throw e}let n;try{n=await a.default.open(e,yr)}catch(e){throw S(e)?new H(`not-found`,`file not found`):Xe(e)?new H(`symlink`,`symlink open blocked`,{cause:e}):Ye(e,`EISDIR`)?new H(`not-file`,`not a file`):e}try{let[r,i]=await Promise.all([n.stat(),a.default.lstat(e)]);if(i.isSymbolicLink())throw new H(`symlink`,`symlink not allowed`);if(!r.isFile())throw new H(`not-file`,`not a file`);if(t?.rejectHardlinks&&r.nlink>1)throw new H(`invalid-path`,`hardlinked path not allowed`);if(!x(r,i))throw new H(`path-mismatch`,`path changed during read`);let o=await a.default.realpath(e),s=await a.default.stat(o);if(t?.rejectHardlinks&&s.nlink>1)throw new H(`invalid-path`,`hardlinked path not allowed`);if(!x(r,s))throw new H(`path-mismatch`,`path mismatch`);return{handle:n,realPath:o,stat:r}}catch(e){throw await n.close().catch(()=>{}),e instanceof H?e:S(e)?new H(`not-found`,`file not found`):e}}async function Er(e){let t;try{t=await a.default.realpath(e.rootDir)}catch(e){throw S(e)?new H(`not-found`,`root dir not found`):e}let r=wr(t),i=await Tr(e.relativePath),o=n.default.resolve(r,i);if(!C(r,o))throw new H(`outside-workspace`,`file is outside workspace root`);return{rootReal:t,rootWithSep:r,resolved:o}}async function Dr(e){let{rootWithSep:t,resolved:n}=await Er(e),r;try{r=await W(n)}catch(e){throw e instanceof H?e.code===`not-found`?e:new H(`invalid-path`,`path is not a regular file under root`,{cause:e}):e}if(e.rejectHardlinks!==!1&&r.stat.nlink>1)throw await r.handle.close().catch(()=>{}),new H(`invalid-path`,`hardlinked path not allowed`);if(!C(t,r.realPath))throw await r.handle.close().catch(()=>{}),new H(`outside-workspace`,`file is outside workspace root`);return r}async function Or(e){let t=await Dr({rootDir:e.rootDir,relativePath:e.relativePath,rejectHardlinks:e.rejectHardlinks});try{return await Mr({opened:t,maxBytes:e.maxBytes})}finally{await t.handle.close().catch(()=>{})}}async function kr(e){let t=n.default.resolve(e.rootDir),r=n.default.isAbsolute(e.filePath)?n.default.resolve(e.filePath):n.default.resolve(t,e.filePath);return await Or({rootDir:t,relativePath:n.default.relative(t,r),rejectHardlinks:e.rejectHardlinks,maxBytes:e.maxBytes})}function Ar(e){let t=n.default.resolve(e.rootDir);return async n=>(await kr({rootDir:t,filePath:n,rejectHardlinks:e.rejectHardlinks,maxBytes:e.maxBytes})).buffer}async function jr(e){let t=await W(e.filePath);try{return await Mr({opened:t,maxBytes:e.maxBytes})}finally{await t.handle.close().catch(()=>{})}}async function Mr(e){if(e.maxBytes!==void 0&&e.opened.stat.size>e.maxBytes)throw new H(`too-large`,`file exceeds limit of ${e.maxBytes} bytes (got ${e.opened.stat.size})`);return{buffer:await e.opened.handle.readFile(),realPath:e.opened.realPath,stat:e.opened.stat}}function G(e){t.i(`security: fs-safe write boundary warning (${e})`)}function Nr(e){let t=n.default.dirname(e),r=n.default.basename(e);return n.default.join(t,`.${r}.${process.pid}.${(0,s.randomUUID)()}.tmp`)}async function Pr(e){let t=await a.default.open(e.tempPath,xr,e.mode);try{return typeof e.data==`string`?await t.writeFile(e.data,e.encoding??`utf8`):await t.writeFile(e.data),await t.stat()}finally{await t.close().catch(()=>{})}}async function K(e){let t=wr(await a.default.realpath(e.rootDir)),n=await W(e.targetPath,{rejectHardlinks:!0});try{if(!x(n.stat,e.expectedIdentity))throw new H(`path-mismatch`,`path changed during write`);if(!C(t,n.realPath))throw new H(`outside-workspace`,`file is outside workspace root`)}finally{await n.handle.close().catch(()=>{})}}async function Fr(e,t){try{return await a.default.realpath(t)}catch(e){if(!S(e))throw e}let n=process.platform===`linux`?[`/proc/self/fd/${e.fd}`,`/dev/fd/${e.fd}`]:process.platform===`win32`?[]:[`/dev/fd/${e.fd}`];for(let e of n)try{return await a.default.realpath(e)}catch{}throw new H(`path-mismatch`,`unable to resolve opened file path`)}async function q(e){let{rootReal:t,rootWithSep:r,resolved:i}=await Er(e);try{await mr({absolutePath:i,rootPath:t,boundaryLabel:`root`})}catch(e){throw new H(`invalid-path`,`path alias escape blocked`,{cause:e})}e.mkdir!==!1&&await a.default.mkdir(n.default.dirname(i),{recursive:!0});let o=i;try{let e=await a.default.realpath(i);if(!C(r,e))throw new H(`outside-workspace`,`file is outside workspace root`);o=e}catch(e){if(e instanceof H||!S(e))throw e}let s=e.mode??384,c,l=!1,u=e.append?Sr:br,d=e.append?Cr:xr;try{try{c=await a.default.open(o,u,s)}catch(e){if(!S(e))throw e;c=await a.default.open(o,d,s),l=!0}}catch(e){throw S(e)?new H(`not-found`,`file not found`):Xe(e)?new H(`invalid-path`,`symlink open blocked`,{cause:e}):e}let f=null;try{let t=await c.stat();if(!t.isFile())throw new H(`invalid-path`,`path is not a regular file under root`);if(t.nlink>1)throw new H(`invalid-path`,`hardlinked path not allowed`);try{let e=await a.default.lstat(o);if(e.isSymbolicLink()||!e.isFile())throw new H(`invalid-path`,`path is not a regular file under root`);if(!x(t,e))throw new H(`path-mismatch`,`path changed during write`)}catch(e){if(!S(e))throw e}let n=await Fr(c,o);f=n;let i=await a.default.stat(n);if(!x(t,i))throw new H(`path-mismatch`,`path mismatch`);if(i.nlink>1)throw new H(`invalid-path`,`hardlinked path not allowed`);if(!C(r,n))throw new H(`outside-workspace`,`file is outside workspace root`);return e.append!==!0&&e.truncateExisting!==!1&&!l&&await c.truncate(0),{handle:c,createdForWrite:l,openedRealPath:n,openedStat:t}}catch(e){let t=l&&e instanceof H,n=f??o;throw await c.close().catch(()=>{}),t&&await a.default.rm(n,{force:!0}).catch(()=>{}),e}}async function Ir(e){let t=await q({rootDir:e.rootDir,relativePath:e.relativePath,mkdir:e.mkdir,truncateExisting:!1,append:!0});try{let n=``;if(e.prependNewlineIfNeeded===!0&&!t.createdForWrite&&t.openedStat.size>0&&(typeof e.data==`string`&&!e.data.startsWith(`
4
4
  `)||Buffer.isBuffer(e.data)&&e.data.length>0&&e.data[0]!==10)){let e=Buffer.alloc(1),{bytesRead:r}=await t.handle.read(e,0,1,t.openedStat.size-1);r===1&&e[0]!==10&&(n=`
5
5
  `)}if(typeof e.data==`string`){await t.handle.appendFile(`${n}${e.data}`,e.encoding??`utf8`);return}let r=n.length>0?Buffer.concat([Buffer.from(n,`utf8`),e.data]):e.data;await t.handle.appendFile(r)}finally{await t.handle.close().catch(()=>{})}}async function Lr(e){if(process.platform===`win32`){await Hr(e);return}let t=await Br({rootDir:e.rootDir,relativePath:e.relativePath}),n=await _r({rootPath:t.rootReal,relativeParentPath:t.relativeParentPath,basename:t.basename,mkdir:e.mkdir!==!1,mode:t.mode,input:{kind:`buffer`,data:e.data,encoding:e.encoding}}).catch(e=>{throw Vr(e)});try{await K({rootDir:e.rootDir,targetPath:t.targetPath,expectedIdentity:n})}catch(e){throw G(`post-write verification failed: ${String(e)}`),e}}async function Rr(e){let t=await W(e.sourcePath,{rejectHardlinks:e.rejectSourceHardlinks});if(e.maxBytes!==void 0&&t.stat.size>e.maxBytes)throw await t.handle.close().catch(()=>{}),new H(`too-large`,`file exceeds limit of ${e.maxBytes} bytes (got ${t.stat.size})`);try{if(process.platform===`win32`){await Ur(e,t);return}let n=await Br({rootDir:e.rootDir,relativePath:e.relativePath}),r=t.handle.createReadStream(),i=await _r({rootPath:n.rootReal,relativeParentPath:n.relativeParentPath,basename:n.basename,mkdir:e.mkdir!==!1,mode:n.mode,input:{kind:`stream`,stream:r}}).catch(e=>{throw Vr(e)});try{await K({rootDir:e.rootDir,targetPath:n.targetPath,expectedIdentity:i})}catch(e){throw G(`post-copy verification failed: ${String(e)}`),e}}finally{await t.handle.close().catch(()=>{})}}async function zr(e){await Rr({sourcePath:e.sourcePath,rootDir:e.rootDir,relativePath:e.relativePath,mkdir:e.mkdir,rejectSourceHardlinks:!0})}async function Br(e){let{rootReal:t,rootWithSep:r,resolved:i}=await Er(e);try{await mr({absolutePath:i,rootPath:t,boundaryLabel:`root`})}catch(e){throw new H(`invalid-path`,`path alias escape blocked`,{cause:e})}let a=n.default.relative(t,i);if(a.startsWith(`..`)||n.default.isAbsolute(a))throw new H(`outside-workspace`,`file is outside workspace root`);let o=a?a.split(n.default.sep).join(n.default.posix.sep):``,s=n.default.posix.basename(o);if(!s||s===`.`||s===`/`)throw new H(`invalid-path`,`invalid target path`);let c=384;try{let t=await Dr({rootDir:e.rootDir,relativePath:e.relativePath,rejectHardlinks:!0});try{if(c=t.stat.mode&511,!C(r,t.realPath))throw new H(`outside-workspace`,`file is outside workspace root`)}finally{await t.handle.close().catch(()=>{})}}catch(e){if(!(e instanceof H)||e.code!==`not-found`)throw e}return{rootReal:t,targetPath:i,relativeParentPath:n.default.posix.dirname(o)===`.`?``:n.default.posix.dirname(o),basename:s,mode:c||384}}function Vr(e){return e instanceof H?e:new H(`invalid-path`,`path is not a regular file under root`,{cause:e instanceof Error?e:void 0})}async function Hr(e){let t=await q({rootDir:e.rootDir,relativePath:e.relativePath,mkdir:e.mkdir,truncateExisting:!1}),n=t.openedRealPath,r=t.openedStat.mode&511;await t.handle.close().catch(()=>{});let i=null;try{i=Nr(n);let t=await Pr({tempPath:i,data:e.data,encoding:e.encoding,mode:r||384});await a.default.rename(i,n),i=null;try{await K({rootDir:e.rootDir,targetPath:n,expectedIdentity:t})}catch(e){throw G(`post-write verification failed: ${String(e)}`),e}}finally{i&&await a.default.rm(i,{force:!0}).catch(()=>{})}}async function Ur(e,t){let n=null,r=!1,i=!1,o=null,s=null,c=!1;try{n=await q({rootDir:e.rootDir,relativePath:e.relativePath,mkdir:e.mkdir,truncateExisting:!1});let l=n.openedRealPath,u=n.openedStat.mode&511;await n.handle.close().catch(()=>{}),i=!0,s=Nr(l),o=await a.default.open(s,xr,u||384);let d=t.handle.createReadStream(),f=o.createWriteStream();d.once(`close`,()=>{r=!0}),f.once(`close`,()=>{c=!0}),await import(`node:stream/promises`).then(({pipeline:e})=>e(d,f));let ee=await a.default.stat(s);c||=(await o.close().catch(()=>{}),!0),o=null,await a.default.rename(s,l),s=null;try{await K({rootDir:e.rootDir,targetPath:l,expectedIdentity:ee})}catch(e){throw G(`post-copy verification failed: ${String(e)}`),e}}catch(e){throw n?.createdForWrite&&await a.default.rm(n.openedRealPath,{force:!0}).catch(()=>{}),e}finally{s&&await a.default.rm(s,{force:!0}).catch(()=>{}),r||await t.handle.close().catch(()=>{}),o&&!c&&await o.close().catch(()=>{}),n&&!i&&await n.handle.close().catch(()=>{})}}const Wr=6*1024*1024,Gr=100*1024*1024;function Kr(e){if(e){if(e.startsWith(`image/`))return`image`;if(e.startsWith(`audio/`))return`audio`;if(e.startsWith(`video/`))return`video`;if(e===`application/pdf`||e.startsWith(`text/`)||e.startsWith(`application/`))return`document`}}function qr(e){switch(e){case`image`:return Wr;case`audio`:return 16777216;case`video`:return 16777216;case`document`:return Gr;default:return Gr}}const Jr={"image/heic":`.heic`,"image/heif":`.heif`,"image/jpeg":`.jpg`,"image/png":`.png`,"image/webp":`.webp`,"image/gif":`.gif`,"audio/ogg":`.ogg`,"audio/mpeg":`.mp3`,"audio/wav":`.wav`,"audio/flac":`.flac`,"audio/aac":`.aac`,"audio/opus":`.opus`,"audio/x-m4a":`.m4a`,"audio/mp4":`.m4a`,"video/mp4":`.mp4`,"video/quicktime":`.mov`,"application/pdf":`.pdf`,"application/json":`.json`,"application/zip":`.zip`,"application/gzip":`.gz`,"application/x-tar":`.tar`,"application/x-7z-compressed":`.7z`,"application/vnd.rar":`.rar`,"application/msword":`.doc`,"application/vnd.ms-excel":`.xls`,"application/vnd.ms-powerpoint":`.ppt`,"application/vnd.openxmlformats-officedocument.wordprocessingml.document":`.docx`,"application/vnd.openxmlformats-officedocument.spreadsheetml.sheet":`.xlsx`,"application/vnd.openxmlformats-officedocument.presentationml.presentation":`.pptx`,"text/csv":`.csv`,"text/plain":`.txt`,"text/markdown":`.md`},Yr={...Object.fromEntries(Object.entries(Jr).map(([e,t])=>[t,e])),".jpeg":`image/jpeg`,".js":`text/javascript`},Xr=new Set([`.aac`,`.caf`,`.flac`,`.m4a`,`.mp3`,`.oga`,`.ogg`,`.opus`,`.wav`]);function J(e){if(e)return e.split(`;`)[0]?.trim().toLowerCase()||void 0}async function Zr(e){if(e)try{return(await(0,d.fileTypeFromBuffer)(e))?.mime??void 0}catch{return}}function Y(e){if(e){try{if(/^https?:\/\//i.test(e)){let t=new URL(e);return n.default.extname(t.pathname).toLowerCase()||void 0}}catch{}return n.default.extname(e).toLowerCase()||void 0}}function Qr(e){let t=Y(e);return t?Xr.has(t):!1}function $r(e){return ti(e)}function ei(e){if(!e)return!0;let t=e.toLowerCase();return t===`application/octet-stream`||t===`application/zip`}async function ti(e){let t=Y(e.filePath),n=t?Yr[t]:void 0,r=J(e.headerMime),i=await Zr(e.buffer);if(i&&(!ei(i)||!n))return i;if(n)return n;if(r&&!ei(r))return r;if(i)return i;if(r)return r}function ni(e){let t=J(e);if(t)return Jr[t]}function ri(e){return e.contentType?.toLowerCase()===`image/gif`?!0:Y(e.fileName)===`.gif`}function ii(e){if(e)switch(e.toLowerCase()){case`jpg`:case`jpeg`:return`image/jpeg`;case`heic`:return`image/heic`;case`heif`:return`image/heif`;case`png`:return`image/png`;case`webp`:return`image/webp`;case`gif`:return`image/gif`;default:return}}function ai(e){return Kr(J(e))}function X(e){try{return(0,r.statSync)(e).isFile()}catch{return!1}}function oi(e,t){if(e.includes(`/`)||e.includes(`\\`)||n.default.isAbsolute(e))return e;let r=(t.PATH??t.Path??process.env.PATH??process.env.Path??``).split(`;`).map(e=>e.trim()).filter(Boolean),i=n.default.extname(e).length>0,a=t.PATHEXT??t.Pathext??process.env.PATHEXT??process.env.Pathext??`.EXE;.CMD;.BAT;.COM`,o=i?[``]:a.split(`;`).map(e=>e.trim()).filter(Boolean).map(e=>e.startsWith(`.`)?e:`.${e}`);for(let t of r)for(let r of o)for(let i of[r,r.toLowerCase(),r.toUpperCase()]){let r=n.default.join(t,`${e}${i}`);if(X(r))return r}return e}function si(e){if(!X(e))return null;try{let t=(0,r.readFileSync)(e,`utf8`),i=[];for(let r of t.matchAll(/"([^"\r\n]*)"/g)){let t=(r[1]??``).match(/%~?dp0%?\s*[\\/]*(.*)$/i)?.[1]?.trim();if(!t)continue;let a=t.replace(/[\\/]+/g,n.default.sep).replace(/^[\\/]+/,``),o=n.default.resolve(n.default.dirname(e),a);X(o)&&i.push(o)}return i.find(e=>{let t=n.default.basename(e).toLowerCase();return t!==`node.exe`&&t!==`node`})??null}catch{return null}}function ci(e,t){if(typeof t==`string`)return t.trim()||null;if(!t||typeof t!=`object`)return null;if(e){let n=t[e];if(typeof n==`string`&&n.trim())return n.trim()}for(let e of Object.values(t))if(typeof e==`string`&&e.trim())return e.trim();return null}function li(e,t){if(!t)return null;let i=n.default.dirname(e),a=[n.default.resolve(i,`..`,t),n.default.resolve(i,`node_modules`,t)];for(let e of a){let i=n.default.join(e,`package.json`);if(X(i))try{let a=ci(t,JSON.parse((0,r.readFileSync)(i,`utf8`)).bin);if(!a)continue;let o=n.default.resolve(e,a);if(X(o))return o}catch{}}return null}function ui(e){let t=e.platform??process.platform,r=e.env??process.env,i=e.execPath??process.execPath;if(t!==`win32`)return{command:e.command,leadingArgv:[],resolution:`direct`};let a=oi(e.command,r),o=n.default.extname(a).toLowerCase();if(o===`.js`||o===`.cjs`||o===`.mjs`)return{command:i,leadingArgv:[a],resolution:`node-entrypoint`,windowsHide:!0};if(o===`.cmd`||o===`.bat`){let t=si(a)??li(a,e.packageName);return t?n.default.extname(t).toLowerCase()===`.exe`?{command:t,leadingArgv:[],resolution:`exe-entrypoint`,windowsHide:!0}:{command:i,leadingArgv:[t],resolution:`node-entrypoint`,windowsHide:!0}:{command:a,leadingArgv:[],resolution:`unresolved-wrapper`}}return{command:a,leadingArgv:[],resolution:`direct`}}function di(e){if(e.candidate.resolution!==`unresolved-wrapper`)return{command:e.candidate.command,leadingArgv:e.candidate.leadingArgv,resolution:e.candidate.resolution,windowsHide:e.candidate.windowsHide};if(e.allowShellFallback!==!1)return{command:e.candidate.command,leadingArgv:[],resolution:`shell-fallback`,shell:!0};throw Error(`${n.default.basename(e.candidate.command)} wrapper resolved, but no executable/Node entrypoint could be resolved without shell execution.`)}function fi(e){return di({candidate:ui(e),allowShellFallback:e.allowShellFallback})}function pi(e,t){return{command:e.command,argv:[...e.leadingArgv,...t],resolution:e.resolution,shell:e.shell,windowsHide:e.windowsHide}}function Z(t,r=process.env,a=()=>e.d(r,i.default.homedir)){let o=e.c(r,a),s=b(t??`main`);return n.default.join(o,`agents`,s,`sessions`)}function mi(t,n=process.env,r=()=>e.d(n,i.default.homedir)){return Z(t,n,r)}function hi(e){return n.default.join(Z(e),`sessions.json`)}function gi(e){let t=e.agentId?.trim(),r=e.storePath?.trim();if(r&&r!==`(multiple)`){let e=n.default.dirname(n.default.resolve(r));return t?{sessionsDir:e,agentId:t}:{sessionsDir:e}}if(t)return{agentId:t}}const _i=/^[a-z0-9][a-z0-9._-]{0,127}$/i;function vi(e){let t=e.trim();if(!_i.test(t))throw Error(`Invalid session ID: ${e}`);return t}function yi(e){let t=e?.sessionsDir?.trim();return t?n.default.resolve(t):Z(e?.agentId)}function bi(e,t){let r=Q(n.default.resolve(e))??n.default.resolve(e),i=Q(t)??t,a=n.default.relative(r,i);if(!(!a||a.startsWith(`..`)||n.default.isAbsolute(a)))return n.default.resolve(r,a)}function xi(e,t){let r=n.default.resolve(e);if(n.default.basename(r)!==`sessions`)return;let i=n.default.dirname(r),a=n.default.dirname(i);if(n.default.basename(a)!==`agents`)return;let o=n.default.dirname(a);return n.default.join(o,`agents`,b(t),`sessions`)}function Si(e){let t=n.default.normalize(n.default.resolve(e)).split(n.default.sep).filter(Boolean),r=t.lastIndexOf(`sessions`);return r<2||t[r-2]!==`agents`?null:{parts:t,sessionsIndex:r}}function Ci(e){let t=Si(e);if(!t)return;let{parts:n,sessionsIndex:r}=t;return n[r-1]||void 0}function wi(e,t){let r=Si(e);if(!r)return;let{parts:i,sessionsIndex:a}=r,o=i[a-1];if(!o)return;let s=b(o);if(s!==o.toLowerCase()||s!==b(t))return;let c=i.slice(a+1);if(c.length!==1)return;let l=c[0];if(!(!l||l===`.`||l===`..`))return n.default.normalize(n.default.resolve(e))}function Q(e){try{return r.default.realpathSync(e)}catch{return}}function Ti(e,t,r){let i=t.trim();if(!i)throw Error(`Session file path must not be empty`);let a=n.default.resolve(e),o=Q(a)??a,s=n.default.isAbsolute(i)?Q(i)??i:i,c=n.default.isAbsolute(s)?n.default.relative(o,s):s;if(c.startsWith(`..`)&&n.default.isAbsolute(s)){let e=e=>{let t=b(e),n=xi(o,t);if(n){let e=bi(n,s);if(e)return e}return bi(Z(t),s)},t=r?.agentId?.trim();if(t){let n=e(t);if(n)return n}let n=Ci(s);if(n){let t=e(n);if(t)return t;let r=wi(s,n);if(r)return r}}if(!c||c.startsWith(`..`)||n.default.isAbsolute(c))throw Error(`Session file path must be within sessions directory`);return n.default.resolve(o,c)}function $(e,t,n){let r=vi(e),i=typeof n==`string`?encodeURIComponent(n):typeof n==`number`?String(n):void 0;return Ti(t,i===void 0?`${r}.jsonl`:`${r}-topic-${i}.jsonl`)}function Ei(e,t,n){return $(e,Z(t),n)}function Di(e,t,n){let r=yi(n),i=t?.sessionFile?.trim();if(i)try{return Ti(r,i,{agentId:n?.agentId})}catch{}return $(e,r)}function Oi(t,r){let a=b(r?.agentId??`main`);if(!t)return hi(a);if(t.includes(`{agentId}`)){let r=t.replaceAll(`{agentId}`,a);return r.startsWith(`~`)?n.default.resolve(e.l(r,{home:e.d(process.env,i.default.homedir),env:process.env,homedir:i.default.homedir})):n.default.resolve(r)}return t.startsWith(`~`)?n.default.resolve(e.l(t,{home:e.d(process.env,i.default.homedir),env:process.env,homedir:i.default.homedir})):n.default.resolve(t)}Object.defineProperty(exports,`$`,{enumerable:!0,get:function(){return F}}),Object.defineProperty(exports,`A`,{enumerable:!0,get:function(){return pr}}),Object.defineProperty(exports,`At`,{enumerable:!0,get:function(){return we}}),Object.defineProperty(exports,`B`,{enumerable:!0,get:function(){return B}}),Object.defineProperty(exports,`Bt`,{enumerable:!0,get:function(){return me}}),Object.defineProperty(exports,`C`,{enumerable:!0,get:function(){return Rr}}),Object.defineProperty(exports,`Ct`,{enumerable:!0,get:function(){return Me}}),Object.defineProperty(exports,`D`,{enumerable:!0,get:function(){return jr}}),Object.defineProperty(exports,`Dt`,{enumerable:!0,get:function(){return De}}),Object.defineProperty(exports,`E`,{enumerable:!0,get:function(){return Or}}),Object.defineProperty(exports,`Et`,{enumerable:!0,get:function(){return ge}}),Object.defineProperty(exports,`F`,{enumerable:!0,get:function(){return Xn}}),Object.defineProperty(exports,`Ft`,{enumerable:!0,get:function(){return je}}),Object.defineProperty(exports,`G`,{enumerable:!0,get:function(){return wn}}),Object.defineProperty(exports,`Gt`,{enumerable:!0,get:function(){return te}}),Object.defineProperty(exports,`H`,{enumerable:!0,get:function(){return jn}}),Object.defineProperty(exports,`Ht`,{enumerable:!0,get:function(){return ee}}),Object.defineProperty(exports,`I`,{enumerable:!0,get:function(){return Jn}}),Object.defineProperty(exports,`It`,{enumerable:!0,get:function(){return Ee}}),Object.defineProperty(exports,`J`,{enumerable:!0,get:function(){return En}}),Object.defineProperty(exports,`Jt`,{enumerable:!0,get:function(){return p}}),Object.defineProperty(exports,`K`,{enumerable:!0,get:function(){return In}}),Object.defineProperty(exports,`Kt`,{enumerable:!0,get:function(){return ne}}),Object.defineProperty(exports,`L`,{enumerable:!0,get:function(){return zn}}),Object.defineProperty(exports,`Lt`,{enumerable:!0,get:function(){return xe}}),Object.defineProperty(exports,`M`,{enumerable:!0,get:function(){return ur}}),Object.defineProperty(exports,`Mt`,{enumerable:!0,get:function(){return b}}),Object.defineProperty(exports,`N`,{enumerable:!0,get:function(){return cr}}),Object.defineProperty(exports,`Nt`,{enumerable:!0,get:function(){return Se}}),Object.defineProperty(exports,`O`,{enumerable:!0,get:function(){return zr}}),Object.defineProperty(exports,`Ot`,{enumerable:!0,get:function(){return Oe}}),Object.defineProperty(exports,`P`,{enumerable:!0,get:function(){return lr}}),Object.defineProperty(exports,`Pt`,{enumerable:!0,get:function(){return Ce}}),Object.defineProperty(exports,`Q`,{enumerable:!0,get:function(){return I}}),Object.defineProperty(exports,`R`,{enumerable:!0,get:function(){return Fn}}),Object.defineProperty(exports,`Rt`,{enumerable:!0,get:function(){return h}}),Object.defineProperty(exports,`S`,{enumerable:!0,get:function(){return Ir}}),Object.defineProperty(exports,`St`,{enumerable:!0,get:function(){return Pe}}),Object.defineProperty(exports,`T`,{enumerable:!0,get:function(){return Dr}}),Object.defineProperty(exports,`Tt`,{enumerable:!0,get:function(){return v}}),Object.defineProperty(exports,`U`,{enumerable:!0,get:function(){return On}}),Object.defineProperty(exports,`Ut`,{enumerable:!0,get:function(){return re}}),Object.defineProperty(exports,`V`,{enumerable:!0,get:function(){return Rn}}),Object.defineProperty(exports,`Vt`,{enumerable:!0,get:function(){return m}}),Object.defineProperty(exports,`W`,{enumerable:!0,get:function(){return Ln}}),Object.defineProperty(exports,`Wt`,{enumerable:!0,get:function(){return ie}}),Object.defineProperty(exports,`X`,{enumerable:!0,get:function(){return A}}),Object.defineProperty(exports,`Y`,{enumerable:!0,get:function(){return Tn}}),Object.defineProperty(exports,`Z`,{enumerable:!0,get:function(){return nn}}),Object.defineProperty(exports,`_`,{enumerable:!0,get:function(){return J}}),Object.defineProperty(exports,`_t`,{enumerable:!0,get:function(){return He}}),Object.defineProperty(exports,`a`,{enumerable:!0,get:function(){return $}}),Object.defineProperty(exports,`at`,{enumerable:!0,get:function(){return vn}}),Object.defineProperty(exports,`b`,{enumerable:!0,get:function(){return Kr}}),Object.defineProperty(exports,`bt`,{enumerable:!0,get:function(){return ze}}),Object.defineProperty(exports,`c`,{enumerable:!0,get:function(){return pi}}),Object.defineProperty(exports,`ct`,{enumerable:!0,get:function(){return Zt}}),Object.defineProperty(exports,`d`,{enumerable:!0,get:function(){return ni}}),Object.defineProperty(exports,`dt`,{enumerable:!0,get:function(){return It}}),Object.defineProperty(exports,`et`,{enumerable:!0,get:function(){return N}}),Object.defineProperty(exports,`f`,{enumerable:!0,get:function(){return Y}}),Object.defineProperty(exports,`ft`,{enumerable:!0,get:function(){return E}}),Object.defineProperty(exports,`g`,{enumerable:!0,get:function(){return ai}}),Object.defineProperty(exports,`gt`,{enumerable:!0,get:function(){return We}}),Object.defineProperty(exports,`h`,{enumerable:!0,get:function(){return ri}}),Object.defineProperty(exports,`ht`,{enumerable:!0,get:function(){return qe}}),Object.defineProperty(exports,`i`,{enumerable:!0,get:function(){return Ei}}),Object.defineProperty(exports,`it`,{enumerable:!0,get:function(){return mn}}),Object.defineProperty(exports,`j`,{enumerable:!0,get:function(){return mr}}),Object.defineProperty(exports,`jt`,{enumerable:!0,get:function(){return Te}}),Object.defineProperty(exports,`k`,{enumerable:!0,get:function(){return Lr}}),Object.defineProperty(exports,`kt`,{enumerable:!0,get:function(){return Ae}}),Object.defineProperty(exports,`l`,{enumerable:!0,get:function(){return fi}}),Object.defineProperty(exports,`lt`,{enumerable:!0,get:function(){return Ft}}),Object.defineProperty(exports,`m`,{enumerable:!0,get:function(){return Qr}}),Object.defineProperty(exports,`mt`,{enumerable:!0,get:function(){return C}}),Object.defineProperty(exports,`n`,{enumerable:!0,get:function(){return Di}}),Object.defineProperty(exports,`nt`,{enumerable:!0,get:function(){return M}}),Object.defineProperty(exports,`o`,{enumerable:!0,get:function(){return mi}}),Object.defineProperty(exports,`ot`,{enumerable:!0,get:function(){return gn}}),Object.defineProperty(exports,`p`,{enumerable:!0,get:function(){return ii}}),Object.defineProperty(exports,`pt`,{enumerable:!0,get:function(){return S}}),Object.defineProperty(exports,`q`,{enumerable:!0,get:function(){return Pn}}),Object.defineProperty(exports,`qt`,{enumerable:!0,get:function(){return f}}),Object.defineProperty(exports,`r`,{enumerable:!0,get:function(){return gi}}),Object.defineProperty(exports,`rt`,{enumerable:!0,get:function(){return P}}),Object.defineProperty(exports,`s`,{enumerable:!0,get:function(){return Oi}}),Object.defineProperty(exports,`st`,{enumerable:!0,get:function(){return Xt}}),Object.defineProperty(exports,`t`,{enumerable:!0,get:function(){return hi}}),Object.defineProperty(exports,`tt`,{enumerable:!0,get:function(){return j}}),Object.defineProperty(exports,`u`,{enumerable:!0,get:function(){return $r}}),Object.defineProperty(exports,`ut`,{enumerable:!0,get:function(){return zt}}),Object.defineProperty(exports,`v`,{enumerable:!0,get:function(){return Wr}}),Object.defineProperty(exports,`vt`,{enumerable:!0,get:function(){return Ve}}),Object.defineProperty(exports,`w`,{enumerable:!0,get:function(){return Ar}}),Object.defineProperty(exports,`wt`,{enumerable:!0,get:function(){return Ne}}),Object.defineProperty(exports,`x`,{enumerable:!0,get:function(){return H}}),Object.defineProperty(exports,`xt`,{enumerable:!0,get:function(){return Fe}}),Object.defineProperty(exports,`y`,{enumerable:!0,get:function(){return qr}}),Object.defineProperty(exports,`yt`,{enumerable:!0,get:function(){return Ue}}),Object.defineProperty(exports,`z`,{enumerable:!0,get:function(){return Cn}}),Object.defineProperty(exports,`zt`,{enumerable:!0,get:function(){return pe}});
6
+ //# sourceMappingURL=paths-D90l3h_o.cjs.map
@@ -1 +1,2 @@
1
1
  import e from"node:fs";import t from"node:path";import n from"node:os";function r(e){return e?.trim()||void 0}function i(e=process.env,r=n.homedir){let i=a(e,r);return i?t.resolve(i):void 0}function a(e,t){let n=r(e.OPENCLAW_HOME);if(n){if(n===`~`||n.startsWith(`~/`)||n.startsWith(`~\\`)){let i=r(e.HOME)??r(e.USERPROFILE)??o(t);return i?n.replace(/^~(?=$|[\\/])/,i):void 0}return n}return r(e.HOME)||r(e.USERPROFILE)||o(t)}function o(e){try{return r(e())}catch{return}}function s(e=process.env,r=n.homedir){return i(e,r)??t.resolve(process.cwd())}function c(e,t){if(!e.startsWith(`~`))return e;let a=r(t?.home)??i(t?.env??process.env,t?.homedir??n.homedir);return a?e.replace(/^~(?=$|[\\/])/,a):e}function l(e=process.env){return e.OPENCLAW_NIX_MODE===`1`}l();const u=[`.clawdbot`,`.moldbot`,`.moltbot`],d=`.openclaw-qbot.json`,f=[`openclaw.json`,`clawdbot.json`,`moldbot.json`,`moltbot.json`];function p(){return s(process.env,n.homedir)}function m(e){return()=>s(e,n.homedir)}function h(e=p){return u.map(n=>t.join(e(),n))}function g(e=p){return t.join(e(),`.qbotclaw`)}function _(t=process.env,n=m(t)){let r=()=>s(t,n),i=t.OPENCLAW_STATE_DIR?.trim()||t.CLAWDBOT_STATE_DIR?.trim();if(i)return v(i,t,r);let a=g(r);if(t.OPENCLAW_TEST_FAST===`1`)return a;let o=h(r);return e.existsSync(a)?a:o.find(t=>{try{return e.existsSync(t)}catch{return!1}})||a}function v(e,n=process.env,r=m(n)){let i=e.trim();if(!i)return i;if(i.startsWith(`~`)){let e=c(i,{home:s(n,r),env:n,homedir:r});return t.resolve(e)}return t.resolve(i)}const y=_();function b(e=process.env,n=_(e,m(e))){let r=e.OPENCLAW_CONFIG_PATH?.trim()||e.CLAWDBOT_CONFIG_PATH?.trim();return r?v(r,e,m(e)):t.join(n,d)}function x(t=process.env,n=m(t)){return t.OPENCLAW_TEST_FAST===`1`?b(t,_(t,n)):C(t,n).find(t=>{try{return e.existsSync(t)}catch{return!1}})||b(t,_(t,n))}function S(n=process.env,r=_(n,m(n)),i=m(n)){let a=n.OPENCLAW_CONFIG_PATH?.trim();if(a)return v(a,n,i);if(n.OPENCLAW_TEST_FAST===`1`)return t.join(r,d);let o=n.OPENCLAW_STATE_DIR?.trim(),s=[t.join(r,d),...f.map(e=>t.join(r,e))].find(t=>{try{return e.existsSync(t)}catch{return!1}});if(s)return s;if(o)return t.join(r,d);let c=_(n,i);return t.resolve(r)===t.resolve(c)?x(n,i):t.join(r,d)}x();function C(e=process.env,n=m(e)){let r=()=>s(e,n),i=e.OPENCLAW_CONFIG_PATH?.trim()||e.CLAWDBOT_CONFIG_PATH?.trim();if(i)return[v(i,e,r)];let a=[],o=e.OPENCLAW_STATE_DIR?.trim()||e.CLAWDBOT_STATE_DIR?.trim();if(o){let n=v(o,e,r);a.push(t.join(n,d)),a.push(...f.map(e=>t.join(n,e)))}let c=[g(r),...h(r)];for(let e of c)a.push(t.join(e,d)),a.push(...f.map(n=>t.join(e,n)));return a}const w=18789;function T(e=process.env,n=_(e,m(e))){let r=e.OPENCLAW_OAUTH_DIR?.trim();return r?v(r,e,m(e)):t.join(n,`credentials`)}function E(e=process.env,n=_(e,m(e))){return t.join(T(e,n),`oauth.json`)}function D(e,t=process.env){let n=t.OPENCLAW_GATEWAY_PORT?.trim()||t.CLAWDBOT_GATEWAY_PORT?.trim();if(n){let e=Number.parseInt(n,10);if(Number.isFinite(e)&&e>=0)return e}let r=e?.gateway?.port;return typeof r==`number`&&Number.isFinite(r)&&r>=0?r:w}export{D as a,_ as c,s as d,C as i,c as l,y as n,T as o,S as r,E as s,w as t,i as u};
2
+ //# sourceMappingURL=paths-DaRoqzBQ.js.map
@@ -3,3 +3,4 @@ const e=require(`./paths-Bcdg3ma0.cjs`),t=require(`./logger-6O6OsYBL.cjs`);let n
3
3
  `);function gr(e){let t=e.trim().split(/\r?\n/).map(e=>e.trim()).filter(Boolean).at(-1);if(!t)throw Error(`Pinned write helper returned no identity`);let[n,r]=t.split(`|`),i=Number.parseInt(n??``,10),a=Number.parseInt(r??``,10);if(!Number.isFinite(i)||!Number.isFinite(a))throw Error(`Pinned write helper returned invalid identity: ${t}`);return{dev:i,ino:a}}async function _r(e){let t=(0,r.spawn)(`python3`,[`-c`,hr,e.rootPath,e.relativeParentPath,e.basename,e.mkdir?`1`:`0`,(e.mode||384).toString(8)],{stdio:[`pipe`,`pipe`,`pipe`]}),n=``,i=``;t.stdout.setEncoding?.(`utf8`),t.stderr.setEncoding?.(`utf8`),t.stdout.on(`data`,e=>{n+=e}),t.stderr.on(`data`,e=>{i+=e});let a=(0,l.once)(t,`close`);try{if(!t.stdin){let t=await vr(e);return await a.catch(()=>{}),t}if(e.input.kind===`buffer`){let n=e.input;await new Promise((e,r)=>{if(t.stdin.once(`error`,r),typeof n.data==`string`){t.stdin.end(n.data,n.encoding??`utf8`,()=>e());return}t.stdin.end(n.data,()=>e())})}else await(0,u.pipeline)(e.input.stream,t.stdin);let[r,o]=await a;if(r!==0)throw Error(i.trim()||`Pinned write helper failed with code ${r??`null`} (${o??`?`})`);return gr(n)}catch(e){throw t.kill(`SIGKILL`),await a.catch(()=>{}),e}}async function vr(e){let t=e.relativeParentPath?n.default.join(e.rootPath,...e.relativeParentPath.split(`/`)):e.rootPath;e.mkdir&&await o.default.mkdir(t,{recursive:!0});let r=n.default.join(t,e.basename),i=n.default.join(t,`.${e.basename}.fallback.tmp`);if(e.input.kind===`buffer`)typeof e.input.data==`string`?await o.default.writeFile(i,e.input.data,{encoding:e.input.encoding??`utf8`,mode:e.mode}):await o.default.writeFile(i,e.input.data,{mode:e.mode});else{let t=await o.default.open(i,`w`,e.mode);try{await(0,u.pipeline)(e.input.stream,t.createWriteStream())}finally{await t.close().catch(()=>{})}}await o.default.rename(i,r);let a=await o.default.stat(r);return{dev:a.dev,ino:a.ino}}var H=class extends Error{constructor(e,t,n){super(t,n),this.code=e,this.name=`SafeOpenError`}};const U=process.platform!==`win32`&&`O_NOFOLLOW`in i.constants,yr=i.constants.O_RDONLY|(U?i.constants.O_NOFOLLOW:0),br=i.constants.O_WRONLY|(U?i.constants.O_NOFOLLOW:0),xr=i.constants.O_WRONLY|i.constants.O_CREAT|i.constants.O_EXCL|(U?i.constants.O_NOFOLLOW:0),Sr=i.constants.O_RDWR|i.constants.O_APPEND|(U?i.constants.O_NOFOLLOW:0),Cr=i.constants.O_RDWR|i.constants.O_APPEND|i.constants.O_CREAT|i.constants.O_EXCL|(U?i.constants.O_NOFOLLOW:0),wr=e=>e.endsWith(n.default.sep)?e:e+n.default.sep;async function Tr(t){let n=process.env.HOME||process.env.USERPROFILE||a.default.homedir();try{n=await o.default.realpath(n)}catch{}return e.l(t,{home:n})}async function W(e,t){try{if((await o.default.lstat(e)).isDirectory())throw new H(`not-file`,`not a file`)}catch(e){if(e instanceof H)throw e}let n;try{n=await o.default.open(e,yr)}catch(e){throw x(e)?new H(`not-found`,`file not found`):Ge(e)?new H(`symlink`,`symlink open blocked`,{cause:e}):We(e,`EISDIR`)?new H(`not-file`,`not a file`):e}try{let[r,i]=await Promise.all([n.stat(),o.default.lstat(e)]);if(i.isSymbolicLink())throw new H(`symlink`,`symlink not allowed`);if(!r.isFile())throw new H(`not-file`,`not a file`);if(t?.rejectHardlinks&&r.nlink>1)throw new H(`invalid-path`,`hardlinked path not allowed`);if(!D(r,i))throw new H(`path-mismatch`,`path changed during read`);let a=await o.default.realpath(e),s=await o.default.stat(a);if(t?.rejectHardlinks&&s.nlink>1)throw new H(`invalid-path`,`hardlinked path not allowed`);if(!D(r,s))throw new H(`path-mismatch`,`path mismatch`);return{handle:n,realPath:a,stat:r}}catch(e){throw await n.close().catch(()=>{}),e instanceof H?e:x(e)?new H(`not-found`,`file not found`):e}}async function Er(e){let t;try{t=await o.default.realpath(e.rootDir)}catch(e){throw x(e)?new H(`not-found`,`root dir not found`):e}let r=wr(t),i=await Tr(e.relativePath),a=n.default.resolve(r,i);if(!S(r,a))throw new H(`outside-workspace`,`file is outside workspace root`);return{rootReal:t,rootWithSep:r,resolved:a}}async function Dr(e){let{rootWithSep:t,resolved:n}=await Er(e),r;try{r=await W(n)}catch(e){throw e instanceof H?e.code===`not-found`?e:new H(`invalid-path`,`path is not a regular file under root`,{cause:e}):e}if(e.rejectHardlinks!==!1&&r.stat.nlink>1)throw await r.handle.close().catch(()=>{}),new H(`invalid-path`,`hardlinked path not allowed`);if(!S(t,r.realPath))throw await r.handle.close().catch(()=>{}),new H(`outside-workspace`,`file is outside workspace root`);return r}async function Or(e){let t=await Dr({rootDir:e.rootDir,relativePath:e.relativePath,rejectHardlinks:e.rejectHardlinks});try{return await Mr({opened:t,maxBytes:e.maxBytes})}finally{await t.handle.close().catch(()=>{})}}async function kr(e){let t=n.default.resolve(e.rootDir),r=n.default.isAbsolute(e.filePath)?n.default.resolve(e.filePath):n.default.resolve(t,e.filePath);return await Or({rootDir:t,relativePath:n.default.relative(t,r),rejectHardlinks:e.rejectHardlinks,maxBytes:e.maxBytes})}function Ar(e){let t=n.default.resolve(e.rootDir);return async n=>(await kr({rootDir:t,filePath:n,rejectHardlinks:e.rejectHardlinks,maxBytes:e.maxBytes})).buffer}async function jr(e){let t=await W(e.filePath);try{return await Mr({opened:t,maxBytes:e.maxBytes})}finally{await t.handle.close().catch(()=>{})}}async function Mr(e){if(e.maxBytes!==void 0&&e.opened.stat.size>e.maxBytes)throw new H(`too-large`,`file exceeds limit of ${e.maxBytes} bytes (got ${e.opened.stat.size})`);return{buffer:await e.opened.handle.readFile(),realPath:e.opened.realPath,stat:e.opened.stat}}function G(e){t.i(`security: fs-safe write boundary warning (${e})`)}function Nr(e){let t=n.default.dirname(e),r=n.default.basename(e);return n.default.join(t,`.${r}.${process.pid}.${(0,c.randomUUID)()}.tmp`)}async function Pr(e){let t=await o.default.open(e.tempPath,xr,e.mode);try{return typeof e.data==`string`?await t.writeFile(e.data,e.encoding??`utf8`):await t.writeFile(e.data),await t.stat()}finally{await t.close().catch(()=>{})}}async function K(e){let t=wr(await o.default.realpath(e.rootDir)),n=await W(e.targetPath,{rejectHardlinks:!0});try{if(!D(n.stat,e.expectedIdentity))throw new H(`path-mismatch`,`path changed during write`);if(!S(t,n.realPath))throw new H(`outside-workspace`,`file is outside workspace root`)}finally{await n.handle.close().catch(()=>{})}}async function Fr(e,t){try{return await o.default.realpath(t)}catch(e){if(!x(e))throw e}let n=process.platform===`linux`?[`/proc/self/fd/${e.fd}`,`/dev/fd/${e.fd}`]:process.platform===`win32`?[]:[`/dev/fd/${e.fd}`];for(let e of n)try{return await o.default.realpath(e)}catch{}throw new H(`path-mismatch`,`unable to resolve opened file path`)}async function q(e){let{rootReal:t,rootWithSep:r,resolved:i}=await Er(e);try{await mr({absolutePath:i,rootPath:t,boundaryLabel:`root`})}catch(e){throw new H(`invalid-path`,`path alias escape blocked`,{cause:e})}e.mkdir!==!1&&await o.default.mkdir(n.default.dirname(i),{recursive:!0});let a=i;try{let e=await o.default.realpath(i);if(!S(r,e))throw new H(`outside-workspace`,`file is outside workspace root`);a=e}catch(e){if(e instanceof H||!x(e))throw e}let s=e.mode??384,c,l=!1,u=e.append?Sr:br,d=e.append?Cr:xr;try{try{c=await o.default.open(a,u,s)}catch(e){if(!x(e))throw e;c=await o.default.open(a,d,s),l=!0}}catch(e){throw x(e)?new H(`not-found`,`file not found`):Ge(e)?new H(`invalid-path`,`symlink open blocked`,{cause:e}):e}let f=null;try{let t=await c.stat();if(!t.isFile())throw new H(`invalid-path`,`path is not a regular file under root`);if(t.nlink>1)throw new H(`invalid-path`,`hardlinked path not allowed`);try{let e=await o.default.lstat(a);if(e.isSymbolicLink()||!e.isFile())throw new H(`invalid-path`,`path is not a regular file under root`);if(!D(t,e))throw new H(`path-mismatch`,`path changed during write`)}catch(e){if(!x(e))throw e}let n=await Fr(c,a);f=n;let i=await o.default.stat(n);if(!D(t,i))throw new H(`path-mismatch`,`path mismatch`);if(i.nlink>1)throw new H(`invalid-path`,`hardlinked path not allowed`);if(!S(r,n))throw new H(`outside-workspace`,`file is outside workspace root`);return e.append!==!0&&e.truncateExisting!==!1&&!l&&await c.truncate(0),{handle:c,createdForWrite:l,openedRealPath:n,openedStat:t}}catch(e){let t=l&&e instanceof H,n=f??a;throw await c.close().catch(()=>{}),t&&await o.default.rm(n,{force:!0}).catch(()=>{}),e}}async function Ir(e){let t=await q({rootDir:e.rootDir,relativePath:e.relativePath,mkdir:e.mkdir,truncateExisting:!1,append:!0});try{let n=``;if(e.prependNewlineIfNeeded===!0&&!t.createdForWrite&&t.openedStat.size>0&&(typeof e.data==`string`&&!e.data.startsWith(`
4
4
  `)||Buffer.isBuffer(e.data)&&e.data.length>0&&e.data[0]!==10)){let e=Buffer.alloc(1),{bytesRead:r}=await t.handle.read(e,0,1,t.openedStat.size-1);r===1&&e[0]!==10&&(n=`
5
5
  `)}if(typeof e.data==`string`){await t.handle.appendFile(`${n}${e.data}`,e.encoding??`utf8`);return}let r=n.length>0?Buffer.concat([Buffer.from(n,`utf8`),e.data]):e.data;await t.handle.appendFile(r)}finally{await t.handle.close().catch(()=>{})}}async function Lr(e){if(process.platform===`win32`){await Hr(e);return}let t=await Br({rootDir:e.rootDir,relativePath:e.relativePath}),n=await _r({rootPath:t.rootReal,relativeParentPath:t.relativeParentPath,basename:t.basename,mkdir:e.mkdir!==!1,mode:t.mode,input:{kind:`buffer`,data:e.data,encoding:e.encoding}}).catch(e=>{throw Vr(e)});try{await K({rootDir:e.rootDir,targetPath:t.targetPath,expectedIdentity:n})}catch(e){throw G(`post-write verification failed: ${String(e)}`),e}}async function Rr(e){let t=await W(e.sourcePath,{rejectHardlinks:e.rejectSourceHardlinks});if(e.maxBytes!==void 0&&t.stat.size>e.maxBytes)throw await t.handle.close().catch(()=>{}),new H(`too-large`,`file exceeds limit of ${e.maxBytes} bytes (got ${t.stat.size})`);try{if(process.platform===`win32`){await Ur(e,t);return}let n=await Br({rootDir:e.rootDir,relativePath:e.relativePath}),r=t.handle.createReadStream(),i=await _r({rootPath:n.rootReal,relativeParentPath:n.relativeParentPath,basename:n.basename,mkdir:e.mkdir!==!1,mode:n.mode,input:{kind:`stream`,stream:r}}).catch(e=>{throw Vr(e)});try{await K({rootDir:e.rootDir,targetPath:n.targetPath,expectedIdentity:i})}catch(e){throw G(`post-copy verification failed: ${String(e)}`),e}}finally{await t.handle.close().catch(()=>{})}}async function zr(e){await Rr({sourcePath:e.sourcePath,rootDir:e.rootDir,relativePath:e.relativePath,mkdir:e.mkdir,rejectSourceHardlinks:!0})}async function Br(e){let{rootReal:t,rootWithSep:r,resolved:i}=await Er(e);try{await mr({absolutePath:i,rootPath:t,boundaryLabel:`root`})}catch(e){throw new H(`invalid-path`,`path alias escape blocked`,{cause:e})}let a=n.default.relative(t,i);if(a.startsWith(`..`)||n.default.isAbsolute(a))throw new H(`outside-workspace`,`file is outside workspace root`);let o=a?a.split(n.default.sep).join(n.default.posix.sep):``,s=n.default.posix.basename(o);if(!s||s===`.`||s===`/`)throw new H(`invalid-path`,`invalid target path`);let c=384;try{let t=await Dr({rootDir:e.rootDir,relativePath:e.relativePath,rejectHardlinks:!0});try{if(c=t.stat.mode&511,!S(r,t.realPath))throw new H(`outside-workspace`,`file is outside workspace root`)}finally{await t.handle.close().catch(()=>{})}}catch(e){if(!(e instanceof H)||e.code!==`not-found`)throw e}return{rootReal:t,targetPath:i,relativeParentPath:n.default.posix.dirname(o)===`.`?``:n.default.posix.dirname(o),basename:s,mode:c||384}}function Vr(e){return e instanceof H?e:new H(`invalid-path`,`path is not a regular file under root`,{cause:e instanceof Error?e:void 0})}async function Hr(e){let t=await q({rootDir:e.rootDir,relativePath:e.relativePath,mkdir:e.mkdir,truncateExisting:!1}),n=t.openedRealPath,r=t.openedStat.mode&511;await t.handle.close().catch(()=>{});let i=null;try{i=Nr(n);let t=await Pr({tempPath:i,data:e.data,encoding:e.encoding,mode:r||384});await o.default.rename(i,n),i=null;try{await K({rootDir:e.rootDir,targetPath:n,expectedIdentity:t})}catch(e){throw G(`post-write verification failed: ${String(e)}`),e}}finally{i&&await o.default.rm(i,{force:!0}).catch(()=>{})}}async function Ur(e,t){let n=null,r=!1,i=!1,a=null,s=null,c=!1;try{n=await q({rootDir:e.rootDir,relativePath:e.relativePath,mkdir:e.mkdir,truncateExisting:!1});let l=n.openedRealPath,u=n.openedStat.mode&511;await n.handle.close().catch(()=>{}),i=!0,s=Nr(l),a=await o.default.open(s,xr,u||384);let d=t.handle.createReadStream(),f=a.createWriteStream();d.once(`close`,()=>{r=!0}),f.once(`close`,()=>{c=!0}),await import(`node:stream/promises`).then(({pipeline:e})=>e(d,f));let ee=await o.default.stat(s);c||=(await a.close().catch(()=>{}),!0),a=null,await o.default.rename(s,l),s=null;try{await K({rootDir:e.rootDir,targetPath:l,expectedIdentity:ee})}catch(e){throw G(`post-copy verification failed: ${String(e)}`),e}}catch(e){throw n?.createdForWrite&&await o.default.rm(n.openedRealPath,{force:!0}).catch(()=>{}),e}finally{s&&await o.default.rm(s,{force:!0}).catch(()=>{}),r||await t.handle.close().catch(()=>{}),a&&!c&&await a.close().catch(()=>{}),n&&!i&&await n.handle.close().catch(()=>{})}}const Wr=6*1024*1024,Gr=100*1024*1024;function Kr(e){if(e){if(e.startsWith(`image/`))return`image`;if(e.startsWith(`audio/`))return`audio`;if(e.startsWith(`video/`))return`video`;if(e===`application/pdf`||e.startsWith(`text/`)||e.startsWith(`application/`))return`document`}}function qr(e){switch(e){case`image`:return Wr;case`audio`:return 16777216;case`video`:return 16777216;case`document`:return Gr;default:return Gr}}const Jr={"image/heic":`.heic`,"image/heif":`.heif`,"image/jpeg":`.jpg`,"image/png":`.png`,"image/webp":`.webp`,"image/gif":`.gif`,"audio/ogg":`.ogg`,"audio/mpeg":`.mp3`,"audio/wav":`.wav`,"audio/flac":`.flac`,"audio/aac":`.aac`,"audio/opus":`.opus`,"audio/x-m4a":`.m4a`,"audio/mp4":`.m4a`,"video/mp4":`.mp4`,"video/quicktime":`.mov`,"application/pdf":`.pdf`,"application/json":`.json`,"application/zip":`.zip`,"application/gzip":`.gz`,"application/x-tar":`.tar`,"application/x-7z-compressed":`.7z`,"application/vnd.rar":`.rar`,"application/msword":`.doc`,"application/vnd.ms-excel":`.xls`,"application/vnd.ms-powerpoint":`.ppt`,"application/vnd.openxmlformats-officedocument.wordprocessingml.document":`.docx`,"application/vnd.openxmlformats-officedocument.spreadsheetml.sheet":`.xlsx`,"application/vnd.openxmlformats-officedocument.presentationml.presentation":`.pptx`,"text/csv":`.csv`,"text/plain":`.txt`,"text/markdown":`.md`},Yr={...Object.fromEntries(Object.entries(Jr).map(([e,t])=>[t,e])),".jpeg":`image/jpeg`,".js":`text/javascript`},Xr=new Set([`.aac`,`.caf`,`.flac`,`.m4a`,`.mp3`,`.oga`,`.ogg`,`.opus`,`.wav`]);function J(e){if(e)return e.split(`;`)[0]?.trim().toLowerCase()||void 0}async function Zr(e){if(e)try{return(await(0,d.fileTypeFromBuffer)(e))?.mime??void 0}catch{return}}function Y(e){if(e){try{if(/^https?:\/\//i.test(e)){let t=new URL(e);return n.default.extname(t.pathname).toLowerCase()||void 0}}catch{}return n.default.extname(e).toLowerCase()||void 0}}function Qr(e){let t=Y(e);return t?Xr.has(t):!1}function $r(e){return ti(e)}function ei(e){if(!e)return!0;let t=e.toLowerCase();return t===`application/octet-stream`||t===`application/zip`}async function ti(e){let t=Y(e.filePath),n=t?Yr[t]:void 0,r=J(e.headerMime),i=await Zr(e.buffer);if(i&&(!ei(i)||!n))return i;if(n)return n;if(r&&!ei(r))return r;if(i)return i;if(r)return r}function ni(e){let t=J(e);if(t)return Jr[t]}function ri(e){return e.contentType?.toLowerCase()===`image/gif`?!0:Y(e.fileName)===`.gif`}function ii(e){if(e)switch(e.toLowerCase()){case`jpg`:case`jpeg`:return`image/jpeg`;case`heic`:return`image/heic`;case`heif`:return`image/heif`;case`png`:return`image/png`;case`webp`:return`image/webp`;case`gif`:return`image/gif`;default:return}}function ai(e){return Kr(J(e))}function X(e){try{return(0,i.statSync)(e).isFile()}catch{return!1}}function oi(e,t){if(e.includes(`/`)||e.includes(`\\`)||n.default.isAbsolute(e))return e;let r=(t.PATH??t.Path??process.env.PATH??process.env.Path??``).split(`;`).map(e=>e.trim()).filter(Boolean),i=n.default.extname(e).length>0,a=t.PATHEXT??t.Pathext??process.env.PATHEXT??process.env.Pathext??`.EXE;.CMD;.BAT;.COM`,o=i?[``]:a.split(`;`).map(e=>e.trim()).filter(Boolean).map(e=>e.startsWith(`.`)?e:`.${e}`);for(let t of r)for(let r of o)for(let i of[r,r.toLowerCase(),r.toUpperCase()]){let r=n.default.join(t,`${e}${i}`);if(X(r))return r}return e}function si(e){if(!X(e))return null;try{let t=(0,i.readFileSync)(e,`utf8`),r=[];for(let i of t.matchAll(/"([^"\r\n]*)"/g)){let t=(i[1]??``).match(/%~?dp0%?\s*[\\/]*(.*)$/i)?.[1]?.trim();if(!t)continue;let a=t.replace(/[\\/]+/g,n.default.sep).replace(/^[\\/]+/,``),o=n.default.resolve(n.default.dirname(e),a);X(o)&&r.push(o)}return r.find(e=>{let t=n.default.basename(e).toLowerCase();return t!==`node.exe`&&t!==`node`})??null}catch{return null}}function ci(e,t){if(typeof t==`string`)return t.trim()||null;if(!t||typeof t!=`object`)return null;if(e){let n=t[e];if(typeof n==`string`&&n.trim())return n.trim()}for(let e of Object.values(t))if(typeof e==`string`&&e.trim())return e.trim();return null}function li(e,t){if(!t)return null;let r=n.default.dirname(e),a=[n.default.resolve(r,`..`,t),n.default.resolve(r,`node_modules`,t)];for(let e of a){let r=n.default.join(e,`package.json`);if(X(r))try{let a=ci(t,JSON.parse((0,i.readFileSync)(r,`utf8`)).bin);if(!a)continue;let o=n.default.resolve(e,a);if(X(o))return o}catch{}}return null}function ui(e){let t=e.platform??process.platform,r=e.env??process.env,i=e.execPath??process.execPath;if(t!==`win32`)return{command:e.command,leadingArgv:[],resolution:`direct`};let a=oi(e.command,r),o=n.default.extname(a).toLowerCase();if(o===`.js`||o===`.cjs`||o===`.mjs`)return{command:i,leadingArgv:[a],resolution:`node-entrypoint`,windowsHide:!0};if(o===`.cmd`||o===`.bat`){let t=si(a)??li(a,e.packageName);return t?n.default.extname(t).toLowerCase()===`.exe`?{command:t,leadingArgv:[],resolution:`exe-entrypoint`,windowsHide:!0}:{command:i,leadingArgv:[t],resolution:`node-entrypoint`,windowsHide:!0}:{command:a,leadingArgv:[],resolution:`unresolved-wrapper`}}return{command:a,leadingArgv:[],resolution:`direct`}}function di(e){if(e.candidate.resolution!==`unresolved-wrapper`)return{command:e.candidate.command,leadingArgv:e.candidate.leadingArgv,resolution:e.candidate.resolution,windowsHide:e.candidate.windowsHide};if(e.allowShellFallback!==!1)return{command:e.candidate.command,leadingArgv:[],resolution:`shell-fallback`,shell:!0};throw Error(`${n.default.basename(e.candidate.command)} wrapper resolved, but no executable/Node entrypoint could be resolved without shell execution.`)}function fi(e){return di({candidate:ui(e),allowShellFallback:e.allowShellFallback})}function pi(e,t){return{command:e.command,argv:[...e.leadingArgv,...t],resolution:e.resolution,shell:e.shell,windowsHide:e.windowsHide}}function Z(t,r=process.env,i=()=>e.d(r,a.default.homedir)){let o=e.c(r,i),s=b(t??`main`);return n.default.join(o,`agents`,s,`sessions`)}function mi(t,n=process.env,r=()=>e.d(n,a.default.homedir)){return Z(t,n,r)}function hi(e){return n.default.join(Z(e),`sessions.json`)}function gi(e){let t=e.agentId?.trim(),r=e.storePath?.trim();if(r&&r!==`(multiple)`){let e=n.default.dirname(n.default.resolve(r));return t?{sessionsDir:e,agentId:t}:{sessionsDir:e}}if(t)return{agentId:t}}const _i=/^[a-z0-9][a-z0-9._-]{0,127}$/i;function vi(e){let t=e.trim();if(!_i.test(t))throw Error(`Invalid session ID: ${e}`);return t}function yi(e){let t=e?.sessionsDir?.trim();return t?n.default.resolve(t):Z(e?.agentId)}function bi(e,t){let r=Q(n.default.resolve(e))??n.default.resolve(e),i=Q(t)??t,a=n.default.relative(r,i);if(!(!a||a.startsWith(`..`)||n.default.isAbsolute(a)))return n.default.resolve(r,a)}function xi(e,t){let r=n.default.resolve(e);if(n.default.basename(r)!==`sessions`)return;let i=n.default.dirname(r),a=n.default.dirname(i);if(n.default.basename(a)!==`agents`)return;let o=n.default.dirname(a);return n.default.join(o,`agents`,b(t),`sessions`)}function Si(e){let t=n.default.normalize(n.default.resolve(e)).split(n.default.sep).filter(Boolean),r=t.lastIndexOf(`sessions`);return r<2||t[r-2]!==`agents`?null:{parts:t,sessionsIndex:r}}function Ci(e){let t=Si(e);if(!t)return;let{parts:n,sessionsIndex:r}=t;return n[r-1]||void 0}function wi(e,t){let r=Si(e);if(!r)return;let{parts:i,sessionsIndex:a}=r,o=i[a-1];if(!o)return;let s=b(o);if(s!==o.toLowerCase()||s!==b(t))return;let c=i.slice(a+1);if(c.length!==1)return;let l=c[0];if(!(!l||l===`.`||l===`..`))return n.default.normalize(n.default.resolve(e))}function Q(e){try{return i.default.realpathSync(e)}catch{return}}function Ti(e,t,r){let i=t.trim();if(!i)throw Error(`Session file path must not be empty`);let a=n.default.resolve(e),o=Q(a)??a,s=n.default.isAbsolute(i)?Q(i)??i:i,c=n.default.isAbsolute(s)?n.default.relative(o,s):s;if(c.startsWith(`..`)&&n.default.isAbsolute(s)){let e=e=>{let t=b(e),n=xi(o,t);if(n){let e=bi(n,s);if(e)return e}return bi(Z(t),s)},t=r?.agentId?.trim();if(t){let n=e(t);if(n)return n}let n=Ci(s);if(n){let t=e(n);if(t)return t;let r=wi(s,n);if(r)return r}}if(!c||c.startsWith(`..`)||n.default.isAbsolute(c))throw Error(`Session file path must be within sessions directory`);return n.default.resolve(o,c)}function $(e,t,n){let r=vi(e),i=typeof n==`string`?encodeURIComponent(n):typeof n==`number`?String(n):void 0;return Ti(t,i===void 0?`${r}.jsonl`:`${r}-topic-${i}.jsonl`)}function Ei(e,t,n){return $(e,Z(t),n)}function Di(e,t,n){let r=yi(n),i=t?.sessionFile?.trim();if(i)try{return Ti(r,i,{agentId:n?.agentId})}catch{}return $(e,r)}function Oi(t,r){let i=b(r?.agentId??`main`);if(!t)return hi(i);if(t.includes(`{agentId}`)){let r=t.replaceAll(`{agentId}`,i);return r.startsWith(`~`)?n.default.resolve(e.l(r,{home:e.d(process.env,a.default.homedir),env:process.env,homedir:a.default.homedir})):n.default.resolve(r)}return t.startsWith(`~`)?n.default.resolve(e.l(t,{home:e.d(process.env,a.default.homedir),env:process.env,homedir:a.default.homedir})):n.default.resolve(t)}Object.defineProperty(exports,`$`,{enumerable:!0,get:function(){return F}}),Object.defineProperty(exports,`A`,{enumerable:!0,get:function(){return pr}}),Object.defineProperty(exports,`At`,{enumerable:!0,get:function(){return we}}),Object.defineProperty(exports,`B`,{enumerable:!0,get:function(){return B}}),Object.defineProperty(exports,`Bt`,{enumerable:!0,get:function(){return me}}),Object.defineProperty(exports,`C`,{enumerable:!0,get:function(){return Rr}}),Object.defineProperty(exports,`Ct`,{enumerable:!0,get:function(){return Me}}),Object.defineProperty(exports,`D`,{enumerable:!0,get:function(){return jr}}),Object.defineProperty(exports,`Dt`,{enumerable:!0,get:function(){return De}}),Object.defineProperty(exports,`E`,{enumerable:!0,get:function(){return Or}}),Object.defineProperty(exports,`Et`,{enumerable:!0,get:function(){return ge}}),Object.defineProperty(exports,`F`,{enumerable:!0,get:function(){return Xn}}),Object.defineProperty(exports,`Ft`,{enumerable:!0,get:function(){return je}}),Object.defineProperty(exports,`G`,{enumerable:!0,get:function(){return wn}}),Object.defineProperty(exports,`Gt`,{enumerable:!0,get:function(){return te}}),Object.defineProperty(exports,`H`,{enumerable:!0,get:function(){return jn}}),Object.defineProperty(exports,`Ht`,{enumerable:!0,get:function(){return ee}}),Object.defineProperty(exports,`I`,{enumerable:!0,get:function(){return Jn}}),Object.defineProperty(exports,`It`,{enumerable:!0,get:function(){return Ee}}),Object.defineProperty(exports,`J`,{enumerable:!0,get:function(){return En}}),Object.defineProperty(exports,`Jt`,{enumerable:!0,get:function(){return m}}),Object.defineProperty(exports,`K`,{enumerable:!0,get:function(){return In}}),Object.defineProperty(exports,`Kt`,{enumerable:!0,get:function(){return ne}}),Object.defineProperty(exports,`L`,{enumerable:!0,get:function(){return zn}}),Object.defineProperty(exports,`Lt`,{enumerable:!0,get:function(){return xe}}),Object.defineProperty(exports,`M`,{enumerable:!0,get:function(){return ur}}),Object.defineProperty(exports,`Mt`,{enumerable:!0,get:function(){return b}}),Object.defineProperty(exports,`N`,{enumerable:!0,get:function(){return cr}}),Object.defineProperty(exports,`Nt`,{enumerable:!0,get:function(){return Se}}),Object.defineProperty(exports,`O`,{enumerable:!0,get:function(){return zr}}),Object.defineProperty(exports,`Ot`,{enumerable:!0,get:function(){return Oe}}),Object.defineProperty(exports,`P`,{enumerable:!0,get:function(){return lr}}),Object.defineProperty(exports,`Pt`,{enumerable:!0,get:function(){return Ce}}),Object.defineProperty(exports,`Q`,{enumerable:!0,get:function(){return I}}),Object.defineProperty(exports,`R`,{enumerable:!0,get:function(){return Fn}}),Object.defineProperty(exports,`Rt`,{enumerable:!0,get:function(){return g}}),Object.defineProperty(exports,`S`,{enumerable:!0,get:function(){return Ir}}),Object.defineProperty(exports,`St`,{enumerable:!0,get:function(){return Ne}}),Object.defineProperty(exports,`T`,{enumerable:!0,get:function(){return Dr}}),Object.defineProperty(exports,`Tt`,{enumerable:!0,get:function(){return v}}),Object.defineProperty(exports,`U`,{enumerable:!0,get:function(){return On}}),Object.defineProperty(exports,`Ut`,{enumerable:!0,get:function(){return p}}),Object.defineProperty(exports,`V`,{enumerable:!0,get:function(){return Rn}}),Object.defineProperty(exports,`Vt`,{enumerable:!0,get:function(){return h}}),Object.defineProperty(exports,`W`,{enumerable:!0,get:function(){return Ln}}),Object.defineProperty(exports,`Wt`,{enumerable:!0,get:function(){return re}}),Object.defineProperty(exports,`X`,{enumerable:!0,get:function(){return A}}),Object.defineProperty(exports,`Y`,{enumerable:!0,get:function(){return Tn}}),Object.defineProperty(exports,`Z`,{enumerable:!0,get:function(){return nn}}),Object.defineProperty(exports,`_`,{enumerable:!0,get:function(){return J}}),Object.defineProperty(exports,`_t`,{enumerable:!0,get:function(){return ze}}),Object.defineProperty(exports,`a`,{enumerable:!0,get:function(){return $}}),Object.defineProperty(exports,`at`,{enumerable:!0,get:function(){return vn}}),Object.defineProperty(exports,`b`,{enumerable:!0,get:function(){return Kr}}),Object.defineProperty(exports,`bt`,{enumerable:!0,get:function(){return Fe}}),Object.defineProperty(exports,`c`,{enumerable:!0,get:function(){return pi}}),Object.defineProperty(exports,`ct`,{enumerable:!0,get:function(){return Zt}}),Object.defineProperty(exports,`d`,{enumerable:!0,get:function(){return ni}}),Object.defineProperty(exports,`dt`,{enumerable:!0,get:function(){return It}}),Object.defineProperty(exports,`et`,{enumerable:!0,get:function(){return N}}),Object.defineProperty(exports,`f`,{enumerable:!0,get:function(){return Y}}),Object.defineProperty(exports,`ft`,{enumerable:!0,get:function(){return Nt}}),Object.defineProperty(exports,`g`,{enumerable:!0,get:function(){return ai}}),Object.defineProperty(exports,`gt`,{enumerable:!0,get:function(){return He}}),Object.defineProperty(exports,`h`,{enumerable:!0,get:function(){return ri}}),Object.defineProperty(exports,`ht`,{enumerable:!0,get:function(){return S}}),Object.defineProperty(exports,`i`,{enumerable:!0,get:function(){return Ei}}),Object.defineProperty(exports,`it`,{enumerable:!0,get:function(){return mn}}),Object.defineProperty(exports,`j`,{enumerable:!0,get:function(){return mr}}),Object.defineProperty(exports,`jt`,{enumerable:!0,get:function(){return Te}}),Object.defineProperty(exports,`k`,{enumerable:!0,get:function(){return Lr}}),Object.defineProperty(exports,`kt`,{enumerable:!0,get:function(){return Ae}}),Object.defineProperty(exports,`l`,{enumerable:!0,get:function(){return fi}}),Object.defineProperty(exports,`lt`,{enumerable:!0,get:function(){return Ft}}),Object.defineProperty(exports,`m`,{enumerable:!0,get:function(){return Qr}}),Object.defineProperty(exports,`mt`,{enumerable:!0,get:function(){return x}}),Object.defineProperty(exports,`n`,{enumerable:!0,get:function(){return Di}}),Object.defineProperty(exports,`nt`,{enumerable:!0,get:function(){return M}}),Object.defineProperty(exports,`o`,{enumerable:!0,get:function(){return mi}}),Object.defineProperty(exports,`ot`,{enumerable:!0,get:function(){return gn}}),Object.defineProperty(exports,`p`,{enumerable:!0,get:function(){return ii}}),Object.defineProperty(exports,`pt`,{enumerable:!0,get:function(){return T}}),Object.defineProperty(exports,`q`,{enumerable:!0,get:function(){return Pn}}),Object.defineProperty(exports,`qt`,{enumerable:!0,get:function(){return f}}),Object.defineProperty(exports,`r`,{enumerable:!0,get:function(){return gi}}),Object.defineProperty(exports,`rt`,{enumerable:!0,get:function(){return P}}),Object.defineProperty(exports,`s`,{enumerable:!0,get:function(){return Oi}}),Object.defineProperty(exports,`st`,{enumerable:!0,get:function(){return Xt}}),Object.defineProperty(exports,`t`,{enumerable:!0,get:function(){return hi}}),Object.defineProperty(exports,`tt`,{enumerable:!0,get:function(){return j}}),Object.defineProperty(exports,`u`,{enumerable:!0,get:function(){return $r}}),Object.defineProperty(exports,`ut`,{enumerable:!0,get:function(){return zt}}),Object.defineProperty(exports,`v`,{enumerable:!0,get:function(){return Wr}}),Object.defineProperty(exports,`vt`,{enumerable:!0,get:function(){return Re}}),Object.defineProperty(exports,`w`,{enumerable:!0,get:function(){return Ar}}),Object.defineProperty(exports,`wt`,{enumerable:!0,get:function(){return Pe}}),Object.defineProperty(exports,`x`,{enumerable:!0,get:function(){return H}}),Object.defineProperty(exports,`xt`,{enumerable:!0,get:function(){return Ie}}),Object.defineProperty(exports,`y`,{enumerable:!0,get:function(){return qr}}),Object.defineProperty(exports,`yt`,{enumerable:!0,get:function(){return Le}}),Object.defineProperty(exports,`z`,{enumerable:!0,get:function(){return Cn}}),Object.defineProperty(exports,`zt`,{enumerable:!0,get:function(){return pe}});
6
+ //# sourceMappingURL=paths-Dd7r1qlB.cjs.map
@@ -1 +1,2 @@
1
1
  import e from"node:path";import t from"node:fs";import n from"node:os";function r(e){return e?.trim()||void 0}function i(t=process.env,r=n.homedir){let i=a(t,r);return i?e.resolve(i):void 0}function a(e,t){let n=r(e.OPENCLAW_HOME);if(n){if(n===`~`||n.startsWith(`~/`)||n.startsWith(`~\\`)){let i=r(e.HOME)??r(e.USERPROFILE)??o(t);return i?n.replace(/^~(?=$|[\\/])/,i):void 0}return n}return r(e.HOME)||r(e.USERPROFILE)||o(t)}function o(e){try{return r(e())}catch{return}}function s(t=process.env,r=n.homedir){return i(t,r)??e.resolve(process.cwd())}function c(e,t){if(!e.startsWith(`~`))return e;let a=r(t?.home)??i(t?.env??process.env,t?.homedir??n.homedir);return a?e.replace(/^~(?=$|[\\/])/,a):e}function l(e=process.env){return e.OPENCLAW_NIX_MODE===`1`}l();const u=[`.clawdbot`,`.moldbot`,`.moltbot`],d=`.openclaw-qbot.json`,f=[`openclaw.json`,`clawdbot.json`,`moldbot.json`,`moltbot.json`];function p(){return s(process.env,n.homedir)}function m(e){return()=>s(e,n.homedir)}function h(t=p){return u.map(n=>e.join(t(),n))}function g(t=p){return e.join(t(),`.qbotclaw`)}function _(e=process.env,n=m(e)){let r=()=>s(e,n),i=e.OPENCLAW_STATE_DIR?.trim()||e.CLAWDBOT_STATE_DIR?.trim();if(i)return v(i,e,r);let a=g(r);if(e.OPENCLAW_TEST_FAST===`1`)return a;let o=h(r);return t.existsSync(a)?a:o.find(e=>{try{return t.existsSync(e)}catch{return!1}})||a}function v(t,n=process.env,r=m(n)){let i=t.trim();if(!i)return i;if(i.startsWith(`~`)){let t=c(i,{home:s(n,r),env:n,homedir:r});return e.resolve(t)}return e.resolve(i)}const y=_();function b(t=process.env,n=_(t,m(t))){let r=t.OPENCLAW_CONFIG_PATH?.trim()||t.CLAWDBOT_CONFIG_PATH?.trim();return r?v(r,t,m(t)):e.join(n,d)}function x(e=process.env,n=m(e)){return e.OPENCLAW_TEST_FAST===`1`?b(e,_(e,n)):C(e,n).find(e=>{try{return t.existsSync(e)}catch{return!1}})||b(e,_(e,n))}function S(n=process.env,r=_(n,m(n)),i=m(n)){let a=n.OPENCLAW_CONFIG_PATH?.trim();if(a)return v(a,n,i);if(n.OPENCLAW_TEST_FAST===`1`)return e.join(r,d);let o=n.OPENCLAW_STATE_DIR?.trim(),s=[e.join(r,d),...f.map(t=>e.join(r,t))].find(e=>{try{return t.existsSync(e)}catch{return!1}});if(s)return s;if(o)return e.join(r,d);let c=_(n,i);return e.resolve(r)===e.resolve(c)?x(n,i):e.join(r,d)}x();function C(t=process.env,n=m(t)){let r=()=>s(t,n),i=t.OPENCLAW_CONFIG_PATH?.trim()||t.CLAWDBOT_CONFIG_PATH?.trim();if(i)return[v(i,t,r)];let a=[],o=t.OPENCLAW_STATE_DIR?.trim()||t.CLAWDBOT_STATE_DIR?.trim();if(o){let n=v(o,t,r);a.push(e.join(n,d)),a.push(...f.map(t=>e.join(n,t)))}let c=[g(r),...h(r)];for(let t of c)a.push(e.join(t,d)),a.push(...f.map(n=>e.join(t,n)));return a}const w=18789;function T(t=process.env,n=_(t,m(t))){let r=t.OPENCLAW_OAUTH_DIR?.trim();return r?v(r,t,m(t)):e.join(n,`credentials`)}function E(t=process.env,n=_(t,m(t))){return e.join(T(t,n),`oauth.json`)}function D(e,t=process.env){let n=t.OPENCLAW_GATEWAY_PORT?.trim()||t.CLAWDBOT_GATEWAY_PORT?.trim();if(n){let e=Number.parseInt(n,10);if(Number.isFinite(e)&&e>=0)return e}let r=e?.gateway?.port;return typeof r==`number`&&Number.isFinite(r)&&r>=0?r:w}export{D as a,_ as c,s as d,C as i,c as l,y as n,T as o,S as r,E as s,w as t,i as u};
2
+ //# sourceMappingURL=paths-DhSjTRMz.js.map
@@ -3,3 +3,4 @@ import{J as e,O as t,_ as n,g as r,i,y as a}from"./logger-DJGHvDbX.js";import{c
3
3
  `);function wr(e){let t=e.trim().split(/\r?\n/).map(e=>e.trim()).filter(Boolean).at(-1);if(!t)throw Error(`Pinned write helper returned no identity`);let[n,r]=t.split(`|`),i=Number.parseInt(n??``,10),a=Number.parseInt(r??``,10);if(!Number.isFinite(i)||!Number.isFinite(a))throw Error(`Pinned write helper returned invalid identity: ${t}`);return{dev:i,ino:a}}async function Tr(e){let t=u(`python3`,[`-c`,Cr,e.rootPath,e.relativeParentPath,e.basename,e.mkdir?`1`:`0`,(e.mode||384).toString(8)],{stdio:[`pipe`,`pipe`,`pipe`]}),n=``,r=``;t.stdout.setEncoding?.(`utf8`),t.stderr.setEncoding?.(`utf8`),t.stdout.on(`data`,e=>{n+=e}),t.stderr.on(`data`,e=>{r+=e});let i=g(t,`close`);try{if(!t.stdin){let t=await Er(e);return await i.catch(()=>{}),t}if(e.input.kind===`buffer`){let n=e.input;await new Promise((e,r)=>{if(t.stdin.once(`error`,r),typeof n.data==`string`){t.stdin.end(n.data,n.encoding??`utf8`,()=>e());return}t.stdin.end(n.data,()=>e())})}else await _(e.input.stream,t.stdin);let[a,o]=await i;if(a!==0)throw Error(r.trim()||`Pinned write helper failed with code ${a??`null`} (${o??`?`})`);return wr(n)}catch(e){throw t.kill(`SIGKILL`),await i.catch(()=>{}),e}}async function Er(e){let t=e.relativeParentPath?l.join(e.rootPath,...e.relativeParentPath.split(`/`)):e.rootPath;e.mkdir&&await m.mkdir(t,{recursive:!0});let n=l.join(t,e.basename),r=l.join(t,`.${e.basename}.fallback.tmp`);if(e.input.kind===`buffer`)typeof e.input.data==`string`?await m.writeFile(r,e.input.data,{encoding:e.input.encoding??`utf8`,mode:e.mode}):await m.writeFile(r,e.input.data,{mode:e.mode});else{let t=await m.open(r,`w`,e.mode);try{await _(e.input.stream,t.createWriteStream())}finally{await t.close().catch(()=>{})}}await m.rename(r,n);let i=await m.stat(n);return{dev:i.dev,ino:i.ino}}var W=class extends Error{constructor(e,t,n){super(t,n),this.code=e,this.name=`SafeOpenError`}};const G=process.platform!==`win32`&&`O_NOFOLLOW`in f,Dr=f.O_RDONLY|(G?f.O_NOFOLLOW:0),Or=f.O_WRONLY|(G?f.O_NOFOLLOW:0),kr=f.O_WRONLY|f.O_CREAT|f.O_EXCL|(G?f.O_NOFOLLOW:0),Ar=f.O_RDWR|f.O_APPEND|(G?f.O_NOFOLLOW:0),jr=f.O_RDWR|f.O_APPEND|f.O_CREAT|f.O_EXCL|(G?f.O_NOFOLLOW:0),Mr=e=>e.endsWith(l.sep)?e:e+l.sep;async function Nr(e){let t=process.env.HOME||process.env.USERPROFILE||p.homedir();try{t=await m.realpath(t)}catch{}return c(e,{home:t})}async function K(e,t){try{if((await m.lstat(e)).isDirectory())throw new W(`not-file`,`not a file`)}catch(e){if(e instanceof W)throw e}let n;try{n=await m.open(e,Dr)}catch(e){throw w(e)?new W(`not-found`,`file not found`):Qe(e)?new W(`symlink`,`symlink open blocked`,{cause:e}):Ze(e,`EISDIR`)?new W(`not-file`,`not a file`):e}try{let[r,i]=await Promise.all([n.stat(),m.lstat(e)]);if(i.isSymbolicLink())throw new W(`symlink`,`symlink not allowed`);if(!r.isFile())throw new W(`not-file`,`not a file`);if(t?.rejectHardlinks&&r.nlink>1)throw new W(`invalid-path`,`hardlinked path not allowed`);if(!k(r,i))throw new W(`path-mismatch`,`path changed during read`);let a=await m.realpath(e),o=await m.stat(a);if(t?.rejectHardlinks&&o.nlink>1)throw new W(`invalid-path`,`hardlinked path not allowed`);if(!k(r,o))throw new W(`path-mismatch`,`path mismatch`);return{handle:n,realPath:a,stat:r}}catch(e){throw await n.close().catch(()=>{}),e instanceof W?e:w(e)?new W(`not-found`,`file not found`):e}}async function Pr(e){let t;try{t=await m.realpath(e.rootDir)}catch(e){throw w(e)?new W(`not-found`,`root dir not found`):e}let n=Mr(t),r=await Nr(e.relativePath),i=l.resolve(n,r);if(!T(n,i))throw new W(`outside-workspace`,`file is outside workspace root`);return{rootReal:t,rootWithSep:n,resolved:i}}async function Fr(e){let{rootWithSep:t,resolved:n}=await Pr(e),r;try{r=await K(n)}catch(e){throw e instanceof W?e.code===`not-found`?e:new W(`invalid-path`,`path is not a regular file under root`,{cause:e}):e}if(e.rejectHardlinks!==!1&&r.stat.nlink>1)throw await r.handle.close().catch(()=>{}),new W(`invalid-path`,`hardlinked path not allowed`);if(!T(t,r.realPath))throw await r.handle.close().catch(()=>{}),new W(`outside-workspace`,`file is outside workspace root`);return r}async function Ir(e){let t=await Fr({rootDir:e.rootDir,relativePath:e.relativePath,rejectHardlinks:e.rejectHardlinks});try{return await Br({opened:t,maxBytes:e.maxBytes})}finally{await t.handle.close().catch(()=>{})}}async function Lr(e){let t=l.resolve(e.rootDir),n=l.isAbsolute(e.filePath)?l.resolve(e.filePath):l.resolve(t,e.filePath);return await Ir({rootDir:t,relativePath:l.relative(t,n),rejectHardlinks:e.rejectHardlinks,maxBytes:e.maxBytes})}function Rr(e){let t=l.resolve(e.rootDir);return async n=>(await Lr({rootDir:t,filePath:n,rejectHardlinks:e.rejectHardlinks,maxBytes:e.maxBytes})).buffer}async function zr(e){let t=await K(e.filePath);try{return await Br({opened:t,maxBytes:e.maxBytes})}finally{await t.handle.close().catch(()=>{})}}async function Br(e){if(e.maxBytes!==void 0&&e.opened.stat.size>e.maxBytes)throw new W(`too-large`,`file exceeds limit of ${e.maxBytes} bytes (got ${e.opened.stat.size})`);return{buffer:await e.opened.handle.readFile(),realPath:e.opened.realPath,stat:e.opened.stat}}function q(e){i(`security: fs-safe write boundary warning (${e})`)}function Vr(e){let t=l.dirname(e),n=l.basename(e);return l.join(t,`.${n}.${process.pid}.${ne()}.tmp`)}async function Hr(e){let t=await m.open(e.tempPath,kr,e.mode);try{return typeof e.data==`string`?await t.writeFile(e.data,e.encoding??`utf8`):await t.writeFile(e.data),await t.stat()}finally{await t.close().catch(()=>{})}}async function J(e){let t=Mr(await m.realpath(e.rootDir)),n=await K(e.targetPath,{rejectHardlinks:!0});try{if(!k(n.stat,e.expectedIdentity))throw new W(`path-mismatch`,`path changed during write`);if(!T(t,n.realPath))throw new W(`outside-workspace`,`file is outside workspace root`)}finally{await n.handle.close().catch(()=>{})}}async function Ur(e,t){try{return await m.realpath(t)}catch(e){if(!w(e))throw e}let n=process.platform===`linux`?[`/proc/self/fd/${e.fd}`,`/dev/fd/${e.fd}`]:process.platform===`win32`?[]:[`/dev/fd/${e.fd}`];for(let e of n)try{return await m.realpath(e)}catch{}throw new W(`path-mismatch`,`unable to resolve opened file path`)}async function Wr(e){let{rootReal:t,rootWithSep:n,resolved:r}=await Pr(e);try{await Sr({absolutePath:r,rootPath:t,boundaryLabel:`root`})}catch(e){throw new W(`invalid-path`,`path alias escape blocked`,{cause:e})}e.mkdir!==!1&&await m.mkdir(l.dirname(r),{recursive:!0});let i=r;try{let e=await m.realpath(r);if(!T(n,e))throw new W(`outside-workspace`,`file is outside workspace root`);i=e}catch(e){if(e instanceof W||!w(e))throw e}let a=e.mode??384,o,s=!1,c=e.append?Ar:Or,u=e.append?jr:kr;try{try{o=await m.open(i,c,a)}catch(e){if(!w(e))throw e;o=await m.open(i,u,a),s=!0}}catch(e){throw w(e)?new W(`not-found`,`file not found`):Qe(e)?new W(`invalid-path`,`symlink open blocked`,{cause:e}):e}let d=null;try{let t=await o.stat();if(!t.isFile())throw new W(`invalid-path`,`path is not a regular file under root`);if(t.nlink>1)throw new W(`invalid-path`,`hardlinked path not allowed`);try{let e=await m.lstat(i);if(e.isSymbolicLink()||!e.isFile())throw new W(`invalid-path`,`path is not a regular file under root`);if(!k(t,e))throw new W(`path-mismatch`,`path changed during write`)}catch(e){if(!w(e))throw e}let r=await Ur(o,i);d=r;let a=await m.stat(r);if(!k(t,a))throw new W(`path-mismatch`,`path mismatch`);if(a.nlink>1)throw new W(`invalid-path`,`hardlinked path not allowed`);if(!T(n,r))throw new W(`outside-workspace`,`file is outside workspace root`);return e.append!==!0&&e.truncateExisting!==!1&&!s&&await o.truncate(0),{handle:o,createdForWrite:s,openedRealPath:r,openedStat:t}}catch(e){let t=s&&e instanceof W,n=d??i;throw await o.close().catch(()=>{}),t&&await m.rm(n,{force:!0}).catch(()=>{}),e}}async function Gr(e){let t=await Wr({rootDir:e.rootDir,relativePath:e.relativePath,mkdir:e.mkdir,truncateExisting:!1,append:!0});try{let n=``;if(e.prependNewlineIfNeeded===!0&&!t.createdForWrite&&t.openedStat.size>0&&(typeof e.data==`string`&&!e.data.startsWith(`
4
4
  `)||Buffer.isBuffer(e.data)&&e.data.length>0&&e.data[0]!==10)){let e=Buffer.alloc(1),{bytesRead:r}=await t.handle.read(e,0,1,t.openedStat.size-1);r===1&&e[0]!==10&&(n=`
5
5
  `)}if(typeof e.data==`string`){await t.handle.appendFile(`${n}${e.data}`,e.encoding??`utf8`);return}let r=n.length>0?Buffer.concat([Buffer.from(n,`utf8`),e.data]):e.data;await t.handle.appendFile(r)}finally{await t.handle.close().catch(()=>{})}}async function Kr(e){if(process.platform===`win32`){await Zr(e);return}let t=await Yr({rootDir:e.rootDir,relativePath:e.relativePath}),n=await Tr({rootPath:t.rootReal,relativeParentPath:t.relativeParentPath,basename:t.basename,mkdir:e.mkdir!==!1,mode:t.mode,input:{kind:`buffer`,data:e.data,encoding:e.encoding}}).catch(e=>{throw Xr(e)});try{await J({rootDir:e.rootDir,targetPath:t.targetPath,expectedIdentity:n})}catch(e){throw q(`post-write verification failed: ${String(e)}`),e}}async function qr(e){let t=await K(e.sourcePath,{rejectHardlinks:e.rejectSourceHardlinks});if(e.maxBytes!==void 0&&t.stat.size>e.maxBytes)throw await t.handle.close().catch(()=>{}),new W(`too-large`,`file exceeds limit of ${e.maxBytes} bytes (got ${t.stat.size})`);try{if(process.platform===`win32`){await Qr(e,t);return}let n=await Yr({rootDir:e.rootDir,relativePath:e.relativePath}),r=t.handle.createReadStream(),i=await Tr({rootPath:n.rootReal,relativeParentPath:n.relativeParentPath,basename:n.basename,mkdir:e.mkdir!==!1,mode:n.mode,input:{kind:`stream`,stream:r}}).catch(e=>{throw Xr(e)});try{await J({rootDir:e.rootDir,targetPath:n.targetPath,expectedIdentity:i})}catch(e){throw q(`post-copy verification failed: ${String(e)}`),e}}finally{await t.handle.close().catch(()=>{})}}async function Jr(e){await qr({sourcePath:e.sourcePath,rootDir:e.rootDir,relativePath:e.relativePath,mkdir:e.mkdir,rejectSourceHardlinks:!0})}async function Yr(e){let{rootReal:t,rootWithSep:n,resolved:r}=await Pr(e);try{await Sr({absolutePath:r,rootPath:t,boundaryLabel:`root`})}catch(e){throw new W(`invalid-path`,`path alias escape blocked`,{cause:e})}let i=l.relative(t,r);if(i.startsWith(`..`)||l.isAbsolute(i))throw new W(`outside-workspace`,`file is outside workspace root`);let a=i?i.split(l.sep).join(l.posix.sep):``,o=l.posix.basename(a);if(!o||o===`.`||o===`/`)throw new W(`invalid-path`,`invalid target path`);let s=384;try{let t=await Fr({rootDir:e.rootDir,relativePath:e.relativePath,rejectHardlinks:!0});try{if(s=t.stat.mode&511,!T(n,t.realPath))throw new W(`outside-workspace`,`file is outside workspace root`)}finally{await t.handle.close().catch(()=>{})}}catch(e){if(!(e instanceof W)||e.code!==`not-found`)throw e}return{rootReal:t,targetPath:r,relativeParentPath:l.posix.dirname(a)===`.`?``:l.posix.dirname(a),basename:o,mode:s||384}}function Xr(e){return e instanceof W?e:new W(`invalid-path`,`path is not a regular file under root`,{cause:e instanceof Error?e:void 0})}async function Zr(e){let t=await Wr({rootDir:e.rootDir,relativePath:e.relativePath,mkdir:e.mkdir,truncateExisting:!1}),n=t.openedRealPath,r=t.openedStat.mode&511;await t.handle.close().catch(()=>{});let i=null;try{i=Vr(n);let t=await Hr({tempPath:i,data:e.data,encoding:e.encoding,mode:r||384});await m.rename(i,n),i=null;try{await J({rootDir:e.rootDir,targetPath:n,expectedIdentity:t})}catch(e){throw q(`post-write verification failed: ${String(e)}`),e}}finally{i&&await m.rm(i,{force:!0}).catch(()=>{})}}async function Qr(e,t){let n=null,r=!1,i=!1,a=null,o=null,s=!1;try{n=await Wr({rootDir:e.rootDir,relativePath:e.relativePath,mkdir:e.mkdir,truncateExisting:!1});let c=n.openedRealPath,l=n.openedStat.mode&511;await n.handle.close().catch(()=>{}),i=!0,o=Vr(c),a=await m.open(o,kr,l||384);let u=t.handle.createReadStream(),d=a.createWriteStream();u.once(`close`,()=>{r=!0}),d.once(`close`,()=>{s=!0}),await import(`node:stream/promises`).then(({pipeline:e})=>e(u,d));let f=await m.stat(o);s||=(await a.close().catch(()=>{}),!0),a=null,await m.rename(o,c),o=null;try{await J({rootDir:e.rootDir,targetPath:c,expectedIdentity:f})}catch(e){throw q(`post-copy verification failed: ${String(e)}`),e}}catch(e){throw n?.createdForWrite&&await m.rm(n.openedRealPath,{force:!0}).catch(()=>{}),e}finally{o&&await m.rm(o,{force:!0}).catch(()=>{}),r||await t.handle.close().catch(()=>{}),a&&!s&&await a.close().catch(()=>{}),n&&!i&&await n.handle.close().catch(()=>{})}}const $r=6*1024*1024,ei=100*1024*1024;function ti(e){if(e){if(e.startsWith(`image/`))return`image`;if(e.startsWith(`audio/`))return`audio`;if(e.startsWith(`video/`))return`video`;if(e===`application/pdf`||e.startsWith(`text/`)||e.startsWith(`application/`))return`document`}}function ni(e){switch(e){case`image`:return $r;case`audio`:return 16777216;case`video`:return 16777216;case`document`:return ei;default:return ei}}const ri={"image/heic":`.heic`,"image/heif":`.heif`,"image/jpeg":`.jpg`,"image/png":`.png`,"image/webp":`.webp`,"image/gif":`.gif`,"audio/ogg":`.ogg`,"audio/mpeg":`.mp3`,"audio/wav":`.wav`,"audio/flac":`.flac`,"audio/aac":`.aac`,"audio/opus":`.opus`,"audio/x-m4a":`.m4a`,"audio/mp4":`.m4a`,"video/mp4":`.mp4`,"video/quicktime":`.mov`,"application/pdf":`.pdf`,"application/json":`.json`,"application/zip":`.zip`,"application/gzip":`.gz`,"application/x-tar":`.tar`,"application/x-7z-compressed":`.7z`,"application/vnd.rar":`.rar`,"application/msword":`.doc`,"application/vnd.ms-excel":`.xls`,"application/vnd.ms-powerpoint":`.ppt`,"application/vnd.openxmlformats-officedocument.wordprocessingml.document":`.docx`,"application/vnd.openxmlformats-officedocument.spreadsheetml.sheet":`.xlsx`,"application/vnd.openxmlformats-officedocument.presentationml.presentation":`.pptx`,"text/csv":`.csv`,"text/plain":`.txt`,"text/markdown":`.md`},ii={...Object.fromEntries(Object.entries(ri).map(([e,t])=>[t,e])),".jpeg":`image/jpeg`,".js":`text/javascript`},ai=new Set([`.aac`,`.caf`,`.flac`,`.m4a`,`.mp3`,`.oga`,`.ogg`,`.opus`,`.wav`]);function Y(e){if(e)return e.split(`;`)[0]?.trim().toLowerCase()||void 0}async function oi(e){if(e)try{return(await v(e))?.mime??void 0}catch{return}}function X(e){if(e){try{if(/^https?:\/\//i.test(e)){let t=new URL(e);return l.extname(t.pathname).toLowerCase()||void 0}}catch{}return l.extname(e).toLowerCase()||void 0}}function si(e){let t=X(e);return t?ai.has(t):!1}function ci(e){return ui(e)}function li(e){if(!e)return!0;let t=e.toLowerCase();return t===`application/octet-stream`||t===`application/zip`}async function ui(e){let t=X(e.filePath),n=t?ii[t]:void 0,r=Y(e.headerMime),i=await oi(e.buffer);if(i&&(!li(i)||!n))return i;if(n)return n;if(r&&!li(r))return r;if(i)return i;if(r)return r}function di(e){let t=Y(e);if(t)return ri[t]}function fi(e){return e.contentType?.toLowerCase()===`image/gif`?!0:X(e.fileName)===`.gif`}function pi(e){if(e)switch(e.toLowerCase()){case`jpg`:case`jpeg`:return`image/jpeg`;case`heic`:return`image/heic`;case`heif`:return`image/heif`;case`png`:return`image/png`;case`webp`:return`image/webp`;case`gif`:return`image/gif`;default:return}}function mi(e){return ti(Y(e))}function Z(e){try{return te(e).isFile()}catch{return!1}}function hi(e,t){if(e.includes(`/`)||e.includes(`\\`)||l.isAbsolute(e))return e;let n=(t.PATH??t.Path??process.env.PATH??process.env.Path??``).split(`;`).map(e=>e.trim()).filter(Boolean),r=l.extname(e).length>0,i=t.PATHEXT??t.Pathext??process.env.PATHEXT??process.env.Pathext??`.EXE;.CMD;.BAT;.COM`,a=r?[``]:i.split(`;`).map(e=>e.trim()).filter(Boolean).map(e=>e.startsWith(`.`)?e:`.${e}`);for(let t of n)for(let n of a)for(let r of[n,n.toLowerCase(),n.toUpperCase()]){let n=l.join(t,`${e}${r}`);if(Z(n))return n}return e}function gi(e){if(!Z(e))return null;try{let t=ee(e,`utf8`),n=[];for(let r of t.matchAll(/"([^"\r\n]*)"/g)){let t=(r[1]??``).match(/%~?dp0%?\s*[\\/]*(.*)$/i)?.[1]?.trim();if(!t)continue;let i=t.replace(/[\\/]+/g,l.sep).replace(/^[\\/]+/,``),a=l.resolve(l.dirname(e),i);Z(a)&&n.push(a)}return n.find(e=>{let t=l.basename(e).toLowerCase();return t!==`node.exe`&&t!==`node`})??null}catch{return null}}function _i(e,t){if(typeof t==`string`)return t.trim()||null;if(!t||typeof t!=`object`)return null;if(e){let n=t[e];if(typeof n==`string`&&n.trim())return n.trim()}for(let e of Object.values(t))if(typeof e==`string`&&e.trim())return e.trim();return null}function vi(e,t){if(!t)return null;let n=l.dirname(e),r=[l.resolve(n,`..`,t),l.resolve(n,`node_modules`,t)];for(let e of r){let n=l.join(e,`package.json`);if(Z(n))try{let r=_i(t,JSON.parse(ee(n,`utf8`)).bin);if(!r)continue;let i=l.resolve(e,r);if(Z(i))return i}catch{}}return null}function yi(e){let t=e.platform??process.platform,n=e.env??process.env,r=e.execPath??process.execPath;if(t!==`win32`)return{command:e.command,leadingArgv:[],resolution:`direct`};let i=hi(e.command,n),a=l.extname(i).toLowerCase();if(a===`.js`||a===`.cjs`||a===`.mjs`)return{command:r,leadingArgv:[i],resolution:`node-entrypoint`,windowsHide:!0};if(a===`.cmd`||a===`.bat`){let t=gi(i)??vi(i,e.packageName);return t?l.extname(t).toLowerCase()===`.exe`?{command:t,leadingArgv:[],resolution:`exe-entrypoint`,windowsHide:!0}:{command:r,leadingArgv:[t],resolution:`node-entrypoint`,windowsHide:!0}:{command:i,leadingArgv:[],resolution:`unresolved-wrapper`}}return{command:i,leadingArgv:[],resolution:`direct`}}function bi(e){if(e.candidate.resolution!==`unresolved-wrapper`)return{command:e.candidate.command,leadingArgv:e.candidate.leadingArgv,resolution:e.candidate.resolution,windowsHide:e.candidate.windowsHide};if(e.allowShellFallback!==!1)return{command:e.candidate.command,leadingArgv:[],resolution:`shell-fallback`,shell:!0};throw Error(`${l.basename(e.candidate.command)} wrapper resolved, but no executable/Node entrypoint could be resolved without shell execution.`)}function xi(e){return bi({candidate:yi(e),allowShellFallback:e.allowShellFallback})}function Si(e,t){return{command:e.command,argv:[...e.leadingArgv,...t],resolution:e.resolution,shell:e.shell,windowsHide:e.windowsHide}}function Q(e,t=process.env,n=()=>s(t,p.homedir)){let r=o(t,n),i=C(e??`main`);return l.join(r,`agents`,i,`sessions`)}function Ci(e,t=process.env,n=()=>s(t,p.homedir)){return Q(e,t,n)}function wi(e){return l.join(Q(e),`sessions.json`)}function Ti(e){let t=e.agentId?.trim(),n=e.storePath?.trim();if(n&&n!==`(multiple)`){let e=l.dirname(l.resolve(n));return t?{sessionsDir:e,agentId:t}:{sessionsDir:e}}if(t)return{agentId:t}}const Ei=/^[a-z0-9][a-z0-9._-]{0,127}$/i;function Di(e){let t=e.trim();if(!Ei.test(t))throw Error(`Invalid session ID: ${e}`);return t}function Oi(e){let t=e?.sessionsDir?.trim();return t?l.resolve(t):Q(e?.agentId)}function ki(e,t){let n=$(l.resolve(e))??l.resolve(e),r=$(t)??t,i=l.relative(n,r);if(!(!i||i.startsWith(`..`)||l.isAbsolute(i)))return l.resolve(n,i)}function Ai(e,t){let n=l.resolve(e);if(l.basename(n)!==`sessions`)return;let r=l.dirname(n),i=l.dirname(r);if(l.basename(i)!==`agents`)return;let a=l.dirname(i);return l.join(a,`agents`,C(t),`sessions`)}function ji(e){let t=l.normalize(l.resolve(e)).split(l.sep).filter(Boolean),n=t.lastIndexOf(`sessions`);return n<2||t[n-2]!==`agents`?null:{parts:t,sessionsIndex:n}}function Mi(e){let t=ji(e);if(!t)return;let{parts:n,sessionsIndex:r}=t;return n[r-1]||void 0}function Ni(e,t){let n=ji(e);if(!n)return;let{parts:r,sessionsIndex:i}=n,a=r[i-1];if(!a)return;let o=C(a);if(o!==a.toLowerCase()||o!==C(t))return;let s=r.slice(i+1);if(s.length!==1)return;let c=s[0];if(!(!c||c===`.`||c===`..`))return l.normalize(l.resolve(e))}function $(e){try{return d.realpathSync(e)}catch{return}}function Pi(e,t,n){let r=t.trim();if(!r)throw Error(`Session file path must not be empty`);let i=l.resolve(e),a=$(i)??i,o=l.isAbsolute(r)?$(r)??r:r,s=l.isAbsolute(o)?l.relative(a,o):o;if(s.startsWith(`..`)&&l.isAbsolute(o)){let e=e=>{let t=C(e),n=Ai(a,t);if(n){let e=ki(n,o);if(e)return e}return ki(Q(t),o)},t=n?.agentId?.trim();if(t){let n=e(t);if(n)return n}let r=Mi(o);if(r){let t=e(r);if(t)return t;let n=Ni(o,r);if(n)return n}}if(!s||s.startsWith(`..`)||l.isAbsolute(s))throw Error(`Session file path must be within sessions directory`);return l.resolve(a,s)}function Fi(e,t,n){let r=Di(e),i=typeof n==`string`?encodeURIComponent(n):typeof n==`number`?String(n):void 0;return Pi(t,i===void 0?`${r}.jsonl`:`${r}-topic-${i}.jsonl`)}function Ii(e,t,n){return Fi(e,Q(t),n)}function Li(e,t,n){let r=Oi(n),i=t?.sessionFile?.trim();if(i)try{return Pi(r,i,{agentId:n?.agentId})}catch{}return Fi(e,r)}function Ri(e,t){let n=C(t?.agentId??`main`);if(!e)return wi(n);if(e.includes(`{agentId}`)){let t=e.replaceAll(`{agentId}`,n);return t.startsWith(`~`)?l.resolve(c(t,{home:s(process.env,p.homedir),env:process.env,homedir:p.homedir})):l.resolve(t)}return e.startsWith(`~`)?l.resolve(c(e,{home:s(process.env,p.homedir),env:process.env,homedir:p.homedir})):l.resolve(e)}export{L as $,xr as A,je as At,H as B,xe as Bt,qr as C,ze as Ct,zr as D,Pe as Dt,Ir as E,Ce as Et,ir as F,Re as Ft,Mn as G,re as Gt,zn as H,b as Ht,nr as I,Ne as It,Pn as J,ce as Jt,Wn as K,ie as Kt,qn as L,Oe as Lt,vr as M,C as Mt,gr as N,ke as Nt,Jr as O,Fe as Ot,_r as P,Ae as Pt,R as Q,Un as R,de as Rt,Gr as S,Be as St,Fr as T,x as Tt,In as U,ae as Ut,Kn as V,ue as Vt,Gn as W,oe as Wt,M as X,Nn as Y,dn as Z,Y as _,Ke as _t,Fi as a,En as at,ti as b,He as bt,Si as c,on as ct,di as d,Wt as dt,F as et,X as f,Vt as ft,mi as g,Ye as gt,fi as h,T as ht,Ii as i,Sn as it,Sr as j,Me as jt,Kr as k,Le as kt,xi as l,Ut as lt,si as m,w as mt,Li as n,P as nt,Ci as o,wn as ot,pi as p,D as pt,Hn as q,y as qt,Ti as r,I as rt,Ri as s,an as st,wi as t,N as tt,ci as u,qt as ut,$r as v,Ge as vt,Rr as w,Ve as wt,W as x,Ue as xt,ni as y,We as yt,jn as z,be as zt};
6
+ //# sourceMappingURL=paths-Do0djuaj.js.map
@@ -3,3 +3,4 @@ import{c as e,d as t,l as n}from"./paths-DaRoqzBQ.js";import{D as r,T as i,Y as
3
3
  `);function Tr(e){let t=e.trim().split(/\r?\n/).map(e=>e.trim()).filter(Boolean).at(-1);if(!t)throw Error(`Pinned write helper returned no identity`);let[n,r]=t.split(`|`),i=Number.parseInt(n??``,10),a=Number.parseInt(r??``,10);if(!Number.isFinite(i)||!Number.isFinite(a))throw Error(`Pinned write helper returned invalid identity: ${t}`);return{dev:i,ino:a}}async function Er(e){let t=ne(`python3`,[`-c`,wr,e.rootPath,e.relativeParentPath,e.basename,e.mkdir?`1`:`0`,(e.mode||384).toString(8)],{stdio:[`pipe`,`pipe`,`pipe`]}),n=``,r=``;t.stdout.setEncoding?.(`utf8`),t.stderr.setEncoding?.(`utf8`),t.stdout.on(`data`,e=>{n+=e}),t.stderr.on(`data`,e=>{r+=e});let i=h(t,`close`);try{if(!t.stdin){let t=await Dr(e);return await i.catch(()=>{}),t}if(e.input.kind===`buffer`){let n=e.input;await new Promise((e,r)=>{if(t.stdin.once(`error`,r),typeof n.data==`string`){t.stdin.end(n.data,n.encoding??`utf8`,()=>e());return}t.stdin.end(n.data,()=>e())})}else await g(e.input.stream,t.stdin);let[a,o]=await i;if(a!==0)throw Error(r.trim()||`Pinned write helper failed with code ${a??`null`} (${o??`?`})`);return Tr(n)}catch(e){throw t.kill(`SIGKILL`),await i.catch(()=>{}),e}}async function Dr(e){let t=e.relativeParentPath?f.join(e.rootPath,...e.relativeParentPath.split(`/`)):e.rootPath;e.mkdir&&await m.mkdir(t,{recursive:!0});let n=f.join(t,e.basename),r=f.join(t,`.${e.basename}.fallback.tmp`);if(e.input.kind===`buffer`)typeof e.input.data==`string`?await m.writeFile(r,e.input.data,{encoding:e.input.encoding??`utf8`,mode:e.mode}):await m.writeFile(r,e.input.data,{mode:e.mode});else{let t=await m.open(r,`w`,e.mode);try{await g(e.input.stream,t.createWriteStream())}finally{await t.close().catch(()=>{})}}await m.rename(r,n);let i=await m.stat(n);return{dev:i.dev,ino:i.ino}}var U=class extends Error{constructor(e,t,n){super(t,n),this.code=e,this.name=`SafeOpenError`}};const W=process.platform!==`win32`&&`O_NOFOLLOW`in u,Or=u.O_RDONLY|(W?u.O_NOFOLLOW:0),kr=u.O_WRONLY|(W?u.O_NOFOLLOW:0),Ar=u.O_WRONLY|u.O_CREAT|u.O_EXCL|(W?u.O_NOFOLLOW:0),jr=u.O_RDWR|u.O_APPEND|(W?u.O_NOFOLLOW:0),Mr=u.O_RDWR|u.O_APPEND|u.O_CREAT|u.O_EXCL|(W?u.O_NOFOLLOW:0),Nr=e=>e.endsWith(f.sep)?e:e+f.sep;async function Pr(e){let t=process.env.HOME||process.env.USERPROFILE||p.homedir();try{t=await m.realpath(t)}catch{}return n(e,{home:t})}async function G(e,t){try{if((await m.lstat(e)).isDirectory())throw new U(`not-file`,`not a file`)}catch(e){if(e instanceof U)throw e}let n;try{n=await m.open(e,Or)}catch(e){throw C(e)?new U(`not-found`,`file not found`):$e(e)?new U(`symlink`,`symlink open blocked`,{cause:e}):Qe(e,`EISDIR`)?new U(`not-file`,`not a file`):e}try{let[r,i]=await Promise.all([n.stat(),m.lstat(e)]);if(i.isSymbolicLink())throw new U(`symlink`,`symlink not allowed`);if(!r.isFile())throw new U(`not-file`,`not a file`);if(t?.rejectHardlinks&&r.nlink>1)throw new U(`invalid-path`,`hardlinked path not allowed`);if(!O(r,i))throw new U(`path-mismatch`,`path changed during read`);let a=await m.realpath(e),o=await m.stat(a);if(t?.rejectHardlinks&&o.nlink>1)throw new U(`invalid-path`,`hardlinked path not allowed`);if(!O(r,o))throw new U(`path-mismatch`,`path mismatch`);return{handle:n,realPath:a,stat:r}}catch(e){throw await n.close().catch(()=>{}),e instanceof U?e:C(e)?new U(`not-found`,`file not found`):e}}async function Fr(e){let t;try{t=await m.realpath(e.rootDir)}catch(e){throw C(e)?new U(`not-found`,`root dir not found`):e}let n=Nr(t),r=await Pr(e.relativePath),i=f.resolve(n,r);if(!w(n,i))throw new U(`outside-workspace`,`file is outside workspace root`);return{rootReal:t,rootWithSep:n,resolved:i}}async function Ir(e){let{rootWithSep:t,resolved:n}=await Fr(e),r;try{r=await G(n)}catch(e){throw e instanceof U?e.code===`not-found`?e:new U(`invalid-path`,`path is not a regular file under root`,{cause:e}):e}if(e.rejectHardlinks!==!1&&r.stat.nlink>1)throw await r.handle.close().catch(()=>{}),new U(`invalid-path`,`hardlinked path not allowed`);if(!w(t,r.realPath))throw await r.handle.close().catch(()=>{}),new U(`outside-workspace`,`file is outside workspace root`);return r}async function Lr(e){let t=await Ir({rootDir:e.rootDir,relativePath:e.relativePath,rejectHardlinks:e.rejectHardlinks});try{return await Vr({opened:t,maxBytes:e.maxBytes})}finally{await t.handle.close().catch(()=>{})}}async function Rr(e){let t=f.resolve(e.rootDir),n=f.isAbsolute(e.filePath)?f.resolve(e.filePath):f.resolve(t,e.filePath);return await Lr({rootDir:t,relativePath:f.relative(t,n),rejectHardlinks:e.rejectHardlinks,maxBytes:e.maxBytes})}function zr(e){let t=f.resolve(e.rootDir);return async n=>(await Rr({rootDir:t,filePath:n,rejectHardlinks:e.rejectHardlinks,maxBytes:e.maxBytes})).buffer}async function Br(e){let t=await G(e.filePath);try{return await Vr({opened:t,maxBytes:e.maxBytes})}finally{await t.handle.close().catch(()=>{})}}async function Vr(e){if(e.maxBytes!==void 0&&e.opened.stat.size>e.maxBytes)throw new U(`too-large`,`file exceeds limit of ${e.maxBytes} bytes (got ${e.opened.stat.size})`);return{buffer:await e.opened.handle.readFile(),realPath:e.opened.realPath,stat:e.opened.stat}}function K(e){s(`security: fs-safe write boundary warning (${e})`)}function Hr(e){let t=f.dirname(e),n=f.basename(e);return f.join(t,`.${n}.${process.pid}.${te()}.tmp`)}async function Ur(e){let t=await m.open(e.tempPath,Ar,e.mode);try{return typeof e.data==`string`?await t.writeFile(e.data,e.encoding??`utf8`):await t.writeFile(e.data),await t.stat()}finally{await t.close().catch(()=>{})}}async function q(e){let t=Nr(await m.realpath(e.rootDir)),n=await G(e.targetPath,{rejectHardlinks:!0});try{if(!O(n.stat,e.expectedIdentity))throw new U(`path-mismatch`,`path changed during write`);if(!w(t,n.realPath))throw new U(`outside-workspace`,`file is outside workspace root`)}finally{await n.handle.close().catch(()=>{})}}async function Wr(e,t){try{return await m.realpath(t)}catch(e){if(!C(e))throw e}let n=process.platform===`linux`?[`/proc/self/fd/${e.fd}`,`/dev/fd/${e.fd}`]:process.platform===`win32`?[]:[`/dev/fd/${e.fd}`];for(let e of n)try{return await m.realpath(e)}catch{}throw new U(`path-mismatch`,`unable to resolve opened file path`)}async function J(e){let{rootReal:t,rootWithSep:n,resolved:r}=await Fr(e);try{await Cr({absolutePath:r,rootPath:t,boundaryLabel:`root`})}catch(e){throw new U(`invalid-path`,`path alias escape blocked`,{cause:e})}e.mkdir!==!1&&await m.mkdir(f.dirname(r),{recursive:!0});let i=r;try{let e=await m.realpath(r);if(!w(n,e))throw new U(`outside-workspace`,`file is outside workspace root`);i=e}catch(e){if(e instanceof U||!C(e))throw e}let a=e.mode??384,o,s=!1,c=e.append?jr:kr,l=e.append?Mr:Ar;try{try{o=await m.open(i,c,a)}catch(e){if(!C(e))throw e;o=await m.open(i,l,a),s=!0}}catch(e){throw C(e)?new U(`not-found`,`file not found`):$e(e)?new U(`invalid-path`,`symlink open blocked`,{cause:e}):e}let u=null;try{let t=await o.stat();if(!t.isFile())throw new U(`invalid-path`,`path is not a regular file under root`);if(t.nlink>1)throw new U(`invalid-path`,`hardlinked path not allowed`);try{let e=await m.lstat(i);if(e.isSymbolicLink()||!e.isFile())throw new U(`invalid-path`,`path is not a regular file under root`);if(!O(t,e))throw new U(`path-mismatch`,`path changed during write`)}catch(e){if(!C(e))throw e}let r=await Wr(o,i);u=r;let a=await m.stat(r);if(!O(t,a))throw new U(`path-mismatch`,`path mismatch`);if(a.nlink>1)throw new U(`invalid-path`,`hardlinked path not allowed`);if(!w(n,r))throw new U(`outside-workspace`,`file is outside workspace root`);return e.append!==!0&&e.truncateExisting!==!1&&!s&&await o.truncate(0),{handle:o,createdForWrite:s,openedRealPath:r,openedStat:t}}catch(e){let t=s&&e instanceof U,n=u??i;throw await o.close().catch(()=>{}),t&&await m.rm(n,{force:!0}).catch(()=>{}),e}}async function Gr(e){let t=await J({rootDir:e.rootDir,relativePath:e.relativePath,mkdir:e.mkdir,truncateExisting:!1,append:!0});try{let n=``;if(e.prependNewlineIfNeeded===!0&&!t.createdForWrite&&t.openedStat.size>0&&(typeof e.data==`string`&&!e.data.startsWith(`
4
4
  `)||Buffer.isBuffer(e.data)&&e.data.length>0&&e.data[0]!==10)){let e=Buffer.alloc(1),{bytesRead:r}=await t.handle.read(e,0,1,t.openedStat.size-1);r===1&&e[0]!==10&&(n=`
5
5
  `)}if(typeof e.data==`string`){await t.handle.appendFile(`${n}${e.data}`,e.encoding??`utf8`);return}let r=n.length>0?Buffer.concat([Buffer.from(n,`utf8`),e.data]):e.data;await t.handle.appendFile(r)}finally{await t.handle.close().catch(()=>{})}}async function Kr(e){if(process.platform===`win32`){await Zr(e);return}let t=await Yr({rootDir:e.rootDir,relativePath:e.relativePath}),n=await Er({rootPath:t.rootReal,relativeParentPath:t.relativeParentPath,basename:t.basename,mkdir:e.mkdir!==!1,mode:t.mode,input:{kind:`buffer`,data:e.data,encoding:e.encoding}}).catch(e=>{throw Xr(e)});try{await q({rootDir:e.rootDir,targetPath:t.targetPath,expectedIdentity:n})}catch(e){throw K(`post-write verification failed: ${String(e)}`),e}}async function qr(e){let t=await G(e.sourcePath,{rejectHardlinks:e.rejectSourceHardlinks});if(e.maxBytes!==void 0&&t.stat.size>e.maxBytes)throw await t.handle.close().catch(()=>{}),new U(`too-large`,`file exceeds limit of ${e.maxBytes} bytes (got ${t.stat.size})`);try{if(process.platform===`win32`){await Qr(e,t);return}let n=await Yr({rootDir:e.rootDir,relativePath:e.relativePath}),r=t.handle.createReadStream(),i=await Er({rootPath:n.rootReal,relativeParentPath:n.relativeParentPath,basename:n.basename,mkdir:e.mkdir!==!1,mode:n.mode,input:{kind:`stream`,stream:r}}).catch(e=>{throw Xr(e)});try{await q({rootDir:e.rootDir,targetPath:n.targetPath,expectedIdentity:i})}catch(e){throw K(`post-copy verification failed: ${String(e)}`),e}}finally{await t.handle.close().catch(()=>{})}}async function Jr(e){await qr({sourcePath:e.sourcePath,rootDir:e.rootDir,relativePath:e.relativePath,mkdir:e.mkdir,rejectSourceHardlinks:!0})}async function Yr(e){let{rootReal:t,rootWithSep:n,resolved:r}=await Fr(e);try{await Cr({absolutePath:r,rootPath:t,boundaryLabel:`root`})}catch(e){throw new U(`invalid-path`,`path alias escape blocked`,{cause:e})}let i=f.relative(t,r);if(i.startsWith(`..`)||f.isAbsolute(i))throw new U(`outside-workspace`,`file is outside workspace root`);let a=i?i.split(f.sep).join(f.posix.sep):``,o=f.posix.basename(a);if(!o||o===`.`||o===`/`)throw new U(`invalid-path`,`invalid target path`);let s=384;try{let t=await Ir({rootDir:e.rootDir,relativePath:e.relativePath,rejectHardlinks:!0});try{if(s=t.stat.mode&511,!w(n,t.realPath))throw new U(`outside-workspace`,`file is outside workspace root`)}finally{await t.handle.close().catch(()=>{})}}catch(e){if(!(e instanceof U)||e.code!==`not-found`)throw e}return{rootReal:t,targetPath:r,relativeParentPath:f.posix.dirname(a)===`.`?``:f.posix.dirname(a),basename:o,mode:s||384}}function Xr(e){return e instanceof U?e:new U(`invalid-path`,`path is not a regular file under root`,{cause:e instanceof Error?e:void 0})}async function Zr(e){let t=await J({rootDir:e.rootDir,relativePath:e.relativePath,mkdir:e.mkdir,truncateExisting:!1}),n=t.openedRealPath,r=t.openedStat.mode&511;await t.handle.close().catch(()=>{});let i=null;try{i=Hr(n);let t=await Ur({tempPath:i,data:e.data,encoding:e.encoding,mode:r||384});await m.rename(i,n),i=null;try{await q({rootDir:e.rootDir,targetPath:n,expectedIdentity:t})}catch(e){throw K(`post-write verification failed: ${String(e)}`),e}}finally{i&&await m.rm(i,{force:!0}).catch(()=>{})}}async function Qr(e,t){let n=null,r=!1,i=!1,a=null,o=null,s=!1;try{n=await J({rootDir:e.rootDir,relativePath:e.relativePath,mkdir:e.mkdir,truncateExisting:!1});let c=n.openedRealPath,l=n.openedStat.mode&511;await n.handle.close().catch(()=>{}),i=!0,o=Hr(c),a=await m.open(o,Ar,l||384);let u=t.handle.createReadStream(),d=a.createWriteStream();u.once(`close`,()=>{r=!0}),d.once(`close`,()=>{s=!0}),await import(`node:stream/promises`).then(({pipeline:e})=>e(u,d));let ee=await m.stat(o);s||=(await a.close().catch(()=>{}),!0),a=null,await m.rename(o,c),o=null;try{await q({rootDir:e.rootDir,targetPath:c,expectedIdentity:ee})}catch(e){throw K(`post-copy verification failed: ${String(e)}`),e}}catch(e){throw n?.createdForWrite&&await m.rm(n.openedRealPath,{force:!0}).catch(()=>{}),e}finally{o&&await m.rm(o,{force:!0}).catch(()=>{}),r||await t.handle.close().catch(()=>{}),a&&!s&&await a.close().catch(()=>{}),n&&!i&&await n.handle.close().catch(()=>{})}}const $r=6*1024*1024,ei=100*1024*1024;function ti(e){if(e){if(e.startsWith(`image/`))return`image`;if(e.startsWith(`audio/`))return`audio`;if(e.startsWith(`video/`))return`video`;if(e===`application/pdf`||e.startsWith(`text/`)||e.startsWith(`application/`))return`document`}}function ni(e){switch(e){case`image`:return $r;case`audio`:return 16777216;case`video`:return 16777216;case`document`:return ei;default:return ei}}const ri={"image/heic":`.heic`,"image/heif":`.heif`,"image/jpeg":`.jpg`,"image/png":`.png`,"image/webp":`.webp`,"image/gif":`.gif`,"audio/ogg":`.ogg`,"audio/mpeg":`.mp3`,"audio/wav":`.wav`,"audio/flac":`.flac`,"audio/aac":`.aac`,"audio/opus":`.opus`,"audio/x-m4a":`.m4a`,"audio/mp4":`.m4a`,"video/mp4":`.mp4`,"video/quicktime":`.mov`,"application/pdf":`.pdf`,"application/json":`.json`,"application/zip":`.zip`,"application/gzip":`.gz`,"application/x-tar":`.tar`,"application/x-7z-compressed":`.7z`,"application/vnd.rar":`.rar`,"application/msword":`.doc`,"application/vnd.ms-excel":`.xls`,"application/vnd.ms-powerpoint":`.ppt`,"application/vnd.openxmlformats-officedocument.wordprocessingml.document":`.docx`,"application/vnd.openxmlformats-officedocument.spreadsheetml.sheet":`.xlsx`,"application/vnd.openxmlformats-officedocument.presentationml.presentation":`.pptx`,"text/csv":`.csv`,"text/plain":`.txt`,"text/markdown":`.md`},ii={...Object.fromEntries(Object.entries(ri).map(([e,t])=>[t,e])),".jpeg":`image/jpeg`,".js":`text/javascript`},ai=new Set([`.aac`,`.caf`,`.flac`,`.m4a`,`.mp3`,`.oga`,`.ogg`,`.opus`,`.wav`]);function Y(e){if(e)return e.split(`;`)[0]?.trim().toLowerCase()||void 0}async function oi(e){if(e)try{return(await _(e))?.mime??void 0}catch{return}}function X(e){if(e){try{if(/^https?:\/\//i.test(e)){let t=new URL(e);return f.extname(t.pathname).toLowerCase()||void 0}}catch{}return f.extname(e).toLowerCase()||void 0}}function si(e){let t=X(e);return t?ai.has(t):!1}function ci(e){return ui(e)}function li(e){if(!e)return!0;let t=e.toLowerCase();return t===`application/octet-stream`||t===`application/zip`}async function ui(e){let t=X(e.filePath),n=t?ii[t]:void 0,r=Y(e.headerMime),i=await oi(e.buffer);if(i&&(!li(i)||!n))return i;if(n)return n;if(r&&!li(r))return r;if(i)return i;if(r)return r}function di(e){let t=Y(e);if(t)return ri[t]}function fi(e){return e.contentType?.toLowerCase()===`image/gif`?!0:X(e.fileName)===`.gif`}function pi(e){if(e)switch(e.toLowerCase()){case`jpg`:case`jpeg`:return`image/jpeg`;case`heic`:return`image/heic`;case`heif`:return`image/heif`;case`png`:return`image/png`;case`webp`:return`image/webp`;case`gif`:return`image/gif`;default:return}}function mi(e){return ti(Y(e))}function Z(e){try{return ee(e).isFile()}catch{return!1}}function hi(e,t){if(e.includes(`/`)||e.includes(`\\`)||f.isAbsolute(e))return e;let n=(t.PATH??t.Path??process.env.PATH??process.env.Path??``).split(`;`).map(e=>e.trim()).filter(Boolean),r=f.extname(e).length>0,i=t.PATHEXT??t.Pathext??process.env.PATHEXT??process.env.Pathext??`.EXE;.CMD;.BAT;.COM`,a=r?[``]:i.split(`;`).map(e=>e.trim()).filter(Boolean).map(e=>e.startsWith(`.`)?e:`.${e}`);for(let t of n)for(let n of a)for(let r of[n,n.toLowerCase(),n.toUpperCase()]){let n=f.join(t,`${e}${r}`);if(Z(n))return n}return e}function gi(e){if(!Z(e))return null;try{let t=d(e,`utf8`),n=[];for(let r of t.matchAll(/"([^"\r\n]*)"/g)){let t=(r[1]??``).match(/%~?dp0%?\s*[\\/]*(.*)$/i)?.[1]?.trim();if(!t)continue;let i=t.replace(/[\\/]+/g,f.sep).replace(/^[\\/]+/,``),a=f.resolve(f.dirname(e),i);Z(a)&&n.push(a)}return n.find(e=>{let t=f.basename(e).toLowerCase();return t!==`node.exe`&&t!==`node`})??null}catch{return null}}function _i(e,t){if(typeof t==`string`)return t.trim()||null;if(!t||typeof t!=`object`)return null;if(e){let n=t[e];if(typeof n==`string`&&n.trim())return n.trim()}for(let e of Object.values(t))if(typeof e==`string`&&e.trim())return e.trim();return null}function vi(e,t){if(!t)return null;let n=f.dirname(e),r=[f.resolve(n,`..`,t),f.resolve(n,`node_modules`,t)];for(let e of r){let n=f.join(e,`package.json`);if(Z(n))try{let r=_i(t,JSON.parse(d(n,`utf8`)).bin);if(!r)continue;let i=f.resolve(e,r);if(Z(i))return i}catch{}}return null}function yi(e){let t=e.platform??process.platform,n=e.env??process.env,r=e.execPath??process.execPath;if(t!==`win32`)return{command:e.command,leadingArgv:[],resolution:`direct`};let i=hi(e.command,n),a=f.extname(i).toLowerCase();if(a===`.js`||a===`.cjs`||a===`.mjs`)return{command:r,leadingArgv:[i],resolution:`node-entrypoint`,windowsHide:!0};if(a===`.cmd`||a===`.bat`){let t=gi(i)??vi(i,e.packageName);return t?f.extname(t).toLowerCase()===`.exe`?{command:t,leadingArgv:[],resolution:`exe-entrypoint`,windowsHide:!0}:{command:r,leadingArgv:[t],resolution:`node-entrypoint`,windowsHide:!0}:{command:i,leadingArgv:[],resolution:`unresolved-wrapper`}}return{command:i,leadingArgv:[],resolution:`direct`}}function bi(e){if(e.candidate.resolution!==`unresolved-wrapper`)return{command:e.candidate.command,leadingArgv:e.candidate.leadingArgv,resolution:e.candidate.resolution,windowsHide:e.candidate.windowsHide};if(e.allowShellFallback!==!1)return{command:e.candidate.command,leadingArgv:[],resolution:`shell-fallback`,shell:!0};throw Error(`${f.basename(e.candidate.command)} wrapper resolved, but no executable/Node entrypoint could be resolved without shell execution.`)}function xi(e){return bi({candidate:yi(e),allowShellFallback:e.allowShellFallback})}function Si(e,t){return{command:e.command,argv:[...e.leadingArgv,...t],resolution:e.resolution,shell:e.shell,windowsHide:e.windowsHide}}function Q(n,r=process.env,i=()=>t(r,p.homedir)){let a=e(r,i),o=S(n??`main`);return f.join(a,`agents`,o,`sessions`)}function Ci(e,n=process.env,r=()=>t(n,p.homedir)){return Q(e,n,r)}function wi(e){return f.join(Q(e),`sessions.json`)}function Ti(e){let t=e.agentId?.trim(),n=e.storePath?.trim();if(n&&n!==`(multiple)`){let e=f.dirname(f.resolve(n));return t?{sessionsDir:e,agentId:t}:{sessionsDir:e}}if(t)return{agentId:t}}const Ei=/^[a-z0-9][a-z0-9._-]{0,127}$/i;function Di(e){let t=e.trim();if(!Ei.test(t))throw Error(`Invalid session ID: ${e}`);return t}function Oi(e){let t=e?.sessionsDir?.trim();return t?f.resolve(t):Q(e?.agentId)}function ki(e,t){let n=$(f.resolve(e))??f.resolve(e),r=$(t)??t,i=f.relative(n,r);if(!(!i||i.startsWith(`..`)||f.isAbsolute(i)))return f.resolve(n,i)}function Ai(e,t){let n=f.resolve(e);if(f.basename(n)!==`sessions`)return;let r=f.dirname(n),i=f.dirname(r);if(f.basename(i)!==`agents`)return;let a=f.dirname(i);return f.join(a,`agents`,S(t),`sessions`)}function ji(e){let t=f.normalize(f.resolve(e)).split(f.sep).filter(Boolean),n=t.lastIndexOf(`sessions`);return n<2||t[n-2]!==`agents`?null:{parts:t,sessionsIndex:n}}function Mi(e){let t=ji(e);if(!t)return;let{parts:n,sessionsIndex:r}=t;return n[r-1]||void 0}function Ni(e,t){let n=ji(e);if(!n)return;let{parts:r,sessionsIndex:i}=n,a=r[i-1];if(!a)return;let o=S(a);if(o!==a.toLowerCase()||o!==S(t))return;let s=r.slice(i+1);if(s.length!==1)return;let c=s[0];if(!(!c||c===`.`||c===`..`))return f.normalize(f.resolve(e))}function $(e){try{return l.realpathSync(e)}catch{return}}function Pi(e,t,n){let r=t.trim();if(!r)throw Error(`Session file path must not be empty`);let i=f.resolve(e),a=$(i)??i,o=f.isAbsolute(r)?$(r)??r:r,s=f.isAbsolute(o)?f.relative(a,o):o;if(s.startsWith(`..`)&&f.isAbsolute(o)){let e=e=>{let t=S(e),n=Ai(a,t);if(n){let e=ki(n,o);if(e)return e}return ki(Q(t),o)},t=n?.agentId?.trim();if(t){let n=e(t);if(n)return n}let r=Mi(o);if(r){let t=e(r);if(t)return t;let n=Ni(o,r);if(n)return n}}if(!s||s.startsWith(`..`)||f.isAbsolute(s))throw Error(`Session file path must be within sessions directory`);return f.resolve(a,s)}function Fi(e,t,n){let r=Di(e),i=typeof n==`string`?encodeURIComponent(n):typeof n==`number`?String(n):void 0;return Pi(t,i===void 0?`${r}.jsonl`:`${r}-topic-${i}.jsonl`)}function Ii(e,t,n){return Fi(e,Q(t),n)}function Li(e,t,n){let r=Oi(n),i=t?.sessionFile?.trim();if(i)try{return Pi(r,i,{agentId:n?.agentId})}catch{}return Fi(e,r)}function Ri(e,r){let i=S(r?.agentId??`main`);if(!e)return wi(i);if(e.includes(`{agentId}`)){let r=e.replaceAll(`{agentId}`,i);return r.startsWith(`~`)?f.resolve(n(r,{home:t(process.env,p.homedir),env:process.env,homedir:p.homedir})):f.resolve(r)}return e.startsWith(`~`)?f.resolve(n(e,{home:t(process.env,p.homedir),env:process.env,homedir:p.homedir})):f.resolve(e)}export{Pn as $,le as $t,Lr as A,b as At,rr as B,ze as Bt,ti as C,Ke as Ct,zr as D,Ve as Dt,qr as E,We as Et,Cr as F,Me as Ft,qn as G,Se as Gt,Wn as H,ke as Ht,yr as I,Ne as It,Kn as J,oe as Jt,Bn as K,de as Kt,_r as L,S as Lt,Jr as M,Fe as Mt,Kr as N,Ie as Nt,Ir as O,Be as Ot,Sr as P,Re as Pt,Fn as Q,v as Qt,vr as R,Ae as Rt,ni as S,qe as St,Gr as T,Ue as Tt,Mn as U,fe as Ut,Jn as V,Pe as Vt,V as W,xe as Wt,Gn as X,ie as Xt,Nn as Y,se as Yt,Un as Z,ae as Zt,si as _,O as _t,Fi as a,M as at,Y as b,w as bt,bi as c,Cn as ct,xi as d,on as dt,j as et,yi as f,sn as ft,pi as g,Ht as gt,X as h,Gt as ht,Ii as i,P as it,Br as j,we as jt,J as k,He as kt,Si as l,Dn as lt,di as m,Jt as mt,Li as n,L as nt,Ci as o,N as ot,ci as p,Wt as pt,Ln as q,y as qt,Ti as r,I as rt,Ri as s,F as st,wi as t,fn as tt,hi as u,Tn as ut,fi as v,E as vt,U as w,Ge as wt,$r as x,Xe as xt,mi as y,C as yt,ar as z,je as zt};
6
+ //# sourceMappingURL=paths-J4JUiRsa.js.map
@@ -3,3 +3,4 @@ import{J as e,O as t,_ as n,g as r,i,y as a}from"./logger-vBDTZWl3.js";import{c
3
3
  `);function wr(e){let t=e.trim().split(/\r?\n/).map(e=>e.trim()).filter(Boolean).at(-1);if(!t)throw Error(`Pinned write helper returned no identity`);let[n,r]=t.split(`|`),i=Number.parseInt(n??``,10),a=Number.parseInt(r??``,10);if(!Number.isFinite(i)||!Number.isFinite(a))throw Error(`Pinned write helper returned invalid identity: ${t}`);return{dev:i,ino:a}}async function Tr(e){let t=ne(`python3`,[`-c`,Cr,e.rootPath,e.relativeParentPath,e.basename,e.mkdir?`1`:`0`,(e.mode||384).toString(8)],{stdio:[`pipe`,`pipe`,`pipe`]}),n=``,r=``;t.stdout.setEncoding?.(`utf8`),t.stderr.setEncoding?.(`utf8`),t.stdout.on(`data`,e=>{n+=e}),t.stderr.on(`data`,e=>{r+=e});let i=g(t,`close`);try{if(!t.stdin){let t=await Er(e);return await i.catch(()=>{}),t}if(e.input.kind===`buffer`){let n=e.input;await new Promise((e,r)=>{if(t.stdin.once(`error`,r),typeof n.data==`string`){t.stdin.end(n.data,n.encoding??`utf8`,()=>e());return}t.stdin.end(n.data,()=>e())})}else await _(e.input.stream,t.stdin);let[a,o]=await i;if(a!==0)throw Error(r.trim()||`Pinned write helper failed with code ${a??`null`} (${o??`?`})`);return wr(n)}catch(e){throw t.kill(`SIGKILL`),await i.catch(()=>{}),e}}async function Er(e){let t=e.relativeParentPath?l.join(e.rootPath,...e.relativeParentPath.split(`/`)):e.rootPath;e.mkdir&&await m.mkdir(t,{recursive:!0});let n=l.join(t,e.basename),r=l.join(t,`.${e.basename}.fallback.tmp`);if(e.input.kind===`buffer`)typeof e.input.data==`string`?await m.writeFile(r,e.input.data,{encoding:e.input.encoding??`utf8`,mode:e.mode}):await m.writeFile(r,e.input.data,{mode:e.mode});else{let t=await m.open(r,`w`,e.mode);try{await _(e.input.stream,t.createWriteStream())}finally{await t.close().catch(()=>{})}}await m.rename(r,n);let i=await m.stat(n);return{dev:i.dev,ino:i.ino}}var W=class extends Error{constructor(e,t,n){super(t,n),this.code=e,this.name=`SafeOpenError`}};const G=process.platform!==`win32`&&`O_NOFOLLOW`in d,Dr=d.O_RDONLY|(G?d.O_NOFOLLOW:0),Or=d.O_WRONLY|(G?d.O_NOFOLLOW:0),kr=d.O_WRONLY|d.O_CREAT|d.O_EXCL|(G?d.O_NOFOLLOW:0),Ar=d.O_RDWR|d.O_APPEND|(G?d.O_NOFOLLOW:0),jr=d.O_RDWR|d.O_APPEND|d.O_CREAT|d.O_EXCL|(G?d.O_NOFOLLOW:0),Mr=e=>e.endsWith(l.sep)?e:e+l.sep;async function Nr(e){let t=process.env.HOME||process.env.USERPROFILE||p.homedir();try{t=await m.realpath(t)}catch{}return c(e,{home:t})}async function K(e,t){try{if((await m.lstat(e)).isDirectory())throw new W(`not-file`,`not a file`)}catch(e){if(e instanceof W)throw e}let n;try{n=await m.open(e,Dr)}catch(e){throw T(e)?new W(`not-found`,`file not found`):rt(e)?new W(`symlink`,`symlink open blocked`,{cause:e}):nt(e,`EISDIR`)?new W(`not-file`,`not a file`):e}try{let[r,i]=await Promise.all([n.stat(),m.lstat(e)]);if(i.isSymbolicLink())throw new W(`symlink`,`symlink not allowed`);if(!r.isFile())throw new W(`not-file`,`not a file`);if(t?.rejectHardlinks&&r.nlink>1)throw new W(`invalid-path`,`hardlinked path not allowed`);if(!w(r,i))throw new W(`path-mismatch`,`path changed during read`);let a=await m.realpath(e),o=await m.stat(a);if(t?.rejectHardlinks&&o.nlink>1)throw new W(`invalid-path`,`hardlinked path not allowed`);if(!w(r,o))throw new W(`path-mismatch`,`path mismatch`);return{handle:n,realPath:a,stat:r}}catch(e){throw await n.close().catch(()=>{}),e instanceof W?e:T(e)?new W(`not-found`,`file not found`):e}}async function Pr(e){let t;try{t=await m.realpath(e.rootDir)}catch(e){throw T(e)?new W(`not-found`,`root dir not found`):e}let n=Mr(t),r=await Nr(e.relativePath),i=l.resolve(n,r);if(!E(n,i))throw new W(`outside-workspace`,`file is outside workspace root`);return{rootReal:t,rootWithSep:n,resolved:i}}async function Fr(e){let{rootWithSep:t,resolved:n}=await Pr(e),r;try{r=await K(n)}catch(e){throw e instanceof W?e.code===`not-found`?e:new W(`invalid-path`,`path is not a regular file under root`,{cause:e}):e}if(e.rejectHardlinks!==!1&&r.stat.nlink>1)throw await r.handle.close().catch(()=>{}),new W(`invalid-path`,`hardlinked path not allowed`);if(!E(t,r.realPath))throw await r.handle.close().catch(()=>{}),new W(`outside-workspace`,`file is outside workspace root`);return r}async function Ir(e){let t=await Fr({rootDir:e.rootDir,relativePath:e.relativePath,rejectHardlinks:e.rejectHardlinks});try{return await Br({opened:t,maxBytes:e.maxBytes})}finally{await t.handle.close().catch(()=>{})}}async function Lr(e){let t=l.resolve(e.rootDir),n=l.isAbsolute(e.filePath)?l.resolve(e.filePath):l.resolve(t,e.filePath);return await Ir({rootDir:t,relativePath:l.relative(t,n),rejectHardlinks:e.rejectHardlinks,maxBytes:e.maxBytes})}function Rr(e){let t=l.resolve(e.rootDir);return async n=>(await Lr({rootDir:t,filePath:n,rejectHardlinks:e.rejectHardlinks,maxBytes:e.maxBytes})).buffer}async function zr(e){let t=await K(e.filePath);try{return await Br({opened:t,maxBytes:e.maxBytes})}finally{await t.handle.close().catch(()=>{})}}async function Br(e){if(e.maxBytes!==void 0&&e.opened.stat.size>e.maxBytes)throw new W(`too-large`,`file exceeds limit of ${e.maxBytes} bytes (got ${e.opened.stat.size})`);return{buffer:await e.opened.handle.readFile(),realPath:e.opened.realPath,stat:e.opened.stat}}function q(e){i(`security: fs-safe write boundary warning (${e})`)}function Vr(e){let t=l.dirname(e),n=l.basename(e);return l.join(t,`.${n}.${process.pid}.${te()}.tmp`)}async function Hr(e){let t=await m.open(e.tempPath,kr,e.mode);try{return typeof e.data==`string`?await t.writeFile(e.data,e.encoding??`utf8`):await t.writeFile(e.data),await t.stat()}finally{await t.close().catch(()=>{})}}async function J(e){let t=Mr(await m.realpath(e.rootDir)),n=await K(e.targetPath,{rejectHardlinks:!0});try{if(!w(n.stat,e.expectedIdentity))throw new W(`path-mismatch`,`path changed during write`);if(!E(t,n.realPath))throw new W(`outside-workspace`,`file is outside workspace root`)}finally{await n.handle.close().catch(()=>{})}}async function Ur(e,t){try{return await m.realpath(t)}catch(e){if(!T(e))throw e}let n=process.platform===`linux`?[`/proc/self/fd/${e.fd}`,`/dev/fd/${e.fd}`]:process.platform===`win32`?[]:[`/dev/fd/${e.fd}`];for(let e of n)try{return await m.realpath(e)}catch{}throw new W(`path-mismatch`,`unable to resolve opened file path`)}async function Wr(e){let{rootReal:t,rootWithSep:n,resolved:r}=await Pr(e);try{await Sr({absolutePath:r,rootPath:t,boundaryLabel:`root`})}catch(e){throw new W(`invalid-path`,`path alias escape blocked`,{cause:e})}e.mkdir!==!1&&await m.mkdir(l.dirname(r),{recursive:!0});let i=r;try{let e=await m.realpath(r);if(!E(n,e))throw new W(`outside-workspace`,`file is outside workspace root`);i=e}catch(e){if(e instanceof W||!T(e))throw e}let a=e.mode??384,o,s=!1,c=e.append?Ar:Or,u=e.append?jr:kr;try{try{o=await m.open(i,c,a)}catch(e){if(!T(e))throw e;o=await m.open(i,u,a),s=!0}}catch(e){throw T(e)?new W(`not-found`,`file not found`):rt(e)?new W(`invalid-path`,`symlink open blocked`,{cause:e}):e}let d=null;try{let t=await o.stat();if(!t.isFile())throw new W(`invalid-path`,`path is not a regular file under root`);if(t.nlink>1)throw new W(`invalid-path`,`hardlinked path not allowed`);try{let e=await m.lstat(i);if(e.isSymbolicLink()||!e.isFile())throw new W(`invalid-path`,`path is not a regular file under root`);if(!w(t,e))throw new W(`path-mismatch`,`path changed during write`)}catch(e){if(!T(e))throw e}let r=await Ur(o,i);d=r;let a=await m.stat(r);if(!w(t,a))throw new W(`path-mismatch`,`path mismatch`);if(a.nlink>1)throw new W(`invalid-path`,`hardlinked path not allowed`);if(!E(n,r))throw new W(`outside-workspace`,`file is outside workspace root`);return e.append!==!0&&e.truncateExisting!==!1&&!s&&await o.truncate(0),{handle:o,createdForWrite:s,openedRealPath:r,openedStat:t}}catch(e){let t=s&&e instanceof W,n=d??i;throw await o.close().catch(()=>{}),t&&await m.rm(n,{force:!0}).catch(()=>{}),e}}async function Gr(e){let t=await Wr({rootDir:e.rootDir,relativePath:e.relativePath,mkdir:e.mkdir,truncateExisting:!1,append:!0});try{let n=``;if(e.prependNewlineIfNeeded===!0&&!t.createdForWrite&&t.openedStat.size>0&&(typeof e.data==`string`&&!e.data.startsWith(`
4
4
  `)||Buffer.isBuffer(e.data)&&e.data.length>0&&e.data[0]!==10)){let e=Buffer.alloc(1),{bytesRead:r}=await t.handle.read(e,0,1,t.openedStat.size-1);r===1&&e[0]!==10&&(n=`
5
5
  `)}if(typeof e.data==`string`){await t.handle.appendFile(`${n}${e.data}`,e.encoding??`utf8`);return}let r=n.length>0?Buffer.concat([Buffer.from(n,`utf8`),e.data]):e.data;await t.handle.appendFile(r)}finally{await t.handle.close().catch(()=>{})}}async function Kr(e){if(process.platform===`win32`){await Zr(e);return}let t=await Yr({rootDir:e.rootDir,relativePath:e.relativePath}),n=await Tr({rootPath:t.rootReal,relativeParentPath:t.relativeParentPath,basename:t.basename,mkdir:e.mkdir!==!1,mode:t.mode,input:{kind:`buffer`,data:e.data,encoding:e.encoding}}).catch(e=>{throw Xr(e)});try{await J({rootDir:e.rootDir,targetPath:t.targetPath,expectedIdentity:n})}catch(e){throw q(`post-write verification failed: ${String(e)}`),e}}async function qr(e){let t=await K(e.sourcePath,{rejectHardlinks:e.rejectSourceHardlinks});if(e.maxBytes!==void 0&&t.stat.size>e.maxBytes)throw await t.handle.close().catch(()=>{}),new W(`too-large`,`file exceeds limit of ${e.maxBytes} bytes (got ${t.stat.size})`);try{if(process.platform===`win32`){await Qr(e,t);return}let n=await Yr({rootDir:e.rootDir,relativePath:e.relativePath}),r=t.handle.createReadStream(),i=await Tr({rootPath:n.rootReal,relativeParentPath:n.relativeParentPath,basename:n.basename,mkdir:e.mkdir!==!1,mode:n.mode,input:{kind:`stream`,stream:r}}).catch(e=>{throw Xr(e)});try{await J({rootDir:e.rootDir,targetPath:n.targetPath,expectedIdentity:i})}catch(e){throw q(`post-copy verification failed: ${String(e)}`),e}}finally{await t.handle.close().catch(()=>{})}}async function Jr(e){await qr({sourcePath:e.sourcePath,rootDir:e.rootDir,relativePath:e.relativePath,mkdir:e.mkdir,rejectSourceHardlinks:!0})}async function Yr(e){let{rootReal:t,rootWithSep:n,resolved:r}=await Pr(e);try{await Sr({absolutePath:r,rootPath:t,boundaryLabel:`root`})}catch(e){throw new W(`invalid-path`,`path alias escape blocked`,{cause:e})}let i=l.relative(t,r);if(i.startsWith(`..`)||l.isAbsolute(i))throw new W(`outside-workspace`,`file is outside workspace root`);let a=i?i.split(l.sep).join(l.posix.sep):``,o=l.posix.basename(a);if(!o||o===`.`||o===`/`)throw new W(`invalid-path`,`invalid target path`);let s=384;try{let t=await Fr({rootDir:e.rootDir,relativePath:e.relativePath,rejectHardlinks:!0});try{if(s=t.stat.mode&511,!E(n,t.realPath))throw new W(`outside-workspace`,`file is outside workspace root`)}finally{await t.handle.close().catch(()=>{})}}catch(e){if(!(e instanceof W)||e.code!==`not-found`)throw e}return{rootReal:t,targetPath:r,relativeParentPath:l.posix.dirname(a)===`.`?``:l.posix.dirname(a),basename:o,mode:s||384}}function Xr(e){return e instanceof W?e:new W(`invalid-path`,`path is not a regular file under root`,{cause:e instanceof Error?e:void 0})}async function Zr(e){let t=await Wr({rootDir:e.rootDir,relativePath:e.relativePath,mkdir:e.mkdir,truncateExisting:!1}),n=t.openedRealPath,r=t.openedStat.mode&511;await t.handle.close().catch(()=>{});let i=null;try{i=Vr(n);let t=await Hr({tempPath:i,data:e.data,encoding:e.encoding,mode:r||384});await m.rename(i,n),i=null;try{await J({rootDir:e.rootDir,targetPath:n,expectedIdentity:t})}catch(e){throw q(`post-write verification failed: ${String(e)}`),e}}finally{i&&await m.rm(i,{force:!0}).catch(()=>{})}}async function Qr(e,t){let n=null,r=!1,i=!1,a=null,o=null,s=!1;try{n=await Wr({rootDir:e.rootDir,relativePath:e.relativePath,mkdir:e.mkdir,truncateExisting:!1});let c=n.openedRealPath,l=n.openedStat.mode&511;await n.handle.close().catch(()=>{}),i=!0,o=Vr(c),a=await m.open(o,kr,l||384);let u=t.handle.createReadStream(),d=a.createWriteStream();u.once(`close`,()=>{r=!0}),d.once(`close`,()=>{s=!0}),await import(`node:stream/promises`).then(({pipeline:e})=>e(u,d));let f=await m.stat(o);s||=(await a.close().catch(()=>{}),!0),a=null,await m.rename(o,c),o=null;try{await J({rootDir:e.rootDir,targetPath:c,expectedIdentity:f})}catch(e){throw q(`post-copy verification failed: ${String(e)}`),e}}catch(e){throw n?.createdForWrite&&await m.rm(n.openedRealPath,{force:!0}).catch(()=>{}),e}finally{o&&await m.rm(o,{force:!0}).catch(()=>{}),r||await t.handle.close().catch(()=>{}),a&&!s&&await a.close().catch(()=>{}),n&&!i&&await n.handle.close().catch(()=>{})}}const $r=6*1024*1024,ei=100*1024*1024;function ti(e){if(e){if(e.startsWith(`image/`))return`image`;if(e.startsWith(`audio/`))return`audio`;if(e.startsWith(`video/`))return`video`;if(e===`application/pdf`||e.startsWith(`text/`)||e.startsWith(`application/`))return`document`}}function ni(e){switch(e){case`image`:return $r;case`audio`:return 16777216;case`video`:return 16777216;case`document`:return ei;default:return ei}}const ri={"image/heic":`.heic`,"image/heif":`.heif`,"image/jpeg":`.jpg`,"image/png":`.png`,"image/webp":`.webp`,"image/gif":`.gif`,"audio/ogg":`.ogg`,"audio/mpeg":`.mp3`,"audio/wav":`.wav`,"audio/flac":`.flac`,"audio/aac":`.aac`,"audio/opus":`.opus`,"audio/x-m4a":`.m4a`,"audio/mp4":`.m4a`,"video/mp4":`.mp4`,"video/quicktime":`.mov`,"application/pdf":`.pdf`,"application/json":`.json`,"application/zip":`.zip`,"application/gzip":`.gz`,"application/x-tar":`.tar`,"application/x-7z-compressed":`.7z`,"application/vnd.rar":`.rar`,"application/msword":`.doc`,"application/vnd.ms-excel":`.xls`,"application/vnd.ms-powerpoint":`.ppt`,"application/vnd.openxmlformats-officedocument.wordprocessingml.document":`.docx`,"application/vnd.openxmlformats-officedocument.spreadsheetml.sheet":`.xlsx`,"application/vnd.openxmlformats-officedocument.presentationml.presentation":`.pptx`,"text/csv":`.csv`,"text/plain":`.txt`,"text/markdown":`.md`},ii={...Object.fromEntries(Object.entries(ri).map(([e,t])=>[t,e])),".jpeg":`image/jpeg`,".js":`text/javascript`},ai=new Set([`.aac`,`.caf`,`.flac`,`.m4a`,`.mp3`,`.oga`,`.ogg`,`.opus`,`.wav`]);function Y(e){if(e)return e.split(`;`)[0]?.trim().toLowerCase()||void 0}async function oi(e){if(e)try{return(await v(e))?.mime??void 0}catch{return}}function X(e){if(e){try{if(/^https?:\/\//i.test(e)){let t=new URL(e);return l.extname(t.pathname).toLowerCase()||void 0}}catch{}return l.extname(e).toLowerCase()||void 0}}function si(e){let t=X(e);return t?ai.has(t):!1}function ci(e){return ui(e)}function li(e){if(!e)return!0;let t=e.toLowerCase();return t===`application/octet-stream`||t===`application/zip`}async function ui(e){let t=X(e.filePath),n=t?ii[t]:void 0,r=Y(e.headerMime),i=await oi(e.buffer);if(i&&(!li(i)||!n))return i;if(n)return n;if(r&&!li(r))return r;if(i)return i;if(r)return r}function di(e){let t=Y(e);if(t)return ri[t]}function fi(e){return e.contentType?.toLowerCase()===`image/gif`?!0:X(e.fileName)===`.gif`}function pi(e){if(e)switch(e.toLowerCase()){case`jpg`:case`jpeg`:return`image/jpeg`;case`heic`:return`image/heic`;case`heif`:return`image/heif`;case`png`:return`image/png`;case`webp`:return`image/webp`;case`gif`:return`image/gif`;default:return}}function mi(e){return ti(Y(e))}function Z(e){try{return ee(e).isFile()}catch{return!1}}function hi(e,t){if(e.includes(`/`)||e.includes(`\\`)||l.isAbsolute(e))return e;let n=(t.PATH??t.Path??process.env.PATH??process.env.Path??``).split(`;`).map(e=>e.trim()).filter(Boolean),r=l.extname(e).length>0,i=t.PATHEXT??t.Pathext??process.env.PATHEXT??process.env.Pathext??`.EXE;.CMD;.BAT;.COM`,a=r?[``]:i.split(`;`).map(e=>e.trim()).filter(Boolean).map(e=>e.startsWith(`.`)?e:`.${e}`);for(let t of n)for(let n of a)for(let r of[n,n.toLowerCase(),n.toUpperCase()]){let n=l.join(t,`${e}${r}`);if(Z(n))return n}return e}function gi(e){if(!Z(e))return null;try{let t=f(e,`utf8`),n=[];for(let r of t.matchAll(/"([^"\r\n]*)"/g)){let t=(r[1]??``).match(/%~?dp0%?\s*[\\/]*(.*)$/i)?.[1]?.trim();if(!t)continue;let i=t.replace(/[\\/]+/g,l.sep).replace(/^[\\/]+/,``),a=l.resolve(l.dirname(e),i);Z(a)&&n.push(a)}return n.find(e=>{let t=l.basename(e).toLowerCase();return t!==`node.exe`&&t!==`node`})??null}catch{return null}}function _i(e,t){if(typeof t==`string`)return t.trim()||null;if(!t||typeof t!=`object`)return null;if(e){let n=t[e];if(typeof n==`string`&&n.trim())return n.trim()}for(let e of Object.values(t))if(typeof e==`string`&&e.trim())return e.trim();return null}function vi(e,t){if(!t)return null;let n=l.dirname(e),r=[l.resolve(n,`..`,t),l.resolve(n,`node_modules`,t)];for(let e of r){let n=l.join(e,`package.json`);if(Z(n))try{let r=_i(t,JSON.parse(f(n,`utf8`)).bin);if(!r)continue;let i=l.resolve(e,r);if(Z(i))return i}catch{}}return null}function yi(e){let t=e.platform??process.platform,n=e.env??process.env,r=e.execPath??process.execPath;if(t!==`win32`)return{command:e.command,leadingArgv:[],resolution:`direct`};let i=hi(e.command,n),a=l.extname(i).toLowerCase();if(a===`.js`||a===`.cjs`||a===`.mjs`)return{command:r,leadingArgv:[i],resolution:`node-entrypoint`,windowsHide:!0};if(a===`.cmd`||a===`.bat`){let t=gi(i)??vi(i,e.packageName);return t?l.extname(t).toLowerCase()===`.exe`?{command:t,leadingArgv:[],resolution:`exe-entrypoint`,windowsHide:!0}:{command:r,leadingArgv:[t],resolution:`node-entrypoint`,windowsHide:!0}:{command:i,leadingArgv:[],resolution:`unresolved-wrapper`}}return{command:i,leadingArgv:[],resolution:`direct`}}function bi(e){if(e.candidate.resolution!==`unresolved-wrapper`)return{command:e.candidate.command,leadingArgv:e.candidate.leadingArgv,resolution:e.candidate.resolution,windowsHide:e.candidate.windowsHide};if(e.allowShellFallback!==!1)return{command:e.candidate.command,leadingArgv:[],resolution:`shell-fallback`,shell:!0};throw Error(`${l.basename(e.candidate.command)} wrapper resolved, but no executable/Node entrypoint could be resolved without shell execution.`)}function xi(e){return bi({candidate:yi(e),allowShellFallback:e.allowShellFallback})}function Si(e,t){return{command:e.command,argv:[...e.leadingArgv,...t],resolution:e.resolution,shell:e.shell,windowsHide:e.windowsHide}}function Q(e,t=process.env,n=()=>s(t,p.homedir)){let r=o(t,n),i=C(e??`main`);return l.join(r,`agents`,i,`sessions`)}function Ci(e,t=process.env,n=()=>s(t,p.homedir)){return Q(e,t,n)}function wi(e){return l.join(Q(e),`sessions.json`)}function Ti(e){let t=e.agentId?.trim(),n=e.storePath?.trim();if(n&&n!==`(multiple)`){let e=l.dirname(l.resolve(n));return t?{sessionsDir:e,agentId:t}:{sessionsDir:e}}if(t)return{agentId:t}}const Ei=/^[a-z0-9][a-z0-9._-]{0,127}$/i;function Di(e){let t=e.trim();if(!Ei.test(t))throw Error(`Invalid session ID: ${e}`);return t}function Oi(e){let t=e?.sessionsDir?.trim();return t?l.resolve(t):Q(e?.agentId)}function ki(e,t){let n=$(l.resolve(e))??l.resolve(e),r=$(t)??t,i=l.relative(n,r);if(!(!i||i.startsWith(`..`)||l.isAbsolute(i)))return l.resolve(n,i)}function Ai(e,t){let n=l.resolve(e);if(l.basename(n)!==`sessions`)return;let r=l.dirname(n),i=l.dirname(r);if(l.basename(i)!==`agents`)return;let a=l.dirname(i);return l.join(a,`agents`,C(t),`sessions`)}function ji(e){let t=l.normalize(l.resolve(e)).split(l.sep).filter(Boolean),n=t.lastIndexOf(`sessions`);return n<2||t[n-2]!==`agents`?null:{parts:t,sessionsIndex:n}}function Mi(e){let t=ji(e);if(!t)return;let{parts:n,sessionsIndex:r}=t;return n[r-1]||void 0}function Ni(e,t){let n=ji(e);if(!n)return;let{parts:r,sessionsIndex:i}=n,a=r[i-1];if(!a)return;let o=C(a);if(o!==a.toLowerCase()||o!==C(t))return;let s=r.slice(i+1);if(s.length!==1)return;let c=s[0];if(!(!c||c===`.`||c===`..`))return l.normalize(l.resolve(e))}function $(e){try{return u.realpathSync(e)}catch{return}}function Pi(e,t,n){let r=t.trim();if(!r)throw Error(`Session file path must not be empty`);let i=l.resolve(e),a=$(i)??i,o=l.isAbsolute(r)?$(r)??r:r,s=l.isAbsolute(o)?l.relative(a,o):o;if(s.startsWith(`..`)&&l.isAbsolute(o)){let e=e=>{let t=C(e),n=Ai(a,t);if(n){let e=ki(n,o);if(e)return e}return ki(Q(t),o)},t=n?.agentId?.trim();if(t){let n=e(t);if(n)return n}let r=Mi(o);if(r){let t=e(r);if(t)return t;let n=Ni(o,r);if(n)return n}}if(!s||s.startsWith(`..`)||l.isAbsolute(s))throw Error(`Session file path must be within sessions directory`);return l.resolve(a,s)}function Fi(e,t,n){let r=Di(e),i=typeof n==`string`?encodeURIComponent(n):typeof n==`number`?String(n):void 0;return Pi(t,i===void 0?`${r}.jsonl`:`${r}-topic-${i}.jsonl`)}function Ii(e,t,n){return Fi(e,Q(t),n)}function Li(e,t,n){let r=Oi(n),i=t?.sessionFile?.trim();if(i)try{return Pi(r,i,{agentId:n?.agentId})}catch{}return Fi(e,r)}function Ri(e,t){let n=C(t?.agentId??`main`);if(!e)return wi(n);if(e.includes(`{agentId}`)){let t=e.replaceAll(`{agentId}`,n);return t.startsWith(`~`)?l.resolve(c(t,{home:s(process.env,p.homedir),env:process.env,homedir:p.homedir})):l.resolve(t)}return e.startsWith(`~`)?l.resolve(c(e,{home:s(process.env,p.homedir),env:process.env,homedir:p.homedir})):l.resolve(e)}export{L as $,xr as A,je as At,H as B,xe as Bt,qr as C,ze as Ct,zr as D,Pe as Dt,Ir as E,Ce as Et,ir as F,Re as Ft,Mn as G,re as Gt,zn as H,b as Ht,nr as I,Ne as It,Pn as J,ce as Jt,Wn as K,ie as Kt,qn as L,Oe as Lt,vr as M,C as Mt,gr as N,ke as Nt,Jr as O,Fe as Ot,_r as P,Ae as Pt,R as Q,Un as R,de as Rt,Gr as S,Ve as St,Fr as T,x as Tt,In as U,ae as Ut,Kn as V,ue as Vt,Gn as W,oe as Wt,M as X,Nn as Y,dn as Z,Y as _,Ye as _t,Fi as a,En as at,ti as b,Ke as bt,Si as c,on as ct,di as d,Wt as dt,F as et,X as f,O as ft,mi as g,Ze as gt,fi as h,et as ht,Ii as i,Sn as it,Sr as j,Me as jt,Kr as k,Le as kt,xi as l,Ut as lt,si as m,E as mt,Li as n,P as nt,Ci as o,wn as ot,pi as p,T as pt,Hn as q,y as qt,Ti as r,I as rt,Ri as s,an as st,wi as t,N as tt,ci as u,qt as ut,$r as v,Je as vt,Rr as w,Be as wt,W as x,He as xt,ni as y,Xe as yt,jn as z,be as zt};
6
+ //# sourceMappingURL=paths-cBAF6Bj0.js.map
@@ -3,3 +3,4 @@ import{c as e,d as t,l as n}from"./paths-BpQOWYiT.js";import{J as r,O as i,_ as
3
3
  `);function Cr(e){let t=e.trim().split(/\r?\n/).map(e=>e.trim()).filter(Boolean).at(-1);if(!t)throw Error(`Pinned write helper returned no identity`);let[n,r]=t.split(`|`),i=Number.parseInt(n??``,10),a=Number.parseInt(r??``,10);if(!Number.isFinite(i)||!Number.isFinite(a))throw Error(`Pinned write helper returned invalid identity: ${t}`);return{dev:i,ino:a}}async function wr(e){let t=te(`python3`,[`-c`,Sr,e.rootPath,e.relativeParentPath,e.basename,e.mkdir?`1`:`0`,(e.mode||384).toString(8)],{stdio:[`pipe`,`pipe`,`pipe`]}),n=``,r=``;t.stdout.setEncoding?.(`utf8`),t.stderr.setEncoding?.(`utf8`),t.stdout.on(`data`,e=>{n+=e}),t.stderr.on(`data`,e=>{r+=e});let i=g(t,`close`);try{if(!t.stdin){let t=await Tr(e);return await i.catch(()=>{}),t}if(e.input.kind===`buffer`){let n=e.input;await new Promise((e,r)=>{if(t.stdin.once(`error`,r),typeof n.data==`string`){t.stdin.end(n.data,n.encoding??`utf8`,()=>e());return}t.stdin.end(n.data,()=>e())})}else await _(e.input.stream,t.stdin);let[a,o]=await i;if(a!==0)throw Error(r.trim()||`Pinned write helper failed with code ${a??`null`} (${o??`?`})`);return Cr(n)}catch(e){throw t.kill(`SIGKILL`),await i.catch(()=>{}),e}}async function Tr(e){let t=e.relativeParentPath?f.join(e.rootPath,...e.relativeParentPath.split(`/`)):e.rootPath;e.mkdir&&await m.mkdir(t,{recursive:!0});let n=f.join(t,e.basename),r=f.join(t,`.${e.basename}.fallback.tmp`);if(e.input.kind===`buffer`)typeof e.input.data==`string`?await m.writeFile(r,e.input.data,{encoding:e.input.encoding??`utf8`,mode:e.mode}):await m.writeFile(r,e.input.data,{mode:e.mode});else{let t=await m.open(r,`w`,e.mode);try{await _(e.input.stream,t.createWriteStream())}finally{await t.close().catch(()=>{})}}await m.rename(r,n);let i=await m.stat(n);return{dev:i.dev,ino:i.ino}}var G=class extends Error{constructor(e,t,n){super(t,n),this.code=e,this.name=`SafeOpenError`}};const K=process.platform!==`win32`&&`O_NOFOLLOW`in u,Er=u.O_RDONLY|(K?u.O_NOFOLLOW:0),Dr=u.O_WRONLY|(K?u.O_NOFOLLOW:0),Or=u.O_WRONLY|u.O_CREAT|u.O_EXCL|(K?u.O_NOFOLLOW:0),kr=u.O_RDWR|u.O_APPEND|(K?u.O_NOFOLLOW:0),Ar=u.O_RDWR|u.O_APPEND|u.O_CREAT|u.O_EXCL|(K?u.O_NOFOLLOW:0),jr=e=>e.endsWith(f.sep)?e:e+f.sep;async function Mr(e){let t=process.env.HOME||process.env.USERPROFILE||p.homedir();try{t=await m.realpath(t)}catch{}return n(e,{home:t})}async function q(e,t){try{if((await m.lstat(e)).isDirectory())throw new G(`not-file`,`not a file`)}catch(e){if(e instanceof G)throw e}let n;try{n=await m.open(e,Er)}catch(e){throw T(e)?new G(`not-found`,`file not found`):Ze(e)?new G(`symlink`,`symlink open blocked`,{cause:e}):Xe(e,`EISDIR`)?new G(`not-file`,`not a file`):e}try{let[r,i]=await Promise.all([n.stat(),m.lstat(e)]);if(i.isSymbolicLink())throw new G(`symlink`,`symlink not allowed`);if(!r.isFile())throw new G(`not-file`,`not a file`);if(t?.rejectHardlinks&&r.nlink>1)throw new G(`invalid-path`,`hardlinked path not allowed`);if(!A(r,i))throw new G(`path-mismatch`,`path changed during read`);let a=await m.realpath(e),o=await m.stat(a);if(t?.rejectHardlinks&&o.nlink>1)throw new G(`invalid-path`,`hardlinked path not allowed`);if(!A(r,o))throw new G(`path-mismatch`,`path mismatch`);return{handle:n,realPath:a,stat:r}}catch(e){throw await n.close().catch(()=>{}),e instanceof G?e:T(e)?new G(`not-found`,`file not found`):e}}async function Nr(e){let t;try{t=await m.realpath(e.rootDir)}catch(e){throw T(e)?new G(`not-found`,`root dir not found`):e}let n=jr(t),r=await Mr(e.relativePath),i=f.resolve(n,r);if(!E(n,i))throw new G(`outside-workspace`,`file is outside workspace root`);return{rootReal:t,rootWithSep:n,resolved:i}}async function Pr(e){let{rootWithSep:t,resolved:n}=await Nr(e),r;try{r=await q(n)}catch(e){throw e instanceof G?e.code===`not-found`?e:new G(`invalid-path`,`path is not a regular file under root`,{cause:e}):e}if(e.rejectHardlinks!==!1&&r.stat.nlink>1)throw await r.handle.close().catch(()=>{}),new G(`invalid-path`,`hardlinked path not allowed`);if(!E(t,r.realPath))throw await r.handle.close().catch(()=>{}),new G(`outside-workspace`,`file is outside workspace root`);return r}async function Fr(e){let t=await Pr({rootDir:e.rootDir,relativePath:e.relativePath,rejectHardlinks:e.rejectHardlinks});try{return await zr({opened:t,maxBytes:e.maxBytes})}finally{await t.handle.close().catch(()=>{})}}async function Ir(e){let t=f.resolve(e.rootDir),n=f.isAbsolute(e.filePath)?f.resolve(e.filePath):f.resolve(t,e.filePath);return await Fr({rootDir:t,relativePath:f.relative(t,n),rejectHardlinks:e.rejectHardlinks,maxBytes:e.maxBytes})}function Lr(e){let t=f.resolve(e.rootDir);return async n=>(await Ir({rootDir:t,filePath:n,rejectHardlinks:e.rejectHardlinks,maxBytes:e.maxBytes})).buffer}async function Rr(e){let t=await q(e.filePath);try{return await zr({opened:t,maxBytes:e.maxBytes})}finally{await t.handle.close().catch(()=>{})}}async function zr(e){if(e.maxBytes!==void 0&&e.opened.stat.size>e.maxBytes)throw new G(`too-large`,`file exceeds limit of ${e.maxBytes} bytes (got ${e.opened.stat.size})`);return{buffer:await e.opened.handle.readFile(),realPath:e.opened.realPath,stat:e.opened.stat}}function J(e){s(`security: fs-safe write boundary warning (${e})`)}function Br(e){let t=f.dirname(e),n=f.basename(e);return f.join(t,`.${n}.${process.pid}.${ne()}.tmp`)}async function Vr(e){let t=await m.open(e.tempPath,Or,e.mode);try{return typeof e.data==`string`?await t.writeFile(e.data,e.encoding??`utf8`):await t.writeFile(e.data),await t.stat()}finally{await t.close().catch(()=>{})}}async function Y(e){let t=jr(await m.realpath(e.rootDir)),n=await q(e.targetPath,{rejectHardlinks:!0});try{if(!A(n.stat,e.expectedIdentity))throw new G(`path-mismatch`,`path changed during write`);if(!E(t,n.realPath))throw new G(`outside-workspace`,`file is outside workspace root`)}finally{await n.handle.close().catch(()=>{})}}async function Hr(e,t){try{return await m.realpath(t)}catch(e){if(!T(e))throw e}let n=process.platform===`linux`?[`/proc/self/fd/${e.fd}`,`/dev/fd/${e.fd}`]:process.platform===`win32`?[]:[`/dev/fd/${e.fd}`];for(let e of n)try{return await m.realpath(e)}catch{}throw new G(`path-mismatch`,`unable to resolve opened file path`)}async function Ur(e){let{rootReal:t,rootWithSep:n,resolved:r}=await Nr(e);try{await xr({absolutePath:r,rootPath:t,boundaryLabel:`root`})}catch(e){throw new G(`invalid-path`,`path alias escape blocked`,{cause:e})}e.mkdir!==!1&&await m.mkdir(f.dirname(r),{recursive:!0});let i=r;try{let e=await m.realpath(r);if(!E(n,e))throw new G(`outside-workspace`,`file is outside workspace root`);i=e}catch(e){if(e instanceof G||!T(e))throw e}let a=e.mode??384,o,s=!1,c=e.append?kr:Dr,l=e.append?Ar:Or;try{try{o=await m.open(i,c,a)}catch(e){if(!T(e))throw e;o=await m.open(i,l,a),s=!0}}catch(e){throw T(e)?new G(`not-found`,`file not found`):Ze(e)?new G(`invalid-path`,`symlink open blocked`,{cause:e}):e}let u=null;try{let t=await o.stat();if(!t.isFile())throw new G(`invalid-path`,`path is not a regular file under root`);if(t.nlink>1)throw new G(`invalid-path`,`hardlinked path not allowed`);try{let e=await m.lstat(i);if(e.isSymbolicLink()||!e.isFile())throw new G(`invalid-path`,`path is not a regular file under root`);if(!A(t,e))throw new G(`path-mismatch`,`path changed during write`)}catch(e){if(!T(e))throw e}let r=await Hr(o,i);u=r;let a=await m.stat(r);if(!A(t,a))throw new G(`path-mismatch`,`path mismatch`);if(a.nlink>1)throw new G(`invalid-path`,`hardlinked path not allowed`);if(!E(n,r))throw new G(`outside-workspace`,`file is outside workspace root`);return e.append!==!0&&e.truncateExisting!==!1&&!s&&await o.truncate(0),{handle:o,createdForWrite:s,openedRealPath:r,openedStat:t}}catch(e){let t=s&&e instanceof G,n=u??i;throw await o.close().catch(()=>{}),t&&await m.rm(n,{force:!0}).catch(()=>{}),e}}async function Wr(e){let t=await Ur({rootDir:e.rootDir,relativePath:e.relativePath,mkdir:e.mkdir,truncateExisting:!1,append:!0});try{let n=``;if(e.prependNewlineIfNeeded===!0&&!t.createdForWrite&&t.openedStat.size>0&&(typeof e.data==`string`&&!e.data.startsWith(`
4
4
  `)||Buffer.isBuffer(e.data)&&e.data.length>0&&e.data[0]!==10)){let e=Buffer.alloc(1),{bytesRead:r}=await t.handle.read(e,0,1,t.openedStat.size-1);r===1&&e[0]!==10&&(n=`
5
5
  `)}if(typeof e.data==`string`){await t.handle.appendFile(`${n}${e.data}`,e.encoding??`utf8`);return}let r=n.length>0?Buffer.concat([Buffer.from(n,`utf8`),e.data]):e.data;await t.handle.appendFile(r)}finally{await t.handle.close().catch(()=>{})}}async function Gr(e){if(process.platform===`win32`){await Xr(e);return}let t=await Jr({rootDir:e.rootDir,relativePath:e.relativePath}),n=await wr({rootPath:t.rootReal,relativeParentPath:t.relativeParentPath,basename:t.basename,mkdir:e.mkdir!==!1,mode:t.mode,input:{kind:`buffer`,data:e.data,encoding:e.encoding}}).catch(e=>{throw Yr(e)});try{await Y({rootDir:e.rootDir,targetPath:t.targetPath,expectedIdentity:n})}catch(e){throw J(`post-write verification failed: ${String(e)}`),e}}async function Kr(e){let t=await q(e.sourcePath,{rejectHardlinks:e.rejectSourceHardlinks});if(e.maxBytes!==void 0&&t.stat.size>e.maxBytes)throw await t.handle.close().catch(()=>{}),new G(`too-large`,`file exceeds limit of ${e.maxBytes} bytes (got ${t.stat.size})`);try{if(process.platform===`win32`){await Zr(e,t);return}let n=await Jr({rootDir:e.rootDir,relativePath:e.relativePath}),r=t.handle.createReadStream(),i=await wr({rootPath:n.rootReal,relativeParentPath:n.relativeParentPath,basename:n.basename,mkdir:e.mkdir!==!1,mode:n.mode,input:{kind:`stream`,stream:r}}).catch(e=>{throw Yr(e)});try{await Y({rootDir:e.rootDir,targetPath:n.targetPath,expectedIdentity:i})}catch(e){throw J(`post-copy verification failed: ${String(e)}`),e}}finally{await t.handle.close().catch(()=>{})}}async function qr(e){await Kr({sourcePath:e.sourcePath,rootDir:e.rootDir,relativePath:e.relativePath,mkdir:e.mkdir,rejectSourceHardlinks:!0})}async function Jr(e){let{rootReal:t,rootWithSep:n,resolved:r}=await Nr(e);try{await xr({absolutePath:r,rootPath:t,boundaryLabel:`root`})}catch(e){throw new G(`invalid-path`,`path alias escape blocked`,{cause:e})}let i=f.relative(t,r);if(i.startsWith(`..`)||f.isAbsolute(i))throw new G(`outside-workspace`,`file is outside workspace root`);let a=i?i.split(f.sep).join(f.posix.sep):``,o=f.posix.basename(a);if(!o||o===`.`||o===`/`)throw new G(`invalid-path`,`invalid target path`);let s=384;try{let t=await Pr({rootDir:e.rootDir,relativePath:e.relativePath,rejectHardlinks:!0});try{if(s=t.stat.mode&511,!E(n,t.realPath))throw new G(`outside-workspace`,`file is outside workspace root`)}finally{await t.handle.close().catch(()=>{})}}catch(e){if(!(e instanceof G)||e.code!==`not-found`)throw e}return{rootReal:t,targetPath:r,relativeParentPath:f.posix.dirname(a)===`.`?``:f.posix.dirname(a),basename:o,mode:s||384}}function Yr(e){return e instanceof G?e:new G(`invalid-path`,`path is not a regular file under root`,{cause:e instanceof Error?e:void 0})}async function Xr(e){let t=await Ur({rootDir:e.rootDir,relativePath:e.relativePath,mkdir:e.mkdir,truncateExisting:!1}),n=t.openedRealPath,r=t.openedStat.mode&511;await t.handle.close().catch(()=>{});let i=null;try{i=Br(n);let t=await Vr({tempPath:i,data:e.data,encoding:e.encoding,mode:r||384});await m.rename(i,n),i=null;try{await Y({rootDir:e.rootDir,targetPath:n,expectedIdentity:t})}catch(e){throw J(`post-write verification failed: ${String(e)}`),e}}finally{i&&await m.rm(i,{force:!0}).catch(()=>{})}}async function Zr(e,t){let n=null,r=!1,i=!1,a=null,o=null,s=!1;try{n=await Ur({rootDir:e.rootDir,relativePath:e.relativePath,mkdir:e.mkdir,truncateExisting:!1});let c=n.openedRealPath,l=n.openedStat.mode&511;await n.handle.close().catch(()=>{}),i=!0,o=Br(c),a=await m.open(o,Or,l||384);let u=t.handle.createReadStream(),d=a.createWriteStream();u.once(`close`,()=>{r=!0}),d.once(`close`,()=>{s=!0}),await import(`node:stream/promises`).then(({pipeline:e})=>e(u,d));let ee=await m.stat(o);s||=(await a.close().catch(()=>{}),!0),a=null,await m.rename(o,c),o=null;try{await Y({rootDir:e.rootDir,targetPath:c,expectedIdentity:ee})}catch(e){throw J(`post-copy verification failed: ${String(e)}`),e}}catch(e){throw n?.createdForWrite&&await m.rm(n.openedRealPath,{force:!0}).catch(()=>{}),e}finally{o&&await m.rm(o,{force:!0}).catch(()=>{}),r||await t.handle.close().catch(()=>{}),a&&!s&&await a.close().catch(()=>{}),n&&!i&&await n.handle.close().catch(()=>{})}}const Qr=6*1024*1024,$r=100*1024*1024;function ei(e){if(e){if(e.startsWith(`image/`))return`image`;if(e.startsWith(`audio/`))return`audio`;if(e.startsWith(`video/`))return`video`;if(e===`application/pdf`||e.startsWith(`text/`)||e.startsWith(`application/`))return`document`}}function ti(e){switch(e){case`image`:return Qr;case`audio`:return 16777216;case`video`:return 16777216;case`document`:return $r;default:return $r}}const ni={"image/heic":`.heic`,"image/heif":`.heif`,"image/jpeg":`.jpg`,"image/png":`.png`,"image/webp":`.webp`,"image/gif":`.gif`,"audio/ogg":`.ogg`,"audio/mpeg":`.mp3`,"audio/wav":`.wav`,"audio/flac":`.flac`,"audio/aac":`.aac`,"audio/opus":`.opus`,"audio/x-m4a":`.m4a`,"audio/mp4":`.m4a`,"video/mp4":`.mp4`,"video/quicktime":`.mov`,"application/pdf":`.pdf`,"application/json":`.json`,"application/zip":`.zip`,"application/gzip":`.gz`,"application/x-tar":`.tar`,"application/x-7z-compressed":`.7z`,"application/vnd.rar":`.rar`,"application/msword":`.doc`,"application/vnd.ms-excel":`.xls`,"application/vnd.ms-powerpoint":`.ppt`,"application/vnd.openxmlformats-officedocument.wordprocessingml.document":`.docx`,"application/vnd.openxmlformats-officedocument.spreadsheetml.sheet":`.xlsx`,"application/vnd.openxmlformats-officedocument.presentationml.presentation":`.pptx`,"text/csv":`.csv`,"text/plain":`.txt`,"text/markdown":`.md`},ri={...Object.fromEntries(Object.entries(ni).map(([e,t])=>[t,e])),".jpeg":`image/jpeg`,".js":`text/javascript`},ii=new Set([`.aac`,`.caf`,`.flac`,`.m4a`,`.mp3`,`.oga`,`.ogg`,`.opus`,`.wav`]);function X(e){if(e)return e.split(`;`)[0]?.trim().toLowerCase()||void 0}async function ai(e){if(e)try{return(await v(e))?.mime??void 0}catch{return}}function Z(e){if(e){try{if(/^https?:\/\//i.test(e)){let t=new URL(e);return f.extname(t.pathname).toLowerCase()||void 0}}catch{}return f.extname(e).toLowerCase()||void 0}}function oi(e){let t=Z(e);return t?ii.has(t):!1}function si(e){return li(e)}function ci(e){if(!e)return!0;let t=e.toLowerCase();return t===`application/octet-stream`||t===`application/zip`}async function li(e){let t=Z(e.filePath),n=t?ri[t]:void 0,r=X(e.headerMime),i=await ai(e.buffer);if(i&&(!ci(i)||!n))return i;if(n)return n;if(r&&!ci(r))return r;if(i)return i;if(r)return r}function ui(e){let t=X(e);if(t)return ni[t]}function di(e){return e.contentType?.toLowerCase()===`image/gif`?!0:Z(e.fileName)===`.gif`}function fi(e){if(e)switch(e.toLowerCase()){case`jpg`:case`jpeg`:return`image/jpeg`;case`heic`:return`image/heic`;case`heif`:return`image/heif`;case`png`:return`image/png`;case`webp`:return`image/webp`;case`gif`:return`image/gif`;default:return}}function pi(e){return ei(X(e))}function Q(e){try{return ee(e).isFile()}catch{return!1}}function mi(e,t){if(e.includes(`/`)||e.includes(`\\`)||f.isAbsolute(e))return e;let n=(t.PATH??t.Path??process.env.PATH??process.env.Path??``).split(`;`).map(e=>e.trim()).filter(Boolean),r=f.extname(e).length>0,i=t.PATHEXT??t.Pathext??process.env.PATHEXT??process.env.Pathext??`.EXE;.CMD;.BAT;.COM`,a=r?[``]:i.split(`;`).map(e=>e.trim()).filter(Boolean).map(e=>e.startsWith(`.`)?e:`.${e}`);for(let t of n)for(let n of a)for(let r of[n,n.toLowerCase(),n.toUpperCase()]){let n=f.join(t,`${e}${r}`);if(Q(n))return n}return e}function hi(e){if(!Q(e))return null;try{let t=d(e,`utf8`),n=[];for(let r of t.matchAll(/"([^"\r\n]*)"/g)){let t=(r[1]??``).match(/%~?dp0%?\s*[\\/]*(.*)$/i)?.[1]?.trim();if(!t)continue;let i=t.replace(/[\\/]+/g,f.sep).replace(/^[\\/]+/,``),a=f.resolve(f.dirname(e),i);Q(a)&&n.push(a)}return n.find(e=>{let t=f.basename(e).toLowerCase();return t!==`node.exe`&&t!==`node`})??null}catch{return null}}function gi(e,t){if(typeof t==`string`)return t.trim()||null;if(!t||typeof t!=`object`)return null;if(e){let n=t[e];if(typeof n==`string`&&n.trim())return n.trim()}for(let e of Object.values(t))if(typeof e==`string`&&e.trim())return e.trim();return null}function _i(e,t){if(!t)return null;let n=f.dirname(e),r=[f.resolve(n,`..`,t),f.resolve(n,`node_modules`,t)];for(let e of r){let n=f.join(e,`package.json`);if(Q(n))try{let r=gi(t,JSON.parse(d(n,`utf8`)).bin);if(!r)continue;let i=f.resolve(e,r);if(Q(i))return i}catch{}}return null}function vi(e){let t=e.platform??process.platform,n=e.env??process.env,r=e.execPath??process.execPath;if(t!==`win32`)return{command:e.command,leadingArgv:[],resolution:`direct`};let i=mi(e.command,n),a=f.extname(i).toLowerCase();if(a===`.js`||a===`.cjs`||a===`.mjs`)return{command:r,leadingArgv:[i],resolution:`node-entrypoint`,windowsHide:!0};if(a===`.cmd`||a===`.bat`){let t=hi(i)??_i(i,e.packageName);return t?f.extname(t).toLowerCase()===`.exe`?{command:t,leadingArgv:[],resolution:`exe-entrypoint`,windowsHide:!0}:{command:r,leadingArgv:[t],resolution:`node-entrypoint`,windowsHide:!0}:{command:i,leadingArgv:[],resolution:`unresolved-wrapper`}}return{command:i,leadingArgv:[],resolution:`direct`}}function yi(e){if(e.candidate.resolution!==`unresolved-wrapper`)return{command:e.candidate.command,leadingArgv:e.candidate.leadingArgv,resolution:e.candidate.resolution,windowsHide:e.candidate.windowsHide};if(e.allowShellFallback!==!1)return{command:e.candidate.command,leadingArgv:[],resolution:`shell-fallback`,shell:!0};throw Error(`${f.basename(e.candidate.command)} wrapper resolved, but no executable/Node entrypoint could be resolved without shell execution.`)}function bi(e){return yi({candidate:vi(e),allowShellFallback:e.allowShellFallback})}function xi(e,t){return{command:e.command,argv:[...e.leadingArgv,...t],resolution:e.resolution,shell:e.shell,windowsHide:e.windowsHide}}function $(n,r=process.env,i=()=>t(r,p.homedir)){let a=e(r,i),o=w(n??`main`);return f.join(a,`agents`,o,`sessions`)}function Si(e,n=process.env,r=()=>t(n,p.homedir)){return $(e,n,r)}function Ci(e){return f.join($(e),`sessions.json`)}function wi(e){let t=e.agentId?.trim(),n=e.storePath?.trim();if(n&&n!==`(multiple)`){let e=f.dirname(f.resolve(n));return t?{sessionsDir:e,agentId:t}:{sessionsDir:e}}if(t)return{agentId:t}}const Ti=/^[a-z0-9][a-z0-9._-]{0,127}$/i;function Ei(e){let t=e.trim();if(!Ti.test(t))throw Error(`Invalid session ID: ${e}`);return t}function Di(e){let t=e?.sessionsDir?.trim();return t?f.resolve(t):$(e?.agentId)}function Oi(e,t){let n=Ni(f.resolve(e))??f.resolve(e),r=Ni(t)??t,i=f.relative(n,r);if(!(!i||i.startsWith(`..`)||f.isAbsolute(i)))return f.resolve(n,i)}function ki(e,t){let n=f.resolve(e);if(f.basename(n)!==`sessions`)return;let r=f.dirname(n),i=f.dirname(r);if(f.basename(i)!==`agents`)return;let a=f.dirname(i);return f.join(a,`agents`,w(t),`sessions`)}function Ai(e){let t=f.normalize(f.resolve(e)).split(f.sep).filter(Boolean),n=t.lastIndexOf(`sessions`);return n<2||t[n-2]!==`agents`?null:{parts:t,sessionsIndex:n}}function ji(e){let t=Ai(e);if(!t)return;let{parts:n,sessionsIndex:r}=t;return n[r-1]||void 0}function Mi(e,t){let n=Ai(e);if(!n)return;let{parts:r,sessionsIndex:i}=n,a=r[i-1];if(!a)return;let o=w(a);if(o!==a.toLowerCase()||o!==w(t))return;let s=r.slice(i+1);if(s.length!==1)return;let c=s[0];if(!(!c||c===`.`||c===`..`))return f.normalize(f.resolve(e))}function Ni(e){try{return l.realpathSync(e)}catch{return}}function Pi(e,t,n){let r=t.trim();if(!r)throw Error(`Session file path must not be empty`);let i=f.resolve(e),a=Ni(i)??i,o=f.isAbsolute(r)?Ni(r)??r:r,s=f.isAbsolute(o)?f.relative(a,o):o;if(s.startsWith(`..`)&&f.isAbsolute(o)){let e=e=>{let t=w(e),n=ki(a,t);if(n){let e=Oi(n,o);if(e)return e}return Oi($(t),o)},t=n?.agentId?.trim();if(t){let n=e(t);if(n)return n}let r=ji(o);if(r){let t=e(r);if(t)return t;let n=Mi(o,r);if(n)return n}}if(!s||s.startsWith(`..`)||f.isAbsolute(s))throw Error(`Session file path must be within sessions directory`);return f.resolve(a,s)}function Fi(e,t,n){let r=Ei(e),i=typeof n==`string`?encodeURIComponent(n):typeof n==`number`?String(n):void 0;return Pi(t,i===void 0?`${r}.jsonl`:`${r}-topic-${i}.jsonl`)}function Ii(e,t,n){return Fi(e,$(t),n)}function Li(e,t,n){let r=Di(n),i=t?.sessionFile?.trim();if(i)try{return Pi(r,i,{agentId:n?.agentId})}catch{}return Fi(e,r)}function Ri(e,r){let i=w(r?.agentId??`main`);if(!e)return Ci(i);if(e.includes(`{agentId}`)){let r=e.replaceAll(`{agentId}`,i);return r.startsWith(`~`)?f.resolve(n(r,{home:t(process.env,p.homedir),env:process.env,homedir:p.homedir})):f.resolve(r)}return e.startsWith(`~`)?f.resolve(n(e,{home:t(process.env,p.homedir),env:process.env,homedir:p.homedir})):f.resolve(e)}export{R as $,br as A,je as At,U as B,se as Bt,Kr as C,Te as Ct,Rr as D,Ne as Dt,Fr as E,ze as Et,rr as F,pe as Ft,jn as G,ue as Gt,Rn as H,ae as Ht,tr as I,Se as It,Nn as J,re as Jt,Un as K,b as Kt,Kn as L,Ce as Lt,_r as M,Be as Mt,hr as N,Fe as Nt,qr as O,Pe as Ot,gr as P,Ae as Pt,z as Q,Hn as R,fe as Rt,Wr as S,S as St,Pr as T,Le as Tt,Fn as U,oe as Ut,Gn as V,ce as Vt,Wn as W,x as Wt,N as X,Mn as Y,un as Z,X as _,Ge as _t,Fi as a,Tn as at,ei as b,Ve as bt,xi as c,an as ct,ui as d,Ut as dt,I as et,Z as f,Bt as ft,pi as g,Je as gt,di as h,E as ht,Ii as i,xn as it,xr as j,Me as jt,Gr as k,w as kt,bi as l,Ht as lt,oi as m,T as mt,Li as n,F as nt,Si as o,Cn as ot,fi as p,O as pt,Vn as q,y as qt,wi as r,L as rt,Ri as s,rn as st,Ci as t,P as tt,si as u,Kt as ut,Qr as v,We as vt,Lr as w,Ie as wt,G as x,He as xt,ti as y,Ue as yt,An as z,ie as zt};
6
+ //# sourceMappingURL=paths-piJASC5k.js.map
@@ -1 +1,2 @@
1
1
  import e from"node:path";import t from"node:fs";import n from"node:os";function r(e){return e?.trim()||void 0}function i(t=process.env,r=n.homedir){let i=a(t,r);return i?e.resolve(i):void 0}function a(e,t){let n=r(e.OPENCLAW_HOME);if(n){if(n===`~`||n.startsWith(`~/`)||n.startsWith(`~\\`)){let i=r(e.HOME)??r(e.USERPROFILE)??o(t);return i?n.replace(/^~(?=$|[\\/])/,i):void 0}return n}return r(e.HOME)||r(e.USERPROFILE)||o(t)}function o(e){try{return r(e())}catch{return}}function s(t=process.env,r=n.homedir){return i(t,r)??e.resolve(process.cwd())}function c(e,t){if(!e.startsWith(`~`))return e;let a=r(t?.home)??i(t?.env??process.env,t?.homedir??n.homedir);return a?e.replace(/^~(?=$|[\\/])/,a):e}function l(e=process.env){return e.OPENCLAW_NIX_MODE===`1`}l();const u=[`.clawdbot`,`.moldbot`,`.moltbot`],d=`.openclaw-qbot.json`,f=[`openclaw.json`,`clawdbot.json`,`moldbot.json`,`moltbot.json`];function p(){return s(process.env,n.homedir)}function m(e){return()=>s(e,n.homedir)}function h(t=p){return u.map(n=>e.join(t(),n))}function g(t=p){return e.join(t(),`.qbotclaw`)}function _(e=process.env,n=m(e)){let r=()=>s(e,n),i=e.OPENCLAW_STATE_DIR?.trim()||e.CLAWDBOT_STATE_DIR?.trim();if(i)return v(i,e,r);let a=g(r);if(e.OPENCLAW_TEST_FAST===`1`)return a;let o=h(r);return t.existsSync(a)?a:o.find(e=>{try{return t.existsSync(e)}catch{return!1}})||a}function v(t,n=process.env,r=m(n)){let i=t.trim();if(!i)return i;if(i.startsWith(`~`)){let t=c(i,{home:s(n,r),env:n,homedir:r});return e.resolve(t)}return e.resolve(i)}const y=_();function b(t=process.env,n=_(t,m(t))){let r=t.OPENCLAW_CONFIG_PATH?.trim()||t.CLAWDBOT_CONFIG_PATH?.trim();return r?v(r,t,m(t)):e.join(n,d)}function x(e=process.env,n=m(e)){return e.OPENCLAW_TEST_FAST===`1`?b(e,_(e,n)):C(e,n).find(e=>{try{return t.existsSync(e)}catch{return!1}})||b(e,_(e,n))}function S(n=process.env,r=_(n,m(n)),i=m(n)){let a=n.OPENCLAW_CONFIG_PATH?.trim();if(a)return v(a,n,i);if(n.OPENCLAW_TEST_FAST===`1`)return e.join(r,d);let o=n.OPENCLAW_STATE_DIR?.trim(),s=[e.join(r,d),...f.map(t=>e.join(r,t))].find(e=>{try{return t.existsSync(e)}catch{return!1}});if(s)return s;if(o)return e.join(r,d);let c=_(n,i);return e.resolve(r)===e.resolve(c)?x(n,i):e.join(r,d)}x();function C(t=process.env,n=m(t)){let r=()=>s(t,n),i=t.OPENCLAW_CONFIG_PATH?.trim()||t.CLAWDBOT_CONFIG_PATH?.trim();if(i)return[v(i,t,r)];let a=[],o=t.OPENCLAW_STATE_DIR?.trim()||t.CLAWDBOT_STATE_DIR?.trim();if(o){let n=v(o,t,r);a.push(e.join(n,d)),a.push(...f.map(t=>e.join(n,t)))}let c=[g(r),...h(r)];for(let t of c)a.push(e.join(t,d)),a.push(...f.map(n=>e.join(t,n)));return a}const w=18789;function T(t=process.env,n=_(t,m(t))){let r=t.OPENCLAW_OAUTH_DIR?.trim();return r?v(r,t,m(t)):e.join(n,`credentials`)}function E(t=process.env,n=_(t,m(t))){return e.join(T(t,n),`oauth.json`)}function D(e,t=process.env){let n=t.OPENCLAW_GATEWAY_PORT?.trim()||t.CLAWDBOT_GATEWAY_PORT?.trim();if(n){let e=Number.parseInt(n,10);if(Number.isFinite(e)&&e>=0)return e}let r=e?.gateway?.port;return typeof r==`number`&&Number.isFinite(r)&&r>=0?r:w}export{D as a,_ as c,s as d,C as i,c as l,y as n,T as o,S as r,E as s,w as t,i as u};
2
+ //# sourceMappingURL=paths-rO4ehkyU.js.map
@@ -1 +1,2 @@
1
1
  const e=require(`./paths-Bcdg3ma0.cjs`),t=require(`./model-auth-D-7xiXhK.cjs`);let n=require(`node:path`);n=e.p(n);let r=require(`node:fs`);r=e.p(r);let i=require(`@mariozechner/pi-coding-agent`);i=e.p(i);function a(e){if(e.type===`api_key`){let t=typeof e.key==`string`?e.key.trim():``;return t?{type:`api_key`,key:t}:null}if(e.type===`token`){let t=typeof e.token==`string`?e.token.trim():``;return!t||typeof e.expires==`number`&&Number.isFinite(e.expires)&&Date.now()>=e.expires?null:{type:`api_key`,key:t}}if(e.type===`oauth`){let t=typeof e.access==`string`?e.access.trim():``,n=typeof e.refresh==`string`?e.refresh.trim():``;return!t||!n||!Number.isFinite(e.expires)||e.expires<=0?null:{type:`oauth`,access:t,refresh:n,expires:e.expires}}return null}function o(e){let n={};for(let r of Object.values(e.profiles)){let e=t.Ds(String(r.provider??``)).trim();if(!e||n[e])continue;let i=a(r);i&&(n[e]=i)}return n}const s=i.AuthStorage,c=i.ModelRegistry;function l(e){let t=JSON.stringify(e,null,2);return{withLock(e){let{result:n,next:r}=e(t);return typeof r==`string`&&(t=r),n}}}function u(e){return typeof e==`object`&&!!e&&!Array.isArray(e)}function d(e){if(process.env.OPENCLAW_AUTH_STORE_READONLY===`1`||!r.default.existsSync(e))return;let t;try{t=JSON.parse(r.default.readFileSync(e,`utf8`))}catch{return}if(!u(t))return;let n=!1;for(let[e,r]of Object.entries(t))u(r)&&r.type===`api_key`&&(delete t[e],n=!0);if(n){if(Object.keys(t).length===0){r.default.rmSync(e,{force:!0});return}r.default.writeFileSync(e,`${JSON.stringify(t,null,2)}\n`,`utf8`),r.default.chmodSync(e,384)}}function f(e,t,n){let r=e;if(typeof r.inMemory==`function`)return r.inMemory(n);let a=e;if(typeof a.fromStorage==`function`){let e=i.InMemoryAuthStorageBackend,t=typeof e==`function`?new e:l(n);return t.withLock(()=>({result:void 0,next:JSON.stringify(n,null,2)})),a.fromStorage(t)}let o=e,s=typeof o.create==`function`?o.create(t):new e(t);if(typeof s.setRuntimeApiKey==`function`)for(let[e,t]of Object.entries(n)){if(t.type===`api_key`){s.setRuntimeApiKey(e,t.key);continue}s.setRuntimeApiKey(e,t.access)}return s}function p(e){return o(t.hs(e,{allowKeychainPrompt:!1}))}function m(e){let t=p(e),r=n.default.join(e,`auth.json`);return d(r),f(s,r,t)}function h(e,t){return new c(e,n.default.join(t,`models.json`))}Object.defineProperty(exports,`i`,{enumerable:!0,get:function(){return h}}),Object.defineProperty(exports,`n`,{enumerable:!0,get:function(){return c}}),Object.defineProperty(exports,`r`,{enumerable:!0,get:function(){return m}}),Object.defineProperty(exports,`t`,{enumerable:!0,get:function(){return s}});
2
+ //# sourceMappingURL=pi-model-discovery-B9boErNZ.cjs.map
@@ -1 +1,2 @@
1
1
  const e=require(`./paths-BvlJvmRS.cjs`),t=require(`./config-rBz8C_Hi.cjs`);let n=require(`node:fs`);n=e.p(n);let r=require(`node:path`);r=e.p(r);let i=require(`@mariozechner/pi-coding-agent`);i=e.p(i);function a(e){if(e.type===`api_key`){let t=typeof e.key==`string`?e.key.trim():``;return t?{type:`api_key`,key:t}:null}if(e.type===`token`){let t=typeof e.token==`string`?e.token.trim():``;return!t||typeof e.expires==`number`&&Number.isFinite(e.expires)&&Date.now()>=e.expires?null:{type:`api_key`,key:t}}if(e.type===`oauth`){let t=typeof e.access==`string`?e.access.trim():``,n=typeof e.refresh==`string`?e.refresh.trim():``;return!t||!n||!Number.isFinite(e.expires)||e.expires<=0?null:{type:`oauth`,access:t,refresh:n,expires:e.expires}}return null}function o(e){let n={};for(let r of Object.values(e.profiles)){let e=t.Pt(String(r.provider??``)).trim();if(!e||n[e])continue;let i=a(r);i&&(n[e]=i)}return n}const s=i.AuthStorage,c=i.ModelRegistry;function l(e){let t=JSON.stringify(e,null,2);return{withLock(e){let{result:n,next:r}=e(t);return typeof r==`string`&&(t=r),n}}}function u(e){return typeof e==`object`&&!!e&&!Array.isArray(e)}function d(e){if(process.env.OPENCLAW_AUTH_STORE_READONLY===`1`||!n.default.existsSync(e))return;let t;try{t=JSON.parse(n.default.readFileSync(e,`utf8`))}catch{return}if(!u(t))return;let r=!1;for(let[e,n]of Object.entries(t))u(n)&&n.type===`api_key`&&(delete t[e],r=!0);if(r){if(Object.keys(t).length===0){n.default.rmSync(e,{force:!0});return}n.default.writeFileSync(e,`${JSON.stringify(t,null,2)}\n`,`utf8`),n.default.chmodSync(e,384)}}function f(e,t,n){let r=e;if(typeof r.inMemory==`function`)return r.inMemory(n);let a=e;if(typeof a.fromStorage==`function`){let e=i.InMemoryAuthStorageBackend,t=typeof e==`function`?new e:l(n);return t.withLock(()=>({result:void 0,next:JSON.stringify(n,null,2)})),a.fromStorage(t)}let o=e,s=typeof o.create==`function`?o.create(t):new e(t);if(typeof s.setRuntimeApiKey==`function`)for(let[e,t]of Object.entries(n)){if(t.type===`api_key`){s.setRuntimeApiKey(e,t.key);continue}s.setRuntimeApiKey(e,t.access)}return s}function p(e){return o(t.Il(e,{allowKeychainPrompt:!1}))}function m(e){let t=p(e),n=r.default.join(e,`auth.json`);return d(n),f(s,n,t)}function h(e,t){return new c(e,r.default.join(t,`models.json`))}Object.defineProperty(exports,`i`,{enumerable:!0,get:function(){return h}}),Object.defineProperty(exports,`n`,{enumerable:!0,get:function(){return c}}),Object.defineProperty(exports,`r`,{enumerable:!0,get:function(){return m}}),Object.defineProperty(exports,`t`,{enumerable:!0,get:function(){return s}});
2
+ //# sourceMappingURL=pi-model-discovery-BJ8wTgFH.cjs.map
@@ -1 +1,2 @@
1
1
  import{t as e}from"./rolldown-runtime-CNxR59P3.js";import{Nl as t,Pt as n}from"./config-ByA2hluR.js";import r from"node:fs";import i from"node:path";import*as a from"@mariozechner/pi-coding-agent";function o(e){if(e.type===`api_key`){let t=typeof e.key==`string`?e.key.trim():``;return t?{type:`api_key`,key:t}:null}if(e.type===`token`){let t=typeof e.token==`string`?e.token.trim():``;return!t||typeof e.expires==`number`&&Number.isFinite(e.expires)&&Date.now()>=e.expires?null:{type:`api_key`,key:t}}if(e.type===`oauth`){let t=typeof e.access==`string`?e.access.trim():``,n=typeof e.refresh==`string`?e.refresh.trim():``;return!t||!n||!Number.isFinite(e.expires)||e.expires<=0?null:{type:`oauth`,access:t,refresh:n,expires:e.expires}}return null}function s(e){let t={};for(let r of Object.values(e.profiles)){let e=n(String(r.provider??``)).trim();if(!e||t[e])continue;let i=o(r);i&&(t[e]=i)}return t}var c=e({AuthStorage:()=>l,ModelRegistry:()=>u,discoverAuthStorage:()=>g,discoverModels:()=>_});const l=a.AuthStorage,u=a.ModelRegistry;function d(e){let t=JSON.stringify(e,null,2);return{withLock(e){let{result:n,next:r}=e(t);return typeof r==`string`&&(t=r),n}}}function f(e){return typeof e==`object`&&!!e&&!Array.isArray(e)}function p(e){if(process.env.OPENCLAW_AUTH_STORE_READONLY===`1`||!r.existsSync(e))return;let t;try{t=JSON.parse(r.readFileSync(e,`utf8`))}catch{return}if(!f(t))return;let n=!1;for(let[e,r]of Object.entries(t))f(r)&&r.type===`api_key`&&(delete t[e],n=!0);if(n){if(Object.keys(t).length===0){r.rmSync(e,{force:!0});return}r.writeFileSync(e,`${JSON.stringify(t,null,2)}\n`,`utf8`),r.chmodSync(e,384)}}function m(e,t,n){let r=e;if(typeof r.inMemory==`function`)return r.inMemory(n);let i=e;if(typeof i.fromStorage==`function`){let e=a.InMemoryAuthStorageBackend,t=typeof e==`function`?new e:d(n);return t.withLock(()=>({result:void 0,next:JSON.stringify(n,null,2)})),i.fromStorage(t)}let o=e,s=typeof o.create==`function`?o.create(t):new e(t);if(typeof s.setRuntimeApiKey==`function`)for(let[e,t]of Object.entries(n)){if(t.type===`api_key`){s.setRuntimeApiKey(e,t.key);continue}s.setRuntimeApiKey(e,t.access)}return s}function h(e){return s(t(e,{allowKeychainPrompt:!1}))}function g(e){let t=h(e),n=i.join(e,`auth.json`);return p(n),m(l,n,t)}function _(e,t){return new u(e,i.join(t,`models.json`))}export{_ as n,c as r,g as t};
2
+ //# sourceMappingURL=pi-model-discovery-Bb2vCP6M.js.map
@@ -1 +1,2 @@
1
1
  import{t as e}from"./rolldown-runtime-CNxR59P3.js";import{Bo as t,ko as n}from"./model-auth-Cw3fuhm_.js";import r from"node:path";import i from"node:fs";import*as a from"@mariozechner/pi-coding-agent";function o(e){if(e.type===`api_key`){let t=typeof e.key==`string`?e.key.trim():``;return t?{type:`api_key`,key:t}:null}if(e.type===`token`){let t=typeof e.token==`string`?e.token.trim():``;return!t||typeof e.expires==`number`&&Number.isFinite(e.expires)&&Date.now()>=e.expires?null:{type:`api_key`,key:t}}if(e.type===`oauth`){let t=typeof e.access==`string`?e.access.trim():``,n=typeof e.refresh==`string`?e.refresh.trim():``;return!t||!n||!Number.isFinite(e.expires)||e.expires<=0?null:{type:`oauth`,access:t,refresh:n,expires:e.expires}}return null}function s(e){let n={};for(let r of Object.values(e.profiles)){let e=t(String(r.provider??``)).trim();if(!e||n[e])continue;let i=o(r);i&&(n[e]=i)}return n}var c=e({AuthStorage:()=>l,ModelRegistry:()=>u,discoverAuthStorage:()=>g,discoverModels:()=>_});const l=a.AuthStorage,u=a.ModelRegistry;function d(e){let t=JSON.stringify(e,null,2);return{withLock(e){let{result:n,next:r}=e(t);return typeof r==`string`&&(t=r),n}}}function f(e){return typeof e==`object`&&!!e&&!Array.isArray(e)}function p(e){if(process.env.OPENCLAW_AUTH_STORE_READONLY===`1`||!i.existsSync(e))return;let t;try{t=JSON.parse(i.readFileSync(e,`utf8`))}catch{return}if(!f(t))return;let n=!1;for(let[e,r]of Object.entries(t))f(r)&&r.type===`api_key`&&(delete t[e],n=!0);if(n){if(Object.keys(t).length===0){i.rmSync(e,{force:!0});return}i.writeFileSync(e,`${JSON.stringify(t,null,2)}\n`,`utf8`),i.chmodSync(e,384)}}function m(e,t,n){let r=e;if(typeof r.inMemory==`function`)return r.inMemory(n);let i=e;if(typeof i.fromStorage==`function`){let e=a.InMemoryAuthStorageBackend,t=typeof e==`function`?new e:d(n);return t.withLock(()=>({result:void 0,next:JSON.stringify(n,null,2)})),i.fromStorage(t)}let o=e,s=typeof o.create==`function`?o.create(t):new e(t);if(typeof s.setRuntimeApiKey==`function`)for(let[e,t]of Object.entries(n)){if(t.type===`api_key`){s.setRuntimeApiKey(e,t.key);continue}s.setRuntimeApiKey(e,t.access)}return s}function h(e){return s(n(e,{allowKeychainPrompt:!1}))}function g(e){let t=h(e),n=r.join(e,`auth.json`);return p(n),m(l,n,t)}function _(e,t){return new u(e,r.join(t,`models.json`))}export{_ as n,c as r,g as t};
2
+ //# sourceMappingURL=pi-model-discovery-Bor7jHYd.js.map
@@ -1 +1,2 @@
1
1
  const e=require(`./model-selection-BADTZM9n.cjs`);let t=require(`node:fs`);t=e.Pt(t);let n=require(`node:path`);n=e.Pt(n);let r=require(`@mariozechner/pi-coding-agent`);r=e.Pt(r);function i(e){if(e.type===`api_key`){let t=typeof e.key==`string`?e.key.trim():``;return t?{type:`api_key`,key:t}:null}if(e.type===`token`){let t=typeof e.token==`string`?e.token.trim():``;return!t||typeof e.expires==`number`&&Number.isFinite(e.expires)&&Date.now()>=e.expires?null:{type:`api_key`,key:t}}if(e.type===`oauth`){let t=typeof e.access==`string`?e.access.trim():``,n=typeof e.refresh==`string`?e.refresh.trim():``;return!t||!n||!Number.isFinite(e.expires)||e.expires<=0?null:{type:`oauth`,access:t,refresh:n,expires:e.expires}}return null}function a(t){let n={};for(let r of Object.values(t.profiles)){let t=e.r(String(r.provider??``)).trim();if(!t||n[t])continue;let a=i(r);a&&(n[t]=a)}return n}const o=r.AuthStorage,s=r.ModelRegistry;function c(e){let t=JSON.stringify(e,null,2);return{withLock(e){let{result:n,next:r}=e(t);return typeof r==`string`&&(t=r),n}}}function l(e){return typeof e==`object`&&!!e&&!Array.isArray(e)}function u(e){if(process.env.OPENCLAW_AUTH_STORE_READONLY===`1`||!t.default.existsSync(e))return;let n;try{n=JSON.parse(t.default.readFileSync(e,`utf8`))}catch{return}if(!l(n))return;let r=!1;for(let[e,t]of Object.entries(n))l(t)&&t.type===`api_key`&&(delete n[e],r=!0);if(r){if(Object.keys(n).length===0){t.default.rmSync(e,{force:!0});return}t.default.writeFileSync(e,`${JSON.stringify(n,null,2)}\n`,`utf8`),t.default.chmodSync(e,384)}}function d(e,t,n){let i=e;if(typeof i.inMemory==`function`)return i.inMemory(n);let a=e;if(typeof a.fromStorage==`function`){let e=r.InMemoryAuthStorageBackend,t=typeof e==`function`?new e:c(n);return t.withLock(()=>({result:void 0,next:JSON.stringify(n,null,2)})),a.fromStorage(t)}let o=e,s=typeof o.create==`function`?o.create(t):new e(t);if(typeof s.setRuntimeApiKey==`function`)for(let[e,t]of Object.entries(n)){if(t.type===`api_key`){s.setRuntimeApiKey(e,t.key);continue}s.setRuntimeApiKey(e,t.access)}return s}function f(t){return a(e.W(t,{allowKeychainPrompt:!1}))}function p(e){let t=f(e),r=n.default.join(e,`auth.json`);return u(r),d(o,r,t)}function m(e,t){return new s(e,n.default.join(t,`models.json`))}exports.AuthStorage=o,exports.ModelRegistry=s,exports.discoverAuthStorage=p,exports.discoverModels=m;
2
+ //# sourceMappingURL=pi-model-discovery-BrTw1qE2.cjs.map
@@ -1 +1,2 @@
1
1
  import{t as e}from"./rolldown-runtime-CNxR59P3.js";import{Ga as t,in as n}from"./sessions-DxXXAfdI.js";import r from"node:path";import i from"node:fs";import*as a from"@mariozechner/pi-coding-agent";function o(e){if(e.type===`api_key`){let t=typeof e.key==`string`?e.key.trim():``;return t?{type:`api_key`,key:t}:null}if(e.type===`token`){let t=typeof e.token==`string`?e.token.trim():``;return!t||typeof e.expires==`number`&&Number.isFinite(e.expires)&&Date.now()>=e.expires?null:{type:`api_key`,key:t}}if(e.type===`oauth`){let t=typeof e.access==`string`?e.access.trim():``,n=typeof e.refresh==`string`?e.refresh.trim():``;return!t||!n||!Number.isFinite(e.expires)||e.expires<=0?null:{type:`oauth`,access:t,refresh:n,expires:e.expires}}return null}function s(e){let t={};for(let r of Object.values(e.profiles)){let e=n(String(r.provider??``)).trim();if(!e||t[e])continue;let i=o(r);i&&(t[e]=i)}return t}var c=e({AuthStorage:()=>l,ModelRegistry:()=>u,discoverAuthStorage:()=>g,discoverModels:()=>_});const l=a.AuthStorage,u=a.ModelRegistry;function d(e){let t=JSON.stringify(e,null,2);return{withLock(e){let{result:n,next:r}=e(t);return typeof r==`string`&&(t=r),n}}}function f(e){return typeof e==`object`&&!!e&&!Array.isArray(e)}function p(e){if(process.env.OPENCLAW_AUTH_STORE_READONLY===`1`||!i.existsSync(e))return;let t;try{t=JSON.parse(i.readFileSync(e,`utf8`))}catch{return}if(!f(t))return;let n=!1;for(let[e,r]of Object.entries(t))f(r)&&r.type===`api_key`&&(delete t[e],n=!0);if(n){if(Object.keys(t).length===0){i.rmSync(e,{force:!0});return}i.writeFileSync(e,`${JSON.stringify(t,null,2)}\n`,`utf8`),i.chmodSync(e,384)}}function m(e,t,n){let r=e;if(typeof r.inMemory==`function`)return r.inMemory(n);let i=e;if(typeof i.fromStorage==`function`){let e=a.InMemoryAuthStorageBackend,t=typeof e==`function`?new e:d(n);return t.withLock(()=>({result:void 0,next:JSON.stringify(n,null,2)})),i.fromStorage(t)}let o=e,s=typeof o.create==`function`?o.create(t):new e(t);if(typeof s.setRuntimeApiKey==`function`)for(let[e,t]of Object.entries(n)){if(t.type===`api_key`){s.setRuntimeApiKey(e,t.key);continue}s.setRuntimeApiKey(e,t.access)}return s}function h(e){return s(t(e,{allowKeychainPrompt:!1}))}function g(e){let t=h(e),n=r.join(e,`auth.json`);return p(n),m(l,n,t)}function _(e,t){return new u(e,r.join(t,`models.json`))}export{_ as n,c as r,g as t};
2
+ //# sourceMappingURL=pi-model-discovery-BuEMyAsU.js.map
@@ -1 +1,2 @@
1
1
  import{W as e,r as t}from"./model-selection-DUAudCtL.js";import n from"node:fs";import r from"node:path";import*as i from"@mariozechner/pi-coding-agent";function a(e){if(e.type===`api_key`){let t=typeof e.key==`string`?e.key.trim():``;return t?{type:`api_key`,key:t}:null}if(e.type===`token`){let t=typeof e.token==`string`?e.token.trim():``;return!t||typeof e.expires==`number`&&Number.isFinite(e.expires)&&Date.now()>=e.expires?null:{type:`api_key`,key:t}}if(e.type===`oauth`){let t=typeof e.access==`string`?e.access.trim():``,n=typeof e.refresh==`string`?e.refresh.trim():``;return!t||!n||!Number.isFinite(e.expires)||e.expires<=0?null:{type:`oauth`,access:t,refresh:n,expires:e.expires}}return null}function o(e){let n={};for(let r of Object.values(e.profiles)){let e=t(String(r.provider??``)).trim();if(!e||n[e])continue;let i=a(r);i&&(n[e]=i)}return n}const s=i.AuthStorage,c=i.ModelRegistry;function l(e){let t=JSON.stringify(e,null,2);return{withLock(e){let{result:n,next:r}=e(t);return typeof r==`string`&&(t=r),n}}}function u(e){return typeof e==`object`&&!!e&&!Array.isArray(e)}function d(e){if(process.env.OPENCLAW_AUTH_STORE_READONLY===`1`||!n.existsSync(e))return;let t;try{t=JSON.parse(n.readFileSync(e,`utf8`))}catch{return}if(!u(t))return;let r=!1;for(let[e,n]of Object.entries(t))u(n)&&n.type===`api_key`&&(delete t[e],r=!0);if(r){if(Object.keys(t).length===0){n.rmSync(e,{force:!0});return}n.writeFileSync(e,`${JSON.stringify(t,null,2)}\n`,`utf8`),n.chmodSync(e,384)}}function f(e,t,n){let r=e;if(typeof r.inMemory==`function`)return r.inMemory(n);let a=e;if(typeof a.fromStorage==`function`){let e=i.InMemoryAuthStorageBackend,t=typeof e==`function`?new e:l(n);return t.withLock(()=>({result:void 0,next:JSON.stringify(n,null,2)})),a.fromStorage(t)}let o=e,s=typeof o.create==`function`?o.create(t):new e(t);if(typeof s.setRuntimeApiKey==`function`)for(let[e,t]of Object.entries(n)){if(t.type===`api_key`){s.setRuntimeApiKey(e,t.key);continue}s.setRuntimeApiKey(e,t.access)}return s}function p(t){return o(e(t,{allowKeychainPrompt:!1}))}function m(e){let t=p(e),n=r.join(e,`auth.json`);return d(n),f(s,n,t)}function h(e,t){return new c(e,r.join(t,`models.json`))}export{s as AuthStorage,c as ModelRegistry,m as discoverAuthStorage,h as discoverModels};
2
+ //# sourceMappingURL=pi-model-discovery-CV9NTjC4.js.map
@@ -1 +1,2 @@
1
1
  import{t as e}from"./rolldown-runtime-CNxR59P3.js";import{Ja as t,La as n}from"./model-auth-C1YL9HcW.js";import r from"node:fs";import i from"node:path";import*as a from"@mariozechner/pi-coding-agent";function o(e){if(e.type===`api_key`){let t=typeof e.key==`string`?e.key.trim():``;return t?{type:`api_key`,key:t}:null}if(e.type===`token`){let t=typeof e.token==`string`?e.token.trim():``;return!t||typeof e.expires==`number`&&Number.isFinite(e.expires)&&Date.now()>=e.expires?null:{type:`api_key`,key:t}}if(e.type===`oauth`){let t=typeof e.access==`string`?e.access.trim():``,n=typeof e.refresh==`string`?e.refresh.trim():``;return!t||!n||!Number.isFinite(e.expires)||e.expires<=0?null:{type:`oauth`,access:t,refresh:n,expires:e.expires}}return null}function s(e){let n={};for(let r of Object.values(e.profiles)){let e=t(String(r.provider??``)).trim();if(!e||n[e])continue;let i=o(r);i&&(n[e]=i)}return n}var c=e({AuthStorage:()=>l,ModelRegistry:()=>u,discoverAuthStorage:()=>g,discoverModels:()=>_});const l=a.AuthStorage,u=a.ModelRegistry;function d(e){let t=JSON.stringify(e,null,2);return{withLock(e){let{result:n,next:r}=e(t);return typeof r==`string`&&(t=r),n}}}function f(e){return typeof e==`object`&&!!e&&!Array.isArray(e)}function p(e){if(process.env.OPENCLAW_AUTH_STORE_READONLY===`1`||!r.existsSync(e))return;let t;try{t=JSON.parse(r.readFileSync(e,`utf8`))}catch{return}if(!f(t))return;let n=!1;for(let[e,r]of Object.entries(t))f(r)&&r.type===`api_key`&&(delete t[e],n=!0);if(n){if(Object.keys(t).length===0){r.rmSync(e,{force:!0});return}r.writeFileSync(e,`${JSON.stringify(t,null,2)}\n`,`utf8`),r.chmodSync(e,384)}}function m(e,t,n){let r=e;if(typeof r.inMemory==`function`)return r.inMemory(n);let i=e;if(typeof i.fromStorage==`function`){let e=a.InMemoryAuthStorageBackend,t=typeof e==`function`?new e:d(n);return t.withLock(()=>({result:void 0,next:JSON.stringify(n,null,2)})),i.fromStorage(t)}let o=e,s=typeof o.create==`function`?o.create(t):new e(t);if(typeof s.setRuntimeApiKey==`function`)for(let[e,t]of Object.entries(n)){if(t.type===`api_key`){s.setRuntimeApiKey(e,t.key);continue}s.setRuntimeApiKey(e,t.access)}return s}function h(e){return s(n(e,{allowKeychainPrompt:!1}))}function g(e){let t=h(e),n=i.join(e,`auth.json`);return p(n),m(l,n,t)}function _(e,t){return new u(e,i.join(t,`models.json`))}export{_ as n,c as r,g as t};
2
+ //# sourceMappingURL=pi-model-discovery-D5tLf04u.js.map
@@ -1 +1,2 @@
1
1
  const e=require(`./paths-Bcdg3ma0.cjs`),t=require(`./sessions-Dz5JUL8j.cjs`);let n=require(`node:path`);n=e.p(n);let r=require(`node:fs`);r=e.p(r);let i=require(`@mariozechner/pi-coding-agent`);i=e.p(i);function a(e){if(e.type===`api_key`){let t=typeof e.key==`string`?e.key.trim():``;return t?{type:`api_key`,key:t}:null}if(e.type===`token`){let t=typeof e.token==`string`?e.token.trim():``;return!t||typeof e.expires==`number`&&Number.isFinite(e.expires)&&Date.now()>=e.expires?null:{type:`api_key`,key:t}}if(e.type===`oauth`){let t=typeof e.access==`string`?e.access.trim():``,n=typeof e.refresh==`string`?e.refresh.trim():``;return!t||!n||!Number.isFinite(e.expires)||e.expires<=0?null:{type:`oauth`,access:t,refresh:n,expires:e.expires}}return null}function o(e){let n={};for(let r of Object.values(e.profiles)){let e=t.in(String(r.provider??``)).trim();if(!e||n[e])continue;let i=a(r);i&&(n[e]=i)}return n}const s=i.AuthStorage,c=i.ModelRegistry;function l(e){let t=JSON.stringify(e,null,2);return{withLock(e){let{result:n,next:r}=e(t);return typeof r==`string`&&(t=r),n}}}function u(e){return typeof e==`object`&&!!e&&!Array.isArray(e)}function d(e){if(process.env.OPENCLAW_AUTH_STORE_READONLY===`1`||!r.default.existsSync(e))return;let t;try{t=JSON.parse(r.default.readFileSync(e,`utf8`))}catch{return}if(!u(t))return;let n=!1;for(let[e,r]of Object.entries(t))u(r)&&r.type===`api_key`&&(delete t[e],n=!0);if(n){if(Object.keys(t).length===0){r.default.rmSync(e,{force:!0});return}r.default.writeFileSync(e,`${JSON.stringify(t,null,2)}\n`,`utf8`),r.default.chmodSync(e,384)}}function f(e,t,n){let r=e;if(typeof r.inMemory==`function`)return r.inMemory(n);let a=e;if(typeof a.fromStorage==`function`){let e=i.InMemoryAuthStorageBackend,t=typeof e==`function`?new e:l(n);return t.withLock(()=>({result:void 0,next:JSON.stringify(n,null,2)})),a.fromStorage(t)}let o=e,s=typeof o.create==`function`?o.create(t):new e(t);if(typeof s.setRuntimeApiKey==`function`)for(let[e,t]of Object.entries(n)){if(t.type===`api_key`){s.setRuntimeApiKey(e,t.key);continue}s.setRuntimeApiKey(e,t.access)}return s}function p(e){return o(t.Ja(e,{allowKeychainPrompt:!1}))}function m(e){let t=p(e),r=n.default.join(e,`auth.json`);return d(r),f(s,r,t)}function h(e,t){return new c(e,n.default.join(t,`models.json`))}Object.defineProperty(exports,`i`,{enumerable:!0,get:function(){return h}}),Object.defineProperty(exports,`n`,{enumerable:!0,get:function(){return c}}),Object.defineProperty(exports,`r`,{enumerable:!0,get:function(){return m}}),Object.defineProperty(exports,`t`,{enumerable:!0,get:function(){return s}});
2
+ //# sourceMappingURL=pi-model-discovery-D5xlUS2J.cjs.map
@@ -1 +1,2 @@
1
1
  const e=require(`./paths-Bcdg3ma0.cjs`),t=require(`./model-auth-TFUxaK0f.cjs`);let n=require(`node:path`);n=e.p(n);let r=require(`node:fs`);r=e.p(r);let i=require(`@mariozechner/pi-coding-agent`);i=e.p(i);function a(e){if(e.type===`api_key`){let t=typeof e.key==`string`?e.key.trim():``;return t?{type:`api_key`,key:t}:null}if(e.type===`token`){let t=typeof e.token==`string`?e.token.trim():``;return!t||typeof e.expires==`number`&&Number.isFinite(e.expires)&&Date.now()>=e.expires?null:{type:`api_key`,key:t}}if(e.type===`oauth`){let t=typeof e.access==`string`?e.access.trim():``,n=typeof e.refresh==`string`?e.refresh.trim():``;return!t||!n||!Number.isFinite(e.expires)||e.expires<=0?null:{type:`oauth`,access:t,refresh:n,expires:e.expires}}return null}function o(e){let n={};for(let r of Object.values(e.profiles)){let e=t.Cs(String(r.provider??``)).trim();if(!e||n[e])continue;let i=a(r);i&&(n[e]=i)}return n}const s=i.AuthStorage,c=i.ModelRegistry;function l(e){let t=JSON.stringify(e,null,2);return{withLock(e){let{result:n,next:r}=e(t);return typeof r==`string`&&(t=r),n}}}function u(e){return typeof e==`object`&&!!e&&!Array.isArray(e)}function d(e){if(process.env.OPENCLAW_AUTH_STORE_READONLY===`1`||!r.default.existsSync(e))return;let t;try{t=JSON.parse(r.default.readFileSync(e,`utf8`))}catch{return}if(!u(t))return;let n=!1;for(let[e,r]of Object.entries(t))u(r)&&r.type===`api_key`&&(delete t[e],n=!0);if(n){if(Object.keys(t).length===0){r.default.rmSync(e,{force:!0});return}r.default.writeFileSync(e,`${JSON.stringify(t,null,2)}\n`,`utf8`),r.default.chmodSync(e,384)}}function f(e,t,n){let r=e;if(typeof r.inMemory==`function`)return r.inMemory(n);let a=e;if(typeof a.fromStorage==`function`){let e=i.InMemoryAuthStorageBackend,t=typeof e==`function`?new e:l(n);return t.withLock(()=>({result:void 0,next:JSON.stringify(n,null,2)})),a.fromStorage(t)}let o=e,s=typeof o.create==`function`?o.create(t):new e(t);if(typeof s.setRuntimeApiKey==`function`)for(let[e,t]of Object.entries(n)){if(t.type===`api_key`){s.setRuntimeApiKey(e,t.key);continue}s.setRuntimeApiKey(e,t.access)}return s}function p(e){return o(t.ds(e,{allowKeychainPrompt:!1}))}function m(e){let t=p(e),r=n.default.join(e,`auth.json`);return d(r),f(s,r,t)}function h(e,t){return new c(e,n.default.join(t,`models.json`))}Object.defineProperty(exports,`i`,{enumerable:!0,get:function(){return h}}),Object.defineProperty(exports,`n`,{enumerable:!0,get:function(){return c}}),Object.defineProperty(exports,`r`,{enumerable:!0,get:function(){return m}}),Object.defineProperty(exports,`t`,{enumerable:!0,get:function(){return s}});
2
+ //# sourceMappingURL=pi-model-discovery-DGoPUzBj.cjs.map
@@ -1 +1,2 @@
1
1
  const e=require(`./paths-Bcdg3ma0.cjs`),t=require(`./model-auth-BwajGuoF.cjs`);let n=require(`node:path`);n=e.p(n);let r=require(`node:fs`);r=e.p(r);let i=require(`@mariozechner/pi-coding-agent`);i=e.p(i);function a(e){if(e.type===`api_key`){let t=typeof e.key==`string`?e.key.trim():``;return t?{type:`api_key`,key:t}:null}if(e.type===`token`){let t=typeof e.token==`string`?e.token.trim():``;return!t||typeof e.expires==`number`&&Number.isFinite(e.expires)&&Date.now()>=e.expires?null:{type:`api_key`,key:t}}if(e.type===`oauth`){let t=typeof e.access==`string`?e.access.trim():``,n=typeof e.refresh==`string`?e.refresh.trim():``;return!t||!n||!Number.isFinite(e.expires)||e.expires<=0?null:{type:`oauth`,access:t,refresh:n,expires:e.expires}}return null}function o(e){let n={};for(let r of Object.values(e.profiles)){let e=t.Wo(String(r.provider??``)).trim();if(!e||n[e])continue;let i=a(r);i&&(n[e]=i)}return n}const s=i.AuthStorage,c=i.ModelRegistry;function l(e){let t=JSON.stringify(e,null,2);return{withLock(e){let{result:n,next:r}=e(t);return typeof r==`string`&&(t=r),n}}}function u(e){return typeof e==`object`&&!!e&&!Array.isArray(e)}function d(e){if(process.env.OPENCLAW_AUTH_STORE_READONLY===`1`||!r.default.existsSync(e))return;let t;try{t=JSON.parse(r.default.readFileSync(e,`utf8`))}catch{return}if(!u(t))return;let n=!1;for(let[e,r]of Object.entries(t))u(r)&&r.type===`api_key`&&(delete t[e],n=!0);if(n){if(Object.keys(t).length===0){r.default.rmSync(e,{force:!0});return}r.default.writeFileSync(e,`${JSON.stringify(t,null,2)}\n`,`utf8`),r.default.chmodSync(e,384)}}function f(e,t,n){let r=e;if(typeof r.inMemory==`function`)return r.inMemory(n);let a=e;if(typeof a.fromStorage==`function`){let e=i.InMemoryAuthStorageBackend,t=typeof e==`function`?new e:l(n);return t.withLock(()=>({result:void 0,next:JSON.stringify(n,null,2)})),a.fromStorage(t)}let o=e,s=typeof o.create==`function`?o.create(t):new e(t);if(typeof s.setRuntimeApiKey==`function`)for(let[e,t]of Object.entries(n)){if(t.type===`api_key`){s.setRuntimeApiKey(e,t.key);continue}s.setRuntimeApiKey(e,t.access)}return s}function p(e){return o(t.Mo(e,{allowKeychainPrompt:!1}))}function m(e){let t=p(e),r=n.default.join(e,`auth.json`);return d(r),f(s,r,t)}function h(e,t){return new c(e,n.default.join(t,`models.json`))}Object.defineProperty(exports,`i`,{enumerable:!0,get:function(){return h}}),Object.defineProperty(exports,`n`,{enumerable:!0,get:function(){return c}}),Object.defineProperty(exports,`r`,{enumerable:!0,get:function(){return m}}),Object.defineProperty(exports,`t`,{enumerable:!0,get:function(){return s}});
2
+ //# sourceMappingURL=pi-model-discovery-DMrqvV1O.cjs.map