@opencode/core 0.0.0-dev-19666 → 0.0.0-dev-19669

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 (785) hide show
  1. package/dist/account/sql.js +1 -1
  2. package/dist/agent.js +82 -82
  3. package/dist/aisdk-native.js +88 -88
  4. package/dist/aisdk.js +93 -93
  5. package/dist/app.js +9 -9
  6. package/dist/bus.js +72 -72
  7. package/dist/chunks/{credential-y31b318c.js → config-022zszfk.js} +4 -4
  8. package/dist/chunks/{credential-68mh88x5.js → config-05c3m733.js} +13 -13
  9. package/dist/chunks/{credential-e5646j3d.js → config-0agk43sa.js} +5 -5
  10. package/dist/chunks/{credential-yh4x4bcf.js → config-0aktgs08.js} +4 -4
  11. package/dist/chunks/{credential-0paq2nw3.js → config-0paq2nw3.js} +1 -1
  12. package/dist/chunks/{credential-0q0f95c6.js → config-0q0f95c6.js} +1 -1
  13. package/dist/chunks/{credential-s6nyx2af.js → config-0q9emmhb.js} +8 -8
  14. package/dist/chunks/{credential-tf6e7ykh.js → config-14m7ayrf.js} +17 -17
  15. package/dist/chunks/{credential-w5hdw20w.js → config-1bsncdvr.js} +11 -11
  16. package/dist/chunks/{credential-1dazxqgg.js → config-1dazxqgg.js} +2 -2
  17. package/dist/chunks/{credential-738narex.js → config-1e147r25.js} +4 -4
  18. package/dist/chunks/{credential-e1gfgpzq.js → config-1hvh8taj.js} +9 -9
  19. package/dist/chunks/config-1x11rq2a.js +18 -0
  20. package/dist/chunks/{credential-1ygqh575.js → config-1ygqh575.js} +2 -2
  21. package/dist/chunks/{credential-21r38tys.js → config-21r38tys.js} +1 -1
  22. package/dist/chunks/{credential-nb113zne.js → config-23zcgvwt.js} +12 -12
  23. package/dist/chunks/{credential-cx9swraq.js → config-25xmm7zn.js} +3 -3
  24. package/dist/chunks/{credential-2a5m3afh.js → config-2a5m3afh.js} +1 -1
  25. package/dist/chunks/{credential-1fv74gqc.js → config-2a7hagjp.js} +6 -6
  26. package/dist/chunks/{credential-4t549gag.js → config-2ddykbk5.js} +15 -15
  27. package/dist/chunks/{credential-7jdsj2a9.js → config-2f04pwep.js} +3 -3
  28. package/dist/chunks/{credential-fmt9gx9z.js → config-2jhp5w19.js} +5 -5
  29. package/dist/chunks/{credential-h6wsj49y.js → config-2ra6th8z.js} +23 -23
  30. package/dist/chunks/{credential-r2m716tb.js → config-2sejkfem.js} +9 -9
  31. package/dist/chunks/{credential-nca7p386.js → config-2y34zzjz.js} +4 -4
  32. package/dist/chunks/{credential-xf4jyg83.js → config-35h9s572.js} +28 -28
  33. package/dist/chunks/{credential-g4bkzb6c.js → config-36nc0mh0.js} +35 -35
  34. package/dist/chunks/{credential-3fc6dm20.js → config-3fc6dm20.js} +1 -1
  35. package/dist/chunks/{credential-3hepkmqq.js → config-3hepkmqq.js} +1 -1
  36. package/dist/chunks/{credential-kmfjf26x.js → config-3hjq4k9b.js} +43 -43
  37. package/dist/chunks/{credential-3smtnn6g.js → config-3smtnn6g.js} +1 -1
  38. package/dist/chunks/{credential-x8e4p6xd.js → config-3tcwt8xv.js} +18 -18
  39. package/dist/chunks/{credential-3tvqynh2.js → config-3tvqynh2.js} +1 -1
  40. package/dist/chunks/{credential-xs6ytfqx.js → config-3z6jr724.js} +93 -93
  41. package/dist/chunks/{credential-hebf1kxy.js → config-41ctmhx5.js} +21 -21
  42. package/dist/chunks/{credential-gccs2bwb.js → config-433n4zsv.js} +8 -8
  43. package/dist/chunks/{credential-rynznh0p.js → config-45pswbny.js} +1 -1
  44. package/dist/chunks/{credential-bhbz1g28.js → config-462gqw78.js} +5 -5
  45. package/dist/chunks/{credential-2wkyznp6.js → config-4f88ejm2.js} +10 -10
  46. package/dist/chunks/{credential-wy8b5sm2.js → config-4jc5c4h4.js} +1 -1
  47. package/dist/chunks/{credential-gmvdm7qq.js → config-4kdn5gsy.js} +33 -33
  48. package/dist/chunks/{credential-esn92z5j.js → config-4q2pb1pk.js} +12 -12
  49. package/dist/chunks/{credential-r36d19v4.js → config-4yb3spsd.js} +47 -47
  50. package/dist/chunks/{credential-acm2yer0.js → config-4z4hjfg8.js} +15 -15
  51. package/dist/chunks/{credential-3e16hxxp.js → config-518q18qe.js} +57 -57
  52. package/dist/chunks/{credential-spyq2p40.js → config-573twbq1.js} +10 -10
  53. package/dist/chunks/{credential-d9s573fh.js → config-57ez7d0k.js} +2 -2
  54. package/dist/chunks/{credential-13n5e6v7.js → config-580ke28x.js} +32 -32
  55. package/dist/chunks/{credential-5daktx2q.js → config-5daktx2q.js} +1 -1
  56. package/dist/chunks/{credential-9zjppy0x.js → config-5ef5jth6.js} +22 -22
  57. package/dist/chunks/{credential-kd1cpg0d.js → config-5kq55603.js} +20 -20
  58. package/dist/chunks/{credential-x3nvw3tt.js → config-5kyjgc7f.js} +9 -9
  59. package/dist/chunks/{credential-e3qxr5gk.js → config-5qd3pb7m.js} +2 -2
  60. package/dist/chunks/{credential-bgsk5sf6.js → config-5qzcfh3p.js} +29 -29
  61. package/dist/chunks/{credential-27ydpwgw.js → config-5s1182jw.js} +6 -6
  62. package/dist/chunks/{credential-5t3nmthw.js → config-5t3nmthw.js} +2 -2
  63. package/dist/chunks/{credential-x1md2fzm.js → config-62pgy11b.js} +12 -12
  64. package/dist/chunks/{credential-8eg2ksxv.js → config-643ds8g6.js} +28 -28
  65. package/dist/chunks/{credential-h774x8jn.js → config-64md96fj.js} +1 -1
  66. package/dist/chunks/{credential-669tq793.js → config-669tq793.js} +1 -1
  67. package/dist/chunks/{credential-dfgcgxez.js → config-68erpj5b.js} +16 -16
  68. package/dist/chunks/{credential-5gsz1cxq.js → config-6cc51h1n.js} +8 -8
  69. package/dist/chunks/{credential-kna91w2n.js → config-6dckxdxh.js} +11 -11
  70. package/dist/chunks/{credential-kbfsvxgx.js → config-6g88tbc4.js} +3 -3
  71. package/dist/chunks/{credential-2402vzrj.js → config-6h73sxmp.js} +5 -5
  72. package/dist/chunks/{credential-0jq9fyba.js → config-6hjx5zpb.js} +9 -9
  73. package/dist/chunks/{credential-tckg6srr.js → config-6jk8pndw.js} +33 -33
  74. package/dist/chunks/{credential-6msgmcgs.js → config-6msgmcgs.js} +1 -1
  75. package/dist/chunks/{credential-0xq9xhmj.js → config-6ny01ear.js} +20 -20
  76. package/dist/chunks/{credential-f9tp8y98.js → config-6p9taxy6.js} +11 -11
  77. package/dist/chunks/{credential-bex791m1.js → config-6pfh26f2.js} +19 -19
  78. package/dist/chunks/{credential-11bvvhnn.js → config-6z3nc3kn.js} +43 -43
  79. package/dist/chunks/{credential-pamnnq1w.js → config-75z9d89n.js} +9 -9
  80. package/dist/chunks/{credential-64p606dm.js → config-77cm6sad.js} +4 -4
  81. package/dist/chunks/{credential-7bmhse3q.js → config-7bmhse3q.js} +1 -1
  82. package/dist/chunks/{credential-pf91bz7r.js → config-7djp59xp.js} +19 -19
  83. package/dist/chunks/{credential-7dqw4kz8.js → config-7dqw4kz8.js} +1 -1
  84. package/dist/chunks/{credential-22yysgjd.js → config-7eyqb4zv.js} +3 -3
  85. package/dist/chunks/{credential-0nx44e6s.js → config-7fvqwmd1.js} +7 -7
  86. package/dist/chunks/{credential-508p55fx.js → config-7g0vxfav.js} +21 -21
  87. package/dist/chunks/{credential-kzdc4nak.js → config-7ggebw46.js} +23 -23
  88. package/dist/chunks/{credential-ea5hcw4s.js → config-7gvwkz6m.js} +5 -5
  89. package/dist/chunks/{credential-nx9y3xfj.js → config-7mb7swr5.js} +30 -30
  90. package/dist/chunks/{credential-n9kbh9vm.js → config-7p797550.js} +9 -9
  91. package/dist/chunks/{credential-5apets8e.js → config-7q7pbdx1.js} +8 -8
  92. package/dist/chunks/{credential-7z7az0f5.js → config-7z7az0f5.js} +1 -1
  93. package/dist/chunks/{credential-pkvyjtqm.js → config-83eqs40m.js} +24 -24
  94. package/dist/chunks/{credential-8d7r5vzw.js → config-8d7r5vzw.js} +1 -1
  95. package/dist/chunks/{credential-dj2t23y0.js → config-8p4f9s12.js} +2 -2
  96. package/dist/chunks/{credential-36q87gfm.js → config-92cf61v4.js} +32 -32
  97. package/dist/chunks/{credential-dn50tt4t.js → config-97z6t3tg.js} +23 -23
  98. package/dist/chunks/{credential-g7rb6ydv.js → config-9ajsxzhb.js} +41 -41
  99. package/dist/chunks/{credential-2d70jdp9.js → config-9fhefhqa.js} +36 -36
  100. package/dist/chunks/{credential-ze0v8k2q.js → config-9g708cjc.js} +14 -14
  101. package/dist/chunks/{credential-5yzzbxa7.js → config-9hn6k4tm.js} +8 -8
  102. package/dist/chunks/{credential-pq3mzx0q.js → config-9pyv24s2.js} +9 -9
  103. package/dist/chunks/{credential-83wkmbw3.js → config-9qts6h7q.js} +22 -22
  104. package/dist/chunks/{credential-ny7wh072.js → config-9sbp0fay.js} +27 -27
  105. package/dist/chunks/{credential-ww3m2m79.js → config-9ve2a8aw.js} +10 -10
  106. package/dist/chunks/{credential-05ygxhcx.js → config-9wjn16bc.js} +31 -31
  107. package/dist/chunks/{credential-nbj5kk3p.js → config-9yj167tz.js} +62 -62
  108. package/dist/chunks/{credential-5c4hm403.js → config-a1bz86dw.js} +3 -3
  109. package/dist/chunks/{credential-aaet6srn.js → config-aaet6srn.js} +2 -2
  110. package/dist/chunks/{credential-w4apwaf4.js → config-acxx0f6f.js} +7 -7
  111. package/dist/chunks/{credential-9e4nk0tq.js → config-afrna9dt.js} +17 -17
  112. package/dist/chunks/{credential-4fxtva6j.js → config-at1586db.js} +27 -27
  113. package/dist/chunks/{credential-t1dawjzh.js → config-at1kfnmk.js} +8 -8
  114. package/dist/chunks/{credential-sxtjcjkh.js → config-axz21er9.js} +17 -17
  115. package/dist/chunks/{credential-vcr66jmq.js → config-b3kwjq0f.js} +44 -44
  116. package/dist/chunks/{credential-b6gygkdw.js → config-b6gygkdw.js} +2 -2
  117. package/dist/chunks/{credential-e7tvk2tq.js → config-bebye3jc.js} +17 -17
  118. package/dist/chunks/{credential-dfe8djrf.js → config-bf0ztrs3.js} +4 -4
  119. package/dist/chunks/{credential-prx5v8cj.js → config-bq5bs9zh.js} +21 -21
  120. package/dist/chunks/{credential-xvj7j57r.js → config-c228mxvk.js} +11 -11
  121. package/dist/chunks/{credential-zwsreqmt.js → config-c3sp0kct.js} +13 -13
  122. package/dist/chunks/{credential-aww5fh3f.js → config-c6cyd0ya.js} +27 -27
  123. package/dist/chunks/{credential-8pr7wmf3.js → config-c9bzb77z.js} +4 -4
  124. package/dist/chunks/{credential-htz6nkmz.js → config-cbakr6h8.js} +9 -9
  125. package/dist/chunks/{credential-m0jqrx5p.js → config-cfpkc3c9.js} +2 -2
  126. package/dist/chunks/{credential-qz49fwgp.js → config-cpy6gm2a.js} +4 -4
  127. package/dist/chunks/{credential-f5mgxjb1.js → config-cq78gtc7.js} +44 -44
  128. package/dist/chunks/{credential-1kf20zpt.js → config-cqhx78hs.js} +22 -22
  129. package/dist/chunks/{credential-q6fm3z54.js → config-cytean4k.js} +9 -9
  130. package/dist/chunks/{credential-bd16h6cm.js → config-cz7a148r.js} +18 -18
  131. package/dist/chunks/{credential-4fggj5wy.js → config-d73de1xr.js} +177 -177
  132. package/dist/chunks/{credential-dc33ykcf.js → config-d935dh1a.js} +11 -11
  133. package/dist/chunks/{credential-9j72sgz6.js → config-dfz1gvsg.js} +13 -13
  134. package/dist/chunks/{credential-0bnjtszc.js → config-dnt2jfde.js} +11 -11
  135. package/dist/chunks/{credential-e6jvw2we.js → config-drvanad6.js} +301 -301
  136. package/dist/chunks/{credential-drwq78ky.js → config-drwq78ky.js} +1 -1
  137. package/dist/chunks/{credential-81dmkzj2.js → config-dyacsyaw.js} +28 -28
  138. package/dist/chunks/{credential-xgvhk45p.js → config-e11g34hw.js} +12 -12
  139. package/dist/chunks/{credential-4zp3m0y7.js → config-e4wacjjh.js} +26 -26
  140. package/dist/chunks/{credential-dznngq2q.js → config-e5vn354j.js} +3 -3
  141. package/dist/chunks/{credential-qhjfj27n.js → config-e5zqv42s.js} +48 -48
  142. package/dist/chunks/{credential-bnhg3r2a.js → config-e76gvstb.js} +16 -16
  143. package/dist/chunks/{credential-eaj1djv9.js → config-eaj1djv9.js} +1 -1
  144. package/dist/chunks/{credential-dr1t5hnz.js → config-ed0becjx.js} +11 -11
  145. package/dist/chunks/{credential-ef5x83kb.js → config-ef5x83kb.js} +1 -1
  146. package/dist/chunks/{credential-1bbkgx8g.js → config-eq1pz5kg.js} +3 -3
  147. package/dist/chunks/{credential-etq0c3wd.js → config-etq0c3wd.js} +1 -1
  148. package/dist/chunks/{credential-rpjgfq5s.js → config-eye44qas.js} +9 -9
  149. package/dist/chunks/{credential-r7e4w6sk.js → config-ezcdrrzq.js} +3 -3
  150. package/dist/chunks/{credential-1acjjqhc.js → config-f2n192rq.js} +4 -4
  151. package/dist/chunks/{credential-2qerxkme.js → config-f3ebq5cb.js} +18 -18
  152. package/dist/chunks/{credential-x2k6c1jf.js → config-f3f181tw.js} +13 -13
  153. package/dist/chunks/{credential-kk00bynn.js → config-f3ngv102.js} +21 -21
  154. package/dist/chunks/{credential-hdnk95c8.js → config-f828m53h.js} +2 -2
  155. package/dist/chunks/{credential-bgs9y14h.js → config-fepbnb8j.js} +5 -5
  156. package/dist/chunks/{credential-fxbjtjnd.js → config-fxbjtjnd.js} +1 -1
  157. package/dist/chunks/{credential-e6xxsv62.js → config-g7h0cpxk.js} +11 -11
  158. package/dist/chunks/config-gbadjzag.js +4 -0
  159. package/dist/chunks/{credential-gd4qta3r.js → config-gd4qta3r.js} +1 -1
  160. package/dist/chunks/{credential-8jc16yv6.js → config-grjd9chs.js} +13 -13
  161. package/dist/chunks/{credential-ddt2bs9e.js → config-gst7axd9.js} +4 -4
  162. package/dist/chunks/{credential-yyb7tjpc.js → config-gv6a8nnw.js} +2 -2
  163. package/dist/chunks/{credential-0e8sy9ry.js → config-gys2qmg6.js} +12 -12
  164. package/dist/chunks/{credential-h03wrkyp.js → config-h03wrkyp.js} +2 -2
  165. package/dist/chunks/{credential-2g36pw43.js → config-h5pvq839.js} +11 -11
  166. package/dist/chunks/{credential-83sndckj.js → config-h64w4zg1.js} +32 -32
  167. package/dist/chunks/{credential-h6vf3j39.js → config-h6vf3j39.js} +1 -1
  168. package/dist/chunks/{credential-5cfjqfg7.js → config-hdthj1pw.js} +11 -11
  169. package/dist/chunks/{credential-qfrqt7ba.js → config-hgq0066q.js} +41 -41
  170. package/dist/chunks/{credential-gj8zg189.js → config-hq4e2gtc.js} +8 -8
  171. package/dist/chunks/{credential-nbehtjny.js → config-hsp0jww6.js} +39 -39
  172. package/dist/chunks/{credential-6fr6g2j9.js → config-hwwdvv3e.js} +26 -26
  173. package/dist/chunks/{credential-zn7zem8s.js → config-hz2kr7wq.js} +20 -20
  174. package/dist/chunks/{credential-yypw0vbp.js → config-hzaycprp.js} +12 -12
  175. package/dist/chunks/{credential-j56e64zr.js → config-j56e64zr.js} +1 -1
  176. package/dist/chunks/{credential-4ft7aw51.js → config-j7rm3apw.js} +4 -4
  177. package/dist/chunks/{credential-h32de20b.js → config-j8b2fvbr.js} +11 -11
  178. package/dist/chunks/{credential-0y85p7dm.js → config-jkeb6b4x.js} +6 -6
  179. package/dist/chunks/config-jmfp9j8q.js +247 -0
  180. package/dist/chunks/{credential-f34svx4d.js → config-jmss0gwv.js} +22 -22
  181. package/dist/chunks/{credential-1ahzwbrc.js → config-jw4a8xw7.js} +5 -5
  182. package/dist/chunks/{credential-3dz6av1h.js → config-k0426t5b.js} +30 -30
  183. package/dist/chunks/{credential-r19fnxbw.js → config-k231vryy.js} +5 -5
  184. package/dist/chunks/{credential-jppvw2tx.js → config-k3gnzxs0.js} +5 -5
  185. package/dist/chunks/{credential-v689wcn1.js → config-k5mz3qne.js} +35 -35
  186. package/dist/chunks/{credential-1w9mhehj.js → config-k5w8kmw2.js} +7 -7
  187. package/dist/chunks/{credential-tc1y06w0.js → config-k7cgkg0j.js} +5 -5
  188. package/dist/chunks/{credential-9h1fa16h.js → config-kcdh3xhs.js} +25 -25
  189. package/dist/chunks/{credential-gx61xvmr.js → config-kh83n6qb.js} +3 -3
  190. package/dist/chunks/{credential-fkjmw100.js → config-knb7evpn.js} +6 -6
  191. package/dist/chunks/{credential-byrjk9ja.js → config-kt93bk96.js} +9 -9
  192. package/dist/chunks/{credential-z7hh0hye.js → config-ktzck27w.js} +9 -9
  193. package/dist/chunks/{credential-whtyrcz8.js → config-m7507t3w.js} +9 -9
  194. package/dist/chunks/{credential-2e11fzmp.js → config-m9gksh9z.js} +14 -14
  195. package/dist/chunks/{credential-m9w0rfyh.js → config-m9w0rfyh.js} +1 -1
  196. package/dist/chunks/{credential-0t1hp5a3.js → config-mb18hxf9.js} +3 -3
  197. package/dist/chunks/{credential-kk8h1mek.js → config-ms93yq6r.js} +8 -8
  198. package/dist/chunks/{credential-6mxat6pr.js → config-msmw8652.js} +13 -13
  199. package/dist/chunks/{credential-ewh97b2b.js → config-msq47qdw.js} +37 -37
  200. package/dist/chunks/{credential-4x37hr07.js → config-mwc4n0sc.js} +33 -33
  201. package/dist/chunks/{credential-6gewjzag.js → config-naab3paw.js} +25 -25
  202. package/dist/chunks/{credential-m665a3h5.js → config-ndqvy1j6.js} +10 -10
  203. package/dist/chunks/{credential-v8p7hepz.js → config-ngz4ns8d.js} +4 -4
  204. package/dist/chunks/{credential-gvqa5h3n.js → config-nhag9533.js} +20 -20
  205. package/dist/chunks/{credential-wn0ga2b8.js → config-nq7qbqzc.js} +9 -9
  206. package/dist/chunks/{credential-4ygq0zje.js → config-nr24wn3c.js} +22 -22
  207. package/dist/chunks/{credential-r1y777cf.js → config-nvjaav7c.js} +22 -22
  208. package/dist/chunks/{credential-4dgbcxzg.js → config-nzyhnfxz.js} +4 -4
  209. package/dist/chunks/{credential-d1mtykxg.js → config-p7a39gy5.js} +6 -6
  210. package/dist/chunks/{credential-nh00fgee.js → config-pcz6j2yq.js} +11 -11
  211. package/dist/chunks/{credential-5h89xv10.js → config-ph57x98w.js} +3 -3
  212. package/dist/chunks/{credential-pjvnvgmy.js → config-pjvnvgmy.js} +1 -1
  213. package/dist/chunks/{credential-pknna89w.js → config-pknna89w.js} +1 -1
  214. package/dist/chunks/{credential-bfe3gwjm.js → config-q4vxcq8z.js} +10 -10
  215. package/dist/chunks/{credential-jfqtm2ew.js → config-qa3qhgw8.js} +4 -4
  216. package/dist/chunks/{credential-z7h5tktn.js → config-qpce9gs2.js} +36 -36
  217. package/dist/chunks/{credential-j1zf7whd.js → config-qqzkbgts.js} +28 -28
  218. package/dist/chunks/{credential-qsdy395h.js → config-qsdy395h.js} +1 -1
  219. package/dist/chunks/{credential-57nrd0dc.js → config-r3e0j0q4.js} +4 -4
  220. package/dist/chunks/{credential-r9mregkx.js → config-r9mregkx.js} +2 -2
  221. package/dist/chunks/{credential-pab7612g.js → config-rbqrbcat.js} +25 -25
  222. package/dist/chunks/{credential-rdw6cm16.js → config-rdw6cm16.js} +1 -1
  223. package/dist/chunks/{credential-e90yva4k.js → config-rf27w06z.js} +19 -19
  224. package/dist/chunks/{credential-vkw6eg78.js → config-rhydpgac.js} +7 -7
  225. package/dist/chunks/{credential-2xj68b26.js → config-rq184jbh.js} +15 -15
  226. package/dist/chunks/{credential-9kb0rfcz.js → config-s0bwfe95.js} +15 -15
  227. package/dist/chunks/{credential-51jra4mh.js → config-s8610hey.js} +2 -2
  228. package/dist/chunks/{credential-ws1cv121.js → config-sax4e3n0.js} +49 -49
  229. package/dist/chunks/{credential-v24739yc.js → config-sjf3tctt.js} +12 -12
  230. package/dist/chunks/{credential-bpxxtvpb.js → config-sk1cx54q.js} +5 -5
  231. package/dist/chunks/{credential-bbde4wd0.js → config-sqbhyrg9.js} +12 -12
  232. package/dist/chunks/{credential-17dh7jyv.js → config-sr5r393q.js} +36 -36
  233. package/dist/chunks/{credential-m9m18251.js → config-svpps34m.js} +4 -4
  234. package/dist/chunks/{credential-dgve2xzp.js → config-sx9t6843.js} +23 -23
  235. package/dist/chunks/{credential-c86qhz4v.js → config-t3saz5jn.js} +27 -27
  236. package/dist/chunks/{credential-3cmcwjyg.js → config-t51dyfnn.js} +2 -2
  237. package/dist/chunks/{credential-x27zz9cf.js → config-t67qj5tr.js} +10 -10
  238. package/dist/chunks/{credential-tazgh4e4.js → config-tazgh4e4.js} +1 -1
  239. package/dist/chunks/{credential-tcezcvh9.js → config-tcezcvh9.js} +1 -1
  240. package/dist/chunks/{credential-tdstcens.js → config-tdstcens.js} +1 -1
  241. package/dist/chunks/{credential-3tbdz2xg.js → config-th32f3de.js} +11 -11
  242. package/dist/chunks/{credential-36cgn824.js → config-tn0aqsam.js} +5 -5
  243. package/dist/chunks/{credential-7eqb3hhp.js → config-trjvf7gb.js} +80 -80
  244. package/dist/chunks/{credential-xecgr4w2.js → config-trjyp1t4.js} +28 -28
  245. package/dist/chunks/{credential-tvtrv512.js → config-tvtrv512.js} +1 -1
  246. package/dist/chunks/{credential-p55ry8ca.js → config-v3vssvcb.js} +3 -3
  247. package/dist/chunks/{credential-9p1k4t37.js → config-v50j8aqv.js} +5 -5
  248. package/dist/chunks/{credential-6tsskk3m.js → config-v51c9181.js} +23 -23
  249. package/dist/chunks/{credential-dmsmn8n3.js → config-vbgyqf84.js} +26 -26
  250. package/dist/chunks/{credential-veqvce7d.js → config-veqvce7d.js} +1 -1
  251. package/dist/chunks/{credential-sr8e46fz.js → config-vj0cjykb.js} +21 -21
  252. package/dist/chunks/{credential-1t6ktrk6.js → config-vjmn77es.js} +4 -4
  253. package/dist/chunks/{credential-8mfdap3f.js → config-vkt5fbj2.js} +8 -8
  254. package/dist/chunks/{credential-b6cw5a0r.js → config-vqh7t5vg.js} +19 -19
  255. package/dist/chunks/{credential-p12fe6dj.js → config-vqtbthnm.js} +15 -15
  256. package/dist/chunks/{credential-vzcthcp8.js → config-vzcthcp8.js} +1 -1
  257. package/dist/chunks/{credential-64kphnzf.js → config-w1k39n5e.js} +4 -4
  258. package/dist/chunks/{credential-w3wsvvr9.js → config-w3wsvvr9.js} +1 -1
  259. package/dist/chunks/{credential-psbrwbtd.js → config-wbkyxrgf.js} +5 -5
  260. package/dist/chunks/{credential-wd87259q.js → config-wd87259q.js} +1 -1
  261. package/dist/chunks/{credential-rqp7cg88.js → config-wf6wyyhn.js} +32 -32
  262. package/dist/chunks/{credential-6v4n8nt1.js → config-wzv49nq8.js} +15 -15
  263. package/dist/chunks/{credential-mkw2wvv0.js → config-x0e6qwje.js} +7 -7
  264. package/dist/chunks/{credential-x1ezjp6w.js → config-x1ezjp6w.js} +1 -1
  265. package/dist/chunks/{credential-1qcbrk1r.js → config-x8cxx485.js} +12 -12
  266. package/dist/chunks/{credential-9s36ejp2.js → config-xjanr18p.js} +299 -299
  267. package/dist/chunks/{credential-qb62zmsn.js → config-xkdyfc71.js} +67 -67
  268. package/dist/chunks/{credential-y1kk5z1y.js → config-y16t6rzn.js} +5 -5
  269. package/dist/chunks/{credential-y1fvbwt7.js → config-y1fvbwt7.js} +1 -1
  270. package/dist/chunks/{credential-y71avatq.js → config-y71avatq.js} +1 -1
  271. package/dist/chunks/{credential-esaz05fm.js → config-ycwsxkae.js} +11 -11
  272. package/dist/chunks/{credential-fsh1gg8q.js → config-yqt7txvq.js} +17 -17
  273. package/dist/chunks/{credential-yrhqyw5v.js → config-yrhqyw5v.js} +1 -1
  274. package/dist/chunks/{credential-s4enseaf.js → config-yrznvahk.js} +2 -2
  275. package/dist/chunks/{credential-pz6wpjec.js → config-yz41ghh5.js} +11 -11
  276. package/dist/chunks/{credential-z0bkrqjs.js → config-z0bkrqjs.js} +1 -1
  277. package/dist/chunks/{credential-z2qvtray.js → config-z2qvtray.js} +1 -1
  278. package/dist/chunks/{credential-29x78va6.js → config-z63w68vq.js} +6 -6
  279. package/dist/chunks/{credential-5xwnfstc.js → config-z8ejak9q.js} +15 -15
  280. package/dist/chunks/{credential-1ae6kvz9.js → config-zbvzapc7.js} +20 -20
  281. package/dist/chunks/{credential-5dgyrznt.js → config-zdnme1nw.js} +16 -16
  282. package/dist/chunks/{credential-rq775frq.js → config-zeh9ct20.js} +2 -2
  283. package/dist/chunks/{credential-b6q09cwq.js → config-zg6vdfjp.js} +8 -8
  284. package/dist/chunks/{credential-zr2ceqn5.js → config-zr2ceqn5.js} +1 -1
  285. package/dist/chunks/{credential-vh8r7pqb.js → config-zwx2vm5j.js} +12 -12
  286. package/dist/chunks/{credential-zxq2ej10.js → config-zxq2ej10.js} +1 -1
  287. package/dist/codemode/catalog.js +1 -1
  288. package/dist/codemode/instructions.js +5 -5
  289. package/dist/codemode/tool.js +2 -2
  290. package/dist/command.js +80 -80
  291. package/dist/config/discovery.js +81 -81
  292. package/dist/config/markdown.js +1 -1
  293. package/dist/config/normalize.js +105 -105
  294. package/dist/config/plugin/agent.js +122 -122
  295. package/dist/config/plugin/command.js +210 -210
  296. package/dist/config/plugin/compaction.js +158 -158
  297. package/dist/config/plugin/compatibility.js +140 -140
  298. package/dist/config/plugin/entry-observer.js +1 -1
  299. package/dist/config/plugin/formatter.js +123 -123
  300. package/dist/config/plugin/image.js +122 -122
  301. package/dist/config/plugin/instruction.js +89 -89
  302. package/dist/config/plugin/location-watcher.js +122 -122
  303. package/dist/config/plugin/mcp.js +129 -129
  304. package/dist/config/plugin/policy.js +122 -122
  305. package/dist/config/plugin/provider.js +120 -120
  306. package/dist/config/plugin/reference.js +124 -124
  307. package/dist/config/plugin/shell.js +122 -122
  308. package/dist/config/plugin/skill-file.js +101 -101
  309. package/dist/config/plugin/skill.js +141 -141
  310. package/dist/config/plugin/snapshot.js +122 -122
  311. package/dist/config/plugin/source.js +125 -125
  312. package/dist/config/plugin/tool-output.js +124 -124
  313. package/dist/config/plugin/websearch.js +121 -121
  314. package/dist/config/plugin/worktree.js +124 -124
  315. package/dist/config/variable.js +3 -3
  316. package/dist/config/watch.js +1 -1
  317. package/dist/config.js +125 -125
  318. package/dist/credential/sql.js +2 -2
  319. package/dist/credential.js +82 -82
  320. package/dist/database/database.js +65 -65
  321. package/dist/database/drizzle/effect-sqlite/driver.js +12 -12
  322. package/dist/database/drizzle/effect-sqlite/index.js +12 -12
  323. package/dist/database/drizzle/effect-sqlite/session.js +11 -11
  324. package/dist/database/drizzle/index.js +13 -13
  325. package/dist/database/drizzle/internal/drizzle-utils.js +1 -1
  326. package/dist/database/drizzle/sqlite-core/effect/count.js +1 -1
  327. package/dist/database/drizzle/sqlite-core/effect/db.js +9 -9
  328. package/dist/database/drizzle/sqlite-core/effect/delete.js +2 -2
  329. package/dist/database/drizzle/sqlite-core/effect/index.js +10 -10
  330. package/dist/database/drizzle/sqlite-core/effect/insert.js +2 -2
  331. package/dist/database/drizzle/sqlite-core/effect/query.js +1 -1
  332. package/dist/database/drizzle/sqlite-core/effect/raw.js +1 -1
  333. package/dist/database/drizzle/sqlite-core/effect/select.js +2 -2
  334. package/dist/database/drizzle/sqlite-core/effect/session.js +10 -10
  335. package/dist/database/drizzle/sqlite-core/effect/update.js +2 -2
  336. package/dist/database/drizzle.js +14 -14
  337. package/dist/database/migration/20260127222353_familiar_lady_ursula.js +1 -1
  338. package/dist/database/migration/20260211171708_add_project_commands.js +1 -1
  339. package/dist/database/migration/20260213144116_wakeful_the_professor.js +1 -1
  340. package/dist/database/migration/20260225215848_workspace.js +1 -1
  341. package/dist/database/migration/20260227213759_add_session_workspace_id.js +1 -1
  342. package/dist/database/migration/20260228203230_blue_harpoon.js +1 -1
  343. package/dist/database/migration/20260303231226_add_workspace_fields.js +1 -1
  344. package/dist/database/migration/20260309230000_move_org_to_state.js +1 -1
  345. package/dist/database/migration/20260312043431_session_message_cursor.js +1 -1
  346. package/dist/database/migration/20260323234822_events.js +1 -1
  347. package/dist/database/migration/20260410174513_workspace-name.js +1 -1
  348. package/dist/database/migration/20260413175956_chief_energizer.js +1 -1
  349. package/dist/database/migration/20260423070820_add_icon_url_override.js +1 -1
  350. package/dist/database/migration/20260427172553_slow_nightmare.js +1 -1
  351. package/dist/database/migration/20260428004200_add_session_path.js +1 -1
  352. package/dist/database/migration/20260501142318_next_venus.js +1 -1
  353. package/dist/database/migration/20260504145000_add_sync_owner.js +1 -1
  354. package/dist/database/migration/20260507164347_add_workspace_time.js +1 -1
  355. package/dist/database/migration/20260510033149_session_usage.js +1 -1
  356. package/dist/database/migration/20260511000411_data_migration_state.js +1 -1
  357. package/dist/database/migration/20260511173437_session-metadata.js +1 -1
  358. package/dist/database/migration/20260601010001_normalize_storage_paths.js +1 -1
  359. package/dist/database/migration/20260601202201_amazing_prowler.js +1 -1
  360. package/dist/database/migration/20260602002951_lowly_union_jack.js +1 -1
  361. package/dist/database/migration/20260602182828_add_project_directories.js +1 -1
  362. package/dist/database/migration/20260603001617_session_message_projection_indexes.js +1 -1
  363. package/dist/database/migration/20260603040000_session_message_projection_order.js +1 -1
  364. package/dist/database/migration/20260603141458_session_input_inbox.js +1 -1
  365. package/dist/database/migration/20260603160727_jittery_ezekiel_stane.js +1 -1
  366. package/dist/database/migration/20260604172448_event_sourced_session_input.js +1 -1
  367. package/dist/database/migration/20260605003541_add_session_context_snapshot.js +1 -1
  368. package/dist/database/migration/20260605042240_add_context_epoch_agent.js +1 -1
  369. package/dist/database/migration/20260611035744_credential.js +1 -1
  370. package/dist/database/migration/20260611192811_lush_chimera.js +1 -1
  371. package/dist/database/migration/20260612174303_project_dir_strategy.js +1 -1
  372. package/dist/database/migration/20260622142730_simplify_session_context_epoch.js +1 -1
  373. package/dist/database/migration/20260622170816_reset_v2_session_state.js +1 -1
  374. package/dist/database/migration/20260622202450_simplify_session_input.js +1 -1
  375. package/dist/database/migration/20260804233008_loose_psylocke.js +1 -1
  376. package/dist/database/migration/20260805200742_import_legacy_credentials.js +1 -1
  377. package/dist/database/migration/20260808023530_workspace_domain.js +1 -1
  378. package/dist/database/migration/20260811161259_execution_claim_attempts.js +1 -1
  379. package/dist/database/migration/20260812181746_session_inbox.js +1 -1
  380. package/dist/database/migration/20260812213948_worktree.js +1 -1
  381. package/dist/database/migration/20260819222447_session_viewed_state.js +1 -1
  382. package/dist/database/migration/20260823191254_nullable_workspace_binding.js +1 -1
  383. package/dist/database/migration/20260910120000_clear_v1_session_permission.js +1 -1
  384. package/dist/database/migration.gen.js +48 -48
  385. package/dist/database/migration.js +50 -50
  386. package/dist/database/path.js +2 -2
  387. package/dist/database/schema.gen.js +1 -1
  388. package/dist/database/schema.sql.js +1 -1
  389. package/dist/database/sqlite.bun.js +1 -1
  390. package/dist/database/sqlite.js +1 -1
  391. package/dist/database/sqlite.node.js +1 -1
  392. package/dist/database/sqlite.workerd.js +1 -1
  393. package/dist/database/v1-migration.bun.js +75 -75
  394. package/dist/database/v1-migration.js +1 -1
  395. package/dist/effect/app-node-builder.js +364 -364
  396. package/dist/effect/app-node-platform.js +2 -2
  397. package/dist/effect/keyed-mutex.js +1 -1
  398. package/dist/effect/websocket-constructor.js +1 -1
  399. package/dist/environment/driver.js +1 -1
  400. package/dist/environment/environment.js +90 -90
  401. package/dist/environment/exec-defaults.js +2 -2
  402. package/dist/environment/files.js +1 -1
  403. package/dist/environment/index.js +92 -92
  404. package/dist/environment/local.js +2 -2
  405. package/dist/environment/memory.js +2 -2
  406. package/dist/environment/unavailable.js +1 -1
  407. package/dist/event/sql.js +1 -1
  408. package/dist/event-logger.js +73 -73
  409. package/dist/file-access.js +103 -103
  410. package/dist/file-mutation.js +93 -93
  411. package/dist/file-retention.js +1 -1
  412. package/dist/file.js +1 -1
  413. package/dist/filesystem/fff.bun.js +2 -2
  414. package/dist/filesystem/fff.js +1 -1
  415. package/dist/filesystem/fff.node.js +2 -2
  416. package/dist/filesystem/fff.workerd.js +2 -2
  417. package/dist/filesystem/ignore.js +1 -1
  418. package/dist/filesystem/location-watcher-policy.js +6 -6
  419. package/dist/filesystem/location-watcher.js +223 -223
  420. package/dist/filesystem/protected.js +1 -1
  421. package/dist/filesystem/search.js +102 -102
  422. package/dist/filesystem/watcher-binding.js +3 -3
  423. package/dist/filesystem/watcher.js +13 -13
  424. package/dist/filesystem.js +105 -105
  425. package/dist/form.js +83 -83
  426. package/dist/formatter/builtins.js +4 -4
  427. package/dist/formatter.js +86 -86
  428. package/dist/generate.js +102 -102
  429. package/dist/git.js +10 -10
  430. package/dist/github-copilot/chat/convert-to-openai-compatible-chat-messages.js +1 -1
  431. package/dist/github-copilot/chat/get-response-metadata.js +1 -1
  432. package/dist/github-copilot/chat/map-openai-compatible-finish-reason.js +1 -1
  433. package/dist/github-copilot/chat/openai-compatible-chat-language-model.js +7 -7
  434. package/dist/github-copilot/chat/openai-compatible-chat-options.js +1 -1
  435. package/dist/github-copilot/chat/openai-compatible-prepare-tools.js +1 -1
  436. package/dist/github-copilot/copilot-provider.js +17 -17
  437. package/dist/github-copilot/models.js +90 -90
  438. package/dist/github-copilot/openai-compatible-error.js +1 -1
  439. package/dist/github-copilot/responses/convert-to-openai-responses-input.js +1 -1
  440. package/dist/github-copilot/responses/map-openai-responses-finish-reason.js +1 -1
  441. package/dist/github-copilot/responses/openai-error.js +1 -1
  442. package/dist/github-copilot/responses/openai-responses-language-model.js +10 -10
  443. package/dist/github-copilot/responses/openai-responses-prepare-tools.js +6 -6
  444. package/dist/github-copilot/responses/tool/code-interpreter.js +1 -1
  445. package/dist/github-copilot/responses/tool/file-search.js +1 -1
  446. package/dist/github-copilot/responses/tool/image-generation.js +1 -1
  447. package/dist/github-copilot/responses/tool/web-search-preview.js +1 -1
  448. package/dist/github-copilot/responses/tool/web-search.js +1 -1
  449. package/dist/id/id.js +1 -1
  450. package/dist/image/photon.js +2 -2
  451. package/dist/image.js +6 -6
  452. package/dist/instance/service.js +5 -5
  453. package/dist/instance.js +355 -355
  454. package/dist/instruction-discovery.js +84 -84
  455. package/dist/instructions/builtins.js +82 -82
  456. package/dist/instructions/index.js +1 -1
  457. package/dist/integration/connection.js +3 -3
  458. package/dist/integration.js +85 -85
  459. package/dist/job.js +78 -78
  460. package/dist/kv/sql.js +2 -2
  461. package/dist/kv.js +72 -72
  462. package/dist/location-activity.js +134 -134
  463. package/dist/location-mutation.js +103 -103
  464. package/dist/location-service-map.js +85 -85
  465. package/dist/location-services.js +352 -352
  466. package/dist/location.js +84 -84
  467. package/dist/mcp/client.js +90 -90
  468. package/dist/mcp/index.js +103 -103
  469. package/dist/mcp/instructions.js +124 -124
  470. package/dist/mcp/oauth.js +77 -77
  471. package/dist/mcp/stdio.js +89 -89
  472. package/dist/mime.js +1 -1
  473. package/dist/modal/models.js +90 -90
  474. package/dist/model-resolver.js +97 -97
  475. package/dist/model.js +101 -101
  476. package/dist/models-dev.js +100 -100
  477. package/dist/oauth/page.js +1 -1
  478. package/dist/permission/saved.js +79 -79
  479. package/dist/permission/sql.js +5 -5
  480. package/dist/permission.js +116 -116
  481. package/dist/persistent-pty/binary.bun.js +1 -1
  482. package/dist/persistent-pty/daemon.js +1 -1
  483. package/dist/persistent-pty/index.js +83 -83
  484. package/dist/persistent-pty/pty-binding.js +1 -1
  485. package/dist/persistent-pty.js +74 -74
  486. package/dist/plugin/agent.js +101 -101
  487. package/dist/plugin/command.js +98 -98
  488. package/dist/plugin/hooks.js +5 -5
  489. package/dist/plugin/host.js +216 -216
  490. package/dist/plugin/identity.js +3 -3
  491. package/dist/plugin/instance.js +5 -5
  492. package/dist/plugin/internal.js +327 -327
  493. package/dist/plugin/mcp-codemode-exclusion.js +1 -1
  494. package/dist/plugin/models-dev.js +95 -95
  495. package/dist/plugin/module.js +5 -5
  496. package/dist/plugin/optimize.js +4 -4
  497. package/dist/plugin/plan.js +101 -101
  498. package/dist/plugin/promise.js +1 -1
  499. package/dist/plugin/provider/amazon-bedrock.js +89 -89
  500. package/dist/plugin/provider/azure.js +121 -121
  501. package/dist/plugin/provider/cerebras.js +1 -1
  502. package/dist/plugin/provider/cloudflare-ai-gateway.js +120 -120
  503. package/dist/plugin/provider/cloudflare-workers-ai.js +120 -120
  504. package/dist/plugin/provider/cohere.js +2 -2
  505. package/dist/plugin/provider/configured.js +118 -118
  506. package/dist/plugin/provider/digitalocean.js +92 -92
  507. package/dist/plugin/provider/dynamic.js +2 -2
  508. package/dist/plugin/provider/factory.js +1 -1
  509. package/dist/plugin/provider/gateway.js +2 -2
  510. package/dist/plugin/provider/github-copilot.js +92 -92
  511. package/dist/plugin/provider/gitlab.js +90 -90
  512. package/dist/plugin/provider/google-vertex.js +89 -89
  513. package/dist/plugin/provider/kilo.js +1 -1
  514. package/dist/plugin/provider/llmgateway.js +76 -76
  515. package/dist/plugin/provider/lmstudio.js +121 -121
  516. package/dist/plugin/provider/modal.js +91 -91
  517. package/dist/plugin/provider/nvidia.js +1 -1
  518. package/dist/plugin/provider/ollama.js +121 -121
  519. package/dist/plugin/provider/openai.js +93 -93
  520. package/dist/plugin/provider/opencode.js +92 -92
  521. package/dist/plugin/provider/openrouter.js +90 -90
  522. package/dist/plugin/provider/perplexity.js +2 -2
  523. package/dist/plugin/provider/poe.js +77 -77
  524. package/dist/plugin/provider/prompt-cache-key.js +89 -89
  525. package/dist/plugin/provider/sap-ai-core.js +90 -90
  526. package/dist/plugin/provider/sdk-factory.js +1 -1
  527. package/dist/plugin/provider/snowflake-cortex.js +121 -121
  528. package/dist/plugin/provider/venice.js +2 -2
  529. package/dist/plugin/provider/vercel.js +89 -89
  530. package/dist/plugin/provider/vllm.js +121 -121
  531. package/dist/plugin/provider/xai.js +90 -90
  532. package/dist/plugin/provider/zenmux.js +1 -1
  533. package/dist/plugin/provider.js +158 -158
  534. package/dist/plugin/sdk.js +73 -73
  535. package/dist/plugin/service.js +3 -3
  536. package/dist/plugin/skill.js +138 -138
  537. package/dist/plugin/source-directory.js +1 -1
  538. package/dist/plugin/supervisor.js +342 -342
  539. package/dist/plugin/update.js +6 -6
  540. package/dist/plugin/vcs/git.js +85 -85
  541. package/dist/plugin/vcs/hg.js +85 -85
  542. package/dist/plugin/warming.js +120 -120
  543. package/dist/plugin/websearch/exa.js +7 -7
  544. package/dist/plugin/websearch/firecrawl.js +8 -8
  545. package/dist/plugin/websearch/index.js +9 -9
  546. package/dist/plugin/websearch/mcp.js +2 -2
  547. package/dist/plugin/websearch/parallel.js +8 -8
  548. package/dist/plugin/websearch/tavily.js +6 -6
  549. package/dist/plugin/websearch/tinyfish.js +8 -8
  550. package/dist/plugin.js +225 -225
  551. package/dist/project/schema.js +2 -2
  552. package/dist/project/sql.js +4 -4
  553. package/dist/project.js +83 -83
  554. package/dist/provider.js +100 -100
  555. package/dist/pty/protocol.js +1 -1
  556. package/dist/pty/schema.js +3 -3
  557. package/dist/pty/ticket.js +1 -1
  558. package/dist/pty.js +97 -97
  559. package/dist/reference/instructions.js +88 -88
  560. package/dist/reference.js +86 -86
  561. package/dist/repository-cache.js +80 -80
  562. package/dist/repository.js +3 -3
  563. package/dist/ripgrep/binary.js +2 -2
  564. package/dist/ripgrep.js +96 -96
  565. package/dist/rpc.js +85 -85
  566. package/dist/schema.js +1 -1
  567. package/dist/session/command.js +73 -73
  568. package/dist/session/compaction.js +130 -130
  569. package/dist/session/context.js +150 -150
  570. package/dist/session/diff.js +87 -87
  571. package/dist/session/environment.js +5 -5
  572. package/dist/session/error.js +7 -7
  573. package/dist/session/event.js +1 -1
  574. package/dist/session/execution/restart.js +222 -222
  575. package/dist/session/execution.js +127 -127
  576. package/dist/session/generate.js +151 -151
  577. package/dist/session/history.js +15 -15
  578. package/dist/session/inbox.js +85 -85
  579. package/dist/session/info.js +3 -3
  580. package/dist/session/instruction-entry.js +78 -78
  581. package/dist/session/instruction-state.js +8 -8
  582. package/dist/session/instructions.js +96 -96
  583. package/dist/session/message-updater.js +4 -4
  584. package/dist/session/message.js +1 -1
  585. package/dist/session/model-request.js +115 -115
  586. package/dist/session/model-transport.js +7 -7
  587. package/dist/session/move.js +129 -129
  588. package/dist/session/projector.js +85 -85
  589. package/dist/session/prompt.js +104 -104
  590. package/dist/session/provider-context.js +3 -3
  591. package/dist/session/revert.js +89 -89
  592. package/dist/session/run-coordinator.js +3 -3
  593. package/dist/session/runner/index.js +3 -3
  594. package/dist/session/runner/llm.js +228 -228
  595. package/dist/session/runner/max-steps.js +1 -1
  596. package/dist/session/runner/model.js +97 -97
  597. package/dist/session/runner/publish-llm-event.js +3 -3
  598. package/dist/session/runner/retry.js +111 -111
  599. package/dist/session/runner/step.js +124 -124
  600. package/dist/session/runner/to-llm-message.js +2 -2
  601. package/dist/session/schema.js +5 -5
  602. package/dist/session/session.js +171 -171
  603. package/dist/session/shell.js +137 -137
  604. package/dist/session/skill.js +102 -102
  605. package/dist/session/sql.js +5 -5
  606. package/dist/session/stats.js +72 -72
  607. package/dist/session/store.js +84 -84
  608. package/dist/session/subagent-completion.js +1 -1
  609. package/dist/session/subagent-job.js +206 -206
  610. package/dist/session/system-prompt.js +1 -1
  611. package/dist/session/title.js +154 -154
  612. package/dist/session/to-session-error.js +110 -110
  613. package/dist/session/transfer.js +218 -218
  614. package/dist/session/usage.js +1 -1
  615. package/dist/session.js +218 -218
  616. package/dist/shell/parse.js +6 -6
  617. package/dist/shell/result.js +1 -1
  618. package/dist/shell/scan.js +1 -1
  619. package/dist/shell/select.js +11 -11
  620. package/dist/shell.js +139 -139
  621. package/dist/skill/discovery.js +6 -6
  622. package/dist/skill/instructions.js +104 -104
  623. package/dist/skill.js +105 -105
  624. package/dist/snapshot.js +92 -92
  625. package/dist/state.js +1 -1
  626. package/dist/tool/html-markdown.js +1 -1
  627. package/dist/tool/http-body.js +1 -1
  628. package/dist/tool/mcp.js +121 -121
  629. package/dist/tool/plugin/edit.js +119 -119
  630. package/dist/tool/plugin/file-diff.js +1 -1
  631. package/dist/tool/plugin/glob.js +121 -121
  632. package/dist/tool/plugin/grep.js +123 -123
  633. package/dist/tool/plugin/opencode.js +3 -3
  634. package/dist/tool/plugin/patch.js +121 -121
  635. package/dist/tool/plugin/question.js +102 -102
  636. package/dist/tool/plugin/read.js +124 -124
  637. package/dist/tool/plugin/shell.js +213 -213
  638. package/dist/tool/plugin/skill.js +102 -102
  639. package/dist/tool/plugin/subagent.js +217 -217
  640. package/dist/tool/plugin/webfetch.js +109 -109
  641. package/dist/tool/plugin/websearch.js +111 -111
  642. package/dist/tool/plugin/write.js +121 -121
  643. package/dist/tool/read-filesystem.js +95 -95
  644. package/dist/tool/runtime.js +1 -1
  645. package/dist/tool-output.js +8 -8
  646. package/dist/tool.js +15 -15
  647. package/dist/util/error-summary.js +1 -1
  648. package/dist/util/error.js +1 -1
  649. package/dist/util/git-executable.js +2 -2
  650. package/dist/util/iife.js +1 -1
  651. package/dist/util/lazy.js +1 -1
  652. package/dist/util/slug.js +1 -1
  653. package/dist/util/token.js +1 -1
  654. package/dist/util/which.js +1 -1
  655. package/dist/util/wildcard.js +1 -1
  656. package/dist/v1/config/agent.js +7 -7
  657. package/dist/v1/config/attachment.js +4 -4
  658. package/dist/v1/config/command.js +3 -3
  659. package/dist/v1/config/config.js +16 -16
  660. package/dist/v1/config/error.js +4 -4
  661. package/dist/v1/config/formatter.js +3 -3
  662. package/dist/v1/config/layout.js +1 -1
  663. package/dist/v1/config/lsp.js +3 -3
  664. package/dist/v1/config/mcp.js +4 -4
  665. package/dist/v1/config/migrate.js +91 -91
  666. package/dist/v1/config/permission.js +7 -7
  667. package/dist/v1/config/plugin.js +1 -1
  668. package/dist/v1/config/provider-options.js +1 -1
  669. package/dist/v1/config/provider.js +4 -4
  670. package/dist/v1/config/server.js +2 -2
  671. package/dist/v1/config/skills.js +3 -3
  672. package/dist/v1/permission.js +1 -1
  673. package/dist/variant.js +90 -90
  674. package/dist/vcs/patch.js +1 -1
  675. package/dist/vcs.js +86 -86
  676. package/dist/websearch.js +83 -83
  677. package/dist/wellknown/plugin.js +75 -75
  678. package/dist/wellknown.js +78 -78
  679. package/dist/workspace/driver.js +1 -1
  680. package/dist/workspace/sql.js +1 -1
  681. package/dist/workspace.js +77 -77
  682. package/dist/worktree/directory.js +2 -2
  683. package/dist/worktree/git.js +10 -10
  684. package/dist/worktree/sql.js +5 -5
  685. package/dist/worktree/strategies.js +88 -88
  686. package/dist/worktree.js +97 -97
  687. package/package.json +8 -8
  688. package/dist/chunks/credential-0mesazry.js +0 -4
  689. package/dist/chunks/credential-by5v678g.js +0 -18
  690. package/dist/chunks/credential-qsh95xcw.js +0 -247
  691. /package/dist/chunks/{credential-0qkdqm5v.js → config-0qkdqm5v.js} +0 -0
  692. /package/dist/chunks/{credential-0zkw76rk.js → config-0zkw76rk.js} +0 -0
  693. /package/dist/chunks/{credential-17cy0kzp.js → config-17cy0kzp.js} +0 -0
  694. /package/dist/chunks/{credential-1cnp2v09.js → config-1cnp2v09.js} +0 -0
  695. /package/dist/chunks/{credential-1kg9ymc8.js → config-1kg9ymc8.js} +0 -0
  696. /package/dist/chunks/{credential-24dcb14g.js → config-24dcb14g.js} +0 -0
  697. /package/dist/chunks/{credential-2710q6r3.js → config-2710q6r3.js} +0 -0
  698. /package/dist/chunks/{credential-2axfhc9x.js → config-2axfhc9x.js} +0 -0
  699. /package/dist/chunks/{credential-2c3vjs8z.js → config-2c3vjs8z.js} +0 -0
  700. /package/dist/chunks/{credential-359p4xyc.js → config-359p4xyc.js} +0 -0
  701. /package/dist/chunks/{credential-3asan66x.js → config-3asan66x.js} +0 -0
  702. /package/dist/chunks/{credential-3v8g72cx.js → config-3v8g72cx.js} +0 -0
  703. /package/dist/chunks/{credential-3w5fmr99.js → config-3w5fmr99.js} +0 -0
  704. /package/dist/chunks/{credential-3wcehsnq.js → config-3wcehsnq.js} +0 -0
  705. /package/dist/chunks/{credential-43n2bw4t.js → config-43n2bw4t.js} +0 -0
  706. /package/dist/chunks/{credential-4knz6hnm.js → config-4knz6hnm.js} +0 -0
  707. /package/dist/chunks/{credential-4vcrnpx2.js → config-4vcrnpx2.js} +0 -0
  708. /package/dist/chunks/{credential-4y7fprxs.js → config-4y7fprxs.js} +0 -0
  709. /package/dist/chunks/{credential-53557ph1.js → config-53557ph1.js} +0 -0
  710. /package/dist/chunks/{credential-550bvhaj.js → config-550bvhaj.js} +0 -0
  711. /package/dist/chunks/{credential-6prwharc.js → config-6prwharc.js} +0 -0
  712. /package/dist/chunks/{credential-7akdwqpd.js → config-7akdwqpd.js} +0 -0
  713. /package/dist/chunks/{credential-7m9af43g.js → config-7m9af43g.js} +0 -0
  714. /package/dist/chunks/{credential-822emrt2.js → config-822emrt2.js} +0 -0
  715. /package/dist/chunks/{credential-88xbtdfr.js → config-88xbtdfr.js} +0 -0
  716. /package/dist/chunks/{credential-8n3pysct.js → config-8n3pysct.js} +0 -0
  717. /package/dist/chunks/{credential-922hggd3.js → config-922hggd3.js} +0 -0
  718. /package/dist/chunks/{credential-9a4afbnw.js → config-9a4afbnw.js} +0 -0
  719. /package/dist/chunks/{credential-9rqn6x4v.js → config-9rqn6x4v.js} +0 -0
  720. /package/dist/chunks/{credential-a6k6eb26.js → config-a6k6eb26.js} +0 -0
  721. /package/dist/chunks/{credential-af5trqkr.js → config-af5trqkr.js} +0 -0
  722. /package/dist/chunks/{credential-afrmfg78.js → config-afrmfg78.js} +0 -0
  723. /package/dist/chunks/{credential-aqzs7mqg.js → config-aqzs7mqg.js} +0 -0
  724. /package/dist/chunks/{credential-atq7p7m5.js → config-atq7p7m5.js} +0 -0
  725. /package/dist/chunks/{credential-bkyjaxrp.js → config-bkyjaxrp.js} +0 -0
  726. /package/dist/chunks/{credential-bmr6ed5q.js → config-bmr6ed5q.js} +0 -0
  727. /package/dist/chunks/{credential-cf4snx6d.js → config-cf4snx6d.js} +0 -0
  728. /package/dist/chunks/{credential-cvy3z8tj.js → config-cvy3z8tj.js} +0 -0
  729. /package/dist/chunks/{credential-d9fn303g.js → config-d9fn303g.js} +0 -0
  730. /package/dist/chunks/{credential-d9jj8t3e.js → config-d9jj8t3e.js} +0 -0
  731. /package/dist/chunks/{credential-dajrwvna.js → config-dajrwvna.js} +0 -0
  732. /package/dist/chunks/{credential-dap0rakb.js → config-dap0rakb.js} +0 -0
  733. /package/dist/chunks/{credential-df08tz66.js → config-df08tz66.js} +0 -0
  734. /package/dist/chunks/{credential-dy18nga0.js → config-dy18nga0.js} +0 -0
  735. /package/dist/chunks/{credential-e5kj55wp.js → config-e5kj55wp.js} +0 -0
  736. /package/dist/chunks/{credential-e73j6tqm.js → config-e73j6tqm.js} +0 -0
  737. /package/dist/chunks/{credential-ec1grn59.js → config-ec1grn59.js} +0 -0
  738. /package/dist/chunks/{credential-eh3zwz77.js → config-eh3zwz77.js} +0 -0
  739. /package/dist/chunks/{credential-emrn6kk6.js → config-emrn6kk6.js} +0 -0
  740. /package/dist/chunks/{credential-f0mxakyp.js → config-f0mxakyp.js} +0 -0
  741. /package/dist/chunks/{credential-f6n9ztr4.js → config-f6n9ztr4.js} +0 -0
  742. /package/dist/chunks/{credential-faypxj3z.js → config-faypxj3z.js} +0 -0
  743. /package/dist/chunks/{credential-fd410y7t.js → config-fd410y7t.js} +0 -0
  744. /package/dist/chunks/{credential-fxgpk5d8.js → config-fxgpk5d8.js} +0 -0
  745. /package/dist/chunks/{credential-g4wezp1m.js → config-g4wezp1m.js} +0 -0
  746. /package/dist/chunks/{credential-g86h250q.js → config-g86h250q.js} +0 -0
  747. /package/dist/chunks/{credential-gebd4c9n.js → config-gebd4c9n.js} +0 -0
  748. /package/dist/chunks/{credential-gftt206x.js → config-gftt206x.js} +0 -0
  749. /package/dist/chunks/{credential-hjbc5kem.js → config-hjbc5kem.js} +0 -0
  750. /package/dist/chunks/{credential-hk9envan.js → config-hk9envan.js} +0 -0
  751. /package/dist/chunks/{credential-j2ntwpah.js → config-j2ntwpah.js} +0 -0
  752. /package/dist/chunks/{credential-j5zkgpj8.js → config-j5zkgpj8.js} +0 -0
  753. /package/dist/chunks/{credential-jjkms2e6.js → config-jjkms2e6.js} +0 -0
  754. /package/dist/chunks/{credential-jr7sbwjy.js → config-jr7sbwjy.js} +0 -0
  755. /package/dist/chunks/{credential-jwfs4k6c.js → config-jwfs4k6c.js} +0 -0
  756. /package/dist/chunks/{credential-jzg6c2d5.js → config-jzg6c2d5.js} +0 -0
  757. /package/dist/chunks/{credential-mp448xyj.js → config-mp448xyj.js} +0 -0
  758. /package/dist/chunks/{credential-msx8hqn2.js → config-msx8hqn2.js} +0 -0
  759. /package/dist/chunks/{credential-n05xt0ee.js → config-n05xt0ee.js} +0 -0
  760. /package/dist/chunks/{credential-n3j8tn72.js → config-n3j8tn72.js} +0 -0
  761. /package/dist/chunks/{credential-njntx4h6.js → config-njntx4h6.js} +0 -0
  762. /package/dist/chunks/{credential-q3sfg36h.js → config-q3sfg36h.js} +0 -0
  763. /package/dist/chunks/{credential-q74kybfr.js → config-q74kybfr.js} +0 -0
  764. /package/dist/chunks/{credential-qaymkmh1.js → config-qaymkmh1.js} +0 -0
  765. /package/dist/chunks/{credential-qb87gjwd.js → config-qb87gjwd.js} +0 -0
  766. /package/dist/chunks/{credential-qfa1cgps.js → config-qfa1cgps.js} +0 -0
  767. /package/dist/chunks/{credential-qg3g05ea.js → config-qg3g05ea.js} +0 -0
  768. /package/dist/chunks/{credential-qrg20bc0.js → config-qrg20bc0.js} +0 -0
  769. /package/dist/chunks/{credential-rcb2kzg1.js → config-rcb2kzg1.js} +0 -0
  770. /package/dist/chunks/{credential-sdp7kfr6.js → config-sdp7kfr6.js} +0 -0
  771. /package/dist/chunks/{credential-sk3qaz4a.js → config-sk3qaz4a.js} +0 -0
  772. /package/dist/chunks/{credential-ssg3fenm.js → config-ssg3fenm.js} +0 -0
  773. /package/dist/chunks/{credential-twg0f83k.js → config-twg0f83k.js} +0 -0
  774. /package/dist/chunks/{credential-w803qqfp.js → config-w803qqfp.js} +0 -0
  775. /package/dist/chunks/{credential-wc3fc9cn.js → config-wc3fc9cn.js} +0 -0
  776. /package/dist/chunks/{credential-wer8tq1h.js → config-wer8tq1h.js} +0 -0
  777. /package/dist/chunks/{credential-wtztk69x.js → config-wtztk69x.js} +0 -0
  778. /package/dist/chunks/{credential-x0ckcb58.js → config-x0ckcb58.js} +0 -0
  779. /package/dist/chunks/{credential-x61499pn.js → config-x61499pn.js} +0 -0
  780. /package/dist/chunks/{credential-y44na4kk.js → config-y44na4kk.js} +0 -0
  781. /package/dist/chunks/{credential-y8cydn3q.js → config-y8cydn3q.js} +0 -0
  782. /package/dist/chunks/{credential-y8f7s663.js → config-y8f7s663.js} +0 -0
  783. /package/dist/chunks/{credential-ygaqb7jw.js → config-ygaqb7jw.js} +0 -0
  784. /package/dist/chunks/{credential-ym463w8f.js → config-ym463w8f.js} +0 -0
  785. /package/dist/chunks/{credential-z9919s4g.js → config-z9919s4g.js} +0 -0
@@ -1,39 +1,48 @@
1
1
  import {
2
- Service81,
3
- node85
4
- } from "./credential-yypw0vbp.js";
2
+ Service80,
3
+ node84
4
+ } from "./config-hzaycprp.js";
5
5
  import {
6
6
  shutdown2,
7
7
  create3
8
- } from "./credential-rdw6cm16.js";
8
+ } from "./config-rdw6cm16.js";
9
9
  import {
10
- ID14,
11
- Service72,
12
- node76,
13
- Event17
14
- } from "./credential-xecgr4w2.js";
10
+ ID9,
11
+ Service66,
12
+ node69,
13
+ Event15
14
+ } from "./config-trjyp1t4.js";
15
15
  import {
16
16
  key2
17
- } from "./credential-4dgbcxzg.js";
17
+ } from "./config-nzyhnfxz.js";
18
18
  import {
19
- Service78,
20
- node82
21
- } from "./credential-ze0v8k2q.js";
19
+ Service77,
20
+ node81
21
+ } from "./config-9g708cjc.js";
22
22
  import {
23
23
  __export
24
- } from "./credential-9rqn6x4v.js";
24
+ } from "./config-9rqn6x4v.js";
25
+
26
+ // src/aisdk-native.ts
27
+ var exports_aisdk_native = {};
28
+ __export(exports_aisdk_native, {
29
+ AISDKNative: () => exports_aisdk_native,
30
+ native: () => native2,
31
+ rewrite: () => rewrite2
32
+ });
33
+ import { Effect as Effect2, Option, Schema as Schema2, Struct as Struct2 } from "effect";
25
34
 
26
35
  // src/provider.ts
27
36
  var exports_provider3 = {};
28
37
  __export(exports_provider3, {
29
38
  AISDK_PREFIX: () => AISDK_PREFIX2,
30
- Event: () => Event16,
31
- ID: () => ID13,
32
- Info: () => Info26,
39
+ Event: () => Event14,
40
+ ID: () => ID8,
41
+ Info: () => Info22,
33
42
  LoadError: () => LoadError3,
34
43
  Provider: () => exports_provider3,
35
- Request: () => Request3,
36
- Service: () => Service71,
44
+ Request: () => Request2,
45
+ Service: () => Service65,
37
46
  Settings: () => Settings2,
38
47
  aisdk: () => aisdk2,
39
48
  isAISDK: () => isAISDK2,
@@ -41,10 +50,10 @@ __export(exports_provider3, {
41
50
  mergeHeaders: () => mergeHeaders2,
42
51
  mergeOverlay: () => mergeOverlay2,
43
52
  nativeSettings: () => nativeSettings2,
44
- node: () => node75,
53
+ node: () => node68,
45
54
  packageName: () => packageName2
46
55
  });
47
- import { Context, Effect as Effect2, Layer, Schema as Schema2, Stream, Struct as Struct2 } from "effect";
56
+ import { Context, Effect, Layer, Schema, Stream, Struct } from "effect";
48
57
  import { Provider } from "@opencode/schema/provider";
49
58
  import { Model } from "@opencode/schema/model";
50
59
  import { makeLocationNode } from "@opencode/util/effect/app-node";
@@ -52,255 +61,8 @@ import { isRecord } from "@opencode/ai/utils/record";
52
61
  import { importModule, resolveModule } from "@opencode/util/runtime-import";
53
62
  import { Credential } from "@opencode/schema/credential";
54
63
  import { freeze } from "immer";
55
-
56
- // src/aisdk-native.ts
57
- var exports_aisdk_native = {};
58
- __export(exports_aisdk_native, {
59
- AISDKNative: () => exports_aisdk_native,
60
- native: () => native2,
61
- rewrite: () => rewrite2
62
- });
63
- import { Effect, Option, Schema, Struct } from "effect";
64
- function rewrite2(target, input) {
65
- if (input.specifier === undefined)
66
- return;
67
- const plain = resolve(input.specifier, input);
68
- if (!plain)
69
- return;
70
- const settings = decode(target.settings ?? {});
71
- const replacement = resolve(input.specifier, { ...input, settings }) ?? plain;
72
- const translated = options(replacement, input.modelID, settings);
73
- if (target.package !== undefined || replacement !== input.specifier)
74
- target.package = replacement;
75
- target.settings = target.settings === undefined ? undefined : {
76
- ...translated.settings,
77
- ...!NATIVE.has(input.specifier) && replacement === "@opencode/ai/providers/openai-compatible" ? { provider: input.canonical ?? input.providerID } : {}
78
- };
79
- target.headers = mergeHeaders2(translated.headers, target.headers);
80
- target.body = mergeOverlay2(translated.body, target.body);
81
- target.variants = target.variants?.map((variant) => {
82
- const overlay = options(replacement, input.modelID, decode(variant.settings ?? {}));
83
- const headers = mergeHeaders2(overlay.headers, variant.headers);
84
- const body = mergeOverlay2(overlay.body, variant.body);
85
- return {
86
- id: variant.id,
87
- ...variant.settings === undefined ? {} : { settings: overlay.settings },
88
- ...headers === undefined ? {} : { headers },
89
- ...body === undefined ? {} : { body }
90
- };
91
- });
92
- }
93
- var PACKAGES = {
94
- "@ai-sdk/amazon-bedrock": "@opencode/ai/providers/amazon-bedrock",
95
- "@ai-sdk/alibaba": "@opencode/ai/providers/alibaba/chat",
96
- "@ai-sdk/anthropic": "@opencode/ai/providers/anthropic",
97
- "@ai-sdk/azure": "@opencode/ai/providers/azure/responses",
98
- "@ai-sdk/cerebras": "@opencode/ai/providers/cerebras",
99
- "@ai-sdk/deepinfra": "@opencode/ai/providers/deepinfra",
100
- "@ai-sdk/google": "@opencode/ai/providers/google",
101
- "@ai-sdk/google-vertex": "@opencode/ai/providers/google-vertex",
102
- "@ai-sdk/google-vertex/anthropic": "@opencode/ai/providers/google-vertex/messages",
103
- "@ai-sdk/groq": "@opencode/ai/providers/groq",
104
- "@ai-sdk/mistral": "@opencode/ai/providers/mistral",
105
- "@ai-sdk/openai": "@opencode/ai/providers/openai",
106
- "@ai-sdk/openai-compatible": "@opencode/ai/providers/openai-compatible",
107
- "@ai-sdk/togetherai": "@opencode/ai/providers/togetherai",
108
- "@ai-sdk/xai": "@opencode/ai/providers/xai",
109
- "@openrouter/ai-sdk-provider": "@opencode/ai/providers/openrouter",
110
- "ai-gateway-provider": "@opencode/ai/providers/cloudflare-ai-gateway"
111
- };
112
- var protocols = (name) => ({
113
- "@ai-sdk/openai-compatible": `@opencode/ai/providers/${name}/chat`,
114
- "@ai-sdk/anthropic": `@opencode/ai/providers/${name}/messages`,
115
- "@ai-sdk/openai": `@opencode/ai/providers/${name}/responses`
116
- });
117
- var HOSTS = {
118
- alibaba: protocols("alibaba"),
119
- "alibaba-cn": protocols("alibaba"),
120
- "alibaba-coding-plan": protocols("alibaba"),
121
- "alibaba-coding-plan-cn": protocols("alibaba"),
122
- "alibaba-token-plan": protocols("alibaba"),
123
- "alibaba-token-plan-cn": protocols("alibaba"),
124
- baseten: { "@ai-sdk/openai-compatible": "@opencode/ai/providers/baseten" },
125
- "cloudflare-ai-gateway": {
126
- "@ai-sdk/anthropic": "@opencode/ai/providers/cloudflare-ai-gateway",
127
- "@ai-sdk/openai": "@opencode/ai/providers/cloudflare-ai-gateway",
128
- "@ai-sdk/openai-compatible": "@opencode/ai/providers/cloudflare-ai-gateway",
129
- "ai-gateway-provider": "@opencode/ai/providers/cloudflare-ai-gateway"
130
- },
131
- "cloudflare-workers-ai": { "@ai-sdk/openai-compatible": "@opencode/ai/providers/cloudflare-workers-ai" },
132
- deepseek: { "@ai-sdk/openai-compatible": "@opencode/ai/providers/deepseek" },
133
- "fireworks-ai": { "@ai-sdk/openai-compatible": "@opencode/ai/providers/fireworks" },
134
- "google-vertex": { "@ai-sdk/openai-compatible": "@opencode/ai/providers/google-vertex/chat" },
135
- "kimi-for-coding": protocols("moonshot"),
136
- meta: protocols("meta"),
137
- minimax: protocols("minimax"),
138
- "minimax-cn": protocols("minimax"),
139
- "minimax-coding-plan": protocols("minimax"),
140
- "minimax-cn-coding-plan": protocols("minimax"),
141
- moonshotai: protocols("moonshot"),
142
- "moonshotai-cn": protocols("moonshot"),
143
- zai: { "@ai-sdk/openai-compatible": "@opencode/ai/providers/zai/chat" },
144
- "zai-coding-plan": protocols("zai-coding-plan"),
145
- zhipuai: { "@ai-sdk/openai-compatible": "@opencode/ai/providers/zai/chat" },
146
- "zhipuai-coding-plan": protocols("zai-coding-plan")
147
- };
148
- var NATIVE = new Set([
149
- ...Object.values(PACKAGES),
150
- ...Object.values(HOSTS).flatMap((host) => Object.values(host)),
151
- "@opencode/ai/providers/azure/chat",
152
- "@opencode/ai/providers/amazon-bedrock/mantle",
153
- "@opencode/ai/providers/amazon-bedrock/mantle/chat",
154
- "@opencode/ai/providers/amazon-bedrock/mantle/responses"
155
- ]);
156
- function native2(npm, context) {
157
- const host = HOSTS[context.providerID]?.[npm];
158
- if (host)
159
- return host;
160
- if (npm === "@ai-sdk/amazon-bedrock/mantle")
161
- return mantle(context.modelID);
162
- if (npm === "@ai-sdk/azure" && context.settings?.useCompletionUrls === true)
163
- return "@opencode/ai/providers/azure/chat";
164
- return PACKAGES[npm];
165
- }
166
- var mantle = (modelID) => {
167
- if (modelID === undefined)
168
- return "@opencode/ai/providers/amazon-bedrock/mantle";
169
- return `@opencode/ai/providers/amazon-bedrock/mantle/${modelID.includes("gpt-oss") ? "chat" : "responses"}`;
170
- };
171
- function resolve(specifier, context) {
172
- const npm = packageName2(specifier);
173
- if (isAISDK2(specifier) || npm in PACKAGES || npm in (HOSTS[context.providerID] ?? {}))
174
- return native2(npm, context);
175
- if (npm === "@opencode/ai/providers/amazon-bedrock/mantle")
176
- return mantle(context.modelID);
177
- if (npm === "@opencode/ai/providers/azure/responses" && context.settings?.useCompletionUrls === true)
178
- return "@opencode/ai/providers/azure/chat";
179
- return NATIVE.has(npm) ? npm : undefined;
180
- }
181
- function options(replacement, modelID, settings) {
182
- const converse = replacement === "@opencode/ai/providers/amazon-bedrock" && modelID !== undefined;
183
- const kept = Struct.omit(settings, ["headers", "extraBody", "useCompletionUrls", ...OPENROUTER_KEYS]);
184
- return {
185
- settings: replacement.startsWith("@opencode/ai/providers/amazon-bedrock") ? bedrockSettings(kept, converse) : kept,
186
- ...settings.headers === undefined ? {} : { headers: settings.headers },
187
- ...settings.extraBody === undefined ? {} : { body: settings.extraBody },
188
- ...converse ? bedrockRequest(modelID, settings) : {},
189
- ...replacement === "@opencode/ai/providers/openrouter" ? openRouterRequest(settings) : {}
190
- };
191
- }
192
- var BEDROCK_KEYS = [
193
- "bearerToken",
194
- "endpoint",
195
- "credentials",
196
- "credentialProvider",
197
- "accessKeyId",
198
- "secretAccessKey",
199
- "sessionToken"
200
- ];
201
- var CONVERSE_KEYS = ["additionalModelRequestFields", "reasoningConfig", "anthropicBeta", "serviceTier"];
202
- function bedrockSettings(settings, converse) {
203
- const region = settings.region ?? settings.credentials?.region;
204
- const credentials = settings.credentials ?? settings;
205
- const baseURL = settings.baseURL ?? settings.endpoint;
206
- return {
207
- ...Struct.omit(settings, converse ? [...BEDROCK_KEYS, ...CONVERSE_KEYS] : BEDROCK_KEYS),
208
- ...baseURL === undefined ? {} : { baseURL: region === undefined ? baseURL : baseURL.replaceAll("${AWS_REGION}", region) },
209
- ...settings.apiKey === undefined && settings.bearerToken !== undefined ? { apiKey: settings.bearerToken } : {},
210
- ...credentials.accessKeyId === undefined || credentials.secretAccessKey === undefined ? {} : {
211
- credentials: {
212
- ...region === undefined ? {} : { region },
213
- accessKeyId: credentials.accessKeyId,
214
- secretAccessKey: credentials.secretAccessKey,
215
- ...credentials.sessionToken === undefined ? {} : { sessionToken: credentials.sessionToken }
216
- }
217
- }
218
- };
219
- }
220
- function bedrockRequest(modelID, settings) {
221
- const additional = settings.additionalModelRequestFields ?? {};
222
- const reasoning = settings.reasoningConfig;
223
- const anthropic = modelID?.includes("anthropic") ?? false;
224
- const openai = modelID?.includes("openai.") ?? false;
225
- const harmony = modelID?.includes("openai.gpt-oss") ?? false;
226
- const effort = reasoning?.maxReasoningEffort;
227
- const type = reasoning?.type;
228
- const budget = reasoning?.budgetTokens;
229
- const display = reasoning?.display;
230
- const betas = settings.anthropicBeta ?? [];
231
- const fields = mergeOverlay2(additional, {
232
- ...betas.length > 0 ? { anthropic_beta: [...additional.anthropic_beta ?? [], ...betas] } : {},
233
- ...anthropic && type === "enabled" && budget !== undefined ? { thinking: { type: "enabled", budget_tokens: budget } } : {},
234
- ...anthropic && type === "adaptive" ? { thinking: { type: "adaptive", ...display === undefined ? {} : { display } } } : {},
235
- ...anthropic && effort !== undefined ? { output_config: { ...additional.output_config, effort } } : {},
236
- ...!anthropic && openai && harmony && effort !== undefined ? { reasoning_effort: effort } : {},
237
- ...!anthropic && openai && !harmony && effort !== undefined ? { reasoning: { ...additional.reasoning, effort } } : {},
238
- ...!anthropic && !openai && effort !== undefined ? {
239
- reasoningConfig: {
240
- ...type === undefined || type === "adaptive" ? {} : { type },
241
- ...budget === undefined ? {} : { budgetTokens: budget },
242
- maxReasoningEffort: effort
243
- }
244
- } : {}
245
- });
246
- const body = {
247
- ...fields && Object.keys(fields).length > 0 ? { additionalModelRequestFields: fields } : {},
248
- ...settings.serviceTier === undefined ? {} : { serviceTier: { type: settings.serviceTier } }
249
- };
250
- return Object.keys(body).length === 0 ? {} : { body };
251
- }
252
- var OPENROUTER_KEYS = ["appName", "appUrl", "api_keys", "compatibility"];
253
- function openRouterRequest(settings) {
254
- const headers = mergeHeaders2({
255
- ...settings.appName === undefined ? {} : { "X-OpenRouter-Title": settings.appName },
256
- ...settings.appUrl === undefined ? {} : { "HTTP-Referer": settings.appUrl },
257
- ...settings.api_keys === undefined || Object.keys(settings.api_keys).length === 0 ? {} : { "X-Provider-API-Keys": JSON.stringify(settings.api_keys) }
258
- }, settings.headers) ?? {};
259
- return Object.keys(headers).length === 0 ? {} : { headers };
260
- }
261
- var lenient = (schema) => Schema.optional(Schema.UndefinedOr(schema).pipe(Schema.catchDecoding(() => Effect.succeed(Option.some(undefined)))));
262
- var Credentials = Schema.Struct({
263
- accessKeyId: Schema.String,
264
- secretAccessKey: Schema.String,
265
- sessionToken: lenient(Schema.String),
266
- region: lenient(Schema.String)
267
- });
268
- var Legacy = Schema.StructWithRest(Schema.Struct({
269
- apiKey: lenient(Schema.String),
270
- baseURL: lenient(Schema.String),
271
- headers: lenient(Schema.Record(Schema.String, Schema.String)),
272
- extraBody: lenient(Schema.Record(Schema.String, Schema.Unknown)),
273
- useCompletionUrls: lenient(Schema.Boolean),
274
- auth: lenient(Schema.Literals(["bearer", "sigv4"])),
275
- bearerToken: lenient(Schema.String),
276
- endpoint: lenient(Schema.String),
277
- region: lenient(Schema.String),
278
- credentials: lenient(Credentials),
279
- accessKeyId: lenient(Schema.String),
280
- secretAccessKey: lenient(Schema.String),
281
- sessionToken: lenient(Schema.String),
282
- anthropicBeta: lenient(Schema.Array(Schema.String)),
283
- serviceTier: lenient(Schema.String),
284
- reasoningConfig: lenient(Schema.Struct({
285
- type: lenient(Schema.String),
286
- display: lenient(Schema.String),
287
- maxReasoningEffort: lenient(Schema.String),
288
- budgetTokens: lenient(Schema.Number)
289
- })),
290
- additionalModelRequestFields: lenient(Schema.StructWithRest(Schema.Struct({
291
- anthropic_beta: lenient(Schema.Array(Schema.String)),
292
- output_config: lenient(Schema.Record(Schema.String, Schema.Unknown)),
293
- reasoning: lenient(Schema.Record(Schema.String, Schema.Unknown))
294
- }), [Schema.Record(Schema.String, Schema.Unknown)])),
295
- appName: lenient(Schema.String),
296
- appUrl: lenient(Schema.String),
297
- api_keys: lenient(Schema.Record(Schema.String, Schema.String))
298
- }), [Schema.Record(Schema.String, Schema.Unknown)]);
299
- var decode = Schema.decodeUnknownSync(Legacy);
300
-
301
- // src/provider.ts
302
- import { Event as Event16 } from "@opencode/schema/provider";
303
- var ID13 = Provider.ID;
64
+ import { Event as Event14 } from "@opencode/schema/provider";
65
+ var ID8 = Provider.ID;
304
66
  var AISDK_PREFIX2 = "aisdk:";
305
67
  var isAISDK2 = (value) => value?.startsWith(AISDK_PREFIX2) ?? false;
306
68
  var aisdk2 = (value) => isAISDK2(value) ? value : `${AISDK_PREFIX2}${value}`;
@@ -311,12 +73,12 @@ function packageName2(value) {
311
73
  return value;
312
74
  return value.slice(AISDK_PREFIX2.length);
313
75
  }
314
- var JsonRecord = Schema2.Record(Schema2.String, Schema2.Json);
315
- var decodeJsonRecord = Schema2.decodeUnknownSync(JsonRecord);
76
+ var JsonRecord = Schema.Record(Schema.String, Schema.Json);
77
+ var decodeJsonRecord = Schema.decodeUnknownSync(JsonRecord);
316
78
 
317
- class LoadError3 extends Schema2.TaggedError()("Provider.LoadError", {
318
- package: Schema2.String,
319
- cause: Schema2.Defect()
79
+ class LoadError3 extends Schema.TaggedError()("Provider.LoadError", {
80
+ package: Schema.String,
81
+ cause: Schema.Defect()
320
82
  }) {
321
83
  }
322
84
  var packages = new Map;
@@ -377,12 +139,12 @@ var builtins = new Map([
377
139
  () => import("@opencode/ai/providers/zai-coding-plan/responses")
378
140
  ]
379
141
  ]);
380
- var loadPackage2 = Effect2.fn("Provider.loadPackage")(function* (input, npm) {
142
+ var loadPackage2 = Effect.fn("Provider.loadPackage")(function* (input, npm) {
381
143
  const specifier = packageName2(input);
382
144
  const builtin = builtins.get(specifier);
383
145
  if (builtin)
384
146
  return yield* importPackage(specifier, specifier, builtin);
385
- const resolved = yield* Effect2.sync(() => {
147
+ const resolved = yield* Effect.sync(() => {
386
148
  if (specifier.startsWith("file://") || specifier.startsWith("@opencode/ai/"))
387
149
  return specifier;
388
150
  try {
@@ -401,8 +163,8 @@ var loadPackage2 = Effect2.fn("Provider.loadPackage")(function* (input, npm) {
401
163
  }
402
164
  const parts = specifier.split("/");
403
165
  const root = specifier.startsWith("@") ? parts.slice(0, 2).join("/") : parts[0] ?? specifier;
404
- const installed = yield* npm.add(root).pipe(Effect2.mapError((cause) => new LoadError3({ package: specifier, cause })));
405
- const entrypoint = yield* Effect2.try({
166
+ const installed = yield* npm.add(root).pipe(Effect.mapError((cause) => new LoadError3({ package: specifier, cause })));
167
+ const entrypoint = yield* Effect.try({
406
168
  try: () => resolveModule(specifier, installed.directory),
407
169
  catch: (cause) => new LoadError3({ package: specifier, cause })
408
170
  });
@@ -410,7 +172,7 @@ var loadPackage2 = Effect2.fn("Provider.loadPackage")(function* (input, npm) {
410
172
  });
411
173
  var TRANSPORT_KEYS = ["chunkTimeout", "fetch", "timeout"];
412
174
  function nativeSettings2(settings) {
413
- return Struct2.omit(settings, TRANSPORT_KEYS);
175
+ return Struct.omit(settings, TRANSPORT_KEYS);
414
176
  }
415
177
  function mergeOverlay2(base, overlay) {
416
178
  if (base === undefined)
@@ -437,11 +199,11 @@ function mergeHeaders2(base, overlay) {
437
199
  return result;
438
200
  }, new Map).values());
439
201
  }
440
- var Request3 = Provider.Request;
202
+ var Request2 = Provider.Request;
441
203
  var Settings2 = Provider.Settings;
442
- var Info26 = Provider.Info;
204
+ var Info22 = Provider.Info;
443
205
 
444
- class Service71 extends Context.Service()("@opencode/Provider") {
206
+ class Service65 extends Context.Service()("@opencode/Provider") {
445
207
  }
446
208
  var definitions = new WeakMap;
447
209
  function index(models) {
@@ -452,10 +214,10 @@ function index(models) {
452
214
  definitions.set(models, result);
453
215
  return result;
454
216
  }
455
- var layer = Layer.effect(Service71, Effect2.gen(function* () {
456
- const bus = yield* Service81;
457
- const integrations = yield* Service72;
458
- const location = yield* Service78;
217
+ var layer = Layer.effect(Service65, Effect.gen(function* () {
218
+ const bus = yield* Service80;
219
+ const integrations = yield* Service66;
220
+ const location = yield* Service77;
459
221
  const state = create3({
460
222
  name: "provider",
461
223
  initial: () => new Map,
@@ -466,7 +228,7 @@ var layer = Layer.effect(Service71, Effect2.gen(function* () {
466
228
  const current = records.get(id);
467
229
  if (current)
468
230
  return current;
469
- const added = { provider: Info26.empty(id), models: new Map };
231
+ const added = { provider: Info22.empty(id), models: new Map };
470
232
  records.set(id, added);
471
233
  maps.add(added.models);
472
234
  return added;
@@ -534,9 +296,9 @@ var layer = Layer.effect(Service71, Effect2.gen(function* () {
534
296
  },
535
297
  notify: () => notify
536
298
  });
537
- yield* Effect2.addFinalizer(() => shutdown2(state.reload()));
299
+ yield* Effect.addFinalizer(() => shutdown2(state.reload()));
538
300
  let cached;
539
- const snapshot = Effect2.fn("Provider.snapshot")(function* () {
301
+ const snapshot = Effect.fn("Provider.snapshot")(function* () {
540
302
  while (true) {
541
303
  const revision = integrations.revision();
542
304
  const records = state.get();
@@ -550,7 +312,7 @@ var layer = Layer.effect(Service71, Effect2.gen(function* () {
550
312
  const available = Array.from(records.values()).filter((record) => {
551
313
  if (record.provider.activation === "disabled")
552
314
  return false;
553
- const integration = byID.get(record.provider.integrationID ?? ID14.make(record.provider.id));
315
+ const integration = byID.get(record.provider.integrationID ?? ID9.make(record.provider.id));
554
316
  if (record.sourceConnection && key2(record.sourceConnection) !== key2(integration?.connections[0]))
555
317
  return false;
556
318
  if (record.provider.activation === "enabled")
@@ -565,7 +327,7 @@ var layer = Layer.effect(Service71, Effect2.gen(function* () {
565
327
  }
566
328
  });
567
329
  let published;
568
- const notify = Effect2.gen(function* () {
330
+ const notify = Effect.gen(function* () {
569
331
  const value = yield* snapshot();
570
332
  if (value === published)
571
333
  return;
@@ -574,19 +336,19 @@ var layer = Layer.effect(Service71, Effect2.gen(function* () {
574
336
  location: { directory: location.directory, workspaceID: location.workspaceID }
575
337
  });
576
338
  });
577
- yield* bus.subscribe([Event17.Updated, Credential.Event.Updated, Credential.Event.Switched]).pipe(Stream.runForEach(() => notify), Effect2.forkScoped({ startImmediately: true }));
578
- return Service71.of({
339
+ yield* bus.subscribe([Event15.Updated, Credential.Event.Updated, Credential.Event.Switched]).pipe(Stream.runForEach(() => notify), Effect.forkScoped({ startImmediately: true }));
340
+ return Service65.of({
579
341
  transform: state.transform,
580
342
  reload: state.reload,
581
- get: Effect2.fn("Provider.get")((id) => Effect2.sync(() => freeze(state.get().get(id)?.provider, true))),
582
- all: Effect2.fn("Provider.all")(() => Effect2.sync(() => Array.from(state.get().values(), (record) => freeze(record.provider, true)))),
583
- available: Effect2.fn("Provider.available")(() => snapshot().pipe(Effect2.map((value) => value.providers))),
343
+ get: Effect.fn("Provider.get")((id) => Effect.sync(() => freeze(state.get().get(id)?.provider, true))),
344
+ all: Effect.fn("Provider.all")(() => Effect.sync(() => Array.from(state.get().values(), (record) => freeze(record.provider, true)))),
345
+ available: Effect.fn("Provider.available")(() => snapshot().pipe(Effect.map((value) => value.providers))),
584
346
  snapshot
585
347
  });
586
348
  }));
587
- var node75 = makeLocationNode({ service: Service71, layer, deps: [node85, node76, node82] });
588
- var importPackage = Effect2.fn("Provider.importPackage")(function* (specifier, entrypoint, load = () => importModule(entrypoint)) {
589
- const module = yield* Effect2.tryPromise({
349
+ var node68 = makeLocationNode({ service: Service65, layer, deps: [node84, node69, node81] });
350
+ var importPackage = Effect.fn("Provider.importPackage")(function* (specifier, entrypoint, load = () => importModule(entrypoint)) {
351
+ const module = yield* Effect.tryPromise({
590
352
  try: () => {
591
353
  const existing = packages.get(entrypoint);
592
354
  if (existing)
@@ -606,4 +368,242 @@ var importPackage = Effect2.fn("Provider.importPackage")(function* (specifier, e
606
368
  return module;
607
369
  });
608
370
 
609
- export { ID13, AISDK_PREFIX2, isAISDK2, aisdk2, packageName2, LoadError3, loadPackage2, nativeSettings2, mergeOverlay2, mergeHeaders2, Request3, Settings2, Info26, Service71, node75, exports_provider3, Event16, rewrite2, native2, exports_aisdk_native };
371
+ // src/aisdk-native.ts
372
+ function rewrite2(target, input) {
373
+ if (input.specifier === undefined)
374
+ return;
375
+ const plain = resolve(input.specifier, input);
376
+ if (!plain)
377
+ return;
378
+ const settings = decode(target.settings ?? {});
379
+ const replacement = resolve(input.specifier, { ...input, settings }) ?? plain;
380
+ const translated = options(replacement, input.modelID, settings);
381
+ if (target.package !== undefined || replacement !== input.specifier)
382
+ target.package = replacement;
383
+ target.settings = target.settings === undefined ? undefined : {
384
+ ...translated.settings,
385
+ ...!NATIVE.has(input.specifier) && replacement === "@opencode/ai/providers/openai-compatible" ? { provider: input.canonical ?? input.providerID } : {}
386
+ };
387
+ target.headers = mergeHeaders2(translated.headers, target.headers);
388
+ target.body = mergeOverlay2(translated.body, target.body);
389
+ target.variants = target.variants?.map((variant) => {
390
+ const overlay = options(replacement, input.modelID, decode(variant.settings ?? {}));
391
+ const headers = mergeHeaders2(overlay.headers, variant.headers);
392
+ const body = mergeOverlay2(overlay.body, variant.body);
393
+ return {
394
+ id: variant.id,
395
+ ...variant.settings === undefined ? {} : { settings: overlay.settings },
396
+ ...headers === undefined ? {} : { headers },
397
+ ...body === undefined ? {} : { body }
398
+ };
399
+ });
400
+ }
401
+ var PACKAGES = {
402
+ "@ai-sdk/amazon-bedrock": "@opencode/ai/providers/amazon-bedrock",
403
+ "@ai-sdk/alibaba": "@opencode/ai/providers/alibaba/chat",
404
+ "@ai-sdk/anthropic": "@opencode/ai/providers/anthropic",
405
+ "@ai-sdk/azure": "@opencode/ai/providers/azure/responses",
406
+ "@ai-sdk/cerebras": "@opencode/ai/providers/cerebras",
407
+ "@ai-sdk/deepinfra": "@opencode/ai/providers/deepinfra",
408
+ "@ai-sdk/google": "@opencode/ai/providers/google",
409
+ "@ai-sdk/google-vertex": "@opencode/ai/providers/google-vertex",
410
+ "@ai-sdk/google-vertex/anthropic": "@opencode/ai/providers/google-vertex/messages",
411
+ "@ai-sdk/groq": "@opencode/ai/providers/groq",
412
+ "@ai-sdk/mistral": "@opencode/ai/providers/mistral",
413
+ "@ai-sdk/openai": "@opencode/ai/providers/openai",
414
+ "@ai-sdk/openai-compatible": "@opencode/ai/providers/openai-compatible",
415
+ "@ai-sdk/togetherai": "@opencode/ai/providers/togetherai",
416
+ "@ai-sdk/xai": "@opencode/ai/providers/xai",
417
+ "@openrouter/ai-sdk-provider": "@opencode/ai/providers/openrouter",
418
+ "ai-gateway-provider": "@opencode/ai/providers/cloudflare-ai-gateway"
419
+ };
420
+ var protocols = (name) => ({
421
+ "@ai-sdk/openai-compatible": `@opencode/ai/providers/${name}/chat`,
422
+ "@ai-sdk/anthropic": `@opencode/ai/providers/${name}/messages`,
423
+ "@ai-sdk/openai": `@opencode/ai/providers/${name}/responses`
424
+ });
425
+ var HOSTS = {
426
+ alibaba: protocols("alibaba"),
427
+ "alibaba-cn": protocols("alibaba"),
428
+ "alibaba-coding-plan": protocols("alibaba"),
429
+ "alibaba-coding-plan-cn": protocols("alibaba"),
430
+ "alibaba-token-plan": protocols("alibaba"),
431
+ "alibaba-token-plan-cn": protocols("alibaba"),
432
+ baseten: { "@ai-sdk/openai-compatible": "@opencode/ai/providers/baseten" },
433
+ "cloudflare-ai-gateway": {
434
+ "@ai-sdk/anthropic": "@opencode/ai/providers/cloudflare-ai-gateway",
435
+ "@ai-sdk/openai": "@opencode/ai/providers/cloudflare-ai-gateway",
436
+ "@ai-sdk/openai-compatible": "@opencode/ai/providers/cloudflare-ai-gateway",
437
+ "ai-gateway-provider": "@opencode/ai/providers/cloudflare-ai-gateway"
438
+ },
439
+ "cloudflare-workers-ai": { "@ai-sdk/openai-compatible": "@opencode/ai/providers/cloudflare-workers-ai" },
440
+ deepseek: { "@ai-sdk/openai-compatible": "@opencode/ai/providers/deepseek" },
441
+ "fireworks-ai": { "@ai-sdk/openai-compatible": "@opencode/ai/providers/fireworks" },
442
+ "google-vertex": { "@ai-sdk/openai-compatible": "@opencode/ai/providers/google-vertex/chat" },
443
+ "kimi-for-coding": protocols("moonshot"),
444
+ meta: protocols("meta"),
445
+ minimax: protocols("minimax"),
446
+ "minimax-cn": protocols("minimax"),
447
+ "minimax-coding-plan": protocols("minimax"),
448
+ "minimax-cn-coding-plan": protocols("minimax"),
449
+ moonshotai: protocols("moonshot"),
450
+ "moonshotai-cn": protocols("moonshot"),
451
+ zai: { "@ai-sdk/openai-compatible": "@opencode/ai/providers/zai/chat" },
452
+ "zai-coding-plan": protocols("zai-coding-plan"),
453
+ zhipuai: { "@ai-sdk/openai-compatible": "@opencode/ai/providers/zai/chat" },
454
+ "zhipuai-coding-plan": protocols("zai-coding-plan")
455
+ };
456
+ var NATIVE = new Set([
457
+ ...Object.values(PACKAGES),
458
+ ...Object.values(HOSTS).flatMap((host) => Object.values(host)),
459
+ "@opencode/ai/providers/azure/chat",
460
+ "@opencode/ai/providers/amazon-bedrock/mantle",
461
+ "@opencode/ai/providers/amazon-bedrock/mantle/chat",
462
+ "@opencode/ai/providers/amazon-bedrock/mantle/responses"
463
+ ]);
464
+ function native2(npm, context) {
465
+ const host = HOSTS[context.providerID]?.[npm];
466
+ if (host)
467
+ return host;
468
+ if (npm === "@ai-sdk/amazon-bedrock/mantle")
469
+ return mantle(context.modelID);
470
+ if (npm === "@ai-sdk/azure" && context.settings?.useCompletionUrls === true)
471
+ return "@opencode/ai/providers/azure/chat";
472
+ return PACKAGES[npm];
473
+ }
474
+ var mantle = (modelID) => {
475
+ if (modelID === undefined)
476
+ return "@opencode/ai/providers/amazon-bedrock/mantle";
477
+ return `@opencode/ai/providers/amazon-bedrock/mantle/${modelID.includes("gpt-oss") ? "chat" : "responses"}`;
478
+ };
479
+ function resolve(specifier, context) {
480
+ const npm = packageName2(specifier);
481
+ if (isAISDK2(specifier) || npm in PACKAGES || npm in (HOSTS[context.providerID] ?? {}))
482
+ return native2(npm, context);
483
+ if (npm === "@opencode/ai/providers/amazon-bedrock/mantle")
484
+ return mantle(context.modelID);
485
+ if (npm === "@opencode/ai/providers/azure/responses" && context.settings?.useCompletionUrls === true)
486
+ return "@opencode/ai/providers/azure/chat";
487
+ return NATIVE.has(npm) ? npm : undefined;
488
+ }
489
+ function options(replacement, modelID, settings) {
490
+ const converse = replacement === "@opencode/ai/providers/amazon-bedrock" && modelID !== undefined;
491
+ const kept = Struct2.omit(settings, ["headers", "extraBody", "useCompletionUrls", ...OPENROUTER_KEYS]);
492
+ return {
493
+ settings: replacement.startsWith("@opencode/ai/providers/amazon-bedrock") ? bedrockSettings(kept, converse) : kept,
494
+ ...settings.headers === undefined ? {} : { headers: settings.headers },
495
+ ...settings.extraBody === undefined ? {} : { body: settings.extraBody },
496
+ ...converse ? bedrockRequest(modelID, settings) : {},
497
+ ...replacement === "@opencode/ai/providers/openrouter" ? openRouterRequest(settings) : {}
498
+ };
499
+ }
500
+ var BEDROCK_KEYS = [
501
+ "bearerToken",
502
+ "endpoint",
503
+ "credentials",
504
+ "credentialProvider",
505
+ "accessKeyId",
506
+ "secretAccessKey",
507
+ "sessionToken"
508
+ ];
509
+ var CONVERSE_KEYS = ["additionalModelRequestFields", "reasoningConfig", "anthropicBeta", "serviceTier"];
510
+ function bedrockSettings(settings, converse) {
511
+ const region = settings.region ?? settings.credentials?.region;
512
+ const credentials = settings.credentials ?? settings;
513
+ const baseURL = settings.baseURL ?? settings.endpoint;
514
+ return {
515
+ ...Struct2.omit(settings, converse ? [...BEDROCK_KEYS, ...CONVERSE_KEYS] : BEDROCK_KEYS),
516
+ ...baseURL === undefined ? {} : { baseURL: region === undefined ? baseURL : baseURL.replaceAll("${AWS_REGION}", region) },
517
+ ...settings.apiKey === undefined && settings.bearerToken !== undefined ? { apiKey: settings.bearerToken } : {},
518
+ ...credentials.accessKeyId === undefined || credentials.secretAccessKey === undefined ? {} : {
519
+ credentials: {
520
+ ...region === undefined ? {} : { region },
521
+ accessKeyId: credentials.accessKeyId,
522
+ secretAccessKey: credentials.secretAccessKey,
523
+ ...credentials.sessionToken === undefined ? {} : { sessionToken: credentials.sessionToken }
524
+ }
525
+ }
526
+ };
527
+ }
528
+ function bedrockRequest(modelID, settings) {
529
+ const additional = settings.additionalModelRequestFields ?? {};
530
+ const reasoning = settings.reasoningConfig;
531
+ const anthropic = modelID?.includes("anthropic") ?? false;
532
+ const openai = modelID?.includes("openai.") ?? false;
533
+ const harmony = modelID?.includes("openai.gpt-oss") ?? false;
534
+ const effort = reasoning?.maxReasoningEffort;
535
+ const type = reasoning?.type;
536
+ const budget = reasoning?.budgetTokens;
537
+ const display = reasoning?.display;
538
+ const betas = settings.anthropicBeta ?? [];
539
+ const fields = mergeOverlay2(additional, {
540
+ ...betas.length > 0 ? { anthropic_beta: [...additional.anthropic_beta ?? [], ...betas] } : {},
541
+ ...anthropic && type === "enabled" && budget !== undefined ? { thinking: { type: "enabled", budget_tokens: budget } } : {},
542
+ ...anthropic && type === "adaptive" ? { thinking: { type: "adaptive", ...display === undefined ? {} : { display } } } : {},
543
+ ...anthropic && effort !== undefined ? { output_config: { ...additional.output_config, effort } } : {},
544
+ ...!anthropic && openai && harmony && effort !== undefined ? { reasoning_effort: effort } : {},
545
+ ...!anthropic && openai && !harmony && effort !== undefined ? { reasoning: { ...additional.reasoning, effort } } : {},
546
+ ...!anthropic && !openai && effort !== undefined ? {
547
+ reasoningConfig: {
548
+ ...type === undefined || type === "adaptive" ? {} : { type },
549
+ ...budget === undefined ? {} : { budgetTokens: budget },
550
+ maxReasoningEffort: effort
551
+ }
552
+ } : {}
553
+ });
554
+ const body = {
555
+ ...fields && Object.keys(fields).length > 0 ? { additionalModelRequestFields: fields } : {},
556
+ ...settings.serviceTier === undefined ? {} : { serviceTier: { type: settings.serviceTier } }
557
+ };
558
+ return Object.keys(body).length === 0 ? {} : { body };
559
+ }
560
+ var OPENROUTER_KEYS = ["appName", "appUrl", "api_keys", "compatibility"];
561
+ function openRouterRequest(settings) {
562
+ const headers = mergeHeaders2({
563
+ ...settings.appName === undefined ? {} : { "X-OpenRouter-Title": settings.appName },
564
+ ...settings.appUrl === undefined ? {} : { "HTTP-Referer": settings.appUrl },
565
+ ...settings.api_keys === undefined || Object.keys(settings.api_keys).length === 0 ? {} : { "X-Provider-API-Keys": JSON.stringify(settings.api_keys) }
566
+ }, settings.headers) ?? {};
567
+ return Object.keys(headers).length === 0 ? {} : { headers };
568
+ }
569
+ var lenient = (schema) => Schema2.optional(Schema2.UndefinedOr(schema).pipe(Schema2.catchDecoding(() => Effect2.succeed(Option.some(undefined)))));
570
+ var Credentials = Schema2.Struct({
571
+ accessKeyId: Schema2.String,
572
+ secretAccessKey: Schema2.String,
573
+ sessionToken: lenient(Schema2.String),
574
+ region: lenient(Schema2.String)
575
+ });
576
+ var Legacy = Schema2.StructWithRest(Schema2.Struct({
577
+ apiKey: lenient(Schema2.String),
578
+ baseURL: lenient(Schema2.String),
579
+ headers: lenient(Schema2.Record(Schema2.String, Schema2.String)),
580
+ extraBody: lenient(Schema2.Record(Schema2.String, Schema2.Unknown)),
581
+ useCompletionUrls: lenient(Schema2.Boolean),
582
+ auth: lenient(Schema2.Literals(["bearer", "sigv4"])),
583
+ bearerToken: lenient(Schema2.String),
584
+ endpoint: lenient(Schema2.String),
585
+ region: lenient(Schema2.String),
586
+ credentials: lenient(Credentials),
587
+ accessKeyId: lenient(Schema2.String),
588
+ secretAccessKey: lenient(Schema2.String),
589
+ sessionToken: lenient(Schema2.String),
590
+ anthropicBeta: lenient(Schema2.Array(Schema2.String)),
591
+ serviceTier: lenient(Schema2.String),
592
+ reasoningConfig: lenient(Schema2.Struct({
593
+ type: lenient(Schema2.String),
594
+ display: lenient(Schema2.String),
595
+ maxReasoningEffort: lenient(Schema2.String),
596
+ budgetTokens: lenient(Schema2.Number)
597
+ })),
598
+ additionalModelRequestFields: lenient(Schema2.StructWithRest(Schema2.Struct({
599
+ anthropic_beta: lenient(Schema2.Array(Schema2.String)),
600
+ output_config: lenient(Schema2.Record(Schema2.String, Schema2.Unknown)),
601
+ reasoning: lenient(Schema2.Record(Schema2.String, Schema2.Unknown))
602
+ }), [Schema2.Record(Schema2.String, Schema2.Unknown)])),
603
+ appName: lenient(Schema2.String),
604
+ appUrl: lenient(Schema2.String),
605
+ api_keys: lenient(Schema2.Record(Schema2.String, Schema2.String))
606
+ }), [Schema2.Record(Schema2.String, Schema2.Unknown)]);
607
+ var decode = Schema2.decodeUnknownSync(Legacy);
608
+
609
+ export { rewrite2, native2, exports_aisdk_native, ID8, AISDK_PREFIX2, isAISDK2, aisdk2, packageName2, LoadError3, loadPackage2, nativeSettings2, mergeOverlay2, mergeHeaders2, Request2, Settings2, Info22, Service65, node68, exports_provider3, Event14 };