@opencode/core 0.0.0-dev-20968 → 0.0.0-dev-20970

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 (463) hide show
  1. package/dist/agent.js +70 -70
  2. package/dist/aisdk-native.js +68 -68
  3. package/dist/aisdk.js +73 -73
  4. package/dist/app.js +7 -7
  5. package/dist/bus.js +59 -59
  6. package/dist/chunks/{location-service-map-vfd5z52g.js → location-service-map-0e0z4xs4.js} +22 -22
  7. package/dist/chunks/{location-service-map-t550f9t1.js → location-service-map-0gdmqesm.js} +3 -3
  8. package/dist/chunks/{location-service-map-2gw07b48.js → location-service-map-0hws4rz6.js} +22 -22
  9. package/dist/chunks/{location-service-map-4v7ngy20.js → location-service-map-0xqyf95c.js} +3 -3
  10. package/dist/chunks/{location-service-map-3fgtv7ze.js → location-service-map-15gp8gwp.js} +18 -18
  11. package/dist/chunks/{location-service-map-wvf4y7rr.js → location-service-map-1cwtqt4r.js} +17 -17
  12. package/dist/chunks/{location-service-map-bjx1sjef.js → location-service-map-1ffvrpkg.js} +4 -4
  13. package/dist/chunks/{location-service-map-emxdjm72.js → location-service-map-1g7cdmxb.js} +20 -20
  14. package/dist/chunks/{location-service-map-a62egxb3.js → location-service-map-1j6f3fcz.js} +4 -4
  15. package/dist/chunks/{location-service-map-kp5we7ps.js → location-service-map-1nswxt31.js} +24 -24
  16. package/dist/chunks/{location-service-map-4z58m4b4.js → location-service-map-1rn5pcm9.js} +3 -3
  17. package/dist/chunks/{location-service-map-mgjjdy5b.js → location-service-map-2f8xmtvs.js} +9 -9
  18. package/dist/chunks/{location-service-map-a42kkhkg.js → location-service-map-2gbtb9ex.js} +27 -27
  19. package/dist/chunks/{location-service-map-e334ff5n.js → location-service-map-2kgr186q.js} +17 -17
  20. package/dist/chunks/{location-service-map-hxtckxf3.js → location-service-map-2sxk7h72.js} +25 -25
  21. package/dist/chunks/{location-service-map-bpq9gadp.js → location-service-map-2wdjt9g8.js} +12 -12
  22. package/dist/chunks/{location-service-map-5jvy51wy.js → location-service-map-333jpv82.js} +1 -1
  23. package/dist/chunks/{location-service-map-vxznmwbn.js → location-service-map-3a7h0qtw.js} +12 -12
  24. package/dist/chunks/{location-service-map-yjqnk9hn.js → location-service-map-3p5gpzs5.js} +25 -25
  25. package/dist/chunks/{location-service-map-5pyvwtgy.js → location-service-map-3sw2dssw.js} +12 -12
  26. package/dist/chunks/{location-service-map-trecwywa.js → location-service-map-3z3xn5yy.js} +18 -18
  27. package/dist/chunks/{location-service-map-qrabmw5q.js → location-service-map-40jkzs91.js} +44 -44
  28. package/dist/chunks/{location-service-map-st6tfvct.js → location-service-map-47yqzcwx.js} +28 -28
  29. package/dist/chunks/{location-service-map-qb7q1f1d.js → location-service-map-4f3wm1ac.js} +12 -12
  30. package/dist/chunks/{location-service-map-mh8n60fa.js → location-service-map-4h8beb84.js} +42 -42
  31. package/dist/chunks/{location-service-map-had4kgfk.js → location-service-map-4ns3h2re.js} +3 -3
  32. package/dist/chunks/{location-service-map-9d2vkprr.js → location-service-map-4ybf7fnk.js} +9 -9
  33. package/dist/chunks/{location-service-map-exs4tskk.js → location-service-map-50n7yzyq.js} +44 -44
  34. package/dist/chunks/{location-service-map-4sqgwhvg.js → location-service-map-58sy987p.js} +14 -14
  35. package/dist/chunks/{location-service-map-8czxvfjx.js → location-service-map-5jz5gmkx.js} +28 -28
  36. package/dist/chunks/{location-service-map-5cs9fw4j.js → location-service-map-5mq28h2t.js} +13 -13
  37. package/dist/chunks/{location-service-map-a4hp8e9p.js → location-service-map-5tjn6tpp.js} +15 -15
  38. package/dist/chunks/{location-service-map-gabsh7yw.js → location-service-map-5wbv3d1w.js} +6 -6
  39. package/dist/chunks/{location-service-map-9hn6k4tm.js → location-service-map-5xtgfte3.js} +7 -7
  40. package/dist/chunks/{location-service-map-gd0tnyjc.js → location-service-map-68wqtz75.js} +1 -1
  41. package/dist/chunks/{location-service-map-x5wrmng7.js → location-service-map-6bjhz71w.js} +3 -3
  42. package/dist/chunks/{location-service-map-g0xzmjr0.js → location-service-map-6jpm8ex2.js} +16 -16
  43. package/dist/chunks/{location-service-map-8ykp9xbw.js → location-service-map-79nhj7b6.js} +29 -29
  44. package/dist/chunks/{location-service-map-2k8khapm.js → location-service-map-7dqw4kz8.js} +4 -4
  45. package/dist/chunks/{location-service-map-ej81gkeg.js → location-service-map-7k1rdhbp.js} +5 -5
  46. package/dist/chunks/{location-service-map-hhyv66vq.js → location-service-map-7ph0vnsv.js} +7 -7
  47. package/dist/chunks/{location-service-map-kdxh9szv.js → location-service-map-7zdn2k09.js} +9 -9
  48. package/dist/chunks/{location-service-map-k4xdy46r.js → location-service-map-80m1sdbk.js} +314 -314
  49. package/dist/chunks/{location-service-map-vycw7md4.js → location-service-map-80scg3y3.js} +3 -3
  50. package/dist/chunks/{location-service-map-dacbrmk2.js → location-service-map-89x5zc49.js} +5 -5
  51. package/dist/chunks/{location-service-map-najnejyn.js → location-service-map-8acdjqfv.js} +11 -11
  52. package/dist/chunks/{location-service-map-mt6brxxc.js → location-service-map-8fe0d2sh.js} +1 -1
  53. package/dist/chunks/{location-service-map-w34bt5ev.js → location-service-map-8v3872mr.js} +4 -4
  54. package/dist/chunks/{location-service-map-0fzbfnq7.js → location-service-map-8z12w5mn.js} +1 -1
  55. package/dist/chunks/{location-service-map-6mdwj01c.js → location-service-map-9a1mrhyh.js} +13 -13
  56. package/dist/chunks/{location-service-map-qe178b41.js → location-service-map-9byyftbt.js} +22 -22
  57. package/dist/chunks/{location-service-map-kww7pfa5.js → location-service-map-9m4mwgwd.js} +5 -5
  58. package/dist/chunks/{location-service-map-7fj5dwt0.js → location-service-map-9sh4wc5j.js} +4 -4
  59. package/dist/chunks/{location-service-map-w75czvp0.js → location-service-map-9t8w0vez.js} +4 -4
  60. package/dist/chunks/{location-service-map-6xc75jjq.js → location-service-map-a22dk6g9.js} +43 -43
  61. package/dist/chunks/{location-service-map-jeewe651.js → location-service-map-a5e101j6.js} +4 -4
  62. package/dist/chunks/{location-service-map-0hw4dk4w.js → location-service-map-a7z0fe8c.js} +1 -1
  63. package/dist/chunks/{location-service-map-69jqfsnf.js → location-service-map-a8hvaj9p.js} +8 -8
  64. package/dist/chunks/{location-service-map-x661k3y3.js → location-service-map-addxnjmp.js} +3 -3
  65. package/dist/chunks/{location-service-map-j5chjq9f.js → location-service-map-agg557zn.js} +9 -9
  66. package/dist/chunks/{location-service-map-jrzj45fy.js → location-service-map-ah1t51zw.js} +9 -9
  67. package/dist/chunks/{location-service-map-1xjc3krj.js → location-service-map-ah9s4888.js} +4 -4
  68. package/dist/chunks/{location-service-map-05hkmm44.js → location-service-map-apbyd0y0.js} +13 -13
  69. package/dist/chunks/{location-service-map-jvnghvnw.js → location-service-map-at1kfnmk.js} +7 -7
  70. package/dist/chunks/{location-service-map-nc1ev885.js → location-service-map-av4ka64b.js} +70 -70
  71. package/dist/chunks/{location-service-map-bh3fdk74.js → location-service-map-avdzqnth.js} +2 -2
  72. package/dist/chunks/{location-service-map-jpaf2qm1.js → location-service-map-b5ab48k5.js} +41 -41
  73. package/dist/chunks/{location-service-map-thf5141v.js → location-service-map-bg0scr0s.js} +4 -4
  74. package/dist/chunks/{location-service-map-t9es0ena.js → location-service-map-bpqmbvp8.js} +17 -17
  75. package/dist/chunks/{location-service-map-ncp1h5wm.js → location-service-map-brzr8pgk.js} +1 -1
  76. package/dist/chunks/{location-service-map-xdfgfet0.js → location-service-map-bz1ch3a7.js} +24 -24
  77. package/dist/chunks/{location-service-map-kcdapykd.js → location-service-map-c67afrq3.js} +6 -6
  78. package/dist/chunks/{location-service-map-rfnwmvtk.js → location-service-map-c9y76qr3.js} +10 -10
  79. package/dist/chunks/{location-service-map-r2m716tb.js → location-service-map-cwa6csj7.js} +7 -7
  80. package/dist/chunks/{location-service-map-mdmc61fe.js → location-service-map-d2s7sfgk.js} +3 -3
  81. package/dist/chunks/{location-service-map-bjkg2ks4.js → location-service-map-dbd4bcxh.js} +24 -24
  82. package/dist/chunks/{location-service-map-6bkr64fg.js → location-service-map-ddnd35kk.js} +8 -8
  83. package/dist/chunks/{location-service-map-9h357zpk.js → location-service-map-djvdn7j4.js} +3 -3
  84. package/dist/chunks/{location-service-map-z1a6nf3f.js → location-service-map-dn85cbp5.js} +12 -12
  85. package/dist/chunks/{location-service-map-k6709ays.js → location-service-map-dn8fxr7e.js} +14 -14
  86. package/dist/chunks/{location-service-map-38x8v0tv.js → location-service-map-dnxwqgza.js} +16 -16
  87. package/dist/chunks/{location-service-map-y71avatq.js → location-service-map-dpkg50ah.js} +3 -3
  88. package/dist/chunks/{location-service-map-1hyeesvh.js → location-service-map-dprgbttx.js} +19 -19
  89. package/dist/chunks/{location-service-map-189fjxnc.js → location-service-map-dqss8s9h.js} +18 -18
  90. package/dist/chunks/{location-service-map-pck7vvdx.js → location-service-map-drmqggy3.js} +1 -1
  91. package/dist/chunks/{location-service-map-ktgr00t7.js → location-service-map-drnf6xwf.js} +1 -1
  92. package/dist/chunks/{location-service-map-h9mky73t.js → location-service-map-dvzj1xmf.js} +9 -9
  93. package/dist/chunks/{location-service-map-ewf8j77t.js → location-service-map-dwwb2yn6.js} +9 -9
  94. package/dist/chunks/{location-service-map-sdk84yjp.js → location-service-map-dzj3pesk.js} +5 -5
  95. package/dist/chunks/{location-service-map-wve2b6s5.js → location-service-map-e59gya24.js} +8 -8
  96. package/dist/chunks/{location-service-map-h8rphgn6.js → location-service-map-eegn9671.js} +4 -4
  97. package/dist/chunks/{location-service-map-95kyz0q3.js → location-service-map-ek79twyn.js} +1 -1
  98. package/dist/chunks/{location-service-map-8cxvr4t8.js → location-service-map-f6vptca4.js} +40 -40
  99. package/dist/chunks/{location-service-map-whqshyfz.js → location-service-map-fahd1t22.js} +7 -7
  100. package/dist/chunks/{location-service-map-v6tgae3y.js → location-service-map-fdn2kncn.js} +175 -175
  101. package/dist/chunks/{location-service-map-7hff53af.js → location-service-map-fjmme1zd.js} +21 -21
  102. package/dist/chunks/{location-service-map-vh4rw25j.js → location-service-map-fkrwggfj.js} +8 -8
  103. package/dist/chunks/{location-service-map-7mp49jye.js → location-service-map-ftxqeyfp.js} +22 -22
  104. package/dist/chunks/{location-service-map-hsvqr7g3.js → location-service-map-fwh25w6r.js} +27 -27
  105. package/dist/chunks/{location-service-map-ebbyhdvc.js → location-service-map-g16zfax1.js} +29 -29
  106. package/dist/chunks/{location-service-map-0b5g1ynf.js → location-service-map-gbh65n66.js} +1 -1
  107. package/dist/chunks/{location-service-map-fkhvp8gb.js → location-service-map-gc30vjt8.js} +19 -19
  108. package/dist/chunks/{location-service-map-6kpyj4fb.js → location-service-map-gfvfhfth.js} +9 -9
  109. package/dist/chunks/{location-service-map-9zdssp4n.js → location-service-map-gh8rs6tp.js} +8 -8
  110. package/dist/chunks/{location-service-map-q4aap459.js → location-service-map-gq9mz0q5.js} +23 -23
  111. package/dist/chunks/{location-service-map-977pwvh6.js → location-service-map-gvmyet0t.js} +4 -4
  112. package/dist/chunks/{location-service-map-9vjjhptz.js → location-service-map-gwaf4cyv.js} +7 -7
  113. package/dist/chunks/{location-service-map-eb5nwvjj.js → location-service-map-gybmckzj.js} +11 -11
  114. package/dist/chunks/{location-service-map-gv2dj64n.js → location-service-map-h36qpgyc.js} +5 -5
  115. package/dist/chunks/{location-service-map-61qtfb41.js → location-service-map-h3damvf7.js} +19 -19
  116. package/dist/chunks/{location-service-map-f50nbvzh.js → location-service-map-h5ctynge.js} +40 -40
  117. package/dist/chunks/{location-service-map-bhhmebad.js → location-service-map-h796dgtk.js} +11 -11
  118. package/dist/chunks/{location-service-map-ttbvdjdw.js → location-service-map-hbhk3w7g.js} +14 -14
  119. package/dist/chunks/{location-service-map-bm095xha.js → location-service-map-hse9bmtq.js} +2 -2
  120. package/dist/chunks/{location-service-map-hzp768xy.js → location-service-map-htr2xv6b.js} +5 -5
  121. package/dist/chunks/{location-service-map-vdcsbfm7.js → location-service-map-hw1z087j.js} +6 -6
  122. package/dist/chunks/{location-service-map-xsccak5w.js → location-service-map-hw81jkqg.js} +17 -17
  123. package/dist/chunks/{location-service-map-ykdkqy2w.js → location-service-map-hxxxkake.js} +14 -14
  124. package/dist/chunks/{location-service-map-sfz6vzg3.js → location-service-map-hy35aq5e.js} +9 -9
  125. package/dist/chunks/{location-service-map-0ycdfwp1.js → location-service-map-j0z1hbm7.js} +10 -10
  126. package/dist/chunks/{location-service-map-453vx0dg.js → location-service-map-j26e8f99.js} +36 -36
  127. package/dist/chunks/{location-service-map-zpfqjb86.js → location-service-map-j4xtsjbj.js} +12 -12
  128. package/dist/chunks/{location-service-map-c6nr29zh.js → location-service-map-jgrj7vpb.js} +9 -9
  129. package/dist/chunks/{location-service-map-w5rka97k.js → location-service-map-jvvc3tfq.js} +7 -7
  130. package/dist/chunks/{location-service-map-a41h3yhs.js → location-service-map-jxntzgs7.js} +22 -22
  131. package/dist/chunks/{location-service-map-07w9enf1.js → location-service-map-jz647r1p.js} +12 -12
  132. package/dist/chunks/{location-service-map-4pn1xf0p.js → location-service-map-k73fr1k7.js} +19 -19
  133. package/dist/chunks/{location-service-map-j947zhwf.js → location-service-map-k7wxww75.js} +9 -9
  134. package/dist/chunks/{location-service-map-gk6ab8mf.js → location-service-map-kc16ztxm.js} +10 -10
  135. package/dist/chunks/location-service-map-kf3mbpd3.js +253 -0
  136. package/dist/chunks/{location-service-map-8kzy7b3z.js → location-service-map-kfj9hn6k.js} +20 -20
  137. package/dist/chunks/{location-service-map-0pj15cwb.js → location-service-map-kg0ryrs1.js} +26 -26
  138. package/dist/chunks/{location-service-map-qce5rqyv.js → location-service-map-kjttyt96.js} +24 -24
  139. package/dist/chunks/{location-service-map-jvf3yq6v.js → location-service-map-kne8f3cn.js} +3 -3
  140. package/dist/chunks/{location-service-map-6npkjnc9.js → location-service-map-krpype3t.js} +14 -14
  141. package/dist/chunks/{location-service-map-av8cscef.js → location-service-map-kt13rzk4.js} +28 -28
  142. package/dist/chunks/{location-service-map-qwf29bqw.js → location-service-map-kvh9ex0n.js} +1 -1
  143. package/dist/chunks/{location-service-map-qezm2w8e.js → location-service-map-kvsv9rq3.js} +19 -19
  144. package/dist/chunks/{location-service-map-285qnyny.js → location-service-map-kxqng4z4.js} +14 -14
  145. package/dist/chunks/{location-service-map-y4a0ptp4.js → location-service-map-kz8sfr61.js} +5 -5
  146. package/dist/chunks/{location-service-map-svcw9x3w.js → location-service-map-m329mjby.js} +1 -1
  147. package/dist/chunks/{location-service-map-z5rnbfrr.js → location-service-map-m47hdp86.js} +8 -8
  148. package/dist/chunks/{location-service-map-4c3ndrn6.js → location-service-map-mcwdvdbx.js} +8 -8
  149. package/dist/chunks/{location-service-map-190mk5vc.js → location-service-map-ms1sgmgt.js} +12 -12
  150. package/dist/chunks/{location-service-map-51f5btjf.js → location-service-map-mx9vqzsb.js} +5 -5
  151. package/dist/chunks/{location-service-map-b1a1n7cj.js → location-service-map-my4zabxr.js} +3 -3
  152. package/dist/chunks/{location-service-map-x852hbsc.js → location-service-map-n3gkh2k8.js} +1 -1
  153. package/dist/chunks/{location-service-map-wnsxc07p.js → location-service-map-n7chbqxk.js} +19 -19
  154. package/dist/chunks/{location-service-map-zmr78fwr.js → location-service-map-n8vdnqrc.js} +3 -3
  155. package/dist/chunks/{location-service-map-3dq15cxk.js → location-service-map-ns04df5e.js} +11 -11
  156. package/dist/chunks/{location-service-map-zt28r1k4.js → location-service-map-nszkg83g.js} +22 -22
  157. package/dist/chunks/location-service-map-pc3mwg2h.js +513 -0
  158. package/dist/chunks/{location-service-map-ra67jj04.js → location-service-map-phz50fbd.js} +7 -7
  159. package/dist/chunks/{location-service-map-qyvjbqsg.js → location-service-map-pj97maf1.js} +22 -22
  160. package/dist/chunks/{location-service-map-qgw57eb3.js → location-service-map-pp6tmt8p.js} +5 -5
  161. package/dist/chunks/{location-service-map-pjykpq9n.js → location-service-map-pp7c1v3z.js} +30 -30
  162. package/dist/chunks/{location-service-map-e2t7s5t4.js → location-service-map-pxpx7y6c.js} +43 -43
  163. package/dist/chunks/{location-service-map-8sze2n9a.js → location-service-map-py3kkmfq.js} +4 -4
  164. package/dist/chunks/{location-service-map-b7hvd3bh.js → location-service-map-pynx3rzn.js} +11 -11
  165. package/dist/chunks/{location-service-map-s90bytks.js → location-service-map-q15xqe5w.js} +11 -11
  166. package/dist/chunks/{location-service-map-mpw5hxye.js → location-service-map-qn90mm7z.js} +10 -10
  167. package/dist/chunks/{location-service-map-1krj7acz.js → location-service-map-qv519ymt.js} +32 -32
  168. package/dist/chunks/{location-service-map-605e1jbp.js → location-service-map-qwqqzdxk.js} +7 -7
  169. package/dist/chunks/{location-service-map-nma959mg.js → location-service-map-r2z489rp.js} +2 -2
  170. package/dist/chunks/{location-service-map-erts2f6e.js → location-service-map-r37wb9bh.js} +9 -9
  171. package/dist/chunks/{location-service-map-x309wg9x.js → location-service-map-r5p8p72t.js} +6 -6
  172. package/dist/chunks/{location-service-map-t89fqycx.js → location-service-map-r61qxybf.js} +7 -7
  173. package/dist/chunks/{location-service-map-q85n4xbh.js → location-service-map-r80kwpvr.js} +8 -8
  174. package/dist/chunks/{location-service-map-0a3bg0j5.js → location-service-map-r8bwyjs3.js} +25 -25
  175. package/dist/chunks/{location-service-map-qvcr5dcn.js → location-service-map-ra8aazcz.js} +16 -16
  176. package/dist/chunks/{location-service-map-v2fstvx9.js → location-service-map-rdb1svpf.js} +26 -26
  177. package/dist/chunks/{location-service-map-b89jdn4q.js → location-service-map-rwme0grx.js} +16 -16
  178. package/dist/chunks/{location-service-map-96kn8jjj.js → location-service-map-ry082wg0.js} +1 -1
  179. package/dist/chunks/{location-service-map-79rgchyy.js → location-service-map-s0gydmaw.js} +19 -19
  180. package/dist/chunks/{location-service-map-t7n4d1yf.js → location-service-map-s2t00s75.js} +2 -2
  181. package/dist/chunks/location-service-map-s315gvtx.js +26 -0
  182. package/dist/chunks/{location-service-map-17t4d4av.js → location-service-map-s68q802c.js} +14 -14
  183. package/dist/chunks/{location-service-map-5e6vztpv.js → location-service-map-sb86xevf.js} +9 -9
  184. package/dist/chunks/{location-service-map-zcfatamc.js → location-service-map-shm9gt2y.js} +11 -11
  185. package/dist/chunks/{location-service-map-w85jx7ef.js → location-service-map-sx3pjf9c.js} +20 -20
  186. package/dist/chunks/{location-service-map-w7th8kft.js → location-service-map-t58ss6va.js} +9 -9
  187. package/dist/chunks/{location-service-map-112anbc5.js → location-service-map-t8ne3r2q.js} +18 -18
  188. package/dist/chunks/{location-service-map-ykxyh7k6.js → location-service-map-tbt5dvb1.js} +12 -12
  189. package/dist/chunks/{location-service-map-89znhe33.js → location-service-map-tcezcvh9.js} +3 -3
  190. package/dist/chunks/{location-service-map-8sqat94k.js → location-service-map-tgnnk969.js} +35 -35
  191. package/dist/chunks/{location-service-map-h83xjv7f.js → location-service-map-tk14y25j.js} +3 -3
  192. package/dist/chunks/{location-service-map-x94bbvss.js → location-service-map-txd8c2hd.js} +2 -2
  193. package/dist/chunks/{location-service-map-r3yrqnb5.js → location-service-map-txqtqxhq.js} +11 -11
  194. package/dist/chunks/{location-service-map-raxjnfg2.js → location-service-map-vb8wgay5.js} +9 -9
  195. package/dist/chunks/{location-service-map-6c5stfwb.js → location-service-map-vcc1d1p0.js} +1 -1
  196. package/dist/chunks/{location-service-map-z4qs0yhw.js → location-service-map-vjwphg0n.js} +29 -29
  197. package/dist/chunks/{location-service-map-kwqk5vnc.js → location-service-map-w0cr6kn3.js} +16 -16
  198. package/dist/chunks/{location-service-map-vhvv9bf9.js → location-service-map-w76n4hge.js} +8 -8
  199. package/dist/chunks/{location-service-map-04ttag0w.js → location-service-map-wqptjszz.js} +17 -17
  200. package/dist/chunks/{location-service-map-1bz87fsm.js → location-service-map-wyazz7bw.js} +13 -13
  201. package/dist/chunks/{location-service-map-88jjz5re.js → location-service-map-x5hsf6rj.js} +11 -11
  202. package/dist/chunks/{location-service-map-qavnhd3j.js → location-service-map-xe9ktzb9.js} +26 -26
  203. package/dist/chunks/{location-service-map-hmdrvyfh.js → location-service-map-xh49hxk7.js} +61 -61
  204. package/dist/chunks/{location-service-map-d54g0exn.js → location-service-map-xmpwqgz4.js} +7 -7
  205. package/dist/chunks/{location-service-map-dzrvr4nb.js → location-service-map-xsgpdrvd.js} +40 -40
  206. package/dist/chunks/{location-service-map-xe6vm9p8.js → location-service-map-y1em8rf3.js} +14 -14
  207. package/dist/chunks/{location-service-map-6hjx5zpb.js → location-service-map-y56ehv6b.js} +8 -8
  208. package/dist/chunks/{location-service-map-nqsv03v6.js → location-service-map-ydah9gdn.js} +81 -81
  209. package/dist/chunks/{location-service-map-yhebgegd.js → location-service-map-yfv96e1b.js} +23 -23
  210. package/dist/chunks/{location-service-map-cakf0m7d.js → location-service-map-ykw935pc.js} +28 -28
  211. package/dist/chunks/{location-service-map-0bztnv55.js → location-service-map-yytnj0xn.js} +15 -15
  212. package/dist/chunks/{location-service-map-dkpnw212.js → location-service-map-z029qf89.js} +7 -7
  213. package/dist/chunks/{location-service-map-npgv39fj.js → location-service-map-z186befd.js} +1 -1
  214. package/dist/chunks/{location-service-map-c7s5xd0e.js → location-service-map-z1zdzsfj.js} +37 -37
  215. package/dist/chunks/{location-service-map-kxssyy3x.js → location-service-map-z2dcak32.js} +30 -30
  216. package/dist/chunks/{location-service-map-d04ep358.js → location-service-map-z3507kbh.js} +8 -8
  217. package/dist/chunks/{location-service-map-ayt5007s.js → location-service-map-z37zr1de.js} +4 -4
  218. package/dist/chunks/{location-service-map-rht436q7.js → location-service-map-z5s28eht.js} +14 -14
  219. package/dist/chunks/{location-service-map-9tr2qfdk.js → location-service-map-zcf38hqe.js} +7 -7
  220. package/dist/chunks/{location-service-map-j8ssv6es.js → location-service-map-zh94prq5.js} +10 -10
  221. package/dist/chunks/{location-service-map-3b16v5tt.js → location-service-map-zjtrsxny.js} +3 -3
  222. package/dist/chunks/{location-service-map-c87q280n.js → location-service-map-zx2dwjq0.js} +3 -3
  223. package/dist/codemode/instructions.js +6 -6
  224. package/dist/command.js +70 -70
  225. package/dist/config/discovery.js +66 -66
  226. package/dist/config/normalize.js +75 -75
  227. package/dist/config/plugin/agent.js +88 -88
  228. package/dist/config/plugin/command.js +166 -166
  229. package/dist/config/plugin/compaction.js +120 -120
  230. package/dist/config/plugin/compatibility.js +102 -102
  231. package/dist/config/plugin/formatter.js +89 -89
  232. package/dist/config/plugin/image.js +88 -88
  233. package/dist/config/plugin/instruction.js +89 -89
  234. package/dist/config/plugin/location-watcher.js +90 -90
  235. package/dist/config/plugin/mcp.js +95 -95
  236. package/dist/config/plugin/policy.js +88 -88
  237. package/dist/config/plugin/provider.js +88 -88
  238. package/dist/config/plugin/reference.js +89 -89
  239. package/dist/config/plugin/shell.js +90 -90
  240. package/dist/config/plugin/skill-file.js +78 -78
  241. package/dist/config/plugin/skill.js +105 -105
  242. package/dist/config/plugin/snapshot.js +88 -88
  243. package/dist/config/plugin/source.js +91 -91
  244. package/dist/config/plugin/tool-output.js +88 -88
  245. package/dist/config/plugin/websearch.js +89 -89
  246. package/dist/config/plugin/worktree.js +89 -89
  247. package/dist/config.js +90 -90
  248. package/dist/credential.js +71 -71
  249. package/dist/database/database.js +57 -57
  250. package/dist/database/drizzle/effect-sqlite/driver.js +10 -10
  251. package/dist/database/drizzle/effect-sqlite/index.js +6 -6
  252. package/dist/database/drizzle/effect-sqlite/session.js +7 -7
  253. package/dist/database/drizzle/index.js +11 -11
  254. package/dist/database/drizzle/sqlite-core/effect/db.js +5 -5
  255. package/dist/database/drizzle/sqlite-core/effect/index.js +2 -2
  256. package/dist/database/drizzle/sqlite-core/effect/session.js +6 -6
  257. package/dist/database/drizzle.js +11 -11
  258. package/dist/database/migration.gen.js +40 -40
  259. package/dist/database/migration.js +42 -42
  260. package/dist/database/v1-migration.bun.js +9 -9
  261. package/dist/effect/app-node-builder.js +228 -228
  262. package/dist/effect/keyed-mutex.js +3 -3
  263. package/dist/environment/environment.js +70 -70
  264. package/dist/environment/index.js +70 -70
  265. package/dist/event-logger.js +10 -10
  266. package/dist/file-access.js +79 -79
  267. package/dist/file-mutation.js +71 -71
  268. package/dist/filesystem/location-watcher-policy.js +5 -5
  269. package/dist/filesystem/location-watcher.js +181 -181
  270. package/dist/filesystem/protected.js +3 -3
  271. package/dist/filesystem/search.js +79 -79
  272. package/dist/filesystem/watcher.js +11 -11
  273. package/dist/filesystem.js +82 -82
  274. package/dist/form.js +68 -68
  275. package/dist/formatter/builtins.js +3 -3
  276. package/dist/formatter.js +66 -66
  277. package/dist/generate.js +80 -80
  278. package/dist/git.js +2 -2
  279. package/dist/github-copilot/chat/openai-compatible-chat-language-model.js +4 -4
  280. package/dist/github-copilot/copilot-provider.js +3 -3
  281. package/dist/github-copilot/models.js +78 -78
  282. package/dist/github-copilot/responses/openai-responses-language-model.js +7 -7
  283. package/dist/github-copilot/responses/openai-responses-prepare-tools.js +4 -4
  284. package/dist/image/photon.js +1 -1
  285. package/dist/image.js +5 -5
  286. package/dist/instance/service.js +5 -5
  287. package/dist/instance.js +308 -308
  288. package/dist/instruction-discovery.js +69 -69
  289. package/dist/instructions/builtins.js +69 -69
  290. package/dist/instructions/index.js +3 -3
  291. package/dist/integration/connection.js +3 -3
  292. package/dist/integration.js +74 -74
  293. package/dist/job.js +66 -66
  294. package/dist/kv.js +62 -62
  295. package/dist/location-activity.js +52 -52
  296. package/dist/location-lifecycle.js +84 -84
  297. package/dist/location-service-map.js +68 -68
  298. package/dist/location-services.js +305 -305
  299. package/dist/location.js +63 -63
  300. package/dist/managed-policy.js +5 -5
  301. package/dist/mcp/client.js +25 -18
  302. package/dist/mcp/index.js +82 -82
  303. package/dist/mcp/instructions.js +102 -102
  304. package/dist/mcp/oauth.js +14 -14
  305. package/dist/mcp/stdio.js +67 -67
  306. package/dist/modal/models.js +78 -78
  307. package/dist/model-resolver.js +77 -77
  308. package/dist/model.js +79 -79
  309. package/dist/models-dev.js +85 -85
  310. package/dist/permission/saved.js +66 -66
  311. package/dist/permission.js +86 -86
  312. package/dist/persistent-pty/index.js +75 -75
  313. package/dist/persistent-pty.js +61 -61
  314. package/dist/plugin/agent.js +63 -63
  315. package/dist/plugin/command.js +77 -77
  316. package/dist/plugin/hooks.js +5 -5
  317. package/dist/plugin/host.js +172 -172
  318. package/dist/plugin/identity.js +3 -3
  319. package/dist/plugin/instance.js +5 -5
  320. package/dist/plugin/internal.js +281 -281
  321. package/dist/plugin/mcp-codemode-defaults.js +3 -3
  322. package/dist/plugin/models-dev.js +74 -74
  323. package/dist/plugin/module.js +88 -88
  324. package/dist/plugin/optimize.js +3 -3
  325. package/dist/plugin/plan.js +79 -79
  326. package/dist/plugin/provider/amazon-bedrock.js +69 -69
  327. package/dist/plugin/provider/azure.js +89 -89
  328. package/dist/plugin/provider/chatgpt.js +87 -87
  329. package/dist/plugin/provider/cloudflare-ai-gateway.js +86 -86
  330. package/dist/plugin/provider/cloudflare-workers-ai.js +86 -86
  331. package/dist/plugin/provider/configured.js +85 -85
  332. package/dist/plugin/provider/digitalocean.js +71 -71
  333. package/dist/plugin/provider/github-copilot.js +73 -73
  334. package/dist/plugin/provider/gitlab.js +71 -71
  335. package/dist/plugin/provider/google-vertex.js +86 -86
  336. package/dist/plugin/provider/llmgateway.js +65 -65
  337. package/dist/plugin/provider/lmstudio.js +96 -96
  338. package/dist/plugin/provider/local.js +93 -93
  339. package/dist/plugin/provider/modal.js +71 -71
  340. package/dist/plugin/provider/ollama.js +94 -94
  341. package/dist/plugin/provider/openai.js +89 -89
  342. package/dist/plugin/provider/opencode.js +74 -74
  343. package/dist/plugin/provider/openrouter.js +70 -70
  344. package/dist/plugin/provider/poe.js +65 -65
  345. package/dist/plugin/provider/sap-ai-core.js +69 -69
  346. package/dist/plugin/provider/snowflake-cortex.js +87 -87
  347. package/dist/plugin/provider/vercel.js +69 -69
  348. package/dist/plugin/provider/vllm.js +96 -96
  349. package/dist/plugin/provider/xai.js +70 -70
  350. package/dist/plugin/provider.js +130 -130
  351. package/dist/plugin/sdk.js +66 -66
  352. package/dist/plugin/service.js +3 -3
  353. package/dist/plugin/skill.js +103 -103
  354. package/dist/plugin/supervisor.js +299 -299
  355. package/dist/plugin/tool-input-repair.js +3 -3
  356. package/dist/plugin/update.js +6 -6
  357. package/dist/plugin/vcs/git.js +67 -67
  358. package/dist/plugin/vcs/hg.js +67 -67
  359. package/dist/plugin/verbosity.js +72 -72
  360. package/dist/plugin/warming.js +87 -87
  361. package/dist/plugin/websearch/exa.js +6 -6
  362. package/dist/plugin/websearch/firecrawl.js +7 -7
  363. package/dist/plugin/websearch/index.js +8 -8
  364. package/dist/plugin/websearch/mcp.js +3 -3
  365. package/dist/plugin/websearch/parallel.js +7 -7
  366. package/dist/plugin/websearch/tavily.js +6 -6
  367. package/dist/plugin/websearch/tinyfish.js +7 -7
  368. package/dist/plugin.js +185 -185
  369. package/dist/project.js +62 -62
  370. package/dist/provider.js +78 -78
  371. package/dist/pty.js +79 -79
  372. package/dist/reference/instructions.js +72 -72
  373. package/dist/reference.js +74 -74
  374. package/dist/repository-cache.js +63 -63
  375. package/dist/ripgrep.js +73 -73
  376. package/dist/rpc.js +68 -68
  377. package/dist/session/command.js +63 -63
  378. package/dist/session/compaction.js +107 -107
  379. package/dist/session/context.js +123 -123
  380. package/dist/session/diff.js +67 -67
  381. package/dist/session/environment.js +5 -5
  382. package/dist/session/error.js +2 -2
  383. package/dist/session/execution/restart.js +103 -103
  384. package/dist/session/execution.js +98 -98
  385. package/dist/session/generate.js +124 -124
  386. package/dist/session/history.js +6 -6
  387. package/dist/session/inbox.js +68 -68
  388. package/dist/session/info.js +2 -2
  389. package/dist/session/instruction-entry.js +63 -63
  390. package/dist/session/instruction-state.js +2 -2
  391. package/dist/session/instructions.js +76 -76
  392. package/dist/session/model-request.js +96 -96
  393. package/dist/session/model-transport.js +7 -7
  394. package/dist/session/move.js +100 -100
  395. package/dist/session/projector.js +68 -68
  396. package/dist/session/prompt.js +82 -82
  397. package/dist/session/provider-context.js +3 -3
  398. package/dist/session/revert.js +68 -68
  399. package/dist/session/runner/index.js +3 -3
  400. package/dist/session/runner/llm.js +182 -182
  401. package/dist/session/runner/model.js +73 -73
  402. package/dist/session/runner/publish-llm-event.js +87 -87
  403. package/dist/session/runner/step.js +98 -98
  404. package/dist/session/runner/to-llm-message.js +2 -2
  405. package/dist/session/schema.js +5 -5
  406. package/dist/session/session.js +130 -130
  407. package/dist/session/shell.js +100 -100
  408. package/dist/session/skill.js +80 -80
  409. package/dist/session/stats.js +8 -8
  410. package/dist/session/store.js +69 -69
  411. package/dist/session/subagent-job.js +166 -166
  412. package/dist/session/title.js +126 -126
  413. package/dist/session/to-session-error.js +86 -86
  414. package/dist/session/transfer.js +97 -97
  415. package/dist/session.js +171 -171
  416. package/dist/shell/parse.js +2 -2
  417. package/dist/shell/select.js +11 -11
  418. package/dist/shell.js +103 -103
  419. package/dist/skill/discovery.js +5 -5
  420. package/dist/skill/instructions.js +84 -84
  421. package/dist/skill.js +89 -89
  422. package/dist/snapshot.js +68 -68
  423. package/dist/tool/mcp.js +101 -101
  424. package/dist/tool/plugin/edit.js +86 -86
  425. package/dist/tool/plugin/glob.js +95 -95
  426. package/dist/tool/plugin/grep.js +97 -97
  427. package/dist/tool/plugin/mcp-resource.js +90 -90
  428. package/dist/tool/plugin/opencode.js +84 -84
  429. package/dist/tool/plugin/patch.js +94 -94
  430. package/dist/tool/plugin/question.js +82 -82
  431. package/dist/tool/plugin/read.js +98 -98
  432. package/dist/tool/plugin/shell.js +172 -172
  433. package/dist/tool/plugin/skill.js +88 -88
  434. package/dist/tool/plugin/subagent.js +173 -173
  435. package/dist/tool/plugin/webfetch.js +87 -87
  436. package/dist/tool/plugin/websearch.js +90 -90
  437. package/dist/tool/plugin/write.js +94 -94
  438. package/dist/tool/read-filesystem.js +76 -76
  439. package/dist/tool-output.js +5 -5
  440. package/dist/tool.js +11 -11
  441. package/dist/v1/config/agent.js +3 -3
  442. package/dist/v1/config/mcp.js +3 -3
  443. package/dist/v1/config/migrate.js +70 -70
  444. package/dist/v1/config/plugin.js +3 -3
  445. package/dist/v1/config/provider.js +3 -3
  446. package/dist/variant.js +70 -70
  447. package/dist/vcs.js +70 -70
  448. package/dist/websearch.js +72 -72
  449. package/dist/wellknown/plugin.js +65 -65
  450. package/dist/wellknown.js +70 -70
  451. package/dist/workspace/driver.js +3 -3
  452. package/dist/workspace.js +70 -70
  453. package/dist/worktree/git.js +3 -3
  454. package/dist/worktree/strategies.js +69 -69
  455. package/dist/worktree.js +75 -75
  456. package/package.json +8 -8
  457. package/dist/chunks/location-service-map-1g906he0.js +0 -26
  458. package/dist/chunks/location-service-map-asevcyq5.js +0 -253
  459. package/dist/chunks/location-service-map-v2exr8cw.js +0 -513
  460. /package/dist/chunks/{location-service-map-t4jzmwkk.js → location-service-map-3z39tkdq.js} +0 -0
  461. /package/dist/chunks/{location-service-map-s6a94ykt.js → location-service-map-44asg7d3.js} +0 -0
  462. /package/dist/chunks/{location-service-map-btec747f.js → location-service-map-b7v4cx43.js} +0 -0
  463. /package/dist/chunks/{location-service-map-jxr5ks98.js → location-service-map-pd14fbdd.js} +0 -0
@@ -1,37 +1,28 @@
1
1
  import {
2
2
  Service84,
3
3
  node88
4
- } from "./location-service-map-t7n4d1yf.js";
4
+ } from "./location-service-map-s2t00s75.js";
5
5
  import {
6
6
  shutdown2,
7
7
  create3
8
8
  } from "./location-service-map-rdw6cm16.js";
9
9
  import {
10
10
  key2
11
- } from "./location-service-map-x661k3y3.js";
11
+ } from "./location-service-map-addxnjmp.js";
12
12
  import {
13
- ID13,
14
- Service72,
15
- node75,
16
- Event17
17
- } from "./location-service-map-bjkg2ks4.js";
13
+ ID14,
14
+ Service78,
15
+ node82,
16
+ Event18
17
+ } from "./location-service-map-dbd4bcxh.js";
18
18
  import {
19
19
  Service81,
20
20
  node85
21
- } from "./location-service-map-0fzbfnq7.js";
21
+ } from "./location-service-map-8z12w5mn.js";
22
22
  import {
23
23
  __export
24
24
  } from "./location-service-map-9rqn6x4v.js";
25
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 as Option2, Schema as Schema2, Struct as Struct2 } from "effect";
34
-
35
26
  // src/provider.ts
36
27
  var exports_provider3 = {};
37
28
  __export(exports_provider3, {
@@ -39,13 +30,13 @@ __export(exports_provider3, {
39
30
  Compaction: () => Compaction3,
40
31
  DEFAULT_CHUNK_TIMEOUT_MS: () => DEFAULT_CHUNK_TIMEOUT_MS2,
41
32
  DEFAULT_TIMEOUT_MS: () => DEFAULT_TIMEOUT_MS3,
42
- Event: () => Event16,
43
- ID: () => ID12,
44
- Info: () => Info21,
33
+ Event: () => Event17,
34
+ ID: () => ID13,
35
+ Info: () => Info22,
45
36
  LoadError: () => LoadError3,
46
37
  Provider: () => exports_provider3,
47
38
  Request: () => Request3,
48
- Service: () => Service71,
39
+ Service: () => Service77,
49
40
  Settings: () => Settings2,
50
41
  Transport: () => Transport2,
51
42
  aisdk: () => aisdk2,
@@ -56,12 +47,12 @@ __export(exports_provider3, {
56
47
  mergeOverlay: () => mergeOverlay2,
57
48
  modelSettings: () => modelSettings2,
58
49
  nativeSettings: () => nativeSettings2,
59
- node: () => node74,
50
+ node: () => node81,
60
51
  packageName: () => packageName2,
61
52
  timeout: () => timeout2,
62
53
  timeouts: () => timeouts2
63
54
  });
64
- import { Context, Effect, Layer, Option, Schema, Stream, Struct } from "effect";
55
+ import { Context, Effect as Effect2, Layer, Option as Option2, Schema as Schema2, Stream, Struct as Struct2 } from "effect";
65
56
  import { Provider } from "@opencode/schema/provider";
66
57
  import { Model } from "@opencode/schema/model";
67
58
  import { makeLocationNode } from "@opencode/util/effect/app-node";
@@ -70,8 +61,273 @@ import { isRecord } from "@opencode/ai/utils/record";
70
61
  import { importModule, resolveModule } from "@opencode/util/runtime-import";
71
62
  import { Credential } from "@opencode/schema/credential";
72
63
  import { freeze } from "immer";
73
- import { Event as Event16 } from "@opencode/schema/provider";
74
- var ID12 = Provider.ID;
64
+
65
+ // src/aisdk-native.ts
66
+ var exports_aisdk_native = {};
67
+ __export(exports_aisdk_native, {
68
+ AISDKNative: () => exports_aisdk_native,
69
+ native: () => native2,
70
+ rewrite: () => rewrite2
71
+ });
72
+ import { Effect, Option, Schema, Struct } from "effect";
73
+ function rewrite2(target, input) {
74
+ if (input.specifier === undefined)
75
+ return;
76
+ const plain = resolve(input.specifier, input);
77
+ if (!plain)
78
+ return;
79
+ const settings = decode(target.settings ?? {});
80
+ const replacement = resolve(input.specifier, { ...input, settings }) ?? plain;
81
+ const translated = options(replacement, input.modelID, settings);
82
+ if (target.package !== undefined || replacement !== input.specifier)
83
+ target.package = replacement;
84
+ target.settings = target.settings === undefined ? undefined : {
85
+ ...translated.settings,
86
+ ...!NATIVE.has(input.specifier) && replacement === "@opencode/ai/providers/openai-compatible" ? { provider: input.canonical ?? input.providerID } : {}
87
+ };
88
+ target.headers = mergeHeaders2(translated.headers, target.headers);
89
+ target.body = mergeOverlay2(translated.body, target.body);
90
+ target.variants = target.variants?.map((variant) => {
91
+ const overlay = options(replacement, input.modelID, decode(variant.settings ?? {}));
92
+ const headers = mergeHeaders2(overlay.headers, variant.headers);
93
+ const body = mergeOverlay2(overlay.body, variant.body);
94
+ return {
95
+ id: variant.id,
96
+ ...variant.settings === undefined ? {} : { settings: overlay.settings },
97
+ ...headers === undefined ? {} : { headers },
98
+ ...body === undefined ? {} : { body }
99
+ };
100
+ });
101
+ }
102
+ var PACKAGES = {
103
+ "@ai-sdk/amazon-bedrock": "@opencode/ai/providers/amazon-bedrock",
104
+ "@ai-sdk/alibaba": "@opencode/ai/providers/alibaba/chat",
105
+ "@ai-sdk/anthropic": "@opencode/ai/providers/anthropic",
106
+ "@ai-sdk/azure": "@opencode/ai/providers/azure/responses",
107
+ "@ai-sdk/cerebras": "@opencode/ai/providers/cerebras",
108
+ "@ai-sdk/cohere": "@opencode/ai/providers/cohere",
109
+ "@ai-sdk/deepinfra": "@opencode/ai/providers/deepinfra",
110
+ "@ai-sdk/google": "@opencode/ai/providers/google",
111
+ "@ai-sdk/google-vertex": "@opencode/ai/providers/google-vertex",
112
+ "@ai-sdk/google-vertex/anthropic": "@opencode/ai/providers/google-vertex/messages",
113
+ "@ai-sdk/groq": "@opencode/ai/providers/groq",
114
+ "@ai-sdk/mistral": "@opencode/ai/providers/mistral",
115
+ "@ai-sdk/openai": "@opencode/ai/providers/openai",
116
+ "@ai-sdk/openai-compatible": "@opencode/ai/providers/openai-compatible",
117
+ "@ai-sdk/togetherai": "@opencode/ai/providers/togetherai",
118
+ "@ai-sdk/xai": "@opencode/ai/providers/xai",
119
+ "@ai-sdk/gateway": "@opencode/ai/providers/vercel-ai-gateway",
120
+ "@openrouter/ai-sdk-provider": "@opencode/ai/providers/openrouter",
121
+ "ai-gateway-provider": "@opencode/ai/providers/cloudflare-ai-gateway",
122
+ "venice-ai-sdk-provider": "@opencode/ai/providers/venice"
123
+ };
124
+ var protocols = (name) => ({
125
+ "@ai-sdk/openai-compatible": `@opencode/ai/providers/${name}/chat`,
126
+ "@ai-sdk/anthropic": `@opencode/ai/providers/${name}/messages`,
127
+ "@ai-sdk/openai": `@opencode/ai/providers/${name}/responses`
128
+ });
129
+ var HOSTS = {
130
+ alibaba: protocols("alibaba"),
131
+ "alibaba-cn": protocols("alibaba"),
132
+ "alibaba-coding-plan": protocols("alibaba"),
133
+ "alibaba-coding-plan-cn": protocols("alibaba"),
134
+ "alibaba-token-plan": protocols("alibaba"),
135
+ "alibaba-token-plan-cn": protocols("alibaba"),
136
+ baseten: { "@ai-sdk/openai-compatible": "@opencode/ai/providers/baseten" },
137
+ "cloudflare-ai-gateway": {
138
+ "@ai-sdk/anthropic": "@opencode/ai/providers/cloudflare-ai-gateway",
139
+ "@ai-sdk/openai": "@opencode/ai/providers/cloudflare-ai-gateway",
140
+ "@ai-sdk/openai-compatible": "@opencode/ai/providers/cloudflare-ai-gateway",
141
+ "ai-gateway-provider": "@opencode/ai/providers/cloudflare-ai-gateway"
142
+ },
143
+ cohere: { "@ai-sdk/openai-compatible": "@opencode/ai/providers/cohere/chat" },
144
+ "cloudflare-workers-ai": { "@ai-sdk/openai-compatible": "@opencode/ai/providers/cloudflare-workers-ai" },
145
+ deepseek: { "@ai-sdk/openai-compatible": "@opencode/ai/providers/deepseek" },
146
+ digitalocean: { "@ai-sdk/openai-compatible": "@opencode/ai/providers/digitalocean" },
147
+ "fireworks-ai": { "@ai-sdk/openai-compatible": "@opencode/ai/providers/fireworks" },
148
+ "google-vertex": {
149
+ "@ai-sdk/openai-compatible": "@opencode/ai/providers/google-vertex/chat",
150
+ "@ai-sdk/mistral": "@opencode/ai/providers/google-vertex/mistral"
151
+ },
152
+ "kimi-for-coding": protocols("moonshot"),
153
+ meta: protocols("meta"),
154
+ minimax: protocols("minimax"),
155
+ "minimax-cn": protocols("minimax"),
156
+ "minimax-coding-plan": protocols("minimax"),
157
+ "minimax-cn-coding-plan": protocols("minimax"),
158
+ moonshotai: protocols("moonshot"),
159
+ "moonshotai-cn": protocols("moonshot"),
160
+ zai: { "@ai-sdk/openai-compatible": "@opencode/ai/providers/zai/chat" },
161
+ "zai-coding-plan": protocols("zai-coding-plan"),
162
+ zhipuai: { "@ai-sdk/openai-compatible": "@opencode/ai/providers/zai/chat" },
163
+ "zhipuai-coding-plan": protocols("zai-coding-plan")
164
+ };
165
+ var NATIVE = new Set([
166
+ ...Object.values(PACKAGES),
167
+ ...Object.values(HOSTS).flatMap((host) => Object.values(host)),
168
+ "@opencode/ai/providers/azure/chat",
169
+ "@opencode/ai/providers/amazon-bedrock/mantle",
170
+ "@opencode/ai/providers/amazon-bedrock/mantle/chat",
171
+ "@opencode/ai/providers/amazon-bedrock/mantle/responses"
172
+ ]);
173
+ function native2(npm, context) {
174
+ const host = HOSTS[context.providerID]?.[npm];
175
+ if (host)
176
+ return host;
177
+ if (npm === "@ai-sdk/amazon-bedrock/mantle")
178
+ return mantle(context.modelID);
179
+ if (npm === "@ai-sdk/azure" && azureChat(context))
180
+ return "@opencode/ai/providers/azure/chat";
181
+ return PACKAGES[npm];
182
+ }
183
+ var azureChat = (context) => context.shape === "completions" || context.settings?.useCompletionUrls === true;
184
+ var mantle = (modelID) => {
185
+ if (modelID === undefined)
186
+ return "@opencode/ai/providers/amazon-bedrock/mantle";
187
+ return `@opencode/ai/providers/amazon-bedrock/mantle/${modelID.includes("gpt-oss") ? "chat" : "responses"}`;
188
+ };
189
+ function resolve(specifier, context) {
190
+ const npm = packageName2(specifier);
191
+ if (isAISDK2(specifier) || npm in PACKAGES || npm in (HOSTS[context.providerID] ?? {}))
192
+ return native2(npm, context);
193
+ if (npm === "@opencode/ai/providers/amazon-bedrock/mantle")
194
+ return mantle(context.modelID);
195
+ if (npm === "@opencode/ai/providers/azure/responses" && azureChat(context))
196
+ return "@opencode/ai/providers/azure/chat";
197
+ return NATIVE.has(npm) ? npm : undefined;
198
+ }
199
+ function options(replacement, modelID, settings) {
200
+ const converse = replacement === "@opencode/ai/providers/amazon-bedrock" && modelID !== undefined;
201
+ const kept = Struct.omit(settings, ["headers", "extraBody", "useCompletionUrls", ...OPENROUTER_KEYS]);
202
+ const thinking = converse ? bedrockThinking(modelID, settings) : undefined;
203
+ return {
204
+ settings: {
205
+ ...replacement.startsWith("@opencode/ai/providers/amazon-bedrock") ? bedrockSettings(kept, converse) : kept,
206
+ ...thinking === undefined ? {} : { thinking }
207
+ },
208
+ ...settings.headers === undefined ? {} : { headers: settings.headers },
209
+ ...settings.extraBody === undefined ? {} : { body: settings.extraBody },
210
+ ...converse ? bedrockRequest(modelID, settings) : {},
211
+ ...replacement === "@opencode/ai/providers/openrouter" ? openRouterRequest(settings) : {}
212
+ };
213
+ }
214
+ var BEDROCK_KEYS = [
215
+ "bearerToken",
216
+ "endpoint",
217
+ "credentials",
218
+ "credentialProvider",
219
+ "accessKeyId",
220
+ "secretAccessKey",
221
+ "sessionToken"
222
+ ];
223
+ var CONVERSE_KEYS = ["additionalModelRequestFields", "reasoningConfig", "anthropicBeta", "serviceTier"];
224
+ function bedrockSettings(settings, converse) {
225
+ const region = settings.region ?? settings.credentials?.region;
226
+ const credentials = settings.credentials ?? settings;
227
+ const baseURL = settings.baseURL ?? settings.endpoint;
228
+ return {
229
+ ...Struct.omit(settings, converse ? [...BEDROCK_KEYS, ...CONVERSE_KEYS] : BEDROCK_KEYS),
230
+ ...baseURL === undefined ? {} : { baseURL: region === undefined ? baseURL : baseURL.replaceAll("${AWS_REGION}", region) },
231
+ ...settings.apiKey === undefined && settings.bearerToken !== undefined ? { apiKey: settings.bearerToken } : {},
232
+ ...credentials.accessKeyId === undefined || credentials.secretAccessKey === undefined ? {} : {
233
+ credentials: {
234
+ ...region === undefined ? {} : { region },
235
+ accessKeyId: credentials.accessKeyId,
236
+ secretAccessKey: credentials.secretAccessKey,
237
+ ...credentials.sessionToken === undefined ? {} : { sessionToken: credentials.sessionToken }
238
+ }
239
+ }
240
+ };
241
+ }
242
+ function bedrockThinking(modelID, settings) {
243
+ const reasoning = settings.reasoningConfig;
244
+ if (!modelID?.includes("anthropic") || reasoning?.type !== "enabled" || reasoning.budgetTokens === undefined)
245
+ return;
246
+ return { type: "enabled", budgetTokens: reasoning.budgetTokens };
247
+ }
248
+ function bedrockRequest(modelID, settings) {
249
+ const additional = settings.additionalModelRequestFields ?? {};
250
+ const reasoning = settings.reasoningConfig;
251
+ const anthropic = modelID?.includes("anthropic") ?? false;
252
+ const openai = modelID?.includes("openai.") ?? false;
253
+ const harmony = modelID?.includes("openai.gpt-oss") ?? false;
254
+ const effort = reasoning?.maxReasoningEffort;
255
+ const type = reasoning?.type;
256
+ const budget = reasoning?.budgetTokens;
257
+ const display = reasoning?.display;
258
+ const betas = settings.anthropicBeta ?? [];
259
+ const fields = mergeOverlay2(additional, {
260
+ ...betas.length > 0 ? { anthropic_beta: [...additional.anthropic_beta ?? [], ...betas] } : {},
261
+ ...anthropic && type === "adaptive" ? { thinking: { type: "adaptive", ...display === undefined ? {} : { display } } } : {},
262
+ ...anthropic && effort !== undefined ? { output_config: { ...additional.output_config, effort } } : {},
263
+ ...!anthropic && openai && harmony && effort !== undefined ? { reasoning_effort: effort } : {},
264
+ ...!anthropic && openai && !harmony && effort !== undefined ? { reasoning: { ...additional.reasoning, effort } } : {},
265
+ ...!anthropic && !openai && effort !== undefined ? {
266
+ reasoningConfig: {
267
+ ...type === undefined || type === "adaptive" ? {} : { type },
268
+ ...budget === undefined ? {} : { budgetTokens: budget },
269
+ maxReasoningEffort: effort
270
+ }
271
+ } : {}
272
+ });
273
+ const body = {
274
+ ...fields && Object.keys(fields).length > 0 ? { additionalModelRequestFields: fields } : {},
275
+ ...settings.serviceTier === undefined ? {} : { serviceTier: { type: settings.serviceTier } }
276
+ };
277
+ return Object.keys(body).length === 0 ? {} : { body };
278
+ }
279
+ var OPENROUTER_KEYS = ["appName", "appUrl", "api_keys", "compatibility"];
280
+ function openRouterRequest(settings) {
281
+ const headers = mergeHeaders2({
282
+ ...settings.appName === undefined ? {} : { "X-OpenRouter-Title": settings.appName },
283
+ ...settings.appUrl === undefined ? {} : { "HTTP-Referer": settings.appUrl },
284
+ ...settings.api_keys === undefined || Object.keys(settings.api_keys).length === 0 ? {} : { "X-Provider-API-Keys": JSON.stringify(settings.api_keys) }
285
+ }, settings.headers) ?? {};
286
+ return Object.keys(headers).length === 0 ? {} : { headers };
287
+ }
288
+ var lenient = (schema) => Schema.optional(Schema.UndefinedOr(schema).pipe(Schema.catchDecoding(() => Effect.succeed(Option.some(undefined)))));
289
+ var Credentials = Schema.Struct({
290
+ accessKeyId: Schema.String,
291
+ secretAccessKey: Schema.String,
292
+ sessionToken: lenient(Schema.String),
293
+ region: lenient(Schema.String)
294
+ });
295
+ var Legacy = Schema.StructWithRest(Schema.Struct({
296
+ apiKey: lenient(Schema.String),
297
+ baseURL: lenient(Schema.String),
298
+ headers: lenient(Schema.Record(Schema.String, Schema.String)),
299
+ extraBody: lenient(Schema.Record(Schema.String, Schema.Unknown)),
300
+ useCompletionUrls: lenient(Schema.Boolean),
301
+ auth: lenient(Schema.Literals(["bearer", "sigv4"])),
302
+ bearerToken: lenient(Schema.String),
303
+ endpoint: lenient(Schema.String),
304
+ region: lenient(Schema.String),
305
+ credentials: lenient(Credentials),
306
+ accessKeyId: lenient(Schema.String),
307
+ secretAccessKey: lenient(Schema.String),
308
+ sessionToken: lenient(Schema.String),
309
+ anthropicBeta: lenient(Schema.Array(Schema.String)),
310
+ serviceTier: lenient(Schema.String),
311
+ reasoningConfig: lenient(Schema.Struct({
312
+ type: lenient(Schema.String),
313
+ display: lenient(Schema.String),
314
+ maxReasoningEffort: lenient(Schema.String),
315
+ budgetTokens: lenient(Schema.Number)
316
+ })),
317
+ additionalModelRequestFields: lenient(Schema.StructWithRest(Schema.Struct({
318
+ anthropic_beta: lenient(Schema.Array(Schema.String)),
319
+ output_config: lenient(Schema.Record(Schema.String, Schema.Unknown)),
320
+ reasoning: lenient(Schema.Record(Schema.String, Schema.Unknown))
321
+ }), [Schema.Record(Schema.String, Schema.Unknown)])),
322
+ appName: lenient(Schema.String),
323
+ appUrl: lenient(Schema.String),
324
+ api_keys: lenient(Schema.Record(Schema.String, Schema.String))
325
+ }), [Schema.Record(Schema.String, Schema.Unknown)]);
326
+ var decode = Schema.decodeUnknownSync(Legacy);
327
+
328
+ // src/provider.ts
329
+ import { Event as Event17 } from "@opencode/schema/provider";
330
+ var ID13 = Provider.ID;
75
331
  var AISDK_PREFIX2 = "aisdk:";
76
332
  var isAISDK2 = (value) => value?.startsWith(AISDK_PREFIX2) ?? false;
77
333
  var aisdk2 = (value) => isAISDK2(value) ? value : `${AISDK_PREFIX2}${value}`;
@@ -82,12 +338,12 @@ function packageName2(value) {
82
338
  return value;
83
339
  return value.slice(AISDK_PREFIX2.length);
84
340
  }
85
- var JsonRecord = Schema.Record(Schema.String, Schema.Json);
86
- var decodeJsonRecord = Schema.decodeUnknownSync(JsonRecord);
341
+ var JsonRecord = Schema2.Record(Schema2.String, Schema2.Json);
342
+ var decodeJsonRecord = Schema2.decodeUnknownSync(JsonRecord);
87
343
 
88
- class LoadError3 extends Schema.TaggedError()("Provider.LoadError", {
89
- package: Schema.String,
90
- cause: Schema.Defect()
344
+ class LoadError3 extends Schema2.TaggedError()("Provider.LoadError", {
345
+ package: Schema2.String,
346
+ cause: Schema2.Defect()
91
347
  }) {
92
348
  }
93
349
  var packages = new Map;
@@ -168,12 +424,12 @@ var builtins = new Map([
168
424
  () => import("@opencode/ai/providers/zai-coding-plan/responses")
169
425
  ]
170
426
  ]);
171
- var loadPackage2 = Effect.fn("Provider.loadPackage")(function* (input, npm) {
427
+ var loadPackage2 = Effect2.fn("Provider.loadPackage")(function* (input, npm) {
172
428
  const specifier = packageName2(input);
173
429
  const builtin = builtins.get(specifier);
174
430
  if (builtin)
175
431
  return yield* importPackage(specifier, specifier, builtin);
176
- const resolved = yield* Effect.sync(() => {
432
+ const resolved = yield* Effect2.sync(() => {
177
433
  if (specifier.startsWith("file://") || specifier.startsWith("@opencode/ai/"))
178
434
  return specifier;
179
435
  try {
@@ -192,8 +448,8 @@ var loadPackage2 = Effect.fn("Provider.loadPackage")(function* (input, npm) {
192
448
  }
193
449
  const parts = specifier.split("/");
194
450
  const root = specifier.startsWith("@") ? parts.slice(0, 2).join("/") : parts[0] ?? specifier;
195
- const installed = yield* npm.add(root).pipe(Effect.mapError((cause) => new LoadError3({ package: specifier, cause })));
196
- const entrypoint = yield* Effect.try({
451
+ const installed = yield* npm.add(root).pipe(Effect2.mapError((cause) => new LoadError3({ package: specifier, cause })));
452
+ const entrypoint = yield* Effect2.try({
197
453
  try: () => resolveModule(specifier, installed.directory),
198
454
  catch: (cause) => new LoadError3({ package: specifier, cause })
199
455
  });
@@ -202,16 +458,16 @@ var loadPackage2 = Effect.fn("Provider.loadPackage")(function* (input, npm) {
202
458
  var CORE_KEYS = ["chunkTimeout", "compaction", "encoding", "fetch", "headerTimeout", "timeout", "transport"];
203
459
  var PROVIDER_ONLY_KEYS = ["chunkTimeout", "headerTimeout", "timeout", "transport"];
204
460
  function nativeSettings2(settings) {
205
- return Struct.omit(settings, CORE_KEYS);
461
+ return Struct2.omit(settings, CORE_KEYS);
206
462
  }
207
463
  function modelSettings2(settings) {
208
- return settings && Struct.omit(settings, PROVIDER_ONLY_KEYS);
464
+ return settings && Struct2.omit(settings, PROVIDER_ONLY_KEYS);
209
465
  }
210
- var decodeTimeout = Schema.decodeUnknownOption(HttpTimeout);
466
+ var decodeTimeout = Schema2.decodeUnknownOption(HttpTimeout);
211
467
  var DEFAULT_TIMEOUT_MS3 = 300000;
212
468
  var DEFAULT_CHUNK_TIMEOUT_MS2 = 900000;
213
469
  function timeout2(value) {
214
- return Option.getOrUndefined(decodeTimeout(value));
470
+ return Option2.getOrUndefined(decodeTimeout(value));
215
471
  }
216
472
  function timeouts2(settings) {
217
473
  return {
@@ -220,9 +476,9 @@ function timeouts2(settings) {
220
476
  chunkTimeout: timeout2(settings.chunkTimeout) ?? DEFAULT_CHUNK_TIMEOUT_MS2
221
477
  };
222
478
  }
223
- var decodeEncoding = Schema.decodeUnknownOption(Provider.Encoding);
479
+ var decodeEncoding = Schema2.decodeUnknownOption(Provider.Encoding);
224
480
  function encoding2(settings) {
225
- return Option.getOrUndefined(decodeEncoding(settings.encoding));
481
+ return Option2.getOrUndefined(decodeEncoding(settings.encoding));
226
482
  }
227
483
  function mergeOverlay2(base, overlay) {
228
484
  if (base === undefined)
@@ -253,9 +509,9 @@ var Request3 = Provider.Request;
253
509
  var Compaction3 = Provider.Compaction;
254
510
  var Transport2 = Provider.Transport;
255
511
  var Settings2 = Provider.Settings;
256
- var Info21 = Provider.Info;
512
+ var Info22 = Provider.Info;
257
513
 
258
- class Service71 extends Context.Service()("@opencode/Provider") {
514
+ class Service77 extends Context.Service()("@opencode/Provider") {
259
515
  }
260
516
  var definitions = new WeakMap;
261
517
  function index(providerID, models) {
@@ -268,9 +524,9 @@ function index(providerID, models) {
268
524
  definitions.set(models, indexes);
269
525
  return result;
270
526
  }
271
- var layer = Layer.effect(Service71, Effect.gen(function* () {
527
+ var layer = Layer.effect(Service77, Effect2.gen(function* () {
272
528
  const bus = yield* Service84;
273
- const integrations = yield* Service72;
529
+ const integrations = yield* Service78;
274
530
  const location = yield* Service81;
275
531
  const state = create3({
276
532
  name: "provider",
@@ -282,7 +538,7 @@ var layer = Layer.effect(Service71, Effect.gen(function* () {
282
538
  const current = records.get(id);
283
539
  if (current)
284
540
  return current;
285
- const added = { provider: Info21.empty(id), models: new Map };
541
+ const added = { provider: Info22.empty(id), models: new Map };
286
542
  records.set(id, added);
287
543
  maps.add(added.models);
288
544
  return added;
@@ -350,9 +606,9 @@ var layer = Layer.effect(Service71, Effect.gen(function* () {
350
606
  },
351
607
  notify: () => notify
352
608
  });
353
- yield* Effect.addFinalizer(() => shutdown2(state.reload()));
609
+ yield* Effect2.addFinalizer(() => shutdown2(state.reload()));
354
610
  let cached;
355
- const snapshot = Effect.fn("Provider.snapshot")(function* () {
611
+ const snapshot = Effect2.fn("Provider.snapshot")(function* () {
356
612
  while (true) {
357
613
  const revision = integrations.revision();
358
614
  const records = state.get();
@@ -363,7 +619,7 @@ var layer = Layer.effect(Service71, Effect.gen(function* () {
363
619
  const available = Array.from(records.values()).filter((record) => {
364
620
  if (record.provider.activation === "disabled")
365
621
  return false;
366
- const integration = byID.get(record.provider.integrationID ?? ID13.make(record.provider.id));
622
+ const integration = byID.get(record.provider.integrationID ?? ID14.make(record.provider.id));
367
623
  if (record.sourceConnection && key2(record.sourceConnection) !== key2(integration?.connections[0]))
368
624
  return false;
369
625
  if (record.provider.activation === "enabled")
@@ -380,7 +636,7 @@ var layer = Layer.effect(Service71, Effect.gen(function* () {
380
636
  }
381
637
  });
382
638
  let published;
383
- const notify = Effect.gen(function* () {
639
+ const notify = Effect2.gen(function* () {
384
640
  const value = yield* snapshot();
385
641
  if (value === published)
386
642
  return;
@@ -389,19 +645,19 @@ var layer = Layer.effect(Service71, Effect.gen(function* () {
389
645
  location: { directory: location.directory, workspaceID: location.workspaceID }
390
646
  });
391
647
  });
392
- yield* bus.subscribe([Event17.Updated, Credential.Event.Updated, Credential.Event.Switched]).pipe(Stream.runForEach(() => notify), Effect.forkScoped({ startImmediately: true }));
393
- return Service71.of({
648
+ yield* bus.subscribe([Event18.Updated, Credential.Event.Updated, Credential.Event.Switched]).pipe(Stream.runForEach(() => notify), Effect2.forkScoped({ startImmediately: true }));
649
+ return Service77.of({
394
650
  transform: state.transform,
395
651
  reload: state.reload,
396
- get: Effect.fn("Provider.get")((id) => Effect.sync(() => freeze(state.get().get(id)?.provider, true))),
397
- all: Effect.fn("Provider.all")(() => Effect.sync(() => Array.from(state.get().values(), (record) => freeze(record.provider, true)))),
398
- available: Effect.fn("Provider.available")(() => snapshot().pipe(Effect.map((value) => value.providers))),
652
+ get: Effect2.fn("Provider.get")((id) => Effect2.sync(() => freeze(state.get().get(id)?.provider, true))),
653
+ all: Effect2.fn("Provider.all")(() => Effect2.sync(() => Array.from(state.get().values(), (record) => freeze(record.provider, true)))),
654
+ available: Effect2.fn("Provider.available")(() => snapshot().pipe(Effect2.map((value) => value.providers))),
399
655
  snapshot
400
656
  });
401
657
  }));
402
- var node74 = makeLocationNode({ service: Service71, layer, deps: [node88, node75, node85] });
403
- var importPackage = Effect.fn("Provider.importPackage")(function* (specifier, entrypoint, load = () => importModule(entrypoint)) {
404
- const module = yield* Effect.tryPromise({
658
+ var node81 = makeLocationNode({ service: Service77, layer, deps: [node88, node82, node85] });
659
+ var importPackage = Effect2.fn("Provider.importPackage")(function* (specifier, entrypoint, load = () => importModule(entrypoint)) {
660
+ const module = yield* Effect2.tryPromise({
405
661
  try: () => {
406
662
  const existing = packages.get(entrypoint);
407
663
  if (existing)
@@ -421,260 +677,4 @@ var importPackage = Effect.fn("Provider.importPackage")(function* (specifier, en
421
677
  return module;
422
678
  });
423
679
 
424
- // src/aisdk-native.ts
425
- function rewrite2(target, input) {
426
- if (input.specifier === undefined)
427
- return;
428
- const plain = resolve(input.specifier, input);
429
- if (!plain)
430
- return;
431
- const settings = decode(target.settings ?? {});
432
- const replacement = resolve(input.specifier, { ...input, settings }) ?? plain;
433
- const translated = options(replacement, input.modelID, settings);
434
- if (target.package !== undefined || replacement !== input.specifier)
435
- target.package = replacement;
436
- target.settings = target.settings === undefined ? undefined : {
437
- ...translated.settings,
438
- ...!NATIVE.has(input.specifier) && replacement === "@opencode/ai/providers/openai-compatible" ? { provider: input.canonical ?? input.providerID } : {}
439
- };
440
- target.headers = mergeHeaders2(translated.headers, target.headers);
441
- target.body = mergeOverlay2(translated.body, target.body);
442
- target.variants = target.variants?.map((variant) => {
443
- const overlay = options(replacement, input.modelID, decode(variant.settings ?? {}));
444
- const headers = mergeHeaders2(overlay.headers, variant.headers);
445
- const body = mergeOverlay2(overlay.body, variant.body);
446
- return {
447
- id: variant.id,
448
- ...variant.settings === undefined ? {} : { settings: overlay.settings },
449
- ...headers === undefined ? {} : { headers },
450
- ...body === undefined ? {} : { body }
451
- };
452
- });
453
- }
454
- var PACKAGES = {
455
- "@ai-sdk/amazon-bedrock": "@opencode/ai/providers/amazon-bedrock",
456
- "@ai-sdk/alibaba": "@opencode/ai/providers/alibaba/chat",
457
- "@ai-sdk/anthropic": "@opencode/ai/providers/anthropic",
458
- "@ai-sdk/azure": "@opencode/ai/providers/azure/responses",
459
- "@ai-sdk/cerebras": "@opencode/ai/providers/cerebras",
460
- "@ai-sdk/cohere": "@opencode/ai/providers/cohere",
461
- "@ai-sdk/deepinfra": "@opencode/ai/providers/deepinfra",
462
- "@ai-sdk/google": "@opencode/ai/providers/google",
463
- "@ai-sdk/google-vertex": "@opencode/ai/providers/google-vertex",
464
- "@ai-sdk/google-vertex/anthropic": "@opencode/ai/providers/google-vertex/messages",
465
- "@ai-sdk/groq": "@opencode/ai/providers/groq",
466
- "@ai-sdk/mistral": "@opencode/ai/providers/mistral",
467
- "@ai-sdk/openai": "@opencode/ai/providers/openai",
468
- "@ai-sdk/openai-compatible": "@opencode/ai/providers/openai-compatible",
469
- "@ai-sdk/togetherai": "@opencode/ai/providers/togetherai",
470
- "@ai-sdk/xai": "@opencode/ai/providers/xai",
471
- "@ai-sdk/gateway": "@opencode/ai/providers/vercel-ai-gateway",
472
- "@openrouter/ai-sdk-provider": "@opencode/ai/providers/openrouter",
473
- "ai-gateway-provider": "@opencode/ai/providers/cloudflare-ai-gateway",
474
- "venice-ai-sdk-provider": "@opencode/ai/providers/venice"
475
- };
476
- var protocols = (name) => ({
477
- "@ai-sdk/openai-compatible": `@opencode/ai/providers/${name}/chat`,
478
- "@ai-sdk/anthropic": `@opencode/ai/providers/${name}/messages`,
479
- "@ai-sdk/openai": `@opencode/ai/providers/${name}/responses`
480
- });
481
- var HOSTS = {
482
- alibaba: protocols("alibaba"),
483
- "alibaba-cn": protocols("alibaba"),
484
- "alibaba-coding-plan": protocols("alibaba"),
485
- "alibaba-coding-plan-cn": protocols("alibaba"),
486
- "alibaba-token-plan": protocols("alibaba"),
487
- "alibaba-token-plan-cn": protocols("alibaba"),
488
- baseten: { "@ai-sdk/openai-compatible": "@opencode/ai/providers/baseten" },
489
- "cloudflare-ai-gateway": {
490
- "@ai-sdk/anthropic": "@opencode/ai/providers/cloudflare-ai-gateway",
491
- "@ai-sdk/openai": "@opencode/ai/providers/cloudflare-ai-gateway",
492
- "@ai-sdk/openai-compatible": "@opencode/ai/providers/cloudflare-ai-gateway",
493
- "ai-gateway-provider": "@opencode/ai/providers/cloudflare-ai-gateway"
494
- },
495
- cohere: { "@ai-sdk/openai-compatible": "@opencode/ai/providers/cohere/chat" },
496
- "cloudflare-workers-ai": { "@ai-sdk/openai-compatible": "@opencode/ai/providers/cloudflare-workers-ai" },
497
- deepseek: { "@ai-sdk/openai-compatible": "@opencode/ai/providers/deepseek" },
498
- digitalocean: { "@ai-sdk/openai-compatible": "@opencode/ai/providers/digitalocean" },
499
- "fireworks-ai": { "@ai-sdk/openai-compatible": "@opencode/ai/providers/fireworks" },
500
- "google-vertex": {
501
- "@ai-sdk/openai-compatible": "@opencode/ai/providers/google-vertex/chat",
502
- "@ai-sdk/mistral": "@opencode/ai/providers/google-vertex/mistral"
503
- },
504
- "kimi-for-coding": protocols("moonshot"),
505
- meta: protocols("meta"),
506
- minimax: protocols("minimax"),
507
- "minimax-cn": protocols("minimax"),
508
- "minimax-coding-plan": protocols("minimax"),
509
- "minimax-cn-coding-plan": protocols("minimax"),
510
- moonshotai: protocols("moonshot"),
511
- "moonshotai-cn": protocols("moonshot"),
512
- zai: { "@ai-sdk/openai-compatible": "@opencode/ai/providers/zai/chat" },
513
- "zai-coding-plan": protocols("zai-coding-plan"),
514
- zhipuai: { "@ai-sdk/openai-compatible": "@opencode/ai/providers/zai/chat" },
515
- "zhipuai-coding-plan": protocols("zai-coding-plan")
516
- };
517
- var NATIVE = new Set([
518
- ...Object.values(PACKAGES),
519
- ...Object.values(HOSTS).flatMap((host) => Object.values(host)),
520
- "@opencode/ai/providers/azure/chat",
521
- "@opencode/ai/providers/amazon-bedrock/mantle",
522
- "@opencode/ai/providers/amazon-bedrock/mantle/chat",
523
- "@opencode/ai/providers/amazon-bedrock/mantle/responses"
524
- ]);
525
- function native2(npm, context) {
526
- const host = HOSTS[context.providerID]?.[npm];
527
- if (host)
528
- return host;
529
- if (npm === "@ai-sdk/amazon-bedrock/mantle")
530
- return mantle(context.modelID);
531
- if (npm === "@ai-sdk/azure" && azureChat(context))
532
- return "@opencode/ai/providers/azure/chat";
533
- return PACKAGES[npm];
534
- }
535
- var azureChat = (context) => context.shape === "completions" || context.settings?.useCompletionUrls === true;
536
- var mantle = (modelID) => {
537
- if (modelID === undefined)
538
- return "@opencode/ai/providers/amazon-bedrock/mantle";
539
- return `@opencode/ai/providers/amazon-bedrock/mantle/${modelID.includes("gpt-oss") ? "chat" : "responses"}`;
540
- };
541
- function resolve(specifier, context) {
542
- const npm = packageName2(specifier);
543
- if (isAISDK2(specifier) || npm in PACKAGES || npm in (HOSTS[context.providerID] ?? {}))
544
- return native2(npm, context);
545
- if (npm === "@opencode/ai/providers/amazon-bedrock/mantle")
546
- return mantle(context.modelID);
547
- if (npm === "@opencode/ai/providers/azure/responses" && azureChat(context))
548
- return "@opencode/ai/providers/azure/chat";
549
- return NATIVE.has(npm) ? npm : undefined;
550
- }
551
- function options(replacement, modelID, settings) {
552
- const converse = replacement === "@opencode/ai/providers/amazon-bedrock" && modelID !== undefined;
553
- const kept = Struct2.omit(settings, ["headers", "extraBody", "useCompletionUrls", ...OPENROUTER_KEYS]);
554
- const thinking = converse ? bedrockThinking(modelID, settings) : undefined;
555
- return {
556
- settings: {
557
- ...replacement.startsWith("@opencode/ai/providers/amazon-bedrock") ? bedrockSettings(kept, converse) : kept,
558
- ...thinking === undefined ? {} : { thinking }
559
- },
560
- ...settings.headers === undefined ? {} : { headers: settings.headers },
561
- ...settings.extraBody === undefined ? {} : { body: settings.extraBody },
562
- ...converse ? bedrockRequest(modelID, settings) : {},
563
- ...replacement === "@opencode/ai/providers/openrouter" ? openRouterRequest(settings) : {}
564
- };
565
- }
566
- var BEDROCK_KEYS = [
567
- "bearerToken",
568
- "endpoint",
569
- "credentials",
570
- "credentialProvider",
571
- "accessKeyId",
572
- "secretAccessKey",
573
- "sessionToken"
574
- ];
575
- var CONVERSE_KEYS = ["additionalModelRequestFields", "reasoningConfig", "anthropicBeta", "serviceTier"];
576
- function bedrockSettings(settings, converse) {
577
- const region = settings.region ?? settings.credentials?.region;
578
- const credentials = settings.credentials ?? settings;
579
- const baseURL = settings.baseURL ?? settings.endpoint;
580
- return {
581
- ...Struct2.omit(settings, converse ? [...BEDROCK_KEYS, ...CONVERSE_KEYS] : BEDROCK_KEYS),
582
- ...baseURL === undefined ? {} : { baseURL: region === undefined ? baseURL : baseURL.replaceAll("${AWS_REGION}", region) },
583
- ...settings.apiKey === undefined && settings.bearerToken !== undefined ? { apiKey: settings.bearerToken } : {},
584
- ...credentials.accessKeyId === undefined || credentials.secretAccessKey === undefined ? {} : {
585
- credentials: {
586
- ...region === undefined ? {} : { region },
587
- accessKeyId: credentials.accessKeyId,
588
- secretAccessKey: credentials.secretAccessKey,
589
- ...credentials.sessionToken === undefined ? {} : { sessionToken: credentials.sessionToken }
590
- }
591
- }
592
- };
593
- }
594
- function bedrockThinking(modelID, settings) {
595
- const reasoning = settings.reasoningConfig;
596
- if (!modelID?.includes("anthropic") || reasoning?.type !== "enabled" || reasoning.budgetTokens === undefined)
597
- return;
598
- return { type: "enabled", budgetTokens: reasoning.budgetTokens };
599
- }
600
- function bedrockRequest(modelID, settings) {
601
- const additional = settings.additionalModelRequestFields ?? {};
602
- const reasoning = settings.reasoningConfig;
603
- const anthropic = modelID?.includes("anthropic") ?? false;
604
- const openai = modelID?.includes("openai.") ?? false;
605
- const harmony = modelID?.includes("openai.gpt-oss") ?? false;
606
- const effort = reasoning?.maxReasoningEffort;
607
- const type = reasoning?.type;
608
- const budget = reasoning?.budgetTokens;
609
- const display = reasoning?.display;
610
- const betas = settings.anthropicBeta ?? [];
611
- const fields = mergeOverlay2(additional, {
612
- ...betas.length > 0 ? { anthropic_beta: [...additional.anthropic_beta ?? [], ...betas] } : {},
613
- ...anthropic && type === "adaptive" ? { thinking: { type: "adaptive", ...display === undefined ? {} : { display } } } : {},
614
- ...anthropic && effort !== undefined ? { output_config: { ...additional.output_config, effort } } : {},
615
- ...!anthropic && openai && harmony && effort !== undefined ? { reasoning_effort: effort } : {},
616
- ...!anthropic && openai && !harmony && effort !== undefined ? { reasoning: { ...additional.reasoning, effort } } : {},
617
- ...!anthropic && !openai && effort !== undefined ? {
618
- reasoningConfig: {
619
- ...type === undefined || type === "adaptive" ? {} : { type },
620
- ...budget === undefined ? {} : { budgetTokens: budget },
621
- maxReasoningEffort: effort
622
- }
623
- } : {}
624
- });
625
- const body = {
626
- ...fields && Object.keys(fields).length > 0 ? { additionalModelRequestFields: fields } : {},
627
- ...settings.serviceTier === undefined ? {} : { serviceTier: { type: settings.serviceTier } }
628
- };
629
- return Object.keys(body).length === 0 ? {} : { body };
630
- }
631
- var OPENROUTER_KEYS = ["appName", "appUrl", "api_keys", "compatibility"];
632
- function openRouterRequest(settings) {
633
- const headers = mergeHeaders2({
634
- ...settings.appName === undefined ? {} : { "X-OpenRouter-Title": settings.appName },
635
- ...settings.appUrl === undefined ? {} : { "HTTP-Referer": settings.appUrl },
636
- ...settings.api_keys === undefined || Object.keys(settings.api_keys).length === 0 ? {} : { "X-Provider-API-Keys": JSON.stringify(settings.api_keys) }
637
- }, settings.headers) ?? {};
638
- return Object.keys(headers).length === 0 ? {} : { headers };
639
- }
640
- var lenient = (schema) => Schema2.optional(Schema2.UndefinedOr(schema).pipe(Schema2.catchDecoding(() => Effect2.succeed(Option2.some(undefined)))));
641
- var Credentials = Schema2.Struct({
642
- accessKeyId: Schema2.String,
643
- secretAccessKey: Schema2.String,
644
- sessionToken: lenient(Schema2.String),
645
- region: lenient(Schema2.String)
646
- });
647
- var Legacy = Schema2.StructWithRest(Schema2.Struct({
648
- apiKey: lenient(Schema2.String),
649
- baseURL: lenient(Schema2.String),
650
- headers: lenient(Schema2.Record(Schema2.String, Schema2.String)),
651
- extraBody: lenient(Schema2.Record(Schema2.String, Schema2.Unknown)),
652
- useCompletionUrls: lenient(Schema2.Boolean),
653
- auth: lenient(Schema2.Literals(["bearer", "sigv4"])),
654
- bearerToken: lenient(Schema2.String),
655
- endpoint: lenient(Schema2.String),
656
- region: lenient(Schema2.String),
657
- credentials: lenient(Credentials),
658
- accessKeyId: lenient(Schema2.String),
659
- secretAccessKey: lenient(Schema2.String),
660
- sessionToken: lenient(Schema2.String),
661
- anthropicBeta: lenient(Schema2.Array(Schema2.String)),
662
- serviceTier: lenient(Schema2.String),
663
- reasoningConfig: lenient(Schema2.Struct({
664
- type: lenient(Schema2.String),
665
- display: lenient(Schema2.String),
666
- maxReasoningEffort: lenient(Schema2.String),
667
- budgetTokens: lenient(Schema2.Number)
668
- })),
669
- additionalModelRequestFields: lenient(Schema2.StructWithRest(Schema2.Struct({
670
- anthropic_beta: lenient(Schema2.Array(Schema2.String)),
671
- output_config: lenient(Schema2.Record(Schema2.String, Schema2.Unknown)),
672
- reasoning: lenient(Schema2.Record(Schema2.String, Schema2.Unknown))
673
- }), [Schema2.Record(Schema2.String, Schema2.Unknown)])),
674
- appName: lenient(Schema2.String),
675
- appUrl: lenient(Schema2.String),
676
- api_keys: lenient(Schema2.Record(Schema2.String, Schema2.String))
677
- }), [Schema2.Record(Schema2.String, Schema2.Unknown)]);
678
- var decode = Schema2.decodeUnknownSync(Legacy);
679
-
680
- export { rewrite2, native2, exports_aisdk_native, ID12, AISDK_PREFIX2, isAISDK2, aisdk2, packageName2, LoadError3, loadPackage2, nativeSettings2, modelSettings2, DEFAULT_TIMEOUT_MS3, DEFAULT_CHUNK_TIMEOUT_MS2, timeout2, timeouts2, encoding2, mergeOverlay2, mergeHeaders2, Request3, Compaction3, Transport2, Settings2, Info21, Service71, node74, exports_provider3, Event16 };
680
+ export { ID13, AISDK_PREFIX2, isAISDK2, aisdk2, packageName2, LoadError3, loadPackage2, nativeSettings2, modelSettings2, DEFAULT_TIMEOUT_MS3, DEFAULT_CHUNK_TIMEOUT_MS2, timeout2, timeouts2, encoding2, mergeOverlay2, mergeHeaders2, Request3, Compaction3, Transport2, Settings2, Info22, Service77, node81, exports_provider3, Event17, rewrite2, native2, exports_aisdk_native };