@harrylabsj/kiwi-merchant-cloud 0.12.6 → 0.12.7

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 (1287) hide show
  1. package/app/a2a/access/workbuddy-address.d.ts +45 -0
  2. package/app/a2a/access/workbuddy-address.js +88 -0
  3. package/app/a2a/access/workbuddy-address.js.map +1 -0
  4. package/app/a2a/client/client.d.ts +6 -0
  5. package/app/a2a/client/client.js +27 -2
  6. package/app/a2a/client/client.js.map +1 -1
  7. package/app/a2a/client/types.d.ts +5 -0
  8. package/app/a2a/server/server.d.ts +5 -0
  9. package/app/a2a/server/server.js +10 -2
  10. package/app/a2a/server/server.js.map +1 -1
  11. package/app/buyer-core/a2a-knp.d.ts +18 -1
  12. package/app/buyer-core/a2a-knp.js +29 -5
  13. package/app/buyer-core/a2a-knp.js.map +1 -1
  14. package/app/buyer-core/a2a-negotiator.d.ts +4 -0
  15. package/app/buyer-core/a2a-negotiator.js +3 -0
  16. package/app/buyer-core/a2a-negotiator.js.map +1 -1
  17. package/app/buyer-core/a2a-quote-fetcher.d.ts +47 -0
  18. package/app/buyer-core/a2a-quote-fetcher.js +109 -11
  19. package/app/buyer-core/a2a-quote-fetcher.js.map +1 -1
  20. package/app/buyer-core/build-service.d.ts +7 -0
  21. package/app/buyer-core/build-service.js +67 -0
  22. package/app/buyer-core/build-service.js.map +1 -1
  23. package/app/buyer-core/merchant-index.js +3 -0
  24. package/app/buyer-core/merchant-index.js.map +1 -1
  25. package/app/buyer-core/protocol-recovery.js +7 -0
  26. package/app/buyer-core/protocol-recovery.js.map +1 -1
  27. package/app/buyer-core/service.d.ts +14 -0
  28. package/app/buyer-core/service.js.map +1 -1
  29. package/app/cloud/access/workbuddy-share-link.d.ts +92 -0
  30. package/app/cloud/access/workbuddy-share-link.js +150 -0
  31. package/app/cloud/access/workbuddy-share-link.js.map +1 -0
  32. package/app/cloud/bootstrap.js +33 -0
  33. package/app/cloud/bootstrap.js.map +1 -1
  34. package/app/cloud/catalog-client.d.ts +66 -0
  35. package/app/cloud/catalog-client.js +155 -0
  36. package/app/cloud/catalog-client.js.map +1 -1
  37. package/app/cloud/config.d.ts +6 -0
  38. package/app/cloud/config.js +4 -0
  39. package/app/cloud/config.js.map +1 -1
  40. package/app/cloud/connect-service.d.ts +68 -0
  41. package/app/cloud/connect-service.js +198 -0
  42. package/app/cloud/connect-service.js.map +1 -1
  43. package/app/cloud/http-router.d.ts +5 -0
  44. package/app/cloud/http-router.js +7 -0
  45. package/app/cloud/http-router.js.map +1 -1
  46. package/app/cloud-sample/products.json +3 -3
  47. package/app/discovery/catalog-source/kiwi-record.d.ts +10 -0
  48. package/app/discovery/catalog-source/kiwi-record.js.map +1 -1
  49. package/app/discovery/catalog-source/merchant-access.d.ts +77 -0
  50. package/app/discovery/catalog-source/merchant-access.js +279 -0
  51. package/app/discovery/catalog-source/merchant-access.js.map +1 -0
  52. package/app/http/merchant-management/api.d.ts +21 -0
  53. package/app/http/merchant-management/api.js +79 -0
  54. package/app/http/merchant-management/api.js.map +1 -1
  55. package/app/http/merchant-management/page.js +81 -1
  56. package/app/http/merchant-management/page.js.map +1 -1
  57. package/app/tools/trusted-buyer-keys.d.ts +31 -0
  58. package/app/tools/trusted-buyer-keys.js +98 -0
  59. package/app/tools/trusted-buyer-keys.js.map +1 -0
  60. package/app/tools/workbuddy-echo.d.ts +69 -0
  61. package/app/tools/workbuddy-echo.js +132 -0
  62. package/app/tools/workbuddy-echo.js.map +1 -0
  63. package/build-manifest.json +42772 -41742
  64. package/contracts/kiwi-catalog/1.0/agent-record.schema.json +21 -0
  65. package/contracts/kiwi-contracts.lock.json +2 -2
  66. package/contracts/manifest.json +2 -2
  67. package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/README.md +356 -0
  68. package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/cloudflare.d.ts +53 -0
  69. package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/cloudflare.d.ts.map +1 -0
  70. package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/cloudflare.js +64 -0
  71. package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/cloudflare.js.map +1 -0
  72. package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/declarations.d.ts +43 -0
  73. package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/declarations.d.ts.map +1 -0
  74. package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/declarations.js +320 -0
  75. package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/declarations.js.map +1 -0
  76. package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/identifier.d.ts +6 -0
  77. package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/identifier.d.ts.map +1 -0
  78. package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/identifier.js +13 -0
  79. package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/identifier.js.map +1 -0
  80. package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/index.d.ts +11 -0
  81. package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/index.d.ts.map +1 -0
  82. package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/index.js +10 -0
  83. package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/index.js.map +1 -0
  84. package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/portable.d.ts +15 -0
  85. package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/portable.d.ts.map +1 -0
  86. package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/portable.js +12 -0
  87. package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/portable.js.map +1 -0
  88. package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/runtime/execution.d.ts +66 -0
  89. package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/runtime/execution.d.ts.map +1 -0
  90. package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/runtime/execution.js +494 -0
  91. package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/runtime/execution.js.map +1 -0
  92. package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/runtime/host.d.ts +13 -0
  93. package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/runtime/host.d.ts.map +1 -0
  94. package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/runtime/host.js +72 -0
  95. package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/runtime/host.js.map +1 -0
  96. package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/runtime/inline.d.ts +63 -0
  97. package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/runtime/inline.d.ts.map +1 -0
  98. package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/runtime/inline.js +80 -0
  99. package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/runtime/inline.js.map +1 -0
  100. package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/runtime/prelude-source.d.ts +45 -0
  101. package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/runtime/prelude-source.d.ts.map +1 -0
  102. package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/runtime/prelude-source.js +520 -0
  103. package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/runtime/prelude-source.js.map +1 -0
  104. package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/runtime/protocol.d.ts +110 -0
  105. package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/runtime/protocol.d.ts.map +1 -0
  106. package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/runtime/protocol.js +15 -0
  107. package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/runtime/protocol.js.map +1 -0
  108. package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/runtime/remote.d.ts +102 -0
  109. package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/runtime/remote.d.ts.map +1 -0
  110. package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/runtime/remote.js +175 -0
  111. package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/runtime/remote.js.map +1 -0
  112. package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/runtime/vm.d.ts +24 -0
  113. package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/runtime/vm.d.ts.map +1 -0
  114. package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/runtime/vm.js +293 -0
  115. package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/runtime/vm.js.map +1 -0
  116. package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/runtime/worker.d.ts +2 -0
  117. package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/runtime/worker.d.ts.map +1 -0
  118. package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/runtime/worker.js +38 -0
  119. package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/runtime/worker.js.map +1 -0
  120. package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/source.d.ts +36 -0
  121. package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/source.d.ts.map +1 -0
  122. package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/source.js +98 -0
  123. package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/source.js.map +1 -0
  124. package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/types.d.ts +232 -0
  125. package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/types.d.ts.map +1 -0
  126. package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/types.js +2 -0
  127. package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/types.js.map +1 -0
  128. package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/wasm.d.ts +12 -0
  129. package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/wasm.d.ts.map +1 -0
  130. package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/wasm.js +24 -0
  131. package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/wasm.js.map +1 -0
  132. package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/package.json +76 -0
  133. package/node_modules/body-parser/README.md +17 -13
  134. package/node_modules/body-parser/lib/read.js +74 -57
  135. package/node_modules/body-parser/lib/types/json.js +11 -11
  136. package/node_modules/body-parser/lib/types/urlencoded.js +5 -5
  137. package/node_modules/body-parser/lib/utils.js +0 -15
  138. package/node_modules/body-parser/package.json +7 -12
  139. package/node_modules/fast-uri/.github/workflows/release.yml +35 -0
  140. package/node_modules/fast-uri/README.md +8 -0
  141. package/node_modules/fast-uri/index.js +98 -18
  142. package/node_modules/fast-uri/lib/utils.js +52 -0
  143. package/node_modules/fast-uri/package.json +1 -1
  144. package/node_modules/fast-uri/test/host-delimiter-security.test.js +94 -0
  145. package/node_modules/fast-uri/test/relative-normalization-security.test.js +156 -0
  146. package/node_modules/fast-uri/test/reserved-path-normalization.test.js +32 -4
  147. package/node_modules/fast-uri/test/scheme-validation.test.js +53 -14
  148. package/node_modules/ip-address/README.md +104 -104
  149. package/node_modules/ip-address/dist/common.js +2 -2
  150. package/node_modules/ip-address/dist/common.js.map +1 -1
  151. package/node_modules/ip-address/dist/ipv4.js +7 -0
  152. package/node_modules/ip-address/dist/ipv4.js.map +1 -1
  153. package/node_modules/ip-address/dist/ipv6.js +7 -4
  154. package/node_modules/ip-address/dist/ipv6.js.map +1 -1
  155. package/node_modules/ip-address/dist/v6/constants.d.ts +3 -0
  156. package/node_modules/ip-address/dist/v6/constants.js +3 -0
  157. package/node_modules/ip-address/dist/v6/constants.js.map +1 -1
  158. package/node_modules/ip-address/package.json +3 -2
  159. package/node_modules/qs/.editorconfig +1 -1
  160. package/node_modules/qs/.github/THREAT_MODEL.md +4 -2
  161. package/node_modules/qs/CHANGELOG.md +61 -14
  162. package/node_modules/qs/README.md +57 -4
  163. package/node_modules/qs/dist/qs.js +19 -19
  164. package/node_modules/qs/eslint.config.mjs +61 -50
  165. package/node_modules/qs/lib/formats.js +7 -2
  166. package/node_modules/qs/lib/parse.js +105 -8
  167. package/node_modules/qs/lib/stringify.js +9 -7
  168. package/node_modules/qs/lib/utils.js +145 -13
  169. package/node_modules/qs/package.json +8 -8
  170. package/node_modules/qs/test/parse.js +440 -2
  171. package/node_modules/qs/test/stringify.js +485 -33
  172. package/node_modules/qs/test/utils.js +245 -3
  173. package/node_modules/zod/README.md +29 -2
  174. package/node_modules/zod/compile.cjs +96 -0
  175. package/node_modules/zod/compile.d.cts +1 -0
  176. package/node_modules/zod/compile.d.ts +1 -0
  177. package/node_modules/zod/compile.js +52 -0
  178. package/node_modules/zod/index.cjs +21 -2
  179. package/node_modules/zod/index.d.cts +1 -2
  180. package/node_modules/zod/index.d.ts +1 -2
  181. package/node_modules/zod/index.js +5 -2
  182. package/node_modules/zod/locales/index.cjs +19 -0
  183. package/node_modules/zod/mini/index.cjs +19 -0
  184. package/node_modules/zod/package.json +20 -8
  185. package/node_modules/zod/src/compile.ts +56 -0
  186. package/node_modules/zod/src/index.ts +5 -2
  187. package/node_modules/zod/src/v3/ZodError.ts +22 -12
  188. package/node_modules/zod/src/v3/helpers/errorUtil.ts +1 -1
  189. package/node_modules/zod/src/v3/tests/error.test.ts +35 -0
  190. package/node_modules/zod/src/v3/tests/intersection.test.ts +18 -0
  191. package/node_modules/zod/src/v3/tests/language-server.test.ts +1 -2
  192. package/node_modules/zod/src/v3/tests/object.test.ts +3 -6
  193. package/node_modules/zod/src/v3/tests/readonly.test.ts +0 -80
  194. package/node_modules/zod/src/v3/tests/string.test.ts +6 -0
  195. package/node_modules/zod/src/v3/types.ts +5 -5
  196. package/node_modules/zod/src/v4/classic/checks.ts +1 -0
  197. package/node_modules/zod/src/v4/classic/compat.ts +26 -18
  198. package/node_modules/zod/src/v4/classic/deep-partial.ts +76 -0
  199. package/node_modules/zod/src/v4/classic/errors.ts +59 -44
  200. package/node_modules/zod/src/v4/classic/external.ts +14 -9
  201. package/node_modules/zod/src/v4/classic/from-json-schema.ts +363 -78
  202. package/node_modules/zod/src/v4/classic/in-out.ts +45 -0
  203. package/node_modules/zod/src/v4/classic/index.ts +2 -2
  204. package/node_modules/zod/src/v4/classic/iso.ts +2 -72
  205. package/node_modules/zod/src/v4/classic/parse.ts +10 -4
  206. package/node_modules/zod/src/v4/classic/schemas.ts +640 -375
  207. package/node_modules/zod/src/v4/classic/tests/apply.test.ts +27 -0
  208. package/node_modules/zod/src/v4/classic/tests/array.test.ts +29 -2
  209. package/node_modules/zod/src/v4/classic/tests/assignability.test.ts +186 -0
  210. package/node_modules/zod/src/v4/classic/tests/bigint.test.ts +36 -1
  211. package/node_modules/zod/src/v4/classic/tests/catch.test.ts +278 -0
  212. package/node_modules/zod/src/v4/classic/tests/codec-examples.test.ts +1 -2
  213. package/node_modules/zod/src/v4/classic/tests/codec.test.ts +2 -1
  214. package/node_modules/zod/src/v4/classic/tests/continuability.test.ts +3 -3
  215. package/node_modules/zod/src/v4/classic/tests/credit-card.test.ts +76 -0
  216. package/node_modules/zod/src/v4/classic/tests/cyclic-data.test.ts +985 -0
  217. package/node_modules/zod/src/v4/classic/tests/date.test.ts +30 -0
  218. package/node_modules/zod/src/v4/classic/tests/datetime.test.ts +32 -18
  219. package/node_modules/zod/src/v4/classic/tests/deep-partial.test.ts +380 -0
  220. package/node_modules/zod/src/v4/classic/tests/default-locale.test.ts +32 -0
  221. package/node_modules/zod/src/v4/classic/tests/default.test.ts +46 -0
  222. package/node_modules/zod/src/v4/classic/tests/detached-methods.test.ts +31 -7
  223. package/node_modules/zod/src/v4/classic/tests/discriminated-unions.test.ts +261 -13
  224. package/node_modules/zod/src/v4/classic/tests/enum.test.ts +20 -0
  225. package/node_modules/zod/src/v4/classic/tests/error-utils.test.ts +112 -2
  226. package/node_modules/zod/src/v4/classic/tests/error.test.ts +403 -6
  227. package/node_modules/zod/src/v4/classic/tests/from-json-schema.test.ts +582 -10
  228. package/node_modules/zod/src/v4/classic/tests/function.test.ts +31 -0
  229. package/node_modules/zod/src/v4/classic/tests/global-config.test.ts +2 -9
  230. package/node_modules/zod/src/v4/classic/tests/hash.test.ts +1 -2
  231. package/node_modules/zod/src/v4/classic/tests/iban.test.ts +81 -0
  232. package/node_modules/zod/src/v4/classic/tests/in-out.test.ts +159 -0
  233. package/node_modules/zod/src/v4/classic/tests/index.test.ts +21 -2
  234. package/node_modules/zod/src/v4/classic/tests/instance-footprint.test.ts +319 -0
  235. package/node_modules/zod/src/v4/classic/tests/instanceof.test.ts +67 -0
  236. package/node_modules/zod/src/v4/classic/tests/intersection.test.ts +136 -0
  237. package/node_modules/zod/src/v4/classic/tests/issue-schema.test.ts +215 -0
  238. package/node_modules/zod/src/v4/classic/tests/jitless-allows-eval.test.ts +3 -10
  239. package/node_modules/zod/src/v4/classic/tests/lazy.test.ts +36 -1
  240. package/node_modules/zod/src/v4/classic/tests/literal.test.ts +12 -1
  241. package/node_modules/zod/src/v4/classic/tests/map.test.ts +19 -0
  242. package/node_modules/zod/src/v4/classic/tests/number.test.ts +85 -9
  243. package/node_modules/zod/src/v4/classic/tests/object.test.ts +301 -12
  244. package/node_modules/zod/src/v4/classic/tests/optin-ladder.test.ts +235 -0
  245. package/node_modules/zod/src/v4/classic/tests/optional.test.ts +49 -16
  246. package/node_modules/zod/src/v4/classic/tests/partial.test.ts +51 -4
  247. package/node_modules/zod/src/v4/classic/tests/prefault.test.ts +70 -0
  248. package/node_modules/zod/src/v4/classic/tests/preprocess-types.test.ts +20 -2
  249. package/node_modules/zod/src/v4/classic/tests/properties.test.ts +141 -0
  250. package/node_modules/zod/src/v4/classic/tests/readonly.test.ts +0 -68
  251. package/node_modules/zod/src/v4/classic/tests/record.test.ts +186 -18
  252. package/node_modules/zod/src/v4/classic/tests/recursive-types.test.ts +79 -3
  253. package/node_modules/zod/src/v4/classic/tests/redos.test.ts +68 -0
  254. package/node_modules/zod/src/v4/classic/tests/refine.test.ts +60 -0
  255. package/node_modules/zod/src/v4/classic/tests/set.test.ts +15 -0
  256. package/node_modules/zod/src/v4/classic/tests/standard-schema.test.ts +19 -0
  257. package/node_modules/zod/src/v4/classic/tests/string.test.ts +222 -6
  258. package/node_modules/zod/src/v4/classic/tests/stringbool.test.ts +18 -0
  259. package/node_modules/zod/src/v4/classic/tests/template-literal.test.ts +44 -3
  260. package/node_modules/zod/src/v4/classic/tests/to-json-schema.test.ts +1812 -204
  261. package/node_modules/zod/src/v4/classic/tests/tuple.test.ts +45 -30
  262. package/node_modules/zod/src/v4/classic/tests/union.test.ts +39 -2
  263. package/node_modules/zod/src/v4/classic/tests/validate.test.ts +645 -0
  264. package/node_modules/zod/src/v4/classic/tests/validations.test.ts +2 -2
  265. package/node_modules/zod/src/v4/core/api.ts +87 -35
  266. package/node_modules/zod/src/v4/core/checks.ts +119 -146
  267. package/node_modules/zod/src/v4/core/compile.ts +2322 -0
  268. package/node_modules/zod/src/v4/core/core.ts +99 -22
  269. package/node_modules/zod/src/v4/core/doc.ts +17 -9
  270. package/node_modules/zod/src/v4/core/errors.ts +113 -25
  271. package/node_modules/zod/src/v4/core/index.ts +3 -0
  272. package/node_modules/zod/src/v4/core/json-schema-generator.ts +8 -3
  273. package/node_modules/zod/src/v4/core/json-schema-processors.ts +424 -156
  274. package/node_modules/zod/src/v4/core/json-schema.ts +2 -1
  275. package/node_modules/zod/src/v4/core/memoizer.ts +331 -0
  276. package/node_modules/zod/src/v4/core/parse.ts +164 -50
  277. package/node_modules/zod/src/v4/core/regexes.ts +42 -15
  278. package/node_modules/zod/src/v4/core/registries.ts +2 -2
  279. package/node_modules/zod/src/v4/core/schemas.ts +1035 -539
  280. package/node_modules/zod/src/v4/core/tests/cached.test.ts +54 -0
  281. package/node_modules/zod/src/v4/core/tests/compile-differential.test.ts +1004 -0
  282. package/node_modules/zod/src/v4/core/tests/compile-generative.test.ts +445 -0
  283. package/node_modules/zod/src/v4/core/tests/compile-global.test.ts +89 -0
  284. package/node_modules/zod/src/v4/core/tests/compile-off-by-default.test.ts +26 -0
  285. package/node_modules/zod/src/v4/core/tests/compile-stats.test.ts +34 -0
  286. package/node_modules/zod/src/v4/core/tests/compile.test.ts +2036 -0
  287. package/node_modules/zod/src/v4/core/tests/email-regex.test.ts +140 -0
  288. package/node_modules/zod/src/v4/core/tests/locales/el.test.ts +1 -2
  289. package/node_modules/zod/src/v4/core/tests/locales/es.test.ts +1 -2
  290. package/node_modules/zod/src/v4/core/tests/locales/fr.test.ts +3 -3
  291. package/node_modules/zod/src/v4/core/tests/locales/parity.test.ts +42 -0
  292. package/node_modules/zod/src/v4/core/tests/locales/tg.test.ts +85 -0
  293. package/node_modules/zod/src/v4/core/tests/locales/tk.test.ts +69 -0
  294. package/node_modules/zod/src/v4/core/tests/polyfill-collision.test.ts +46 -0
  295. package/node_modules/zod/src/v4/core/tests/treeshake.test.ts +51 -0
  296. package/node_modules/zod/src/v4/core/tests/url-no-canparse.test.ts +133 -0
  297. package/node_modules/zod/src/v4/core/to-json-schema.ts +283 -48
  298. package/node_modules/zod/src/v4/core/util.ts +467 -157
  299. package/node_modules/zod/src/v4/core/versions.ts +2 -2
  300. package/node_modules/zod/src/v4/core/visit.ts +193 -0
  301. package/node_modules/zod/src/v4/index.ts +3 -3
  302. package/node_modules/zod/src/v4/locales/ar.ts +5 -0
  303. package/node_modules/zod/src/v4/locales/az.ts +5 -0
  304. package/node_modules/zod/src/v4/locales/be.ts +12 -0
  305. package/node_modules/zod/src/v4/locales/bg.ts +5 -0
  306. package/node_modules/zod/src/v4/locales/bn.ts +123 -0
  307. package/node_modules/zod/src/v4/locales/ca.ts +5 -0
  308. package/node_modules/zod/src/v4/locales/ckb.ts +140 -0
  309. package/node_modules/zod/src/v4/locales/cs.ts +5 -0
  310. package/node_modules/zod/src/v4/locales/da.ts +7 -2
  311. package/node_modules/zod/src/v4/locales/de.ts +5 -0
  312. package/node_modules/zod/src/v4/locales/el.ts +3 -0
  313. package/node_modules/zod/src/v4/locales/en.ts +17 -4
  314. package/node_modules/zod/src/v4/locales/eo.ts +5 -0
  315. package/node_modules/zod/src/v4/locales/es.ts +4 -0
  316. package/node_modules/zod/src/v4/locales/fa.ts +5 -0
  317. package/node_modules/zod/src/v4/locales/fi.ts +5 -0
  318. package/node_modules/zod/src/v4/locales/fr-CA.ts +5 -0
  319. package/node_modules/zod/src/v4/locales/fr.ts +21 -14
  320. package/node_modules/zod/src/v4/locales/gu.ts +123 -0
  321. package/node_modules/zod/src/v4/locales/he.ts +8 -1
  322. package/node_modules/zod/src/v4/locales/hi.ts +126 -0
  323. package/node_modules/zod/src/v4/locales/hr.ts +4 -0
  324. package/node_modules/zod/src/v4/locales/hu.ts +5 -0
  325. package/node_modules/zod/src/v4/locales/hy.ts +11 -0
  326. package/node_modules/zod/src/v4/locales/id.ts +5 -0
  327. package/node_modules/zod/src/v4/locales/index.ts +11 -0
  328. package/node_modules/zod/src/v4/locales/is.ts +5 -0
  329. package/node_modules/zod/src/v4/locales/it.ts +5 -0
  330. package/node_modules/zod/src/v4/locales/ja.ts +5 -0
  331. package/node_modules/zod/src/v4/locales/ka.ts +5 -0
  332. package/node_modules/zod/src/v4/locales/km.ts +5 -0
  333. package/node_modules/zod/src/v4/locales/kn.ts +126 -0
  334. package/node_modules/zod/src/v4/locales/ko.ts +5 -0
  335. package/node_modules/zod/src/v4/locales/lt.ts +4 -0
  336. package/node_modules/zod/src/v4/locales/mk.ts +5 -0
  337. package/node_modules/zod/src/v4/locales/ms.ts +5 -0
  338. package/node_modules/zod/src/v4/locales/ne.ts +128 -0
  339. package/node_modules/zod/src/v4/locales/nl.ts +5 -0
  340. package/node_modules/zod/src/v4/locales/nn.ts +121 -0
  341. package/node_modules/zod/src/v4/locales/no.ts +7 -2
  342. package/node_modules/zod/src/v4/locales/ota.ts +5 -0
  343. package/node_modules/zod/src/v4/locales/pl.ts +5 -0
  344. package/node_modules/zod/src/v4/locales/ps.ts +5 -0
  345. package/node_modules/zod/src/v4/locales/pt-BR.ts +161 -0
  346. package/node_modules/zod/src/v4/locales/pt.ts +101 -58
  347. package/node_modules/zod/src/v4/locales/ro.ts +3 -0
  348. package/node_modules/zod/src/v4/locales/ru.ts +12 -0
  349. package/node_modules/zod/src/v4/locales/sk.ts +123 -0
  350. package/node_modules/zod/src/v4/locales/sl.ts +5 -0
  351. package/node_modules/zod/src/v4/locales/sv.ts +7 -2
  352. package/node_modules/zod/src/v4/locales/ta.ts +5 -0
  353. package/node_modules/zod/src/v4/locales/tg.ts +135 -0
  354. package/node_modules/zod/src/v4/locales/th.ts +5 -0
  355. package/node_modules/zod/src/v4/locales/tk.ts +113 -0
  356. package/node_modules/zod/src/v4/locales/tr.ts +5 -0
  357. package/node_modules/zod/src/v4/locales/uk.ts +5 -0
  358. package/node_modules/zod/src/v4/locales/ur.ts +5 -0
  359. package/node_modules/zod/src/v4/locales/uz.ts +3 -0
  360. package/node_modules/zod/src/v4/locales/vi.ts +5 -0
  361. package/node_modules/zod/src/v4/locales/yo.ts +5 -0
  362. package/node_modules/zod/src/v4/locales/zh-CN.ts +5 -0
  363. package/node_modules/zod/src/v4/locales/zh-TW.ts +5 -0
  364. package/node_modules/zod/src/v4/mini/checks.ts +1 -0
  365. package/node_modules/zod/src/v4/mini/deep-partial.ts +73 -0
  366. package/node_modules/zod/src/v4/mini/external.ts +12 -1
  367. package/node_modules/zod/src/v4/mini/in-out.ts +45 -0
  368. package/node_modules/zod/src/v4/mini/parse.ts +2 -0
  369. package/node_modules/zod/src/v4/mini/schemas.ts +167 -63
  370. package/node_modules/zod/src/v4/mini/tests/apply.test.ts +33 -0
  371. package/node_modules/zod/src/v4/mini/tests/assignability.test.ts +62 -1
  372. package/node_modules/zod/src/v4/mini/tests/checks.test.ts +14 -0
  373. package/node_modules/zod/src/v4/mini/tests/codec.test.ts +35 -1
  374. package/node_modules/zod/src/v4/mini/tests/computed.test.ts +11 -17
  375. package/node_modules/zod/src/v4/mini/tests/cyclic-data.test.ts +84 -0
  376. package/node_modules/zod/src/v4/mini/tests/deep-partial.test.ts +54 -0
  377. package/node_modules/zod/src/v4/mini/tests/error.test.ts +23 -4
  378. package/node_modules/zod/src/v4/mini/tests/functions.test.ts +9 -0
  379. package/node_modules/zod/src/v4/mini/tests/index.test.ts +158 -5
  380. package/node_modules/zod/src/v4/mini/tests/number.test.ts +14 -0
  381. package/node_modules/zod/src/v4/mini/tests/object.test.ts +65 -0
  382. package/node_modules/zod/src/v4/mini/tests/recursive-types.test.ts +16 -0
  383. package/node_modules/zod/src/v4/mini/tests/string.test.ts +44 -0
  384. package/node_modules/zod/v3/ZodError.cjs +41 -12
  385. package/node_modules/zod/v3/ZodError.d.cts +1 -1
  386. package/node_modules/zod/v3/ZodError.d.ts +1 -1
  387. package/node_modules/zod/v3/ZodError.js +22 -12
  388. package/node_modules/zod/v3/errors.cjs +19 -0
  389. package/node_modules/zod/v3/external.cjs +19 -0
  390. package/node_modules/zod/v3/helpers/enumUtil.cjs +19 -0
  391. package/node_modules/zod/v3/helpers/errorUtil.cjs +20 -1
  392. package/node_modules/zod/v3/helpers/errorUtil.js +1 -1
  393. package/node_modules/zod/v3/helpers/parseUtil.cjs +19 -0
  394. package/node_modules/zod/v3/helpers/partialUtil.cjs +19 -0
  395. package/node_modules/zod/v3/helpers/typeAliases.cjs +19 -0
  396. package/node_modules/zod/v3/helpers/util.cjs +19 -0
  397. package/node_modules/zod/v3/index.cjs +19 -0
  398. package/node_modules/zod/v3/standard-schema.cjs +19 -0
  399. package/node_modules/zod/v3/types.cjs +26 -5
  400. package/node_modules/zod/v3/types.js +7 -5
  401. package/node_modules/zod/v4/classic/checks.cjs +21 -1
  402. package/node_modules/zod/v4/classic/checks.d.cts +1 -1
  403. package/node_modules/zod/v4/classic/checks.d.ts +1 -1
  404. package/node_modules/zod/v4/classic/checks.js +1 -1
  405. package/node_modules/zod/v4/classic/coerce.cjs +19 -0
  406. package/node_modules/zod/v4/classic/compat.cjs +19 -0
  407. package/node_modules/zod/v4/classic/compat.d.cts +9 -11
  408. package/node_modules/zod/v4/classic/compat.d.ts +9 -11
  409. package/node_modules/zod/v4/classic/deep-partial.cjs +58 -0
  410. package/node_modules/zod/v4/classic/deep-partial.d.cts +14 -0
  411. package/node_modules/zod/v4/classic/deep-partial.d.ts +14 -0
  412. package/node_modules/zod/v4/classic/deep-partial.js +13 -0
  413. package/node_modules/zod/v4/classic/errors.cjs +62 -34
  414. package/node_modules/zod/v4/classic/errors.d.cts +3 -4
  415. package/node_modules/zod/v4/classic/errors.d.ts +3 -4
  416. package/node_modules/zod/v4/classic/errors.js +43 -34
  417. package/node_modules/zod/v4/classic/external.cjs +51 -27
  418. package/node_modules/zod/v4/classic/external.d.cts +5 -2
  419. package/node_modules/zod/v4/classic/external.d.ts +5 -2
  420. package/node_modules/zod/v4/classic/external.js +5 -8
  421. package/node_modules/zod/v4/classic/from-json-schema.cjs +376 -75
  422. package/node_modules/zod/v4/classic/from-json-schema.js +357 -75
  423. package/node_modules/zod/v4/classic/in-out.cjs +82 -0
  424. package/node_modules/zod/v4/classic/in-out.d.cts +8 -0
  425. package/node_modules/zod/v4/classic/in-out.d.ts +8 -0
  426. package/node_modules/zod/v4/classic/in-out.js +36 -0
  427. package/node_modules/zod/v4/classic/index.cjs +21 -2
  428. package/node_modules/zod/v4/classic/index.d.cts +1 -2
  429. package/node_modules/zod/v4/classic/index.d.ts +1 -2
  430. package/node_modules/zod/v4/classic/index.js +2 -2
  431. package/node_modules/zod/v4/classic/iso.cjs +30 -22
  432. package/node_modules/zod/v4/classic/iso.d.cts +2 -17
  433. package/node_modules/zod/v4/classic/iso.d.ts +2 -17
  434. package/node_modules/zod/v4/classic/iso.js +2 -17
  435. package/node_modules/zod/v4/classic/parse.cjs +23 -1
  436. package/node_modules/zod/v4/classic/parse.d.cts +17 -4
  437. package/node_modules/zod/v4/classic/parse.d.ts +17 -4
  438. package/node_modules/zod/v4/classic/parse.js +1 -0
  439. package/node_modules/zod/v4/classic/schemas.cjs +591 -426
  440. package/node_modules/zod/v4/classic/schemas.d.cts +68 -19
  441. package/node_modules/zod/v4/classic/schemas.d.ts +68 -19
  442. package/node_modules/zod/v4/classic/schemas.js +564 -424
  443. package/node_modules/zod/v4/core/api.cjs +66 -24
  444. package/node_modules/zod/v4/core/api.d.cts +22 -12
  445. package/node_modules/zod/v4/core/api.d.ts +22 -12
  446. package/node_modules/zod/v4/core/api.js +44 -24
  447. package/node_modules/zod/v4/core/checks.cjs +88 -128
  448. package/node_modules/zod/v4/core/checks.d.cts +29 -13
  449. package/node_modules/zod/v4/core/checks.d.ts +29 -13
  450. package/node_modules/zod/v4/core/checks.js +68 -127
  451. package/node_modules/zod/v4/core/compile.cjs +1916 -0
  452. package/node_modules/zod/v4/core/compile.d.cts +65 -0
  453. package/node_modules/zod/v4/core/compile.d.ts +65 -0
  454. package/node_modules/zod/v4/core/compile.js +1866 -0
  455. package/node_modules/zod/v4/core/core.cjs +101 -19
  456. package/node_modules/zod/v4/core/core.d.cts +16 -4
  457. package/node_modules/zod/v4/core/core.d.ts +16 -4
  458. package/node_modules/zod/v4/core/core.js +83 -20
  459. package/node_modules/zod/v4/core/doc.cjs +31 -9
  460. package/node_modules/zod/v4/core/doc.d.cts +3 -1
  461. package/node_modules/zod/v4/core/doc.d.ts +3 -1
  462. package/node_modules/zod/v4/core/doc.js +12 -9
  463. package/node_modules/zod/v4/core/errors.cjs +126 -25
  464. package/node_modules/zod/v4/core/errors.d.cts +4 -0
  465. package/node_modules/zod/v4/core/errors.d.ts +4 -0
  466. package/node_modules/zod/v4/core/errors.js +107 -25
  467. package/node_modules/zod/v4/core/index.cjs +24 -1
  468. package/node_modules/zod/v4/core/index.d.cts +3 -0
  469. package/node_modules/zod/v4/core/index.d.ts +3 -0
  470. package/node_modules/zod/v4/core/index.js +3 -0
  471. package/node_modules/zod/v4/core/json-schema-generator.cjs +24 -1
  472. package/node_modules/zod/v4/core/json-schema-generator.d.cts +2 -2
  473. package/node_modules/zod/v4/core/json-schema-generator.d.ts +2 -2
  474. package/node_modules/zod/v4/core/json-schema-generator.js +6 -2
  475. package/node_modules/zod/v4/core/json-schema-processors.cjs +441 -156
  476. package/node_modules/zod/v4/core/json-schema-processors.d.cts +16 -0
  477. package/node_modules/zod/v4/core/json-schema-processors.d.ts +16 -0
  478. package/node_modules/zod/v4/core/json-schema-processors.js +400 -158
  479. package/node_modules/zod/v4/core/json-schema.cjs +19 -0
  480. package/node_modules/zod/v4/core/json-schema.d.cts +2 -1
  481. package/node_modules/zod/v4/core/json-schema.d.ts +2 -1
  482. package/node_modules/zod/v4/core/memoizer.cjs +360 -0
  483. package/node_modules/zod/v4/core/memoizer.d.cts +15 -0
  484. package/node_modules/zod/v4/core/memoizer.d.ts +15 -0
  485. package/node_modules/zod/v4/core/memoizer.js +311 -0
  486. package/node_modules/zod/v4/core/parse.cjs +148 -46
  487. package/node_modules/zod/v4/core/parse.d.cts +14 -11
  488. package/node_modules/zod/v4/core/parse.d.ts +14 -11
  489. package/node_modules/zod/v4/core/parse.js +127 -45
  490. package/node_modules/zod/v4/core/regexes.cjs +54 -17
  491. package/node_modules/zod/v4/core/regexes.d.cts +5 -0
  492. package/node_modules/zod/v4/core/regexes.d.ts +5 -0
  493. package/node_modules/zod/v4/core/regexes.js +32 -15
  494. package/node_modules/zod/v4/core/registries.cjs +19 -0
  495. package/node_modules/zod/v4/core/registries.js +2 -2
  496. package/node_modules/zod/v4/core/schemas.cjs +815 -386
  497. package/node_modules/zod/v4/core/schemas.d.cts +126 -35
  498. package/node_modules/zod/v4/core/schemas.d.ts +126 -35
  499. package/node_modules/zod/v4/core/schemas.js +783 -386
  500. package/node_modules/zod/v4/core/standard-schema.cjs +19 -0
  501. package/node_modules/zod/v4/core/to-json-schema.cjs +269 -45
  502. package/node_modules/zod/v4/core/to-json-schema.d.cts +45 -5
  503. package/node_modules/zod/v4/core/to-json-schema.d.ts +45 -5
  504. package/node_modules/zod/v4/core/to-json-schema.js +247 -44
  505. package/node_modules/zod/v4/core/util.cjs +387 -157
  506. package/node_modules/zod/v4/core/util.d.cts +81 -1
  507. package/node_modules/zod/v4/core/util.d.ts +81 -1
  508. package/node_modules/zod/v4/core/util.js +355 -156
  509. package/node_modules/zod/v4/core/versions.cjs +21 -2
  510. package/node_modules/zod/v4/core/versions.d.cts +1 -1
  511. package/node_modules/zod/v4/core/versions.d.ts +1 -1
  512. package/node_modules/zod/v4/core/versions.js +2 -2
  513. package/node_modules/zod/v4/core/visit.cjs +214 -0
  514. package/node_modules/zod/v4/core/visit.d.cts +30 -0
  515. package/node_modules/zod/v4/core/visit.d.ts +30 -0
  516. package/node_modules/zod/v4/core/visit.js +169 -0
  517. package/node_modules/zod/v4/index.cjs +34 -5
  518. package/node_modules/zod/v4/index.d.cts +2 -2
  519. package/node_modules/zod/v4/index.d.ts +2 -2
  520. package/node_modules/zod/v4/index.js +3 -2
  521. package/node_modules/zod/v4/locales/ar.cjs +5 -0
  522. package/node_modules/zod/v4/locales/ar.js +5 -0
  523. package/node_modules/zod/v4/locales/az.cjs +5 -0
  524. package/node_modules/zod/v4/locales/az.js +5 -0
  525. package/node_modules/zod/v4/locales/be.cjs +12 -0
  526. package/node_modules/zod/v4/locales/be.js +12 -0
  527. package/node_modules/zod/v4/locales/bg.cjs +5 -0
  528. package/node_modules/zod/v4/locales/bg.js +5 -0
  529. package/node_modules/zod/v4/locales/bn.cjs +140 -0
  530. package/node_modules/zod/v4/locales/bn.d.cts +5 -0
  531. package/node_modules/zod/v4/locales/bn.d.ts +4 -0
  532. package/node_modules/zod/v4/locales/bn.js +113 -0
  533. package/node_modules/zod/v4/locales/ca.cjs +5 -0
  534. package/node_modules/zod/v4/locales/ca.js +5 -0
  535. package/node_modules/zod/v4/locales/ckb.cjs +160 -0
  536. package/node_modules/zod/v4/locales/ckb.d.cts +5 -0
  537. package/node_modules/zod/v4/locales/ckb.d.ts +4 -0
  538. package/node_modules/zod/v4/locales/ckb.js +133 -0
  539. package/node_modules/zod/v4/locales/cs.cjs +5 -0
  540. package/node_modules/zod/v4/locales/cs.js +5 -0
  541. package/node_modules/zod/v4/locales/da.cjs +7 -2
  542. package/node_modules/zod/v4/locales/da.js +7 -2
  543. package/node_modules/zod/v4/locales/de.cjs +5 -0
  544. package/node_modules/zod/v4/locales/de.js +5 -0
  545. package/node_modules/zod/v4/locales/el.cjs +3 -0
  546. package/node_modules/zod/v4/locales/el.js +3 -0
  547. package/node_modules/zod/v4/locales/en.cjs +16 -4
  548. package/node_modules/zod/v4/locales/en.js +16 -4
  549. package/node_modules/zod/v4/locales/eo.cjs +5 -0
  550. package/node_modules/zod/v4/locales/eo.js +5 -0
  551. package/node_modules/zod/v4/locales/es.cjs +4 -0
  552. package/node_modules/zod/v4/locales/es.js +4 -0
  553. package/node_modules/zod/v4/locales/fa.cjs +5 -0
  554. package/node_modules/zod/v4/locales/fa.js +5 -0
  555. package/node_modules/zod/v4/locales/fi.cjs +5 -0
  556. package/node_modules/zod/v4/locales/fi.js +5 -0
  557. package/node_modules/zod/v4/locales/fr-CA.cjs +5 -0
  558. package/node_modules/zod/v4/locales/fr-CA.js +5 -0
  559. package/node_modules/zod/v4/locales/fr.cjs +18 -14
  560. package/node_modules/zod/v4/locales/fr.js +18 -14
  561. package/node_modules/zod/v4/locales/gu.cjs +140 -0
  562. package/node_modules/zod/v4/locales/gu.d.cts +5 -0
  563. package/node_modules/zod/v4/locales/gu.d.ts +4 -0
  564. package/node_modules/zod/v4/locales/gu.js +113 -0
  565. package/node_modules/zod/v4/locales/he.cjs +7 -0
  566. package/node_modules/zod/v4/locales/he.js +7 -0
  567. package/node_modules/zod/v4/locales/hi.cjs +138 -0
  568. package/node_modules/zod/v4/locales/hi.d.cts +5 -0
  569. package/node_modules/zod/v4/locales/hi.d.ts +4 -0
  570. package/node_modules/zod/v4/locales/hi.js +111 -0
  571. package/node_modules/zod/v4/locales/hr.cjs +4 -0
  572. package/node_modules/zod/v4/locales/hr.js +4 -0
  573. package/node_modules/zod/v4/locales/hu.cjs +5 -0
  574. package/node_modules/zod/v4/locales/hu.js +5 -0
  575. package/node_modules/zod/v4/locales/hy.cjs +11 -0
  576. package/node_modules/zod/v4/locales/hy.js +11 -0
  577. package/node_modules/zod/v4/locales/id.cjs +5 -0
  578. package/node_modules/zod/v4/locales/id.js +5 -0
  579. package/node_modules/zod/v4/locales/index.cjs +43 -2
  580. package/node_modules/zod/v4/locales/index.d.cts +11 -0
  581. package/node_modules/zod/v4/locales/index.d.ts +11 -0
  582. package/node_modules/zod/v4/locales/index.js +11 -0
  583. package/node_modules/zod/v4/locales/is.cjs +5 -0
  584. package/node_modules/zod/v4/locales/is.js +5 -0
  585. package/node_modules/zod/v4/locales/it.cjs +5 -0
  586. package/node_modules/zod/v4/locales/it.js +5 -0
  587. package/node_modules/zod/v4/locales/ja.cjs +5 -0
  588. package/node_modules/zod/v4/locales/ja.js +5 -0
  589. package/node_modules/zod/v4/locales/ka.cjs +5 -0
  590. package/node_modules/zod/v4/locales/ka.js +5 -0
  591. package/node_modules/zod/v4/locales/km.cjs +5 -0
  592. package/node_modules/zod/v4/locales/km.js +5 -0
  593. package/node_modules/zod/v4/locales/kn.cjs +143 -0
  594. package/node_modules/zod/v4/locales/kn.d.cts +5 -0
  595. package/node_modules/zod/v4/locales/kn.d.ts +4 -0
  596. package/node_modules/zod/v4/locales/kn.js +116 -0
  597. package/node_modules/zod/v4/locales/ko.cjs +5 -0
  598. package/node_modules/zod/v4/locales/ko.js +5 -0
  599. package/node_modules/zod/v4/locales/lt.cjs +4 -0
  600. package/node_modules/zod/v4/locales/lt.js +4 -0
  601. package/node_modules/zod/v4/locales/mk.cjs +5 -0
  602. package/node_modules/zod/v4/locales/mk.js +5 -0
  603. package/node_modules/zod/v4/locales/ms.cjs +5 -0
  604. package/node_modules/zod/v4/locales/ms.js +5 -0
  605. package/node_modules/zod/v4/locales/ne.cjs +138 -0
  606. package/node_modules/zod/v4/locales/ne.d.cts +5 -0
  607. package/node_modules/zod/v4/locales/ne.d.ts +4 -0
  608. package/node_modules/zod/v4/locales/ne.js +111 -0
  609. package/node_modules/zod/v4/locales/nl.cjs +5 -0
  610. package/node_modules/zod/v4/locales/nl.js +5 -0
  611. package/node_modules/zod/v4/locales/nn.cjs +140 -0
  612. package/node_modules/zod/v4/locales/nn.d.cts +5 -0
  613. package/node_modules/zod/v4/locales/nn.d.ts +4 -0
  614. package/node_modules/zod/v4/locales/nn.js +113 -0
  615. package/node_modules/zod/v4/locales/no.cjs +7 -2
  616. package/node_modules/zod/v4/locales/no.js +7 -2
  617. package/node_modules/zod/v4/locales/ota.cjs +5 -0
  618. package/node_modules/zod/v4/locales/ota.js +5 -0
  619. package/node_modules/zod/v4/locales/pl.cjs +5 -0
  620. package/node_modules/zod/v4/locales/pl.js +5 -0
  621. package/node_modules/zod/v4/locales/ps.cjs +5 -0
  622. package/node_modules/zod/v4/locales/ps.js +5 -0
  623. package/node_modules/zod/v4/locales/pt-BR.cjs +170 -0
  624. package/node_modules/zod/v4/locales/pt-BR.d.cts +5 -0
  625. package/node_modules/zod/v4/locales/pt-BR.d.ts +4 -0
  626. package/node_modules/zod/v4/locales/pt-BR.js +143 -0
  627. package/node_modules/zod/v4/locales/pt.cjs +89 -55
  628. package/node_modules/zod/v4/locales/pt.js +89 -55
  629. package/node_modules/zod/v4/locales/ro.cjs +3 -0
  630. package/node_modules/zod/v4/locales/ro.js +3 -0
  631. package/node_modules/zod/v4/locales/ru.cjs +12 -0
  632. package/node_modules/zod/v4/locales/ru.js +12 -0
  633. package/node_modules/zod/v4/locales/sk.cjs +143 -0
  634. package/node_modules/zod/v4/locales/sk.d.cts +5 -0
  635. package/node_modules/zod/v4/locales/sk.d.ts +4 -0
  636. package/node_modules/zod/v4/locales/sk.js +116 -0
  637. package/node_modules/zod/v4/locales/sl.cjs +5 -0
  638. package/node_modules/zod/v4/locales/sl.js +5 -0
  639. package/node_modules/zod/v4/locales/sv.cjs +7 -2
  640. package/node_modules/zod/v4/locales/sv.js +7 -2
  641. package/node_modules/zod/v4/locales/ta.cjs +5 -0
  642. package/node_modules/zod/v4/locales/ta.js +5 -0
  643. package/node_modules/zod/v4/locales/tg.cjs +144 -0
  644. package/node_modules/zod/v4/locales/tg.d.cts +5 -0
  645. package/node_modules/zod/v4/locales/tg.d.ts +4 -0
  646. package/node_modules/zod/v4/locales/tg.js +117 -0
  647. package/node_modules/zod/v4/locales/th.cjs +5 -0
  648. package/node_modules/zod/v4/locales/th.js +5 -0
  649. package/node_modules/zod/v4/locales/tk.cjs +134 -0
  650. package/node_modules/zod/v4/locales/tk.d.cts +5 -0
  651. package/node_modules/zod/v4/locales/tk.d.ts +4 -0
  652. package/node_modules/zod/v4/locales/tk.js +107 -0
  653. package/node_modules/zod/v4/locales/tr.cjs +5 -0
  654. package/node_modules/zod/v4/locales/tr.js +5 -0
  655. package/node_modules/zod/v4/locales/uk.cjs +5 -0
  656. package/node_modules/zod/v4/locales/uk.js +5 -0
  657. package/node_modules/zod/v4/locales/ur.cjs +5 -0
  658. package/node_modules/zod/v4/locales/ur.js +5 -0
  659. package/node_modules/zod/v4/locales/uz.cjs +3 -0
  660. package/node_modules/zod/v4/locales/uz.js +3 -0
  661. package/node_modules/zod/v4/locales/vi.cjs +5 -0
  662. package/node_modules/zod/v4/locales/vi.js +5 -0
  663. package/node_modules/zod/v4/locales/yo.cjs +5 -0
  664. package/node_modules/zod/v4/locales/yo.js +5 -0
  665. package/node_modules/zod/v4/locales/zh-CN.cjs +5 -0
  666. package/node_modules/zod/v4/locales/zh-CN.js +5 -0
  667. package/node_modules/zod/v4/locales/zh-TW.cjs +5 -0
  668. package/node_modules/zod/v4/locales/zh-TW.js +5 -0
  669. package/node_modules/zod/v4/mini/checks.cjs +21 -1
  670. package/node_modules/zod/v4/mini/checks.d.cts +1 -1
  671. package/node_modules/zod/v4/mini/checks.d.ts +1 -1
  672. package/node_modules/zod/v4/mini/checks.js +1 -1
  673. package/node_modules/zod/v4/mini/coerce.cjs +19 -0
  674. package/node_modules/zod/v4/mini/deep-partial.cjs +58 -0
  675. package/node_modules/zod/v4/mini/deep-partial.d.cts +14 -0
  676. package/node_modules/zod/v4/mini/deep-partial.d.ts +14 -0
  677. package/node_modules/zod/v4/mini/deep-partial.js +13 -0
  678. package/node_modules/zod/v4/mini/external.cjs +33 -1
  679. package/node_modules/zod/v4/mini/external.d.cts +5 -2
  680. package/node_modules/zod/v4/mini/external.d.ts +5 -2
  681. package/node_modules/zod/v4/mini/external.js +3 -1
  682. package/node_modules/zod/v4/mini/in-out.cjs +82 -0
  683. package/node_modules/zod/v4/mini/in-out.d.cts +8 -0
  684. package/node_modules/zod/v4/mini/in-out.d.ts +8 -0
  685. package/node_modules/zod/v4/mini/in-out.js +36 -0
  686. package/node_modules/zod/v4/mini/index.cjs +19 -0
  687. package/node_modules/zod/v4/mini/iso.cjs +19 -0
  688. package/node_modules/zod/v4/mini/parse.cjs +22 -1
  689. package/node_modules/zod/v4/mini/parse.d.cts +1 -1
  690. package/node_modules/zod/v4/mini/parse.d.ts +1 -1
  691. package/node_modules/zod/v4/mini/parse.js +1 -1
  692. package/node_modules/zod/v4/mini/schemas.cjs +117 -53
  693. package/node_modules/zod/v4/mini/schemas.d.cts +49 -14
  694. package/node_modules/zod/v4/mini/schemas.d.ts +49 -14
  695. package/node_modules/zod/v4/mini/schemas.js +92 -51
  696. package/node_modules/zod/v4-mini/index.cjs +19 -0
  697. package/package.json +7 -7
  698. package/runtime-package.json +13 -8
  699. package/shipping-sbom.cdx.json +159 -160
  700. package/shipping-source.json +12 -12
  701. package/node_modules/zod/src/v4/core/config.ts +0 -15
  702. /package/node_modules/@earendil-works/{pi-telemetry → pi-ai/node_modules/@earendil-works/pi-telemetry}/README.md +0 -0
  703. /package/node_modules/@earendil-works/{pi-telemetry → pi-ai/node_modules/@earendil-works/pi-telemetry}/dist/index.d.ts +0 -0
  704. /package/node_modules/@earendil-works/{pi-telemetry → pi-ai/node_modules/@earendil-works/pi-telemetry}/dist/index.d.ts.map +0 -0
  705. /package/node_modules/@earendil-works/{pi-telemetry → pi-ai/node_modules/@earendil-works/pi-telemetry}/dist/index.js +0 -0
  706. /package/node_modules/@earendil-works/{pi-telemetry → pi-ai/node_modules/@earendil-works/pi-telemetry}/dist/index.js.map +0 -0
  707. /package/node_modules/@earendil-works/{pi-telemetry → pi-ai/node_modules/@earendil-works/pi-telemetry}/dist/memory.d.ts +0 -0
  708. /package/node_modules/@earendil-works/{pi-telemetry → pi-ai/node_modules/@earendil-works/pi-telemetry}/dist/memory.d.ts.map +0 -0
  709. /package/node_modules/@earendil-works/{pi-telemetry → pi-ai/node_modules/@earendil-works/pi-telemetry}/dist/memory.js +0 -0
  710. /package/node_modules/@earendil-works/{pi-telemetry → pi-ai/node_modules/@earendil-works/pi-telemetry}/dist/memory.js.map +0 -0
  711. /package/node_modules/@earendil-works/{pi-telemetry → pi-ai/node_modules/@earendil-works/pi-telemetry}/dist/noop.d.ts +0 -0
  712. /package/node_modules/@earendil-works/{pi-telemetry → pi-ai/node_modules/@earendil-works/pi-telemetry}/dist/noop.d.ts.map +0 -0
  713. /package/node_modules/@earendil-works/{pi-telemetry → pi-ai/node_modules/@earendil-works/pi-telemetry}/dist/noop.js +0 -0
  714. /package/node_modules/@earendil-works/{pi-telemetry → pi-ai/node_modules/@earendil-works/pi-telemetry}/dist/noop.js.map +0 -0
  715. /package/node_modules/@earendil-works/{pi-telemetry → pi-ai/node_modules/@earendil-works/pi-telemetry}/dist/testing/conformance.d.ts +0 -0
  716. /package/node_modules/@earendil-works/{pi-telemetry → pi-ai/node_modules/@earendil-works/pi-telemetry}/dist/testing/conformance.d.ts.map +0 -0
  717. /package/node_modules/@earendil-works/{pi-telemetry → pi-ai/node_modules/@earendil-works/pi-telemetry}/dist/testing/conformance.js +0 -0
  718. /package/node_modules/@earendil-works/{pi-telemetry → pi-ai/node_modules/@earendil-works/pi-telemetry}/dist/testing/conformance.js.map +0 -0
  719. /package/node_modules/@earendil-works/{pi-telemetry → pi-ai/node_modules/@earendil-works/pi-telemetry}/dist/testing/index.d.ts +0 -0
  720. /package/node_modules/@earendil-works/{pi-telemetry → pi-ai/node_modules/@earendil-works/pi-telemetry}/dist/testing/index.d.ts.map +0 -0
  721. /package/node_modules/@earendil-works/{pi-telemetry → pi-ai/node_modules/@earendil-works/pi-telemetry}/dist/testing/index.js +0 -0
  722. /package/node_modules/@earendil-works/{pi-telemetry → pi-ai/node_modules/@earendil-works/pi-telemetry}/dist/testing/index.js.map +0 -0
  723. /package/node_modules/@earendil-works/{pi-telemetry → pi-ai/node_modules/@earendil-works/pi-telemetry}/dist/testing/types.d.ts +0 -0
  724. /package/node_modules/@earendil-works/{pi-telemetry → pi-ai/node_modules/@earendil-works/pi-telemetry}/dist/testing/types.d.ts.map +0 -0
  725. /package/node_modules/@earendil-works/{pi-codemode/dist → pi-ai/node_modules/@earendil-works/pi-telemetry/dist/testing}/types.js +0 -0
  726. /package/node_modules/@earendil-works/{pi-telemetry → pi-ai/node_modules/@earendil-works/pi-telemetry}/dist/testing/types.js.map +0 -0
  727. /package/node_modules/@earendil-works/{pi-telemetry → pi-ai/node_modules/@earendil-works/pi-telemetry}/package.json +0 -0
  728. /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/README.md +0 -0
  729. /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/cloudflare.d.ts +0 -0
  730. /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/cloudflare.d.ts.map +0 -0
  731. /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/cloudflare.js +0 -0
  732. /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/cloudflare.js.map +0 -0
  733. /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/declarations.d.ts +0 -0
  734. /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/declarations.d.ts.map +0 -0
  735. /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/declarations.js +0 -0
  736. /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/declarations.js.map +0 -0
  737. /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/identifier.d.ts +0 -0
  738. /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/identifier.d.ts.map +0 -0
  739. /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/identifier.js +0 -0
  740. /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/identifier.js.map +0 -0
  741. /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/index.d.ts +0 -0
  742. /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/index.d.ts.map +0 -0
  743. /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/index.js +0 -0
  744. /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/index.js.map +0 -0
  745. /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/portable.d.ts +0 -0
  746. /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/portable.d.ts.map +0 -0
  747. /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/portable.js +0 -0
  748. /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/portable.js.map +0 -0
  749. /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/runtime/execution.d.ts +0 -0
  750. /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/runtime/execution.d.ts.map +0 -0
  751. /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/runtime/execution.js +0 -0
  752. /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/runtime/execution.js.map +0 -0
  753. /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/runtime/host.d.ts +0 -0
  754. /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/runtime/host.d.ts.map +0 -0
  755. /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/runtime/host.js +0 -0
  756. /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/runtime/host.js.map +0 -0
  757. /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/runtime/inline.d.ts +0 -0
  758. /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/runtime/inline.d.ts.map +0 -0
  759. /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/runtime/inline.js +0 -0
  760. /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/runtime/inline.js.map +0 -0
  761. /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/runtime/prelude-source.d.ts +0 -0
  762. /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/runtime/prelude-source.d.ts.map +0 -0
  763. /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/runtime/prelude-source.js +0 -0
  764. /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/runtime/prelude-source.js.map +0 -0
  765. /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/runtime/protocol.d.ts +0 -0
  766. /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/runtime/protocol.d.ts.map +0 -0
  767. /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/runtime/protocol.js +0 -0
  768. /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/runtime/protocol.js.map +0 -0
  769. /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/runtime/remote.d.ts +0 -0
  770. /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/runtime/remote.d.ts.map +0 -0
  771. /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/runtime/remote.js +0 -0
  772. /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/runtime/remote.js.map +0 -0
  773. /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/runtime/vm.d.ts +0 -0
  774. /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/runtime/vm.d.ts.map +0 -0
  775. /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/runtime/vm.js +0 -0
  776. /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/runtime/vm.js.map +0 -0
  777. /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/runtime/worker.d.ts +0 -0
  778. /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/runtime/worker.d.ts.map +0 -0
  779. /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/runtime/worker.js +0 -0
  780. /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/runtime/worker.js.map +0 -0
  781. /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/source.d.ts +0 -0
  782. /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/source.d.ts.map +0 -0
  783. /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/source.js +0 -0
  784. /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/source.js.map +0 -0
  785. /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/types.d.ts +0 -0
  786. /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/types.d.ts.map +0 -0
  787. /package/node_modules/@earendil-works/{pi-telemetry/dist/testing → pi-coding-agent/node_modules/@earendil-works/pi-codemode/dist}/types.js +0 -0
  788. /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/types.js.map +0 -0
  789. /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/wasm.d.ts +0 -0
  790. /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/wasm.d.ts.map +0 -0
  791. /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/wasm.js +0 -0
  792. /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/wasm.js.map +0 -0
  793. /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/package.json +0 -0
  794. /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/CHANGELOG.md +0 -0
  795. /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/LICENSES/modelcontextprotocol-typescript-sdk.txt +0 -0
  796. /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/README.md +0 -0
  797. /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/auth-provider.d.ts +0 -0
  798. /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/auth-provider.d.ts.map +0 -0
  799. /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/auth-provider.js +0 -0
  800. /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/auth-provider.js.map +0 -0
  801. /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/client.d.ts +0 -0
  802. /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/client.d.ts.map +0 -0
  803. /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/client.js +0 -0
  804. /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/client.js.map +0 -0
  805. /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/index.d.ts +0 -0
  806. /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/index.d.ts.map +0 -0
  807. /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/index.js +0 -0
  808. /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/index.js.map +0 -0
  809. /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/oauth/callback.d.ts +0 -0
  810. /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/oauth/callback.d.ts.map +0 -0
  811. /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/oauth/callback.js +0 -0
  812. /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/oauth/callback.js.map +0 -0
  813. /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/oauth/discovery.d.ts +0 -0
  814. /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/oauth/discovery.d.ts.map +0 -0
  815. /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/oauth/discovery.js +0 -0
  816. /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/oauth/discovery.js.map +0 -0
  817. /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/oauth/errors.d.ts +0 -0
  818. /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/oauth/errors.d.ts.map +0 -0
  819. /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/oauth/errors.js +0 -0
  820. /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/oauth/errors.js.map +0 -0
  821. /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/oauth/flow.d.ts +0 -0
  822. /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/oauth/flow.d.ts.map +0 -0
  823. /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/oauth/flow.js +0 -0
  824. /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/oauth/flow.js.map +0 -0
  825. /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/oauth/index.d.ts +0 -0
  826. /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/oauth/index.d.ts.map +0 -0
  827. /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/oauth/index.js +0 -0
  828. /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/oauth/index.js.map +0 -0
  829. /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/oauth/provider.d.ts +0 -0
  830. /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/oauth/provider.d.ts.map +0 -0
  831. /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/oauth/provider.js +0 -0
  832. /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/oauth/provider.js.map +0 -0
  833. /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/oauth/types.d.ts +0 -0
  834. /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/oauth/types.d.ts.map +0 -0
  835. /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/oauth/types.js +0 -0
  836. /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/oauth/types.js.map +0 -0
  837. /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/protocol/content.d.ts +0 -0
  838. /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/protocol/content.d.ts.map +0 -0
  839. /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/protocol/content.js +0 -0
  840. /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/protocol/content.js.map +0 -0
  841. /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/protocol/jsonrpc.d.ts +0 -0
  842. /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/protocol/jsonrpc.d.ts.map +0 -0
  843. /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/protocol/jsonrpc.js +0 -0
  844. /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/protocol/jsonrpc.js.map +0 -0
  845. /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/protocol/types.d.ts +0 -0
  846. /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/protocol/types.d.ts.map +0 -0
  847. /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/protocol/types.js +0 -0
  848. /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/protocol/types.js.map +0 -0
  849. /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/testing/index.d.ts +0 -0
  850. /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/testing/index.d.ts.map +0 -0
  851. /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/testing/index.js +0 -0
  852. /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/testing/index.js.map +0 -0
  853. /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/transports/in-memory.d.ts +0 -0
  854. /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/transports/in-memory.d.ts.map +0 -0
  855. /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/transports/in-memory.js +0 -0
  856. /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/transports/in-memory.js.map +0 -0
  857. /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/transports/stdio.d.ts +0 -0
  858. /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/transports/stdio.d.ts.map +0 -0
  859. /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/transports/stdio.js +0 -0
  860. /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/transports/stdio.js.map +0 -0
  861. /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/transports/streamable-http.d.ts +0 -0
  862. /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/transports/streamable-http.d.ts.map +0 -0
  863. /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/transports/streamable-http.js +0 -0
  864. /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/transports/streamable-http.js.map +0 -0
  865. /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/transports/transport.d.ts +0 -0
  866. /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/transports/transport.d.ts.map +0 -0
  867. /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/transports/transport.js +0 -0
  868. /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/transports/transport.js.map +0 -0
  869. /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/package.json +0 -0
  870. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/README.md +0 -0
  871. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/alt-screen-search.d.ts +0 -0
  872. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/alt-screen-search.d.ts.map +0 -0
  873. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/alt-screen-search.js +0 -0
  874. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/alt-screen-search.js.map +0 -0
  875. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/autocomplete.d.ts +0 -0
  876. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/autocomplete.d.ts.map +0 -0
  877. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/autocomplete.js +0 -0
  878. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/autocomplete.js.map +0 -0
  879. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/colors.d.ts +0 -0
  880. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/colors.d.ts.map +0 -0
  881. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/colors.js +0 -0
  882. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/colors.js.map +0 -0
  883. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/alt-screen-flash.d.ts +0 -0
  884. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/alt-screen-flash.d.ts.map +0 -0
  885. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/alt-screen-flash.js +0 -0
  886. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/alt-screen-flash.js.map +0 -0
  887. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/box.d.ts +0 -0
  888. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/box.d.ts.map +0 -0
  889. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/box.js +0 -0
  890. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/box.js.map +0 -0
  891. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/cancellable-loader.d.ts +0 -0
  892. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/cancellable-loader.d.ts.map +0 -0
  893. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/cancellable-loader.js +0 -0
  894. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/cancellable-loader.js.map +0 -0
  895. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/editor.d.ts +0 -0
  896. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/editor.d.ts.map +0 -0
  897. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/editor.js +0 -0
  898. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/editor.js.map +0 -0
  899. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/h-stack.d.ts +0 -0
  900. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/h-stack.d.ts.map +0 -0
  901. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/h-stack.js +0 -0
  902. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/h-stack.js.map +0 -0
  903. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/image.d.ts +0 -0
  904. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/image.d.ts.map +0 -0
  905. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/image.js +0 -0
  906. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/image.js.map +0 -0
  907. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/input.d.ts +0 -0
  908. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/input.d.ts.map +0 -0
  909. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/input.js +0 -0
  910. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/input.js.map +0 -0
  911. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/loader.d.ts +0 -0
  912. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/loader.d.ts.map +0 -0
  913. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/loader.js +0 -0
  914. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/loader.js.map +0 -0
  915. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/markdown.d.ts +0 -0
  916. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/markdown.d.ts.map +0 -0
  917. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/markdown.js +0 -0
  918. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/markdown.js.map +0 -0
  919. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/mouse-region.d.ts +0 -0
  920. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/mouse-region.d.ts.map +0 -0
  921. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/mouse-region.js +0 -0
  922. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/mouse-region.js.map +0 -0
  923. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/scroll-view.d.ts +0 -0
  924. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/scroll-view.d.ts.map +0 -0
  925. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/scroll-view.js +0 -0
  926. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/scroll-view.js.map +0 -0
  927. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/select-list.d.ts +0 -0
  928. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/select-list.d.ts.map +0 -0
  929. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/select-list.js +0 -0
  930. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/select-list.js.map +0 -0
  931. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/settings-list.d.ts +0 -0
  932. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/settings-list.d.ts.map +0 -0
  933. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/settings-list.js +0 -0
  934. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/settings-list.js.map +0 -0
  935. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/spacer.d.ts +0 -0
  936. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/spacer.d.ts.map +0 -0
  937. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/spacer.js +0 -0
  938. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/spacer.js.map +0 -0
  939. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/stack.d.ts +0 -0
  940. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/stack.d.ts.map +0 -0
  941. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/stack.js +0 -0
  942. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/stack.js.map +0 -0
  943. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/text.d.ts +0 -0
  944. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/text.d.ts.map +0 -0
  945. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/text.js +0 -0
  946. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/text.js.map +0 -0
  947. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/truncated-text.d.ts +0 -0
  948. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/truncated-text.d.ts.map +0 -0
  949. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/truncated-text.js +0 -0
  950. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/truncated-text.js.map +0 -0
  951. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/v-stack.d.ts +0 -0
  952. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/v-stack.d.ts.map +0 -0
  953. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/v-stack.js +0 -0
  954. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/v-stack.js.map +0 -0
  955. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/editor-component.d.ts +0 -0
  956. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/editor-component.d.ts.map +0 -0
  957. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/editor-component.js +0 -0
  958. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/editor-component.js.map +0 -0
  959. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/fuzzy.d.ts +0 -0
  960. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/fuzzy.d.ts.map +0 -0
  961. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/fuzzy.js +0 -0
  962. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/fuzzy.js.map +0 -0
  963. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/index.d.ts +0 -0
  964. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/index.d.ts.map +0 -0
  965. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/index.js +0 -0
  966. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/index.js.map +0 -0
  967. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/keybindings.d.ts +0 -0
  968. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/keybindings.d.ts.map +0 -0
  969. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/keybindings.js +0 -0
  970. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/keybindings.js.map +0 -0
  971. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/keys.d.ts +0 -0
  972. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/keys.d.ts.map +0 -0
  973. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/keys.js +0 -0
  974. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/keys.js.map +0 -0
  975. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/kill-ring.d.ts +0 -0
  976. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/kill-ring.d.ts.map +0 -0
  977. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/kill-ring.js +0 -0
  978. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/kill-ring.js.map +0 -0
  979. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/latex.d.ts +0 -0
  980. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/latex.d.ts.map +0 -0
  981. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/latex.js +0 -0
  982. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/latex.js.map +0 -0
  983. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/layout-node.d.ts +0 -0
  984. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/layout-node.d.ts.map +0 -0
  985. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/layout-node.js +0 -0
  986. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/layout-node.js.map +0 -0
  987. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/layout.d.ts +0 -0
  988. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/layout.d.ts.map +0 -0
  989. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/layout.js +0 -0
  990. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/layout.js.map +0 -0
  991. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/native-modifiers.d.ts +0 -0
  992. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/native-modifiers.d.ts.map +0 -0
  993. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/native-modifiers.js +0 -0
  994. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/native-modifiers.js.map +0 -0
  995. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/native-module-path.d.ts +0 -0
  996. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/native-module-path.d.ts.map +0 -0
  997. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/native-module-path.js +0 -0
  998. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/native-module-path.js.map +0 -0
  999. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/native-platform.d.ts +0 -0
  1000. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/native-platform.d.ts.map +0 -0
  1001. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/native-platform.js +0 -0
  1002. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/native-platform.js.map +0 -0
  1003. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/oklab.d.ts +0 -0
  1004. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/oklab.d.ts.map +0 -0
  1005. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/oklab.js +0 -0
  1006. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/oklab.js.map +0 -0
  1007. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/program-status.d.ts +0 -0
  1008. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/program-status.d.ts.map +0 -0
  1009. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/program-status.js +0 -0
  1010. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/program-status.js.map +0 -0
  1011. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/stdin-buffer.d.ts +0 -0
  1012. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/stdin-buffer.d.ts.map +0 -0
  1013. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/stdin-buffer.js +0 -0
  1014. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/stdin-buffer.js.map +0 -0
  1015. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/terminal-colors.d.ts +0 -0
  1016. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/terminal-colors.d.ts.map +0 -0
  1017. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/terminal-colors.js +0 -0
  1018. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/terminal-colors.js.map +0 -0
  1019. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/terminal-image.d.ts +0 -0
  1020. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/terminal-image.d.ts.map +0 -0
  1021. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/terminal-image.js +0 -0
  1022. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/terminal-image.js.map +0 -0
  1023. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/terminal.d.ts +0 -0
  1024. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/terminal.d.ts.map +0 -0
  1025. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/terminal.js +0 -0
  1026. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/terminal.js.map +0 -0
  1027. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/tui-alt-screen.d.ts +0 -0
  1028. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/tui-alt-screen.d.ts.map +0 -0
  1029. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/tui-alt-screen.js +0 -0
  1030. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/tui-alt-screen.js.map +0 -0
  1031. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/tui-main-screen.d.ts +0 -0
  1032. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/tui-main-screen.d.ts.map +0 -0
  1033. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/tui-main-screen.js +0 -0
  1034. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/tui-main-screen.js.map +0 -0
  1035. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/tui.d.ts +0 -0
  1036. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/tui.d.ts.map +0 -0
  1037. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/tui.js +0 -0
  1038. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/tui.js.map +0 -0
  1039. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/undo-stack.d.ts +0 -0
  1040. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/undo-stack.d.ts.map +0 -0
  1041. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/undo-stack.js +0 -0
  1042. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/undo-stack.js.map +0 -0
  1043. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/utils.d.ts +0 -0
  1044. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/utils.d.ts.map +0 -0
  1045. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/utils.js +0 -0
  1046. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/utils.js.map +0 -0
  1047. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/wheel-scroll.d.ts +0 -0
  1048. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/wheel-scroll.d.ts.map +0 -0
  1049. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/wheel-scroll.js +0 -0
  1050. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/wheel-scroll.js.map +0 -0
  1051. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/word-navigation.d.ts +0 -0
  1052. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/word-navigation.d.ts.map +0 -0
  1053. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/word-navigation.js +0 -0
  1054. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/word-navigation.js.map +0 -0
  1055. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/native/clipboard.h +0 -0
  1056. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/native/darwin/README.md +0 -0
  1057. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/native/darwin/build.sh +0 -0
  1058. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/native/darwin/prebuilds/darwin-arm64/darwin-platform.node +0 -0
  1059. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/native/darwin/prebuilds/darwin-x64/darwin-platform.node +0 -0
  1060. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/native/darwin/src/darwin-platform.m +0 -0
  1061. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/native/linux/README.md +0 -0
  1062. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/native/linux/build.sh +0 -0
  1063. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/native/linux/prebuilds/linux-arm64/linux-platform-x11.node +0 -0
  1064. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/native/linux/prebuilds/linux-x64/linux-platform-x11.node +0 -0
  1065. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/native/linux/src/clipboard-worker.h +0 -0
  1066. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/native/linux/src/linux-platform-x11.c +0 -0
  1067. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/native/napi.h +0 -0
  1068. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/native/win32/README.md +0 -0
  1069. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/native/win32/build.mjs +0 -0
  1070. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/native/win32/prebuilds/win32-arm64/win32-platform.node +0 -0
  1071. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/native/win32/prebuilds/win32-x64/win32-platform.node +0 -0
  1072. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/native/win32/src/win32-platform.c +0 -0
  1073. /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/package.json +0 -0
  1074. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/LICENSE +0 -0
  1075. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/README.md +0 -0
  1076. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/docs/docs/api/Agent.md +0 -0
  1077. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/docs/docs/api/BalancedPool.md +0 -0
  1078. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/docs/docs/api/CacheStorage.md +0 -0
  1079. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/docs/docs/api/CacheStore.md +0 -0
  1080. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/docs/docs/api/Client.md +0 -0
  1081. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/docs/docs/api/ClientStats.md +0 -0
  1082. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/docs/docs/api/Connector.md +0 -0
  1083. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/docs/docs/api/ContentType.md +0 -0
  1084. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/docs/docs/api/Cookies.md +0 -0
  1085. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/docs/docs/api/Debug.md +0 -0
  1086. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/docs/docs/api/DiagnosticsChannel.md +0 -0
  1087. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/docs/docs/api/Dispatcher.md +0 -0
  1088. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/docs/docs/api/EnvHttpProxyAgent.md +0 -0
  1089. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/docs/docs/api/Errors.md +0 -0
  1090. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/docs/docs/api/EventSource.md +0 -0
  1091. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/docs/docs/api/Fetch.md +0 -0
  1092. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/docs/docs/api/GlobalInstallation.md +0 -0
  1093. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/docs/docs/api/H2CClient.md +0 -0
  1094. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/docs/docs/api/Interceptors.md +0 -0
  1095. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/docs/docs/api/MockAgent.md +0 -0
  1096. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/docs/docs/api/MockCallHistory.md +0 -0
  1097. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/docs/docs/api/MockCallHistoryLog.md +0 -0
  1098. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/docs/docs/api/MockClient.md +0 -0
  1099. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/docs/docs/api/MockErrors.md +0 -0
  1100. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/docs/docs/api/MockPool.md +0 -0
  1101. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/docs/docs/api/Pool.md +0 -0
  1102. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/docs/docs/api/PoolStats.md +0 -0
  1103. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/docs/docs/api/ProxyAgent.md +0 -0
  1104. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/docs/docs/api/RedirectHandler.md +0 -0
  1105. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/docs/docs/api/RetryAgent.md +0 -0
  1106. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/docs/docs/api/RetryHandler.md +0 -0
  1107. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/docs/docs/api/RoundRobinPool.md +0 -0
  1108. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/docs/docs/api/SnapshotAgent.md +0 -0
  1109. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/docs/docs/api/Socks5ProxyAgent.md +0 -0
  1110. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/docs/docs/api/Util.md +0 -0
  1111. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/docs/docs/api/WebSocket.md +0 -0
  1112. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/docs/docs/api/api-lifecycle.md +0 -0
  1113. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/docs/docs/best-practices/client-certificate.md +0 -0
  1114. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/docs/docs/best-practices/crawling.md +0 -0
  1115. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/docs/docs/best-practices/migrating-from-v7-to-v8.md +0 -0
  1116. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/docs/docs/best-practices/mocking-request.md +0 -0
  1117. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/docs/docs/best-practices/proxy.md +0 -0
  1118. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/docs/docs/best-practices/undici-vs-builtin-fetch.md +0 -0
  1119. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/docs/docs/best-practices/writing-tests.md +0 -0
  1120. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/docs/docs/getting-started.md +0 -0
  1121. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/docs/docs/index.md +0 -0
  1122. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/docs/docs/site.json +0 -0
  1123. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/docs/docs/type-map.json +0 -0
  1124. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/index-fetch.js +0 -0
  1125. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/index.d.ts +0 -0
  1126. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/index.js +0 -0
  1127. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/api/abort-signal.js +0 -0
  1128. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/api/api-connect.js +0 -0
  1129. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/api/api-pipeline.js +0 -0
  1130. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/api/api-request.js +0 -0
  1131. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/api/api-stream.js +0 -0
  1132. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/api/api-upgrade.js +0 -0
  1133. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/api/index.js +0 -0
  1134. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/api/readable.js +0 -0
  1135. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/cache/memory-cache-store.js +0 -0
  1136. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/cache/sqlite-cache-store.js +0 -0
  1137. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/core/connect.js +0 -0
  1138. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/core/constants.js +0 -0
  1139. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/core/diagnostics.js +0 -0
  1140. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/core/errors.js +0 -0
  1141. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/core/request.js +0 -0
  1142. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/core/socks5-client.js +0 -0
  1143. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/core/socks5-utils.js +0 -0
  1144. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/core/symbols.js +0 -0
  1145. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/core/tree.js +0 -0
  1146. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/core/util.js +0 -0
  1147. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/dispatcher/agent.js +0 -0
  1148. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/dispatcher/balanced-pool.js +0 -0
  1149. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/dispatcher/client-h1.js +0 -0
  1150. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/dispatcher/client-h2.js +0 -0
  1151. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/dispatcher/client.js +0 -0
  1152. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/dispatcher/dispatcher-base.js +0 -0
  1153. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/dispatcher/dispatcher.js +0 -0
  1154. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/dispatcher/dispatcher1-wrapper.js +0 -0
  1155. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/dispatcher/env-http-proxy-agent.js +0 -0
  1156. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/dispatcher/fixed-queue.js +0 -0
  1157. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/dispatcher/h2c-client.js +0 -0
  1158. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/dispatcher/pool-base.js +0 -0
  1159. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/dispatcher/pool.js +0 -0
  1160. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/dispatcher/proxy-agent.js +0 -0
  1161. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/dispatcher/retry-agent.js +0 -0
  1162. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/dispatcher/round-robin-pool.js +0 -0
  1163. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/dispatcher/socks5-proxy-agent.js +0 -0
  1164. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/encoding/index.js +0 -0
  1165. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/global.js +0 -0
  1166. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/handler/cache-handler.js +0 -0
  1167. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/handler/cache-revalidation-handler.js +0 -0
  1168. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/handler/decorator-handler.js +0 -0
  1169. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/handler/deduplication-handler.js +0 -0
  1170. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/handler/redirect-handler.js +0 -0
  1171. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/handler/retry-handler.js +0 -0
  1172. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/interceptor/cache.js +0 -0
  1173. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/interceptor/decompress.js +0 -0
  1174. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/interceptor/deduplicate.js +0 -0
  1175. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/interceptor/dns.js +0 -0
  1176. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/interceptor/dump.js +0 -0
  1177. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/interceptor/redirect.js +0 -0
  1178. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/interceptor/response-error.js +0 -0
  1179. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/interceptor/retry.js +0 -0
  1180. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/llhttp/constants.d.ts +0 -0
  1181. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/llhttp/constants.js +0 -0
  1182. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/llhttp/llhttp-wasm.js +0 -0
  1183. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/llhttp/llhttp_simd-wasm.js +0 -0
  1184. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/llhttp/utils.d.ts +0 -0
  1185. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/llhttp/utils.js +0 -0
  1186. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/mock/mock-agent.js +0 -0
  1187. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/mock/mock-call-history.js +0 -0
  1188. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/mock/mock-client.js +0 -0
  1189. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/mock/mock-errors.js +0 -0
  1190. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/mock/mock-interceptor.js +0 -0
  1191. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/mock/mock-pool.js +0 -0
  1192. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/mock/mock-symbols.js +0 -0
  1193. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/mock/mock-utils.js +0 -0
  1194. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/mock/pending-interceptors-formatter.js +0 -0
  1195. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/mock/snapshot-agent.js +0 -0
  1196. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/mock/snapshot-recorder.js +0 -0
  1197. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/mock/snapshot-utils.js +0 -0
  1198. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/util/cache.js +0 -0
  1199. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/util/date.js +0 -0
  1200. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/util/runtime-features.js +0 -0
  1201. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/util/stats.js +0 -0
  1202. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/util/timers.js +0 -0
  1203. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/web/cache/cache.js +0 -0
  1204. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/web/cache/cachestorage.js +0 -0
  1205. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/web/cache/util.js +0 -0
  1206. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/web/cookies/constants.js +0 -0
  1207. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/web/cookies/index.js +0 -0
  1208. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/web/cookies/parse.js +0 -0
  1209. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/web/cookies/util.js +0 -0
  1210. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/web/eventsource/eventsource-stream.js +0 -0
  1211. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/web/eventsource/eventsource.js +0 -0
  1212. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/web/eventsource/util.js +0 -0
  1213. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/web/fetch/LICENSE +0 -0
  1214. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/web/fetch/body.js +0 -0
  1215. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/web/fetch/constants.js +0 -0
  1216. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/web/fetch/data-url.js +0 -0
  1217. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/web/fetch/formdata-parser.js +0 -0
  1218. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/web/fetch/formdata.js +0 -0
  1219. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/web/fetch/global.js +0 -0
  1220. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/web/fetch/headers.js +0 -0
  1221. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/web/fetch/index.js +0 -0
  1222. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/web/fetch/request.js +0 -0
  1223. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/web/fetch/response.js +0 -0
  1224. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/web/fetch/util.js +0 -0
  1225. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/web/infra/index.js +0 -0
  1226. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/web/subresource-integrity/Readme.md +0 -0
  1227. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/web/subresource-integrity/subresource-integrity.js +0 -0
  1228. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/web/webidl/index.js +0 -0
  1229. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/web/websocket/connection.js +0 -0
  1230. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/web/websocket/constants.js +0 -0
  1231. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/web/websocket/events.js +0 -0
  1232. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/web/websocket/frame.js +0 -0
  1233. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/web/websocket/permessage-deflate.js +0 -0
  1234. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/web/websocket/receiver.js +0 -0
  1235. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/web/websocket/sender.js +0 -0
  1236. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/web/websocket/stream/websocketerror.js +0 -0
  1237. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/web/websocket/stream/websocketstream.js +0 -0
  1238. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/web/websocket/util.js +0 -0
  1239. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/web/websocket/websocket.js +0 -0
  1240. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/package.json +0 -0
  1241. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/scripts/strip-comments.js +0 -0
  1242. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/types/README.md +0 -0
  1243. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/types/agent.d.ts +0 -0
  1244. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/types/api.d.ts +0 -0
  1245. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/types/balanced-pool.d.ts +0 -0
  1246. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/types/cache-interceptor.d.ts +0 -0
  1247. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/types/cache.d.ts +0 -0
  1248. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/types/client-stats.d.ts +0 -0
  1249. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/types/client.d.ts +0 -0
  1250. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/types/connector.d.ts +0 -0
  1251. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/types/content-type.d.ts +0 -0
  1252. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/types/cookies.d.ts +0 -0
  1253. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/types/diagnostics-channel.d.ts +0 -0
  1254. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/types/dispatcher.d.ts +0 -0
  1255. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/types/dispatcher1-wrapper.d.ts +0 -0
  1256. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/types/env-http-proxy-agent.d.ts +0 -0
  1257. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/types/errors.d.ts +0 -0
  1258. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/types/eventsource.d.ts +0 -0
  1259. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/types/fetch.d.ts +0 -0
  1260. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/types/formdata.d.ts +0 -0
  1261. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/types/global-dispatcher.d.ts +0 -0
  1262. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/types/global-origin.d.ts +0 -0
  1263. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/types/h2c-client.d.ts +0 -0
  1264. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/types/handlers.d.ts +0 -0
  1265. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/types/header.d.ts +0 -0
  1266. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/types/index.d.ts +0 -0
  1267. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/types/interceptors.d.ts +0 -0
  1268. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/types/mock-agent.d.ts +0 -0
  1269. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/types/mock-call-history.d.ts +0 -0
  1270. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/types/mock-client.d.ts +0 -0
  1271. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/types/mock-errors.d.ts +0 -0
  1272. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/types/mock-interceptor.d.ts +0 -0
  1273. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/types/mock-pool.d.ts +0 -0
  1274. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/types/patch.d.ts +0 -0
  1275. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/types/pool-stats.d.ts +0 -0
  1276. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/types/pool.d.ts +0 -0
  1277. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/types/proxy-agent.d.ts +0 -0
  1278. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/types/readable.d.ts +0 -0
  1279. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/types/retry-agent.d.ts +0 -0
  1280. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/types/retry-handler.d.ts +0 -0
  1281. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/types/round-robin-pool.d.ts +0 -0
  1282. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/types/snapshot-agent.d.ts +0 -0
  1283. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/types/socks5-proxy-agent.d.ts +0 -0
  1284. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/types/util.d.ts +0 -0
  1285. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/types/utility.d.ts +0 -0
  1286. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/types/webidl.d.ts +0 -0
  1287. /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/types/websocket.d.ts +0 -0
@@ -0,0 +1,494 @@
1
+ /**
2
+ * Host side of an execution, shared by every place a VM can run.
3
+ *
4
+ * The host owns everything the script must not influence: the tool table, call records, output,
5
+ * the deadline, the caller's abort signal, and the decoding of what the VM reports. The VM itself
6
+ * runs somewhere a {@link VmLauncher} decides: a worker thread (`CodemodeSandbox`), the calling
7
+ * thread (`InlineCodemodeSandbox`), or another isolate reached over RPC (`RemoteCodemodeSandbox`).
8
+ * The two sides only exchange the messages in `protocol.ts`, so the launchers differ in transport
9
+ * and termination, not in behavior.
10
+ *
11
+ * Lifecycle of one execution:
12
+ * 1. The constructor arms the deadline and abort listener, then asks the launcher for a channel.
13
+ * 2. Messages from the VM arrive through {@link VmEvents.message}; tool calls run here and their
14
+ * results go back through {@link VmChannel.post}. Replies produced before the launcher has
15
+ * returned its channel are queued and flushed when it arrives.
16
+ * 3. The first terminal event wins: `done`, `crash`, a launcher failure, the deadline, or an abort.
17
+ * `finish()` aborts pending tool calls, stops the channel, and resolves the result once the
18
+ * channel reports it stopped. Later events are ignored.
19
+ *
20
+ * The launcher, not this class, is responsible for actually stopping a running VM: a worker is
21
+ * terminated, an in-thread VM is interrupted and disposed, and a remote VM is told to stop at its
22
+ * next exchange.
23
+ */
24
+ import { toCodemodeIdentifier } from "../identifier.js";
25
+ import { isWorkerToHostMessage, } from "./protocol.js";
26
+ const DEFAULT_TIMEOUT_MS = 300_000;
27
+ const IDENTIFIER = /^[A-Za-z_$][A-Za-z0-9_$]*$/;
28
+ const RESERVED_GLOBALS = new Set([
29
+ "tools",
30
+ "ALL_TOOLS",
31
+ "console",
32
+ "text",
33
+ "image",
34
+ "exit",
35
+ "globalThis",
36
+ "store",
37
+ "load",
38
+ ]);
39
+ export function errorMessage(error) {
40
+ return error instanceof Error ? error.message : String(error);
41
+ }
42
+ function serializeStore(store) {
43
+ const serialized = {};
44
+ for (const [key, value] of Object.entries(store ?? {})) {
45
+ const json = JSON.stringify(value);
46
+ if (json !== undefined)
47
+ serialized[key] = json;
48
+ }
49
+ return serialized;
50
+ }
51
+ /**
52
+ * The prelude that serializes values for the host runs in the same VM as the script, so a script
53
+ * that patches built-ins (for example `Array.prototype.toJSON`) can make it send malformed data.
54
+ * Payloads that do not decode throw this error, and the execution fails as a sandbox error.
55
+ */
56
+ class BridgeError extends Error {
57
+ }
58
+ function parseBridgeJson(json, what) {
59
+ try {
60
+ return JSON.parse(json);
61
+ }
62
+ catch {
63
+ throw new BridgeError(`${what} is not valid JSON`);
64
+ }
65
+ }
66
+ function parseStoreWrites(json) {
67
+ const entries = parseBridgeJson(json, "store writes");
68
+ if (!Array.isArray(entries))
69
+ throw new BridgeError("store writes are not an array");
70
+ const writes = { set: {}, delete: [] };
71
+ for (const entry of entries) {
72
+ if (!Array.isArray(entry) ||
73
+ typeof entry[0] !== "string" ||
74
+ (entry.length === 2 ? typeof entry[1] !== "string" : entry.length !== 1)) {
75
+ throw new BridgeError("store writes contain a malformed entry");
76
+ }
77
+ const [key, value] = entry;
78
+ if (value === undefined)
79
+ writes.delete.push(key);
80
+ else
81
+ writes.set[key] = parseBridgeJson(value, `store value for ${JSON.stringify(key)}`);
82
+ }
83
+ return writes;
84
+ }
85
+ function parseScriptError(json) {
86
+ const parsed = parseBridgeJson(json, "script error");
87
+ if (typeof parsed !== "object" || parsed === null)
88
+ throw new BridgeError("script error is not an object");
89
+ const { name, message, stack } = parsed;
90
+ if (typeof message !== "string" ||
91
+ (name !== undefined && typeof name !== "string") ||
92
+ (stack !== undefined && typeof stack !== "string")) {
93
+ throw new BridgeError("script error is malformed");
94
+ }
95
+ return { kind: "script", name, message, stack };
96
+ }
97
+ /** Checks global names: identifiers or `namespace.member`, not shadowing a built-in global or each other. */
98
+ function checkGlobals(globals) {
99
+ const names = new Set();
100
+ const namespaces = new Set();
101
+ for (const global of globals) {
102
+ const parts = global.name.split(".");
103
+ if (parts.length > 2 || !parts.every((part) => IDENTIFIER.test(part)) || RESERVED_GLOBALS.has(parts[0])) {
104
+ throw new Error(`Invalid global name "${global.name}"`);
105
+ }
106
+ if (names.has(global.name))
107
+ throw new Error(`Global "${global.name}" is already registered`);
108
+ if (parts.length === 2)
109
+ namespaces.add(parts[0]);
110
+ names.add(global.name);
111
+ }
112
+ for (const name of namespaces) {
113
+ if (names.has(name))
114
+ throw new Error(`Global "${name}" conflicts with the namespace "${name}"`);
115
+ }
116
+ }
117
+ /** One script run in its own VM. */
118
+ class Execution {
119
+ promise;
120
+ resolveResult;
121
+ channel;
122
+ /** Replies produced before the launcher returned the channel. */
123
+ unsent = [];
124
+ executors;
125
+ control;
126
+ /** Result numbers `deliver()` used. */
127
+ delivered = new Set();
128
+ signal;
129
+ timer;
130
+ output = [];
131
+ calls = [];
132
+ pending = new Map();
133
+ /** Whether the execution has its outcome. */
134
+ finished = false;
135
+ constructor(options) {
136
+ this.promise = new Promise((resolve) => {
137
+ this.resolveResult = resolve;
138
+ });
139
+ this.executors = options.executors;
140
+ this.control = options.control;
141
+ this.signal = options.signal;
142
+ if (Number.isFinite(options.timeoutMs)) {
143
+ this.timer = setTimeout(() => {
144
+ this.finish({ kind: "timeout", message: `Execution timed out after ${options.timeoutMs} ms` });
145
+ }, options.timeoutMs);
146
+ }
147
+ if (options.signal) {
148
+ if (options.signal.aborted) {
149
+ this.onAbort();
150
+ }
151
+ else {
152
+ options.signal.addEventListener("abort", this.onAbort, { once: true });
153
+ }
154
+ }
155
+ if (this.finished)
156
+ return;
157
+ const data = {
158
+ code: options.code,
159
+ tools: options.tools.map((tool) => ({
160
+ name: tool.name,
161
+ jsName: tool.jsName ?? toCodemodeIdentifier(tool.name),
162
+ description: tool.description ?? "",
163
+ })),
164
+ globals: options.globals.map((global) => ({ name: global.name, spread: global.spread === true })),
165
+ memoryLimitBytes: options.memoryLimitBytes,
166
+ store: options.store,
167
+ ...(options.deterministic ? { deterministic: options.deterministic } : {}),
168
+ };
169
+ const events = {
170
+ message: (message) => this.receive(message),
171
+ failure: (error) => this.finish(error),
172
+ };
173
+ new Promise((resolve) => resolve(options.launch(data, events))).then((channel) => {
174
+ if (this.finished) {
175
+ void channel.stop().catch(() => undefined);
176
+ return;
177
+ }
178
+ this.channel = channel;
179
+ for (const message of this.unsent.splice(0))
180
+ channel.post(message);
181
+ }, (error) => {
182
+ this.finish({ kind: "sandbox", message: errorMessage(error) });
183
+ });
184
+ }
185
+ /** `CodemodeRun.deliver()`. */
186
+ deliver(seq, now, id, outcome) {
187
+ if (this.finished)
188
+ return;
189
+ if (!Number.isFinite(now))
190
+ throw new Error(`The clock value of result ${seq} is not a finite number`);
191
+ if (!Number.isInteger(seq) || seq < 1 || this.delivered.has(seq)) {
192
+ throw new Error(`Result number ${seq} is not a positive integer used once`);
193
+ }
194
+ const pending = this.pending.get(id);
195
+ if (pending === undefined)
196
+ throw new Error(`Call ${id} is not waiting for a result`);
197
+ if (!outcome.ok && outcome.properties !== undefined) {
198
+ const { properties } = outcome;
199
+ if (typeof properties !== "object" || properties === null || Array.isArray(properties)) {
200
+ throw new Error(`The properties of result ${seq} are not an object`);
201
+ }
202
+ }
203
+ // Serialized before anything is recorded, so a value JSON cannot hold leaves the call waiting for another answer.
204
+ const payload = outcome.ok
205
+ ? outcome.value === undefined
206
+ ? undefined
207
+ : JSON.stringify(outcome.value)
208
+ : outcome.message;
209
+ const properties = !outcome.ok && outcome.properties !== undefined ? JSON.stringify(outcome.properties) : undefined;
210
+ this.delivered.add(seq);
211
+ this.pending.delete(id);
212
+ if (pending.record) {
213
+ pending.record.status = outcome.ok ? "ok" : "error";
214
+ pending.record.durationMs = performance.now() - pending.startedAt;
215
+ }
216
+ this.post({
217
+ type: "result",
218
+ id,
219
+ ok: outcome.ok,
220
+ payload,
221
+ seq,
222
+ now,
223
+ ...(properties === undefined ? {} : { properties }),
224
+ });
225
+ }
226
+ abort(message) {
227
+ this.finish({ kind: "aborted", message });
228
+ return this.promise;
229
+ }
230
+ onAbort = () => {
231
+ const reason = this.signal?.reason;
232
+ this.finish({ kind: "aborted", message: reason instanceof Error ? reason.message : "Execution aborted" });
233
+ };
234
+ post(message) {
235
+ if (this.channel)
236
+ this.channel.post(message);
237
+ else
238
+ this.unsent.push(message);
239
+ }
240
+ /** An exception here would escape into the launcher's transport and leave the execution unsettled. */
241
+ receive(message) {
242
+ try {
243
+ this.handleMessage(message);
244
+ }
245
+ catch (error) {
246
+ this.finish({
247
+ kind: "sandbox",
248
+ message: error instanceof BridgeError
249
+ ? `Sandbox bridge broken: ${error.message}. The script may have modified built-ins such as a prototype's toJSON.`
250
+ : `Sandbox host failed: ${errorMessage(error)}`,
251
+ });
252
+ }
253
+ }
254
+ handleMessage(message) {
255
+ if (this.finished)
256
+ return;
257
+ if (!isWorkerToHostMessage(message))
258
+ throw new BridgeError("unknown message from the worker");
259
+ switch (message.type) {
260
+ case "output":
261
+ this.output.push(message.item);
262
+ break;
263
+ case "call":
264
+ if (this.pending.has(message.id))
265
+ throw new BridgeError(`duplicate call id ${message.id}`);
266
+ if (this.control)
267
+ this.forwardCall(message, this.control);
268
+ else
269
+ void this.handleCall(message);
270
+ break;
271
+ case "started":
272
+ this.control?.onStarted?.(message.fingerprint);
273
+ break;
274
+ case "idle":
275
+ this.control?.onIdle?.(message.seq, message.issued);
276
+ break;
277
+ case "done":
278
+ this.handleDone(message);
279
+ break;
280
+ case "crash":
281
+ this.finish({ kind: "sandbox", message: message.message });
282
+ break;
283
+ }
284
+ }
285
+ handleDone(message) {
286
+ // Decode everything before finish(), which must not throw once it starts.
287
+ if (!message.ok) {
288
+ this.finish(parseScriptError(message.error), undefined, undefined, message.during);
289
+ return;
290
+ }
291
+ const value = message.value === undefined ? undefined : parseBridgeJson(message.value, "return value");
292
+ this.finish(undefined, value, parseStoreWrites(message.writes), message.during);
293
+ }
294
+ /** A host-controlled run: record the call and hand it to the caller, which answers with `deliver()`. */
295
+ forwardCall(message, control) {
296
+ const { id, name, target } = message;
297
+ const args = message.args === undefined ? undefined : parseBridgeJson(message.args, "call arguments");
298
+ const record = target === "tool" ? { name, status: "cancelled", durationMs: 0 } : undefined;
299
+ if (record)
300
+ this.calls.push(record);
301
+ this.pending.set(id, { record, startedAt: performance.now(), controller: new AbortController() });
302
+ control.onCall({ id, target, name, args });
303
+ }
304
+ async handleCall(message) {
305
+ const { id, name } = message;
306
+ const isTool = message.target === "tool";
307
+ const record = isTool ? { name, status: "cancelled", durationMs: 0 } : undefined;
308
+ if (record)
309
+ this.calls.push(record);
310
+ const pending = { record, startedAt: performance.now(), controller: new AbortController() };
311
+ this.pending.set(id, pending);
312
+ let status;
313
+ let reply;
314
+ try {
315
+ const tool = (isTool ? this.executors.tools : this.executors.globals).get(name);
316
+ if (!tool)
317
+ throw new Error(`Unknown ${isTool ? "tool" : "global"} "${name}"`);
318
+ const args = message.args === undefined ? undefined : JSON.parse(message.args);
319
+ const value = await tool.execute(args, { signal: pending.controller.signal });
320
+ reply = { type: "result", id, ok: true, payload: value === undefined ? undefined : JSON.stringify(value) };
321
+ status = "ok";
322
+ }
323
+ catch (error) {
324
+ reply = { type: "result", id, ok: false, payload: errorMessage(error) };
325
+ status = "error";
326
+ }
327
+ // Already cancelled by finish(): the record keeps "cancelled" and the
328
+ // VM is gone or going.
329
+ if (!this.pending.delete(id))
330
+ return;
331
+ if (record) {
332
+ record.status = status;
333
+ record.durationMs = performance.now() - pending.startedAt;
334
+ }
335
+ this.post(reply);
336
+ }
337
+ finish(error, value, writes, during) {
338
+ if (this.finished)
339
+ return;
340
+ this.finished = true;
341
+ clearTimeout(this.timer);
342
+ this.signal?.removeEventListener("abort", this.onAbort);
343
+ const now = performance.now();
344
+ for (const pending of this.pending.values()) {
345
+ if (pending.record)
346
+ pending.record.durationMs = now - pending.startedAt;
347
+ pending.controller.abort();
348
+ }
349
+ this.pending.clear();
350
+ this.unsent = [];
351
+ const ended = during === undefined ? {} : { during: { seq: during.seq, issued: during.issued } };
352
+ const result = error
353
+ ? { ok: false, error, output: this.output, calls: this.calls, ...ended }
354
+ : {
355
+ ok: true,
356
+ value,
357
+ output: this.output,
358
+ calls: this.calls,
359
+ storeWrites: writes ?? { set: {}, delete: [] },
360
+ ...ended,
361
+ };
362
+ if (!this.channel) {
363
+ this.resolveResult(result);
364
+ return;
365
+ }
366
+ this.channel
367
+ .stop()
368
+ .catch(() => undefined)
369
+ .then(() => this.resolveResult(result));
370
+ }
371
+ }
372
+ /**
373
+ * Tool table, defaults, and in-flight executions; the behavior every sandbox shares. Subclasses
374
+ * only choose where the VM runs by passing a {@link VmLauncher}.
375
+ *
376
+ * The script sees `tools.<name>(args)` for every registered tool, `ALL_TOOLS`, the output helpers
377
+ * `text`, `image`, `exit`, and `console.*`, `store`/`load`, and the configured globals; nothing
378
+ * else (no timers, `fetch`, `process`, `require`, modules). Each `execute()` gets its own VM; the
379
+ * sandbox only holds the tool table and defaults. `close()` aborts in-flight executions.
380
+ */
381
+ export class CodemodeSandboxBase {
382
+ toolsByName = new Map();
383
+ globalsByName = new Map();
384
+ timeoutMs;
385
+ memoryLimitBytes;
386
+ launch;
387
+ running = new Set();
388
+ closed = false;
389
+ constructor(options, launch) {
390
+ this.timeoutMs = options.timeoutMs ?? DEFAULT_TIMEOUT_MS;
391
+ this.memoryLimitBytes = options.memoryLimitBytes;
392
+ this.launch = launch;
393
+ for (const tool of options.tools ?? [])
394
+ this.registerTool(tool);
395
+ checkGlobals(options.globals ?? []);
396
+ for (const global of options.globals ?? [])
397
+ this.globalsByName.set(global.name, global);
398
+ }
399
+ /** Throws if a tool with the same name is already registered. */
400
+ registerTool(tool) {
401
+ if (this.toolsByName.has(tool.name))
402
+ throw new Error(`Tool "${tool.name}" is already registered`);
403
+ this.toolsByName.set(tool.name, tool);
404
+ }
405
+ unregisterTool(name) {
406
+ return this.toolsByName.delete(name);
407
+ }
408
+ get tools() {
409
+ return [...this.toolsByName.values()];
410
+ }
411
+ get globals() {
412
+ return [...this.globalsByName.values()];
413
+ }
414
+ /**
415
+ * `code` is an async function body: `return` and top-level `await` work.
416
+ * Never rejects for script failures; those come back as `{ ok: false }`.
417
+ * The script can use `store(key, value)` and `load(key)` on `options.store`.
418
+ */
419
+ execute(code, options = {}) {
420
+ if (this.closed)
421
+ return Promise.reject(new Error("Sandbox is closed"));
422
+ const tools = new Map(this.toolsByName);
423
+ const execution = new Execution({
424
+ code,
425
+ tools: [...tools.values()],
426
+ globals: [...this.globalsByName.values()],
427
+ executors: { tools, globals: this.globalsByName },
428
+ timeoutMs: options.timeoutMs ?? this.timeoutMs,
429
+ signal: options.signal,
430
+ memoryLimitBytes: this.memoryLimitBytes,
431
+ store: serializeStore(options.store),
432
+ launch: this.launch,
433
+ });
434
+ this.running.add(execution);
435
+ return execution.promise.finally(() => this.running.delete(execution));
436
+ }
437
+ /**
438
+ * Run `code` deterministically, with the caller answering its calls: the same script, start time, seed, tools,
439
+ * globals, and store, answered with the same results in the same `seq` order, makes the same calls with the same
440
+ * arguments and produces the same output, on any VM with the same fingerprint. A host can therefore replay it
441
+ * after a restart. The VM runs in UTC, its clock reads `startedAt` and then the `now` of the result being
442
+ * processed, its randomness comes from `seed`, and `WeakRef` and `FinalizationRegistry` do not exist.
443
+ *
444
+ * The sandbox's own tools and globals are not used: the run declares its own, and every call goes to
445
+ * `options.onCall`. Never rejects for script failures; abort through `options.signal` to end the run with an
446
+ * error the script cannot catch.
447
+ */
448
+ start(code, options) {
449
+ if (this.closed)
450
+ throw new Error("Sandbox is closed");
451
+ if (!Number.isFinite(options.startedAt) || options.startedAt < 0) {
452
+ throw new Error("startedAt must be a non-negative number of milliseconds since the epoch");
453
+ }
454
+ if (!Number.isInteger(options.seed) || options.seed < 0 || options.seed > 0xffffffff) {
455
+ throw new Error("seed must be a 32-bit unsigned integer");
456
+ }
457
+ const tools = options.tools ?? [];
458
+ if (new Set(tools.map((tool) => tool.name)).size !== tools.length)
459
+ throw new Error("Tool names must be unique");
460
+ const scriptNames = tools.map((tool) => tool.jsName ?? toCodemodeIdentifier(tool.name));
461
+ if (new Set(scriptNames).size !== tools.length)
462
+ throw new Error("Tool script names must be unique");
463
+ const globals = options.globals ?? [];
464
+ checkGlobals(globals);
465
+ const execution = new Execution({
466
+ code,
467
+ tools,
468
+ globals,
469
+ executors: { tools: new Map(), globals: new Map() },
470
+ timeoutMs: options.timeoutMs ?? Number.POSITIVE_INFINITY,
471
+ signal: options.signal,
472
+ memoryLimitBytes: this.memoryLimitBytes,
473
+ store: serializeStore(options.store),
474
+ deterministic: { startedAt: options.startedAt, seed: options.seed },
475
+ control: { onStarted: options.onStarted, onCall: options.onCall, onIdle: options.onIdle },
476
+ launch: this.launch,
477
+ });
478
+ this.running.add(execution);
479
+ const result = execution.promise.finally(() => this.running.delete(execution));
480
+ return {
481
+ result,
482
+ deliver: (seq, now, id, outcome) => execution.deliver(seq, now, id, outcome),
483
+ get finished() {
484
+ return execution.finished;
485
+ },
486
+ };
487
+ }
488
+ /** Aborts in-flight executions (they resolve with `kind: "aborted"`) and rejects new ones. */
489
+ async close() {
490
+ this.closed = true;
491
+ await Promise.all([...this.running].map((execution) => execution.abort("Sandbox closed")));
492
+ }
493
+ }
494
+ //# sourceMappingURL=execution.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"execution.js","sourceRoot":"","sources":["../../src/runtime/execution.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;GAsBG;AACH,OAAO,EAAE,oBAAoB,EAAE,MAAM,kBAAkB,CAAC;AAkBxD,OAAO,EAEN,qBAAqB,GAGrB,MAAM,eAAe,CAAC;AAEvB,MAAM,kBAAkB,GAAG,OAAO,CAAC;AACnC,MAAM,UAAU,GAAG,4BAA4B,CAAC;AAChD,MAAM,gBAAgB,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gB;YACvC,KAAK,EAAE,cAAc,CAAC,OAAO,CAAC,KAAK,CAAC;YACpC,aAAa,EAAE,EAAE,SAAS,EAAE,OAAO,CAAC,SAAS,EAAE,IAAI,EAAE,OAAO,CAAC,IAAI,EAAE;YACnE,OAAO,EAAE,EAAE,SAAS,EAAE,OAAO,CAAC,SAAS,EAAE,MAAM,EAAE,OAAO,CAAC,MAAM,EAAE,MAAM,EAAE,OAAO,CAAC,MAAM,EAAE;YACzF,MAAM,EAAE,IAAI,CAAC,MAAM;SACnB,CAAC,CAAC;QACH,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,SAAS,CAAC,CAAC;QAC5B,MAAM,MAAM,GAAG,SAAS,CAAC,OAAO,CAAC,OAAO,CAAC,GAAG,EAAE,CAAC,IAAI,CAAC,OAAO,CAAC,MAAM,CAAC,SAAS,CAAC,CAAC,CAAC;QAC/E,OAAO;YACN,MAAM;YACN,OAAO,EAAE,CAAC,GAAG,EAAE,GAAG,EAAE,EAAE,EAAE,OAAO,EAAE,EAAE,CAAC,SAAS,CAAC,OAAO,CAAC,GAAG,EAAE,GAAG,EAAE,EAAE,EAAE,OAAO,CAAC;YAC5E,IAAI,QAAQ;gBACX,OAAO,SAAS,CAAC,QAAQ,CAAC;YAC3B,CAAC;SACD,CAAC;IACH,CAAC;IAED,8FAA8F;IAC9F,KAAK,CAAC,KAAK;QACV,IAAI,CAAC,MAAM,GAAG,IAAI,CAAC;QACnB,MAAM,OAAO,CAAC,GAAG,CAAC,CAAC,GAAG,IAAI,CAAC,OAAO,CAAC,CAAC,GAAG,CAAC,CAAC,SAAS,EAAE,EAAE,CAAC,SAAS,CAAC,KAAK,CAAC,gBAAgB,CAAC,CAAC,CAAC,CAAC;IAC5F,CAAC;CACD","sourcesContent":["/**\n * Host side of an execution, shared by every place a VM can run.\n *\n * The host owns everything the script must not influence: the tool table, call records, output,\n * the deadline, the caller's abort signal, and the decoding of what the VM reports. The VM itself\n * runs somewhere a {@link VmLauncher} decides: a worker thread (`CodemodeSandbox`), the calling\n * thread (`InlineCodemodeSandbox`), or another isolate reached over RPC (`RemoteCodemodeSandbox`).\n * The two sides only exchange the messages in `protocol.ts`, so the launchers differ in transport\n * and termination, not in behavior.\n *\n * Lifecycle of one execution:\n * 1. The constructor arms the deadline and abort listener, then asks the launcher for a channel.\n * 2. Messages from the VM arrive through {@link VmEvents.message}; tool calls run here and their\n * results go back through {@link VmChannel.post}. Replies produced before the launcher has\n * returned its channel are queued and flushed when it arrives.\n * 3. The first terminal event wins: `done`, `crash`, a launcher failure, the deadline, or an abort.\n * `finish()` aborts pending tool calls, stops the channel, and resolves the result once the\n * channel reports it stopped. Later events are ignored.\n *\n * The launcher, not this class, is responsible for actually stopping a running VM: a worker is\n * terminated, an in-thread VM is interrupted and disposed, and a remote VM is told to stop at its\n * next exchange.\n */\nimport { toCodemodeIdentifier } from \"../identifier.ts\";\nimport type {\n\tCodemodeCall,\n\tCodemodeCallStatus,\n\tCodemodeDeclaredGlobal,\n\tCodemodeDeclaredTool,\n\tCodemodeDuring,\n\tCodemodeError,\n\tCodemodeExecuteOptions,\n\tCodemodeOutcome,\n\tCodemodeOutputItem,\n\tCodemodeResult,\n\tCodemodeRun,\n\tCodemodeRunOptions,\n\tCodemodeSandboxBaseOptions,\n\tCodemodeStoreWrites,\n\tCodemodeTool,\n} from \"../types.ts\";\nimport {\n\ttype HostToWorkerMessage,\n\tisWorkerToHostMessage,\n\ttype VmStartData,\n\ttype WorkerToHostMessage,\n} from \"./protocol.ts\";\n\nconst DEFAULT_TIMEOUT_MS = 300_000;\nconst IDENTIFIER = /^[A-Za-z_$][A-Za-z0-9_$]*$/;\nconst RESERVED_GLOBALS: ReadonlySet<string> = new Set([\n\t\"tools\",\n\t\"ALL_TOOLS\",\n\t\"console\",\n\t\"text\",\n\t\"image\",\n\t\"exit\",\n\t\"globalThis\",\n\t\"store\",\n\t\"load\",\n]);\n\n/** Callbacks a launcher uses to report what its VM does. */\nexport interface VmEvents {\n\t/** A message from the VM. Validated here, so launchers can pass through anything they receive. */\n\tmessage(message: unknown): void;\n\t/** The VM failed or stopped outside the bridge, for example a worker exit or a remote error. */\n\tfailure(error: CodemodeError): void;\n}\n\n/** The host's handle on a running VM. */\nexport interface VmChannel {\n\tpost(message: HostToWorkerMessage): void;\n\t/** Stops the VM. Called once, after the execution has its result. */\n\tstop(): Promise<void>;\n}\n\n/**\n * Starts a VM for one execution. Rejections become `sandbox` errors with the rejection's message.\n * The VM may start reporting messages before the returned promise settles.\n */\nexport type VmLauncher = (data: VmStartData, events: VmEvents) => VmChannel | Promise<VmChannel>;\n\nexport function errorMessage(error: unknown): string {\n\treturn error instanceof Error ? error.message : String(error);\n}\n\nfunction serializeStore(store: Readonly<Record<string, unknown>> | undefined): Record<string, string> {\n\tconst serialized: Record<string, string> = {};\n\tfor (const [key, value] of Object.entries(store ?? {})) {\n\t\tconst json = JSON.stringify(value);\n\t\tif (json !== undefined) serialized[key] = json;\n\t}\n\treturn serialized;\n}\n\n/**\n * The prelude that serializes values for the host runs in the same VM as the script, so a script\n * that patches built-ins (for example `Array.prototype.toJSON`) can make it send malformed data.\n * Payloads that do not decode throw this error, and the execution fails as a sandbox error.\n */\nclass BridgeError extends Error {}\n\nfunction parseBridgeJson(json: string, what: string): unknown {\n\ttry {\n\t\treturn JSON.parse(json);\n\t} catch {\n\t\tthrow new BridgeError(`${what} is not valid JSON`);\n\t}\n}\n\nfunction parseStoreWrites(json: string): CodemodeStoreWrites {\n\tconst entries = parseBridgeJson(json, \"store writes\");\n\tif (!Array.isArray(entries)) throw new BridgeError(\"store writes are not an array\");\n\tconst writes: CodemodeStoreWrites = { set: {}, delete: [] };\n\tfor (const entry of entries) {\n\t\tif (\n\t\t\t!Array.isArray(entry) ||\n\t\t\ttypeof entry[0] !== \"string\" ||\n\t\t\t(entry.length === 2 ? typeof entry[1] !== \"string\" : entry.length !== 1)\n\t\t) {\n\t\t\tthrow new BridgeError(\"store writes contain a malformed entry\");\n\t\t}\n\t\tconst [key, value] = entry as [string, string?];\n\t\tif (value === undefined) writes.delete.push(key);\n\t\telse writes.set[key] = parseBridgeJson(value, `store value for ${JSON.stringify(key)}`);\n\t}\n\treturn writes;\n}\n\nfunction parseScriptError(json: string): CodemodeError {\n\tconst parsed = parseBridgeJson(json, \"script error\");\n\tif (typeof parsed !== \"object\" || parsed === null) throw new BridgeError(\"script error is not an object\");\n\tconst { name, message, stack } = parsed as Record<string, unknown>;\n\tif (\n\t\ttypeof message !== \"string\" ||\n\t\t(name !== undefined && typeof name !== \"string\") ||\n\t\t(stack !== undefined && typeof stack !== \"string\")\n\t) {\n\t\tthrow new BridgeError(\"script error is malformed\");\n\t}\n\treturn { kind: \"script\", name, message, stack };\n}\n\ninterface PendingCall {\n\trecord: CodemodeCall | undefined;\n\tstartedAt: number;\n\tcontroller: AbortController;\n}\n\n/** Checks global names: identifiers or `namespace.member`, not shadowing a built-in global or each other. */\nfunction checkGlobals(globals: readonly CodemodeDeclaredGlobal[]): void {\n\tconst names = new Set<string>();\n\tconst namespaces = new Set<string>();\n\tfor (const global of globals) {\n\t\tconst parts = global.name.split(\".\");\n\t\tif (parts.length > 2 || !parts.every((part) => IDENTIFIER.test(part)) || RESERVED_GLOBALS.has(parts[0])) {\n\t\t\tthrow new Error(`Invalid global name \"${global.name}\"`);\n\t\t}\n\t\tif (names.has(global.name)) throw new Error(`Global \"${global.name}\" is already registered`);\n\t\tif (parts.length === 2) namespaces.add(parts[0]);\n\t\tnames.add(global.name);\n\t}\n\tfor (const name of namespaces) {\n\t\tif (names.has(name)) throw new Error(`Global \"${name}\" conflicts with the namespace \"${name}\"`);\n\t}\n}\n\n/** Callbacks of a host-controlled run: its calls go to the caller, which answers them with `deliver()`. */\ntype Control = Pick<CodemodeRunOptions, \"onStarted\" | \"onCall\" | \"onIdle\">;\n\ninterface ExecutionOptions {\n\tcode: string;\n\ttools: readonly CodemodeDeclaredTool[];\n\tglobals: readonly CodemodeDeclaredGlobal[];\n\t/** Run the script's calls; unused when `control` is set. */\n\texecutors: { tools: ReadonlyMap<string, CodemodeTool>; globals: ReadonlyMap<string, CodemodeTool> };\n\ttimeoutMs: number;\n\tsignal: AbortSignal | undefined;\n\tmemoryLimitBytes: number | undefined;\n\tstore: Record<string, string>;\n\tdeterministic?: { startedAt: number; seed: number };\n\tcontrol?: Control;\n\tlaunch: VmLauncher;\n}\n\n/** One script run in its own VM. */\nclass Execution {\n\treadonly promise: Promise<CodemodeResult>;\n\tprivate resolveResult!: (result: CodemodeResult) => void;\n\tprivate channel: VmChannel | undefined;\n\t/** Replies produced before the launcher returned the channel. */\n\tprivate unsent: HostToWorkerMessage[] = [];\n\tprivate readonly executors: ExecutionOptions[\"executors\"];\n\tprivate readonly control: Control | undefined;\n\t/** Result numbers `deliver()` used. */\n\tprivate readonly delivered = new Set<number>();\n\tprivate readonly signal: AbortSignal | undefined;\n\tprivate readonly timer: ReturnType<typeof setTimeout> | undefined;\n\tprivate readonly output: CodemodeOutputItem[] = [];\n\tprivate readonly calls: CodemodeCall[] = [];\n\tprivate readonly pending = new Map<number, PendingCall>();\n\t/** Whether the execution has its outcome. */\n\tfinished = false;\n\n\tconstructor(options: ExecutionOptions) {\n\t\tthis.promise = new Promise<CodemodeResult>((resolve) => {\n\t\t\tthis.resolveResult = resolve;\n\t\t});\n\t\tthis.executors = options.executors;\n\t\tthis.control = options.control;\n\t\tthis.signal = options.signal;\n\n\t\tif (Number.isFinite(options.timeoutMs)) {\n\t\t\tthis.timer = setTimeout(() => {\n\t\t\t\tthis.finish({ kind: \"timeout\", message: `Execution timed out after ${options.timeoutMs} ms` });\n\t\t\t}, options.timeoutMs);\n\t\t}\n\n\t\tif (options.signal) {\n\t\t\tif (options.signal.aborted) {\n\t\t\t\tthis.onAbort();\n\t\t\t} else {\n\t\t\t\toptions.signal.addEventListener(\"abort\", this.onAbort, { once: true });\n\t\t\t}\n\t\t}\n\t\tif (this.finished) return;\n\n\t\tconst data: VmStartData = {\n\t\t\tcode: options.code,\n\t\t\ttools: options.tools.map((tool) => ({\n\t\t\t\tname: tool.name,\n\t\t\t\tjsName: tool.jsName ?? toCodemodeIdentifier(tool.name),\n\t\t\t\tdescription: tool.description ?? \"\",\n\t\t\t})),\n\t\t\tglobals: options.globals.map((global) => ({ name: global.name, spread: global.spread === true })),\n\t\t\tmemoryLimitBytes: options.memoryLimitBytes,\n\t\t\tstore: options.store,\n\t\t\t...(options.deterministic ? { deterministic: options.deterministic } : {}),\n\t\t};\n\t\tconst events: VmEvents = {\n\t\t\tmessage: (message) => this.receive(message),\n\t\t\tfailure: (error) => this.finish(error),\n\t\t};\n\t\tnew Promise<VmChannel>((resolve) => resolve(options.launch(data, events))).then(\n\t\t\t(channel) => {\n\t\t\t\tif (this.finished) {\n\t\t\t\t\tvoid channel.stop().catch(() => undefined);\n\t\t\t\t\treturn;\n\t\t\t\t}\n\t\t\t\tthis.channel = channel;\n\t\t\t\tfor (const message of this.unsent.splice(0)) channel.post(message);\n\t\t\t},\n\t\t\t(error: unknown) => {\n\t\t\t\tthis.finish({ kind: \"sandbox\", message: errorMessage(error) });\n\t\t\t},\n\t\t);\n\t}\n\n\t/** `CodemodeRun.deliver()`. */\n\tdeliver(seq: number, now: number, id: number, outcome: CodemodeOutcome): void {\n\t\tif (this.finished) return;\n\t\tif (!Number.isFinite(now)) throw new Error(`The clock value of result ${seq} is not a finite number`);\n\t\tif (!Number.isInteger(seq) || seq < 1 || this.delivered.has(seq)) {\n\t\t\tthrow new Error(`Result number ${seq} is not a positive integer used once`);\n\t\t}\n\t\tconst pending = this.pending.get(id);\n\t\tif (pending === undefined) throw new Error(`Call ${id} is not waiting for a result`);\n\t\tif (!outcome.ok && outcome.properties !== undefined) {\n\t\t\tconst { properties } = outcome;\n\t\t\tif (typeof properties !== \"object\" || properties === null || Array.isArray(properties)) {\n\t\t\t\tthrow new Error(`The properties of result ${seq} are not an object`);\n\t\t\t}\n\t\t}\n\t\t// Serialized before anything is recorded, so a value JSON cannot hold leaves the call waiting for another answer.\n\t\tconst payload = outcome.ok\n\t\t\t? outcome.value === undefined\n\t\t\t\t? undefined\n\t\t\t\t: JSON.stringify(outcome.value)\n\t\t\t: outcome.message;\n\t\tconst properties =\n\t\t\t!outcome.ok && outcome.properties !== undefined ? JSON.stringify(outcome.properties) : undefined;\n\t\tthis.delivered.add(seq);\n\t\tthis.pending.delete(id);\n\t\tif (pending.record) {\n\t\t\tpending.record.status = outcome.ok ? \"ok\" : \"error\";\n\t\t\tpending.record.durationMs = performance.now() - pending.startedAt;\n\t\t}\n\t\tthis.post({\n\t\t\ttype: \"result\",\n\t\t\tid,\n\t\t\tok: outcome.ok,\n\t\t\tpayload,\n\t\t\tseq,\n\t\t\tnow,\n\t\t\t...(properties === undefined ? {} : { properties }),\n\t\t});\n\t}\n\n\tabort(message: string): Promise<CodemodeResult> {\n\t\tthis.finish({ kind: \"aborted\", message });\n\t\treturn this.promise;\n\t}\n\n\tprivate readonly onAbort = (): void => {\n\t\tconst reason: unknown = this.signal?.reason;\n\t\tthis.finish({ kind: \"aborted\", message: reason instanceof Error ? reason.message : \"Execution aborted\" });\n\t};\n\n\tprivate post(message: HostToWorkerMessage): void {\n\t\tif (this.channel) this.channel.post(message);\n\t\telse this.unsent.push(message);\n\t}\n\n\t/** An exception here would escape into the launcher's transport and leave the execution unsettled. */\n\tprivate receive(message: unknown): void {\n\t\ttry {\n\t\t\tthis.handleMessage(message);\n\t\t} catch (error) {\n\t\t\tthis.finish({\n\t\t\t\tkind: \"sandbox\",\n\t\t\t\tmessage:\n\t\t\t\t\terror instanceof BridgeError\n\t\t\t\t\t\t? `Sandbox bridge broken: ${error.message}. The script may have modified built-ins such as a prototype's toJSON.`\n\t\t\t\t\t\t: `Sandbox host failed: ${errorMessage(error)}`,\n\t\t\t});\n\t\t}\n\t}\n\n\tprivate handleMessage(message: unknown): void {\n\t\tif (this.finished) return;\n\t\tif (!isWorkerToHostMessage(message)) throw new BridgeError(\"unknown message from the worker\");\n\t\tswitch (message.type) {\n\t\t\tcase \"output\":\n\t\t\t\tthis.output.push(message.item);\n\t\t\t\tbreak;\n\t\t\tcase \"call\":\n\t\t\t\tif (this.pending.has(message.id)) throw new BridgeError(`duplicate call id ${message.id}`);\n\t\t\t\tif (this.control) this.forwardCall(message, this.control);\n\t\t\t\telse void this.handleCall(message);\n\t\t\t\tbreak;\n\t\t\tcase \"started\":\n\t\t\t\tthis.control?.onStarted?.(message.fingerprint);\n\t\t\t\tbreak;\n\t\t\tcase \"idle\":\n\t\t\t\tthis.control?.onIdle?.(message.seq, message.issued);\n\t\t\t\tbreak;\n\t\t\tcase \"done\":\n\t\t\t\tthis.handleDone(message);\n\t\t\t\tbreak;\n\t\t\tcase \"crash\":\n\t\t\t\tthis.finish({ kind: \"sandbox\", message: message.message });\n\t\t\t\tbreak;\n\t\t}\n\t}\n\n\tprivate handleDone(message: Extract<WorkerToHostMessage, { type: \"done\" }>): void {\n\t\t// Decode everything before finish(), which must not throw once it starts.\n\t\tif (!message.ok) {\n\t\t\tthis.finish(parseScriptError(message.error), undefined, undefined, message.during);\n\t\t\treturn;\n\t\t}\n\t\tconst value = message.value === undefined ? undefined : parseBridgeJson(message.value, \"return value\");\n\t\tthis.finish(undefined, value, parseStoreWrites(message.writes), message.during);\n\t}\n\n\t/** A host-controlled run: record the call and hand it to the caller, which answers with `deliver()`. */\n\tprivate forwardCall(message: Extract<WorkerToHostMessage, { type: \"call\" }>, control: Control): void {\n\t\tconst { id, name, target } = message;\n\t\tconst args = message.args === undefined ? undefined : parseBridgeJson(message.args, \"call arguments\");\n\t\tconst record: CodemodeCall | undefined =\n\t\t\ttarget === \"tool\" ? { name, status: \"cancelled\", durationMs: 0 } : undefined;\n\t\tif (record) this.calls.push(record);\n\t\tthis.pending.set(id, { record, startedAt: performance.now(), controller: new AbortController() });\n\t\tcontrol.onCall({ id, target, name, args });\n\t}\n\n\tprivate async handleCall(message: Extract<WorkerToHostMessage, { type: \"call\" }>): Promise<void> {\n\t\tconst { id, name } = message;\n\t\tconst isTool = message.target === \"tool\";\n\t\tconst record: CodemodeCall | undefined = isTool ? { name, status: \"cancelled\", durationMs: 0 } : undefined;\n\t\tif (record) this.calls.push(record);\n\t\tconst pending: PendingCall = { record, startedAt: performance.now(), controller: new AbortController() };\n\t\tthis.pending.set(id, pending);\n\n\t\tlet status: CodemodeCallStatus;\n\t\tlet reply: HostToWorkerMessage;\n\t\ttry {\n\t\t\tconst tool = (isTool ? this.executors.tools : this.executors.globals).get(name);\n\t\t\tif (!tool) throw new Error(`Unknown ${isTool ? \"tool\" : \"global\"} \"${name}\"`);\n\t\t\tconst args: unknown = message.args === undefined ? undefined : JSON.parse(message.args);\n\t\t\tconst value = await tool.execute(args, { signal: pending.controller.signal });\n\t\t\treply = { type: \"result\", id, ok: true, payload: value === undefined ? undefined : JSON.stringify(value) };\n\t\t\tstatus = \"ok\";\n\t\t} catch (error) {\n\t\t\treply = { type: \"result\", id, ok: false, payload: errorMessage(error) };\n\t\t\tstatus = \"error\";\n\t\t}\n\n\t\t// Already cancelled by finish(): the record keeps \"cancelled\" and the\n\t\t// VM is gone or going.\n\t\tif (!this.pending.delete(id)) return;\n\t\tif (record) {\n\t\t\trecord.status = status;\n\t\t\trecord.durationMs = performance.now() - pending.startedAt;\n\t\t}\n\t\tthis.post(reply);\n\t}\n\n\tprivate finish(\n\t\terror: CodemodeError | undefined,\n\t\tvalue?: unknown,\n\t\twrites?: CodemodeStoreWrites,\n\t\tduring?: CodemodeDuring,\n\t): void {\n\t\tif (this.finished) return;\n\t\tthis.finished = true;\n\t\tclearTimeout(this.timer);\n\t\tthis.signal?.removeEventListener(\"abort\", this.onAbort);\n\n\t\tconst now = performance.now();\n\t\tfor (const pending of this.pending.values()) {\n\t\t\tif (pending.record) pending.record.durationMs = now - pending.startedAt;\n\t\t\tpending.controller.abort();\n\t\t}\n\t\tthis.pending.clear();\n\t\tthis.unsent = [];\n\n\t\tconst ended = during === undefined ? {} : { during: { seq: during.seq, issued: during.issued } };\n\t\tconst result: CodemodeResult = error\n\t\t\t? { ok: false, error, output: this.output, calls: this.calls, ...ended }\n\t\t\t: {\n\t\t\t\t\tok: true,\n\t\t\t\t\tvalue,\n\t\t\t\t\toutput: this.output,\n\t\t\t\t\tcalls: this.calls,\n\t\t\t\t\tstoreWrites: writes ?? { set: {}, delete: [] },\n\t\t\t\t\t...ended,\n\t\t\t\t};\n\t\tif (!this.channel) {\n\t\t\tthis.resolveResult(result);\n\t\t\treturn;\n\t\t}\n\t\tthis.channel\n\t\t\t.stop()\n\t\t\t.catch(() => undefined)\n\t\t\t.then(() => this.resolveResult(result));\n\t}\n}\n\n/**\n * Tool table, defaults, and in-flight executions; the behavior every sandbox shares. Subclasses\n * only choose where the VM runs by passing a {@link VmLauncher}.\n *\n * The script sees `tools.<name>(args)` for every registered tool, `ALL_TOOLS`, the output helpers\n * `text`, `image`, `exit`, and `console.*`, `store`/`load`, and the configured globals; nothing\n * else (no timers, `fetch`, `process`, `require`, modules). Each `execute()` gets its own VM; the\n * sandbox only holds the tool table and defaults. `close()` aborts in-flight executions.\n */\nexport class CodemodeSandboxBase {\n\tprivate readonly toolsByName = new Map<string, CodemodeTool>();\n\tprivate readonly globalsByName = new Map<string, CodemodeTool>();\n\tprivate readonly timeoutMs: number;\n\tprivate readonly memoryLimitBytes: number | undefined;\n\tprivate readonly launch: VmLauncher;\n\tprivate readonly running = new Set<Execution>();\n\tprivate closed = false;\n\n\tconstructor(options: CodemodeSandboxBaseOptions, launch: VmLauncher) {\n\t\tthis.timeoutMs = options.timeoutMs ?? DEFAULT_TIMEOUT_MS;\n\t\tthis.memoryLimitBytes = options.memoryLimitBytes;\n\t\tthis.launch = launch;\n\t\tfor (const tool of options.tools ?? []) this.registerTool(tool);\n\t\tcheckGlobals(options.globals ?? []);\n\t\tfor (const global of options.globals ?? []) this.globalsByName.set(global.name, global);\n\t}\n\n\t/** Throws if a tool with the same name is already registered. */\n\tregisterTool(tool: CodemodeTool): void {\n\t\tif (this.toolsByName.has(tool.name)) throw new Error(`Tool \"${tool.name}\" is already registered`);\n\t\tthis.toolsByName.set(tool.name, tool);\n\t}\n\n\tunregisterTool(name: string): boolean {\n\t\treturn this.toolsByName.delete(name);\n\t}\n\n\tget tools(): CodemodeTool[] {\n\t\treturn [...this.toolsByName.values()];\n\t}\n\n\tget globals(): CodemodeTool[] {\n\t\treturn [...this.globalsByName.values()];\n\t}\n\n\t/**\n\t * `code` is an async function body: `return` and top-level `await` work.\n\t * Never rejects for script failures; those come back as `{ ok: false }`.\n\t * The script can use `store(key, value)` and `load(key)` on `options.store`.\n\t */\n\texecute(code: string, options: CodemodeExecuteOptions = {}): Promise<CodemodeResult> {\n\t\tif (this.closed) return Promise.reject(new Error(\"Sandbox is closed\"));\n\t\tconst tools = new Map(this.toolsByName);\n\t\tconst execution = new Execution({\n\t\t\tcode,\n\t\t\ttools: [...tools.values()],\n\t\t\tglobals: [...this.globalsByName.values()],\n\t\t\texecutors: { tools, globals: this.globalsByName },\n\t\t\ttimeoutMs: options.timeoutMs ?? this.timeoutMs,\n\t\t\tsignal: options.signal,\n\t\t\tmemoryLimitBytes: this.memoryLimitBytes,\n\t\t\tstore: serializeStore(options.store),\n\t\t\tlaunch: this.launch,\n\t\t});\n\t\tthis.running.add(execution);\n\t\treturn execution.promise.finally(() => this.running.delete(execution));\n\t}\n\n\t/**\n\t * Run `code` deterministically, with the caller answering its calls: the same script, start time, seed, tools,\n\t * globals, and store, answered with the same results in the same `seq` order, makes the same calls with the same\n\t * arguments and produces the same output, on any VM with the same fingerprint. A host can therefore replay it\n\t * after a restart. The VM runs in UTC, its clock reads `startedAt` and then the `now` of the result being\n\t * processed, its randomness comes from `seed`, and `WeakRef` and `FinalizationRegistry` do not exist.\n\t *\n\t * The sandbox's own tools and globals are not used: the run declares its own, and every call goes to\n\t * `options.onCall`. Never rejects for script failures; abort through `options.signal` to end the run with an\n\t * error the script cannot catch.\n\t */\n\tstart(code: string, options: CodemodeRunOptions): CodemodeRun {\n\t\tif (this.closed) throw new Error(\"Sandbox is closed\");\n\t\tif (!Number.isFinite(options.startedAt) || options.startedAt < 0) {\n\t\t\tthrow new Error(\"startedAt must be a non-negative number of milliseconds since the epoch\");\n\t\t}\n\t\tif (!Number.isInteger(options.seed) || options.seed < 0 || options.seed > 0xffffffff) {\n\t\t\tthrow new Error(\"seed must be a 32-bit unsigned integer\");\n\t\t}\n\t\tconst tools = options.tools ?? [];\n\t\tif (new Set(tools.map((tool) => tool.name)).size !== tools.length) throw new Error(\"Tool names must be unique\");\n\t\tconst scriptNames = tools.map((tool) => tool.jsName ?? toCodemodeIdentifier(tool.name));\n\t\tif (new Set(scriptNames).size !== tools.length) throw new Error(\"Tool script names must be unique\");\n\t\tconst globals = options.globals ?? [];\n\t\tcheckGlobals(globals);\n\t\tconst execution = new Execution({\n\t\t\tcode,\n\t\t\ttools,\n\t\t\tglobals,\n\t\t\texecutors: { tools: new Map(), globals: new Map() },\n\t\t\ttimeoutMs: options.timeoutMs ?? Number.POSITIVE_INFINITY,\n\t\t\tsignal: options.signal,\n\t\t\tmemoryLimitBytes: this.memoryLimitBytes,\n\t\t\tstore: serializeStore(options.store),\n\t\t\tdeterministic: { startedAt: options.startedAt, seed: options.seed },\n\t\t\tcontrol: { onStarted: options.onStarted, onCall: options.onCall, onIdle: options.onIdle },\n\t\t\tlaunch: this.launch,\n\t\t});\n\t\tthis.running.add(execution);\n\t\tconst result = execution.promise.finally(() => this.running.delete(execution));\n\t\treturn {\n\t\t\tresult,\n\t\t\tdeliver: (seq, now, id, outcome) => execution.deliver(seq, now, id, outcome),\n\t\t\tget finished() {\n\t\t\t\treturn execution.finished;\n\t\t\t},\n\t\t};\n\t}\n\n\t/** Aborts in-flight executions (they resolve with `kind: \"aborted\"`) and rejects new ones. */\n\tasync close(): Promise<void> {\n\t\tthis.closed = true;\n\t\tawait Promise.all([...this.running].map((execution) => execution.abort(\"Sandbox closed\")));\n\t}\n}\n"]}
@@ -0,0 +1,13 @@
1
+ import type { CodemodeSandboxOptions } from "../types.ts";
2
+ import { CodemodeSandboxBase } from "./execution.ts";
3
+ /**
4
+ * Runs JavaScript in a QuickJS VM (a separate wasm instance) inside a worker thread. The worker
5
+ * keeps script execution off the host thread: QuickJS runs synchronously, so a spinning script on
6
+ * the host thread would block its event loop. Requires `node:worker_threads` (Node or Bun); see
7
+ * `InlineCodemodeSandbox` and `RemoteCodemodeSandbox` in `@earendil-works/pi-codemode/portable`
8
+ * for other runtimes.
9
+ */
10
+ export declare class CodemodeSandbox extends CodemodeSandboxBase {
11
+ constructor(options?: CodemodeSandboxOptions);
12
+ }
13
+ //# sourceMappingURL=host.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"host.d.ts","sourceRoot":"","sources":["../../src/runtime/host.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,sBAAsB,EAAE,MAAM,aAAa,CAAC;AAE1D,OAAO,EAAE,mBAAmB,EAAiC,MAAM,gBAAgB,CAAC;AAgEpF;;;;;;GAMG;AACH,qBAAa,eAAgB,SAAQ,mBAAmB;IACvD,YAAY,OAAO,GAAE,sBAA2B,EAE/C;CACD"}