@qitqode/qitqode-android-arm64 0.1.22 → 0.1.23

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 (383) hide show
  1. package/bundle/{chunk-mbmc1mg0.js → chunk-0136n3jt.js} +1 -1
  2. package/bundle/{chunk-wm3b050v.js → chunk-05badzhy.js} +1 -1
  3. package/bundle/{chunk-p64fb4rm.js → chunk-07szgr15.js} +1 -1
  4. package/bundle/{chunk-jtbf88gw.js → chunk-0svy8w30.js} +2 -2
  5. package/bundle/{chunk-c88rh38d.js → chunk-0vhsc0yh.js} +1 -1
  6. package/bundle/{chunk-y0fxwgrv.js → chunk-101y7ce2.js} +1 -1
  7. package/bundle/{chunk-x6gzygc3.js → chunk-12cd1yj9.js} +1 -1
  8. package/bundle/chunk-1by6y9tm.js +2 -0
  9. package/bundle/{chunk-fkdbba26.js → chunk-1eg8mr1q.js} +1 -1
  10. package/bundle/{chunk-cx0z3mm3.js → chunk-1gg4c0pq.js} +1 -1
  11. package/bundle/{chunk-cckshvkb.js → chunk-1gjh45v5.js} +1 -1
  12. package/bundle/chunk-1p7wqmxp.js +2 -0
  13. package/bundle/{chunk-th189x63.js → chunk-1v47v7vm.js} +1 -1
  14. package/bundle/{chunk-zt8kghd2.js → chunk-1vx26nt2.js} +1 -1
  15. package/bundle/{chunk-ee5r4h0v.js → chunk-1w8b88y5.js} +1 -1
  16. package/bundle/{chunk-mt8zem33.js → chunk-21hnx8rx.js} +1 -1
  17. package/bundle/chunk-22pvftx8.js +2 -0
  18. package/bundle/{chunk-j2k4wxsk.js → chunk-22tf95dw.js} +1 -1
  19. package/bundle/{chunk-hrnx60em.js → chunk-22vvjp4g.js} +2 -2
  20. package/bundle/{chunk-3nc9wy1m.js → chunk-24r5h0fx.js} +2 -2
  21. package/bundle/{chunk-kywg73qz.js → chunk-26m5yn5d.js} +1 -1
  22. package/bundle/{chunk-n4spe0sv.js → chunk-26mt118z.js} +1 -1
  23. package/bundle/{chunk-t2n6fmpy.js → chunk-29hmwttd.js} +2 -2
  24. package/bundle/{chunk-abc7ccfd.js → chunk-2adsn1ca.js} +1 -1
  25. package/bundle/chunk-2bce1njy.js +2 -0
  26. package/bundle/{chunk-6hkv9411.js → chunk-2e76kpa6.js} +1 -1
  27. package/bundle/{chunk-7276th89.js → chunk-2e9a9brg.js} +1 -1
  28. package/bundle/{chunk-ne8ftsv3.js → chunk-2es79khv.js} +3 -3
  29. package/bundle/{chunk-6v4mhtha.js → chunk-2qj66wf5.js} +1 -1
  30. package/bundle/{chunk-x1naayst.js → chunk-2qy760rf.js} +1 -1
  31. package/bundle/{chunk-3f6t3wde.js → chunk-2wcwbp3t.js} +152 -152
  32. package/bundle/{chunk-6pe3xzkk.js → chunk-338hbnza.js} +1 -1
  33. package/bundle/{chunk-5a80qybt.js → chunk-36c2avm4.js} +1 -1
  34. package/bundle/{chunk-9fdv5d8a.js → chunk-381j1hqf.js} +1 -1
  35. package/bundle/{chunk-y2tnzn1y.js → chunk-3cpqdake.js} +1 -1
  36. package/bundle/chunk-3gsvbfqz.js +2 -0
  37. package/bundle/chunk-3j6nrrva.js +4 -0
  38. package/bundle/{chunk-9g05wsae.js → chunk-3ne6j2h5.js} +1 -1
  39. package/bundle/{chunk-b5h8vd5n.js → chunk-3sem578c.js} +1 -1
  40. package/bundle/{chunk-cm31dbwq.js → chunk-3vgnqaem.js} +1 -1
  41. package/bundle/{chunk-c9afcdba.js → chunk-3w9k7yxx.js} +1 -1
  42. package/bundle/{chunk-xtjsfqam.js → chunk-3wzpdvpg.js} +1 -1
  43. package/bundle/{chunk-fyd31m33.js → chunk-3xf7q4ww.js} +1 -1
  44. package/bundle/chunk-3xrhxyz9.js +2 -0
  45. package/bundle/chunk-3zdyrnvp.js +2 -0
  46. package/bundle/{chunk-73d0dy03.js → chunk-44amvtcs.js} +1 -1
  47. package/bundle/chunk-4nhbgva1.js +2 -0
  48. package/bundle/{chunk-1zb95qfx.js → chunk-576zfh1s.js} +1 -1
  49. package/bundle/{chunk-n1wawwry.js → chunk-58w4dhb6.js} +1 -1
  50. package/bundle/chunk-5ch23jj3.js +2 -0
  51. package/bundle/{chunk-rvz05kxy.js → chunk-5d18fd4p.js} +1 -1
  52. package/bundle/{chunk-8x6x3g16.js → chunk-5dpev64z.js} +1 -1
  53. package/bundle/chunk-5hzkd9te.js +2 -0
  54. package/bundle/{chunk-t813v629.js → chunk-5vwhfa42.js} +1 -1
  55. package/bundle/{chunk-gzwcj7c9.js → chunk-5vyper2h.js} +1 -1
  56. package/bundle/{chunk-bjw39da9.js → chunk-5wr5gpaa.js} +1 -1
  57. package/bundle/{chunk-xjdxyeja.js → chunk-5x19yah0.js} +1 -1
  58. package/bundle/{chunk-zfw873yt.js → chunk-62yja34m.js} +1 -1
  59. package/bundle/{chunk-h9ftcgs2.js → chunk-63pvqy8n.js} +3 -3
  60. package/bundle/chunk-662x3gq6.js +2 -0
  61. package/bundle/{chunk-xa0f5g9z.js → chunk-6an0pk19.js} +1 -1
  62. package/bundle/{chunk-4gfryje2.js → chunk-6j07cgna.js} +1 -1
  63. package/bundle/chunk-6ybqwnp7.js +2 -0
  64. package/bundle/{chunk-4se8cbmb.js → chunk-70gfpkxv.js} +1 -1
  65. package/bundle/chunk-7365jzj1.js +2 -0
  66. package/bundle/{chunk-x1dfc7qd.js → chunk-799c17nk.js} +1 -1
  67. package/bundle/chunk-7amvpgng.js +2 -0
  68. package/bundle/{chunk-68jsyydc.js → chunk-7bxe5s20.js} +1 -1
  69. package/bundle/chunk-7dcz5ytp.js +2 -0
  70. package/bundle/chunk-7h7bwjmm.js +2 -0
  71. package/bundle/{chunk-ck65rcxb.js → chunk-7m4camry.js} +1 -1
  72. package/bundle/{chunk-vpp88hhd.js → chunk-7n994qss.js} +209 -209
  73. package/bundle/{chunk-s1mx3bkw.js → chunk-7pr4jxkn.js} +1 -1
  74. package/bundle/{chunk-98nh88th.js → chunk-7tb9fjvq.js} +2 -2
  75. package/bundle/{chunk-dgsg31vm.js → chunk-7tthc48p.js} +1 -1
  76. package/bundle/chunk-7vk5fhhv.js +2 -0
  77. package/bundle/chunk-7vqw9wge.js +2 -0
  78. package/bundle/chunk-7vxk5t11.js +2 -0
  79. package/bundle/{chunk-xz7dccwp.js → chunk-83fm5xcn.js} +1 -1
  80. package/bundle/{chunk-awdpkgxf.js → chunk-863s0tqa.js} +1 -1
  81. package/bundle/{chunk-3degq6rv.js → chunk-87pzwjjj.js} +3 -3
  82. package/bundle/{chunk-78wt9ad8.js → chunk-88kt6qmd.js} +1 -1
  83. package/bundle/chunk-8b644ae2.js +2 -0
  84. package/bundle/{chunk-mbkw9s6e.js → chunk-8e2wwdgb.js} +1 -1
  85. package/bundle/{chunk-hmm1m733.js → chunk-8hh5ejmr.js} +2 -2
  86. package/bundle/{chunk-y3x5m3e8.js → chunk-8k4mkrdw.js} +1 -1
  87. package/bundle/{chunk-j6cpsxva.js → chunk-9jjjzmvn.js} +1 -1
  88. package/bundle/{chunk-8r4xs1q9.js → chunk-9n6f9n1c.js} +1 -1
  89. package/bundle/{chunk-pp44xnd7.js → chunk-9tq5yt3t.js} +1 -1
  90. package/bundle/{chunk-qq9pvscd.js → chunk-9y65kbcf.js} +2 -2
  91. package/bundle/{chunk-vqxyph4q.js → chunk-9yaw0hbp.js} +1 -1
  92. package/bundle/{chunk-18xhxdsh.js → chunk-9zg3y89v.js} +1 -1
  93. package/bundle/{chunk-bbznk59q.js → chunk-a3te67a5.js} +2 -2
  94. package/bundle/{chunk-h7rxnbf0.js → chunk-ac69b9tm.js} +1 -1
  95. package/bundle/{chunk-50aznc8e.js → chunk-afpwjn78.js} +2 -2
  96. package/bundle/{chunk-6r4gn18m.js → chunk-agx5m1ev.js} +1 -1
  97. package/bundle/{chunk-en7nxqvn.js → chunk-agyxa9nj.js} +1 -1
  98. package/bundle/{chunk-61ndvjmm.js → chunk-an5sr6gw.js} +1 -1
  99. package/bundle/{chunk-2p6w3w8f.js → chunk-apv1v4tk.js} +2 -2
  100. package/bundle/{chunk-n9gzj085.js → chunk-ar1by07g.js} +1 -1
  101. package/bundle/chunk-av2q0ffj.js +2 -0
  102. package/bundle/{chunk-bn6mg34g.js → chunk-avk3wfch.js} +2 -2
  103. package/bundle/{chunk-n68xjm4p.js → chunk-ax9yyznf.js} +1 -1
  104. package/bundle/chunk-azna4wdf.js +2 -0
  105. package/bundle/chunk-b192q4m0.js +2 -0
  106. package/bundle/{chunk-b5x3zghc.js → chunk-b2k9yafd.js} +2 -2
  107. package/bundle/{chunk-fjtq8164.js → chunk-b8z4hgq0.js} +1 -1
  108. package/bundle/chunk-bh46627y.js +2 -0
  109. package/bundle/{chunk-6w15nfph.js → chunk-bkaprkf6.js} +1 -1
  110. package/bundle/{chunk-0ddhkapd.js → chunk-bqeyh2gx.js} +2 -2
  111. package/bundle/{chunk-tcp31yv0.js → chunk-brrtcqrc.js} +1 -1
  112. package/bundle/{chunk-m79gd4yt.js → chunk-bwgnmy92.js} +1 -1
  113. package/bundle/{chunk-1eqcgkyq.js → chunk-bwvjft74.js} +1 -1
  114. package/bundle/chunk-c267ggx2.js +2 -0
  115. package/bundle/{chunk-60dxyp37.js → chunk-c38ppnm8.js} +1 -1
  116. package/bundle/{chunk-4xpfmpjf.js → chunk-c546xxjk.js} +1 -1
  117. package/bundle/chunk-c6kxegws.js +2 -0
  118. package/bundle/{chunk-w8xaw2dv.js → chunk-c7dt464m.js} +1 -1
  119. package/bundle/{chunk-ha5qct06.js → chunk-cbfjjbfd.js} +1 -1
  120. package/bundle/chunk-cek3cfz4.js +2 -0
  121. package/bundle/{chunk-x8w2xgx6.js → chunk-cwkdc1cc.js} +1 -1
  122. package/bundle/{chunk-jrwfx6d8.js → chunk-cz8nnm2a.js} +1 -1
  123. package/bundle/{chunk-z9b0ydw1.js → chunk-dn1jryxz.js} +1 -1
  124. package/bundle/{chunk-s4epqtge.js → chunk-dq1wprmb.js} +1 -1
  125. package/bundle/{chunk-dhvwrrqx.js → chunk-dsny9dh8.js} +2 -2
  126. package/bundle/{chunk-db7hykjs.js → chunk-ecczet3b.js} +1 -1
  127. package/bundle/{chunk-qryeqw9s.js → chunk-ejy5404v.js} +1 -1
  128. package/bundle/{chunk-qwf258sw.js → chunk-eqed7tvt.js} +1 -1
  129. package/bundle/{chunk-ht1hqsaa.js → chunk-erh9y0sx.js} +1 -1
  130. package/bundle/{chunk-skjx57kv.js → chunk-ete0y35c.js} +1 -1
  131. package/bundle/{chunk-qe8zp79w.js → chunk-f1mmzzsn.js} +1 -1
  132. package/bundle/chunk-f66cvq2q.js +2 -0
  133. package/bundle/{chunk-bdzgtazc.js → chunk-f958hsha.js} +1 -1
  134. package/bundle/{chunk-2bbvvh0d.js → chunk-febbrhev.js} +1 -1
  135. package/bundle/{chunk-j1kqhxnq.js → chunk-fhjpfzjc.js} +1 -1
  136. package/bundle/{chunk-c2w3bqsa.js → chunk-fnect0ny.js} +1 -1
  137. package/bundle/{chunk-t7v8wzr9.js → chunk-fp5mvrrx.js} +2 -2
  138. package/bundle/chunk-fq4v97xn.js +2 -0
  139. package/bundle/{chunk-6nhgkw5r.js → chunk-fvwys8ej.js} +1 -1
  140. package/bundle/{chunk-dcyzpkww.js → chunk-fw1f6br4.js} +1 -1
  141. package/bundle/{chunk-jee9y4t0.js → chunk-fzzze6zd.js} +1 -1
  142. package/bundle/{chunk-8wzc27e3.js → chunk-g0vzdt58.js} +1 -1
  143. package/bundle/{chunk-hf0gny5t.js → chunk-g2ec45xj.js} +1 -1
  144. package/bundle/chunk-g3pb8rad.js +2 -0
  145. package/bundle/{chunk-3xbtg0hn.js → chunk-g5g9r3v5.js} +1 -1
  146. package/bundle/{chunk-yy91rm3y.js → chunk-g6gs7cc6.js} +1 -1
  147. package/bundle/{chunk-h5wh2d49.js → chunk-g6tw5dvr.js} +1 -1
  148. package/bundle/{chunk-b3x13ndd.js → chunk-g7742sqm.js} +1 -1
  149. package/bundle/{chunk-btjcs9ee.js → chunk-g7g3zm4v.js} +1 -1
  150. package/bundle/{chunk-ymv05pbt.js → chunk-g8zrn0at.js} +1 -1
  151. package/bundle/chunk-gc1yetqd.js +2 -0
  152. package/bundle/{chunk-67wvdfs5.js → chunk-gjsaw7wm.js} +1 -1
  153. package/bundle/chunk-gtckkn15.js +2 -0
  154. package/bundle/chunk-gtzreftf.js +2 -0
  155. package/bundle/{chunk-tepesp0b.js → chunk-gz8x3915.js} +1 -1
  156. package/bundle/{chunk-zy0zn8yx.js → chunk-gzse9pab.js} +1 -1
  157. package/bundle/{chunk-40vz0fhv.js → chunk-hg7kfd0t.js} +1 -1
  158. package/bundle/{chunk-43xq4p51.js → chunk-hk1ha5fj.js} +1 -1
  159. package/bundle/{chunk-jfy6bfvv.js → chunk-hqv0s6sw.js} +1 -1
  160. package/bundle/{chunk-xce77xex.js → chunk-hs8qwx4n.js} +1 -1
  161. package/bundle/{chunk-k19zvbzh.js → chunk-hvcdemxe.js} +1 -1
  162. package/bundle/chunk-j5vahbw1.js +2 -0
  163. package/bundle/{chunk-tq258v8s.js → chunk-jazpapb9.js} +1 -1
  164. package/bundle/chunk-jek1cnfk.js +3 -0
  165. package/bundle/chunk-jevrajsx.js +2 -0
  166. package/bundle/{chunk-m9bc5csy.js → chunk-jge74hh4.js} +1 -1
  167. package/bundle/{chunk-rpy4rgmm.js → chunk-jq6y56m5.js} +1 -1
  168. package/bundle/{chunk-6emme4kp.js → chunk-jvkqvgae.js} +1 -1
  169. package/bundle/chunk-jzdks7bv.js +2 -0
  170. package/bundle/{chunk-hzexvrnj.js → chunk-k0arcqnt.js} +1 -1
  171. package/bundle/{chunk-f72j5yx8.js → chunk-k0v37hc6.js} +1 -1
  172. package/bundle/chunk-k1e7w7w5.js +2 -0
  173. package/bundle/{chunk-5z8gpy3x.js → chunk-k1ht1sjr.js} +1 -1
  174. package/bundle/{chunk-thbjhgw0.js → chunk-k33xx2z9.js} +1 -1
  175. package/bundle/{chunk-496rb1e4.js → chunk-k3pvgwgc.js} +1 -1
  176. package/bundle/{chunk-1123xk5a.js → chunk-k5294ajv.js} +1 -1
  177. package/bundle/chunk-k6vf6vq6.js +2 -0
  178. package/bundle/{chunk-ah9cm91p.js → chunk-kbhby60s.js} +1 -1
  179. package/bundle/{chunk-01gtn79f.js → chunk-kdr6nxmk.js} +2 -2
  180. package/bundle/{chunk-ng85b73s.js → chunk-kfdqfha0.js} +1 -1
  181. package/bundle/{chunk-msqx5bb0.js → chunk-kktcccep.js} +1 -1
  182. package/bundle/chunk-kn391hb2.js +2 -0
  183. package/bundle/{chunk-aznbvrbm.js → chunk-kn9skc0g.js} +1 -1
  184. package/bundle/{chunk-q2weasmk.js → chunk-knmba0q6.js} +1 -1
  185. package/bundle/chunk-knnemqfm.js +3 -0
  186. package/bundle/{chunk-gvj8qg7x.js → chunk-kpkbyek5.js} +2 -2
  187. package/bundle/chunk-kx4b39v6.js +2 -0
  188. package/bundle/{chunk-qafcfb4x.js → chunk-ky840wjj.js} +1 -1
  189. package/bundle/{chunk-7yw60h8j.js → chunk-m34zrf70.js} +1 -1
  190. package/bundle/{chunk-pcctf3gs.js → chunk-m3gsrb1x.js} +1 -1
  191. package/bundle/{chunk-a3a9bbk7.js → chunk-m81z3zgm.js} +1 -1
  192. package/bundle/{chunk-30233h8f.js → chunk-m8njvpb8.js} +1 -1
  193. package/bundle/{chunk-x4c8drpe.js → chunk-m8tfv36b.js} +1 -1
  194. package/bundle/chunk-mah572rs.js +2 -0
  195. package/bundle/{chunk-0qmaxpkv.js → chunk-mg03szpz.js} +1 -1
  196. package/bundle/chunk-mg6nwfw3.js +2 -0
  197. package/bundle/{chunk-30p5pm3w.js → chunk-mj7rk4xs.js} +1 -1
  198. package/bundle/{chunk-jatba8z8.js → chunk-mt8btwrv.js} +1 -1
  199. package/bundle/{chunk-2bxy8zm1.js → chunk-mwbcmvmh.js} +2 -2
  200. package/bundle/{chunk-pqyds00j.js → chunk-mwjhyj53.js} +1 -1
  201. package/bundle/{chunk-0jv8r99k.js → chunk-my0kzcby.js} +6 -6
  202. package/bundle/{chunk-1d6ret10.js → chunk-n889mwgv.js} +1 -1
  203. package/bundle/{chunk-fa03gsff.js → chunk-naq602da.js} +1 -1
  204. package/bundle/{chunk-fssgbz70.js → chunk-nb0gc3sx.js} +1 -1
  205. package/bundle/{chunk-prrrw8t8.js → chunk-ntfh16rj.js} +1 -1
  206. package/bundle/{chunk-x4b0ywbs.js → chunk-p33fchnf.js} +1 -1
  207. package/bundle/chunk-pdgrang4.js +2 -0
  208. package/bundle/{chunk-cpkega70.js → chunk-px15ev1g.js} +1 -1
  209. package/bundle/{chunk-t4c0zy2s.js → chunk-q1472d56.js} +1 -1
  210. package/bundle/{chunk-f8xnn26j.js → chunk-q1nvfmrm.js} +1 -1
  211. package/bundle/{chunk-0vw5a7m9.js → chunk-qkn4039t.js} +1 -1
  212. package/bundle/{chunk-10qkxzhh.js → chunk-qr2ave8f.js} +1 -1
  213. package/bundle/{chunk-mqt5qh3t.js → chunk-qx9j6nz1.js} +1 -1
  214. package/bundle/{chunk-bwyf1bvf.js → chunk-qzd0q1jg.js} +1 -1
  215. package/bundle/{chunk-7hx0pza2.js → chunk-r0sjwtfc.js} +2 -2
  216. package/bundle/chunk-r3q82hz3.js +2 -0
  217. package/bundle/chunk-r4ygs0jv.js +2 -0
  218. package/bundle/chunk-r6xhxvjv.js +2 -0
  219. package/bundle/{chunk-djcsvcby.js → chunk-r79mz5kd.js} +1 -1
  220. package/bundle/chunk-r99pnfra.js +2 -0
  221. package/bundle/{chunk-qxrjbw22.js → chunk-rjjgnvdk.js} +1 -1
  222. package/bundle/{chunk-9hrpcnt8.js → chunk-rmmyjyr9.js} +1 -1
  223. package/bundle/chunk-rq4xdyst.js +2 -0
  224. package/bundle/chunk-rsd3v7cg.js +2 -0
  225. package/bundle/{chunk-n39gqxkz.js → chunk-rwanncah.js} +2 -2
  226. package/bundle/chunk-rxsgbdv0.js +2 -0
  227. package/bundle/chunk-s4x1jhj3.js +2 -0
  228. package/bundle/{chunk-ntmn6epc.js → chunk-s75chpxq.js} +1 -1
  229. package/bundle/{chunk-pkdk0ppc.js → chunk-s7sksztt.js} +2 -2
  230. package/bundle/{chunk-56cty7nr.js → chunk-scb48j07.js} +2 -2
  231. package/bundle/{chunk-fgtyrvan.js → chunk-sgq94p3x.js} +1 -1
  232. package/bundle/{chunk-meaa7wrs.js → chunk-shav33fq.js} +2 -2
  233. package/bundle/{chunk-zz192a31.js → chunk-shxny9x9.js} +1 -1
  234. package/bundle/{chunk-t1f7jeat.js → chunk-sjqgmp12.js} +2 -2
  235. package/bundle/chunk-sx760d9d.js +2 -0
  236. package/bundle/{chunk-351wfvhp.js → chunk-t42kh492.js} +2 -2
  237. package/bundle/{chunk-07b36w5g.js → chunk-t66hycva.js} +1 -1
  238. package/bundle/{chunk-1kje2a6g.js → chunk-t86vj45b.js} +1 -1
  239. package/bundle/{chunk-fzhgxcej.js → chunk-tfpwfczs.js} +1 -1
  240. package/bundle/chunk-tmjd3evp.js +8 -0
  241. package/bundle/chunk-tp1d856p.js +2 -0
  242. package/bundle/chunk-tpxs00p5.js +2 -0
  243. package/bundle/chunk-tqk12r89.js +2 -0
  244. package/bundle/chunk-tycgrqgq.js +2 -0
  245. package/bundle/{chunk-p20ft5mj.js → chunk-tydvpy1s.js} +2 -2
  246. package/bundle/{chunk-rry321tn.js → chunk-v1hvnq7y.js} +1 -1
  247. package/bundle/{chunk-khkv9s5c.js → chunk-v1y3pbfv.js} +1 -1
  248. package/bundle/chunk-v32cyrg2.js +2 -0
  249. package/bundle/chunk-v7pypmvk.js +2 -0
  250. package/bundle/{chunk-mgp034y0.js → chunk-vay29sqp.js} +1 -1
  251. package/bundle/chunk-vbqyddy8.js +2 -0
  252. package/bundle/chunk-vgx86f2r.js +2 -0
  253. package/bundle/{chunk-r8ddb02d.js → chunk-vxc5q0wk.js} +2 -2
  254. package/bundle/chunk-w0jvqdez.js +2 -0
  255. package/bundle/{chunk-2qy62cv4.js → chunk-w32tj884.js} +2 -2
  256. package/bundle/{chunk-8t1whx0k.js → chunk-w6t1qmeg.js} +1 -1
  257. package/bundle/{chunk-aftpj9fe.js → chunk-w6zgm4vn.js} +1 -1
  258. package/bundle/chunk-w79yek40.js +2 -0
  259. package/bundle/chunk-w7nxsfbd.js +3 -0
  260. package/bundle/{chunk-wfb9dwmc.js → chunk-w8r4gjea.js} +1 -1
  261. package/bundle/chunk-w9vv1whr.js +2 -0
  262. package/bundle/chunk-wcea06cr.js +2 -0
  263. package/bundle/chunk-wcx4bbvn.js +2 -0
  264. package/bundle/chunk-wdw183vh.js +2 -0
  265. package/bundle/{chunk-hkmx6w54.js → chunk-wf2mj6de.js} +1 -1
  266. package/bundle/{chunk-jyh2g13j.js → chunk-wk11xsdh.js} +1 -1
  267. package/bundle/chunk-wqd3svh6.js +2 -0
  268. package/bundle/chunk-wqe5spdq.js +2 -0
  269. package/bundle/chunk-wqww2byk.js +2 -0
  270. package/bundle/chunk-wybd806z.js +2 -0
  271. package/bundle/chunk-x1vb00hr.js +2 -0
  272. package/bundle/chunk-xafh07r3.js +2 -0
  273. package/bundle/chunk-xgzjcsad.js +2 -0
  274. package/bundle/{chunk-t8365msg.js → chunk-xjr0xy58.js} +1 -1
  275. package/bundle/{chunk-zbvf09bm.js → chunk-xn0xhd0w.js} +1 -1
  276. package/bundle/chunk-xnbfy5jy.js +2 -0
  277. package/bundle/{chunk-2epf5806.js → chunk-xqzbcs8x.js} +1 -1
  278. package/bundle/{chunk-h6htvj2y.js → chunk-xtj5qqsw.js} +1 -1
  279. package/bundle/chunk-xxed39zx.js +3 -0
  280. package/bundle/{chunk-7w01dxp9.js → chunk-y0qaz8db.js} +1 -1
  281. package/bundle/{chunk-s6qdtfty.js → chunk-y2h0adg5.js} +2 -2
  282. package/bundle/{chunk-adgrn60n.js → chunk-y3qf1kg9.js} +1 -1
  283. package/bundle/{chunk-h725tttx.js → chunk-y62tnk9q.js} +1 -1
  284. package/bundle/{chunk-4qegdkss.js → chunk-y68fp4kt.js} +1 -1
  285. package/bundle/chunk-y6pzag4n.js +2 -0
  286. package/bundle/chunk-y7w6fjwt.js +2 -0
  287. package/bundle/{chunk-a2ty2e0g.js → chunk-yccm7cfm.js} +2 -2
  288. package/bundle/{chunk-5mrjxapq.js → chunk-yffkcska.js} +1 -1
  289. package/bundle/{chunk-mr7ya5kc.js → chunk-ypff4a5n.js} +1 -1
  290. package/bundle/{chunk-anqjy235.js → chunk-yr4evt94.js} +1 -1
  291. package/bundle/{chunk-b1t8d1s8.js → chunk-yyarzhw3.js} +1 -1
  292. package/bundle/chunk-z195gv71.js +2 -0
  293. package/bundle/{chunk-v9sfzkg5.js → chunk-z1hd38wp.js} +1 -1
  294. package/bundle/{chunk-8rcpj28e.js → chunk-z65snfyw.js} +1 -1
  295. package/bundle/{chunk-h99n5rv7.js → chunk-zx90w4mt.js} +1 -1
  296. package/bundle/{chunk-er5q8nhp.js → chunk-zzdbrxkh.js} +1 -1
  297. package/bundle/index.js +3 -3
  298. package/bundle/parser.worker.js +2 -2
  299. package/bundle/worker.js +1 -1
  300. package/package.json +1 -1
  301. package/bundle/chunk-04ezvjjf.js +0 -2
  302. package/bundle/chunk-0msr85tj.js +0 -2
  303. package/bundle/chunk-0qrpg3n8.js +0 -2
  304. package/bundle/chunk-0w8ztgmg.js +0 -2
  305. package/bundle/chunk-0y2nwncb.js +0 -2
  306. package/bundle/chunk-0zh8tykf.js +0 -2
  307. package/bundle/chunk-21z1vfgm.js +0 -2
  308. package/bundle/chunk-2ec8msmq.js +0 -2
  309. package/bundle/chunk-2n5m61m9.js +0 -2
  310. package/bundle/chunk-362z696e.js +0 -2
  311. package/bundle/chunk-367rm03h.js +0 -2
  312. package/bundle/chunk-43k17qzb.js +0 -2
  313. package/bundle/chunk-4r574drd.js +0 -2
  314. package/bundle/chunk-6c2xn1ab.js +0 -2
  315. package/bundle/chunk-6rak9ez9.js +0 -2
  316. package/bundle/chunk-71dbq1d0.js +0 -2
  317. package/bundle/chunk-73r1zvgw.js +0 -2
  318. package/bundle/chunk-7az1bpy8.js +0 -2
  319. package/bundle/chunk-7bm1t462.js +0 -2
  320. package/bundle/chunk-7nq8126b.js +0 -2
  321. package/bundle/chunk-80a0d0js.js +0 -2
  322. package/bundle/chunk-9ac4h2d9.js +0 -2
  323. package/bundle/chunk-9zp746aj.js +0 -2
  324. package/bundle/chunk-a0vpemkf.js +0 -2
  325. package/bundle/chunk-atjzxp7b.js +0 -2
  326. package/bundle/chunk-ax4f4fbm.js +0 -2
  327. package/bundle/chunk-aybmm0jf.js +0 -2
  328. package/bundle/chunk-b2scgkye.js +0 -2
  329. package/bundle/chunk-bbpze4hq.js +0 -2
  330. package/bundle/chunk-c6wrjyep.js +0 -2
  331. package/bundle/chunk-ce3c03mh.js +0 -2
  332. package/bundle/chunk-cqaw6hka.js +0 -2
  333. package/bundle/chunk-cxbkhs5y.js +0 -2
  334. package/bundle/chunk-d9vs6zd0.js +0 -2
  335. package/bundle/chunk-dj3rct8v.js +0 -2
  336. package/bundle/chunk-ds162xgb.js +0 -3
  337. package/bundle/chunk-e1zv873k.js +0 -2
  338. package/bundle/chunk-eb0ksh4x.js +0 -2
  339. package/bundle/chunk-efxshjyz.js +0 -2
  340. package/bundle/chunk-enry018j.js +0 -2
  341. package/bundle/chunk-f03yje8k.js +0 -3
  342. package/bundle/chunk-fydd2nmw.js +0 -2
  343. package/bundle/chunk-g2bw2qf5.js +0 -2
  344. package/bundle/chunk-h9a4zzr4.js +0 -2
  345. package/bundle/chunk-hkqcpdmt.js +0 -3
  346. package/bundle/chunk-jx3kvzka.js +0 -2
  347. package/bundle/chunk-k6eyc1wv.js +0 -8
  348. package/bundle/chunk-k9m536te.js +0 -2
  349. package/bundle/chunk-kv58j3yk.js +0 -2
  350. package/bundle/chunk-m3sr6xdg.js +0 -2
  351. package/bundle/chunk-mmyhzhzt.js +0 -2
  352. package/bundle/chunk-mw60bmaf.js +0 -2
  353. package/bundle/chunk-nk42gy65.js +0 -2
  354. package/bundle/chunk-ps8xnz0h.js +0 -2
  355. package/bundle/chunk-pvn4dz8e.js +0 -2
  356. package/bundle/chunk-pw3tnt2j.js +0 -2
  357. package/bundle/chunk-pzajshbc.js +0 -2
  358. package/bundle/chunk-qvcnvqvf.js +0 -2
  359. package/bundle/chunk-qy9s3nmy.js +0 -2
  360. package/bundle/chunk-r0zsgad8.js +0 -4
  361. package/bundle/chunk-r4hkkcj4.js +0 -2
  362. package/bundle/chunk-r50kjthp.js +0 -2
  363. package/bundle/chunk-rbrkvj3x.js +0 -2
  364. package/bundle/chunk-rhgfyvth.js +0 -2
  365. package/bundle/chunk-rjdpw6at.js +0 -2
  366. package/bundle/chunk-s6c5c940.js +0 -2
  367. package/bundle/chunk-s79zd152.js +0 -2
  368. package/bundle/chunk-ssfgge5z.js +0 -2
  369. package/bundle/chunk-tdqbsbyb.js +0 -2
  370. package/bundle/chunk-tk6gjy9d.js +0 -3
  371. package/bundle/chunk-tsfpkwvr.js +0 -2
  372. package/bundle/chunk-v07wtbmt.js +0 -2
  373. package/bundle/chunk-v6kenrks.js +0 -2
  374. package/bundle/chunk-v7dfqwxx.js +0 -2
  375. package/bundle/chunk-vf7hhxsa.js +0 -2
  376. package/bundle/chunk-vmhq6cyz.js +0 -2
  377. package/bundle/chunk-vvs87e61.js +0 -2
  378. package/bundle/chunk-w6z123g2.js +0 -2
  379. package/bundle/chunk-wg0849tq.js +0 -2
  380. package/bundle/chunk-xj0ba60b.js +0 -2
  381. package/bundle/chunk-xtfcdgwe.js +0 -2
  382. package/bundle/chunk-ye6j8k26.js +0 -2
  383. package/bundle/chunk-zmqmccbc.js +0 -2
@@ -1,3 +0,0 @@
1
- // @bun
2
- import{ct as n}from"./chunk-p20ft5mj.js";import{pP as f}from"./chunk-fa03gsff.js";function l(t){if(!t?.fetch)t={...t,fetch:(s)=>{return s.timeout=!1,fetch(s)}};if(t?.directory)t.headers={...t.headers,"x-qitqode-directory":encodeURIComponent(t.directory)};return t}import o from"path";function g(t){if(t?.type!=="api"||typeof t.key!=="string")return;let s=t.metadata?.method==="api-key"?"api-key":"sso";return{key:t.key,method:s}}async function E(){let t=o.join(n.Path.data,"auth.json");try{let{readFile:u}=await import("fs/promises"),s=await u(t,"utf8"),e=JSON.parse(s),r=g(e?.forgewise);if(r)return r}catch{}if(process.env.QITQODE_AUTH_CONTENT)try{let u=JSON.parse(process.env.QITQODE_AUTH_CONTENT);return g(u?.forgewise)}catch{}return}async function A(){let t=o.join(n.Path.data,"auth.json"),{readFile:u,writeFile:s}=await import("fs/promises"),e=await u(t,"utf8"),r=JSON.parse(e);if(!("forgewise"in r))return;delete r.forgewise,await s(t,JSON.stringify(r,null,2),"utf8")}function b(t){return t.method==="api-key"?{"x-api-key":t.key}:{authorization:`Bearer ${t.key}`}}
3
- export{l as np,E as op,A as pp,b as qp};
@@ -1,2 +0,0 @@
1
- // @bun
2
- import{ff as a}from"./chunk-s6qdtfty.js";import"./chunk-fa03gsff.js";export default a();
@@ -1,2 +0,0 @@
1
- // @bun
2
- import{a,b,c,d,e,f}from"./chunk-6pe3xzkk.js";import"./chunk-2bbvvh0d.js";import"./chunk-f72j5yx8.js";import"./chunk-zbvf09bm.js";import"./chunk-9g05wsae.js";import"./chunk-x1dfc7qd.js";import"./chunk-wmmck56g.js";import"./chunk-ntmn6epc.js";import"./chunk-cckshvkb.js";import"./chunk-0jv8r99k.js";import"./chunk-th189x63.js";import"./chunk-k6eyc1wv.js";import"./chunk-q6x5bmc3.js";import"./chunk-n1m5qdf5.js";import"./chunk-zeh3mjgp.js";import"./chunk-prrrw8t8.js";import"./chunk-tz8qhbk9.js";import"./chunk-k19zvbzh.js";import"./chunk-3f6t3wde.js";import"./chunk-b5h8vd5n.js";import"./chunk-jee9y4t0.js";import"./chunk-50aznc8e.js";import"./chunk-c4x99ayd.js";import"./chunk-73d0dy03.js";import"./chunk-ha5qct06.js";import"./chunk-w8xaw2dv.js";import"./chunk-tq258v8s.js";import"./chunk-ds162xgb.js";import"./chunk-jfy6bfvv.js";import"./chunk-2p6w3w8f.js";import"./chunk-98nh88th.js";import"./chunk-t7v8wzr9.js";import"./chunk-er5q8nhp.js";import"./chunk-cqtkxwd8.js";import"./chunk-h6htvj2y.js";import"./chunk-2qy62cv4.js";import"./chunk-t2n6fmpy.js";import"./chunk-x1naayst.js";import"./chunk-ng85b73s.js";import"./chunk-351wfvhp.js";import"./chunk-hmm1m733.js";import"./chunk-2bxy8zm1.js";import"./chunk-qq9pvscd.js";import"./chunk-3nc9wy1m.js";import"./chunk-r8ddb02d.js";import"./chunk-dhvwrrqx.js";import"./chunk-56cty7nr.js";import"./chunk-thbjhgw0.js";import"./chunk-p20ft5mj.js";import"./chunk-b5x3zghc.js";import"./chunk-t1f7jeat.js";import"./chunk-tk6gjy9d.js";import"./chunk-pkdk0ppc.js";import"./chunk-hrnx60em.js";import"./chunk-bbznk59q.js";import"./chunk-01gtn79f.js";import"./chunk-meaa7wrs.js";import"./chunk-0ddhkapd.js";import"./chunk-gvj8qg7x.js";import"./chunk-fa03gsff.js";export{e as statusEffect,a as resolveApiKeyFlag,d as logoutEffect,c as loginEffect,b as apiKeyLoginEffect,f as AuthCommand};
@@ -1,2 +0,0 @@
1
- // @bun
2
- import"./chunk-fa03gsff.js";var a="./highlights-x6tmsnaa.scm";export{a as default};
@@ -1,2 +0,0 @@
1
- // @bun
2
- import{pP as t}from"./chunk-fa03gsff.js";var e=await import("./chunk-80a0d0js.js",{with:{type:"file"}}),a=e.default;export{a as default};
@@ -1,3 +0,0 @@
1
- // @bun
2
- import{Zf as E}from"./chunk-h5wh2d49.js";import"./chunk-xjdxyeja.js";import"./chunk-1zb95qfx.js";import"./chunk-cckshvkb.js";import"./chunk-hkqcpdmt.js";import"./chunk-nfg7nt13.js";import"./chunk-awdpkgxf.js";import"./chunk-8x6x3g16.js";import"./chunk-0jv8r99k.js";import"./chunk-th189x63.js";import"./chunk-k6eyc1wv.js";import"./chunk-q6x5bmc3.js";import"./chunk-n1m5qdf5.js";import"./chunk-zeh3mjgp.js";import"./chunk-prrrw8t8.js";import"./chunk-tz8qhbk9.js";import"./chunk-k19zvbzh.js";import"./chunk-3f6t3wde.js";import"./chunk-b5h8vd5n.js";import"./chunk-jee9y4t0.js";import"./chunk-50aznc8e.js";import"./chunk-c4x99ayd.js";import"./chunk-73d0dy03.js";import"./chunk-ha5qct06.js";import"./chunk-w8xaw2dv.js";import"./chunk-tq258v8s.js";import"./chunk-ds162xgb.js";import"./chunk-jfy6bfvv.js";import"./chunk-2p6w3w8f.js";import"./chunk-98nh88th.js";import"./chunk-t7v8wzr9.js";import"./chunk-er5q8nhp.js";import"./chunk-cqtkxwd8.js";import"./chunk-h6htvj2y.js";import"./chunk-2qy62cv4.js";import"./chunk-t2n6fmpy.js";import"./chunk-x1naayst.js";import"./chunk-ng85b73s.js";import"./chunk-351wfvhp.js";import"./chunk-hmm1m733.js";import"./chunk-2bxy8zm1.js";import"./chunk-qq9pvscd.js";import"./chunk-3nc9wy1m.js";import"./chunk-r8ddb02d.js";import"./chunk-dhvwrrqx.js";import"./chunk-56cty7nr.js";import"./chunk-thbjhgw0.js";import"./chunk-p20ft5mj.js";import"./chunk-b5x3zghc.js";import"./chunk-t1f7jeat.js";import"./chunk-tk6gjy9d.js";import"./chunk-pkdk0ppc.js";import"./chunk-hrnx60em.js";import"./chunk-bbznk59q.js";import"./chunk-01gtn79f.js";import"./chunk-meaa7wrs.js";import"./chunk-0ddhkapd.js";import"./chunk-gvj8qg7x.js";import{pP as z}from"./chunk-fa03gsff.js";var J={command:"generate",handler:async()=>{let A=await E.openapi();for(let q of Object.values(A.paths))for(let y of["get","post","put","delete","patch"]){let k=q[y];if(!k?.operationId)continue;k["x-codeSamples"]=[{lang:"js",source:['import { createQitQodeClient } from "@qitqode/sdk"',"","const client = createQitQodeClient()",`await client.${k.operationId}({`," ...","})"].join(`
3
- `)}]}let F=JSON.stringify(A,null,2),B=await import("./chunk-ne8ftsv3.js"),C=await import("./chunk-ck65rcxb.js"),D=await import("./chunk-p64fb4rm.js"),G=await(B.format??B.default?.format)(F,{parser:"json",plugins:[C.default??C,D.default??D],printWidth:120});await new Promise((q,y)=>{process.stdout.write(G,(k)=>{if(k)y(k);else q()})})}};export{J as GenerateCommand};
@@ -1,2 +0,0 @@
1
- // @bun
2
- import{il as a,jl as b,kl as c,ll as d,ml as e,nl as f,ol as g,pl as h,ql as i}from"./chunk-b5h8vd5n.js";import"./chunk-50aznc8e.js";import"./chunk-w8xaw2dv.js";import"./chunk-jfy6bfvv.js";import"./chunk-3nc9wy1m.js";import"./chunk-p20ft5mj.js";import"./chunk-b5x3zghc.js";import"./chunk-t1f7jeat.js";import"./chunk-tk6gjy9d.js";import"./chunk-pkdk0ppc.js";import"./chunk-hrnx60em.js";import"./chunk-bbznk59q.js";import"./chunk-01gtn79f.js";import"./chunk-meaa7wrs.js";import"./chunk-fa03gsff.js";export{i as stopRefresh,h as startRefresh,g as refresh,d as readModelCatalogResponse,f as get,c as Provider,b as Model,a as MODEL_CATALOG_MAX_BYTES,e as Data};
@@ -1,2 +0,0 @@
1
- // @bun
2
- import{rd as a,sd as b}from"./chunk-hf0gny5t.js";import"./chunk-jfy6bfvv.js";import"./chunk-b5x3zghc.js";import"./chunk-t1f7jeat.js";import"./chunk-01gtn79f.js";import"./chunk-meaa7wrs.js";import"./chunk-fa03gsff.js";export{a as read,b as copy};
@@ -1,2 +0,0 @@
1
- // @bun
2
- import{zf as a}from"./chunk-qxrjbw22.js";import"./chunk-cn7nnjsf.js";import"./chunk-nfg7nt13.js";import"./chunk-awdpkgxf.js";import"./chunk-fa03gsff.js";export{a as default};
@@ -1,3 +0,0 @@
1
- // @bun
2
- import{pP as o}from"./chunk-fa03gsff.js";var i=(t)=>`standard-openapi: ${t}`,s=new Map,r=async(t)=>{let e=s.get(t);if(e)return e;let a;switch(t){case"valibot":a=(await import("./chunk-4xpfmpjf.js")).default();break;case"zod":a=(await import("./chunk-ssfgge5z.js")).default();break;default:a=(await import("./chunk-h9a4zzr4.js")).default()}return s.set(t,a),a},d=async(t,e={})=>{let a=await r(t["~standard"].vendor),{components:n={},options:c}=e;return{schema:await a(t,{components:n,options:c}),components:Object.keys(n).length>0?n:void 0}};
3
- export{i as Cg,d as Dg};
@@ -1,2 +0,0 @@
1
- // @bun
2
- import"./chunk-fa03gsff.js";var q="./tree-sitter-powershell-ryb2ffqs.wasm";export{q as default};
@@ -1,8 +0,0 @@
1
- // @bun
2
- import{Ji as LO,Li as UO}from"./chunk-tz8qhbk9.js";import{np as WO,op as l,pp as e,qp as n}from"./chunk-ds162xgb.js";import{$q as D$}from"./chunk-t2n6fmpy.js";import{Fs as VO}from"./chunk-thbjhgw0.js";import{dt as k,mt as DO}from"./chunk-p20ft5mj.js";import{Ht as fO}from"./chunk-t1f7jeat.js";import{$H as f}from"./chunk-meaa7wrs.js";import{lP as gO,nP as yO}from"./chunk-fa03gsff.js";import{spawn as SO}from"child_process";async function oO(O){if(process.platform==="linux"){if(await new Promise((X)=>{let W=!1,J=(D)=>{if(W)return;W=!0,X(D)};try{let D=SO("xdg-open",[O],{stdio:"ignore",detached:!0});D.once("error",()=>J(!1)),D.once("spawn",()=>{D.unref(),J(!0)})}catch{J(!1)}}))return!0}try{let $=await D$(O);if(!$)return!1;return $.once("error",()=>{}),!0}catch{return!1}}function L$({onRequest:O,onSseError:$,onSseEvent:X,responseTransformer:W,responseValidator:J,sseDefaultRetryDelay:D,sseMaxRetryAttempts:G,sseMaxRetryDelay:Y,sseSleepFn:V,url:z,...I}){let U,S=V??((K)=>new Promise((N)=>setTimeout(N,K)));return{stream:async function*(){let K=D??3000,N=0,_=I.signal??new AbortController().signal;while(!0){if(_.aborted)break;N++;let v=I.headers instanceof Headers?I.headers:new Headers(I.headers);if(U!==void 0)v.set("Last-Event-ID",U);try{let R={redirect:"follow",...I,body:I.serializedBody,headers:v,signal:_},x=new Request(z,R);if(O)x=await O(z,R);let M=await(I.fetch??globalThis.fetch)(x);if(!M.ok)throw Error(`SSE failed: ${M.status} ${M.statusText}`);if(!M.body)throw Error("No body in SSE response");let F=M.body.pipeThrough(new TextDecoderStream).getReader(),w="",G$=()=>{try{F.cancel()}catch{}};_.addEventListener("abort",G$);try{while(!0){let{done:KO,value:BO}=await F.read();if(KO)break;w+=BO,w=w.replace(/\r\n?/g,`
3
- `);let Y$=w.split(`
4
-
5
- `);w=Y$.pop()??"";for(let NO of Y$){let MO=NO.split(`
6
- `),y=[],J$;for(let Q of MO)if(Q.startsWith("data:"))y.push(Q.replace(/^data:\s*/,""));else if(Q.startsWith("event:"))J$=Q.replace(/^event:\s*/,"");else if(Q.startsWith("id:"))U=Q.replace(/^id:\s*/,"");else if(Q.startsWith("retry:")){let V$=Number.parseInt(Q.replace(/^retry:\s*/,""),10);if(!Number.isNaN(V$))K=V$}let E,W$=!1;if(y.length){let Q=y.join(`
7
- `);try{E=JSON.parse(Q),W$=!0}catch{E=Q}}if(W$){if(J)await J(E);if(W)E=await W(E)}if(X?.({data:E,event:J$,id:U,retry:K}),y.length)yield E}}}finally{_.removeEventListener("abort",G$),F.releaseLock()}break}catch(R){if($?.(R),G!==void 0&&N>=G)break;let x=Math.min(K*2**(N-1),Y??30000);await S(x)}}}()}}var wO=(O)=>{switch(O){case"label":return".";case"matrix":return";";case"simple":return",";default:return"&"}},jO=(O)=>{switch(O){case"form":return",";case"pipeDelimited":return"|";case"spaceDelimited":return"%20";default:return","}},_O=(O)=>{switch(O){case"label":return".";case"matrix":return";";case"simple":return",";default:return"&"}},C=({allowReserved:O,explode:$,name:X,style:W,value:J})=>{if(!$){let Y=(O?J:J.map((V)=>encodeURIComponent(V))).join(jO(W));switch(W){case"label":return`.${Y}`;case"matrix":return`;${X}=${Y}`;case"simple":return Y;default:return`${X}=${Y}`}}let D=wO(W),G=J.map((Y)=>{if(W==="label"||W==="simple")return O?Y:encodeURIComponent(Y);return A({allowReserved:O,name:X,value:Y})}).join(D);return W==="label"||W==="matrix"?D+G:G},A=({allowReserved:O,name:$,value:X})=>{if(X===void 0||X===null)return"";if(typeof X==="object")throw Error("Deeply-nested arrays/objects aren\u2019t supported. Provide your own `querySerializer()` to handle these.");return`${$}=${O?X:encodeURIComponent(X)}`},c=({allowReserved:O,explode:$,name:X,style:W,value:J,valueOnly:D})=>{if(J instanceof Date)return D?J.toISOString():`${X}=${J.toISOString()}`;if(W!=="deepObject"&&!$){let V=[];Object.entries(J).forEach(([I,U])=>{V=[...V,I,O?U:encodeURIComponent(U)]});let z=V.join(",");switch(W){case"form":return`${X}=${z}`;case"label":return`.${z}`;case"matrix":return`;${X}=${z}`;default:return z}}let G=_O(W),Y=Object.entries(J).map(([V,z])=>A({allowReserved:O,name:W==="deepObject"?`${X}[${V}]`:V,value:z})).join(G);return W==="label"||W==="matrix"?G+Y:Y};var FO=/\{[^{}]+\}/g,QO=({path:O,url:$})=>{let X=$,W=$.match(FO);if(W)for(let J of W){let D=!1,G=J.substring(1,J.length-1),Y="simple";if(G.endsWith("*"))D=!0,G=G.substring(0,G.length-1);if(G.startsWith("."))G=G.substring(1),Y="label";else if(G.startsWith(";"))G=G.substring(1),Y="matrix";let V=O[G];if(V===void 0||V===null)continue;if(Array.isArray(V)){X=X.replace(J,C({explode:D,name:G,style:Y,value:V}));continue}if(typeof V==="object"){X=X.replace(J,c({explode:D,name:G,style:Y,value:V,valueOnly:!0}));continue}if(Y==="matrix"){X=X.replace(J,`;${A({name:G,value:V})}`);continue}let z=encodeURIComponent(Y==="label"?`.${V}`:V);X=X.replace(J,z)}return X},U$=({baseUrl:O,path:$,query:X,querySerializer:W,url:J})=>{let D=J.startsWith("/")?J:`/${J}`,G=(O??"")+D;if($)G=QO({path:$,url:G});let Y=X?W(X):"";if(Y.startsWith("?"))Y=Y.substring(1);if(Y)G+=`?${Y}`;return G};function r(O){let $=O.body!==void 0;if($&&O.bodySerializer){if("serializedBody"in O)return O.serializedBody!==void 0&&O.serializedBody!==""?O.serializedBody:null;return O.body!==""?O.body:null}if($)return O.body;return}var I$=async(O,$)=>{let X=typeof $==="function"?await $(O):$;if(!X)return;if(O.scheme==="bearer")return`Bearer ${X}`;if(O.scheme==="basic")return`Basic ${btoa(X)}`;return X};var i={bodySerializer:(O)=>JSON.stringify(O,($,X)=>typeof X==="bigint"?X.toString():X)};var z$=({parameters:O={},...$}={})=>{return(W)=>{let J=[];if(W&&typeof W==="object")for(let D in W){let G=W[D];if(G===void 0||G===null)continue;let Y=O[D]||$;if(Array.isArray(G)){let V=C({allowReserved:Y.allowReserved,explode:!0,name:D,style:"form",value:G,...Y.array});if(V)J.push(V)}else if(typeof G==="object"){let V=c({allowReserved:Y.allowReserved,explode:!0,name:D,style:"deepObject",value:G,...Y.object});if(V)J.push(V)}else{let V=A({allowReserved:Y.allowReserved,name:D,value:G});if(V)J.push(V)}}return J.join("&")}},K$=(O)=>{if(!O)return"stream";let $=O.split(";")[0]?.trim();if(!$)return;if($.startsWith("application/json")||$.endsWith("+json"))return"json";if($==="multipart/form-data")return"formData";if(["application/","audio/","image/","video/"].some((X)=>$.startsWith(X)))return"blob";if($.startsWith("text/"))return"text";return},TO=(O,$)=>{if(!$)return!1;if(O.headers.has($)||O.query?.[$]||O.headers.get("Cookie")?.includes(`${$}=`))return!0;return!1};async function B$(O){for(let $ of O.security??[]){if(TO(O,$.name))continue;let X=await I$($,O.auth);if(!X)continue;let W=$.name??"Authorization";switch($.in){case"query":if(!O.query)O.query={};O.query[W]=X;break;case"cookie":O.headers.append("Cookie",`${W}=${X}`);break;case"header":default:O.headers.set(W,X);break}}}var t=(O)=>U$({baseUrl:O.baseUrl,path:O.path,query:O.query,querySerializer:typeof O.querySerializer==="function"?O.querySerializer:z$(O.querySerializer),url:O.url}),s=(O,$)=>{let X={...O,...$};if(X.baseUrl?.endsWith("/"))X.baseUrl=X.baseUrl.substring(0,X.baseUrl.length-1);return X.headers=u(O.headers,$.headers),X},RO=(O)=>{let $=[];return O.forEach((X,W)=>{$.push([W,X])}),$},u=(...O)=>{let $=new Headers;for(let X of O){if(!X)continue;let W=X instanceof Headers?RO(X):Object.entries(X);for(let[J,D]of W)if(D===null)$.delete(J);else if(Array.isArray(D))for(let G of D)$.append(J,G);else if(D!==void 0)$.set(J,typeof D==="object"?JSON.stringify(D):D)}return $};class d{fns=[];clear(){this.fns=[]}eject(O){let $=this.getInterceptorIndex(O);if(this.fns[$])this.fns[$]=null}exists(O){let $=this.getInterceptorIndex(O);return Boolean(this.fns[$])}getInterceptorIndex(O){if(typeof O==="number")return this.fns[O]?O:-1;return this.fns.indexOf(O)}update(O,$){let X=this.getInterceptorIndex(O);if(this.fns[X])return this.fns[X]=$,O;return!1}use(O){return this.fns.push(O),this.fns.length-1}}var N$=()=>({error:new d,request:new d,response:new d}),xO=z$({allowReserved:!1,array:{explode:!0,style:"form"},object:{explode:!0,style:"deepObject"}}),EO={"Content-Type":"application/json"},P=(O={})=>({...i,headers:EO,parseAs:"auto",querySerializer:xO,...O});var g=(O={})=>{let $=s(P(),O),X=()=>({...$}),W=(I)=>{return $=s($,I),X()},J=N$(),D=async(I)=>{let U={...$,...I,fetch:I.fetch??$.fetch??globalThis.fetch,headers:u($.headers,I.headers),serializedBody:void 0};if(U.security)await B$(U);if(U.requestValidator)await U.requestValidator(U);if(U.body!==void 0&&U.bodySerializer)U.serializedBody=U.bodySerializer(U.body);if(U.body===void 0||U.serializedBody==="")U.headers.delete("Content-Type");let S=U,j=t(S);return{opts:S,url:j}},G=async(I)=>{let U=I.throwOnError??$.throwOnError,S=I.responseStyle??$.responseStyle,j,B;try{let{opts:K,url:N}=await D(I),_={redirect:"follow",...K,body:r(K)};j=new Request(N,_);for(let M of J.request.fns)if(M)j=await M(j,K);let v=K.fetch;B=await v(j);for(let M of J.response.fns)if(M)B=await M(B,j,K);let R={request:j,response:B};if(B.ok){let M=(K.parseAs==="auto"?K$(B.headers.get("Content-Type")):K.parseAs)??"json";if(B.status===204||B.headers.get("Content-Length")==="0"){let w;switch(M){case"arrayBuffer":case"blob":case"text":w=await B[M]();break;case"formData":w=new FormData;break;case"stream":w=B.body;break;case"json":default:w={};break}return K.responseStyle==="data"?w:{data:w,...R}}let F;switch(M){case"arrayBuffer":case"blob":case"formData":case"text":F=await B[M]();break;case"json":{let w=await B.text();F=w?JSON.parse(w):{};break}case"stream":return K.responseStyle==="data"?B.body:{data:B.body,...R}}if(M==="json"){if(K.responseValidator)await K.responseValidator(F);if(K.responseTransformer)F=await K.responseTransformer(F)}return K.responseStyle==="data"?F:{data:F,...R}}let x=await B.text(),p;try{p=JSON.parse(x)}catch{}throw p??x}catch(K){let N=K;for(let _ of J.error.fns)if(_)N=await _(N,B,j,I);if(N=N||{},U)throw N;return S==="data"?void 0:{error:N,request:j,response:B}}},Y=(I)=>(U)=>G({...U,method:I}),V=(I)=>async(U)=>{let{opts:S,url:j}=await D(U);return L$({...S,body:S.body,method:I,onRequest:async(B,K)=>{let N=new Request(B,K);for(let _ of J.request.fns)if(_)N=await _(N,S);return N},serializedBody:r(S),url:j})};return{buildUrl:(I)=>t({...$,...I}),connect:Y("CONNECT"),delete:Y("DELETE"),get:Y("GET"),getConfig:X,head:Y("HEAD"),interceptors:J,options:Y("OPTIONS"),patch:Y("PATCH"),post:Y("POST"),put:Y("PUT"),request:G,setConfig:W,sse:{connect:V("CONNECT"),delete:V("DELETE"),get:V("GET"),head:V("HEAD"),options:V("OPTIONS"),patch:V("PATCH"),post:V("POST"),put:V("PUT"),trace:V("TRACE")},trace:Y("TRACE")}};var qO={$body_:"body",$headers_:"headers",$path_:"path",$query_:"query"},HO=Object.entries(qO),M$=(O,$)=>{if(!$)$=new Map;for(let X of O)if("in"in X){if(X.key)$.set(X.key,{in:X.in,map:X.map})}else if("key"in X)$.set(X.key,{map:X.map});else if(X.args)M$(X.args,$);return $},kO=(O)=>{for(let[$,X]of Object.entries(O))if(X&&typeof X==="object"&&!Array.isArray(X)&&!Object.keys(X).length)delete O[$]},Z=(O,$)=>{let X={body:Object.create(null),headers:Object.create(null),path:Object.create(null),query:Object.create(null)},W=M$($),J;for(let[D,G]of O.entries()){if($[D])J=$[D];if(!J)continue;if("in"in J)if(J.key){let Y=W.get(J.key),V=Y.map||J.key;if(Y.in)X[Y.in][V]=G}else X.body=G;else for(let[Y,V]of Object.entries(G??{})){let z=W.get(Y);if(z)if(z.in){let I=z.map||Y;X[z.in][I]=V}else X[z.map]=V;else{let I=HO.find(([U])=>Y.startsWith(U));if(I){let[U,S]=I;X[S][Y.slice(U.length)]=V}else if("allowExtra"in J&&J.allowExtra){for(let[U,S]of Object.entries(J.allowExtra))if(S){X[U][Y]=V;break}}}}}return kO(X),X};var S$=g(P({baseUrl:"http://localhost:4096"}));class L{client;constructor(O){this.client=O?.client??S$}}class w${defaultKey="default";instances=new Map;get(O){let $=this.instances.get(O??this.defaultKey);if(!$)throw Error('No SDK client found. Create one with "new QitQodeClient()" to fix this error.');return $}set(O,$){this.instances.set($??this.defaultKey,O)}}class j$ extends L{get(O){return(O?.client??this.client).get({url:"/global/config",...O})}update(O,$){let X=Z([O],[{args:[{key:"config",map:"body"}]}]);return($?.client??this.client).patch({url:"/global/config",...$,...X,headers:{"Content-Type":"application/json",...$?.headers,...X.headers}})}}class _$ extends L{scan(O){return(O?.client??this.client).get({url:"/global/import/scan",...O})}run(O,$){let X=Z([O],[{args:[{in:"body",key:"sources"},{in:"body",key:"force"}]}]);return($?.client??this.client).post({url:"/global/import/run",...$,...X,headers:{"Content-Type":"application/json",...$?.headers,...X.headers}})}}class F$ extends L{health(O){return(O?.client??this.client).get({url:"/global/health",...O})}event(O){return(O?.client??this.client).sse.get({url:"/global/event",...O})}dispose(O){return(O?.client??this.client).post({url:"/global/dispose",...O})}upgrade(O,$){let X=Z([O],[{args:[{in:"body",key:"target"}]}]);return($?.client??this.client).post({url:"/global/upgrade",...$,...X,headers:{"Content-Type":"application/json",...$?.headers,...X.headers}})}_config;get config(){return this._config??=new j$({client:this.client})}_import;get import(){return this._import??=new _$({client:this.client})}}class Q$ extends L{remove(O,$){let X=Z([O],[{args:[{in:"path",key:"providerID"}]}]);return($?.client??this.client).delete({url:"/auth/{providerID}",...$,...X})}set(O,$){let X=Z([O],[{args:[{in:"path",key:"providerID"},{key:"auth",map:"body"}]}]);return($?.client??this.client).put({url:"/auth/{providerID}",...$,...X,headers:{"Content-Type":"application/json",...$?.headers,...X.headers}})}}class T$ extends L{log(O,$){let X=Z([O],[{args:[{in:"query",key:"directory"},{in:"query",key:"workspace"},{in:"body",key:"service"},{in:"body",key:"level"},{in:"body",key:"message"},{in:"body",key:"extra"}]}]);return($?.client??this.client).post({url:"/log",...$,...X,headers:{"Content-Type":"application/json",...$?.headers,...X.headers}})}agents(O,$){let X=Z([O],[{args:[{in:"query",key:"directory"},{in:"query",key:"workspace"}]}]);return($?.client??this.client).get({url:"/agent",...$,...X})}skills(O,$){let X=Z([O],[{args:[{in:"query",key:"directory"},{in:"query",key:"workspace"}]}]);return($?.client??this.client).get({url:"/skill",...$,...X})}}class R$ extends L{list(O,$){let X=Z([O],[{args:[{in:"query",key:"directory"},{in:"query",key:"workspace"}]}]);return($?.client??this.client).get({url:"/experimental/workspace/adaptor",...$,...X})}}class x$ extends L{list(O,$){let X=Z([O],[{args:[{in:"query",key:"directory"},{in:"query",key:"workspace"}]}]);return($?.client??this.client).get({url:"/experimental/workspace",...$,...X})}create(O,$){let X=Z([O],[{args:[{in:"query",key:"directory"},{in:"query",key:"workspace"},{in:"body",key:"id"},{in:"body",key:"type"},{in:"body",key:"branch"},{in:"body",key:"extra"}]}]);return($?.client??this.client).post({url:"/experimental/workspace",...$,...X,headers:{"Content-Type":"application/json",...$?.headers,...X.headers}})}status(O,$){let X=Z([O],[{args:[{in:"query",key:"directory"},{in:"query",key:"workspace"}]}]);return($?.client??this.client).get({url:"/experimental/workspace/status",...$,...X})}remove(O,$){let X=Z([O],[{args:[{in:"path",key:"id"},{in:"query",key:"directory"},{in:"query",key:"workspace"}]}]);return($?.client??this.client).delete({url:"/experimental/workspace/{id}",...$,...X})}sessionRestore(O,$){let X=Z([O],[{args:[{in:"path",key:"id"},{in:"query",key:"directory"},{in:"query",key:"workspace"},{in:"body",key:"sessionID"}]}]);return($?.client??this.client).post({url:"/experimental/workspace/{id}/session-restore",...$,...X,headers:{"Content-Type":"application/json",...$?.headers,...X.headers}})}_adaptor;get adaptor(){return this._adaptor??=new R$({client:this.client})}}class E$ extends L{get(O,$){let X=Z([O],[{args:[{in:"query",key:"directory"},{in:"query",key:"workspace"}]}]);return($?.client??this.client).get({url:"/experimental/console",...$,...X})}listOrgs(O,$){let X=Z([O],[{args:[{in:"query",key:"directory"},{in:"query",key:"workspace"}]}]);return($?.client??this.client).get({url:"/experimental/console/orgs",...$,...X})}switchOrg(O,$){let X=Z([O],[{args:[{in:"query",key:"directory"},{in:"query",key:"workspace"},{in:"body",key:"accountID"},{in:"body",key:"orgID"}]}]);return($?.client??this.client).post({url:"/experimental/console/switch",...$,...X,headers:{"Content-Type":"application/json",...$?.headers,...X.headers}})}}class q$ extends L{list(O,$){let X=Z([O],[{args:[{in:"query",key:"directory"},{in:"query",key:"workspace"},{in:"query",key:"roots"},{in:"query",key:"start"},{in:"query",key:"cursor"},{in:"query",key:"search"},{in:"query",key:"limit"},{in:"query",key:"archived"}]}]);return($?.client??this.client).get({url:"/experimental/session",...$,...X})}}class H$ extends L{list(O,$){let X=Z([O],[{args:[{in:"query",key:"directory"},{in:"query",key:"workspace"}]}]);return($?.client??this.client).get({url:"/experimental/resource",...$,...X})}}class k$ extends L{_workspace;get workspace(){return this._workspace??=new x$({client:this.client})}_console;get console(){return this._console??=new E$({client:this.client})}_session;get session(){return this._session??=new q$({client:this.client})}_resource;get resource(){return this._resource??=new H$({client:this.client})}}class A$ extends L{list(O,$){let X=Z([O],[{args:[{in:"query",key:"directory"},{in:"query",key:"workspace"}]}]);return($?.client??this.client).get({url:"/project",...$,...X})}current(O,$){let X=Z([O],[{args:[{in:"query",key:"directory"},{in:"query",key:"workspace"}]}]);return($?.client??this.client).get({url:"/project/current",...$,...X})}initGit(O,$){let X=Z([O],[{args:[{in:"query",key:"directory"},{in:"query",key:"workspace"}]}]);return($?.client??this.client).post({url:"/project/git/init",...$,...X})}update(O,$){let X=Z([O],[{args:[{in:"path",key:"projectID"},{in:"query",key:"directory"},{in:"query",key:"workspace"},{in:"body",key:"name"},{in:"body",key:"icon"},{in:"body",key:"commands"}]}]);return($?.client??this.client).patch({url:"/project/{projectID}",...$,...X,headers:{"Content-Type":"application/json",...$?.headers,...X.headers}})}}class h$ extends L{list(O,$){let X=Z([O],[{args:[{in:"query",key:"directory"},{in:"query",key:"workspace"}]}]);return($?.client??this.client).get({url:"/pty",...$,...X})}create(O,$){let X=Z([O],[{args:[{in:"query",key:"directory"},{in:"query",key:"workspace"},{in:"body",key:"command"},{in:"body",key:"args"},{in:"body",key:"cwd"},{in:"body",key:"title"},{in:"body",key:"env"}]}]);return($?.client??this.client).post({url:"/pty",...$,...X,headers:{"Content-Type":"application/json",...$?.headers,...X.headers}})}remove(O,$){let X=Z([O],[{args:[{in:"path",key:"ptyID"},{in:"query",key:"directory"},{in:"query",key:"workspace"}]}]);return($?.client??this.client).delete({url:"/pty/{ptyID}",...$,...X})}get(O,$){let X=Z([O],[{args:[{in:"path",key:"ptyID"},{in:"query",key:"directory"},{in:"query",key:"workspace"}]}]);return($?.client??this.client).get({url:"/pty/{ptyID}",...$,...X})}update(O,$){let X=Z([O],[{args:[{in:"path",key:"ptyID"},{in:"query",key:"directory"},{in:"query",key:"workspace"},{in:"body",key:"title"},{in:"body",key:"size"}]}]);return($?.client??this.client).put({url:"/pty/{ptyID}",...$,...X,headers:{"Content-Type":"application/json",...$?.headers,...X.headers}})}connectToken(O,$){let X=Z([O],[{args:[{in:"path",key:"ptyID"},{in:"query",key:"directory"},{in:"query",key:"workspace"}]}]);return($?.client??this.client).post({url:"/pty/{ptyID}/connect-token",...$,...X})}connect(O,$){let X=Z([O],[{args:[{in:"path",key:"ptyID"},{in:"query",key:"directory"},{in:"query",key:"workspace"}]}]);return($?.client??this.client).get({url:"/pty/{ptyID}/connect",...$,...X})}}class P$ extends L{get(O,$){let X=Z([O],[{args:[{in:"query",key:"directory"},{in:"query",key:"workspace"}]}]);return($?.client??this.client).get({url:"/config",...$,...X})}update(O,$){let X=Z([O],[{args:[{in:"query",key:"directory"},{in:"query",key:"workspace"},{key:"config",map:"body"}]}]);return($?.client??this.client).patch({url:"/config",...$,...X,headers:{"Content-Type":"application/json",...$?.headers,...X.headers}})}providers(O,$){let X=Z([O],[{args:[{in:"query",key:"directory"},{in:"query",key:"workspace"}]}]);return($?.client??this.client).get({url:"/config/providers",...$,...X})}}class g$ extends L{ids(O,$){let X=Z([O],[{args:[{in:"query",key:"directory"},{in:"query",key:"workspace"}]}]);return($?.client??this.client).get({url:"/experimental/tool/ids",...$,...X})}list(O,$){let X=Z([O],[{args:[{in:"query",key:"directory"},{in:"query",key:"workspace"},{in:"query",key:"provider"},{in:"query",key:"model"}]}]);return($?.client??this.client).get({url:"/experimental/tool",...$,...X})}}class f$ extends L{remove(O,$){let X=Z([O],[{args:[{in:"query",key:"directory"},{in:"query",key:"workspace"},{key:"worktreeRemoveInput",map:"body"}]}]);return($?.client??this.client).delete({url:"/experimental/worktree",...$,...X,headers:{"Content-Type":"application/json",...$?.headers,...X.headers}})}list(O,$){let X=Z([O],[{args:[{in:"query",key:"directory"},{in:"query",key:"workspace"}]}]);return($?.client??this.client).get({url:"/experimental/worktree",...$,...X})}create(O,$){let X=Z([O],[{args:[{in:"query",key:"directory"},{in:"query",key:"workspace"},{key:"worktreeCreateInput",map:"body"}]}]);return($?.client??this.client).post({url:"/experimental/worktree",...$,...X,headers:{"Content-Type":"application/json",...$?.headers,...X.headers}})}reset(O,$){let X=Z([O],[{args:[{in:"query",key:"directory"},{in:"query",key:"workspace"},{key:"worktreeResetInput",map:"body"}]}]);return($?.client??this.client).post({url:"/experimental/worktree/reset",...$,...X,headers:{"Content-Type":"application/json",...$?.headers,...X.headers}})}}class b$ extends L{list(O,$){let X=Z([O],[{args:[{in:"query",key:"directory"},{in:"query",key:"workspace"},{in:"query",key:"roots"},{in:"query",key:"start"},{in:"query",key:"search"},{in:"query",key:"limit"}]}]);return($?.client??this.client).get({url:"/session",...$,...X})}create(O,$){let X=Z([O],[{args:[{in:"query",key:"directory"},{in:"query",key:"workspace"},{in:"body",key:"parentID"},{in:"body",key:"contextFrom"},{in:"body",key:"contextWatermark"},{in:"body",key:"title"},{in:"body",key:"permission"},{in:"body",key:"workspaceID"}]}]);return($?.client??this.client).post({url:"/session",...$,...X,headers:{"Content-Type":"application/json",...$?.headers,...X.headers}})}status(O,$){let X=Z([O],[{args:[{in:"query",key:"directory"},{in:"query",key:"workspace"}]}]);return($?.client??this.client).get({url:"/session/status",...$,...X})}delete(O,$){let X=Z([O],[{args:[{in:"path",key:"sessionID"},{in:"query",key:"directory"},{in:"query",key:"workspace"}]}]);return($?.client??this.client).delete({url:"/session/{sessionID}",...$,...X})}get(O,$){let X=Z([O],[{args:[{in:"path",key:"sessionID"},{in:"query",key:"directory"},{in:"query",key:"workspace"}]}]);return($?.client??this.client).get({url:"/session/{sessionID}",...$,...X})}update(O,$){let X=Z([O],[{args:[{in:"path",key:"sessionID"},{in:"query",key:"directory"},{in:"query",key:"workspace"},{in:"body",key:"title"},{in:"body",key:"permission"},{in:"body",key:"time"}]}]);return($?.client??this.client).patch({url:"/session/{sessionID}",...$,...X,headers:{"Content-Type":"application/json",...$?.headers,...X.headers}})}children(O,$){let X=Z([O],[{args:[{in:"path",key:"sessionID"},{in:"query",key:"directory"},{in:"query",key:"workspace"}]}]);return($?.client??this.client).get({url:"/session/{sessionID}/children",...$,...X})}init(O,$){let X=Z([O],[{args:[{in:"path",key:"sessionID"},{in:"query",key:"directory"},{in:"query",key:"workspace"},{in:"body",key:"modelID"},{in:"body",key:"providerID"},{in:"body",key:"messageID"}]}]);return($?.client??this.client).post({url:"/session/{sessionID}/init",...$,...X,headers:{"Content-Type":"application/json",...$?.headers,...X.headers}})}fork(O,$){let X=Z([O],[{args:[{in:"path",key:"sessionID"},{in:"query",key:"directory"},{in:"query",key:"workspace"},{in:"body",key:"messageID"}]}]);return($?.client??this.client).post({url:"/session/{sessionID}/fork",...$,...X,headers:{"Content-Type":"application/json",...$?.headers,...X.headers}})}abort(O,$){let X=Z([O],[{args:[{in:"path",key:"sessionID"},{in:"query",key:"directory"},{in:"query",key:"workspace"}]}]);return($?.client??this.client).post({url:"/session/{sessionID}/abort",...$,...X})}actors(O,$){let X=Z([O],[{args:[{in:"path",key:"sessionID"},{in:"query",key:"directory"},{in:"query",key:"workspace"}]}]);return($?.client??this.client).get({url:"/session/{sessionID}/actors",...$,...X})}todo(O,$){let X=Z([O],[{args:[{in:"path",key:"sessionID"},{in:"query",key:"directory"},{in:"query",key:"workspace"}]}]);return($?.client??this.client).get({url:"/session/{sessionID}/todo",...$,...X})}task(O,$){let X=Z([O],[{args:[{in:"path",key:"sessionID"},{in:"query",key:"directory"},{in:"query",key:"workspace"}]}]);return($?.client??this.client).get({url:"/session/{sessionID}/task",...$,...X})}unshare(O,$){let X=Z([O],[{args:[{in:"path",key:"sessionID"},{in:"query",key:"directory"},{in:"query",key:"workspace"}]}]);return($?.client??this.client).delete({url:"/session/{sessionID}/share",...$,...X})}share(O,$){let X=Z([O],[{args:[{in:"path",key:"sessionID"},{in:"query",key:"directory"},{in:"query",key:"workspace"}]}]);return($?.client??this.client).post({url:"/session/{sessionID}/share",...$,...X})}diff(O,$){let X=Z([O],[{args:[{in:"path",key:"sessionID"},{in:"query",key:"directory"},{in:"query",key:"workspace"},{in:"query",key:"messageID"}]}]);return($?.client??this.client).get({url:"/session/{sessionID}/diff",...$,...X})}summarize(O,$){let X=Z([O],[{args:[{in:"path",key:"sessionID"},{in:"query",key:"directory"},{in:"query",key:"workspace"},{in:"body",key:"providerID"},{in:"body",key:"modelID"},{in:"body",key:"auto"}]}]);return($?.client??this.client).post({url:"/session/{sessionID}/summarize",...$,...X,headers:{"Content-Type":"application/json",...$?.headers,...X.headers}})}revert(O,$){let X=Z([O],[{args:[{in:"path",key:"sessionID"},{in:"query",key:"directory"},{in:"query",key:"workspace"},{in:"body",key:"messageID"},{in:"body",key:"partID"}]}]);return($?.client??this.client).post({url:"/session/{sessionID}/revert",...$,...X,headers:{"Content-Type":"application/json",...$?.headers,...X.headers}})}unrevert(O,$){let X=Z([O],[{args:[{in:"path",key:"sessionID"},{in:"query",key:"directory"},{in:"query",key:"workspace"}]}]);return($?.client??this.client).post({url:"/session/{sessionID}/unrevert",...$,...X})}messages(O,$){let X=Z([O],[{args:[{in:"path",key:"sessionID"},{in:"query",key:"directory"},{in:"query",key:"workspace"},{in:"query",key:"limit"},{in:"query",key:"before"},{in:"query",key:"agent_id"}]}]);return($?.client??this.client).get({url:"/session/{sessionID}/message",...$,...X})}prompt(O,$){let X=Z([O],[{args:[{in:"path",key:"sessionID"},{in:"query",key:"directory"},{in:"query",key:"workspace"},{in:"body",key:"messageID"},{in:"body",key:"model"},{in:"body",key:"modelRef"},{in:"body",key:"agent"},{in:"body",key:"agentID"},{in:"body",key:"task_id"},{in:"body",key:"source"},{in:"body",key:"provenance"},{in:"body",key:"noReply"},{in:"body",key:"tools"},{in:"body",key:"format"},{in:"body",key:"system"},{in:"body",key:"variant"},{in:"body",key:"parts"}]}]);return($?.client??this.client).post({url:"/session/{sessionID}/message",...$,...X,headers:{"Content-Type":"application/json",...$?.headers,...X.headers}})}deleteMessage(O,$){let X=Z([O],[{args:[{in:"path",key:"sessionID"},{in:"path",key:"messageID"},{in:"query",key:"directory"},{in:"query",key:"workspace"}]}]);return($?.client??this.client).delete({url:"/session/{sessionID}/message/{messageID}",...$,...X})}message(O,$){let X=Z([O],[{args:[{in:"path",key:"sessionID"},{in:"path",key:"messageID"},{in:"query",key:"directory"},{in:"query",key:"workspace"}]}]);return($?.client??this.client).get({url:"/session/{sessionID}/message/{messageID}",...$,...X})}promptAsync(O,$){let X=Z([O],[{args:[{in:"path",key:"sessionID"},{in:"query",key:"directory"},{in:"query",key:"workspace"},{in:"body",key:"messageID"},{in:"body",key:"model"},{in:"body",key:"modelRef"},{in:"body",key:"agent"},{in:"body",key:"agentID"},{in:"body",key:"task_id"},{in:"body",key:"source"},{in:"body",key:"provenance"},{in:"body",key:"noReply"},{in:"body",key:"tools"},{in:"body",key:"format"},{in:"body",key:"system"},{in:"body",key:"variant"},{in:"body",key:"parts"}]}]);return($?.client??this.client).post({url:"/session/{sessionID}/prompt_async",...$,...X,headers:{"Content-Type":"application/json",...$?.headers,...X.headers}})}command(O,$){let X=Z([O],[{args:[{in:"path",key:"sessionID"},{in:"query",key:"directory"},{in:"query",key:"workspace"},{in:"body",key:"messageID"},{in:"body",key:"agent"},{in:"body",key:"model"},{in:"body",key:"arguments"},{in:"body",key:"command"},{in:"body",key:"variant"},{in:"body",key:"parts"}]}]);return($?.client??this.client).post({url:"/session/{sessionID}/command",...$,...X,headers:{"Content-Type":"application/json",...$?.headers,...X.headers}})}predict(O,$){let X=Z([O],[{args:[{in:"path",key:"sessionID"},{in:"query",key:"directory"},{in:"query",key:"workspace"}]}]);return($?.client??this.client).post({url:"/session/{sessionID}/predict",...$,...X})}shell(O,$){let X=Z([O],[{args:[{in:"path",key:"sessionID"},{in:"query",key:"directory"},{in:"query",key:"workspace"},{in:"body",key:"messageID"},{in:"body",key:"agent"},{in:"body",key:"model"},{in:"body",key:"modelRef"},{in:"body",key:"command"}]}]);return($?.client??this.client).post({url:"/session/{sessionID}/shell",...$,...X,headers:{"Content-Type":"application/json",...$?.headers,...X.headers}})}}class v$ extends L{delete(O,$){let X=Z([O],[{args:[{in:"path",key:"sessionID"},{in:"path",key:"messageID"},{in:"path",key:"partID"},{in:"query",key:"directory"},{in:"query",key:"workspace"}]}]);return($?.client??this.client).delete({url:"/session/{sessionID}/message/{messageID}/part/{partID}",...$,...X})}update(O,$){let X=Z([O],[{args:[{in:"path",key:"sessionID"},{in:"path",key:"messageID"},{in:"path",key:"partID"},{in:"query",key:"directory"},{in:"query",key:"workspace"},{key:"part",map:"body"}]}]);return($?.client??this.client).patch({url:"/session/{sessionID}/message/{messageID}/part/{partID}",...$,...X,headers:{"Content-Type":"application/json",...$?.headers,...X.headers}})}}class y$ extends L{respond(O,$){let X=Z([O],[{args:[{in:"path",key:"sessionID"},{in:"path",key:"permissionID"},{in:"query",key:"directory"},{in:"query",key:"workspace"},{in:"body",key:"response"}]}]);return($?.client??this.client).post({url:"/session/{sessionID}/permissions/{permissionID}",...$,...X,headers:{"Content-Type":"application/json",...$?.headers,...X.headers}})}reply(O,$){let X=Z([O],[{args:[{in:"path",key:"requestID"},{in:"query",key:"directory"},{in:"query",key:"workspace"},{in:"body",key:"reply"},{in:"body",key:"message"}]}]);return($?.client??this.client).post({url:"/permission/{requestID}/reply",...$,...X,headers:{"Content-Type":"application/json",...$?.headers,...X.headers}})}list(O,$){let X=Z([O],[{args:[{in:"query",key:"directory"},{in:"query",key:"workspace"}]}]);return($?.client??this.client).get({url:"/permission",...$,...X})}}class C$ extends L{balance(O,$){let X=Z([O],[{args:[{in:"query",key:"directory"},{in:"query",key:"workspace"}]}]);return($?.client??this.client).get({url:"/qredits/balance",...$,...X})}}class c$ extends L{list(O,$){let X=Z([O],[{args:[{in:"query",key:"directory"},{in:"query",key:"workspace"},{in:"query",key:"sessionID"}]}]);return($?.client??this.client).get({url:"/workflows",...$,...X})}resume(O,$){let X=Z([O],[{args:[{in:"path",key:"runID"},{in:"query",key:"directory"},{in:"query",key:"workspace"}]}]);return($?.client??this.client).post({url:"/workflows/{runID}/resume",...$,...X})}}class d$ extends L{list(O,$){let X=Z([O],[{args:[{in:"query",key:"directory"},{in:"query",key:"workspace"}]}]);return($?.client??this.client).get({url:"/question",...$,...X})}neverAsk(O,$){let X=Z([O],[{args:[{in:"query",key:"directory"},{in:"query",key:"workspace"}]}]);return($?.client??this.client).get({url:"/question/never-ask",...$,...X})}setNeverAsk(O,$){let X=Z([O],[{args:[{in:"query",key:"directory"},{in:"query",key:"workspace"},{in:"body",key:"enabled"}]}]);return($?.client??this.client).post({url:"/question/never-ask",...$,...X,headers:{"Content-Type":"application/json",...$?.headers,...X.headers}})}reply(O,$){let X=Z([O],[{args:[{in:"path",key:"requestID"},{in:"query",key:"directory"},{in:"query",key:"workspace"},{in:"body",key:"answers"}]}]);return($?.client??this.client).post({url:"/question/{requestID}/reply",...$,...X,headers:{"Content-Type":"application/json",...$?.headers,...X.headers}})}reject(O,$){let X=Z([O],[{args:[{in:"path",key:"requestID"},{in:"query",key:"directory"},{in:"query",key:"workspace"}]}]);return($?.client??this.client).post({url:"/question/{requestID}/reject",...$,...X})}}class u$ extends L{list(O,$){let X=Z([O],[{args:[{in:"query",key:"directory"},{in:"query",key:"workspace"}]}]);return($?.client??this.client).get({url:"/bash-interactive",...$,...X})}reply(O,$){let X=Z([O],[{args:[{in:"path",key:"id"},{in:"query",key:"directory"},{in:"query",key:"workspace"},{in:"body",key:"output"},{in:"body",key:"exitCode"}]}]);return($?.client??this.client).post({url:"/bash-interactive/{id}/reply",...$,...X,headers:{"Content-Type":"application/json",...$?.headers,...X.headers}})}}class m$ extends L{_interactive;get interactive(){return this._interactive??=new u$({client:this.client})}}class l$ extends L{authorize(O,$){let X=Z([O],[{args:[{in:"path",key:"providerID"},{in:"query",key:"directory"},{in:"query",key:"workspace"},{in:"body",key:"method"},{in:"body",key:"inputs"}]}]);return($?.client??this.client).post({url:"/provider/{providerID}/oauth/authorize",...$,...X,headers:{"Content-Type":"application/json",...$?.headers,...X.headers}})}callback(O,$){let X=Z([O],[{args:[{in:"path",key:"providerID"},{in:"query",key:"directory"},{in:"query",key:"workspace"},{in:"body",key:"method"},{in:"body",key:"code"}]}]);return($?.client??this.client).post({url:"/provider/{providerID}/oauth/callback",...$,...X,headers:{"Content-Type":"application/json",...$?.headers,...X.headers}})}}class n$ extends L{list(O,$){let X=Z([O],[{args:[{in:"query",key:"directory"},{in:"query",key:"workspace"}]}]);return($?.client??this.client).get({url:"/provider",...$,...X})}auth(O,$){let X=Z([O],[{args:[{in:"query",key:"directory"},{in:"query",key:"workspace"}]}]);return($?.client??this.client).get({url:"/provider/auth",...$,...X})}_oauth;get oauth(){return this._oauth??=new l$({client:this.client})}}class p$ extends L{list(O,$){let X=Z([O],[{args:[{in:"query",key:"directory"},{in:"query",key:"workspace"},{key:"body",map:"body"}]}]);return($?.client??this.client).post({url:"/sync/history",...$,...X,headers:{"Content-Type":"application/json",...$?.headers,...X.headers}})}}class r$ extends L{start(O,$){let X=Z([O],[{args:[{in:"query",key:"directory"},{in:"query",key:"workspace"}]}]);return($?.client??this.client).post({url:"/sync/start",...$,...X})}replay(O,$){let X=Z([O],[{args:[{in:"query",key:"query_directory",map:"directory"},{in:"query",key:"workspace"},{in:"body",key:"body_directory",map:"directory"},{in:"body",key:"events"}]}]);return($?.client??this.client).post({url:"/sync/replay",...$,...X,headers:{"Content-Type":"application/json",...$?.headers,...X.headers}})}_history;get history(){return this._history??=new p$({client:this.client})}}class i$ extends L{text(O,$){let X=Z([O],[{args:[{in:"query",key:"directory"},{in:"query",key:"workspace"},{in:"query",key:"pattern"}]}]);return($?.client??this.client).get({url:"/find",...$,...X})}files(O,$){let X=Z([O],[{args:[{in:"query",key:"directory"},{in:"query",key:"workspace"},{in:"query",key:"query"},{in:"query",key:"dirs"},{in:"query",key:"type"},{in:"query",key:"limit"}]}]);return($?.client??this.client).get({url:"/find/file",...$,...X})}symbols(O,$){let X=Z([O],[{args:[{in:"query",key:"directory"},{in:"query",key:"workspace"},{in:"query",key:"query"}]}]);return($?.client??this.client).get({url:"/find/symbol",...$,...X})}}class t$ extends L{list(O,$){let X=Z([O],[{args:[{in:"query",key:"directory"},{in:"query",key:"workspace"},{in:"query",key:"path"}]}]);return($?.client??this.client).get({url:"/file",...$,...X})}read(O,$){let X=Z([O],[{args:[{in:"query",key:"directory"},{in:"query",key:"workspace"},{in:"query",key:"path"}]}]);return($?.client??this.client).get({url:"/file/content",...$,...X})}status(O,$){let X=Z([O],[{args:[{in:"query",key:"directory"},{in:"query",key:"workspace"}]}]);return($?.client??this.client).get({url:"/file/status",...$,...X})}}class s$ extends L{subscribe(O,$){let X=Z([O],[{args:[{in:"query",key:"directory"},{in:"query",key:"workspace"}]}]);return($?.client??this.client).sse.get({url:"/event",...$,...X})}}class a$ extends L{remove(O,$){let X=Z([O],[{args:[{in:"path",key:"name"},{in:"query",key:"directory"},{in:"query",key:"workspace"}]}]);return($?.client??this.client).delete({url:"/mcp/{name}/auth",...$,...X})}start(O,$){let X=Z([O],[{args:[{in:"path",key:"name"},{in:"query",key:"directory"},{in:"query",key:"workspace"}]}]);return($?.client??this.client).post({url:"/mcp/{name}/auth",...$,...X})}callback(O,$){let X=Z([O],[{args:[{in:"path",key:"name"},{in:"query",key:"directory"},{in:"query",key:"workspace"},{in:"body",key:"code"}]}]);return($?.client??this.client).post({url:"/mcp/{name}/auth/callback",...$,...X,headers:{"Content-Type":"application/json",...$?.headers,...X.headers}})}authenticate(O,$){let X=Z([O],[{args:[{in:"path",key:"name"},{in:"query",key:"directory"},{in:"query",key:"workspace"}]}]);return($?.client??this.client).post({url:"/mcp/{name}/auth/authenticate",...$,...X})}}class o$ extends L{status(O,$){let X=Z([O],[{args:[{in:"query",key:"directory"},{in:"query",key:"workspace"}]}]);return($?.client??this.client).get({url:"/mcp",...$,...X})}add(O,$){let X=Z([O],[{args:[{in:"query",key:"directory"},{in:"query",key:"workspace"},{in:"body",key:"name"},{in:"body",key:"config"}]}]);return($?.client??this.client).post({url:"/mcp",...$,...X,headers:{"Content-Type":"application/json",...$?.headers,...X.headers}})}connect(O,$){let X=Z([O],[{args:[{in:"path",key:"name"},{in:"query",key:"directory"},{in:"query",key:"workspace"}]}]);return($?.client??this.client).post({url:"/mcp/{name}/connect",...$,...X})}disconnect(O,$){let X=Z([O],[{args:[{in:"path",key:"name"},{in:"query",key:"directory"},{in:"query",key:"workspace"}]}]);return($?.client??this.client).post({url:"/mcp/{name}/disconnect",...$,...X})}_auth;get auth(){return this._auth??=new a$({client:this.client})}}class e$ extends L{next(O,$){let X=Z([O],[{args:[{in:"query",key:"directory"},{in:"query",key:"workspace"}]}]);return($?.client??this.client).get({url:"/tui/control/next",...$,...X})}response(O,$){let X=Z([O],[{args:[{in:"query",key:"directory"},{in:"query",key:"workspace"},{key:"body",map:"body"}]}]);return($?.client??this.client).post({url:"/tui/control/response",...$,...X,headers:{"Content-Type":"application/json",...$?.headers,...X.headers}})}}class $O extends L{appendPrompt(O,$){let X=Z([O],[{args:[{in:"query",key:"directory"},{in:"query",key:"workspace"},{in:"body",key:"text"}]}]);return($?.client??this.client).post({url:"/tui/append-prompt",...$,...X,headers:{"Content-Type":"application/json",...$?.headers,...X.headers}})}openHelp(O,$){let X=Z([O],[{args:[{in:"query",key:"directory"},{in:"query",key:"workspace"}]}]);return($?.client??this.client).post({url:"/tui/open-help",...$,...X})}openSessions(O,$){let X=Z([O],[{args:[{in:"query",key:"directory"},{in:"query",key:"workspace"}]}]);return($?.client??this.client).post({url:"/tui/open-sessions",...$,...X})}openThemes(O,$){let X=Z([O],[{args:[{in:"query",key:"directory"},{in:"query",key:"workspace"}]}]);return($?.client??this.client).post({url:"/tui/open-themes",...$,...X})}openModels(O,$){let X=Z([O],[{args:[{in:"query",key:"directory"},{in:"query",key:"workspace"}]}]);return($?.client??this.client).post({url:"/tui/open-models",...$,...X})}submitPrompt(O,$){let X=Z([O],[{args:[{in:"query",key:"directory"},{in:"query",key:"workspace"}]}]);return($?.client??this.client).post({url:"/tui/submit-prompt",...$,...X})}clearPrompt(O,$){let X=Z([O],[{args:[{in:"query",key:"directory"},{in:"query",key:"workspace"}]}]);return($?.client??this.client).post({url:"/tui/clear-prompt",...$,...X})}executeCommand(O,$){let X=Z([O],[{args:[{in:"query",key:"directory"},{in:"query",key:"workspace"},{in:"body",key:"command"}]}]);return($?.client??this.client).post({url:"/tui/execute-command",...$,...X,headers:{"Content-Type":"application/json",...$?.headers,...X.headers}})}showToast(O,$){let X=Z([O],[{args:[{in:"query",key:"directory"},{in:"query",key:"workspace"},{in:"body",key:"title"},{in:"body",key:"message"},{in:"body",key:"variant"},{in:"body",key:"duration"}]}]);return($?.client??this.client).post({url:"/tui/show-toast",...$,...X,headers:{"Content-Type":"application/json",...$?.headers,...X.headers}})}publish(O,$){let X=Z([O],[{args:[{in:"query",key:"directory"},{in:"query",key:"workspace"},{key:"body",map:"body"}]}]);return($?.client??this.client).post({url:"/tui/publish",...$,...X,headers:{"Content-Type":"application/json",...$?.headers,...X.headers}})}selectSession(O,$){let X=Z([O],[{args:[{in:"query",key:"directory"},{in:"query",key:"workspace"},{in:"body",key:"sessionID"}]}]);return($?.client??this.client).post({url:"/tui/select-session",...$,...X,headers:{"Content-Type":"application/json",...$?.headers,...X.headers}})}_control;get control(){return this._control??=new e$({client:this.client})}}class OO extends L{dispose(O,$){let X=Z([O],[{args:[{in:"query",key:"directory"},{in:"query",key:"workspace"}]}]);return($?.client??this.client).post({url:"/instance/dispose",...$,...X})}}class XO extends L{get(O,$){let X=Z([O],[{args:[{in:"query",key:"directory"},{in:"query",key:"workspace"}]}]);return($?.client??this.client).get({url:"/path",...$,...X})}}class ZO extends L{get(O,$){let X=Z([O],[{args:[{in:"query",key:"directory"},{in:"query",key:"workspace"}]}]);return($?.client??this.client).get({url:"/vcs",...$,...X})}diff(O,$){let X=Z([O],[{args:[{in:"query",key:"directory"},{in:"query",key:"workspace"},{in:"query",key:"mode"}]}]);return($?.client??this.client).get({url:"/vcs/diff",...$,...X})}}class GO extends L{list(O,$){let X=Z([O],[{args:[{in:"query",key:"directory"},{in:"query",key:"workspace"}]}]);return($?.client??this.client).get({url:"/command",...$,...X})}}class YO extends L{status(O,$){let X=Z([O],[{args:[{in:"query",key:"directory"},{in:"query",key:"workspace"}]}]);return($?.client??this.client).get({url:"/lsp",...$,...X})}}class JO extends L{status(O,$){let X=Z([O],[{args:[{in:"query",key:"directory"},{in:"query",key:"workspace"}]}]);return($?.client??this.client).get({url:"/formatter",...$,...X})}}class m extends L{static __registry=new w$;constructor(O){super(O);m.__registry.set(this,O?.key)}_global;get global(){return this._global??=new F$({client:this.client})}_auth;get auth(){return this._auth??=new Q$({client:this.client})}_app;get app(){return this._app??=new T$({client:this.client})}_experimental;get experimental(){return this._experimental??=new k$({client:this.client})}_project;get project(){return this._project??=new A$({client:this.client})}_pty;get pty(){return this._pty??=new h$({client:this.client})}_config;get config(){return this._config??=new P$({client:this.client})}_tool;get tool(){return this._tool??=new g$({client:this.client})}_worktree;get worktree(){return this._worktree??=new f$({client:this.client})}_session;get session(){return this._session??=new b$({client:this.client})}_part;get part(){return this._part??=new v$({client:this.client})}_permission;get permission(){return this._permission??=new y$({client:this.client})}_qredits;get qredits(){return this._qredits??=new C$({client:this.client})}_workflow;get workflow(){return this._workflow??=new c$({client:this.client})}_question;get question(){return this._question??=new d$({client:this.client})}_bash;get bash(){return this._bash??=new m$({client:this.client})}_provider;get provider(){return this._provider??=new n$({client:this.client})}_sync;get sync(){return this._sync??=new r$({client:this.client})}_find;get find(){return this._find??=new i$({client:this.client})}_file;get file(){return this._file??=new t$({client:this.client})}_event;get event(){return this._event??=new s$({client:this.client})}_mcp;get mcp(){return this._mcp??=new o$({client:this.client})}_tui;get tui(){return this._tui??=new $O({client:this.client})}_instance;get instance(){return this._instance??=new OO({client:this.client})}_path;get path(){return this._path??=new XO({client:this.client})}_vcs;get vcs(){return this._vcs??=new ZO({client:this.client})}_command;get command(){return this._command??=new GO({client:this.client})}_lsp;get lsp(){return this._lsp??=new YO({client:this.client})}_formatter;get formatter(){return this._formatter??=new JO({client:this.client})}}function AO(O,$,X){if(!O)return;if(!$)return O;if(O===$)return $;if(X&&O===X($))return $;return O}function hO(O,$){if(O.method!=="GET"&&O.method!=="HEAD")return O;let X=new URL(O.url),W=!1;for(let[D,G]of[["x-qitqode-directory","directory"],["x-qitqode-workspace","workspace"]]){let Y=AO(O.headers.get(D),G==="directory"?$.directory:$.workspace,G==="directory"?encodeURIComponent:void 0);if(!Y)continue;if(!X.searchParams.has(G))X.searchParams.set(G,Y);W=!0}if(!W)return O;let J=new Request(X,O);return J.headers.delete("x-qitqode-directory"),J.headers.delete("x-qitqode-workspace"),J}function PO(O){if(O=WO(O),O?.experimental_workspaceID)O.headers={...O.headers,"x-qitqode-workspace":O.experimental_workspaceID};let $=g(O);return $.interceptors.request.use((X)=>hO(X,{directory:O?.directory,workspace:O?.experimental_workspaceID})),$.interceptors.response.use((X)=>{if(X.headers.get("content-type")==="text/html")throw Error("Request is not supported by this version of QitQode Server (Server responded with text/html)");return X}),new m({client:$})}var bO=gO(fO(),1);var Z$={};yO(Z$,{toolDescriptionEffect:()=>lO,resolveWorkflowSummaries:()=>dO,resolveWorkflowSpec:()=>uO,resolveToolDescription:()=>zO,resolvePrompt:()=>IO,resolveGetHistory:()=>iO,resolveGetBalance:()=>rO,resolveForgewiseConfig:()=>pO,resolveFetchQreditsBalance:()=>tO,resolveBashArity:()=>mO,resolveAgentPrompt:()=>cO,remoteStats:()=>T,clearRemoteCache:()=>CO,BackendRemote:()=>Z$,BackendAuthRejectedError:()=>h});var q=DO.create({service:"backend.remote"}),$$=30000,O$=5000,H=new Map,T={failures:0,authRejections:0,missingPrompts:0,missingToolDescriptions:0},a=new Set,o=new Set;class h extends Error{name="BackendAuthRejectedError";constructor(O){super(VO.copy().invalidCredentials(O))}}function CO(){H.clear(),a.clear(),o.clear()}async function b(O,$){let X=k.QITQODE_BACKEND_URL,W=Date.now(),J=`${X}::${O}`,D=H.get(J);if(D&&D.expires>W)return D.value;try{let G=await l(),Y=G?n(G):void 0,z=await $(UO({baseUrl:X,headers:Y,fetch:(I,U)=>fetch(I,{...U,signal:U?.signal??AbortSignal.timeout(O$)})}));return H.set(J,{value:z,expires:W+$$}),z}catch(G){if(G instanceof LO)throw T.authRejections++,await e().catch(()=>{}),q.warn("backend rejected the credential; prompting re-auth",{cacheKey:O,baseUrl:X,status:G.status}),new h(`HTTP ${G.status}`);throw T.failures++,q.warn("backend request failed; surfacing error",{cacheKey:O,baseUrl:X,error:G instanceof Error?G.message:String(G)}),G}}async function IO(O){if(O.indexOf("/")<=0)return;return b(`prompt:${O}`,($)=>$.prompt(O).then((X)=>X??void 0))}async function cO(O){let $=`agent/${O}`,X=await IO($);if(X===void 0||X===""){if(!a.has(O))a.add(O),T.missingPrompts++,q.warn("backend served no content for agent prompt; running with an empty prompt",{prompt:$,baseUrl:k.QITQODE_BACKEND_URL,missingPrompts:T.missingPrompts})}return X}async function dO(){return b("workflow.list",(O)=>O.workflowSummaries())}async function uO(O){return b(`workflow.get:${O}`,($)=>$.workflowSpec(O).then((X)=>X??void 0))}async function mO(){return b("permission.arity",(O)=>O.bashArity())}async function zO(O){let $=await b(`tool.description:${O}`,(X)=>X.toolDescription(O).then((W)=>W??void 0));if($===void 0||$===""){if(!o.has(O))o.add(O),T.missingToolDescriptions++,q.warn("backend served no content for tool description; running with an empty description",{tool:O,baseUrl:k.QITQODE_BACKEND_URL,missingToolDescriptions:T.missingToolDescriptions})}return $}function lO(O){return f.promise(()=>zO(O)).pipe(f.catchDefect(($)=>$ instanceof h?f.succeed(void 0):f.die($)))}async function X$(O,$,X,W={}){let J=k.QITQODE_BACKEND_URL,D=`${J}::post:${O}`;if(!W.noCache){let G=Date.now(),Y=H.get(D);if(Y&&Y.expires>G)return Y.value}try{let G=await l(),Y=G?n(G):{},V=await fetch(`${J}/${$}`,{method:"POST",headers:{"Content-Type":"application/json",...Y},body:JSON.stringify(X),signal:W.signal});if(V.status===401||V.status===403){let U=await V.text().catch(()=>"");if(U.includes("ERR_GATEWAY_REQUIRED"))throw Error(`Backend routing error: ${U}`);throw T.authRejections++,await e().catch(()=>{}),q.warn("backend rejected the credential; prompting re-auth",{fnName:$,baseUrl:J,status:V.status}),new h(`HTTP ${V.status}`)}if(!V.ok)throw Error(`Backend POST /${$} failed: ${V.status}`);let z=await V.json();if(!z.success)throw Error(`Backend POST /${$} returned failure: ${z.error??"unknown error"}`);let I=z.data;if(!W.noCache)H.set(D,{value:I,expires:Date.now()+$$});return I}catch(G){if(G instanceof h)throw G;throw T.failures++,q.warn("backend POST request failed; surfacing error",{fnName:$,baseUrl:J,error:G instanceof Error?G.message:String(G)}),G}}async function nO(O,$,X){let W=k.QITQODE_BACKEND_URL,J=`${W}::public:${O}`,D=Date.now(),G=H.get(J);if(G&&G.expires>D)return G.value;try{let Y=await fetch(`${W}/${$}`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(X),signal:AbortSignal.timeout(O$)});if(!Y.ok)throw Error(`Backend public POST /${$} failed: ${Y.status}`);let V=await Y.json();if(!V.success)throw Error(`Backend public POST /${$} returned failure: ${V.error??"unknown error"}`);let z=V.data;return H.set(J,{value:z,expires:D+$$}),z}catch(Y){throw T.failures++,q.warn("backend public request failed; surfacing error",{fnName:$,baseUrl:W,error:Y instanceof Error?Y.message:String(Y)}),Y}}async function pO(){try{return await nO("forgewise.config","forgewiseConfig",{})}catch(O){let $=await l().catch(()=>null);if(!$)throw O;let X=k.QITQODE_BACKEND_URL,W=await fetch(`${X}/forgewiseConfig`,{method:"POST",headers:{"Content-Type":"application/json",...n($)},body:JSON.stringify({}),signal:AbortSignal.timeout(O$)}).catch(()=>null);if(!W?.ok)throw O;let J=await W.json().catch(()=>null);if(!J?.success)throw O;return J.data}}async function rO(O){return X$("qredits.balance","getBalance",O,{noCache:!0})}async function iO(O){return X$("qredits.history","getHistory",O,{noCache:!0})}async function tO(O){return X$("forgewise.qredits.balance","fetchQreditsBalance",O,{noCache:!0})}
8
- export{oO as Ah,PO as Bh,pO as Ch,iO as Dh,tO as Eh,Z$ as Fh};
@@ -1,2 +0,0 @@
1
- // @bun
2
- import{Fd as q,Gd as K,Hd as D,Kd as L,Ld as N}from"./chunk-9g05wsae.js";import"./chunk-x1dfc7qd.js";import{Sf as B}from"./chunk-ntmn6epc.js";import{qh as G}from"./chunk-0jv8r99k.js";import"./chunk-th189x63.js";import"./chunk-k6eyc1wv.js";import"./chunk-q6x5bmc3.js";import"./chunk-n1m5qdf5.js";import"./chunk-zeh3mjgp.js";import"./chunk-prrrw8t8.js";import"./chunk-tz8qhbk9.js";import"./chunk-k19zvbzh.js";import"./chunk-3f6t3wde.js";import{hl as C}from"./chunk-b5h8vd5n.js";import"./chunk-jee9y4t0.js";import"./chunk-50aznc8e.js";import"./chunk-c4x99ayd.js";import"./chunk-73d0dy03.js";import"./chunk-ha5qct06.js";import"./chunk-w8xaw2dv.js";import"./chunk-tq258v8s.js";import"./chunk-ds162xgb.js";import"./chunk-jfy6bfvv.js";import"./chunk-2p6w3w8f.js";import"./chunk-98nh88th.js";import"./chunk-t7v8wzr9.js";import"./chunk-er5q8nhp.js";import"./chunk-cqtkxwd8.js";import"./chunk-h6htvj2y.js";import"./chunk-2qy62cv4.js";import"./chunk-t2n6fmpy.js";import"./chunk-x1naayst.js";import"./chunk-ng85b73s.js";import"./chunk-351wfvhp.js";import"./chunk-hmm1m733.js";import"./chunk-2bxy8zm1.js";import"./chunk-qq9pvscd.js";import"./chunk-3nc9wy1m.js";import"./chunk-r8ddb02d.js";import"./chunk-dhvwrrqx.js";import"./chunk-56cty7nr.js";import"./chunk-thbjhgw0.js";import{Gs as J}from"./chunk-p20ft5mj.js";import"./chunk-b5x3zghc.js";import"./chunk-t1f7jeat.js";import"./chunk-tk6gjy9d.js";import"./chunk-pkdk0ppc.js";import"./chunk-hrnx60em.js";import"./chunk-bbznk59q.js";import"./chunk-01gtn79f.js";import"./chunk-meaa7wrs.js";import"./chunk-0ddhkapd.js";import"./chunk-gvj8qg7x.js";import"./chunk-fa03gsff.js";var X={command:"upgrade [target]",describe:"upgrade qitqode to the latest or a specific version",builder:(z)=>{return z.positional("target",{describe:"version to upgrade to, for ex '0.1.48' or 'v0.1.48'",type:"string"}).option("method",{alias:"m",describe:"installation method to use",type:"string",choices:["curl","npm","pnpm","bun","brew","choco","scoop"]})},handler:async(z)=>{B.empty(),B.println(B.logo(" ")),B.empty(),K("Upgrade");let O=await G.runPromise(C.Service.use((j)=>j.method())),E=z.method??O;if(E==="unknown"){if(q.error(`qitqode is installed to ${process.execPath} and may be managed by a package manager`),!await N({message:"Install anyways?",options:[{label:"Yes",value:!0},{label:"No",value:!1}],initialValue:!1})){D("Done");return}}q.info("Using method: "+E);let F=z.target?z.target.replace(/^v/,""):await G.runPromise(C.Service.use((j)=>j.latest()));if(J===F){q.warn(`qitqode upgrade skipped: ${F} is already installed`),D("Done");return}q.info(`From ${J} \u2192 ${F}`);let H=L();H.start("Upgrading...");let x=await G.runPromise(C.Service.use((j)=>j.upgrade(E,F))).catch((j)=>j);if(x){if(H.stop("Upgrade failed",1),x instanceof C.UpgradeFailedError)if(E==="choco"&&x.stderr.includes("not running from an elevated command shell"))q.error("Please run the terminal as Administrator and try again");else q.error(x.stderr);else if(x instanceof Error)q.error(x.message);D("Done");return}H.stop("Upgrade complete"),D("Done")}};export{X as UpgradeCommand};
@@ -1,2 +0,0 @@
1
- // @bun
2
- import{Os as c,Ps as d,Qs as e,Ss as f,Ts as h,Us as i,Vs as j,Ws as k,Ys as l,Zs as m,mt as n}from"./chunk-p20ft5mj.js";import{Gt as g,vt as b}from"./chunk-b5x3zghc.js";import"./chunk-t1f7jeat.js";import"./chunk-tk6gjy9d.js";import{_t as a}from"./chunk-pkdk0ppc.js";import"./chunk-hrnx60em.js";import"./chunk-bbznk59q.js";import"./chunk-01gtn79f.js";import"./chunk-meaa7wrs.js";import"./chunk-fa03gsff.js";export{f as getEnvInfo,a as Wildcard,m as Token,l as Rpc,b as Process,n as Log,k as Lock,j as Locale,i as LocalContext,h as Keybind,g as Filesystem,e as EffectUtil,d as Color,c as Archive};
@@ -1,2 +0,0 @@
1
- // @bun
2
- import{Eg as o}from"./chunk-awdpkgxf.js";import{pP as n}from"./chunk-fa03gsff.js";async function a(){try{let{toJsonSchema:t}=await import("./chunk-6r4gn18m.js");return t}catch{throw new o("@valibot/to-json-schema")}}export{a as default};
@@ -1,2 +0,0 @@
1
- // @bun
2
- import"./chunk-fa03gsff.js";var l="./tree-sitter-javascript-nd0q4pe9.wasm";export{l as default};
@@ -1,2 +0,0 @@
1
- // @bun
2
- import"./chunk-fa03gsff.js";var L="./libopentui-430t0qv0.dylib";export{L as default};
@@ -1,2 +0,0 @@
1
- // @bun
2
- import{ur as a,vr as b,wr as c}from"./chunk-2bxy8zm1.js";import"./chunk-qq9pvscd.js";import"./chunk-3nc9wy1m.js";import"./chunk-p20ft5mj.js";import"./chunk-b5x3zghc.js";import"./chunk-t1f7jeat.js";import"./chunk-tk6gjy9d.js";import"./chunk-pkdk0ppc.js";import"./chunk-hrnx60em.js";import"./chunk-bbznk59q.js";import"./chunk-01gtn79f.js";import"./chunk-meaa7wrs.js";import"./chunk-fa03gsff.js";export{c as makeRuntime,a as attachWith,b as attach};
@@ -1,2 +0,0 @@
1
- // @bun
2
- import{pP as t}from"./chunk-fa03gsff.js";var e=await import("./chunk-367rm03h.js",{with:{type:"file"}}),a=e.default;export{a as default};
@@ -1,2 +0,0 @@
1
- // @bun
2
- import"./chunk-fa03gsff.js";var t="./highlights-ghv9g403.scm";export{t as default};
@@ -1,2 +0,0 @@
1
- // @bun
2
- import{pP as t}from"./chunk-fa03gsff.js";var e=await import("./chunk-atjzxp7b.js",{with:{type:"file"}}),a=e.default;export{a as default};
@@ -1,2 +0,0 @@
1
- // @bun
2
- import{pe as a}from"./chunk-6w15nfph.js";import"./chunk-a2ty2e0g.js";import"./chunk-78wt9ad8.js";import"./chunk-60dxyp37.js";import"./chunk-fa03gsff.js";export{a as fromProcess};
@@ -1,2 +0,0 @@
1
- // @bun
2
- import"./chunk-fa03gsff.js";var r="./highlights-eq9cgrbb.scm";export{r as default};
@@ -1,2 +0,0 @@
1
- // @bun
2
- import{ph as a,qh as b}from"./chunk-0jv8r99k.js";import"./chunk-th189x63.js";import"./chunk-k6eyc1wv.js";import"./chunk-q6x5bmc3.js";import"./chunk-n1m5qdf5.js";import"./chunk-zeh3mjgp.js";import"./chunk-prrrw8t8.js";import"./chunk-tz8qhbk9.js";import"./chunk-k19zvbzh.js";import"./chunk-3f6t3wde.js";import"./chunk-b5h8vd5n.js";import"./chunk-jee9y4t0.js";import"./chunk-50aznc8e.js";import"./chunk-c4x99ayd.js";import"./chunk-73d0dy03.js";import"./chunk-ha5qct06.js";import"./chunk-w8xaw2dv.js";import"./chunk-tq258v8s.js";import"./chunk-ds162xgb.js";import"./chunk-jfy6bfvv.js";import"./chunk-2p6w3w8f.js";import"./chunk-98nh88th.js";import"./chunk-t7v8wzr9.js";import"./chunk-er5q8nhp.js";import"./chunk-cqtkxwd8.js";import"./chunk-h6htvj2y.js";import"./chunk-2qy62cv4.js";import"./chunk-t2n6fmpy.js";import"./chunk-x1naayst.js";import"./chunk-ng85b73s.js";import"./chunk-351wfvhp.js";import"./chunk-hmm1m733.js";import"./chunk-2bxy8zm1.js";import"./chunk-qq9pvscd.js";import"./chunk-3nc9wy1m.js";import"./chunk-r8ddb02d.js";import"./chunk-dhvwrrqx.js";import"./chunk-56cty7nr.js";import"./chunk-thbjhgw0.js";import"./chunk-p20ft5mj.js";import"./chunk-b5x3zghc.js";import"./chunk-t1f7jeat.js";import"./chunk-tk6gjy9d.js";import"./chunk-pkdk0ppc.js";import"./chunk-hrnx60em.js";import"./chunk-bbznk59q.js";import"./chunk-01gtn79f.js";import"./chunk-meaa7wrs.js";import"./chunk-0ddhkapd.js";import"./chunk-gvj8qg7x.js";import"./chunk-fa03gsff.js";export{b as AppRuntime,a as AppLayer};
@@ -1,4 +0,0 @@
1
- // @bun
2
- import{zd as Xf}from"./chunk-2epf5806.js";import{Bd as Jf}from"./chunk-07b36w5g.js";import{Od as Gf}from"./chunk-wmmck56g.js";import{Lf as Af}from"./chunk-18xhxdsh.js";import{Zf as jf}from"./chunk-h5wh2d49.js";import"./chunk-xjdxyeja.js";import"./chunk-1zb95qfx.js";import"./chunk-cckshvkb.js";import"./chunk-hkqcpdmt.js";import"./chunk-nfg7nt13.js";import"./chunk-awdpkgxf.js";import"./chunk-8x6x3g16.js";import{gh as Uw,qh as Cw}from"./chunk-0jv8r99k.js";import"./chunk-th189x63.js";import{Bh as yf}from"./chunk-k6eyc1wv.js";import"./chunk-q6x5bmc3.js";import"./chunk-n1m5qdf5.js";import"./chunk-zeh3mjgp.js";import"./chunk-prrrw8t8.js";import"./chunk-tz8qhbk9.js";import"./chunk-k19zvbzh.js";import{Uk as Qf,Vk as h,Xk as _f,_j as zw,ek as H,fk as P}from"./chunk-3f6t3wde.js";import"./chunk-b5h8vd5n.js";import"./chunk-jee9y4t0.js";import"./chunk-50aznc8e.js";import"./chunk-c4x99ayd.js";import"./chunk-73d0dy03.js";import"./chunk-ha5qct06.js";import"./chunk-w8xaw2dv.js";import"./chunk-tq258v8s.js";import"./chunk-ds162xgb.js";import"./chunk-jfy6bfvv.js";import"./chunk-2p6w3w8f.js";import"./chunk-98nh88th.js";import"./chunk-t7v8wzr9.js";import{Lq as $f}from"./chunk-er5q8nhp.js";import"./chunk-cqtkxwd8.js";import"./chunk-h6htvj2y.js";import"./chunk-2qy62cv4.js";import"./chunk-t2n6fmpy.js";import"./chunk-x1naayst.js";import"./chunk-ng85b73s.js";import"./chunk-351wfvhp.js";import"./chunk-hmm1m733.js";import"./chunk-2bxy8zm1.js";import"./chunk-qq9pvscd.js";import"./chunk-3nc9wy1m.js";import"./chunk-r8ddb02d.js";import"./chunk-dhvwrrqx.js";import"./chunk-56cty7nr.js";import"./chunk-thbjhgw0.js";import{Gs as Df,_s as ff,mt as V}from"./chunk-p20ft5mj.js";import{Gt as Hw}from"./chunk-b5x3zghc.js";import"./chunk-t1f7jeat.js";import"./chunk-tk6gjy9d.js";import"./chunk-pkdk0ppc.js";import{Cu as w}from"./chunk-hrnx60em.js";import"./chunk-bbznk59q.js";import"./chunk-01gtn79f.js";import"./chunk-meaa7wrs.js";import"./chunk-0ddhkapd.js";import"./chunk-gvj8qg7x.js";import{nP as mD}from"./chunk-fa03gsff.js";var B={authenticate:"authenticate",initialize:"initialize",session_cancel:"session/cancel",session_close:"session/close",session_fork:"session/fork",session_list:"session/list",session_load:"session/load",session_new:"session/new",session_prompt:"session/prompt",session_resume:"session/resume",session_set_config_option:"session/set_config_option",session_set_mode:"session/set_mode",session_set_model:"session/set_model"},L={fs_read_text_file:"fs/read_text_file",fs_write_text_file:"fs/write_text_file",session_request_permission:"session/request_permission",session_update:"session/update",terminal_create:"terminal/create",terminal_kill:"terminal/kill",terminal_output:"terminal/output",terminal_release:"terminal/release",terminal_wait_for_exit:"terminal/wait_for_exit"};var Zf=w.object({_meta:w.record(w.string(),w.unknown()).nullish(),terminal:w.boolean().optional().default(!1)}),Of=w.object({_meta:w.record(w.string(),w.unknown()).nullish(),label:w.string().nullish(),name:w.string(),optional:w.boolean().optional().default(!1),secret:w.boolean().optional().default(!0)}),Nf=w.object({_meta:w.record(w.string(),w.unknown()).nullish(),description:w.string().nullish(),id:w.string(),name:w.string()}),Wf=w.object({_meta:w.record(w.string(),w.unknown()).nullish(),description:w.string().nullish(),id:w.string(),link:w.string().nullish(),name:w.string(),vars:w.array(Of)}),Bf=w.object({_meta:w.record(w.string(),w.unknown()).nullish(),args:w.array(w.string()).optional(),description:w.string().nullish(),env:w.record(w.string(),w.string()).optional(),id:w.string(),name:w.string()}),Kf=w.union([Wf.and(w.object({type:w.literal("env_var")})),Bf.and(w.object({type:w.literal("terminal")})),Nf]),p=w.object({_meta:w.record(w.string(),w.unknown()).nullish(),methodId:w.string()}),Lf=w.object({_meta:w.record(w.string(),w.unknown()).nullish()}),Ff=w.object({_meta:w.record(w.string(),w.unknown()).nullish(),blob:w.string(),mimeType:w.string().nullish(),uri:w.string()}),kf=w.object({_meta:w.record(w.string(),w.unknown()).nullish()}),xf=w.object({amount:w.number(),currency:w.string()}),Vf=w.object({_meta:w.record(w.string(),w.unknown()).nullish(),terminalId:w.string()}),Pf=w.object({_meta:w.record(w.string(),w.unknown()).nullish(),newText:w.string(),oldText:w.string().nullish(),path:w.string()}),Mw=w.object({_meta:w.record(w.string(),w.unknown()).nullish(),name:w.string(),value:w.string()}),Hf=w.union([w.literal(-32700),w.literal(-32600),w.literal(-32601),w.literal(-32602),w.literal(-32603),w.literal(-32800),w.literal(-32000),w.literal(-32002),w.number().int().min(-2147483648,{message:"Invalid value: Expected int32 to be >= -2147483648"}).max(2147483647,{message:"Invalid value: Expected int32 to be <= 2147483647"})]),Ew=w.object({code:Hf,data:w.unknown().optional(),message:w.string()}),Iw=w.unknown(),qw=w.unknown(),Sw=w.unknown(),Tf=w.object({_meta:w.record(w.string(),w.unknown()).nullish(),readTextFile:w.boolean().optional().default(!1),writeTextFile:w.boolean().optional().default(!1)}),hf=w.object({_meta:w.record(w.string(),w.unknown()).nullish(),auth:Zf.optional().default({terminal:!1}),fs:Tf.optional().default({readTextFile:!1,writeTextFile:!1}),terminal:w.boolean().optional().default(!1)}),cw=w.object({_meta:w.record(w.string(),w.unknown()).nullish(),name:w.string(),value:w.string()}),Rw=w.object({_meta:w.record(w.string(),w.unknown()).nullish(),name:w.string(),title:w.string().nullish(),version:w.string()}),bf=w.object({_meta:w.record(w.string(),w.unknown()).nullish()}),m=w.object({_meta:w.record(w.string(),w.unknown()).nullish(),cursor:w.string().nullish(),cwd:w.string().nullish()}),Uf=w.object({_meta:w.record(w.string(),w.unknown()).nullish(),http:w.boolean().optional().default(!1),sse:w.boolean().optional().default(!1)}),Cf=w.object({_meta:w.record(w.string(),w.unknown()).nullish(),headers:w.array(cw),name:w.string(),url:w.string()}),vf=w.object({_meta:w.record(w.string(),w.unknown()).nullish(),headers:w.array(cw),name:w.string(),url:w.string()}),Mf=w.object({_meta:w.record(w.string(),w.unknown()).nullish(),args:w.array(w.string()),command:w.string(),env:w.array(Mw),name:w.string()}),I=w.union([Cf.and(w.object({type:w.literal("http")})),vf.and(w.object({type:w.literal("sse")})),Mf]),o=w.string(),Ef=w.object({_meta:w.record(w.string(),w.unknown()).nullish(),description:w.string().nullish(),modelId:o,name:w.string()}),r=w.object({_meta:w.record(w.string(),w.unknown()).nullish(),cwd:w.string(),mcpServers:w.array(I)}),uw=w.string(),If=w.union([w.literal("allow_once"),w.literal("allow_always"),w.literal("reject_once"),w.literal("reject_always")]),qf=w.object({_meta:w.record(w.string(),w.unknown()).nullish(),kind:If,name:w.string(),optionId:uw}),Sf=w.union([w.literal("high"),w.literal("medium"),w.literal("low")]),cf=w.union([w.literal("pending"),w.literal("in_progress"),w.literal("completed")]),Rf=w.object({_meta:w.record(w.string(),w.unknown()).nullish(),content:w.string(),priority:Sf,status:cf}),uf=w.object({_meta:w.record(w.string(),w.unknown()).nullish(),entries:w.array(Rf)}),gf=w.object({_meta:w.record(w.string(),w.unknown()).nullish(),audio:w.boolean().optional().default(!1),embeddedContext:w.boolean().optional().default(!1),image:w.boolean().optional().default(!1)}),gw=w.number().int().gte(0).lte(65535),a=w.object({_meta:w.record(w.string(),w.unknown()).nullish(),clientCapabilities:hf.optional().default({auth:{terminal:!1},fs:{readTextFile:!1,writeTextFile:!1},terminal:!1}),clientInfo:Rw.nullish(),protocolVersion:gw}),lf=w.object({_meta:w.record(w.string(),w.unknown()).nullish(),content:w.string()}),tf=w.object({_meta:w.record(w.string(),w.unknown()).nullish()}),T=w.union([w.number(),w.string()]).nullable(),sD=w.object({_meta:w.record(w.string(),w.unknown()).nullish(),requestId:T}),df=w.enum(["assistant","user"]),M=w.object({_meta:w.record(w.string(),w.unknown()).nullish(),audience:w.array(df).nullish(),lastModified:w.string().nullish(),priority:w.number().nullish()}),nf=w.object({_meta:w.record(w.string(),w.unknown()).nullish(),annotations:M.nullish(),data:w.string(),mimeType:w.string()}),pf=w.object({_meta:w.record(w.string(),w.unknown()).nullish(),annotations:M.nullish(),data:w.string(),mimeType:w.string(),uri:w.string().nullish()}),mf=w.object({_meta:w.record(w.string(),w.unknown()).nullish(),annotations:M.nullish(),description:w.string().nullish(),mimeType:w.string().nullish(),name:w.string(),size:w.number().nullish(),title:w.string().nullish(),uri:w.string()}),of=w.object({_meta:w.record(w.string(),w.unknown()).nullish(),optionId:uw}),rf=w.union([w.object({outcome:w.literal("cancelled")}),of.and(w.object({outcome:w.literal("selected")}))]),af=w.object({_meta:w.record(w.string(),w.unknown()).nullish(),outcome:rf}),zf=w.object({_meta:w.record(w.string(),w.unknown()).nullish()}),sf=w.object({currentValue:w.boolean()}),ef=w.string(),lw=w.string(),wD=w.union([w.literal("mode"),w.literal("model"),w.literal("thought_level"),w.string()]),z=w.string(),iw=w.object({_meta:w.record(w.string(),w.unknown()).nullish(),description:w.string().nullish(),name:w.string(),value:z}),fD=w.object({_meta:w.record(w.string(),w.unknown()).nullish(),group:ef,name:w.string(),options:w.array(iw)}),DD=w.union([w.array(iw),w.array(fD)]),$D=w.object({currentValue:z,options:DD}),C=w.intersection(w.union([$D.and(w.object({type:w.literal("select")})),sf.and(w.object({type:w.literal("boolean")}))]),w.object({_meta:w.record(w.string(),w.unknown()).nullish(),category:wD.nullish(),description:w.string().nullish(),id:lw,name:w.string()})),QD=w.object({_meta:w.record(w.string(),w.unknown()).nullish(),configOptions:w.array(C)}),_D=w.object({_meta:w.record(w.string(),w.unknown()).nullish()}),K=w.string(),s=w.object({_meta:w.record(w.string(),w.unknown()).nullish(),sessionId:K}),eD=w.object({method:w.string(),params:w.union([s,Iw]).nullish()}),e=w.object({_meta:w.record(w.string(),w.unknown()).nullish(),sessionId:K}),ww=w.object({_meta:w.record(w.string(),w.unknown()).nullish(),args:w.array(w.string()).optional(),command:w.string(),cwd:w.string().nullish(),env:w.array(Mw).optional(),outputByteLimit:w.number().nullish(),sessionId:K}),fw=w.object({_meta:w.record(w.string(),w.unknown()).nullish(),cwd:w.string(),mcpServers:w.array(I).optional(),sessionId:K}),Dw=w.object({_meta:w.record(w.string(),w.unknown()).nullish(),sessionId:K,terminalId:w.string()}),$w=w.object({_meta:w.record(w.string(),w.unknown()).nullish(),cwd:w.string(),mcpServers:w.array(I),sessionId:K}),Qw=w.object({_meta:w.record(w.string(),w.unknown()).nullish(),limit:w.number().int().gte(0).max(4294967295,{message:"Invalid value: Expected uint32 to be <= 4294967295"}).nullish(),line:w.number().int().gte(0).max(4294967295,{message:"Invalid value: Expected uint32 to be <= 4294967295"}).nullish(),path:w.string(),sessionId:K}),_w=w.object({_meta:w.record(w.string(),w.unknown()).nullish(),sessionId:K,terminalId:w.string()}),Aw=w.object({_meta:w.record(w.string(),w.unknown()).nullish(),cwd:w.string(),mcpServers:w.array(I).optional(),sessionId:K}),AD=w.object({_meta:w.record(w.string(),w.unknown()).nullish(),cwd:w.string(),sessionId:K,title:w.string().nullish(),updatedAt:w.string().nullish()}),yD=w.object({_meta:w.record(w.string(),w.unknown()).nullish(),nextCursor:w.string().nullish(),sessions:w.array(AD)}),jD=w.object({_meta:w.record(w.string(),w.unknown()).nullish(),title:w.string().nullish(),updatedAt:w.string().nullish()}),JD=w.object({_meta:w.record(w.string(),w.unknown()).nullish()}),q=w.string(),GD=w.object({_meta:w.record(w.string(),w.unknown()).nullish(),currentModeId:q}),XD=w.object({_meta:w.record(w.string(),w.unknown()).nullish(),description:w.string().nullish(),id:q,name:w.string()}),S=w.object({_meta:w.record(w.string(),w.unknown()).nullish(),availableModes:w.array(XD),currentModeId:q}),c=w.object({_meta:w.record(w.string(),w.unknown()).nullish(),availableModels:w.array(Ef),currentModelId:o}),YD=w.object({_meta:w.record(w.string(),w.unknown()).nullish(),configOptions:w.array(C).nullish(),models:c.nullish(),modes:S.nullish(),sessionId:K}),ZD=w.object({_meta:w.record(w.string(),w.unknown()).nullish(),configOptions:w.array(C).nullish(),models:c.nullish(),modes:S.nullish()}),OD=w.object({_meta:w.record(w.string(),w.unknown()).nullish(),configOptions:w.array(C).nullish(),models:c.nullish(),modes:S.nullish(),sessionId:K}),ND=w.object({_meta:w.record(w.string(),w.unknown()).nullish(),configOptions:w.array(C).nullish(),models:c.nullish(),modes:S.nullish()}),WD=w.object({_meta:w.record(w.string(),w.unknown()).nullish()}),BD=w.object({_meta:w.record(w.string(),w.unknown()).nullish(),close:zf.nullish(),fork:_D.nullish(),list:JD.nullish(),resume:WD.nullish()}),KD=w.object({_meta:w.record(w.string(),w.unknown()).nullish(),loadSession:w.boolean().optional().default(!1),mcpCapabilities:Uf.optional().default({http:!1,sse:!1}),promptCapabilities:gf.optional().default({audio:!1,embeddedContext:!1,image:!1}),sessionCapabilities:BD.optional().default({})}),LD=w.object({_meta:w.record(w.string(),w.unknown()).nullish(),agentCapabilities:KD.optional().default({loadSession:!1,mcpCapabilities:{http:!1,sse:!1},promptCapabilities:{audio:!1,embeddedContext:!1,image:!1},sessionCapabilities:{}}),agentInfo:Rw.nullish(),authMethods:w.array(Kf).optional().default([]),protocolVersion:gw}),yw=w.intersection(w.union([w.object({type:w.literal("boolean"),value:w.boolean()}),w.object({value:z})]),w.object({_meta:w.record(w.string(),w.unknown()).nullish(),configId:lw,sessionId:K})),FD=w.object({_meta:w.record(w.string(),w.unknown()).nullish(),configOptions:w.array(C)}),jw=w.object({_meta:w.record(w.string(),w.unknown()).nullish(),modeId:q,sessionId:K}),kD=w.object({_meta:w.record(w.string(),w.unknown()).nullish()}),Jw=w.object({_meta:w.record(w.string(),w.unknown()).nullish(),modelId:o,sessionId:K}),xD=w.object({_meta:w.record(w.string(),w.unknown()).nullish()}),VD=w.union([w.literal("end_turn"),w.literal("max_tokens"),w.literal("max_turn_requests"),w.literal("refusal"),w.literal("cancelled")]),PD=w.object({_meta:w.record(w.string(),w.unknown()).nullish(),terminalId:w.string()}),HD=w.object({_meta:w.record(w.string(),w.unknown()).nullish(),exitCode:w.number().int().gte(0).max(4294967295,{message:"Invalid value: Expected uint32 to be <= 4294967295"}).nullish(),signal:w.string().nullish()}),Gw=w.object({_meta:w.record(w.string(),w.unknown()).nullish(),sessionId:K,terminalId:w.string()}),TD=w.object({_meta:w.record(w.string(),w.unknown()).nullish(),exitStatus:HD.nullish(),output:w.string(),truncated:w.boolean()}),hD=w.object({_meta:w.record(w.string(),w.unknown()).nullish(),annotations:M.nullish(),text:w.string()}),bD=w.object({_meta:w.record(w.string(),w.unknown()).nullish(),mimeType:w.string().nullish(),text:w.string(),uri:w.string()}),UD=w.union([bD,Ff]),CD=w.object({_meta:w.record(w.string(),w.unknown()).nullish(),annotations:M.nullish(),resource:UD}),Xw=w.union([hD.and(w.object({type:w.literal("text")})),pf.and(w.object({type:w.literal("image")})),nf.and(w.object({type:w.literal("audio")})),mf.and(w.object({type:w.literal("resource_link")})),CD.and(w.object({type:w.literal("resource")}))]),vD=w.object({_meta:w.record(w.string(),w.unknown()).nullish(),content:Xw}),n=w.object({_meta:w.record(w.string(),w.unknown()).nullish(),content:Xw,messageId:w.string().nullish()}),Yw=w.object({_meta:w.record(w.string(),w.unknown()).nullish(),messageId:w.string().nullish(),prompt:w.array(Xw),sessionId:K}),w$=w.object({id:T,method:w.string(),params:w.union([a,p,r,$w,m,fw,Aw,e,jw,yw,Yw,Jw,qw]).nullish()}),tw=w.union([vD.and(w.object({type:w.literal("content")})),Pf.and(w.object({type:w.literal("diff")})),PD.and(w.object({type:w.literal("terminal")}))]),dw=w.string(),nw=w.object({_meta:w.record(w.string(),w.unknown()).nullish(),line:w.number().int().gte(0).max(4294967295,{message:"Invalid value: Expected uint32 to be <= 4294967295"}).nullish(),path:w.string()}),pw=w.union([w.literal("pending"),w.literal("in_progress"),w.literal("completed"),w.literal("failed")]),mw=w.union([w.literal("read"),w.literal("edit"),w.literal("delete"),w.literal("move"),w.literal("search"),w.literal("execute"),w.literal("think"),w.literal("fetch"),w.literal("switch_mode"),w.literal("other")]),MD=w.object({_meta:w.record(w.string(),w.unknown()).nullish(),content:w.array(tw).optional(),kind:mw.optional(),locations:w.array(nw).optional(),rawInput:w.unknown().optional(),rawOutput:w.unknown().optional(),status:pw.optional(),title:w.string(),toolCallId:dw}),ow=w.object({_meta:w.record(w.string(),w.unknown()).nullish(),content:w.array(tw).nullish(),kind:mw.nullish(),locations:w.array(nw).nullish(),rawInput:w.unknown().optional(),rawOutput:w.unknown().optional(),status:pw.nullish(),title:w.string().nullish(),toolCallId:dw}),Zw=w.object({_meta:w.record(w.string(),w.unknown()).nullish(),options:w.array(qf),sessionId:K,toolCall:ow}),ED=w.object({_meta:w.record(w.string(),w.unknown()).nullish(),hint:w.string()}),ID=ED,qD=w.object({_meta:w.record(w.string(),w.unknown()).nullish(),description:w.string(),input:ID.nullish(),name:w.string()}),SD=w.object({_meta:w.record(w.string(),w.unknown()).nullish(),availableCommands:w.array(qD)}),cD=w.object({cachedReadTokens:w.number().nullish(),cachedWriteTokens:w.number().nullish(),inputTokens:w.number(),outputTokens:w.number(),thoughtTokens:w.number().nullish(),totalTokens:w.number()}),RD=w.object({_meta:w.record(w.string(),w.unknown()).nullish(),stopReason:VD,usage:cD.nullish(),userMessageId:w.string().nullish()}),f$=w.union([w.object({id:T,result:w.union([LD,Lf,OD,ZD,yD,YD,ND,kf,kD,FD,RD,xD,Sw])}),w.object({error:Ew,id:T})]),uD=w.object({_meta:w.record(w.string(),w.unknown()).nullish(),cost:xf.nullish(),size:w.number(),used:w.number()}),gD=w.union([n.and(w.object({sessionUpdate:w.literal("user_message_chunk")})),n.and(w.object({sessionUpdate:w.literal("agent_message_chunk")})),n.and(w.object({sessionUpdate:w.literal("agent_thought_chunk")})),MD.and(w.object({sessionUpdate:w.literal("tool_call")})),ow.and(w.object({sessionUpdate:w.literal("tool_call_update")})),uf.and(w.object({sessionUpdate:w.literal("plan")})),SD.and(w.object({sessionUpdate:w.literal("available_commands_update")})),GD.and(w.object({sessionUpdate:w.literal("current_mode_update")})),QD.and(w.object({sessionUpdate:w.literal("config_option_update")})),jD.and(w.object({sessionUpdate:w.literal("session_info_update")})),uD.and(w.object({sessionUpdate:w.literal("usage_update")}))]),Ow=w.object({_meta:w.record(w.string(),w.unknown()).nullish(),sessionId:K,update:gD}),D$=w.object({method:w.string(),params:w.union([Ow,Iw]).nullish()}),Nw=w.object({_meta:w.record(w.string(),w.unknown()).nullish(),sessionId:K,terminalId:w.string()}),lD=w.object({_meta:w.record(w.string(),w.unknown()).nullish(),exitCode:w.number().int().gte(0).max(4294967295,{message:"Invalid value: Expected uint32 to be <= 4294967295"}).nullish(),signal:w.string().nullish()}),Ww=w.object({_meta:w.record(w.string(),w.unknown()).nullish(),content:w.string(),path:w.string(),sessionId:K}),$$=w.object({id:T,method:w.string(),params:w.union([Ww,Qw,Zw,ww,Gw,_w,Nw,Dw,qw]).nullish()}),iD=w.object({_meta:w.record(w.string(),w.unknown()).nullish()}),Q$=w.union([w.object({id:T,result:w.union([iD,lf,af,Vf,TD,tf,lD,bf,Sw])}),w.object({error:Ew,id:T})]);function rw(f,$){let D=new TextEncoder,Q=new TextDecoder,j=new ReadableStream({async start(_){let y="",X=$.getReader();try{while(!0){let{value:W,done:J}=await X.read();if(J)break;if(!W)continue;y+=Q.decode(W,{stream:!0});let G=y.split(`
3
- `);y=G.pop()||"";for(let Y of G){let O=Y.trim();if(O)try{let Z=JSON.parse(O);_.enqueue(Z)}catch(Z){console.error("Failed to parse JSON message:",O,Z)}}}}finally{X.releaseLock(),_.close()}}}),A=new WritableStream({async write(_){let y=JSON.stringify(_)+`
4
- `,X=f.getWriter();try{await X.write(D.encode(y))}finally{X.releaseLock()}}});return{readable:j,writable:A}}class Bw{#w;constructor(f,$){let D=f(this),Q=async(A,_)=>{switch(A){case B.initialize:{let y=a.parse(_);return D.initialize(y)}case B.session_new:{let y=r.parse(_);return D.newSession(y)}case B.session_load:{if(!D.loadSession)throw N.methodNotFound(A);let y=$w.parse(_);return D.loadSession(y)}case B.session_list:{if(!D.listSessions)throw N.methodNotFound(A);let y=m.parse(_);return D.listSessions(y)}case B.session_fork:{if(!D.unstable_forkSession)throw N.methodNotFound(A);let y=fw.parse(_);return D.unstable_forkSession(y)}case B.session_resume:{if(!D.unstable_resumeSession)throw N.methodNotFound(A);let y=Aw.parse(_);return D.unstable_resumeSession(y)}case B.session_close:{if(!D.unstable_closeSession)throw N.methodNotFound(A);let y=e.parse(_);return D.unstable_closeSession(y)}case B.session_set_mode:{if(!D.setSessionMode)throw N.methodNotFound(A);let y=jw.parse(_);return await D.setSessionMode(y)??{}}case B.authenticate:{let y=p.parse(_);return await D.authenticate(y)??{}}case B.session_prompt:{let y=Yw.parse(_);return D.prompt(y)}case B.session_set_model:{if(!D.unstable_setSessionModel)throw N.methodNotFound(A);let y=Jw.parse(_);return await D.unstable_setSessionModel(y)??{}}case B.session_set_config_option:{if(!D.setSessionConfigOption)throw N.methodNotFound(A);let y=yw.parse(_);return D.setSessionConfigOption(y)}default:if(D.extMethod)return D.extMethod(A,_);throw N.methodNotFound(A)}},j=async(A,_)=>{switch(A){case B.session_cancel:{let y=s.parse(_);return D.cancel(y)}default:if(D.extNotification)return D.extNotification(A,_);throw N.methodNotFound(A)}};this.#w=new Kw(Q,j,$)}async sessionUpdate(f){return await this.#w.sendNotification(L.session_update,f)}async requestPermission(f){return await this.#w.sendRequest(L.session_request_permission,f)}async readTextFile(f){return await this.#w.sendRequest(L.fs_read_text_file,f)}async writeTextFile(f){return await this.#w.sendRequest(L.fs_write_text_file,f)??{}}async createTerminal(f){let $=await this.#w.sendRequest(L.terminal_create,f);return new aw($.terminalId,f.sessionId,this.#w)}async extMethod(f,$){return await this.#w.sendRequest(f,$)}async extNotification(f,$){return await this.#w.sendNotification(f,$)}get signal(){return this.#w.signal}get closed(){return this.#w.closed}}class aw{id;#w;#f;constructor(f,$,D){this.id=f,this.#w=$,this.#f=D}async currentOutput(){return await this.#f.sendRequest(L.terminal_output,{sessionId:this.#w,terminalId:this.id})}async waitForExit(){return await this.#f.sendRequest(L.terminal_wait_for_exit,{sessionId:this.#w,terminalId:this.id})}async kill(){return await this.#f.sendRequest(L.terminal_kill,{sessionId:this.#w,terminalId:this.id})??{}}async release(){return await this.#f.sendRequest(L.terminal_release,{sessionId:this.#w,terminalId:this.id})??{}}async[Symbol.asyncDispose](){await this.release()}}class dD{#w;constructor(f,$){let D=f(this),Q=async(A,_)=>{switch(A){case L.fs_write_text_file:{let y=Ww.parse(_);return D.writeTextFile?.(y)}case L.fs_read_text_file:{let y=Qw.parse(_);return D.readTextFile?.(y)}case L.session_request_permission:{let y=Zw.parse(_);return D.requestPermission(y)}case L.terminal_create:{let y=ww.parse(_);return D.createTerminal?.(y)}case L.terminal_output:{let y=Gw.parse(_);return D.terminalOutput?.(y)}case L.terminal_release:{let y=_w.parse(_);return await D.releaseTerminal?.(y)??{}}case L.terminal_wait_for_exit:{let y=Nw.parse(_);return D.waitForTerminalExit?.(y)}case L.terminal_kill:{let y=Dw.parse(_);return await D.killTerminal?.(y)??{}}default:if(D.extMethod)return D.extMethod(A,_);throw N.methodNotFound(A)}},j=async(A,_)=>{switch(A){case L.session_update:{let y=Ow.parse(_);return D.sessionUpdate(y)}default:if(D.extNotification)return D.extNotification(A,_);throw N.methodNotFound(A)}};this.#w=new Kw(Q,j,$)}async initialize(f){return await this.#w.sendRequest(B.initialize,f)}async newSession(f){return await this.#w.sendRequest(B.session_new,f)}async loadSession(f){return await this.#w.sendRequest(B.session_load,f)??{}}async unstable_forkSession(f){return await this.#w.sendRequest(B.session_fork,f)}async listSessions(f){return await this.#w.sendRequest(B.session_list,f)}async unstable_resumeSession(f){return await this.#w.sendRequest(B.session_resume,f)}async unstable_closeSession(f){return await this.#w.sendRequest(B.session_close,f)}async setSessionMode(f){return await this.#w.sendRequest(B.session_set_mode,f)??{}}async unstable_setSessionModel(f){return await this.#w.sendRequest(B.session_set_model,f)??{}}async setSessionConfigOption(f){return await this.#w.sendRequest(B.session_set_config_option,f)}async authenticate(f){return await this.#w.sendRequest(B.authenticate,f)??{}}async prompt(f){return await this.#w.sendRequest(B.session_prompt,f)}async cancel(f){return await this.#w.sendNotification(B.session_cancel,f)}async extMethod(f,$){return await this.#w.sendRequest(f,$)}async extNotification(f,$){return await this.#w.sendNotification(f,$)}get signal(){return this.#w.signal}get closed(){return this.#w.closed}}class Kw{#w=new Map;#f=0;#A;#y;#$;#Q=Promise.resolve();#_=new AbortController;#j;constructor(f,$,D){this.#A=f,this.#y=$,this.#$=D,this.#j=new Promise((Q)=>{this.#_.signal.addEventListener("abort",()=>Q())}),this.#J()}get signal(){return this.#_.signal}get closed(){return this.#j}async#J(){let f=this.#$.readable.getReader();try{while(!0){let{value:$,done:D}=await f.read();if(D)break;if(!$)continue;try{this.#G($)}catch(Q){if(console.error("Unexpected error during message processing:",$,Q),"id"in $&&$.id!==void 0)this.#D({jsonrpc:"2.0",id:$.id,error:{code:-32700,message:"Parse error"}})}}}finally{f.releaseLock(),this.#_.abort()}}async#G(f){if("method"in f&&"id"in f){let $=await this.#X(f.method,f.params);if("error"in $)console.error("Error handling request",f,$.error);await this.#D({jsonrpc:"2.0",id:f.id,...$})}else if("method"in f){let $=await this.#Y(f.method,f.params);if("error"in $)console.error("Error handling notification",f,$.error)}else if("id"in f)this.#Z(f);else console.error("Invalid message",{message:f})}async#X(f,$){try{return{result:await this.#A(f,$)??null}}catch(D){if(D instanceof N)return D.toResult();if(D instanceof w.ZodError)return N.invalidParams(D.format()).toResult();let Q;if(D instanceof Error)Q=D.message;else if(typeof D==="object"&&D!=null&&"message"in D&&typeof D.message==="string")Q=D.message;try{return N.internalError(Q?JSON.parse(Q):{}).toResult()}catch{return N.internalError({details:Q}).toResult()}}}async#Y(f,$){try{return await this.#y(f,$),{result:null}}catch(D){if(D instanceof N)return D.toResult();if(D instanceof w.ZodError)return N.invalidParams(D.format()).toResult();let Q;if(D instanceof Error)Q=D.message;else if(typeof D==="object"&&D!=null&&"message"in D&&typeof D.message==="string")Q=D.message;try{return N.internalError(Q?JSON.parse(Q):{}).toResult()}catch{return N.internalError({details:Q}).toResult()}}}#Z(f){let $=this.#w.get(f.id);if($){if("result"in f)$.resolve(f.result);else if("error"in f)$.reject(f.error);this.#w.delete(f.id)}else console.error("Got response to unknown request",f.id)}async sendRequest(f,$){let D=this.#f++,Q=new Promise((j,A)=>{this.#w.set(D,{resolve:j,reject:A})});return await this.#D({jsonrpc:"2.0",id:D,method:f,params:$}),Q}async sendNotification(f,$){await this.#D({jsonrpc:"2.0",method:f,params:$})}async#D(f){return this.#Q=this.#Q.then(async()=>{let $=this.#$.writable.getWriter();try{await $.write(f)}finally{$.releaseLock()}}).catch(($)=>{console.error("ACP write error:",$)}),this.#Q}}class N extends Error{code;data;constructor(f,$,D){super($);this.code=f,this.name="RequestError",this.data=D}static parseError(f,$){return new N(-32700,`Parse error${$?`: ${$}`:""}`,f)}static invalidRequest(f,$){return new N(-32600,`Invalid request${$?`: ${$}`:""}`,f)}static methodNotFound(f){return new N(-32601,`"Method not found": ${f}`,{method:f})}static invalidParams(f,$){return new N(-32602,`Invalid params${$?`: ${$}`:""}`,f)}static internalError(f,$){return new N(-32603,`Internal error${$?`: ${$}`:""}`,f)}static authRequired(f,$){return new N(-32000,`Authentication required${$?`: ${$}`:""}`,f)}static resourceNotFound(f){return new N(-32002,`Resource not found${f?`: ${f}`:""}`,f&&{uri:f})}toResult(){return{error:{code:this.code,message:this.message,data:this.data}}}toErrorResponse(){return{code:this.code,message:this.message,data:this.data}}}var E={};mD(E,{init:()=>rD,Agent:()=>vw,ACP:()=>E});var Lw=V.create({service:"acp-session-manager"});class Fw{sessions=new Map;sdk;constructor(f){this.sdk=f}tryGet(f){return this.sessions.get(f)}async create(f,$,D){let j=(await this.sdk.session.create({directory:f},{throwOnError:!0}).then((y)=>y.data)).id,_={id:j,cwd:f,mcpServers:$,createdAt:new Date,model:D};return Lw.info("creating_session",{state:_}),this.sessions.set(j,_),_}async load(f,$,D,Q){let j=await this.sdk.session.get({sessionID:f,directory:$},{throwOnError:!0}).then((y)=>y.data),A=Q,_={id:f,cwd:$,mcpServers:D,createdAt:new Date(j.time.created),model:A};return Lw.info("loading_session",{state:_}),this.sessions.set(f,_),_}get(f){let $=this.sessions.get(f);if(!$)throw Lw.error("session not found",{sessionId:f}),N.invalidParams(JSON.stringify({error:`Session not found: ${f}`}));return $}getModel(f){return this.get(f).model}setModel(f,$){let D=this.get(f);return D.model=$,this.sessions.set(f,D),D}getVariant(f){return this.get(f).variant}setVariant(f,$){let D=this.get(f);return D.variant=$,this.sessions.set(f,D),D}setMode(f,$){let D=this.get(f);return D.modeId=$,this.sessions.set(f,D),D}}import{pathToFileURL as R}from"url";var nD=V.create({service:"acp-message-translator"}),pD="default";function b(f){switch(f.toLocaleLowerCase()){case"bash":return"execute";case"webfetch":return"fetch";case"edit":case"patch":case"write":return"edit";case"grep":case"glob":case"context7_resolve_library_id":case"context7_get_library_docs":return"search";case"read":return"read";default:return"other"}}function u(f,$){switch(f.toLocaleLowerCase()){case"read":case"edit":case"write":return $.filePath?[{path:$.filePath}]:[];case"glob":case"grep":return $.path?[{path:$.path}]:[];case"bash":return[];default:return[]}}function g(f){try{if(f.startsWith("file://")){let $=f.slice(7),D=$.split("/").pop()||$;return{type:"file",url:f,filename:D,mime:"text/plain"}}if(f.startsWith("zed://")){let D=new URL(f).searchParams.get("path");if(D){let Q=D.split("/").pop()||D;return{type:"file",url:R(D).href,filename:Q,mime:"text/plain"}}}return{type:"text",text:f}}catch{return{type:"text",text:f}}}function sw(f,$){let D=zw(f,$);if(D===!1){nD.error("Failed to apply unified diff (context mismatch)");return}return D}function kw(f){if(f.tool!=="bash")return;if(!("metadata"in f.state)||!f.state.metadata||typeof f.state.metadata!=="object")return;let $=f.state.metadata.output;if(typeof $!=="string")return;return $}function l(f){return[...f].sort(($,D)=>{let Q=$.name.toLowerCase(),j=D.name.toLowerCase();if(Q<j)return-1;if(Q>j)return 1;return 0})}function xw(f,$){let D=f.find((j)=>j.id===$.providerID);if(!D)return[];let Q=D.models[$.modelID];if(!Q?.variants)return[];return Object.keys(Q.variants)}function ew(f,$={}){let D=$.includeVariants??!1;return f.flatMap((Q)=>{let j=Object.values(Q.models);return h.sort(j).flatMap((_)=>{let y={modelId:`${Q.id}/${_.id}`,name:`${Q.name}/${_.name}`};if(!D||!_.variants)return[y];let W=Object.keys(_.variants).filter((J)=>J!==pD).map((J)=>({modelId:`${Q.id}/${_.id}/${J}`,name:`${Q.name}/${_.name} (${J})`}));return[y,...W]})})}function i(f,$,D,Q){let j=`${f.providerID}/${f.modelID}`;if(!Q||!$||!D.includes($))return j;return`${j}/${$}`}function Vw(f){return{opencode:{modelId:`${f.model.providerID}/${f.model.modelID}`,variant:f.variant??null,availableVariants:f.availableVariants}}}function Pw(f,$){let D=h.parseModel(f),Q=$.find((A)=>A.id===D.providerID);if(!Q)return{model:D,variant:void 0};if(Q.models[D.modelID])return{model:D,variant:void 0};let j=D.modelID.split("/");if(j.length>1){let A=j[j.length-1],_=j.slice(0,-1).join("/"),y=Q.models[_];if(y?.variants&&A in y.variants)return{model:{providerID:D.providerID,modelID:P.make(_)},variant:A}}return{model:D,variant:void 0}}function t(f){let $=[{id:"model",name:"Model",category:"model",type:"select",currentValue:f.currentModelId,options:f.availableModels.map((D)=>({value:D.modelId,name:D.name}))}];if(f.modes)$.push({id:"mode",name:"Session Mode",category:"mode",type:"select",currentValue:f.modes.currentModeId,options:f.modes.availableModes.map((D)=>({value:D.id,name:D.name,...D.description?{description:D.description}:{}}))});return $}var wf=V.create({service:"acp-permissions"});class Tw{connection;sdk;sessionManager;permissionQueues=new Map;permissionOptions=[{optionId:"once",kind:"allow_once",name:"Allow once"},{optionId:"always",kind:"allow_always",name:"Always allow"},{optionId:"reject",kind:"reject_once",name:"Reject"}];constructor(f,$,D){this.connection=f;this.sdk=$;this.sessionManager=D}handle(f){let $=this.sessionManager.tryGet(f.sessionID);if(!$)return;let Q=(this.permissionQueues.get(f.sessionID)??Promise.resolve()).then(async()=>{let j=$.cwd,A=await this.connection.requestPermission({sessionId:f.sessionID,toolCall:{toolCallId:f.tool?.callID??f.id,status:"pending",title:f.permission,rawInput:f.metadata,kind:b(f.permission),locations:u(f.permission,f.metadata??{})},options:this.permissionOptions}).catch(async(_)=>{wf.error("failed to request permission from ACP",{error:_,permissionID:f.id,sessionID:f.sessionID}),await this.sdk.permission.reply({requestID:f.id,reply:"reject",directory:j});return});if(!A)return;if(A.outcome.outcome!=="selected"){await this.sdk.permission.reply({requestID:f.id,reply:"reject",directory:j});return}if(A.outcome.optionId!=="reject"&&f.permission=="edit"){let _=f.metadata||{},y=typeof _.filepath==="string"?_.filepath:"",X=typeof _.diff==="string"?_.diff:"",W=await Hw.exists(y)?await Hw.readText(y):"",J=sw(W,X);if(J)this.connection.writeTextFile({sessionId:$.id,path:y,content:J})}await this.sdk.permission.reply({requestID:f.id,reply:A.outcome.optionId,directory:j})}).catch((j)=>{wf.error("failed to handle permission",{error:j,permissionID:f.id})}).finally(()=>{if(this.permissionQueues.get(f.sessionID)===Q)this.permissionQueues.delete(f.sessionID)});this.permissionQueues.set(f.sessionID,Q)}}var F=V.create({service:"acp-event-bridge"});class hw{connection;sdk;sessionManager;eventAbort=new AbortController;eventStarted=!1;bashSnapshots=new Map;toolStarts=new Set;permissionHandler;constructor(f,$,D){this.connection=f;this.sdk=$;this.sessionManager=D;this.permissionHandler=new Tw(f,$,D)}start(){if(this.eventStarted)return;this.eventStarted=!0,this.runEventSubscription().catch((f)=>{if(this.eventAbort.signal.aborted)return;F.error("event subscription failed",{error:f})})}stop(){this.eventAbort.abort()}async runEventSubscription(){while(!0){if(this.eventAbort.signal.aborted)return;let f=await this.sdk.global.event({signal:this.eventAbort.signal,sseMaxRetryAttempts:0});for await(let $ of f.stream){if(this.eventAbort.signal.aborted)return;let D=$?.payload;if(!D)continue;await this.handleEvent(D).catch((Q)=>{F.error("failed to handle event",{error:Q,type:D.type})})}if(this.eventAbort.signal.aborted)return;await new Promise(($)=>{let D=()=>{clearTimeout(Q),this.eventAbort.signal.removeEventListener("abort",D),$()},Q=setTimeout(D,1000);if(this.eventAbort.signal.addEventListener("abort",D,{once:!0}),this.eventAbort.signal.aborted)D()})}}async handleEvent(f){switch(f.type){case"permission.asked":{this.permissionHandler.handle(f.properties);return}case"message.part.updated":{F.info("message part updated",{event:f.properties});let D=f.properties.part,Q=this.sessionManager.tryGet(D.sessionID);if(!Q)return;let j=Q.id;if(D.type==="tool")switch(await this.toolStart(j,D),D.state.status){case"pending":this.bashSnapshots.delete(D.callID);return;case"running":{let A=kw(D),_=[];if(A){let y=ff.fast(A);if(D.tool==="bash"){if(this.bashSnapshots.get(D.callID)===y){await this.sendToolInProgress(j,D,D.state,[]);return}this.bashSnapshots.set(D.callID,y)}_.push({type:"content",content:{type:"text",text:A}})}await this.sendToolInProgress(j,D,D.state,_);return}case"completed":await this.sendToolCompleted(j,D,D.state);return;case"error":await this.sendToolError(j,D,D.state);return}if(D.type!=="text"&&D.type!=="file")return;return}case"message.part.delta":{let $=f.properties,D=this.sessionManager.tryGet($.sessionID);if(!D)return;let Q=D.id,j=await this.sdk.session.message({sessionID:$.sessionID,messageID:$.messageID,directory:D.cwd},{throwOnError:!0}).then((_)=>_.data).catch((_)=>{F.error("unexpected error when fetching message",{error:_});return});if(!j||j.info.role!=="assistant")return;let A=j.parts.find((_)=>_.id===$.partID);if(!A)return;if(A.type==="text"&&$.field==="text"&&A.ignored!==!0){await this.connection.sessionUpdate({sessionId:Q,update:{sessionUpdate:"agent_message_chunk",messageId:$.messageID,content:{type:"text",text:$.delta}}}).catch((_)=>{F.error("failed to send text delta to ACP",{error:_})});return}if(A.type==="reasoning"&&$.field==="text")await this.connection.sessionUpdate({sessionId:Q,update:{sessionUpdate:"agent_thought_chunk",messageId:$.messageID,content:{type:"text",text:$.delta}}}).catch((_)=>{F.error("failed to send reasoning delta to ACP",{error:_})});return}}}async sendToolInProgress(f,$,D,Q){await this.connection.sessionUpdate({sessionId:f,update:{sessionUpdate:"tool_call_update",toolCallId:$.callID,status:"in_progress",kind:b($.tool),title:$.tool,locations:u($.tool,D.input),rawInput:D.input,...Q.length>0&&{content:Q}}}).catch((j)=>{F.error("failed to send tool in_progress to ACP",{error:j})})}async sendToolCompleted(f,$,D){this.toolStarts.delete($.callID),this.bashSnapshots.delete($.callID);let Q=b($.tool),j=[{type:"content",content:{type:"text",text:D.output}}];if(Q==="edit"){let A=D.input,_=typeof A.filePath==="string"?A.filePath:"",y=typeof A.oldString==="string"?A.oldString:"",X=typeof A.newString==="string"?A.newString:typeof A.content==="string"?A.content:"";j.push({type:"diff",path:_,oldText:y,newText:X})}await this.connection.sessionUpdate({sessionId:f,update:{sessionUpdate:"tool_call_update",toolCallId:$.callID,status:"completed",kind:Q,content:j,title:D.title,rawInput:D.input,rawOutput:{output:D.output,metadata:D.metadata}}}).catch((A)=>{F.error("failed to send tool completed to ACP",{error:A})})}async sendToolError(f,$,D){this.toolStarts.delete($.callID),this.bashSnapshots.delete($.callID),await this.connection.sessionUpdate({sessionId:f,update:{sessionUpdate:"tool_call_update",toolCallId:$.callID,status:"failed",kind:b($.tool),title:$.tool,rawInput:D.input,content:[{type:"content",content:{type:"text",text:D.error}}],rawOutput:{error:D.error,metadata:D.metadata}}}).catch((Q)=>{F.error("failed to send tool error to ACP",{error:Q})})}async toolStart(f,$){if(this.toolStarts.has($.callID))return;this.toolStarts.add($.callID),await this.connection.sessionUpdate({sessionId:f,update:{sessionUpdate:"tool_call",toolCallId:$.callID,title:$.tool,kind:b($.tool),status:"pending",locations:[],rawInput:{}}}).catch((D)=>{F.error("failed to send tool pending to ACP",{error:D})})}async processMessage(f){if(F.debug("process message",f),f.info.role!=="assistant"&&f.info.role!=="user")return;let $=f.info.sessionID;for(let D of f.parts)if(D.type==="tool")switch(await this.toolStart($,D),D.state.status){case"pending":this.bashSnapshots.delete(D.callID);break;case"running":{let Q=kw(D),j=[];if(Q)j.push({type:"content",content:{type:"text",text:Q}});await this.sendToolInProgress($,D,D.state,j);break}case"completed":await this.sendToolCompleted($,D,D.state);break;case"error":await this.sendToolError($,D,D.state);break}else if(D.type==="text"){if(D.text){let Q=D.synthetic?["assistant"]:D.ignored?["user"]:void 0;await this.connection.sessionUpdate({sessionId:$,update:{sessionUpdate:f.info.role==="user"?"user_message_chunk":"agent_message_chunk",messageId:f.info.id,content:{type:"text",text:D.text,...Q&&{annotations:{audience:Q}}}}}).catch((j)=>{F.error("failed to send text to ACP",{error:j})})}}else if(D.type==="file"){let Q=D.url,j=D.filename??"file",A=D.mime||"application/octet-stream",_=f.info.role==="user"?"user_message_chunk":"agent_message_chunk";if(Q.startsWith("file://"))await this.connection.sessionUpdate({sessionId:$,update:{sessionUpdate:_,messageId:f.info.id,content:{type:"resource_link",uri:Q,name:j,mimeType:A}}}).catch((y)=>{F.error("failed to send resource_link to ACP",{error:y})});else if(Q.startsWith("data:")){let y=Q.match(/^data:([^;]+);base64,(.*)$/),X=y?.[1],W=y?.[2]??"",J=X||A;if(J.startsWith("image/"))await this.connection.sessionUpdate({sessionId:$,update:{sessionUpdate:_,messageId:f.info.id,content:{type:"image",mimeType:J,data:W,uri:R(j).href}}}).catch((G)=>{F.error("failed to send image to ACP",{error:G})});else{let G=J.startsWith("text/")||J==="application/json",Y=R(j).href,O=G?{uri:Y,mimeType:J,text:Buffer.from(W,"base64").toString("utf-8")}:{uri:Y,mimeType:J,blob:W};await this.connection.sessionUpdate({sessionId:$,update:{sessionUpdate:_,messageId:f.info.id,content:{type:"resource",resource:O}}}).catch((Z)=>{F.error("failed to send resource to ACP",{error:Z})})}}}else if(D.type==="reasoning"){if(D.text)await this.connection.sessionUpdate({sessionId:$,update:{sessionUpdate:"agent_thought_chunk",messageId:f.info.id,content:{type:"text",text:D.text}}}).catch((Q)=>{F.error("failed to send reasoning to ACP",{error:Q})})}}}var x=V.create({service:"acp-agent"});async function oD(f,$,D,Q){return(await f.config.providers({directory:Q}).then((y)=>y.data?.providers??[]).catch((y)=>{return x.error("failed to get providers for context limit",{error:y}),[]})).find((y)=>y.id===$)?.models[D]?.limit.context??null}async function bw(f,$,D,Q){let j=await $.session.messages({sessionID:D,directory:Q,agent_id:"main"},{throwOnError:!0}).then((G)=>G.data).catch((G)=>{x.error("failed to fetch messages for usage update",{error:G});return});if(!j)return;let A=j.filter((G)=>G.info.role==="assistant"),_=A[A.length-1];if(!_)return;let y=_.info;if(!y.providerID||!y.modelID)return;let X=await oD($,H.make(y.providerID),P.make(y.modelID),Q);if(!X)return;let W=y.tokens.input+(y.tokens.cache?.read??0),J=A.reduce((G,Y)=>G+Y.info.cost,0);await f.sessionUpdate({sessionId:D,update:{sessionUpdate:"usage_update",used:W,size:X,cost:{amount:J,currency:"USD"}}}).catch((G)=>{x.error("failed to send usage update",{error:G})})}async function rD({sdk:f}){return{create:($,D)=>{return new vw($,D)}}}class vw{connection;config;sdk;sessionManager;eventBridge;constructor(f,$){this.connection=f,this.config=$,this.sdk=$.sdk,this.sessionManager=new Fw(this.sdk),this.eventBridge=new hw(f,this.sdk,this.sessionManager),this.eventBridge.start()}async initialize(f){x.info("initialize",{protocolVersion:f.protocolVersion});let $={description:"Run `qitqode auth login` in the terminal",name:"Login with qitqode",id:"qitqode-login"};if(f.clientCapabilities?._meta?.["terminal-auth"]===!0)$._meta={"terminal-auth":{command:"qitqode",args:["auth","login"],label:"QitQode Login"}};return{protocolVersion:1,agentCapabilities:{loadSession:!0,mcpCapabilities:{http:!0,sse:!0},promptCapabilities:{embeddedContext:!0,image:!0},sessionCapabilities:{fork:{},list:{},resume:{}}},authMethods:[$],agentInfo:{name:"QitQode",version:Df}}}async authenticate(f){throw Error("Authentication not implemented")}rethrowSessionError(f){let $=_f.fromError(f,{providerID:H.make(this.config.defaultModel?.providerID??"unknown")});if($f.isInstance($))throw N.authRequired();throw f}fetchSessionMessages(f,$){return this.sdk.session.messages({sessionID:f,directory:$,agent_id:"main"},{throwOnError:!0}).then((D)=>D.data).catch((D)=>{x.error("unexpected error when fetching message",{error:D});return})}loadSessionProviders(f){return this.sdk.config.providers({directory:f},{throwOnError:!0}).then(($)=>$.data.providers)}async newSession(f){let $=f.cwd;try{let D=await U(this.config,$),j=(await this.sessionManager.create(f.cwd,f.mcpServers,D)).id;x.info("creating_session",{sessionId:j,mcpServers:f.mcpServers.length});let A=await this.loadSessionMode({cwd:$,mcpServers:f.mcpServers,sessionId:j});return{sessionId:j,configOptions:A.configOptions,models:A.models,modes:A.modes,_meta:A._meta}}catch(D){this.rethrowSessionError(D)}}async loadSession(f){let{cwd:$,sessionId:D}=f;try{let Q=await U(this.config,$);await this.sessionManager.load(D,f.cwd,f.mcpServers,Q),x.info("load_session",{sessionId:D,mcpServers:f.mcpServers.length});let j=await this.loadSessionMode({cwd:$,mcpServers:f.mcpServers,sessionId:D}),A=await this.fetchSessionMessages(D,$),_=A?.findLast((y)=>y.info.role==="user")?.info;if(_?.role==="user"){if(j.models.currentModelId=`${_.model.providerID}/${_.model.modelID}`,this.sessionManager.setModel(D,{providerID:H.make(_.model.providerID),modelID:P.make(_.model.modelID)}),j.modes?.availableModes.some((y)=>y.id===_.agent))j.modes.currentModeId=_.agent,this.sessionManager.setMode(D,_.agent);j.configOptions=t({currentModelId:j.models.currentModelId,availableModels:j.models.availableModels,modes:j.modes})}return await this.replayMessagesAndSendUsage(A,D,$),j}catch(Q){this.rethrowSessionError(Q)}}async listSessions(f){try{let D=await this.sdk.session.list({directory:f.cwd??void 0,roots:!0},{throwOnError:!0}).then((G)=>G.data??[]),Q=f.cursor?Number(f.cursor):void 0,j=D.toSorted((G,Y)=>Y.time.updated-G.time.updated),A=Q?j.filter((G)=>G.time.updated<Q):j,_=A.slice(0,100),y=_.map((G)=>({sessionId:G.id,cwd:G.directory,title:G.title,updatedAt:new Date(G.time.updated).toISOString()})),X=_[_.length-1],W=A.length>100&&X?String(X.time.updated):void 0,J={sessions:y};if(W)J.nextCursor=W;return J}catch($){this.rethrowSessionError($)}}async unstable_forkSession(f){let $=f.cwd,D=f.mcpServers??[];try{let Q=await U(this.config,$),j=await this.sdk.session.fork({sessionID:f.sessionId,directory:$},{throwOnError:!0}).then((X)=>X.data);if(!j)throw Error("Fork session returned no data");let A=j.id;await this.sessionManager.load(A,$,D,Q),x.info("fork_session",{sessionId:A,mcpServers:D.length});let _=await this.loadSessionMode({cwd:$,mcpServers:D,sessionId:A}),y=await this.fetchSessionMessages(A,$);return await this.replayMessagesAndSendUsage(y,A,$),_}catch(Q){this.rethrowSessionError(Q)}}async unstable_resumeSession(f){let{cwd:$,sessionId:D}=f,Q=f.mcpServers??[];try{let j=await U(this.config,$);await this.sessionManager.load(D,$,Q,j),x.info("resume_session",{sessionId:D,mcpServers:Q.length});let A=await this.loadSessionMode({cwd:$,mcpServers:Q,sessionId:D});return await bw(this.connection,this.sdk,D,$),A}catch(j){this.rethrowSessionError(j)}}async loadAvailableModes(f){return(await this.config.sdk.app.agents({directory:f},{throwOnError:!0}).then((D)=>D.data)).filter((D)=>D.mode!=="subagent"&&!D.hidden).map((D)=>({id:D.name,name:D.name,description:D.description}))}async resolveModeState(f,$){let D=await this.loadAvailableModes(f),Q=this.sessionManager.get($).modeId||await(async()=>{if(!D.length)return;let j=await Cw.runPromise(Uw.Service.use((_)=>_.defaultAgent())),A=D.find((_)=>_.name===j)?.id??D[0].id;return this.sessionManager.setMode($,A),A})();return{availableModes:D,currentModeId:Q}}async replayMessagesAndSendUsage(f,$,D){for(let Q of f??[])x.debug("replay message",Q),await this.eventBridge.processMessage(Q);await bw(this.connection,this.sdk,$,D)}async resolveModelsAndModes(f){let $=xw(f.entries,f.model);f.onVariants?.($);let D=ew(f.entries,{includeVariants:!0}),Q=await this.resolveModeState(f.directory,f.sessionId),j=Q.currentModeId?{availableModes:Q.availableModes,currentModeId:Q.currentModeId}:void 0;return{availableVariants:$,availableModels:D,modes:j}}async loadSessionMode(f){let $=f.cwd,D=await U(this.config,$),Q=f.sessionId,j=await this.sdk.config.providers({directory:$}).then((Z)=>Z.data.providers),A=l(j),_=this.sessionManager.getVariant(Q),{availableVariants:y,availableModels:X,modes:W}=await this.resolveModelsAndModes({entries:A,model:D,directory:$,sessionId:Q,onVariants:(Z)=>{if(_&&!Z.includes(_))this.sessionManager.setVariant(Q,void 0)}}),G=(await this.config.sdk.command.list({directory:$},{throwOnError:!0}).then((Z)=>Z.data)).map((Z)=>({name:Z.name,description:Z.description??""}));if(!new Set(G.map((Z)=>Z.name)).has("compact"))G.push({name:"compact",description:"summarize the session to reduce context"});let O={};for(let Z of f.mcpServers)if("type"in Z)O[Z.name]={url:Z.url,headers:Z.headers.reduce((k,{name:v,value:d})=>{return k[v]=d,k},{}),type:"remote"};else O[Z.name]={type:"local",command:[Z.command,...Z.args],environment:Z.env.reduce((k,{name:v,value:d})=>{return k[v]=d,k},{})};return await Promise.all(Object.entries(O).map(async([Z,k])=>{await this.sdk.mcp.add({directory:$,name:Z,config:k},{throwOnError:!0}).catch((v)=>{x.error("failed to add mcp server",{name:Z,error:v})})})),setTimeout(()=>{this.connection.sessionUpdate({sessionId:Q,update:{sessionUpdate:"available_commands_update",availableCommands:G}})},0),{sessionId:Q,models:{currentModelId:i(D,_,y,!0),availableModels:X},modes:W,configOptions:t({currentModelId:i(D,_,y,!0),availableModels:X,modes:W}),_meta:Vw({model:D,variant:this.sessionManager.getVariant(Q),availableVariants:y})}}async unstable_setSessionModel(f){let $=this.sessionManager.get(f.sessionId),D=await this.loadSessionProviders($.cwd),Q=Pw(f.modelId,D);this.sessionManager.setModel($.id,Q.model),this.sessionManager.setVariant($.id,Q.variant);let j=l(D),A=xw(j,Q.model);return{_meta:Vw({model:Q.model,variant:Q.variant,availableVariants:A})}}async setSessionMode(f){let $=this.sessionManager.get(f.sessionId);if(!(await this.loadAvailableModes($.cwd)).some((Q)=>Q.id===f.modeId))throw Error(`Agent not found: ${f.modeId}`);this.sessionManager.setMode(f.sessionId,f.modeId)}async setSessionConfigOption(f){let $=this.sessionManager.get(f.sessionId),D=await this.loadSessionProviders($.cwd),Q=l(D);if(f.configId==="model"){if(typeof f.value!=="string")throw N.invalidParams("model value must be a string");let J=Pw(f.value,D);this.sessionManager.setModel($.id,J.model),this.sessionManager.setVariant($.id,J.variant)}else if(f.configId==="mode"){if(typeof f.value!=="string")throw N.invalidParams("mode value must be a string");if(!(await this.loadAvailableModes($.cwd)).some((G)=>G.id===f.value))throw N.invalidParams(JSON.stringify({error:`Mode not found: ${f.value}`}));this.sessionManager.setMode($.id,f.value)}else throw N.invalidParams(JSON.stringify({error:`Unknown config option: ${f.configId}`}));let j=this.sessionManager.get($.id),A=j.model??await U(this.config,$.cwd),{availableVariants:_,availableModels:y,modes:X}=await this.resolveModelsAndModes({entries:Q,model:A,directory:$.cwd,sessionId:$.id}),W=i(A,j.variant,_,!0);return{configOptions:t({currentModelId:W,availableModels:y,modes:X})}}async prompt(f){let $=f.sessionId,D=this.sessionManager.get($),Q=D.cwd,j=D.model,A=j??await U(this.config,Q);if(!j)this.sessionManager.setModel(D.id,A);let _=D.modeId??await Cw.runPromise(Uw.Service.use((Y)=>Y.defaultAgent())),y=[];for(let Y of f.prompt)switch(Y.type){case"text":{let O=Y.annotations?.audience,Z=O?.length===1&&O[0]==="assistant",k=O?.length===1&&O[0]==="user";y.push({type:"text",text:Y.text,...Z&&{synthetic:!0},...k&&{ignored:!0}});break}case"image":{let O=g(Y.uri??""),Z=O.type==="file"?O.filename:"image";if(Y.data)y.push({type:"file",url:`data:${Y.mimeType};base64,${Y.data}`,filename:Z,mime:Y.mimeType});else if(Y.uri&&Y.uri.startsWith("http:"))y.push({type:"file",url:Y.uri,filename:Z,mime:Y.mimeType});break}case"resource_link":{let O=g(Y.uri);if(Y.name&&O.type==="file")O.filename=Y.name;y.push(O);break}case"resource":{let O=Y.resource;if("text"in O&&O.text)y.push({type:"text",text:O.text});else if("blob"in O&&O.blob&&O.mimeType){let Z=g(O.uri??""),k=Z.type==="file"?Z.filename:"file";y.push({type:"file",url:`data:${O.mimeType};base64,${O.blob}`,filename:k,mime:O.mimeType})}break}default:break}x.info("parts",{parts:y});let X=(()=>{let Y=y.filter((k)=>k.type==="text").map((k)=>k.text).join("").trim();if(!Y.startsWith("/"))return;let[O,...Z]=Y.slice(1).split(/\s+/);return{name:O,args:Z.join(" ").trim()}})(),W=(Y)=>({totalTokens:Y.tokens.input+Y.tokens.output+Y.tokens.reasoning+(Y.tokens.cache?.read??0)+(Y.tokens.cache?.write??0),inputTokens:Y.tokens.input,outputTokens:Y.tokens.output,thoughtTokens:Y.tokens.reasoning||void 0,cachedReadTokens:Y.tokens.cache?.read||void 0,cachedWriteTokens:Y.tokens.cache?.write||void 0}),J,G=!1;if(!X)G=!0,J=(await this.sdk.session.prompt({sessionID:$,model:{providerID:A.providerID,modelID:A.modelID},variant:this.sessionManager.getVariant($),parts:y,agent:_,directory:Q})).data?.info;else{let Y=await this.config.sdk.command.list({directory:Q},{throwOnError:!0}).then((O)=>O.data.find((Z)=>Z.name===X.name));if(Y)G=!0,J=(await this.sdk.session.command({sessionID:$,command:Y.name,arguments:X.args,model:A.providerID+"/"+A.modelID,agent:_,directory:Q})).data?.info;else switch(X.name){case"compact":await this.config.sdk.session.summarize({sessionID:$,directory:Q,providerID:A.providerID,modelID:A.modelID},{throwOnError:!0});break}}return await bw(this.connection,this.sdk,$,Q),{stopReason:"end_turn",...G?{usage:J?W(J):void 0}:{},_meta:{}}}async cancel(f){let $=this.sessionManager.get(f.sessionId);await this.config.sdk.session.abort({sessionID:f.sessionId,directory:$.cwd},{throwOnError:!0})}}async function U(f,$){let{sdk:D,defaultModel:Q}=f;if(Q)return Q;let j=$??process.cwd(),A=await D.config.get({directory:j},{throwOnError:!0}).then((J)=>{let G=J.data;if(!G||!G.model)return;return h.parseModel(G.model)}).catch((J)=>{x.error("failed to load user config for default model",{error:J});return}),_=await D.config.providers({directory:j},{throwOnError:!0}).then((J)=>J.data?.providers??[]).catch((J)=>{return x.error("failed to list providers for default model",{error:J}),[]});if(A&&_.length){let J=_.find((G)=>G.id===A.providerID);if(J&&J.models[A.modelID])return A}if(A&&!_.length)return A;let y=_.find((J)=>J.id==="opencode");if(y){if(y.models["big-pickle"])return{providerID:H.opencode,modelID:P.make("big-pickle")};let[J]=h.sort(Object.values(y.models));if(J)return{providerID:H.make(J.providerID),modelID:P.make(J.id)}}for(let J of["default","fast","economical","power"]){let G=Qf[J];if(!G)continue;if(_.find((O)=>O.id===G.providerID)?.models[G.modelID])return{providerID:H.make(G.providerID),modelID:P.make(G.modelID)}}let X=_.flatMap((J)=>Object.values(J.models)),[W]=h.sort(X);if(W)return{providerID:H.make(W.providerID),modelID:P.make(W.id)};if(A)return A;return{providerID:H.opencode,modelID:P.make("big-pickle")}}var aD=V.create({service:"acp-command"}),z$=Gf({command:"acp",describe:"start ACP (Agent Client Protocol) server",builder:(f)=>{return Af(f).option("cwd",{describe:"working directory",type:"string",default:process.cwd()})},handler:async(f)=>{process.env.QITQODE_CLIENT="acp",await Jf(process.cwd(),async()=>{let $=await Xf(f),D=await jf.listen($),Q=yf({baseUrl:`http://${D.hostname}:${D.port}`}),j=new WritableStream({write(X){return new Promise((W,J)=>{process.stdout.write(X,(G)=>{if(G)J(G);else W()})})}}),A=new ReadableStream({start(X){process.stdin.on("data",(W)=>{X.enqueue(new Uint8Array(W))}),process.stdin.on("end",()=>X.close()),process.stdin.on("error",(W)=>X.error(W))}}),_=rw(j,A),y=await E.init({sdk:Q});new Bw((X)=>{return y.create(X,{sdk:Q})},_),aD.info("setup connection"),process.stdin.resume(),await new Promise((X,W)=>{process.stdin.on("end",X),process.stdin.on("error",W)})})}});export{z$ as AcpCommand};
@@ -1,2 +0,0 @@
1
- // @bun
2
- import{Od as b}from"./chunk-wmmck56g.js";import{Sf as t}from"./chunk-ntmn6epc.js";import{qh as u}from"./chunk-0jv8r99k.js";import"./chunk-th189x63.js";import"./chunk-k6eyc1wv.js";import"./chunk-q6x5bmc3.js";import"./chunk-n1m5qdf5.js";import"./chunk-zeh3mjgp.js";import"./chunk-prrrw8t8.js";import"./chunk-tz8qhbk9.js";import"./chunk-k19zvbzh.js";import{Vk as y,ek as m}from"./chunk-3f6t3wde.js";import{rl as v}from"./chunk-b5h8vd5n.js";import{Pl as a}from"./chunk-jee9y4t0.js";import"./chunk-50aznc8e.js";import"./chunk-c4x99ayd.js";import"./chunk-73d0dy03.js";import"./chunk-ha5qct06.js";import"./chunk-w8xaw2dv.js";import"./chunk-tq258v8s.js";import"./chunk-ds162xgb.js";import"./chunk-jfy6bfvv.js";import"./chunk-2p6w3w8f.js";import"./chunk-98nh88th.js";import"./chunk-t7v8wzr9.js";import"./chunk-er5q8nhp.js";import"./chunk-cqtkxwd8.js";import"./chunk-h6htvj2y.js";import"./chunk-2qy62cv4.js";import"./chunk-t2n6fmpy.js";import"./chunk-x1naayst.js";import"./chunk-ng85b73s.js";import"./chunk-351wfvhp.js";import"./chunk-hmm1m733.js";import"./chunk-2bxy8zm1.js";import"./chunk-qq9pvscd.js";import"./chunk-3nc9wy1m.js";import"./chunk-r8ddb02d.js";import"./chunk-dhvwrrqx.js";import"./chunk-56cty7nr.js";import"./chunk-thbjhgw0.js";import"./chunk-p20ft5mj.js";import"./chunk-b5x3zghc.js";import"./chunk-t1f7jeat.js";import"./chunk-tk6gjy9d.js";import"./chunk-pkdk0ppc.js";import"./chunk-hrnx60em.js";import"./chunk-bbznk59q.js";import"./chunk-01gtn79f.js";import{$H as s}from"./chunk-meaa7wrs.js";import"./chunk-0ddhkapd.js";import"./chunk-gvj8qg7x.js";import"./chunk-fa03gsff.js";import{EOL as f}from"os";var M=b({command:"models [provider]",describe:"list all available models",builder:(r)=>{return r.positional("provider",{describe:"provider ID to filter models by",type:"string",array:!1}).option("verbose",{describe:"use more verbose model output (includes metadata like costs)",type:"boolean"}).option("refresh",{describe:"refresh the models cache from models.dev",type:"boolean"})},handler:async(r)=>{if(r.refresh)await v.refresh(!0),t.println(t.Style.TEXT_SUCCESS_BOLD+"Models cache refreshed"+t.Style.TEXT_NORMAL);await a.provide({directory:process.cwd(),async fn(){await u.runPromise(s.gen(function*(){let n=yield*(yield*y.Service).list(),l=(e,o)=>{let i=n[e],d=Object.entries(i.models).sort(([c],[p])=>c.localeCompare(p));for(let[c,p]of d)if(process.stdout.write(`${e}/${c}`),process.stdout.write(f),o)process.stdout.write(JSON.stringify(p,null,2)),process.stdout.write(f)};if(r.provider){let e=m.make(r.provider);if(!n[e]){yield*s.sync(()=>t.error(`Provider not found: ${r.provider}`));return}yield*s.sync(()=>l(e,r.verbose));return}let h=Object.keys(n).sort((e,o)=>{let i=e.startsWith("opencode"),d=o.startsWith("opencode");if(i&&!d)return-1;if(!i&&d)return 1;return e.localeCompare(o)});yield*s.sync(()=>{for(let e of h)l(m.make(e),r.verbose)})}))}})}});export{M as ModelsCommand};
@@ -1,2 +0,0 @@
1
- // @bun
2
- import{Eg as t}from"./chunk-awdpkgxf.js";import{pP as o}from"./chunk-fa03gsff.js";async function e(){try{let{toJSONSchema:r}=await import("./chunk-5z8gpy3x.js");return r}catch{throw new t("sury")}}export{e as default};
@@ -1,2 +0,0 @@
1
- // @bun
2
- import{Ad as c,zd as l}from"./chunk-2epf5806.js";import{Od as i}from"./chunk-wmmck56g.js";import{Lf as a}from"./chunk-18xhxdsh.js";import{Zf as n}from"./chunk-h5wh2d49.js";import"./chunk-xjdxyeja.js";import"./chunk-1zb95qfx.js";import"./chunk-cckshvkb.js";import"./chunk-hkqcpdmt.js";import"./chunk-nfg7nt13.js";import"./chunk-awdpkgxf.js";import"./chunk-8x6x3g16.js";import"./chunk-0jv8r99k.js";import"./chunk-th189x63.js";import"./chunk-k6eyc1wv.js";import"./chunk-q6x5bmc3.js";import"./chunk-n1m5qdf5.js";import"./chunk-zeh3mjgp.js";import"./chunk-prrrw8t8.js";import"./chunk-tz8qhbk9.js";import"./chunk-k19zvbzh.js";import"./chunk-3f6t3wde.js";import"./chunk-b5h8vd5n.js";import"./chunk-jee9y4t0.js";import"./chunk-50aznc8e.js";import"./chunk-c4x99ayd.js";import"./chunk-73d0dy03.js";import"./chunk-ha5qct06.js";import"./chunk-w8xaw2dv.js";import"./chunk-tq258v8s.js";import"./chunk-ds162xgb.js";import"./chunk-jfy6bfvv.js";import"./chunk-2p6w3w8f.js";import"./chunk-98nh88th.js";import"./chunk-t7v8wzr9.js";import"./chunk-er5q8nhp.js";import"./chunk-cqtkxwd8.js";import"./chunk-h6htvj2y.js";import"./chunk-2qy62cv4.js";import"./chunk-t2n6fmpy.js";import"./chunk-x1naayst.js";import"./chunk-ng85b73s.js";import"./chunk-351wfvhp.js";import"./chunk-hmm1m733.js";import"./chunk-2bxy8zm1.js";import"./chunk-qq9pvscd.js";import"./chunk-3nc9wy1m.js";import"./chunk-r8ddb02d.js";import"./chunk-dhvwrrqx.js";import"./chunk-56cty7nr.js";import"./chunk-thbjhgw0.js";import{dt as r}from"./chunk-p20ft5mj.js";import"./chunk-b5x3zghc.js";import"./chunk-t1f7jeat.js";import"./chunk-tk6gjy9d.js";import"./chunk-pkdk0ppc.js";import"./chunk-hrnx60em.js";import"./chunk-bbznk59q.js";import"./chunk-01gtn79f.js";import"./chunk-meaa7wrs.js";import"./chunk-0ddhkapd.js";import"./chunk-gvj8qg7x.js";import"./chunk-fa03gsff.js";var E=i({command:"serve",builder:(o)=>a(o).option("auto-password",{type:"boolean",default:!1,describe:"generate a random ephemeral QITQODE_SERVER_PASSWORD for this run and print it"}),describe:"starts a headless qitqode server",handler:async(o)=>{let s=await l(o);if(o["auto-password"]&&!r.QITQODE_SERVER_PASSWORD){let t=crypto.randomUUID();process.env.QITQODE_SERVER_PASSWORD=t,console.log('Generated ephemeral server password (basic auth, username "qitqode"):'),console.log(` ${t}`)}if(c(s,r.QITQODE_SERVER_PASSWORD))console.error("ERROR: Binding to non-loopback address without QITQODE_SERVER_PASSWORD is not allowed."),console.error("Set QITQODE_SERVER_PASSWORD, pass --auto-password, or pass --no-auth to override (DANGEROUS)."),process.exit(1);if(!r.QITQODE_SERVER_PASSWORD)console.error(""),console.error("\u2554\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2557"),console.error("\u2551 WARNING: server is running WITHOUT authentication. \u2551"),console.error("\u2551 \u2551"),console.error("\u2551 Any process or browser page that can reach this address can read \u2551"),console.error("\u2551 project files, run shell commands, and open terminals as you. \u2551"),console.error("\u2551 \u2551"),console.error("\u2551 Set QITQODE_SERVER_PASSWORD, or restart with --auto-password to \u2551"),console.error("\u2551 generate an ephemeral password for this run. \u2551"),console.error("\u255A\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u255D"),console.error("");let e=await n.listen(s);console.log(`qitqode server listening on http://${e.hostname}:${e.port}`),await new Promise(()=>{}),await e.stop()}});export{E as ServeCommand};
@@ -1,2 +0,0 @@
1
- // @bun
2
- import{Ag as l,Bg as m,pg as a,qg as b,rg as c,sg as d,tg as e,ug as f,vg as g,wg as h,xg as i,yg as j,zg as k}from"./chunk-cckshvkb.js";import"./chunk-k6eyc1wv.js";import"./chunk-tz8qhbk9.js";import"./chunk-ds162xgb.js";import"./chunk-t2n6fmpy.js";import"./chunk-x1naayst.js";import"./chunk-thbjhgw0.js";import"./chunk-p20ft5mj.js";import"./chunk-b5x3zghc.js";import"./chunk-t1f7jeat.js";import"./chunk-tk6gjy9d.js";import"./chunk-pkdk0ppc.js";import"./chunk-hrnx60em.js";import"./chunk-bbznk59q.js";import"./chunk-01gtn79f.js";import"./chunk-meaa7wrs.js";import"./chunk-fa03gsff.js";export{e as resolveDevicePoll,j as refreshAccessToken,i as probeToken,k as loginDevice,m as loginBrowser,l as login,c as isReplitEnv,g as isNearExpiry,d as getConfig,f as getCallbackUri,h as fetchQreditsBalance,a as ForgewiseError,b as DeviceFlowUnsupportedError};
@@ -1,2 +0,0 @@
1
- // @bun
2
- import{pP as t}from"./chunk-fa03gsff.js";var e=await import("./chunk-vf7hhxsa.js",{with:{type:"file"}}),a=e.default;export{a as default};
@@ -1,2 +0,0 @@
1
- // @bun
2
- import"./chunk-fa03gsff.js";var G="./tree-sitter-bash-hq5s6fxb.wasm";export{G as default};
@@ -1,2 +0,0 @@
1
- // @bun
2
- import"./chunk-fa03gsff.js";var L="./opentui-c5en9p2g.dll";export{L as default};
@@ -1,2 +0,0 @@
1
- // @bun
2
- import{zf as l}from"./chunk-qxrjbw22.js";import"./chunk-cn7nnjsf.js";import{Cg as q}from"./chunk-hkqcpdmt.js";import"./chunk-nfg7nt13.js";import"./chunk-awdpkgxf.js";import{pP as C}from"./chunk-fa03gsff.js";function J(){return async(f,b)=>{if("_zod"in f)return l()(f,{components:b.components,options:{io:"input",...b.options}});try{let{createSchema:w}=await import("./chunk-vqxyph4q.js"),{schema:B,components:k}=w(f,{schemaType:"input",...b.options});if(k)b.components.schemas={...b.components.schemas,...k};return B}catch{throw Error(q('Missing dependencies "zod-openapi v4".'))}}}export{J as default};
@@ -1,2 +0,0 @@
1
- // @bun
2
- import{Ap as h,Bp as i,tp as a,up as b,vp as c,wp as d,xp as e,yp as f,zp as g}from"./chunk-98nh88th.js";import"./chunk-t7v8wzr9.js";import"./chunk-er5q8nhp.js";import"./chunk-cqtkxwd8.js";import"./chunk-h6htvj2y.js";import"./chunk-2qy62cv4.js";import"./chunk-tk6gjy9d.js";import"./chunk-hrnx60em.js";import"./chunk-bbznk59q.js";import"./chunk-fa03gsff.js";export{i as gateway,h as createGatewayProvider,h as createGateway,g as GatewayResponseError,d as GatewayRateLimitError,e as GatewayModelNotFoundError,c as GatewayInvalidRequestError,f as GatewayInternalServerError,a as GatewayError,b as GatewayAuthenticationError};
@@ -1,3 +0,0 @@
1
- // @bun
2
- import{Cu as o}from"./chunk-hrnx60em.js";var e=o;
3
- export{e as It};
@@ -1,2 +0,0 @@
1
- // @bun
2
- import{$O as a,aP as b,bP as c,cP as d,dP as e,eP as f,fP as g,gP as h,hP as i,iP as j}from"./chunk-0ddhkapd.js";import"./chunk-fa03gsff.js";export{c as TreeCursor,b as Tree,f as Query,j as Parser,d as Node,i as MIN_COMPATIBLE_VERSION,a as LookaheadIterator,g as Language,h as LANGUAGE_VERSION,e as CaptureQuantifier};
@@ -1,2 +0,0 @@
1
- // @bun
2
- import{jg as a,kg as b,lg as c}from"./chunk-xjdxyeja.js";import"./chunk-3f6t3wde.js";import"./chunk-b5h8vd5n.js";import"./chunk-jee9y4t0.js";import"./chunk-50aznc8e.js";import"./chunk-c4x99ayd.js";import"./chunk-73d0dy03.js";import"./chunk-ha5qct06.js";import"./chunk-w8xaw2dv.js";import"./chunk-tq258v8s.js";import"./chunk-ds162xgb.js";import"./chunk-jfy6bfvv.js";import"./chunk-2p6w3w8f.js";import"./chunk-98nh88th.js";import"./chunk-t7v8wzr9.js";import"./chunk-er5q8nhp.js";import"./chunk-cqtkxwd8.js";import"./chunk-h6htvj2y.js";import"./chunk-2qy62cv4.js";import"./chunk-t2n6fmpy.js";import"./chunk-x1naayst.js";import"./chunk-ng85b73s.js";import"./chunk-2bxy8zm1.js";import"./chunk-qq9pvscd.js";import"./chunk-3nc9wy1m.js";import"./chunk-r8ddb02d.js";import"./chunk-dhvwrrqx.js";import"./chunk-56cty7nr.js";import"./chunk-thbjhgw0.js";import"./chunk-p20ft5mj.js";import"./chunk-b5x3zghc.js";import"./chunk-t1f7jeat.js";import"./chunk-tk6gjy9d.js";import"./chunk-pkdk0ppc.js";import"./chunk-hrnx60em.js";import"./chunk-bbznk59q.js";import"./chunk-01gtn79f.js";import"./chunk-meaa7wrs.js";import"./chunk-gvj8qg7x.js";import"./chunk-fa03gsff.js";export{b as run,a as encodeDir,c as ClaudeImport};
@@ -1,2 +0,0 @@
1
- // @bun
2
- import{s as a,t as b,u as c,v as d,w as e,x as f,y as g}from"./chunk-40vz0fhv.js";import"./chunk-73d0dy03.js";import"./chunk-ha5qct06.js";import"./chunk-w8xaw2dv.js";import"./chunk-tq258v8s.js";import"./chunk-qq9pvscd.js";import"./chunk-3nc9wy1m.js";import"./chunk-r8ddb02d.js";import"./chunk-56cty7nr.js";import"./chunk-p20ft5mj.js";import"./chunk-b5x3zghc.js";import"./chunk-t1f7jeat.js";import"./chunk-tk6gjy9d.js";import"./chunk-pkdk0ppc.js";import"./chunk-hrnx60em.js";import"./chunk-bbznk59q.js";import"./chunk-01gtn79f.js";import"./chunk-meaa7wrs.js";import"./chunk-fa03gsff.js";export{e as waitForDependencies,c as layer,f as get,d as defaultLayer,g as TuiConfig,b as Service,a as Info};
@@ -1,2 +0,0 @@
1
- // @bun
2
- import{Eg as t}from"./chunk-awdpkgxf.js";import{pP as n}from"./chunk-fa03gsff.js";async function a(){try{let{JSONSchema:e}=await import("./chunk-fgtyrvan.js");return(r)=>e.make(r)}catch{throw new t("effect")}}export{a as default};
@@ -1,2 +0,0 @@
1
- // @bun
2
- import"./chunk-fa03gsff.js";var _="./libopentui-0r5w9btr.so";export{_ as default};
@@ -1,2 +0,0 @@
1
- // @bun
2
- import{Gg as a}from"./chunk-8x6x3g16.js";import{Xg as t,qh as c}from"./chunk-0jv8r99k.js";import"./chunk-th189x63.js";import"./chunk-k6eyc1wv.js";import"./chunk-q6x5bmc3.js";import"./chunk-n1m5qdf5.js";import"./chunk-zeh3mjgp.js";import"./chunk-prrrw8t8.js";import"./chunk-tz8qhbk9.js";import"./chunk-k19zvbzh.js";import"./chunk-3f6t3wde.js";import"./chunk-b5h8vd5n.js";import"./chunk-jee9y4t0.js";import"./chunk-50aznc8e.js";import"./chunk-c4x99ayd.js";import"./chunk-73d0dy03.js";import"./chunk-ha5qct06.js";import"./chunk-w8xaw2dv.js";import"./chunk-tq258v8s.js";import"./chunk-ds162xgb.js";import"./chunk-jfy6bfvv.js";import"./chunk-2p6w3w8f.js";import"./chunk-98nh88th.js";import"./chunk-t7v8wzr9.js";import"./chunk-er5q8nhp.js";import"./chunk-cqtkxwd8.js";import"./chunk-h6htvj2y.js";import"./chunk-2qy62cv4.js";import"./chunk-t2n6fmpy.js";import"./chunk-x1naayst.js";import"./chunk-ng85b73s.js";import"./chunk-351wfvhp.js";import"./chunk-hmm1m733.js";import"./chunk-2bxy8zm1.js";import"./chunk-qq9pvscd.js";import"./chunk-3nc9wy1m.js";import"./chunk-r8ddb02d.js";import"./chunk-dhvwrrqx.js";import"./chunk-56cty7nr.js";import"./chunk-thbjhgw0.js";import"./chunk-p20ft5mj.js";import"./chunk-b5x3zghc.js";import"./chunk-t1f7jeat.js";import{It as i}from"./chunk-tk6gjy9d.js";import"./chunk-pkdk0ppc.js";import"./chunk-hrnx60em.js";import"./chunk-bbznk59q.js";import"./chunk-01gtn79f.js";import"./chunk-meaa7wrs.js";import"./chunk-0ddhkapd.js";import"./chunk-gvj8qg7x.js";import"./chunk-fa03gsff.js";var n=i.object({name:a.shape.name,branch:a.shape.branch.unwrap(),directory:a.shape.directory.unwrap()}),d={name:"Worktree",description:"Create a git worktree",async configure(e){let r=await c.runPromise(t.Service.use((o)=>o.makeWorktreeInfo()));return{...e,name:r.name,branch:r.branch,directory:r.directory}},async create(e){let r=n.parse(e);await c.runPromise(t.Service.use((o)=>o.createFromInfo({name:r.name,directory:r.directory,branch:r.branch})))},async remove(e){let r=n.parse(e);await c.runPromise(t.Service.use((o)=>o.remove({directory:r.directory})))},target(e){return{type:"local",directory:n.parse(e).directory}}};export{d as WorktreeAdaptor};
@@ -1,2 +0,0 @@
1
- // @bun
2
- import{Dl as s,El as t,Fl as u,Hl as v,Il as w}from"./chunk-jee9y4t0.js";import"./chunk-50aznc8e.js";import{Gn as q,Hn as r,Im as a,in as b,jn as c,kn as d,ln as e,mn as f,nn as g,on as h,pn as i,qn as j,rn as k,tn as l,un as m,vn as n,xn as o,zn as p}from"./chunk-c4x99ayd.js";import"./chunk-tq258v8s.js";import"./chunk-jfy6bfvv.js";import"./chunk-2p6w3w8f.js";import"./chunk-2bxy8zm1.js";import"./chunk-qq9pvscd.js";import"./chunk-3nc9wy1m.js";import"./chunk-dhvwrrqx.js";import"./chunk-56cty7nr.js";import"./chunk-p20ft5mj.js";import"./chunk-b5x3zghc.js";import"./chunk-t1f7jeat.js";import"./chunk-tk6gjy9d.js";import"./chunk-pkdk0ppc.js";import"./chunk-hrnx60em.js";import"./chunk-bbznk59q.js";import"./chunk-01gtn79f.js";import"./chunk-meaa7wrs.js";import"./chunk-fa03gsff.js";export{a as sql,e as or,f as not,c as ne,j as lte,i as lt,p as like,l as isNull,m as isNotNull,k as inArray,h as gte,g as gt,n as exists,b as eq,r as desc,t as count,o as between,q as asc,d as and,w as Storage,v as NotFoundError,s as JsonMigration,u as Database};
@@ -1,2 +0,0 @@
1
- // @bun
2
- import"./chunk-fa03gsff.js";var A="./tree-sitter-zig-e78zbjpm.wasm";export{A as default};
@@ -1,2 +0,0 @@
1
- // @bun
2
- import{m as a}from"./chunk-vpp88hhd.js";import"./chunk-a3a9bbk7.js";import"./chunk-40vz0fhv.js";import"./chunk-3w60y2x5.js";import"./chunk-zbvf09bm.js";import"./chunk-jj7wrfty.js";import"./chunk-43xq4p51.js";import"./chunk-3degq6rv.js";import"./chunk-hf0gny5t.js";import"./chunk-fd1vbz1f.js";import"./chunk-7b69jj5g.js";import"./chunk-x1dfc7qd.js";import"./chunk-en7nxqvn.js";import"./chunk-v9sfzkg5.js";import"./chunk-djcsvcby.js";import"./chunk-ntmn6epc.js";import"./chunk-1zb95qfx.js";import"./chunk-cckshvkb.js";import"./chunk-th189x63.js";import"./chunk-k6eyc1wv.js";import"./chunk-tz8qhbk9.js";import"./chunk-3f6t3wde.js";import"./chunk-b5h8vd5n.js";import"./chunk-jee9y4t0.js";import"./chunk-50aznc8e.js";import"./chunk-c4x99ayd.js";import"./chunk-73d0dy03.js";import"./chunk-ha5qct06.js";import"./chunk-w8xaw2dv.js";import"./chunk-tq258v8s.js";import"./chunk-ds162xgb.js";import"./chunk-jfy6bfvv.js";import"./chunk-2p6w3w8f.js";import"./chunk-98nh88th.js";import"./chunk-t7v8wzr9.js";import"./chunk-er5q8nhp.js";import"./chunk-cqtkxwd8.js";import"./chunk-h6htvj2y.js";import"./chunk-2qy62cv4.js";import"./chunk-t2n6fmpy.js";import"./chunk-x1naayst.js";import"./chunk-ng85b73s.js";import"./chunk-2bxy8zm1.js";import"./chunk-qq9pvscd.js";import"./chunk-3nc9wy1m.js";import"./chunk-r8ddb02d.js";import"./chunk-dhvwrrqx.js";import"./chunk-56cty7nr.js";import"./chunk-thbjhgw0.js";import"./chunk-p20ft5mj.js";import"./chunk-b5x3zghc.js";import"./chunk-t1f7jeat.js";import"./chunk-tk6gjy9d.js";import"./chunk-pkdk0ppc.js";import"./chunk-hrnx60em.js";import"./chunk-bbznk59q.js";import"./chunk-01gtn79f.js";import"./chunk-meaa7wrs.js";import"./chunk-gvj8qg7x.js";import"./chunk-fa03gsff.js";export{a as tui};
@@ -1,2 +0,0 @@
1
- // @bun
2
- import{sp as a}from"./chunk-2p6w3w8f.js";import"./chunk-dhvwrrqx.js";import"./chunk-p20ft5mj.js";import"./chunk-b5x3zghc.js";import"./chunk-t1f7jeat.js";import"./chunk-tk6gjy9d.js";import"./chunk-pkdk0ppc.js";import"./chunk-hrnx60em.js";import"./chunk-bbznk59q.js";import"./chunk-01gtn79f.js";import"./chunk-meaa7wrs.js";import"./chunk-fa03gsff.js";export{a as which};
@@ -1,2 +0,0 @@
1
- // @bun
2
- import{Vf as a,Wf as b,Xf as c,Yf as d,Zf as e}from"./chunk-h5wh2d49.js";import"./chunk-xjdxyeja.js";import"./chunk-1zb95qfx.js";import"./chunk-cckshvkb.js";import"./chunk-hkqcpdmt.js";import"./chunk-nfg7nt13.js";import"./chunk-awdpkgxf.js";import"./chunk-8x6x3g16.js";import"./chunk-0jv8r99k.js";import"./chunk-th189x63.js";import"./chunk-k6eyc1wv.js";import"./chunk-q6x5bmc3.js";import"./chunk-n1m5qdf5.js";import"./chunk-zeh3mjgp.js";import"./chunk-prrrw8t8.js";import"./chunk-tz8qhbk9.js";import"./chunk-k19zvbzh.js";import"./chunk-3f6t3wde.js";import"./chunk-b5h8vd5n.js";import"./chunk-jee9y4t0.js";import"./chunk-50aznc8e.js";import"./chunk-c4x99ayd.js";import"./chunk-73d0dy03.js";import"./chunk-ha5qct06.js";import"./chunk-w8xaw2dv.js";import"./chunk-tq258v8s.js";import"./chunk-ds162xgb.js";import"./chunk-jfy6bfvv.js";import"./chunk-2p6w3w8f.js";import"./chunk-98nh88th.js";import"./chunk-t7v8wzr9.js";import"./chunk-er5q8nhp.js";import"./chunk-cqtkxwd8.js";import"./chunk-h6htvj2y.js";import"./chunk-2qy62cv4.js";import"./chunk-t2n6fmpy.js";import"./chunk-x1naayst.js";import"./chunk-ng85b73s.js";import"./chunk-351wfvhp.js";import"./chunk-hmm1m733.js";import"./chunk-2bxy8zm1.js";import"./chunk-qq9pvscd.js";import"./chunk-3nc9wy1m.js";import"./chunk-r8ddb02d.js";import"./chunk-dhvwrrqx.js";import"./chunk-56cty7nr.js";import"./chunk-thbjhgw0.js";import"./chunk-p20ft5mj.js";import"./chunk-b5x3zghc.js";import"./chunk-t1f7jeat.js";import"./chunk-tk6gjy9d.js";import"./chunk-pkdk0ppc.js";import"./chunk-hrnx60em.js";import"./chunk-bbznk59q.js";import"./chunk-01gtn79f.js";import"./chunk-meaa7wrs.js";import"./chunk-0ddhkapd.js";import"./chunk-gvj8qg7x.js";import"./chunk-fa03gsff.js";export{c as url,b as openapi,d as listen,e as Server,a as Default};