@opencode-ai/core 0.0.0-dev-18110 → 0.0.0-dev-18111

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 (763) hide show
  1. package/dist/account/sql.js +2 -2
  2. package/dist/agent.js +74 -74
  3. package/dist/aisdk-native.js +3 -3
  4. package/dist/aisdk.js +4 -4
  5. package/dist/app.js +2 -2
  6. package/dist/bus.js +72 -72
  7. package/dist/catalog.js +82 -82
  8. package/dist/chunks/{filesystem-02dbfq60.js → instruction-discovery-02dbfq60.js} +1 -1
  9. package/dist/chunks/{filesystem-02s4hv33.js → instruction-discovery-02s4hv33.js} +4 -4
  10. package/dist/chunks/{filesystem-w4bchrbz.js → instruction-discovery-06xrnyqr.js} +8 -8
  11. package/dist/chunks/{filesystem-0b17sr9d.js → instruction-discovery-0b17sr9d.js} +2 -2
  12. package/dist/chunks/{filesystem-36fzb5s4.js → instruction-discovery-0b4jrky0.js} +3 -3
  13. package/dist/chunks/{filesystem-1apqaax6.js → instruction-discovery-0h0tr10f.js} +10 -10
  14. package/dist/chunks/{filesystem-h9jcba80.js → instruction-discovery-0kgwk256.js} +6 -6
  15. package/dist/chunks/{filesystem-0kvmztkf.js → instruction-discovery-0kvmztkf.js} +1 -1
  16. package/dist/chunks/{filesystem-0ztbj8mr.js → instruction-discovery-0r2hn7v8.js} +8 -8
  17. package/dist/chunks/{filesystem-3gr80pp9.js → instruction-discovery-0rvwjg22.js} +4 -4
  18. package/dist/chunks/{filesystem-0vgt3zn6.js → instruction-discovery-0vgt3zn6.js} +2 -2
  19. package/dist/chunks/{filesystem-kv9ma7px.js → instruction-discovery-132qv026.js} +9 -9
  20. package/dist/chunks/{filesystem-4kgkybk2.js → instruction-discovery-14kfq7dq.js} +4 -4
  21. package/dist/chunks/{filesystem-18pv8fg3.js → instruction-discovery-18pv8fg3.js} +2 -2
  22. package/dist/chunks/{filesystem-1a3a2s70.js → instruction-discovery-1a3a2s70.js} +2 -2
  23. package/dist/chunks/{filesystem-1b390eyt.js → instruction-discovery-1b390eyt.js} +2 -2
  24. package/dist/chunks/{filesystem-r6298cr9.js → instruction-discovery-1fvrp910.js} +4 -4
  25. package/dist/chunks/{filesystem-hdxpw9dd.js → instruction-discovery-1kn0sbhx.js} +3 -3
  26. package/dist/chunks/{filesystem-dzszr927.js → instruction-discovery-1xhs89av.js} +3 -3
  27. package/dist/chunks/{filesystem-br5dm3d1.js → instruction-discovery-264hbdwe.js} +4 -4
  28. package/dist/chunks/{filesystem-2nmyybe0.js → instruction-discovery-2nmyybe0.js} +1 -1
  29. package/dist/chunks/{filesystem-2ya5073c.js → instruction-discovery-2ya5073c.js} +1 -1
  30. package/dist/chunks/{filesystem-2zf7hxjt.js → instruction-discovery-2zf7hxjt.js} +2 -2
  31. package/dist/chunks/{filesystem-p8aq3r46.js → instruction-discovery-34566ygw.js} +90 -90
  32. package/dist/chunks/{filesystem-37e9hbzs.js → instruction-discovery-37e9hbzs.js} +2 -2
  33. package/dist/chunks/{filesystem-04wb7xa8.js → instruction-discovery-3cpyz1g2.js} +5 -5
  34. package/dist/chunks/{filesystem-3d1t6jqf.js → instruction-discovery-3d1t6jqf.js} +3 -3
  35. package/dist/chunks/{filesystem-3g8vftxb.js → instruction-discovery-3g8vftxb.js} +2 -2
  36. package/dist/chunks/{filesystem-3gsv1x0v.js → instruction-discovery-3gsv1x0v.js} +2 -2
  37. package/dist/chunks/{filesystem-3thh6229.js → instruction-discovery-3thh6229.js} +2 -2
  38. package/dist/chunks/{filesystem-kxvkzhzr.js → instruction-discovery-4681ewq2.js} +7 -7
  39. package/dist/chunks/{filesystem-4j7te1s0.js → instruction-discovery-4j7te1s0.js} +2 -2
  40. package/dist/chunks/{filesystem-rrv7gaha.js → instruction-discovery-4rr0rhqg.js} +3 -3
  41. package/dist/chunks/{filesystem-4s2xwh5d.js → instruction-discovery-4s2xwh5d.js} +3 -3
  42. package/dist/chunks/{filesystem-qt85ans7.js → instruction-discovery-4w177n48.js} +1 -1
  43. package/dist/chunks/{filesystem-0x74beht.js → instruction-discovery-4wjap1t8.js} +12 -12
  44. package/dist/chunks/{filesystem-hz9eszaw.js → instruction-discovery-4xgpx06v.js} +17 -15
  45. package/dist/chunks/{filesystem-4zzdwbaz.js → instruction-discovery-4zzdwbaz.js} +2 -2
  46. package/dist/chunks/{filesystem-50jxp3hw.js → instruction-discovery-50jxp3hw.js} +1 -1
  47. package/dist/chunks/{filesystem-mjd2nyv7.js → instruction-discovery-52kdeqqe.js} +2 -2
  48. package/dist/chunks/{filesystem-3p99tmpz.js → instruction-discovery-52xz47dr.js} +3 -3
  49. package/dist/chunks/{filesystem-57tzwnz4.js → instruction-discovery-57tzwnz4.js} +1 -1
  50. package/dist/chunks/{filesystem-50qcmj3d.js → instruction-discovery-5859v30w.js} +2 -2
  51. package/dist/chunks/{filesystem-58xdvehb.js → instruction-discovery-58xdvehb.js} +1 -1
  52. package/dist/chunks/{filesystem-5fe026tx.js → instruction-discovery-5fe026tx.js} +3 -3
  53. package/dist/chunks/{filesystem-5rs65q6p.js → instruction-discovery-5rs65q6p.js} +1 -1
  54. package/dist/chunks/{filesystem-vz8gr2c9.js → instruction-discovery-5rw21afg.js} +2 -2
  55. package/dist/chunks/{filesystem-5vcssjzn.js → instruction-discovery-5vcssjzn.js} +1 -1
  56. package/dist/chunks/{filesystem-5xrsrne4.js → instruction-discovery-5xrsrne4.js} +3 -3
  57. package/dist/chunks/{filesystem-65re92qg.js → instruction-discovery-65re92qg.js} +2 -2
  58. package/dist/chunks/{filesystem-wq39pv62.js → instruction-discovery-6725tqt6.js} +6 -6
  59. package/dist/chunks/{filesystem-1bpc3cv5.js → instruction-discovery-6930qah5.js} +5 -5
  60. package/dist/chunks/{filesystem-7qby5337.js → instruction-discovery-6ddn0q3b.js} +3 -3
  61. package/dist/chunks/{filesystem-6ky7rqk7.js → instruction-discovery-6ky7rqk7.js} +1 -1
  62. package/dist/chunks/{filesystem-6q0m15b3.js → instruction-discovery-6q0m15b3.js} +1 -1
  63. package/dist/chunks/{filesystem-6x98y149.js → instruction-discovery-6x98y149.js} +2 -2
  64. package/dist/chunks/{filesystem-se63n289.js → instruction-discovery-71bgs1st.js} +10 -10
  65. package/dist/chunks/{filesystem-sn3p2e32.js → instruction-discovery-7ecbe3af.js} +11 -11
  66. package/dist/chunks/{filesystem-7gqqz1s8.js → instruction-discovery-7gqqz1s8.js} +1 -1
  67. package/dist/chunks/{filesystem-7mrpdsq5.js → instruction-discovery-7mrpdsq5.js} +1 -1
  68. package/dist/chunks/{filesystem-yqs8hzhh.js → instruction-discovery-7ns9sywf.js} +8 -8
  69. package/dist/chunks/{filesystem-7wcmqxrc.js → instruction-discovery-7wcmqxrc.js} +1 -1
  70. package/dist/chunks/{filesystem-rrta77be.js → instruction-discovery-7xswjvxz.js} +5 -5
  71. package/dist/chunks/{filesystem-81gd7d42.js → instruction-discovery-81gd7d42.js} +1 -1
  72. package/dist/chunks/{filesystem-88jbfw8z.js → instruction-discovery-88jbfw8z.js} +2 -2
  73. package/dist/chunks/{filesystem-5bht3hph.js → instruction-discovery-8a40j5tg.js} +89 -89
  74. package/dist/chunks/{filesystem-8bkmtpp6.js → instruction-discovery-8bkmtpp6.js} +2 -2
  75. package/dist/chunks/{filesystem-8bqpm1yy.js → instruction-discovery-8bqpm1yy.js} +2 -2
  76. package/dist/chunks/{filesystem-gb9476yd.js → instruction-discovery-8e0b3q0s.js} +3 -3
  77. package/dist/chunks/{filesystem-8gp1tmat.js → instruction-discovery-8gp1tmat.js} +3 -3
  78. package/dist/chunks/{filesystem-pr12jhvw.js → instruction-discovery-8h057cpk.js} +7 -7
  79. package/dist/chunks/{filesystem-yg7xqkd8.js → instruction-discovery-8jspjm96.js} +2 -2
  80. package/dist/chunks/{filesystem-f1qndag7.js → instruction-discovery-8k223q5z.js} +7 -7
  81. package/dist/chunks/{filesystem-2jmaq2xg.js → instruction-discovery-8tk4fw0q.js} +7 -7
  82. package/dist/chunks/{filesystem-8v47shgf.js → instruction-discovery-8v47shgf.js} +2 -2
  83. package/dist/chunks/{filesystem-td0yr3hv.js → instruction-discovery-8zbqxhya.js} +10 -10
  84. package/dist/chunks/{filesystem-kr1g6fs4.js → instruction-discovery-91pt43pt.js} +4 -4
  85. package/dist/chunks/{filesystem-3mj2qned.js → instruction-discovery-92tez4qm.js} +3 -3
  86. package/dist/chunks/{filesystem-999qd968.js → instruction-discovery-999qd968.js} +1 -1
  87. package/dist/chunks/{filesystem-9f0rnpkn.js → instruction-discovery-9f0rnpkn.js} +1 -1
  88. package/dist/chunks/{filesystem-604cefgg.js → instruction-discovery-9jbyw4wf.js} +7 -7
  89. package/dist/chunks/{filesystem-4xvdb18m.js → instruction-discovery-9nm3vqzr.js} +3 -3
  90. package/dist/chunks/{filesystem-9p8mhgdp.js → instruction-discovery-9p8mhgdp.js} +1 -1
  91. package/dist/chunks/{filesystem-fxqrk4vv.js → instruction-discovery-9v6j1pv5.js} +11 -11
  92. package/dist/chunks/{filesystem-98qyrz86.js → instruction-discovery-a1v3cs4g.js} +4 -4
  93. package/dist/chunks/{filesystem-ekxg176y.js → instruction-discovery-ak1xffce.js} +16 -16
  94. package/dist/chunks/{filesystem-qqg0v1cf.js → instruction-discovery-ana2f2bw.js} +149 -149
  95. package/dist/chunks/{filesystem-ayfwnm78.js → instruction-discovery-ayfwnm78.js} +2 -2
  96. package/dist/chunks/{filesystem-dygdn9a0.js → instruction-discovery-azq34g6d.js} +3 -3
  97. package/dist/chunks/{filesystem-y533w59j.js → instruction-discovery-b2phsnmz.js} +6 -6
  98. package/dist/chunks/{filesystem-b7hsw5bk.js → instruction-discovery-b7hsw5bk.js} +3 -3
  99. package/dist/chunks/{filesystem-7ad89gx7.js → instruction-discovery-b8ht6622.js} +12 -12
  100. package/dist/chunks/{filesystem-xzygyczk.js → instruction-discovery-bbknaa7d.js} +3 -3
  101. package/dist/chunks/{filesystem-mrph615q.js → instruction-discovery-besznhxz.js} +9 -9
  102. package/dist/chunks/instruction-discovery-bg26xskw.js +165 -0
  103. package/dist/chunks/{filesystem-bh1wr8rq.js → instruction-discovery-bh1wr8rq.js} +2 -2
  104. package/dist/chunks/{filesystem-w1w0wehs.js → instruction-discovery-brn551tr.js} +6 -6
  105. package/dist/chunks/{filesystem-8swsf72c.js → instruction-discovery-bsdk5e0q.js} +2 -2
  106. package/dist/chunks/{filesystem-byab506k.js → instruction-discovery-byab506k.js} +1 -1
  107. package/dist/chunks/{filesystem-khzgnvgv.js → instruction-discovery-byhbgs2h.js} +5 -5
  108. package/dist/chunks/{filesystem-mb7pwhcp.js → instruction-discovery-c0603bsx.js} +11 -11
  109. package/dist/chunks/{filesystem-45jfh8w6.js → instruction-discovery-c3e3zktz.js} +3 -3
  110. package/dist/chunks/{filesystem-c4wcb9vc.js → instruction-discovery-c4wcb9vc.js} +2 -2
  111. package/dist/chunks/{filesystem-c9tk9ghs.js → instruction-discovery-c9tk9ghs.js} +2 -2
  112. package/dist/chunks/{filesystem-s27vnxnv.js → instruction-discovery-cd3hk9pq.js} +20 -20
  113. package/dist/chunks/{filesystem-szn5vbwx.js → instruction-discovery-cp4pq70q.js} +8 -8
  114. package/dist/chunks/{filesystem-t1zt48pm.js → instruction-discovery-crhw50q6.js} +3 -3
  115. package/dist/chunks/{filesystem-cve546b2.js → instruction-discovery-cve546b2.js} +2 -2
  116. package/dist/chunks/{filesystem-cz3dkvcz.js → instruction-discovery-cz3dkvcz.js} +1 -1
  117. package/dist/chunks/{filesystem-d2gk9vpf.js → instruction-discovery-d2gk9vpf.js} +2 -2
  118. package/dist/chunks/{filesystem-sfnaq1w3.js → instruction-discovery-d4msh2h8.js} +9 -9
  119. package/dist/chunks/{filesystem-yrnqef48.js → instruction-discovery-dagfhnya.js} +4 -4
  120. package/dist/chunks/{filesystem-1cjkbzgd.js → instruction-discovery-dcqfw7nd.js} +16 -16
  121. package/dist/chunks/{filesystem-dhphtf1x.js → instruction-discovery-dhphtf1x.js} +1 -1
  122. package/dist/chunks/{filesystem-2d721v68.js → instruction-discovery-djh6t5cr.js} +14 -14
  123. package/dist/chunks/{filesystem-djkt4gex.js → instruction-discovery-djkt4gex.js} +1 -1
  124. package/dist/chunks/{filesystem-dyrphakh.js → instruction-discovery-dyrphakh.js} +2 -2
  125. package/dist/chunks/{filesystem-e1z9a0ts.js → instruction-discovery-e1z9a0ts.js} +2 -2
  126. package/dist/chunks/{filesystem-x4bsx9a7.js → instruction-discovery-ebd3pxjs.js} +4 -4
  127. package/dist/chunks/{filesystem-ec8vrfw5.js → instruction-discovery-ec8vrfw5.js} +1 -1
  128. package/dist/chunks/{filesystem-epzxjdf4.js → instruction-discovery-epzxjdf4.js} +4 -4
  129. package/dist/chunks/{filesystem-3yz3vxy5.js → instruction-discovery-esft0v9g.js} +3 -3
  130. package/dist/chunks/{filesystem-6s8tgd4z.js → instruction-discovery-f7bq3b93.js} +2 -2
  131. package/dist/chunks/{filesystem-f9wt0tjw.js → instruction-discovery-f9wt0tjw.js} +2 -2
  132. package/dist/chunks/{filesystem-fb7nfzf2.js → instruction-discovery-fb7nfzf2.js} +3 -3
  133. package/dist/chunks/{filesystem-v7kzwzr2.js → instruction-discovery-fe4ev4wa.js} +14 -14
  134. package/dist/chunks/{filesystem-qk4fb492.js → instruction-discovery-fq362v4d.js} +9 -9
  135. package/dist/chunks/{filesystem-cnd0crb8.js → instruction-discovery-fx7jz4gh.js} +4 -4
  136. package/dist/chunks/{filesystem-fw9jf2ch.js → instruction-discovery-fxq037mg.js} +11 -11
  137. package/dist/chunks/{filesystem-em2vapdc.js → instruction-discovery-g5yytc8k.js} +4 -4
  138. package/dist/chunks/{filesystem-g7t6p8r2.js → instruction-discovery-g7t6p8r2.js} +1 -1
  139. package/dist/chunks/{filesystem-gcay93cp.js → instruction-discovery-gcay93cp.js} +1 -1
  140. package/dist/chunks/{filesystem-gd2xppx8.js → instruction-discovery-gd2xppx8.js} +1 -1
  141. package/dist/chunks/{filesystem-gg8gy1ab.js → instruction-discovery-gg8gy1ab.js} +2 -2
  142. package/dist/chunks/{filesystem-fp0tw0ch.js → instruction-discovery-gkh260bw.js} +70 -88
  143. package/dist/chunks/{filesystem-26w00a7e.js → instruction-discovery-gqw7y7as.js} +11 -11
  144. package/dist/chunks/{filesystem-cf7gjndv.js → instruction-discovery-gr94h9fd.js} +7 -7
  145. package/dist/chunks/{filesystem-f6cxk7mm.js → instruction-discovery-gtz0an4j.js} +11 -11
  146. package/dist/chunks/{filesystem-t9sa50hm.js → instruction-discovery-h52ce3rk.js} +8 -8
  147. package/dist/chunks/{filesystem-mwav8sab.js → instruction-discovery-h5mp5eph.js} +6 -6
  148. package/dist/chunks/instruction-discovery-h80b8war.js +88 -0
  149. package/dist/chunks/{filesystem-hhxt27np.js → instruction-discovery-hhxt27np.js} +2 -2
  150. package/dist/chunks/{filesystem-hp6rpdnc.js → instruction-discovery-hp6rpdnc.js} +1 -1
  151. package/dist/chunks/{filesystem-sf2vk4y8.js → instruction-discovery-hs6448wb.js} +38 -38
  152. package/dist/chunks/{filesystem-zyv51q6q.js → instruction-discovery-j5q8scqt.js} +8 -8
  153. package/dist/chunks/{filesystem-pb5s395z.js → instruction-discovery-j61j5jvt.js} +3 -3
  154. package/dist/chunks/{filesystem-agcg23yb.js → instruction-discovery-jqwgj4ce.js} +4 -4
  155. package/dist/chunks/{filesystem-jssy2dr3.js → instruction-discovery-jssy2dr3.js} +2 -2
  156. package/dist/chunks/{filesystem-yhvdxpmg.js → instruction-discovery-jstqjytf.js} +4 -4
  157. package/dist/chunks/{filesystem-7brhcdvk.js → instruction-discovery-jt4gx59n.js} +11 -11
  158. package/dist/chunks/{filesystem-6daw6q6m.js → instruction-discovery-jx3sqvpf.js} +10 -10
  159. package/dist/chunks/{filesystem-bcrzy98y.js → instruction-discovery-k07xxtsn.js} +5 -5
  160. package/dist/chunks/{filesystem-ha92wrhk.js → instruction-discovery-k2mv4rgw.js} +7 -7
  161. package/dist/chunks/{filesystem-k42t1tha.js → instruction-discovery-k42t1tha.js} +2 -2
  162. package/dist/chunks/{filesystem-kg1345f7.js → instruction-discovery-kg1345f7.js} +1 -1
  163. package/dist/chunks/{filesystem-68m4zcq7.js → instruction-discovery-khm2pr1s.js} +5 -5
  164. package/dist/chunks/{filesystem-vrm94xha.js → instruction-discovery-knj89sme.js} +10 -10
  165. package/dist/chunks/{filesystem-kp1t5rcy.js → instruction-discovery-kp1t5rcy.js} +1 -1
  166. package/dist/chunks/{filesystem-vaz557xy.js → instruction-discovery-menq60x2.js} +1 -1
  167. package/dist/chunks/{filesystem-mf0hyk7z.js → instruction-discovery-mf0hyk7z.js} +1 -1
  168. package/dist/chunks/{filesystem-mh28new4.js → instruction-discovery-mh28new4.js} +2 -2
  169. package/dist/chunks/{filesystem-mnb85w6b.js → instruction-discovery-mnb85w6b.js} +2 -2
  170. package/dist/chunks/{filesystem-fm1t55er.js → instruction-discovery-mqcsrd9y.js} +13 -13
  171. package/dist/chunks/{filesystem-mxvw03gv.js → instruction-discovery-mxvw03gv.js} +1 -1
  172. package/dist/chunks/{filesystem-nesb2rcz.js → instruction-discovery-nesb2rcz.js} +2 -2
  173. package/dist/chunks/{filesystem-a7wfdbn6.js → instruction-discovery-ng4dz4tp.js} +3 -3
  174. package/dist/chunks/{filesystem-zk6gh5nt.js → instruction-discovery-nmyh0sp9.js} +3 -3
  175. package/dist/chunks/{filesystem-a7xntndb.js → instruction-discovery-nn8fveh1.js} +3 -3
  176. package/dist/chunks/{filesystem-nr76rjj3.js → instruction-discovery-nr76rjj3.js} +2 -2
  177. package/dist/chunks/{filesystem-nrkas8zm.js → instruction-discovery-nrkas8zm.js} +3 -3
  178. package/dist/chunks/{filesystem-a4mmf5cj.js → instruction-discovery-nx9svs6q.js} +33 -33
  179. package/dist/chunks/{filesystem-nzrjycs5.js → instruction-discovery-nzrjycs5.js} +1 -1
  180. package/dist/chunks/{filesystem-eymnbh3g.js → instruction-discovery-p0rbxa3x.js} +8 -8
  181. package/dist/chunks/{filesystem-7everc1f.js → instruction-discovery-p54vphfw.js} +2 -2
  182. package/dist/chunks/{filesystem-9swkr4aq.js → instruction-discovery-pe5ea99a.js} +5 -5
  183. package/dist/chunks/{filesystem-pfqehjmy.js → instruction-discovery-pfqehjmy.js} +2 -2
  184. package/dist/chunks/{filesystem-gvzjn3pd.js → instruction-discovery-pmfxj5fq.js} +6 -6
  185. package/dist/chunks/{filesystem-pq4b4pqk.js → instruction-discovery-pq4b4pqk.js} +2 -2
  186. package/dist/chunks/{filesystem-q07sa4nq.js → instruction-discovery-q07sa4nq.js} +4 -4
  187. package/dist/chunks/{filesystem-0rrmrhe3.js → instruction-discovery-q1xqrv08.js} +28 -28
  188. package/dist/chunks/{filesystem-qe0d689s.js → instruction-discovery-qe0d689s.js} +2 -2
  189. package/dist/chunks/{filesystem-aqmxtdc6.js → instruction-discovery-qepxz698.js} +8 -8
  190. package/dist/chunks/{filesystem-qhdqjp31.js → instruction-discovery-qhdqjp31.js} +1 -1
  191. package/dist/chunks/{filesystem-g85chdxb.js → instruction-discovery-qk227bps.js} +7 -7
  192. package/dist/chunks/{filesystem-p22m5a55.js → instruction-discovery-qpveny88.js} +8 -8
  193. package/dist/chunks/{filesystem-jasr3xfd.js → instruction-discovery-qs8q5xnx.js} +3 -3
  194. package/dist/chunks/{filesystem-d1qpcv06.js → instruction-discovery-qzkr2xpn.js} +36 -36
  195. package/dist/chunks/{filesystem-r3k9abhd.js → instruction-discovery-r3k9abhd.js} +2 -2
  196. package/dist/chunks/{filesystem-rahat93a.js → instruction-discovery-rahat93a.js} +1 -1
  197. package/dist/chunks/{filesystem-rfbm65k8.js → instruction-discovery-rfbm65k8.js} +1 -1
  198. package/dist/chunks/{filesystem-rk5217t6.js → instruction-discovery-rk5217t6.js} +4 -4
  199. package/dist/chunks/{filesystem-rn9r0ddn.js → instruction-discovery-rn9r0ddn.js} +2 -2
  200. package/dist/chunks/{filesystem-g4801p16.js → instruction-discovery-rp8m76y5.js} +11 -11
  201. package/dist/chunks/{filesystem-s33fw6zm.js → instruction-discovery-s33fw6zm.js} +1 -1
  202. package/dist/chunks/{filesystem-s4hn1693.js → instruction-discovery-s4hn1693.js} +2 -2
  203. package/dist/chunks/{filesystem-bkkkvh6a.js → instruction-discovery-s4s2ta5m.js} +8 -8
  204. package/dist/chunks/{filesystem-rww747ss.js → instruction-discovery-s7edmsxz.js} +4 -4
  205. package/dist/chunks/{filesystem-wjw8kef8.js → instruction-discovery-s941sks5.js} +5 -5
  206. package/dist/chunks/{filesystem-ywwamknt.js → instruction-discovery-saxn4m1w.js} +3 -3
  207. package/dist/chunks/{filesystem-v939t017.js → instruction-discovery-sb71th78.js} +6 -6
  208. package/dist/chunks/{filesystem-3h24gwzr.js → instruction-discovery-shjxvpa0.js} +3 -3
  209. package/dist/chunks/{filesystem-smpeg8c9.js → instruction-discovery-smpeg8c9.js} +2 -2
  210. package/dist/chunks/{filesystem-71gzcw6k.js → instruction-discovery-ssmvdm31.js} +8 -8
  211. package/dist/chunks/{filesystem-sw84ckhj.js → instruction-discovery-sw84ckhj.js} +1 -1
  212. package/dist/chunks/{filesystem-t14kykx1.js → instruction-discovery-t14kykx1.js} +1 -1
  213. package/dist/chunks/{filesystem-z27remcz.js → instruction-discovery-t2sex2wn.js} +9 -9
  214. package/dist/chunks/{filesystem-9kwv6rrp.js → instruction-discovery-t829dndb.js} +8 -8
  215. package/dist/chunks/{filesystem-tb33ng7x.js → instruction-discovery-tb33ng7x.js} +2 -2
  216. package/dist/chunks/{filesystem-tcptxgyq.js → instruction-discovery-tcptxgyq.js} +1 -1
  217. package/dist/chunks/{filesystem-frpc6wke.js → instruction-discovery-tczxwgj9.js} +9 -9
  218. package/dist/chunks/{filesystem-thstd87d.js → instruction-discovery-thstd87d.js} +1 -1
  219. package/dist/chunks/{filesystem-tjjf1q77.js → instruction-discovery-tjjf1q77.js} +1 -1
  220. package/dist/chunks/{filesystem-y0m7kkjw.js → instruction-discovery-tqsqjt6h.js} +6 -6
  221. package/dist/chunks/{filesystem-jx8cke6t.js → instruction-discovery-v0zhjcqq.js} +2 -2
  222. package/dist/chunks/{filesystem-v2wshkax.js → instruction-discovery-v2wshkax.js} +1 -1
  223. package/dist/chunks/{filesystem-azadh3bg.js → instruction-discovery-v5htk24g.js} +65 -65
  224. package/dist/chunks/{filesystem-v80zsxnb.js → instruction-discovery-v80zsxnb.js} +1 -1
  225. package/dist/chunks/{filesystem-ywvm29z1.js → instruction-discovery-v90cbgm3.js} +5 -5
  226. package/dist/chunks/{filesystem-v972xay6.js → instruction-discovery-v972xay6.js} +1 -1
  227. package/dist/chunks/{filesystem-v9bfv94f.js → instruction-discovery-v9bfv94f.js} +1 -1
  228. package/dist/chunks/{filesystem-vcwr2vpf.js → instruction-discovery-vcwr2vpf.js} +1 -1
  229. package/dist/chunks/{filesystem-vqbmgfq1.js → instruction-discovery-vqbmgfq1.js} +3 -3
  230. package/dist/chunks/{filesystem-hpy3yygd.js → instruction-discovery-vtm94t60.js} +6 -6
  231. package/dist/chunks/{filesystem-4v3smx9z.js → instruction-discovery-vwqr8pvd.js} +10 -10
  232. package/dist/chunks/{filesystem-vz89hfgr.js → instruction-discovery-vz89hfgr.js} +1 -1
  233. package/dist/chunks/{filesystem-wbkt8qpj.js → instruction-discovery-wbkt8qpj.js} +1 -1
  234. package/dist/chunks/{filesystem-wd268jeg.js → instruction-discovery-wd268jeg.js} +1 -1
  235. package/dist/chunks/{filesystem-wmxdh12w.js → instruction-discovery-wmxdh12w.js} +1 -1
  236. package/dist/chunks/{filesystem-gv9vtevg.js → instruction-discovery-wn0cnvk3.js} +6 -6
  237. package/dist/chunks/{filesystem-wps8gh8n.js → instruction-discovery-wps8gh8n.js} +2 -2
  238. package/dist/chunks/{filesystem-tywrksre.js → instruction-discovery-x334pkgk.js} +14 -14
  239. package/dist/chunks/{filesystem-cke3skfe.js → instruction-discovery-x50faqe6.js} +5 -5
  240. package/dist/chunks/{filesystem-qn56gch6.js → instruction-discovery-x7gn8tvz.js} +84 -9
  241. package/dist/chunks/{filesystem-xczfw7dq.js → instruction-discovery-xczfw7dq.js} +1 -1
  242. package/dist/chunks/{filesystem-xgv25zxy.js → instruction-discovery-xgv25zxy.js} +1 -1
  243. package/dist/chunks/{filesystem-3gd5efv2.js → instruction-discovery-xk7kbcg9.js} +6 -6
  244. package/dist/chunks/{filesystem-xwftk1fd.js → instruction-discovery-xwftk1fd.js} +2 -2
  245. package/dist/chunks/{filesystem-amnr36va.js → instruction-discovery-xx1gqej7.js} +25 -25
  246. package/dist/chunks/{filesystem-a48qfnmh.js → instruction-discovery-xx7h72db.js} +8 -8
  247. package/dist/chunks/{filesystem-xxpvz42q.js → instruction-discovery-xxpvz42q.js} +3 -3
  248. package/dist/chunks/{filesystem-4nn0yfrr.js → instruction-discovery-xyfp9e3r.js} +8 -8
  249. package/dist/chunks/{filesystem-y0x38cee.js → instruction-discovery-y0x38cee.js} +1 -1
  250. package/dist/chunks/{filesystem-y198y2ra.js → instruction-discovery-y198y2ra.js} +1 -1
  251. package/dist/chunks/{filesystem-5qeh4brg.js → instruction-discovery-y1dv8sj1.js} +3 -3
  252. package/dist/chunks/{filesystem-y67x6rf6.js → instruction-discovery-y67x6rf6.js} +1 -1
  253. package/dist/chunks/{filesystem-y6kvs3g2.js → instruction-discovery-y830za61.js} +4 -4
  254. package/dist/chunks/{filesystem-y980s7ka.js → instruction-discovery-y980s7ka.js} +3 -3
  255. package/dist/chunks/{filesystem-ybhfpy64.js → instruction-discovery-ybhfpy64.js} +2 -2
  256. package/dist/chunks/{filesystem-yf0knd5z.js → instruction-discovery-yf0knd5z.js} +2 -2
  257. package/dist/chunks/{filesystem-xdrwfhdj.js → instruction-discovery-yg7392qs.js} +4 -4
  258. package/dist/chunks/{filesystem-a6rvbckr.js → instruction-discovery-yg9q6dkd.js} +9 -9
  259. package/dist/chunks/{filesystem-ygy0xbqa.js → instruction-discovery-ygy0xbqa.js} +3 -3
  260. package/dist/chunks/{filesystem-zbqqnp0n.js → instruction-discovery-zbqqnp0n.js} +1 -1
  261. package/dist/chunks/{filesystem-zdkg1k91.js → instruction-discovery-zdkg1k91.js} +1 -1
  262. package/dist/chunks/{filesystem-rzq0wnyp.js → instruction-discovery-zh9wjqwb.js} +5 -5
  263. package/dist/chunks/{filesystem-f11jbhcb.js → instruction-discovery-ztjk4rav.js} +6 -6
  264. package/dist/chunks/{filesystem-zxcy6vhn.js → instruction-discovery-zxcy6vhn.js} +1 -1
  265. package/dist/chunks/{filesystem-zxe9jjhn.js → instruction-discovery-zxe9jjhn.js} +2 -2
  266. package/dist/codemode/catalog.js +2 -2
  267. package/dist/codemode/instructions.js +4 -4
  268. package/dist/codemode/tool.js +3 -3
  269. package/dist/command.js +78 -102
  270. package/dist/config/markdown.js +2 -2
  271. package/dist/config/normalize.js +20 -20
  272. package/dist/config/plugin/agent.js +133 -133
  273. package/dist/config/plugin/command.js +117 -130
  274. package/dist/config/plugin/compaction.js +169 -169
  275. package/dist/config/plugin/entry-observer.js +113 -113
  276. package/dist/config/plugin/formatter.js +118 -118
  277. package/dist/config/plugin/image.js +129 -129
  278. package/dist/config/plugin/instruction.js +89 -89
  279. package/dist/config/plugin/location-watcher.js +116 -116
  280. package/dist/config/plugin/mcp.js +126 -126
  281. package/dist/config/plugin/policy.js +115 -115
  282. package/dist/config/plugin/provider.js +114 -114
  283. package/dist/config/plugin/reference.js +118 -118
  284. package/dist/config/plugin/shell.js +117 -117
  285. package/dist/config/plugin/skill-file.js +106 -106
  286. package/dist/config/plugin/skill.js +136 -136
  287. package/dist/config/plugin/snapshot.js +116 -116
  288. package/dist/config/plugin/source.js +113 -113
  289. package/dist/config/plugin/tool-output.js +118 -118
  290. package/dist/config/plugin/websearch.js +114 -114
  291. package/dist/config/variable.js +4 -4
  292. package/dist/config.js +112 -112
  293. package/dist/credential/sql.js +3 -3
  294. package/dist/credential.js +72 -72
  295. package/dist/database/database.js +69 -69
  296. package/dist/database/drizzle/effect-sqlite/driver.js +16 -16
  297. package/dist/database/drizzle/effect-sqlite/index.js +16 -16
  298. package/dist/database/drizzle/effect-sqlite/migrator.js +15 -15
  299. package/dist/database/drizzle/effect-sqlite/session.js +15 -15
  300. package/dist/database/drizzle/index.js +18 -18
  301. package/dist/database/drizzle/internal/drizzle-utils.js +2 -2
  302. package/dist/database/drizzle/sqlite-core/effect/count.js +2 -2
  303. package/dist/database/drizzle/sqlite-core/effect/db.js +10 -10
  304. package/dist/database/drizzle/sqlite-core/effect/delete.js +3 -3
  305. package/dist/database/drizzle/sqlite-core/effect/index.js +23 -23
  306. package/dist/database/drizzle/sqlite-core/effect/insert.js +3 -3
  307. package/dist/database/drizzle/sqlite-core/effect/query.js +2 -2
  308. package/dist/database/drizzle/sqlite-core/effect/raw.js +2 -2
  309. package/dist/database/drizzle/sqlite-core/effect/select.js +3 -3
  310. package/dist/database/drizzle/sqlite-core/effect/session.js +14 -14
  311. package/dist/database/drizzle/sqlite-core/effect/update.js +3 -3
  312. package/dist/database/drizzle/up-migrations/effect-sqlite.js +4 -4
  313. package/dist/database/drizzle/up-migrations/sqlite.js +2 -2
  314. package/dist/database/drizzle/up-migrations/utils.js +2 -2
  315. package/dist/database/drizzle.js +19 -19
  316. package/dist/database/migration/20260127222353_familiar_lady_ursula.js +2 -2
  317. package/dist/database/migration/20260211171708_add_project_commands.js +2 -2
  318. package/dist/database/migration/20260213144116_wakeful_the_professor.js +2 -2
  319. package/dist/database/migration/20260225215848_workspace.js +2 -2
  320. package/dist/database/migration/20260227213759_add_session_workspace_id.js +2 -2
  321. package/dist/database/migration/20260228203230_blue_harpoon.js +2 -2
  322. package/dist/database/migration/20260303231226_add_workspace_fields.js +2 -2
  323. package/dist/database/migration/20260309230000_move_org_to_state.js +2 -2
  324. package/dist/database/migration/20260312043431_session_message_cursor.js +2 -2
  325. package/dist/database/migration/20260323234822_events.js +2 -2
  326. package/dist/database/migration/20260410174513_workspace-name.js +2 -2
  327. package/dist/database/migration/20260413175956_chief_energizer.js +2 -2
  328. package/dist/database/migration/20260423070820_add_icon_url_override.js +2 -2
  329. package/dist/database/migration/20260427172553_slow_nightmare.js +2 -2
  330. package/dist/database/migration/20260428004200_add_session_path.js +2 -2
  331. package/dist/database/migration/20260501142318_next_venus.js +2 -2
  332. package/dist/database/migration/20260504145000_add_sync_owner.js +2 -2
  333. package/dist/database/migration/20260507164347_add_workspace_time.js +2 -2
  334. package/dist/database/migration/20260510033149_session_usage.js +2 -2
  335. package/dist/database/migration/20260511000411_data_migration_state.js +2 -2
  336. package/dist/database/migration/20260511173437_session-metadata.js +2 -2
  337. package/dist/database/migration/20260601010001_normalize_storage_paths.js +2 -2
  338. package/dist/database/migration/20260601202201_amazing_prowler.js +2 -2
  339. package/dist/database/migration/20260602002951_lowly_union_jack.js +2 -2
  340. package/dist/database/migration/20260602182828_add_project_directories.js +2 -2
  341. package/dist/database/migration/20260603001617_session_message_projection_indexes.js +2 -2
  342. package/dist/database/migration/20260603040000_session_message_projection_order.js +2 -2
  343. package/dist/database/migration/20260603141458_session_input_inbox.js +2 -2
  344. package/dist/database/migration/20260603160727_jittery_ezekiel_stane.js +2 -2
  345. package/dist/database/migration/20260604172448_event_sourced_session_input.js +2 -2
  346. package/dist/database/migration/20260605003541_add_session_context_snapshot.js +2 -2
  347. package/dist/database/migration/20260605042240_add_context_epoch_agent.js +2 -2
  348. package/dist/database/migration/20260611035744_credential.js +2 -2
  349. package/dist/database/migration/20260611192811_lush_chimera.js +2 -2
  350. package/dist/database/migration/20260612174303_project_dir_strategy.js +2 -2
  351. package/dist/database/migration/20260622142730_simplify_session_context_epoch.js +2 -2
  352. package/dist/database/migration/20260622170816_reset_v2_session_state.js +2 -2
  353. package/dist/database/migration/20260622202450_simplify_session_input.js +2 -2
  354. package/dist/database/migration/20260804233008_loose_psylocke.js +2 -2
  355. package/dist/database/migration/20260805200742_import_legacy_credentials.js +2 -2
  356. package/dist/database/migration/20260808023530_workspace_domain.js +2 -2
  357. package/dist/database/migration/20260811161259_execution_claim_attempts.js +2 -2
  358. package/dist/database/migration/20260812181746_session_inbox.js +2 -2
  359. package/dist/database/migration/20260812213948_worktree.js +2 -2
  360. package/dist/database/migration/20260819222447_session_viewed_state.js +2 -2
  361. package/dist/database/migration/20260823191254_nullable_workspace_binding.js +2 -2
  362. package/dist/database/migration.gen.js +48 -48
  363. package/dist/database/migration.js +50 -50
  364. package/dist/database/path.js +3 -3
  365. package/dist/database/schema.gen.js +2 -2
  366. package/dist/database/schema.sql.js +2 -2
  367. package/dist/database/sqlite.bun.js +2 -2
  368. package/dist/database/sqlite.js +2 -2
  369. package/dist/database/sqlite.node.js +2 -2
  370. package/dist/database/sqlite.workerd.js +2 -2
  371. package/dist/database/v1-migration.bun.js +83 -83
  372. package/dist/database/v1-migration.js +2 -2
  373. package/dist/database/v1-migration.noop.js +1 -1
  374. package/dist/effect/app-node-builder.js +330 -330
  375. package/dist/effect/app-node-platform.js +3 -3
  376. package/dist/effect/keyed-mutex.js +2 -2
  377. package/dist/effect/websocket-constructor.js +2 -2
  378. package/dist/environment/driver.js +1 -1
  379. package/dist/environment/environment.js +90 -90
  380. package/dist/environment/exec-defaults.js +3 -3
  381. package/dist/environment/files.js +2 -2
  382. package/dist/environment/index.js +92 -92
  383. package/dist/environment/local.js +3 -3
  384. package/dist/environment/memory.js +3 -3
  385. package/dist/environment/unavailable.js +1 -1
  386. package/dist/event/sql.js +2 -2
  387. package/dist/event-logger.js +72 -72
  388. package/dist/file-mutation.js +91 -91
  389. package/dist/file-retention.js +2 -2
  390. package/dist/file.js +2 -2
  391. package/dist/filesystem/fff.bun.js +2 -2
  392. package/dist/filesystem/fff.js +2 -2
  393. package/dist/filesystem/fff.node.js +2 -2
  394. package/dist/filesystem/fff.workerd.js +2 -2
  395. package/dist/filesystem/ignore.js +1 -1
  396. package/dist/filesystem/location-watcher-policy.js +3 -3
  397. package/dist/filesystem/location-watcher.js +305 -305
  398. package/dist/filesystem/protected.js +2 -2
  399. package/dist/filesystem/search.js +95 -95
  400. package/dist/filesystem/watcher-binding.js +2 -2
  401. package/dist/filesystem/watcher.js +4 -4
  402. package/dist/filesystem.js +95 -95
  403. package/dist/form.js +73 -73
  404. package/dist/formatter/builtins.js +3 -3
  405. package/dist/formatter.js +84 -84
  406. package/dist/generate.js +88 -88
  407. package/dist/git.js +5 -5
  408. package/dist/github-copilot/chat/convert-to-openai-compatible-chat-messages.js +2 -2
  409. package/dist/github-copilot/chat/get-response-metadata.js +2 -2
  410. package/dist/github-copilot/chat/map-openai-compatible-finish-reason.js +2 -2
  411. package/dist/github-copilot/chat/openai-compatible-chat-language-model.js +8 -8
  412. package/dist/github-copilot/chat/openai-compatible-chat-options.js +2 -2
  413. package/dist/github-copilot/chat/openai-compatible-prepare-tools.js +2 -2
  414. package/dist/github-copilot/copilot-provider.js +20 -20
  415. package/dist/github-copilot/models.js +4 -4
  416. package/dist/github-copilot/openai-compatible-error.js +2 -2
  417. package/dist/github-copilot/responses/convert-to-openai-responses-input.js +2 -2
  418. package/dist/github-copilot/responses/map-openai-responses-finish-reason.js +2 -2
  419. package/dist/github-copilot/responses/openai-error.js +2 -2
  420. package/dist/github-copilot/responses/openai-responses-language-model.js +11 -11
  421. package/dist/github-copilot/responses/openai-responses-prepare-tools.js +7 -7
  422. package/dist/github-copilot/responses/tool/code-interpreter.js +2 -2
  423. package/dist/github-copilot/responses/tool/file-search.js +2 -2
  424. package/dist/github-copilot/responses/tool/image-generation.js +2 -2
  425. package/dist/github-copilot/responses/tool/web-search-preview.js +2 -2
  426. package/dist/github-copilot/responses/tool/web-search.js +2 -2
  427. package/dist/id/id.js +2 -2
  428. package/dist/image/photon-wasm.bun.js +1 -1
  429. package/dist/image/photon-wasm.node.js +1 -1
  430. package/dist/image/photon-wasm.workerd.js +1 -1
  431. package/dist/image/photon.js +97 -97
  432. package/dist/image.js +97 -97
  433. package/dist/instruction-discovery.js +76 -76
  434. package/dist/instructions/builtins.js +85 -85
  435. package/dist/instructions/index.js +2 -2
  436. package/dist/integration/connection.js +2 -2
  437. package/dist/integration.js +79 -79
  438. package/dist/job.js +4 -4
  439. package/dist/kv/sql.js +3 -3
  440. package/dist/kv.js +72 -72
  441. package/dist/location-activity.js +84 -84
  442. package/dist/location-mutation.js +83 -83
  443. package/dist/location-service-map.js +83 -83
  444. package/dist/location-services.js +330 -330
  445. package/dist/location.js +82 -82
  446. package/dist/mcp/client.js +91 -91
  447. package/dist/mcp/index.js +99 -97
  448. package/dist/mcp/instructions.js +127 -127
  449. package/dist/mcp/oauth.js +2 -2
  450. package/dist/mcp/stdio.js +91 -91
  451. package/dist/mime.js +2 -2
  452. package/dist/model-resolver.js +85 -85
  453. package/dist/model.js +3 -3
  454. package/dist/models-dev.js +79 -79
  455. package/dist/oauth/page.js +2 -2
  456. package/dist/permission/saved.js +83 -83
  457. package/dist/permission/sql.js +6 -6
  458. package/dist/permission.js +103 -103
  459. package/dist/plugin/agent.js +104 -104
  460. package/dist/plugin/command.js +98 -83
  461. package/dist/plugin/hooks.js +3 -3
  462. package/dist/plugin/host.js +166 -166
  463. package/dist/plugin/internal.js +299 -299
  464. package/dist/plugin/mcp-codemode-exclusion.js +2 -2
  465. package/dist/plugin/models-dev.js +80 -80
  466. package/dist/plugin/plan.js +104 -104
  467. package/dist/plugin/promise.js +2 -2
  468. package/dist/plugin/provider/alibaba.js +3 -3
  469. package/dist/plugin/provider/amazon-bedrock.js +3 -3
  470. package/dist/plugin/provider/anthropic.js +3 -3
  471. package/dist/plugin/provider/azure.js +120 -120
  472. package/dist/plugin/provider/cerebras.js +3 -3
  473. package/dist/plugin/provider/cloudflare-ai-gateway.js +121 -121
  474. package/dist/plugin/provider/cloudflare-workers-ai.js +121 -121
  475. package/dist/plugin/provider/cohere.js +3 -3
  476. package/dist/plugin/provider/configured.js +118 -118
  477. package/dist/plugin/provider/deepinfra.js +3 -3
  478. package/dist/plugin/provider/dynamic.js +2 -2
  479. package/dist/plugin/provider/factory.js +2 -2
  480. package/dist/plugin/provider/gateway.js +3 -3
  481. package/dist/plugin/provider/github-copilot.js +86 -86
  482. package/dist/plugin/provider/gitlab.js +4 -4
  483. package/dist/plugin/provider/google-vertex.js +3 -3
  484. package/dist/plugin/provider/groq.js +3 -3
  485. package/dist/plugin/provider/kilo.js +3 -3
  486. package/dist/plugin/provider/llmgateway.js +81 -81
  487. package/dist/plugin/provider/lmstudio.js +113 -113
  488. package/dist/plugin/provider/mistral.js +3 -3
  489. package/dist/plugin/provider/nvidia.js +3 -3
  490. package/dist/plugin/provider/ollama.js +113 -113
  491. package/dist/plugin/provider/openai-compatible.js +2 -2
  492. package/dist/plugin/provider/openai.js +83 -83
  493. package/dist/plugin/provider/opencode.js +97 -97
  494. package/dist/plugin/provider/openrouter.js +4 -4
  495. package/dist/plugin/provider/perplexity.js +3 -3
  496. package/dist/plugin/provider/sap-ai-core.js +3 -3
  497. package/dist/plugin/provider/snowflake-cortex.js +3 -3
  498. package/dist/plugin/provider/togetherai.js +3 -3
  499. package/dist/plugin/provider/venice.js +3 -3
  500. package/dist/plugin/provider/vercel.js +3 -3
  501. package/dist/plugin/provider/vllm.js +113 -113
  502. package/dist/plugin/provider/xai.js +82 -82
  503. package/dist/plugin/provider/zenmux.js +3 -3
  504. package/dist/plugin/provider.js +159 -159
  505. package/dist/plugin/runtime.js +155 -155
  506. package/dist/plugin/sdk.js +73 -73
  507. package/dist/plugin/skill.js +134 -134
  508. package/dist/plugin/supervisor-service.js +2 -2
  509. package/dist/plugin/supervisor.js +304 -304
  510. package/dist/plugin/system-prompt.js +2 -2
  511. package/dist/plugin/variant.js +4 -4
  512. package/dist/plugin/warming.js +114 -114
  513. package/dist/plugin/websearch/exa.js +4 -4
  514. package/dist/plugin/websearch/firecrawl.js +5 -5
  515. package/dist/plugin/websearch/index.js +9 -9
  516. package/dist/plugin/websearch/mcp.js +3 -3
  517. package/dist/plugin/websearch/parallel.js +5 -5
  518. package/dist/plugin/websearch/tavily.js +3 -3
  519. package/dist/plugin.js +167 -167
  520. package/dist/project/schema.js +3 -3
  521. package/dist/project/sql.js +5 -5
  522. package/dist/project.js +81 -81
  523. package/dist/provider.js +2 -2
  524. package/dist/pty/protocol.js +1 -1
  525. package/dist/pty/pty.bun.js +1 -1
  526. package/dist/pty/pty.node.js +1 -1
  527. package/dist/pty/pty.workerd.js +1 -1
  528. package/dist/pty/schema.js +2 -2
  529. package/dist/pty/ticket.js +74 -74
  530. package/dist/pty.js +88 -88
  531. package/dist/reference/instructions.js +81 -81
  532. package/dist/reference.js +79 -79
  533. package/dist/repository-cache.js +7 -7
  534. package/dist/repository.js +2 -2
  535. package/dist/ripgrep/binary.js +3 -3
  536. package/dist/ripgrep.js +93 -93
  537. package/dist/schema.js +2 -2
  538. package/dist/session/compaction.js +141 -141
  539. package/dist/session/context.js +311 -311
  540. package/dist/session/environment.js +3 -3
  541. package/dist/session/error.js +4 -4
  542. package/dist/session/event.js +2 -2
  543. package/dist/session/execution/restart.js +119 -119
  544. package/dist/session/execution.js +119 -119
  545. package/dist/session/generate-node.js +312 -312
  546. package/dist/session/generate.js +2 -2
  547. package/dist/session/history.js +81 -81
  548. package/dist/session/inbox.js +81 -81
  549. package/dist/session/info.js +91 -91
  550. package/dist/session/instruction-entry.js +77 -77
  551. package/dist/session/instruction-state.js +10 -10
  552. package/dist/session/instructions.js +100 -100
  553. package/dist/session/message-updater.js +4 -4
  554. package/dist/session/message.js +2 -2
  555. package/dist/session/model-request.js +137 -137
  556. package/dist/session/model-transport.js +5 -5
  557. package/dist/session/projector.js +94 -94
  558. package/dist/session/prompt-cache-diagnostics.js +2 -2
  559. package/dist/session/revert.js +89 -89
  560. package/dist/session/run-coordinator.js +2 -2
  561. package/dist/session/runner/index.js +88 -88
  562. package/dist/session/runner/llm.js +317 -317
  563. package/dist/session/runner/max-steps.js +2 -2
  564. package/dist/session/runner/model.js +87 -87
  565. package/dist/session/runner/publish-llm-event.js +4 -4
  566. package/dist/session/runner/retry.js +76 -76
  567. package/dist/session/runner/to-llm-message.js +2 -2
  568. package/dist/session/schema.js +2 -2
  569. package/dist/session/sql.js +6 -6
  570. package/dist/session/stats.js +75 -75
  571. package/dist/session/store.js +99 -99
  572. package/dist/session/system-prompt.js +2 -2
  573. package/dist/session/title.js +139 -139
  574. package/dist/session/to-session-error.js +114 -114
  575. package/dist/session/transfer.js +157 -158
  576. package/dist/session/usage.js +2 -2
  577. package/dist/session.js +153 -154
  578. package/dist/shell/parse.js +5 -5
  579. package/dist/shell/parser-wasm.bun.js +1 -1
  580. package/dist/shell/parser-wasm.node.js +1 -1
  581. package/dist/shell/parser-wasm.workerd.js +1 -1
  582. package/dist/shell/scan.js +1 -1
  583. package/dist/shell/select.js +4 -4
  584. package/dist/shell.js +98 -98
  585. package/dist/skill/discovery.js +3 -3
  586. package/dist/skill/instructions.js +105 -105
  587. package/dist/skill.js +104 -104
  588. package/dist/snapshot.js +84 -84
  589. package/dist/state.js +2 -2
  590. package/dist/tool/html-markdown.js +2 -2
  591. package/dist/tool/http-body.js +2 -2
  592. package/dist/tool/mcp.js +126 -126
  593. package/dist/tool/plugin/edit.js +113 -113
  594. package/dist/tool/plugin/file-diff.js +2 -2
  595. package/dist/tool/plugin/glob.js +115 -115
  596. package/dist/tool/plugin/grep.js +115 -115
  597. package/dist/tool/plugin/patch.js +113 -113
  598. package/dist/tool/plugin/question.js +105 -105
  599. package/dist/tool/plugin/read.js +118 -118
  600. package/dist/tool/plugin/shell.js +185 -185
  601. package/dist/tool/plugin/skill.js +105 -105
  602. package/dist/tool/plugin/subagent.js +182 -182
  603. package/dist/tool/plugin/webfetch.js +106 -106
  604. package/dist/tool/plugin/websearch.js +108 -108
  605. package/dist/tool/plugin/write.js +113 -113
  606. package/dist/tool/read-filesystem.js +97 -97
  607. package/dist/tool/runtime.js +2 -2
  608. package/dist/tool-output.js +5 -5
  609. package/dist/tool.js +119 -119
  610. package/dist/types/command.d.ts +23 -65
  611. package/dist/types/config/plugin/command.d.ts +4 -1
  612. package/dist/types/config/plugin/mcp.d.ts +2 -2
  613. package/dist/types/config/plugin/shell.d.ts +1 -1
  614. package/dist/types/location-service-map.d.ts +2 -2
  615. package/dist/types/location-services.d.ts +1 -1
  616. package/dist/types/mcp/index.d.ts +37 -0
  617. package/dist/types/plugin/command.d.ts +3 -1
  618. package/dist/types/plugin/host.d.ts +3 -7
  619. package/dist/types/plugin/internal.d.ts +3 -3
  620. package/dist/types/plugin/supervisor.d.ts +1 -1
  621. package/dist/types/session.d.ts +2 -6
  622. package/dist/types/tool/plugin/shell.d.ts +1 -1
  623. package/dist/types/v1/config/migrate.d.ts +9 -9
  624. package/dist/util/array.js +1 -1
  625. package/dist/util/error.js +2 -2
  626. package/dist/util/identifier.js +1 -1
  627. package/dist/util/iife.js +2 -2
  628. package/dist/util/lazy.js +2 -2
  629. package/dist/util/process-lock-ffi.bun.js +1 -1
  630. package/dist/util/process-lock-ffi.node.js +1 -1
  631. package/dist/util/process-lock-ffi.workerd.js +1 -1
  632. package/dist/util/process-lock.js +1 -1
  633. package/dist/util/slug.js +2 -2
  634. package/dist/util/token.js +2 -2
  635. package/dist/util/which.js +2 -2
  636. package/dist/util/wildcard.js +2 -2
  637. package/dist/v1/config/agent.js +4 -4
  638. package/dist/v1/config/attachment.js +3 -3
  639. package/dist/v1/config/command.js +2 -2
  640. package/dist/v1/config/config.js +15 -15
  641. package/dist/v1/config/error.js +3 -3
  642. package/dist/v1/config/formatter.js +2 -2
  643. package/dist/v1/config/layout.js +2 -2
  644. package/dist/v1/config/lsp.js +2 -2
  645. package/dist/v1/config/mcp.js +3 -3
  646. package/dist/v1/config/migrate.js +19 -19
  647. package/dist/v1/config/permission.js +2 -2
  648. package/dist/v1/config/plugin.js +2 -2
  649. package/dist/v1/config/provider-options.js +2 -2
  650. package/dist/v1/config/provider.js +3 -3
  651. package/dist/v1/config/server.js +3 -3
  652. package/dist/v1/config/skills.js +2 -2
  653. package/dist/v1/permission.js +1 -1
  654. package/dist/vcs/git.js +3 -3
  655. package/dist/vcs/hg.js +3 -3
  656. package/dist/vcs/patch.js +2 -2
  657. package/dist/vcs.js +86 -86
  658. package/dist/websearch.js +77 -77
  659. package/dist/wellknown/plugin.js +77 -77
  660. package/dist/wellknown.js +76 -76
  661. package/dist/workspace/driver.js +2 -2
  662. package/dist/workspace/sql.js +2 -2
  663. package/dist/workspace.js +73 -73
  664. package/dist/worktree/directory.js +3 -3
  665. package/dist/worktree/git.js +7 -7
  666. package/dist/worktree/sql.js +6 -6
  667. package/dist/worktree.js +86 -86
  668. package/package.json +7 -7
  669. package/dist/chunks/filesystem-59g7r0ef.js +0 -210
  670. package/dist/chunks/filesystem-n8zpdqp0.js +0 -93
  671. /package/dist/chunks/{filesystem-0cgt0xh2.js → instruction-discovery-0cgt0xh2.js} +0 -0
  672. /package/dist/chunks/{filesystem-0f48qthw.js → instruction-discovery-0f48qthw.js} +0 -0
  673. /package/dist/chunks/{filesystem-0zz82cjq.js → instruction-discovery-0zz82cjq.js} +0 -0
  674. /package/dist/chunks/{filesystem-1fb7bmpf.js → instruction-discovery-1fb7bmpf.js} +0 -0
  675. /package/dist/chunks/{filesystem-1wcz8fvj.js → instruction-discovery-1wcz8fvj.js} +0 -0
  676. /package/dist/chunks/{filesystem-2qdx6zz3.js → instruction-discovery-2qdx6zz3.js} +0 -0
  677. /package/dist/chunks/{filesystem-39ktntah.js → instruction-discovery-39ktntah.js} +0 -0
  678. /package/dist/chunks/{filesystem-3g3rpp2x.js → instruction-discovery-3g3rpp2x.js} +0 -0
  679. /package/dist/chunks/{filesystem-3q6gbwmd.js → instruction-discovery-3q6gbwmd.js} +0 -0
  680. /package/dist/chunks/{filesystem-3w3ybtfd.js → instruction-discovery-3w3ybtfd.js} +0 -0
  681. /package/dist/chunks/{filesystem-47ty4mvs.js → instruction-discovery-47ty4mvs.js} +0 -0
  682. /package/dist/chunks/{filesystem-4b2tz2m9.js → instruction-discovery-4b2tz2m9.js} +0 -0
  683. /package/dist/chunks/{filesystem-4zg0gww9.js → instruction-discovery-4zg0gww9.js} +0 -0
  684. /package/dist/chunks/{filesystem-5a5ch9ts.js → instruction-discovery-5a5ch9ts.js} +0 -0
  685. /package/dist/chunks/{filesystem-5va1yh78.js → instruction-discovery-5va1yh78.js} +0 -0
  686. /package/dist/chunks/{filesystem-61ek4hj9.js → instruction-discovery-61ek4hj9.js} +0 -0
  687. /package/dist/chunks/{filesystem-69qrqpw0.js → instruction-discovery-69qrqpw0.js} +0 -0
  688. /package/dist/chunks/{filesystem-6yt963b8.js → instruction-discovery-6yt963b8.js} +0 -0
  689. /package/dist/chunks/{filesystem-6zqxzw0a.js → instruction-discovery-6zqxzw0a.js} +0 -0
  690. /package/dist/chunks/{filesystem-7n9qwqk4.js → instruction-discovery-7n9qwqk4.js} +0 -0
  691. /package/dist/chunks/{filesystem-8nn8kqcn.js → instruction-discovery-8nn8kqcn.js} +0 -0
  692. /package/dist/chunks/{filesystem-8rpfd2h6.js → instruction-discovery-8rpfd2h6.js} +0 -0
  693. /package/dist/chunks/{filesystem-8sj3ajy5.js → instruction-discovery-8sj3ajy5.js} +0 -0
  694. /package/dist/chunks/{filesystem-8w9tzfz1.js → instruction-discovery-8w9tzfz1.js} +0 -0
  695. /package/dist/chunks/{filesystem-906y0b6d.js → instruction-discovery-906y0b6d.js} +0 -0
  696. /package/dist/chunks/{filesystem-9dct5xhx.js → instruction-discovery-9dct5xhx.js} +0 -0
  697. /package/dist/chunks/{filesystem-9sdtsapf.js → instruction-discovery-9sdtsapf.js} +0 -0
  698. /package/dist/chunks/{filesystem-a02svayp.js → instruction-discovery-a02svayp.js} +0 -0
  699. /package/dist/chunks/{filesystem-a83yvq99.js → instruction-discovery-a83yvq99.js} +0 -0
  700. /package/dist/chunks/{filesystem-aqg9wnx6.js → instruction-discovery-aqg9wnx6.js} +0 -0
  701. /package/dist/chunks/{filesystem-ayevdmef.js → instruction-discovery-ayevdmef.js} +0 -0
  702. /package/dist/chunks/{filesystem-b02txbh8.js → instruction-discovery-b02txbh8.js} +0 -0
  703. /package/dist/chunks/{filesystem-bbqs2y60.js → instruction-discovery-bbqs2y60.js} +0 -0
  704. /package/dist/chunks/{filesystem-bjwj8hwv.js → instruction-discovery-bjwj8hwv.js} +0 -0
  705. /package/dist/chunks/{filesystem-brsh5f65.js → instruction-discovery-brsh5f65.js} +0 -0
  706. /package/dist/chunks/{filesystem-bxdhjb3y.js → instruction-discovery-bxdhjb3y.js} +0 -0
  707. /package/dist/chunks/{filesystem-c77ad0vh.js → instruction-discovery-c77ad0vh.js} +0 -0
  708. /package/dist/chunks/{filesystem-ck5pgha0.js → instruction-discovery-ck5pgha0.js} +0 -0
  709. /package/dist/chunks/{filesystem-cm67rqy2.js → instruction-discovery-cm67rqy2.js} +0 -0
  710. /package/dist/chunks/{filesystem-df3v2q6j.js → instruction-discovery-df3v2q6j.js} +0 -0
  711. /package/dist/chunks/{filesystem-dhcq6c44.js → instruction-discovery-dhcq6c44.js} +0 -0
  712. /package/dist/chunks/{filesystem-dht5baf0.js → instruction-discovery-dht5baf0.js} +0 -0
  713. /package/dist/chunks/{filesystem-dkmkay92.js → instruction-discovery-dkmkay92.js} +0 -0
  714. /package/dist/chunks/{filesystem-ehj9csmv.js → instruction-discovery-ehj9csmv.js} +0 -0
  715. /package/dist/chunks/{filesystem-em6xpscd.js → instruction-discovery-em6xpscd.js} +0 -0
  716. /package/dist/chunks/{filesystem-emmqknsm.js → instruction-discovery-emmqknsm.js} +0 -0
  717. /package/dist/chunks/{filesystem-ezs3tagn.js → instruction-discovery-ezs3tagn.js} +0 -0
  718. /package/dist/chunks/{filesystem-f14r7hfz.js → instruction-discovery-f14r7hfz.js} +0 -0
  719. /package/dist/chunks/{filesystem-f4cp4g4a.js → instruction-discovery-f4cp4g4a.js} +0 -0
  720. /package/dist/chunks/{filesystem-f84sxdqn.js → instruction-discovery-f84sxdqn.js} +0 -0
  721. /package/dist/chunks/{filesystem-faypg4r1.js → instruction-discovery-faypg4r1.js} +0 -0
  722. /package/dist/chunks/{filesystem-fgbfdq62.js → instruction-discovery-fgbfdq62.js} +0 -0
  723. /package/dist/chunks/{filesystem-gd5xeqc2.js → instruction-discovery-gd5xeqc2.js} +0 -0
  724. /package/dist/chunks/{filesystem-ghm4673n.js → instruction-discovery-ghm4673n.js} +0 -0
  725. /package/dist/chunks/{filesystem-ghwjy7my.js → instruction-discovery-ghwjy7my.js} +0 -0
  726. /package/dist/chunks/{filesystem-gy500k2r.js → instruction-discovery-gy500k2r.js} +0 -0
  727. /package/dist/chunks/{filesystem-hzeg9cfr.js → instruction-discovery-hzeg9cfr.js} +0 -0
  728. /package/dist/chunks/{filesystem-j07kk359.js → instruction-discovery-j07kk359.js} +0 -0
  729. /package/dist/chunks/{filesystem-jf35ek5b.js → instruction-discovery-jf35ek5b.js} +0 -0
  730. /package/dist/chunks/{filesystem-jve7t217.js → instruction-discovery-jve7t217.js} +0 -0
  731. /package/dist/chunks/{filesystem-k3e42drn.js → instruction-discovery-k3e42drn.js} +0 -0
  732. /package/dist/chunks/{filesystem-k8b45nas.js → instruction-discovery-k8b45nas.js} +0 -0
  733. /package/dist/chunks/{filesystem-kcacmy5c.js → instruction-discovery-kcacmy5c.js} +0 -0
  734. /package/dist/chunks/{filesystem-kpdbz7gn.js → instruction-discovery-kpdbz7gn.js} +0 -0
  735. /package/dist/chunks/{filesystem-kxy11nzk.js → instruction-discovery-kxy11nzk.js} +0 -0
  736. /package/dist/chunks/{filesystem-kyyqvx4s.js → instruction-discovery-kyyqvx4s.js} +0 -0
  737. /package/dist/chunks/{filesystem-m8cbvarh.js → instruction-discovery-m8cbvarh.js} +0 -0
  738. /package/dist/chunks/{filesystem-ma60vzgv.js → instruction-discovery-ma60vzgv.js} +0 -0
  739. /package/dist/chunks/{filesystem-n3m50c2t.js → instruction-discovery-n3m50c2t.js} +0 -0
  740. /package/dist/chunks/{filesystem-nkm1m8dz.js → instruction-discovery-nkm1m8dz.js} +0 -0
  741. /package/dist/chunks/{filesystem-nsc0c3zb.js → instruction-discovery-nsc0c3zb.js} +0 -0
  742. /package/dist/chunks/{filesystem-qaarhjrp.js → instruction-discovery-qaarhjrp.js} +0 -0
  743. /package/dist/chunks/{filesystem-qc167nrn.js → instruction-discovery-qc167nrn.js} +0 -0
  744. /package/dist/chunks/{filesystem-qp95y4jb.js → instruction-discovery-qp95y4jb.js} +0 -0
  745. /package/dist/chunks/{filesystem-r8f4w671.js → instruction-discovery-r8f4w671.js} +0 -0
  746. /package/dist/chunks/{filesystem-rdfev9jy.js → instruction-discovery-rdfev9jy.js} +0 -0
  747. /package/dist/chunks/{filesystem-rvfvac9x.js → instruction-discovery-rvfvac9x.js} +0 -0
  748. /package/dist/chunks/{filesystem-s7whb9gt.js → instruction-discovery-s7whb9gt.js} +0 -0
  749. /package/dist/chunks/{filesystem-se76j685.js → instruction-discovery-se76j685.js} +0 -0
  750. /package/dist/chunks/{filesystem-sem2g21k.js → instruction-discovery-sem2g21k.js} +0 -0
  751. /package/dist/chunks/{filesystem-tmb1f636.js → instruction-discovery-tmb1f636.js} +0 -0
  752. /package/dist/chunks/{filesystem-ttxf0gsy.js → instruction-discovery-ttxf0gsy.js} +0 -0
  753. /package/dist/chunks/{filesystem-tvmhrvfj.js → instruction-discovery-tvmhrvfj.js} +0 -0
  754. /package/dist/chunks/{filesystem-v2adqbbe.js → instruction-discovery-v2adqbbe.js} +0 -0
  755. /package/dist/chunks/{filesystem-vkvb1sb3.js → instruction-discovery-vkvb1sb3.js} +0 -0
  756. /package/dist/chunks/{filesystem-wj4sxzqa.js → instruction-discovery-wj4sxzqa.js} +0 -0
  757. /package/dist/chunks/{filesystem-wwntjmk1.js → instruction-discovery-wwntjmk1.js} +0 -0
  758. /package/dist/chunks/{filesystem-wyqjaaa5.js → instruction-discovery-wyqjaaa5.js} +0 -0
  759. /package/dist/chunks/{filesystem-x4q807cx.js → instruction-discovery-x4q807cx.js} +0 -0
  760. /package/dist/chunks/{filesystem-xt0068v8.js → instruction-discovery-xt0068v8.js} +0 -0
  761. /package/dist/chunks/{filesystem-yrqrg4vp.js → instruction-discovery-yrqrg4vp.js} +0 -0
  762. /package/dist/chunks/{filesystem-z47nswr2.js → instruction-discovery-z47nswr2.js} +0 -0
  763. /package/dist/chunks/{filesystem-zsf8rs93.js → instruction-discovery-zsf8rs93.js} +0 -0
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "$schema": "https://json.schemastore.org/package.json",
3
- "version": "0.0.0-dev-18110",
3
+ "version": "0.0.0-dev-18111",
4
4
  "name": "@opencode-ai/core",
5
5
  "type": "module",
6
6
  "license": "MIT",
@@ -91,7 +91,7 @@
91
91
  "@parcel/watcher-linux-x64-musl": "2.5.1",
92
92
  "@parcel/watcher-win32-arm64": "2.5.1",
93
93
  "@parcel/watcher-win32-x64": "2.5.1",
94
- "@opencode-ai/http-recorder": "0.0.0-dev-18110",
94
+ "@opencode-ai/http-recorder": "0.0.0-dev-18111",
95
95
  "drizzle-kit": "1.0.0-rc.5-ab785fc"
96
96
  },
97
97
  "dependencies": {
@@ -117,11 +117,11 @@
117
117
  "@modelcontextprotocol/sdk": "1.29.0",
118
118
  "@ff-labs/fff-bun": "0.10.5",
119
119
  "@ff-labs/fff-node": "0.10.5",
120
- "@opencode-ai/codemode": "0.0.0-dev-18110",
121
- "@opencode-ai/ai": "0.0.0-dev-18110",
122
- "@opencode-ai/schema": "0.0.0-dev-18110",
123
- "@opencode-ai/plugin": "0.0.0-dev-18110",
124
- "@opencode-ai/util": "0.0.0-dev-18110",
120
+ "@opencode-ai/codemode": "0.0.0-dev-18111",
121
+ "@opencode-ai/ai": "0.0.0-dev-18111",
122
+ "@opencode-ai/schema": "0.0.0-dev-18111",
123
+ "@opencode-ai/plugin": "0.0.0-dev-18111",
124
+ "@opencode-ai/util": "0.0.0-dev-18111",
125
125
  "@standard-schema/spec": "1.1.0",
126
126
  "@parcel/watcher": "2.5.1",
127
127
  "@silvia-odwyer/photon-node": "0.3.4",
@@ -1,210 +0,0 @@
1
- import {
2
- exports_mcp
3
- } from "./filesystem-hz9eszaw.js";
4
- import {
5
- exports_select
6
- } from "./filesystem-cke3skfe.js";
7
- import {
8
- exports_location
9
- } from "./filesystem-7everc1f.js";
10
- import {
11
- exports_bus
12
- } from "./filesystem-w1w0wehs.js";
13
- import {
14
- exports_state
15
- } from "./filesystem-qhdqjp31.js";
16
- import {
17
- __export
18
- } from "./filesystem-rvfvac9x.js";
19
-
20
- // src/command.ts
21
- var exports_command = {};
22
- __export(exports_command, {
23
- node: () => node,
24
- Service: () => Service,
25
- NotFoundError: () => NotFoundError,
26
- Info: () => Info,
27
- Event: () => Event,
28
- EvaluationError: () => EvaluationError,
29
- Command: () => exports_command
30
- });
31
- import { makeLocationNode } from "@opencode-ai/util/effect/app-node";
32
- import { Context, Effect, Layer, Schema } from "effect";
33
- import { Command } from "@opencode-ai/schema/command";
34
- import { AppProcess } from "@opencode-ai/util/process";
35
- import { ChildProcess } from "effect/unstable/process";
36
- import { Event } from "@opencode-ai/schema/command";
37
- var Info = Command.Info;
38
-
39
- class NotFoundError extends Schema.TaggedError()("Command.NotFoundError", {
40
- command: Schema.String,
41
- message: Schema.String
42
- }) {
43
- }
44
-
45
- class EvaluationError extends Schema.TaggedError()("Command.EvaluationError", {
46
- command: Schema.String,
47
- message: Schema.String
48
- }) {
49
- }
50
-
51
- class Service extends Context.Service()("@opencode/Command") {
52
- }
53
- var layer = () => Layer.effect(Service, Effect.gen(function* () {
54
- const mcp = yield* exports_mcp.Service;
55
- const bus = yield* exports_bus.Service;
56
- const processes = yield* AppProcess.Service;
57
- const location = yield* exports_location.Service;
58
- const shell = yield* exports_select.Service;
59
- const state = exports_state.create({
60
- name: "command",
61
- initial: () => ({ commands: new Map }),
62
- draft: (draft) => ({
63
- list: () => Array.from(draft.commands.values()),
64
- get: (name) => draft.commands.get(name),
65
- update: (name, update) => {
66
- const current = draft.commands.get(name) ?? { name, template: "" };
67
- if (!draft.commands.has(name))
68
- draft.commands.set(name, current);
69
- update(current);
70
- current.name = name;
71
- },
72
- remove: (name) => {
73
- draft.commands.delete(name);
74
- }
75
- }),
76
- finalize: () => bus.publish(Command.Event.Updated, {}).pipe(Effect.asVoid)
77
- });
78
- const staticCommand = (name) => state.get().commands.get(name);
79
- const mcpCommands = Effect.fnUntraced(function* () {
80
- return (yield* mcp.prompts()).map((prompt) => Info.make({
81
- name: mcpCommandName(prompt.server, prompt.name),
82
- template: "",
83
- description: prompt.description
84
- }));
85
- });
86
- return Service.of({
87
- reload: state.reload,
88
- transform: state.transform,
89
- get: Effect.fn("Command.get")(function* (name) {
90
- const command = staticCommand(name);
91
- if (command)
92
- return command;
93
- return (yield* mcpCommands()).find((command2) => command2.name === name);
94
- }),
95
- list: Effect.fn("Command.list")(function* () {
96
- const commands = Array.from(state.get().commands.values());
97
- const names = new Set(commands.map((command) => command.name));
98
- return [...commands, ...(yield* mcpCommands()).filter((command) => !names.has(command.name))];
99
- }),
100
- evaluate: Effect.fn("Command.evaluate")(function* (input) {
101
- const command = staticCommand(input.name);
102
- if (command)
103
- return yield* evaluateTemplate(input.name, command.template, input.arguments ?? "", {
104
- location,
105
- processes,
106
- shell
107
- });
108
- const prompt = (yield* mcp.prompts()).find((prompt2) => mcpCommandName(prompt2.server, prompt2.name) === input.name);
109
- if (!prompt)
110
- return yield* new NotFoundError({ command: input.name, message: `Command not found: ${input.name}` });
111
- const result = yield* mcp.prompt({
112
- server: prompt.server,
113
- name: prompt.name,
114
- args: Object.fromEntries((prompt.arguments ?? []).map((argument, index) => [
115
- argument.name,
116
- parseArguments(input.arguments ?? "")[index] ?? ""
117
- ]))
118
- }).pipe(Effect.catchTag("MCP.NotFoundError", () => Effect.fail(new EvaluationError({
119
- command: input.name,
120
- message: `MCP server could not be found while evaluating prompt: ${prompt.server}`
121
- }))));
122
- if (!result)
123
- return yield* new EvaluationError({
124
- command: input.name,
125
- message: `MCP prompt could not be evaluated: ${prompt.server}:${prompt.name}`
126
- });
127
- return {
128
- text: result.messages.map((message) => promptMessageText(message.content)).join(`
129
- `).trim()
130
- };
131
- })
132
- });
133
- }));
134
- function evaluateTemplate(command, template, input, services) {
135
- return Effect.gen(function* () {
136
- const expanded = evaluateArguments(template, input);
137
- return { text: yield* evaluateShell(command, expanded, services) };
138
- });
139
- }
140
- function evaluateArguments(template, input) {
141
- const args = parseArguments(input);
142
- const placeholders = template.match(placeholderRegex) ?? [];
143
- const last = Math.max(0, ...placeholders.map((item) => Number(item.slice(1))));
144
- const expanded = template.replaceAll(placeholderRegex, (_, index) => {
145
- const position = Number(index);
146
- const argIndex = position - 1;
147
- if (argIndex >= args.length)
148
- return "";
149
- if (position === last)
150
- return args.slice(argIndex).join(" ");
151
- return args[argIndex];
152
- });
153
- const withArguments = expanded.replaceAll("$ARGUMENTS", input);
154
- if (placeholders.length === 0 && !template.includes("$ARGUMENTS") && input.trim())
155
- return `${withArguments}
156
-
157
- ${input}`.trim();
158
- return withArguments.trim();
159
- }
160
- var evaluateShell = Effect.fnUntraced(function* (command, text, services) {
161
- const matches = Array.from(text.matchAll(shellRegex));
162
- if (matches.length === 0)
163
- return text;
164
- const shell = yield* services.shell.preferred();
165
- const outputs = yield* Effect.forEach(matches, (match) => {
166
- const source = match[1] ?? "";
167
- return services.processes.run(ChildProcess.make(shell, exports_select.args(shell, source), {
168
- cwd: services.location.directory,
169
- stdin: "ignore"
170
- }), {
171
- combineOutput: true
172
- }).pipe(Effect.map((result) => (result.output ?? Buffer.concat([result.stdout, result.stderr])).toString("utf8")), Effect.mapError((error) => new EvaluationError({
173
- command,
174
- message: `Shell interpolation failed for ${JSON.stringify(source)}: ${error.message}`
175
- })));
176
- }, { concurrency: 2 });
177
- const iterator = outputs[Symbol.iterator]();
178
- return text.replace(shellRegex, () => iterator.next().value ?? "");
179
- });
180
- function parseArguments(input) {
181
- return (input.match(argsRegex) ?? []).map((arg) => arg.replace(quoteTrimRegex, ""));
182
- }
183
- function promptMessageText(content) {
184
- if (typeof content === "string")
185
- return content;
186
- if (!content || typeof content !== "object")
187
- return "";
188
- if (!("type" in content) || content.type !== "text")
189
- return "";
190
- if (!("text" in content) || typeof content.text !== "string")
191
- return "";
192
- return content.text;
193
- }
194
- function mcpCommandName(server, prompt) {
195
- return `${sanitize(server)}:${sanitize(prompt)}`;
196
- }
197
- function sanitize(value) {
198
- return value.replace(/[^a-zA-Z0-9_-]/g, "_");
199
- }
200
- var argsRegex = /(?:\[Image\s+\d+\]|"[^"]*"|'[^']*'|[^\s"']+)/gi;
201
- var placeholderRegex = /\$(\d+)/g;
202
- var quoteTrimRegex = /^["']|["']$/g;
203
- var shellRegex = /!`([^`]+)`/g;
204
- var node = makeLocationNode({
205
- service: Service,
206
- layer: layer(),
207
- deps: [exports_mcp.node, exports_bus.node, AppProcess.node, exports_location.node, exports_select.node]
208
- });
209
-
210
- export { Info, NotFoundError, EvaluationError, Service, node, exports_command, Event };
@@ -1,93 +0,0 @@
1
- import {
2
- exports_markdown
3
- } from "./filesystem-7wcmqxrc.js";
4
- import {
5
- exports_config
6
- } from "./filesystem-0x74beht.js";
7
- import {
8
- __export
9
- } from "./filesystem-rvfvac9x.js";
10
-
11
- // src/config/plugin/command.ts
12
- var exports_command = {};
13
- __export(exports_command, {
14
- Plugin: () => Plugin,
15
- ConfigCommandPlugin: () => exports_command
16
- });
17
- import { define } from "@opencode-ai/plugin/effect/plugin";
18
- import { ConfigCommand } from "@opencode-ai/schema/config/command";
19
- import path from "path";
20
- import { Effect, Option, Schema, Stream } from "effect";
21
- import { FSUtil } from "@opencode-ai/util/fs-util";
22
- var decodeCommand = Schema.decodeUnknownOption(ConfigCommand.Info);
23
- var Plugin = define({
24
- id: "opencode.config.command",
25
- effect: Effect.fn(function* (ctx) {
26
- const config = yield* exports_config.Service;
27
- const fs = yield* FSUtil.Service;
28
- const loadEntry = Effect.fnUntraced(function* (entry) {
29
- if (entry.type === "document")
30
- return [{ commands: entry.info.commands }];
31
- if (entry.type !== "directory")
32
- return [];
33
- const commands = yield* loadDirectory(fs, entry.path);
34
- return [{ commands: Object.fromEntries(commands.map((command) => [command.name, command.info])) }];
35
- });
36
- const load = Effect.fn("ConfigCommandPlugin.load")(function* () {
37
- return yield* Effect.forEach(yield* config.entries(), loadEntry).pipe(Effect.map((documents) => documents.flat()));
38
- });
39
- const loaded = { documents: [] };
40
- const reload = load().pipe(Effect.tap((documents) => Effect.sync(() => loaded.documents = documents)), Effect.andThen(ctx.command.reload()));
41
- const sourceChanges = config.changes().pipe(Stream.filterEffect((update) => Effect.map(config.entries(), (entries) => isCommandSource(entries, update.path))));
42
- const configUpdates = ctx.event.subscribe().pipe(Stream.filter((event) => event.type === "config.updated"));
43
- yield* Stream.merge(sourceChanges, configUpdates).pipe(Stream.debounce("100 millis"), Stream.runForEach(() => reload), Effect.forkScoped({ startImmediately: true }));
44
- loaded.documents = yield* load();
45
- yield* ctx.command.transform((draft) => {
46
- for (const document of loaded.documents) {
47
- for (const [name, command] of Object.entries(document.commands ?? {})) {
48
- draft.update(name, (item) => {
49
- item.template = command.template;
50
- if (command.description !== undefined)
51
- item.description = command.description;
52
- if (command.agent !== undefined)
53
- item.agent = command.agent;
54
- if (command.model !== undefined)
55
- item.model = {
56
- id: command.model.model,
57
- providerID: command.model.providerID,
58
- ...command.model.variant === undefined ? {} : { variant: command.model.variant }
59
- };
60
- if (command.subtask !== undefined)
61
- item.subtask = command.subtask;
62
- });
63
- }
64
- }
65
- });
66
- })
67
- });
68
- var sourceDirectories = ["command", "commands"];
69
- function isCommandSource(entries, file) {
70
- return entries.some((entry) => entry.type === "directory" && sourceDirectories.some((name) => FSUtil.contains(path.join(entry.path, name), file)));
71
- }
72
- function loadDirectory(fs, directory) {
73
- return Effect.gen(function* () {
74
- const files = yield* fs.scan("{command,commands}/**/*.md", { cwd: directory, absolute: true, dot: true, symlink: true }).pipe(Effect.orElseSucceed(() => []));
75
- return yield* Effect.forEach(files.toSorted(), (filepath) => fs.readFileStringSafe(filepath).pipe(Effect.map((content) => content === undefined ? undefined : decode(directory, filepath, content)), Effect.orElseSucceed(() => {
76
- return;
77
- }))).pipe(Effect.map((commands) => commands.filter((command) => command !== undefined)));
78
- });
79
- }
80
- function decode(directory, filepath, content) {
81
- const markdown = exports_markdown.parseOption(content);
82
- if (!markdown)
83
- return;
84
- const info = Option.getOrUndefined(decodeCommand({ ...markdown.data, template: markdown.content.trim() }));
85
- if (!info)
86
- return;
87
- return {
88
- name: path.relative(directory, filepath).replaceAll("\\", "/").replace(/^(command|commands)\//, "").replace(/\.md$/, ""),
89
- info
90
- };
91
- }
92
-
93
- export { Plugin, exports_command };