nolo-cli 0.264.0-alpha.2 → 0.266.0-alpha.1

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 (538) hide show
  1. package/{chunk-LXP53WGF.js → chunk-05wkntba.js} +44 -40
  2. package/{chunk-XFYFMTOM.js → chunk-08ts2q1n.js} +9 -11
  3. package/{chromeCommands-MVEEIY4R.js → chunk-0a3m1n6h.js} +182 -238
  4. package/chunk-0gfvc7g8.js +13 -0
  5. package/{chunk-CF7PE763.js → chunk-0h0sncy4.js} +3 -4
  6. package/{chunk-3UH7SS4W.js → chunk-0nsxwrge.js} +232 -241
  7. package/chunk-0ra8cne4.js +11 -0
  8. package/{chunk-MRACVEPZ.js → chunk-0sgwk7am.js} +1 -3
  9. package/{chunk-PEXGRTTQ.js → chunk-0tsfn0dk.js} +44 -45
  10. package/{chunk-WOAZVUSN.js → chunk-0y8cbwzy.js} +26 -30
  11. package/chunk-12gz55kk.js +6 -0
  12. package/{chunk-GLKOYSRU.js → chunk-186gshgw.js} +3 -6
  13. package/chunk-19w4ss38.js +44 -0
  14. package/{chunk-RF576RYE.js → chunk-1cakzp6r.js} +23 -23
  15. package/chunk-1fbfwbzp.js +27 -0
  16. package/{chunk-4IVMDQBA.js → chunk-1fv9k8zt.js} +103 -68
  17. package/{chunk-Q5FJJ6XI.js → chunk-1js4cdzp.js} +11 -19
  18. package/{chunk-YECCIUYU.js → chunk-1nhx0er5.js} +63 -63
  19. package/chunk-1p152b7g.js +12 -0
  20. package/{chunk-HXEO5DNV.js → chunk-1ynbq3yr.js} +322 -353
  21. package/{chunk-6UBGXX2W.js → chunk-1zrg4h5n.js} +3 -4
  22. package/{chunk-Y5GCAMGP.js → chunk-2g6zsfq8.js} +1 -3
  23. package/chunk-2hekb0eh.js +17 -0
  24. package/chunk-2pj6qzq5.js +12 -0
  25. package/chunk-2tvd4jyp.js +226 -0
  26. package/chunk-2ygg7azv.js +846 -0
  27. package/chunk-33405wtv.js +50 -0
  28. package/chunk-34axejtd.js +30 -0
  29. package/{tableCommands-FCPDULSU.js → chunk-3700dvt3.js} +224 -276
  30. package/{pdf-KE3QI2V7.js → chunk-3j08t1nm.js} +12505 -10133
  31. package/chunk-3j9gq18v.js +111 -0
  32. package/{chunk-LYPJYBE5.js → chunk-3qfpcdkm.js} +486 -505
  33. package/{settingThunks-PNC7ZISV.js → chunk-3r2x7h64.js} +189 -272
  34. package/{agentGrantCommands-2VLLXGIU.js → chunk-3tbj5fxt.js} +61 -56
  35. package/chunk-40whhjj5.js +168 -0
  36. package/chunk-4301919y.js +7 -0
  37. package/chunk-43adz39e.js +77 -0
  38. package/{chunk-5ZUL4CUO.js → chunk-49v3zc4g.js} +1 -3
  39. package/chunk-4dd7mxkb.js +72 -0
  40. package/{chunk-BKP325XS.js → chunk-4hapfzpq.js} +66 -62
  41. package/chunk-4mm7dz0m.js +95 -0
  42. package/chunk-4pqxempz.js +440 -0
  43. package/chunk-4x9zf5pv.js +10 -0
  44. package/{chunk-CA7LGAHV.js → chunk-511q8qzv.js} +66 -57
  45. package/{chunk-U7OULUMF.js → chunk-53v9g0np.js} +49 -64
  46. package/chunk-572mg6q5.js +19 -0
  47. package/{chunk-QAW6BEWQ.js → chunk-57eyhmwr.js} +17173 -16165
  48. package/chunk-5hsr0zjm.js +156 -0
  49. package/chunk-5k883yyd.js +20 -0
  50. package/chunk-5m0wsee4.js +639 -0
  51. package/{memberThunks-NEZRAW5K.js → chunk-5r1sq2gt.js} +299 -373
  52. package/chunk-648rq4np.js +255 -0
  53. package/{chunk-IYRZKHA6.js → chunk-666yjw5c.js} +63 -86
  54. package/{chunk-4O22PGNQ.js → chunk-6cdcbmtp.js} +19 -19
  55. package/chunk-6dbyqcf7.js +59 -0
  56. package/{agentProviderCommands-2W3VXDLV.js → chunk-6e8mgp1x.js} +82 -105
  57. package/chunk-6n0pw7sx.js +44 -0
  58. package/chunk-6q1b7381.js +361 -0
  59. package/chunk-6sj756ry.js +23 -0
  60. package/{chunk-4UNN45DS.js → chunk-6t7a7zck.js} +14785 -14454
  61. package/chunk-6yarwtxh.js +776 -0
  62. package/chunk-708h542p.js +18 -0
  63. package/chunk-76f076t8.js +266 -0
  64. package/chunk-782rrrwv.js +523 -0
  65. package/{workloadLifecycle-P2SJVV3S.js → chunk-7gk330wp.js} +77 -84
  66. package/{chunk-EZKIRVLJ.js → chunk-7ks60vxy.js} +146 -128
  67. package/{chunk-FI4DPLR7.js → chunk-7mrqbxe8.js} +342 -228
  68. package/chunk-7sztayrd.js +169 -0
  69. package/chunk-7vgt2mxz.js +15 -0
  70. package/{localFirstLog-OIETGK66.js → chunk-7z8y4k6y.js} +0 -2
  71. package/{chunk-KDDXC2IH.js → chunk-82htft2m.js} +49 -11
  72. package/{updateDialogTitleAction-XOSLNRT3.js → chunk-88vrtxxg.js} +65 -137
  73. package/{chunk-LS5KAVFQ.js → chunk-8dtjbp79.js} +293 -229
  74. package/chunk-8fajbkaz.js +50 -0
  75. package/chunk-8m1ebxpw.js +65 -0
  76. package/{accountResolver-JYG5L7YP.js → chunk-8mgfeg0w.js} +37 -30
  77. package/{chunk-LPXBBC32.js → chunk-8myksy35.js} +156 -160
  78. package/{chunk-BMQ2MJUK.js → chunk-8nrj7dc7.js} +75 -66
  79. package/{commandRegistry-ENNFT77C.js → chunk-8t8x64ec.js} +228 -286
  80. package/chunk-8yj4pq79.js +458 -0
  81. package/{chunk-5MKPNTJP.js → chunk-8z6pepcx.js} +43 -48
  82. package/{chunk-UYQILGDR.js → chunk-90egc9vb.js} +122 -102
  83. package/{chunk-EODBQPRM.js → chunk-91q5dc5r.js} +10 -14
  84. package/{chunk-U6VC4MU4.js → chunk-96jtrqk1.js} +2 -4
  85. package/{chunk-H57T64RA.js → chunk-996j61av.js} +28 -31
  86. package/{chunk-Q6FKWH66.js → chunk-9cxgb9jy.js} +137 -243
  87. package/{chunk-2ZBPWX7N.js → chunk-9q1gbmet.js} +62 -104
  88. package/chunk-9qtjh73q.js +344 -0
  89. package/{chunk-SR57FDTX.js → chunk-9raka469.js} +72 -155
  90. package/{chunk-V6K5U4YE.js → chunk-9vh4v046.js} +32 -41
  91. package/{chunk-AGIM7IMJ.js → chunk-9yr1fy7j.js} +14 -49
  92. package/{chunk-FGFJUFPS.js → chunk-a16x0wt6.js} +11 -18
  93. package/chunk-a5b2rvzs.js +131 -0
  94. package/{chunk-7DPNBQSV.js → chunk-a7bz6nc3.js} +3 -4
  95. package/chunk-ac85azv9.js +29 -0
  96. package/{chunk-VXL2FZTP.js → chunk-ahhbkad4.js} +16 -20
  97. package/{chunk-37DGW762.js → chunk-anhksj2j.js} +16 -29
  98. package/{cliAuthorityBrokerServer-27C5YBYP.js → chunk-atvmx76t.js} +180 -186
  99. package/{chunk-E6A5NHDH.js → chunk-av2mzeqz.js} +16 -17
  100. package/chunk-avbwrb0z.js +614 -0
  101. package/chunk-avr6rqe5.js +544 -0
  102. package/{workContextQueryProjection-CACY5VFE.js → chunk-axx60d5a.js} +7 -7
  103. package/{chunk-EWQ3HGNZ.js → chunk-b00vzjkb.js} +30 -23
  104. package/chunk-b0m6ezxr.js +132 -0
  105. package/chunk-bbd5mgdt.js +47 -0
  106. package/chunk-bcecft0r.js +28 -0
  107. package/chunk-beyr4pyp.js +33 -0
  108. package/{chunk-BR3GT6MR.js → chunk-bge0cagn.js} +7 -18
  109. package/{offlineMarxistsAgentCommand-MFURGWHL.js → chunk-bh53zg3t.js} +33 -43
  110. package/chunk-bmx1cw89.js +37 -0
  111. package/chunk-br2195h4.js +22 -0
  112. package/chunk-bsqkwveq.js +56 -0
  113. package/{chunk-QAU6KM2U.js → chunk-c09s2z1m.js} +139 -98
  114. package/chunk-c235kypv.js +24636 -0
  115. package/{chunk-2JMYAH5O.js → chunk-c30j6pyh.js} +213 -256
  116. package/chunk-c3v6r6sq.js +29 -0
  117. package/{chunk-PDSXYHNI.js → chunk-c5z7qspt.js} +1177 -1196
  118. package/{chunk-GWB6AGME.js → chunk-c6jvz0mp.js} +34 -50
  119. package/{chunk-PRJ473FK.js → chunk-cd6h9qqs.js} +14 -12
  120. package/chunk-cdt0amyy.js +37 -0
  121. package/{chunk-2AJLG6PY.js → chunk-cfh6tfc3.js} +73 -86
  122. package/{chunk-WIVVNJUS.js → chunk-ch4ck1yz.js} +38 -68
  123. package/chunk-chtvrtp5.js +55 -0
  124. package/{chunk-EYLGAEB4.js → chunk-ckvz7abv.js} +170 -165
  125. package/{chunk-YZMNK53S.js → chunk-csf18m5w.js} +32 -25
  126. package/{chunk-C36L6ZID.js → chunk-cwnvf8dt.js} +2 -10
  127. package/chunk-cy7thb6n.js +19877 -0
  128. package/{dialogPortabilityCommands-YQJNB2KL.js → chunk-d61q9nah.js} +439 -487
  129. package/chunk-d6xdy0gp.js +142 -0
  130. package/{chunk-EBH4RFJ6.js → chunk-dh69vqbd.js} +6390 -6496
  131. package/{chunk-KJ4J2XQB.js → chunk-dj4ggbc6.js} +17 -19
  132. package/{chunk-LISC7BD4.js → chunk-djrrhbk3.js} +29 -37
  133. package/chunk-drqzzzvr.js +822 -0
  134. package/chunk-e1n7edjk.js +33 -0
  135. package/chunk-e3atr4hk.js +59 -0
  136. package/chunk-e9bn2aav.js +13 -0
  137. package/chunk-ed396rfq.js +87 -0
  138. package/chunk-eha8ggh6.js +10 -0
  139. package/{chunk-MALPQFGT.js → chunk-ek122zzt.js} +893 -948
  140. package/chunk-epnmvek4.js +22 -0
  141. package/{chunk-S25VJYXV.js → chunk-eqzvk3xm.js} +69 -80
  142. package/chunk-ex34n71b.js +2874 -0
  143. package/{chunk-56OAS5RZ.js → chunk-f3ad6q4h.js} +7 -11
  144. package/{chunk-3PVYUPXK.js → chunk-f8jepva1.js} +6 -7
  145. package/{chunk-GH34JXNV.js → chunk-f9yvy9t9.js} +114 -92
  146. package/chunk-fbdz4f0j.js +90 -0
  147. package/{chunk-J44TXB4J.js → chunk-fcsc2day.js} +216 -164
  148. package/chunk-fevdhnbh.js +19 -0
  149. package/chunk-fkrgqq8w.js +3300 -0
  150. package/{chunk-TSBJVMNW.js → chunk-fs3bvh2p.js} +42 -57
  151. package/chunk-fvwzyhah.js +134 -0
  152. package/chunk-g0mpxdp9.js +101 -0
  153. package/{chunk-LTQ6ECCF.js → chunk-g35f20d1.js} +450 -414
  154. package/{chunk-3L2WKC3W.js → chunk-g5fhtjqg.js} +13 -16
  155. package/{chunk-DBEOW57U.js → chunk-gcq01td7.js} +270 -227
  156. package/{chunk-ADMRXWXJ.js → chunk-ge97b11r.js} +121 -42
  157. package/chunk-ghjtgbkw.js +180 -0
  158. package/chunk-gkra36c1.js +16 -0
  159. package/chunk-gmz86t60.js +1000 -0
  160. package/{localDialogRead-GWGWSL5K.js → chunk-gszpesze.js} +5 -12
  161. package/chunk-gvsfec9m.js +16536 -0
  162. package/{chunk-QSJ3HFEF.js → chunk-h1hzmqph.js} +1 -3
  163. package/chunk-h30dg154.js +17 -0
  164. package/chunk-h3hkb7cw.js +241 -0
  165. package/chunk-h40py996.js +28 -0
  166. package/{chunk-47T3QP4V.js → chunk-h60gnewh.js} +112 -116
  167. package/{agentPullCommand-XEGOUYQT.js → chunk-hkwsv9xf.js} +33 -45
  168. package/chunk-hnyg0gwj.js +28 -0
  169. package/{chunk-KSV6T4AH.js → chunk-hqqqph5w.js} +12 -4
  170. package/{chunk-YQJEXXDK.js → chunk-hrngs1wy.js} +157 -246
  171. package/{chunk-LRLLWD4P.js → chunk-htf69s94.js} +14 -12
  172. package/chunk-j0yxesh3.js +83 -0
  173. package/{chunk-VF4K2QE6.js → chunk-j22t9g05.js} +3 -6
  174. package/{chunk-3R4AYHJR.js → chunk-j4a8m2zn.js} +5 -34
  175. package/chunk-j9p4jnwg.js +27 -0
  176. package/{chunk-R72QWIFO.js → chunk-jdycmfsm.js} +9 -9
  177. package/chunk-jdyvrne0.js +52 -0
  178. package/{spacePruneCommand-YKIEUIDQ.js → chunk-je0b66qf.js} +44 -62
  179. package/{chunk-HNMXYYJR.js → chunk-jec44fkj.js} +3 -4
  180. package/{chunk-526GLZJE.js → chunk-jf1ex00r.js} +107 -73
  181. package/chunk-jgqdec9b.js +31 -0
  182. package/{chunk-56GBUMO5.js → chunk-jkw9n4h5.js} +16 -25
  183. package/{chunk-7422ZLGL.js → chunk-jmnzdwjt.js} +867 -965
  184. package/chunk-jqq57s0a.js +58 -0
  185. package/{chunk-OKUSDVRS.js → chunk-jtkn5aj6.js} +27 -38
  186. package/chunk-jwvzn9r0.js +316 -0
  187. package/chunk-k1re0fc7.js +107 -0
  188. package/chunk-k2ep3rb2.js +103 -0
  189. package/{chunk-JEXVIMYZ.js → chunk-k6ycb24w.js} +5 -8
  190. package/{chunk-RI7SXDJW.js → chunk-kawvydbk.js} +383 -195
  191. package/chunk-kf2ghpzh.js +10 -0
  192. package/{chunk-S6FAHQDH.js → chunk-kgah9e46.js} +28 -59
  193. package/{chunk-T3MWVUBE.js → chunk-kjjepkvc.js} +71 -82
  194. package/chunk-kn4dgg4j.js +4113 -0
  195. package/{chunk-2LFYMWM3.js → chunk-kn5p91n8.js} +43 -53
  196. package/{chunk-MVOZ22RZ.js → chunk-kntqrbwc.js} +8 -12
  197. package/{chunk-I6YIA2TY.js → chunk-kq3vr7mx.js} +25 -20
  198. package/chunk-kz1x1d8n.js +15 -0
  199. package/{mcpLocalAuthorizeCommand-IKOFKY5U.js → chunk-m22e7tt2.js} +53 -71
  200. package/{chunk-ZNFJWEN4.js → chunk-m32rwr4d.js} +11 -8
  201. package/chunk-m39e9m18.js +93 -0
  202. package/{chunk-4D4QD7FT.js → chunk-m5518371.js} +64 -56
  203. package/{chunk-LHTXSC2E.js → chunk-mb5hnfyp.js} +9 -11
  204. package/chunk-mexet11v.js +11 -0
  205. package/chunk-mg2hgfgh.js +185 -0
  206. package/chunk-mmdhm4kx.js +10317 -0
  207. package/chunk-mz002yz8.js +2821 -0
  208. package/chunk-mzadqnyq.js +56 -0
  209. package/{chunk-VIDPVFP3.js → chunk-n3r1ebdm.js} +5 -6
  210. package/chunk-n438qea7.js +33 -0
  211. package/chunk-n5ffnhnb.js +93 -0
  212. package/chunk-nbvd87fy.js +9 -0
  213. package/{chunk-E36V7MPY.js → chunk-ndej7jc9.js} +53 -43
  214. package/{chunk-B767MA64.js → chunk-nen6rwe4.js} +62 -22
  215. package/chunk-nf06tr3v.js +16 -0
  216. package/chunk-ng8z355q.js +16 -0
  217. package/{chunk-4MEKE5D3.js → chunk-nhtxfv8k.js} +78 -63
  218. package/{runAgentClientLoop-2SFASHDS.js → chunk-nj62jscj.js} +132 -214
  219. package/{chunk-GBWGPTA7.js → chunk-nkryrkyp.js} +16 -19
  220. package/chunk-nmesxem8.js +197 -0
  221. package/{chunk-YR4J7RFS.js → chunk-nmq0qwbn.js} +117 -164
  222. package/chunk-nph8brvw.js +7 -0
  223. package/chunk-nr8fees9.js +10 -0
  224. package/{chunk-DFI7MVCQ.js → chunk-nvewvf7h.js} +1441 -1427
  225. package/{chunk-G7Y4GXTY.js → chunk-nyamhphs.js} +70 -79
  226. package/chunk-nz1c8tcg.js +111 -0
  227. package/{chunk-GPLUFN2E.js → chunk-nzc5yffh.js} +176 -217
  228. package/{chunk-G3SUCT4W.js → chunk-p1vg4bx8.js} +2 -4
  229. package/chunk-p3k3abe8.js +202 -0
  230. package/chunk-p4zy30q5.js +8 -0
  231. package/{chunk-ZJACPM5O.js → chunk-p6se1rx0.js} +102 -102
  232. package/chunk-p9dpshev.js +6968 -0
  233. package/chunk-pa42wxr0.js +116 -0
  234. package/{chunk-TA5QI4MM.js → chunk-paxthgqp.js} +56 -107
  235. package/{readlineWorkspace-ZH5FGDMI.js → chunk-pb35s8d9.js} +5395 -5786
  236. package/{chunk-XT6C2QZW.js → chunk-pbebzbcq.js} +8 -8
  237. package/chunk-pbx7e1mb.js +11 -0
  238. package/chunk-pe5czfn9.js +8 -0
  239. package/chunk-pextk1j4.js +62 -0
  240. package/chunk-pf5rywc6.js +575 -0
  241. package/chunk-pjfhd3fz.js +136 -0
  242. package/{chunk-ZCMAKAZM.js → chunk-pkhqb0fs.js} +118 -59
  243. package/chunk-pm5xb9jh.js +26 -0
  244. package/{chunk-Y3KGWZKF.js → chunk-ppdmmdkx.js} +110 -97
  245. package/chunk-pqp6y2hs.js +9 -0
  246. package/{chunk-QHEN7NZ7.js → chunk-ptz8fm2n.js} +12 -17
  247. package/{chunk-EUHMI5KG.js → chunk-pwqnvbt7.js} +65 -46
  248. package/chunk-pzr31nz7.js +12 -0
  249. package/{chunk-WWC7I6TA.js → chunk-q3cx89sw.js} +2 -4
  250. package/chunk-q5pe7be3.js +78 -0
  251. package/{chunk-ZHWTBHT3.js → chunk-q6zqbxp2.js} +418 -409
  252. package/chunk-q7r0e1p3.js +15 -0
  253. package/chunk-q8t2fecd.js +6 -0
  254. package/{chunk-2QAZCYOM.js → chunk-q94zx4d0.js} +721 -753
  255. package/{runtimeDoctorCommands-52MBG5JN.js → chunk-qarz1az1.js} +65 -85
  256. package/{chunk-4INJGWE3.js → chunk-qdcvr25b.js} +72 -53
  257. package/{streamAgentChatTurn-KOUWITHH.js → chunk-qxs27wfg.js} +1079 -1475
  258. package/{chunk-GIXWVN2W.js → chunk-r06ycjjr.js} +50 -47
  259. package/{chunk-63W5N6P3.js → chunk-r20jw5hb.js} +57 -38
  260. package/{chunk-I5BYFTYK.js → chunk-r7sfwdka.js} +1201 -1142
  261. package/{chunk-UMADT6B2.js → chunk-r9sp1yyb.js} +6 -8
  262. package/{handleSendMessageAction-FHGUFT2X.js → chunk-rbd2vgb3.js} +627 -757
  263. package/chunk-rc37js46.js +12 -0
  264. package/{chunk-5YI447UL.js → chunk-rmngk6r3.js} +67 -76
  265. package/chunk-rnhbnbrq.js +15 -0
  266. package/{chunk-WRHVVIGI.js → chunk-rsfnmrt5.js} +111 -131
  267. package/{chunk-YFSM2366.js → chunk-rvvn2rhj.js} +28 -22
  268. package/{chunk-4Y6CZ2N4.js → chunk-s0fpz7ht.js} +37 -33
  269. package/{chunk-VI4SWTUO.js → chunk-s1cqzb2r.js} +77 -65
  270. package/{chunk-6QDYSCPW.js → chunk-s8q81tda.js} +73 -65
  271. package/chunk-s9hy639e.js +6 -0
  272. package/{chunk-R5GO3YZP.js → chunk-s9vbwme8.js} +115 -106
  273. package/chunk-sger1m1b.js +20 -0
  274. package/chunk-spe6crvk.js +60 -0
  275. package/chunk-spwsrvh9.js +70 -0
  276. package/chunk-sr05zpk7.js +573 -0
  277. package/{chunk-M2EJHDJP.js → chunk-srncrd3f.js} +1 -12
  278. package/{chunk-QXHFIX7W.js → chunk-sry80bpx.js} +71 -53
  279. package/{chunk-PSCNXBYA.js → chunk-t6q69p83.js} +3 -4
  280. package/{chunk-UAD2WT54.js → chunk-t714r4q0.js} +9 -28
  281. package/chunk-t7vbraqe.js +42 -0
  282. package/{chunk-CVMMWN6P.js → chunk-td7653rr.js} +10 -20
  283. package/{chunk-3BQDF4QB.js → chunk-tmytcetz.js} +17 -21
  284. package/{chunk-AMWMV56B.js → chunk-tta4prwg.js} +16 -15
  285. package/chunk-tvh8azgq.js +4829 -0
  286. package/{chunk-ID4G2MAR.js → chunk-v08kbfm8.js} +10 -11
  287. package/{chunk-OKPOQGQJ.js → chunk-v1x702q8.js} +801 -852
  288. package/{chunk-KHCLMKZZ.js → chunk-v39fea91.js} +576 -247
  289. package/{chunk-OW765XBU.js → chunk-vejtd8p2.js} +3 -4
  290. package/chunk-vep7zkha.js +368 -0
  291. package/chunk-vfwn1k7n.js +142 -0
  292. package/chunk-vg68vxhx.js +20 -0
  293. package/chunk-vgcqgnsm.js +31 -0
  294. package/{chunk-NF64D32W.js → chunk-vnzyjdea.js} +1 -3
  295. package/{chunk-ZCLSM5AK.js → chunk-vqgtw1px.js} +800 -717
  296. package/chunk-vv1gr5xz.js +76 -0
  297. package/{spaceCommands-Z2CTQD6G.js → chunk-w1qeadpq.js} +176 -242
  298. package/chunk-w468ez1p.js +13 -0
  299. package/chunk-w49s0t79.js +14 -0
  300. package/{mcpLocalManageCommands-KUDZQRM4.js → chunk-w58zhfbn.js} +91 -93
  301. package/chunk-w5b74aq6.js +11 -0
  302. package/chunk-w7y41qyw.js +117 -0
  303. package/chunk-w820gg1w.js +4165 -0
  304. package/{chunk-DBJAJ4UD.js → chunk-wdsmaqmt.js} +399 -453
  305. package/{chunk-3EUW3WEO.js → chunk-wfvvnmmj.js} +1 -3
  306. package/{chunk-QY4NZCDA.js → chunk-wkr04bhk.js} +432 -651
  307. package/{chunk-KUG52IAP.js → chunk-ws402twv.js} +1 -3
  308. package/chunk-wzwh311q.js +164 -0
  309. package/{runtimeModeArgs-X7DL7PUN.js → chunk-x5vtgvwn.js} +6 -5
  310. package/{agentMachineCommands-COJD2KPZ.js → chunk-x8h2csmq.js} +152 -195
  311. package/{chunk-BAZCS5XG.js → chunk-x9zfjnrc.js} +59 -47
  312. package/{chunk-WTIJKWCI.js → chunk-xcarc2rf.js} +50 -56
  313. package/chunk-xf33gz0a.js +8 -0
  314. package/{chunk-PVFYPUIM.js → chunk-y7b3gwx1.js} +78 -71
  315. package/{memoryCommands-SVLAVFCV.js → chunk-y7sphmnh.js} +119 -95
  316. package/{agentListCommands-436FHOIT.js → chunk-ycvaafhc.js} +260 -374
  317. package/chunk-yd7zprb0.js +9 -0
  318. package/chunk-yfz3d27k.js +40 -0
  319. package/{chunk-MKR6KDD3.js → chunk-ykv9g3m4.js} +141 -125
  320. package/chunk-ystjgb9e.js +544 -0
  321. package/chunk-yysxn7ep.js +12 -0
  322. package/{chunk-AL3TYDIF.js → chunk-z17eyawk.js} +18 -16
  323. package/{machineCommands-RVB5OG2X.js → chunk-z17q416p.js} +442 -563
  324. package/chunk-z1n98pcf.js +12 -0
  325. package/{dialogTraceCommand-HWXGIGZX.js → chunk-z566jx5r.js} +292 -397
  326. package/chunk-zjxd6942.js +6 -0
  327. package/{versionChangeNotice-RFABJGJE.js → chunk-zk11x9y5.js} +7 -9
  328. package/{chunk-TEFD5E2D.js → chunk-zt73yc33.js} +48 -51
  329. package/chunk-zvs2fra1.js +5 -0
  330. package/{chunk-SVFFKLMR.js → chunk-zwee84rh.js} +117 -141
  331. package/chunk-zxgfqv72.js +8 -0
  332. package/index.js +53 -69
  333. package/package.json +4 -4
  334. package/_executeModel-YQNZNR2Y.js +0 -341
  335. package/action-UK3HXGXF.js +0 -30
  336. package/addContentAction-CAKFVBDM.js +0 -38
  337. package/addDialogAgentAction-KLJ2YWWM.js +0 -77
  338. package/agentDeleteCommand-S5FVPYKT.js +0 -523
  339. package/agentEmailCommands-ZEFMGVKM.js +0 -742
  340. package/agentRecordCommands-JZ35AC5A.js +0 -211
  341. package/agentRun-UIO43TUG.js +0 -251
  342. package/agentRunCommand-ATLKKD6O.js +0 -249
  343. package/agentRunControl-U2MV74WR.js +0 -211
  344. package/agentRuntimeLocal-P4MMGIR6.js +0 -189
  345. package/agentSlice-HHNKNNYM.js +0 -52
  346. package/appConfigCommands-W4JQHMOJ.js +0 -417
  347. package/appDeleteCommands-IXR47IAV.js +0 -183
  348. package/appDeployCommands-LB6DHDF4.js +0 -232
  349. package/appDeployStatusCommands-UQ6MJL6D.js +0 -204
  350. package/appGetCommands-M5JCTDDQ.js +0 -185
  351. package/appListCommands-TE3ZHE3I.js +0 -186
  352. package/appMigrateCommands-FOXH6R4B.js +0 -230
  353. package/appSourceCommands-3ACYB6I7.js +0 -279
  354. package/authCommand-I5OBJP5S.js +0 -66
  355. package/authCommands-I6KCGOCN.js +0 -54
  356. package/builtinSkillRegistry-MIXYSZUU.js +0 -35
  357. package/chromeOpsCommands-IZRCYDSW.js +0 -579
  358. package/chunk-24BICQPB.js +0 -25
  359. package/chunk-2E4BYAUE.js +0 -69
  360. package/chunk-2O72G3U2.js +0 -17157
  361. package/chunk-2OROOEOQ.js +0 -229
  362. package/chunk-2R6M34JP.js +0 -27225
  363. package/chunk-2SXN7LAY.js +0 -15
  364. package/chunk-35JIFLIG.js +0 -30
  365. package/chunk-3VXVE2LF.js +0 -12
  366. package/chunk-4DBTBNTX.js +0 -477
  367. package/chunk-4JH2UMJR.js +0 -40
  368. package/chunk-4RUQ2PFX.js +0 -432
  369. package/chunk-4SN6J65J.js +0 -38
  370. package/chunk-5MMAK75Q.js +0 -15
  371. package/chunk-6NYQHXMV.js +0 -1737
  372. package/chunk-6R4IY46J.js +0 -14
  373. package/chunk-7E6YXSFZ.js +0 -441
  374. package/chunk-7K4J76JQ.js +0 -917
  375. package/chunk-7LR2IFUH.js +0 -100
  376. package/chunk-AETZ7AD6.js +0 -274
  377. package/chunk-ATNTHIZI.js +0 -13
  378. package/chunk-BPB3T5EU.js +0 -791
  379. package/chunk-BV3FLP2L.js +0 -133
  380. package/chunk-BVYHE6QD.js +0 -110
  381. package/chunk-BWJLEN6X.js +0 -1388
  382. package/chunk-CHOZJMJS.js +0 -78
  383. package/chunk-D2LTQAGN.js +0 -464
  384. package/chunk-DALXH7BG.js +0 -3392
  385. package/chunk-DBCWXGOC.js +0 -15210
  386. package/chunk-DLXL4NSL.js +0 -1179
  387. package/chunk-DSBRIUX5.js +0 -23
  388. package/chunk-DWLEOOGR.js +0 -8
  389. package/chunk-E2KZNP6C.js +0 -13
  390. package/chunk-E5JV4DCB.js +0 -272
  391. package/chunk-EUGTFFO6.js +0 -42
  392. package/chunk-FBNVJ2TO.js +0 -294
  393. package/chunk-FGXG6OLW.js +0 -34
  394. package/chunk-G22P2J7O.js +0 -1775
  395. package/chunk-HEVRQGGH.js +0 -106
  396. package/chunk-HHXF57CL.js +0 -180
  397. package/chunk-HI5RS2O4.js +0 -2109
  398. package/chunk-HJTI7RZV.js +0 -94
  399. package/chunk-HRWRIPTB.js +0 -531
  400. package/chunk-HYCVEESH.js +0 -2824
  401. package/chunk-I42VC5KR.js +0 -15
  402. package/chunk-IB5AR52X.js +0 -15
  403. package/chunk-IIRJ4P4I.js +0 -24
  404. package/chunk-IT3ZZRJE.js +0 -12
  405. package/chunk-IV6VUVLJ.js +0 -88
  406. package/chunk-J42X32PV.js +0 -472
  407. package/chunk-JDMWYVUF.js +0 -449
  408. package/chunk-JKVOKKMQ.js +0 -53
  409. package/chunk-JRTNUU5Z.js +0 -54
  410. package/chunk-K7HLFORE.js +0 -226
  411. package/chunk-KGBASAB5.js +0 -74
  412. package/chunk-KGKTN2NX.js +0 -25
  413. package/chunk-KX6YBIHG.js +0 -8
  414. package/chunk-KYHNSSL2.js +0 -62
  415. package/chunk-KZO2MTVM.js +0 -140
  416. package/chunk-LKZPX6YH.js +0 -0
  417. package/chunk-LLP2NDED.js +0 -201
  418. package/chunk-LOFRSJX2.js +0 -47
  419. package/chunk-M75RM77T.js +0 -3970
  420. package/chunk-MDAYRIP7.js +0 -1889
  421. package/chunk-MI6HRMCK.js +0 -25
  422. package/chunk-MTNQNLSE.js +0 -1029
  423. package/chunk-NH4PUEWK.js +0 -762
  424. package/chunk-NHLLXINQ.js +0 -8
  425. package/chunk-NTUNHTJV.js +0 -40
  426. package/chunk-OJKUU3LP.js +0 -67
  427. package/chunk-OQH3TAB7.js +0 -299
  428. package/chunk-P62DHV4F.js +0 -443
  429. package/chunk-PHIERFHT.js +0 -574
  430. package/chunk-PKDFU6MY.js +0 -102
  431. package/chunk-PL5RKESU.js +0 -40
  432. package/chunk-PSJJBBWV.js +0 -42
  433. package/chunk-QKM55LP2.js +0 -739
  434. package/chunk-QQ56R7KS.js +0 -88
  435. package/chunk-QYPE3TS3.js +0 -43
  436. package/chunk-REAE2SZK.js +0 -62
  437. package/chunk-RGQ4UUWZ.js +0 -208
  438. package/chunk-RIRFHJTW.js +0 -353
  439. package/chunk-RYMLMTPZ.js +0 -547
  440. package/chunk-SSGTV4FC.js +0 -303
  441. package/chunk-SVKWZ3EG.js +0 -607
  442. package/chunk-T7KODHYS.js +0 -317
  443. package/chunk-TGVVE5BA.js +0 -3085
  444. package/chunk-TKLBBR7P.js +0 -779
  445. package/chunk-TZXPT53C.js +0 -8
  446. package/chunk-U67V476Y.js +0 -35
  447. package/chunk-UEILX4EV.js +0 -15
  448. package/chunk-VIWDGTDA.js +0 -8
  449. package/chunk-VXUQWCEZ.js +0 -138
  450. package/chunk-W5GKF5ZW.js +0 -32
  451. package/chunk-WDWZPASX.js +0 -29
  452. package/chunk-WX266G2C.js +0 -9594
  453. package/chunk-YCITCYSJ.js +0 -356
  454. package/chunk-Z3KTXWWB.js +0 -76
  455. package/chunk-ZC3CMUKU.js +0 -322
  456. package/chunk-ZSZBHRLP.js +0 -1710
  457. package/chunk-ZV7ZY46L.js +0 -1343
  458. package/cliAgentConfigHelpers-WB2S7PDO.js +0 -47
  459. package/cliAuthorityBrokerClient-3SKOA7OZ.js +0 -23
  460. package/cliAuthorityBrokerProcess-BMBVXPKU.js +0 -24
  461. package/cliAuthorityStoreDriver-6FE3BJNB.js +0 -20
  462. package/cliEnvHelpers-7V5ZWUJA.js +0 -34
  463. package/cliExecutor-N3445G2Z.js +0 -45
  464. package/cliLocalAgentRecordReader-QKKRK53P.js +0 -113
  465. package/cloudAutomationCommands-S52NKCLL.js +0 -310
  466. package/contentThunks-ERA42OXW.js +0 -100
  467. package/cooldownCommands-ZFDAL4MR.js +0 -79
  468. package/createAgentAutomationAction-DMD2VDPI.js +0 -173
  469. package/createDialogAction-3SPOJQAK.js +0 -87
  470. package/createPageAction-AVXUMZVT.js +0 -91
  471. package/cursorProvider-2RACMEMF.js +0 -6123
  472. package/db-LTHLW7QA.js +0 -178
  473. package/dbSlice-WNUHTF4C.js +0 -76
  474. package/deleteDbKey-KV6MYBAI.js +0 -87
  475. package/desktopFolderProjects-4POAMVJN.js +0 -45
  476. package/dialogCommands-4MOLJW4G.js +0 -165
  477. package/dialogMessageRecord-2HJTEXQX.js +0 -7
  478. package/dialogNotifyCommand-YL2GFKLO.js +0 -45
  479. package/dialogSlice-Q7H2YVNO.js +0 -200
  480. package/dialogUsageCommand-IO2BQKL2.js +0 -31
  481. package/docCreateCommands-OYLRBK2M.js +0 -255
  482. package/docDeleteCommands-3NF6QPJU.js +0 -226
  483. package/docReadCommands-CBAERJAP.js +0 -184
  484. package/docStore-GWPFDV6Y.js +0 -89
  485. package/docUpdateCommands-BAMCGX6F.js +0 -326
  486. package/ebookDownloaderAgentCommand-NOIZ6U7Y.js +0 -675
  487. package/fetchMessages-P7FSCSXV.js +0 -19
  488. package/getPricing-KNXVEIUI.js +0 -40
  489. package/hostCredentialCreate-2VEYBXJV.js +0 -402
  490. package/i18n-SAK6DDY4.js +0 -51
  491. package/keys-FXEGMKSG.js +0 -183
  492. package/legacyMigration-TF4SYJCZ.js +0 -19
  493. package/levelAuthorityStore-L5SVDM5O.js +0 -10
  494. package/localAutomationCommands-XSK7SM7I.js +0 -199
  495. package/localAutomationRuntime-5WBO7HGQ.js +0 -61
  496. package/localRecall-BDYKXB46.js +0 -17
  497. package/localRuntimeAdapter-Y6H6XRIH.js +0 -310
  498. package/localRuntimeAuthority-Q5C2KWGF.js +0 -45
  499. package/localRuntimeDb-MM3DINZM.js +0 -12
  500. package/machineInfo-HNPJHQFU.js +0 -14
  501. package/machineWsRunDispatch-Y5SJGCEE.js +0 -228
  502. package/models-TOXYINNM.js +0 -10
  503. package/oauthTokenStore-RUYNYALS.js +0 -24
  504. package/overlay-JA3SPVUS.js +0 -15
  505. package/parityCommands-5OCBPVES.js +0 -613
  506. package/processSpawn-6GEO77KV.js +0 -11
  507. package/profileConfig-KOWK4HOG.js +0 -49
  508. package/projectArchive-WE3VVPZ2.js +0 -132
  509. package/providerPresetApply-YCVSP2WX.js +0 -235
  510. package/providerRegistry-26PAUYH2.js +0 -24
  511. package/read-D4WYJQJQ.js +0 -32
  512. package/readDocTool-3S3OQFOH.js +0 -22
  513. package/rememberExplicit-ZPI6KK5M.js +0 -16
  514. package/remove-AHRMUDMH.js +0 -32
  515. package/removeDialogAgentAction-AALRBFSA.js +0 -81
  516. package/secretCommands-2PSS3QNZ.js +0 -24
  517. package/setDialogExtraReferencesAction-SLHQ3GYL.js +0 -39
  518. package/setPrimaryDialogAgentAction-XKCSGJ7M.js +0 -96
  519. package/skillDiscovery-IUEZZG2B.js +0 -29
  520. package/skillSummaryMarker-62UW7HI7.js +0 -9
  521. package/slateToRenderMarkdown-R3X74MCX.js +0 -7
  522. package/slateUtils-ESQAJ6RN.js +0 -19
  523. package/store-WSAVTR32.js +0 -50
  524. package/switchDialogAgentAction-YJIWQGIR.js +0 -70
  525. package/tombstones-FQQMEDOW.js +0 -32
  526. package/toolApiClient-FVXTIIEN.js +0 -42
  527. package/tools-WN4AVSNS.js +0 -147
  528. package/tuiRestart-LU2BDLAW.js +0 -50
  529. package/tuiSummaryLlmCaller-Z2ZVBIGN.js +0 -53
  530. package/updateCommands-4QP7WJLA.js +0 -63
  531. package/usageCommand-AZX7D3LB.js +0 -31
  532. package/usageRebuildCommand-XV5QQCHK.js +0 -623
  533. package/userDataMerge-HT2ZVHBJ.js +0 -13
  534. package/windowsSelfUpdate-5OFKSW6Y.js +0 -14
  535. package/workContext-ZAW6VXT7.js +0 -18
  536. package/workContextAccess-VU5I4LKZ.js +0 -11
  537. package/workContextWriteNotice-YCSSMHN4.js +0 -7
  538. /package/{chunk-BYXBJQAS.js → chunk-0bcc25vg.js} +0 -0
@@ -1,11 +1,12 @@
1
1
  import {
2
2
  parseResetsInMs
3
- } from "./chunk-EWQ3HGNZ.js";
3
+ } from "./chunk-b00vzjkb.js";
4
4
 
5
5
  // packages/ai/agent/quotaSnapshot.ts
6
6
  function normalizeHeaders(headers) {
7
7
  const out = {};
8
- if (!headers) return out;
8
+ if (!headers)
9
+ return out;
9
10
  if (typeof headers.get === "function") {
10
11
  headers.forEach((value, key) => {
11
12
  out[key.toLowerCase()] = value;
@@ -13,48 +14,59 @@ function normalizeHeaders(headers) {
13
14
  return out;
14
15
  }
15
16
  for (const [key, value] of Object.entries(headers)) {
16
- if (typeof value === "string") out[key.toLowerCase()] = value;
17
+ if (typeof value === "string")
18
+ out[key.toLowerCase()] = value;
17
19
  }
18
20
  return out;
19
21
  }
20
22
  function readNumber(raw) {
21
- if (typeof raw === "number" && Number.isFinite(raw)) return raw >= 0 ? raw : void 0;
23
+ if (typeof raw === "number" && Number.isFinite(raw))
24
+ return raw >= 0 ? raw : undefined;
22
25
  if (typeof raw === "string") {
23
26
  const n = Number(raw.trim());
24
- if (Number.isFinite(n) && n >= 0) return n;
27
+ if (Number.isFinite(n) && n >= 0)
28
+ return n;
25
29
  }
26
- return void 0;
30
+ return;
27
31
  }
28
32
  function readResetAt(raw, now) {
29
33
  if (typeof raw === "number" && Number.isFinite(raw)) {
30
- if (raw >= 1e12) return raw;
31
- if (raw >= 1e9) return raw * 1e3;
32
- return raw > 0 ? now + raw * 1e3 : now;
34
+ if (raw >= 1000000000000)
35
+ return raw;
36
+ if (raw >= 1e9)
37
+ return raw * 1000;
38
+ return raw > 0 ? now + raw * 1000 : now;
33
39
  }
34
- if (typeof raw !== "string") return void 0;
40
+ if (typeof raw !== "string")
41
+ return;
35
42
  const text = raw.trim();
36
- if (!text) return void 0;
43
+ if (!text)
44
+ return;
37
45
  const msMatch = /^(\d+(?:\.\d+)?)ms$/i.exec(text);
38
46
  let dur;
39
47
  if (msMatch) {
40
- dur = Number(msMatch[1]) / 1e3;
48
+ dur = Number(msMatch[1]) / 1000;
41
49
  } else {
42
50
  const m = /^(?:(\d+(?:\.\d+)?)h)?(?:(\d+(?:\.\d+)?)m)?(?:(\d+(?:\.\d+)?)s)?$/i.exec(text);
43
51
  dur = m && (m[1] || m[2] || m[3]) ? Number(m[1] ?? 0) * 3600 + Number(m[2] ?? 0) * 60 + Number(m[3] ?? 0) : NaN;
44
52
  }
45
- if (Number.isFinite(dur)) return now + dur * 1e3;
53
+ if (Number.isFinite(dur))
54
+ return now + dur * 1000;
46
55
  const n = Number(text);
47
56
  if (Number.isFinite(n)) {
48
- if (n >= 1e12) return n;
49
- if (n >= 1e9) return n * 1e3;
50
- return n > 0 ? now + n * 1e3 : now;
57
+ if (n >= 1000000000000)
58
+ return n;
59
+ if (n >= 1e9)
60
+ return n * 1000;
61
+ return n > 0 ? now + n * 1000 : now;
51
62
  }
52
63
  const parsed = Date.parse(text);
53
- return Number.isFinite(parsed) ? parsed : void 0;
64
+ return Number.isFinite(parsed) ? parsed : undefined;
54
65
  }
55
66
  function readUtilization(raw) {
56
67
  const n = readNumber(raw);
57
- if (n === void 0) return void 0;
68
+ if (n === undefined)
69
+ return;
58
70
  return n > 1 ? n / 100 : n;
59
71
  }
60
72
  function mergeWindow(into, win) {
@@ -63,43 +75,55 @@ function mergeWindow(into, win) {
63
75
  into.set(win.scope, { ...win });
64
76
  return;
65
77
  }
66
- if (win.resetAt !== void 0) {
67
- existing.resetAt = existing.resetAt === void 0 ? win.resetAt : Math.max(existing.resetAt, win.resetAt);
78
+ if (win.resetAt !== undefined) {
79
+ existing.resetAt = existing.resetAt === undefined ? win.resetAt : Math.max(existing.resetAt, win.resetAt);
68
80
  }
69
- if (win.remaining !== void 0) {
70
- existing.remaining = existing.remaining === void 0 ? win.remaining : Math.min(existing.remaining, win.remaining);
81
+ if (win.remaining !== undefined) {
82
+ existing.remaining = existing.remaining === undefined ? win.remaining : Math.min(existing.remaining, win.remaining);
71
83
  }
72
- if (win.limit !== void 0) {
73
- existing.limit = existing.limit === void 0 ? win.limit : Math.min(existing.limit, win.limit);
84
+ if (win.limit !== undefined) {
85
+ existing.limit = existing.limit === undefined ? win.limit : Math.min(existing.limit, win.limit);
74
86
  }
75
- if (win.utilization !== void 0) {
76
- existing.utilization = existing.utilization === void 0 ? win.utilization : Math.max(existing.utilization, win.utilization);
87
+ if (win.utilization !== undefined) {
88
+ existing.utilization = existing.utilization === undefined ? win.utilization : Math.max(existing.utilization, win.utilization);
77
89
  }
78
- if (win.unit !== void 0 && existing.unit === void 0) existing.unit = win.unit;
90
+ if (win.unit !== undefined && existing.unit === undefined)
91
+ existing.unit = win.unit;
79
92
  existing.source = win.source;
80
93
  }
94
+ var SUBSCRIPTION_PERIOD_SCOPES = new Set([
95
+ "daily",
96
+ "weekly",
97
+ "monthly",
98
+ "credits",
99
+ "extra-usage"
100
+ ]);
81
101
  function parseQuotaWindowScope(scope) {
82
102
  const matched = /^(gemini|3p|hydrogen|argon)-(.+)$/.exec(scope);
83
103
  return matched ? { family: matched[1], period: matched[2] } : { period: scope };
84
104
  }
85
105
  function resolveQuotaWindowFamily(model) {
86
- if (typeof model !== "string" || !model.trim()) return void 0;
87
- if (/(?:^|[/-])gemini-[^/]*hydrogen(?:-|$)/i.test(model)) return "hydrogen";
88
- if (/(?:^|[/-])gemini-[^/]*argon(?:-|$)/i.test(model)) return "argon";
106
+ if (typeof model !== "string" || !model.trim())
107
+ return;
108
+ if (/(?:^|[/-])gemini-[^/]*hydrogen(?:-|$)/i.test(model))
109
+ return "hydrogen";
110
+ if (/(?:^|[/-])gemini-[^/]*argon(?:-|$)/i.test(model))
111
+ return "argon";
89
112
  return /gemini/i.test(model) ? "gemini" : "3p";
90
113
  }
91
114
  function isQuotaWindowRelevantToFamily(scope, family, source) {
92
- if (scope === "gemini-5h" && source?.endsWith(":fetchAvailableModels")) return false;
93
- if (typeof scope !== "string") return true;
115
+ if (scope === "gemini-5h" && source?.endsWith(":fetchAvailableModels"))
116
+ return false;
117
+ if (typeof scope !== "string")
118
+ return true;
94
119
  const scopeFamily = parseQuotaWindowScope(scope).family;
95
- return scopeFamily === void 0 || family === void 0 || scopeFamily === family;
120
+ return scopeFamily === undefined || family === undefined || scopeFamily === family;
96
121
  }
97
122
  function selectQuotaWindowsForModel(quota, now, model) {
98
- if (!quota || !Array.isArray(quota.windows)) return [];
123
+ if (!quota || !Array.isArray(quota.windows))
124
+ return [];
99
125
  const family = resolveQuotaWindowFamily(model);
100
- return quota.windows.filter(
101
- (window) => !isQuotaWindowExpired(window, now) && isQuotaWindowRelevantToFamily(window?.scope, family, window?.source)
102
- );
126
+ return quota.windows.filter((window) => !isQuotaWindowExpired(window, now) && isQuotaWindowRelevantToFamily(window?.scope, family, window?.source));
103
127
  }
104
128
  function isQuotaWindowExpired(window, now) {
105
129
  const resetAt = window?.resetAt;
@@ -110,12 +134,13 @@ function scanOpenAiRateLimitHeaders(headers, now, out) {
110
134
  const remaining = readNumber(headers[`x-ratelimit-remaining-${kind}`]);
111
135
  const limit = readNumber(headers[`x-ratelimit-limit-${kind}`]);
112
136
  const resetAt = readResetAt(headers[`x-ratelimit-reset-${kind}`], now);
113
- if (remaining === void 0 && limit === void 0 && resetAt === void 0) continue;
137
+ if (remaining === undefined && limit === undefined && resetAt === undefined)
138
+ continue;
114
139
  mergeWindow(out, {
115
140
  scope: kind,
116
- ...remaining !== void 0 ? { remaining } : {},
117
- ...limit !== void 0 ? { limit } : {},
118
- ...resetAt !== void 0 ? { resetAt } : {},
141
+ ...remaining !== undefined ? { remaining } : {},
142
+ ...limit !== undefined ? { limit } : {},
143
+ ...resetAt !== undefined ? { resetAt } : {},
119
144
  unit: kind,
120
145
  source: `x-ratelimit-*-${kind}`
121
146
  });
@@ -123,12 +148,12 @@ function scanOpenAiRateLimitHeaders(headers, now, out) {
123
148
  const genericRemaining = readNumber(headers["x-ratelimit-remaining"]);
124
149
  const genericLimit = readNumber(headers["x-ratelimit-limit"]);
125
150
  const genericReset = readResetAt(headers["x-ratelimit-reset"], now);
126
- if (genericRemaining !== void 0 || genericLimit !== void 0 || genericReset !== void 0) {
151
+ if (genericRemaining !== undefined || genericLimit !== undefined || genericReset !== undefined) {
127
152
  mergeWindow(out, {
128
153
  scope: "requests",
129
- ...genericRemaining !== void 0 ? { remaining: genericRemaining } : {},
130
- ...genericLimit !== void 0 ? { limit: genericLimit } : {},
131
- ...genericReset !== void 0 ? { resetAt: genericReset } : {},
154
+ ...genericRemaining !== undefined ? { remaining: genericRemaining } : {},
155
+ ...genericLimit !== undefined ? { limit: genericLimit } : {},
156
+ ...genericReset !== undefined ? { resetAt: genericReset } : {},
132
157
  unit: "requests",
133
158
  source: "x-ratelimit"
134
159
  });
@@ -136,18 +161,14 @@ function scanOpenAiRateLimitHeaders(headers, now, out) {
136
161
  }
137
162
  function scanAnthropicUnifiedHeaders(headers, now, out) {
138
163
  for (const scope of ["5h", "7d"]) {
139
- const utilization = readUtilization(
140
- headers[`anthropic-ratelimit-unified-${scope}-utilization`]
141
- );
142
- const resetAt = readResetAt(
143
- headers[`anthropic-ratelimit-unified-${scope}-reset`],
144
- now
145
- );
146
- if (utilization === void 0 && resetAt === void 0) continue;
164
+ const utilization = readUtilization(headers[`anthropic-ratelimit-unified-${scope}-utilization`]);
165
+ const resetAt = readResetAt(headers[`anthropic-ratelimit-unified-${scope}-reset`], now);
166
+ if (utilization === undefined && resetAt === undefined)
167
+ continue;
147
168
  mergeWindow(out, {
148
169
  scope,
149
- ...utilization !== void 0 ? { utilization } : {},
150
- ...resetAt !== void 0 ? { resetAt } : {},
170
+ ...utilization !== undefined ? { utilization } : {},
171
+ ...resetAt !== undefined ? { resetAt } : {},
151
172
  source: `anthropic-ratelimit-unified-${scope}`
152
173
  });
153
174
  }
@@ -162,103 +183,112 @@ function scanGoogleQuotaHeaders(headers, now, out) {
162
183
  const remaining = readNumber(headers[`${prefix}remaining`]);
163
184
  const limit = readNumber(headers[`${prefix}limit`]);
164
185
  const resetAt = readResetAt(headers[`${prefix}reset`], now) ?? genericReset;
165
- if (remaining === void 0 && limit === void 0 && resetAt === void 0) continue;
186
+ if (remaining === undefined && limit === undefined && resetAt === undefined)
187
+ continue;
166
188
  mergeWindow(out, {
167
189
  scope,
168
- ...remaining !== void 0 ? { remaining } : {},
169
- ...limit !== void 0 ? { limit } : {},
170
- ...resetAt !== void 0 ? { resetAt } : {},
190
+ ...remaining !== undefined ? { remaining } : {},
191
+ ...limit !== undefined ? { limit } : {},
192
+ ...resetAt !== undefined ? { resetAt } : {},
171
193
  source: `${prefix}*`
172
194
  });
173
195
  }
174
196
  }
175
197
  function scanSub2ApiHeaders(headers, now, out) {
176
198
  const FIELD_RE = /^x-sub2api-quota(?:-([a-z0-9][a-z0-9._:-]*))?-(remaining|limit|reset)$/;
177
- const groups = /* @__PURE__ */ new Map();
199
+ const groups = new Map;
178
200
  for (const [name, value] of Object.entries(headers)) {
179
201
  const m = FIELD_RE.exec(name);
180
- if (!m) continue;
202
+ if (!m)
203
+ continue;
181
204
  const scope = m[1] ?? "sub2api";
182
205
  const group = groups.get(scope) ?? {};
183
206
  if (m[2] === "reset") {
184
207
  const at = readResetAt(value, now);
185
- if (at !== void 0) group.resetAt = at;
208
+ if (at !== undefined)
209
+ group.resetAt = at;
186
210
  } else if (m[2] === "remaining") {
187
211
  const n = readNumber(value);
188
- if (n !== void 0) group.remaining = n;
212
+ if (n !== undefined)
213
+ group.remaining = n;
189
214
  } else if (m[2] === "limit") {
190
215
  const n = readNumber(value);
191
- if (n !== void 0) group.limit = n;
216
+ if (n !== undefined)
217
+ group.limit = n;
192
218
  }
193
219
  groups.set(scope, group);
194
220
  }
195
221
  for (const [scope, g] of groups) {
196
222
  mergeWindow(out, {
197
223
  scope,
198
- ...g.remaining !== void 0 ? { remaining: g.remaining } : {},
199
- ...g.limit !== void 0 ? { limit: g.limit } : {},
200
- ...g.resetAt !== void 0 ? { resetAt: g.resetAt } : {},
224
+ ...g.remaining !== undefined ? { remaining: g.remaining } : {},
225
+ ...g.limit !== undefined ? { limit: g.limit } : {},
226
+ ...g.resetAt !== undefined ? { resetAt: g.resetAt } : {},
201
227
  source: "x-sub2api-quota"
202
228
  });
203
229
  }
204
230
  }
205
231
  function scanBody(body, now, out) {
206
- if (!body || typeof body !== "object") return;
232
+ if (!body || typeof body !== "object")
233
+ return;
207
234
  const root = body;
208
- const error = root.error && typeof root.error === "object" ? root.error : void 0;
235
+ const error = root.error && typeof root.error === "object" ? root.error : undefined;
209
236
  for (const holder of [root, error]) {
210
237
  const quota = holder?.quota;
211
- if (!quota || typeof quota !== "object") continue;
238
+ if (!quota || typeof quota !== "object")
239
+ continue;
212
240
  const q = quota;
213
241
  const remaining = readNumber(q.remaining ?? q.remaining_amount);
214
242
  const limit = readNumber(q.limit ?? q.total ?? q.quota);
215
- const resetAt = readResetAt(
216
- q.reset_at ?? q.resets_at ?? q.resetAt ?? q.resetTime ?? q.reset_time,
217
- now
218
- );
219
- const unit = typeof q.unit === "string" && q.unit ? q.unit : void 0;
220
- if (remaining === void 0 && limit === void 0 && resetAt === void 0) continue;
243
+ const resetAt = readResetAt(q.reset_at ?? q.resets_at ?? q.resetAt ?? q.resetTime ?? q.reset_time, now);
244
+ const unit = typeof q.unit === "string" && q.unit ? q.unit : undefined;
245
+ if (remaining === undefined && limit === undefined && resetAt === undefined)
246
+ continue;
221
247
  const scope = typeof q.scope === "string" && q.scope ? q.scope : "daily";
222
248
  mergeWindow(out, {
223
249
  scope,
224
- ...remaining !== void 0 ? { remaining } : {},
225
- ...limit !== void 0 ? { limit } : {},
226
- ...resetAt !== void 0 ? { resetAt } : {},
250
+ ...remaining !== undefined ? { remaining } : {},
251
+ ...limit !== undefined ? { limit } : {},
252
+ ...resetAt !== undefined ? { resetAt } : {},
227
253
  ...unit ? { unit } : {},
228
254
  source: "body.quota"
229
255
  });
230
256
  }
231
257
  const details = error?.details ?? root.details;
232
- if (!Array.isArray(details)) return;
258
+ if (!Array.isArray(details))
259
+ return;
233
260
  let retryResetAt;
234
- const quotaScopes = /* @__PURE__ */ new Set();
261
+ const quotaScopes = new Set;
235
262
  for (const item of details) {
236
- if (!item || typeof item !== "object") continue;
263
+ if (!item || typeof item !== "object")
264
+ continue;
237
265
  const record = item;
238
266
  const type = typeof record["@type"] === "string" ? record["@type"] : "";
239
267
  if (type.includes("RetryInfo")) {
240
268
  const at = readResetAt(record.retryDelay ?? record.retry_delay, now);
241
- if (at !== void 0) retryResetAt = retryResetAt === void 0 ? at : Math.max(retryResetAt, at);
269
+ if (at !== undefined)
270
+ retryResetAt = retryResetAt === undefined ? at : Math.max(retryResetAt, at);
242
271
  }
243
272
  if (type.includes("QuotaFailure") && Array.isArray(record.violations)) {
244
273
  for (const v of record.violations) {
245
- const metric = v && typeof v === "object" && typeof v.quotaMetric === "string" ? v.quotaMetric : void 0;
246
- if (metric) quotaScopes.add(`model:${metric}`);
274
+ const metric = v && typeof v === "object" && typeof v.quotaMetric === "string" ? v.quotaMetric : undefined;
275
+ if (metric)
276
+ quotaScopes.add(`model:${metric}`);
247
277
  }
248
278
  }
249
279
  }
250
- if (retryResetAt !== void 0 || quotaScopes.size > 0) {
280
+ if (retryResetAt !== undefined || quotaScopes.size > 0) {
251
281
  if (quotaScopes.size === 0) {
252
282
  mergeWindow(out, {
253
283
  scope: "user",
254
- ...retryResetAt !== void 0 ? { resetAt: retryResetAt } : {},
284
+ ...retryResetAt !== undefined ? { resetAt: retryResetAt } : {},
255
285
  source: "body.details.RetryInfo"
256
286
  });
257
287
  }
258
288
  for (const scope of quotaScopes) {
259
289
  mergeWindow(out, {
260
290
  scope,
261
- ...retryResetAt !== void 0 ? { resetAt: retryResetAt } : {},
291
+ ...retryResetAt !== undefined ? { resetAt: retryResetAt } : {},
262
292
  source: "body.details.QuotaFailure"
263
293
  });
264
294
  }
@@ -266,23 +296,26 @@ function scanBody(body, now, out) {
266
296
  }
267
297
  function extractQuotaSnapshot(provider, status, headers, body, now) {
268
298
  try {
269
- if (!Number.isFinite(now)) return void 0;
299
+ if (!Number.isFinite(now))
300
+ return;
270
301
  const bag = normalizeHeaders(headers);
271
- const windows = /* @__PURE__ */ new Map();
302
+ const windows = new Map;
272
303
  scanOpenAiRateLimitHeaders(bag, now, windows);
273
304
  scanAnthropicUnifiedHeaders(bag, now, windows);
274
305
  scanGoogleQuotaHeaders(bag, now, windows);
275
306
  scanSub2ApiHeaders(bag, now, windows);
276
307
  scanBody(body, now, windows);
277
- if (windows.size === 0) return void 0;
308
+ if (windows.size === 0)
309
+ return;
278
310
  return { windows: [...windows.values()], observedAt: now };
279
311
  } catch {
280
- return void 0;
312
+ return;
281
313
  }
282
314
  }
283
315
  function findTightestQuotaWindow(quota, now = Date.now(), options) {
284
316
  const windows = selectQuotaWindowsForModel(quota, now, options?.model);
285
- if (windows.length === 0) return void 0;
317
+ if (windows.length === 0)
318
+ return;
286
319
  let best;
287
320
  let bestScore = -Infinity;
288
321
  for (const w of windows) {
@@ -309,60 +342,63 @@ function formatQuotaSummary(quota, now = Date.now(), options) {
309
342
  const planText = formatPlanLabel(quota?.plan);
310
343
  const planName = typeof quota?.plan?.name === "string" ? quota.plan.name.trim() : "";
311
344
  const tightest = findTightestQuotaWindow(quota, now, { model: options?.model });
312
- if (!tightest) return compact ? planName || void 0 : planText;
345
+ if (!tightest)
346
+ return compact ? planName || undefined : planText;
313
347
  const parts = [];
314
348
  if (typeof tightest.utilization === "number") {
315
349
  const pct = Math.round(tightest.utilization * 100);
316
- parts.push(`${pct}%\u5DF2\u7528`);
350
+ parts.push(`${pct}%已用`);
317
351
  } else if (typeof tightest.remaining === "number") {
318
352
  if (typeof tightest.limit === "number") {
319
353
  parts.push(`${tightest.remaining}/${tightest.limit}${tightest.unit ? ` ${tightest.unit}` : ""}`);
320
354
  } else {
321
- parts.push(`\u4F59${tightest.remaining}${tightest.unit ? ` ${tightest.unit}` : ""}`);
355
+ parts.push(`余${tightest.remaining}${tightest.unit ? ` ${tightest.unit}` : ""}`);
322
356
  }
323
357
  }
324
358
  if (compact) {
325
- const head = parts.length > 0 ? parts[0] : void 0;
326
- return [planName || void 0, head].filter(Boolean).join(" \xB7 ") || void 0;
359
+ const head = parts.length > 0 ? parts[0] : undefined;
360
+ return [planName || undefined, head].filter(Boolean).join(" · ") || undefined;
327
361
  }
328
362
  if (tightest.scope && tightest.scope !== "user" && tightest.scope !== "project" && tightest.scope !== tightest.unit) {
329
363
  parts.push(tightest.scope);
330
364
  }
331
365
  if (typeof tightest.resetAt === "number" && tightest.resetAt > now) {
332
- const diffSec = Math.round((tightest.resetAt - now) / 1e3);
366
+ const diffSec = Math.round((tightest.resetAt - now) / 1000);
333
367
  if (diffSec < 60) {
334
- parts.push(`${diffSec}s\u540E\u91CD\u7F6E`);
368
+ parts.push(`${diffSec}s后重置`);
335
369
  } else if (diffSec < 3600) {
336
- parts.push(`${Math.round(diffSec / 60)}m\u540E\u91CD\u7F6E`);
370
+ parts.push(`${Math.round(diffSec / 60)}m后重置`);
337
371
  } else if (diffSec < 86400) {
338
372
  const hours = (diffSec / 3600).toFixed(1).replace(/\.0$/, "");
339
- parts.push(`${hours}h\u540E\u91CD\u7F6E`);
373
+ parts.push(`${hours}h后重置`);
340
374
  } else {
341
375
  const days = (diffSec / 86400).toFixed(1).replace(/\.0$/, "");
342
- parts.push(`${days}d\u540E\u91CD\u7F6E`);
376
+ parts.push(`${days}d后重置`);
343
377
  }
344
378
  }
345
379
  const onlyScope = parts.length === 0 || parts.length === 1 && parts[0] === tightest.scope;
346
- if (onlyScope) return planText;
347
- return [planText, ...parts].filter(Boolean).join(" \xB7 ");
380
+ if (onlyScope)
381
+ return planText;
382
+ return [planText, ...parts].filter(Boolean).join(" · ");
348
383
  }
349
384
  function formatPlanLabel(plan) {
350
385
  const name = typeof plan?.name === "string" ? plan.name.trim() : "";
351
- if (!name) return void 0;
352
- const credits = typeof plan?.monthlyCreditsUsd === "number" && Number.isFinite(plan.monthlyCreditsUsd) && plan.monthlyCreditsUsd > 0 ? `\u6708\u5EA6\u989D\u5EA6 $${plan.monthlyCreditsUsd}` : void 0;
353
- return [`${name} \u5957\u9910`, credits].filter(Boolean).join(" \xB7 ");
386
+ if (!name)
387
+ return;
388
+ const credits = typeof plan?.monthlyCreditsUsd === "number" && Number.isFinite(plan.monthlyCreditsUsd) && plan.monthlyCreditsUsd > 0 ? `月度额度 $${plan.monthlyCreditsUsd}` : undefined;
389
+ return [`${name} 套餐`, credits].filter(Boolean).join(" · ");
354
390
  }
355
391
 
356
392
  // packages/ai/agent/agentAvailabilityShared.ts
357
- var DEFAULT_PROVIDER_RETRY_MS = 5 * 60 * 1e3;
358
- var THIN_RATE_LIMIT_COOLDOWN_MS = 60 * 1e3;
359
- var MAX_COOLDOWN_MS = 24 * 60 * 60 * 1e3;
393
+ var DEFAULT_PROVIDER_RETRY_MS = 5 * 60 * 1000;
394
+ var THIN_RATE_LIMIT_COOLDOWN_MS = 60 * 1000;
395
+ var MAX_COOLDOWN_MS = 24 * 60 * 60 * 1000;
360
396
  function clampCooldownDeadline(at, now) {
361
397
  const min = now;
362
398
  const max = now + MAX_COOLDOWN_MS;
363
399
  return Math.min(Math.max(at, min), max);
364
400
  }
365
- var SUBSCRIPTION_PERIODS = /* @__PURE__ */ new Set(["5h", "7d", "daily", "weekly", "monthly"]);
401
+ var SUBSCRIPTION_PERIODS = new Set(["5h", "7d", "daily", "weekly", "monthly"]);
366
402
  function isSubscriptionPeriodWindow(window) {
367
403
  const { period } = parseQuotaWindowScope(window.scope);
368
404
  return SUBSCRIPTION_PERIODS.has(period.trim().toLowerCase());
@@ -371,21 +407,26 @@ function isExhaustedWindow(window) {
371
407
  return window.remaining === 0 || typeof window.utilization === "number" && window.utilization >= 0.95;
372
408
  }
373
409
  function shouldClearCooldownFromQuota(entry, quota, now, options) {
374
- if (!(typeof entry.nextAvailableAt === "number" && entry.nextAvailableAt > now)) return false;
375
- if (typeof entry.markedAt !== "number" || !Number.isFinite(entry.markedAt)) return false;
376
- if (!quota || !(quota.observedAt > entry.markedAt)) return false;
410
+ if (!(typeof entry.nextAvailableAt === "number" && entry.nextAvailableAt > now))
411
+ return false;
412
+ if (typeof entry.markedAt !== "number" || !Number.isFinite(entry.markedAt))
413
+ return false;
414
+ if (!quota || !(quota.observedAt > entry.markedAt))
415
+ return false;
377
416
  const family = resolveQuotaWindowFamily(options?.model);
378
- const relevantWindows = quota.windows.filter(
379
- (window) => isQuotaWindowRelevantToFamily(window.scope, family, window.source)
380
- );
417
+ const relevantWindows = quota.windows.filter((window) => isQuotaWindowRelevantToFamily(window.scope, family, window.source));
381
418
  const subscriptionWindows = relevantWindows.filter(isSubscriptionPeriodWindow);
382
- if (subscriptionWindows.length === 0) return false;
383
- if (relevantWindows.some(isExhaustedWindow)) return false;
384
- if (subscriptionWindows.some((window) => isQuotaWindowExpired(window, now))) return false;
419
+ if (subscriptionWindows.length === 0)
420
+ return false;
421
+ if (relevantWindows.some(isExhaustedWindow))
422
+ return false;
423
+ if (subscriptionWindows.some((window) => isQuotaWindowExpired(window, now)))
424
+ return false;
385
425
  return subscriptionWindows.every((window) => {
386
426
  const hasUtilization = typeof window.utilization === "number";
387
427
  const hasRemaining = typeof window.remaining === "number";
388
- if (!hasUtilization && !hasRemaining) return false;
428
+ if (!hasUtilization && !hasRemaining)
429
+ return false;
389
430
  return (!hasUtilization || window.utilization < 0.95) && (!hasRemaining || window.remaining > 0);
390
431
  });
391
432
  }
@@ -393,9 +434,10 @@ function isAgentUnavailableNow(agent, now = Date.now()) {
393
434
  const at = agent?.nextAvailableAt;
394
435
  return typeof at === "number" && Number.isFinite(at) && at > now;
395
436
  }
396
- var QUOTA_SNAPSHOT_STALE_MS = 2 * 60 * 60 * 1e3;
437
+ var QUOTA_SNAPSHOT_STALE_MS = 2 * 60 * 60 * 1000;
397
438
  function isAdmissibleQuotaSnapshot(quota, now = Date.now()) {
398
- if (!quota || typeof quota !== "object") return false;
439
+ if (!quota || typeof quota !== "object")
440
+ return false;
399
441
  const observedAt = quota.observedAt;
400
442
  if (typeof observedAt !== "number" || !Number.isFinite(observedAt)) {
401
443
  return false;
@@ -411,9 +453,7 @@ function resolveAgentAvailability(agent, now = Date.now()) {
411
453
  const isAdmissible = isAdmissibleQuotaSnapshot(quota, now);
412
454
  const hasObservedAt = Boolean(quota) && typeof quota?.observedAt === "number" && Number.isFinite(quota.observedAt);
413
455
  const family = resolveQuotaWindowFamily(agent?.model);
414
- const relevantWindows = (quota?.windows ?? []).filter(
415
- (window) => isQuotaWindowRelevantToFamily(window?.scope, family, window?.source)
416
- );
456
+ const relevantWindows = (quota?.windows ?? []).filter((window) => isQuotaWindowRelevantToFamily(window?.scope, family, window?.source));
417
457
  const hasWindows = relevantWindows.length > 0;
418
458
  const hasValidQuota = isAdmissible && hasWindows;
419
459
  if (hasValidQuota) {
@@ -423,11 +463,14 @@ function resolveAgentAvailability(agent, now = Date.now()) {
423
463
  let maxResetAt;
424
464
  for (const w of relevantWindows) {
425
465
  const inspected = inspectQuotaWindowExhaustion(w, now);
426
- if (!inspected) continue;
427
- if (inspected.resetAt !== void 0 && inspected.resetAt > now) {
428
- if (inspected.remainingZero) hasActiveRemainingZero = true;
429
- if (inspected.utilizationHigh) hasActiveUtilizationHigh = true;
430
- maxResetAt = maxResetAt !== void 0 ? Math.max(maxResetAt, inspected.resetAt) : inspected.resetAt;
466
+ if (!inspected)
467
+ continue;
468
+ if (inspected.resetAt !== undefined && inspected.resetAt > now) {
469
+ if (inspected.remainingZero)
470
+ hasActiveRemainingZero = true;
471
+ if (inspected.utilizationHigh)
472
+ hasActiveUtilizationHigh = true;
473
+ maxResetAt = maxResetAt !== undefined ? Math.max(maxResetAt, inspected.resetAt) : inspected.resetAt;
431
474
  } else {
432
475
  hasWindowResetPending = true;
433
476
  }
@@ -436,7 +479,7 @@ function resolveAgentAvailability(agent, now = Date.now()) {
436
479
  return {
437
480
  status: "quota_exhausted",
438
481
  reason: hasActiveRemainingZero ? "quota_remaining_zero" : "quota_utilization_high",
439
- ...maxResetAt !== void 0 ? { resetAt: maxResetAt } : {}
482
+ ...maxResetAt !== undefined ? { resetAt: maxResetAt } : {}
440
483
  };
441
484
  }
442
485
  if (hasWindowResetPending) {
@@ -477,52 +520,58 @@ function resolveAgentAvailability(agent, now = Date.now()) {
477
520
  };
478
521
  }
479
522
  function readRetryAfterTimestamp(body, now) {
480
- if (!body || typeof body !== "object") return void 0;
523
+ if (!body || typeof body !== "object")
524
+ return;
481
525
  const root = body;
482
526
  const raw = root.retryAfter ?? root.retry_after ?? root["Retry-After"];
483
527
  if (typeof raw === "number" && Number.isFinite(raw)) {
484
- return raw > 1e12 ? raw : now + Math.max(0, raw) * 1e3;
528
+ return raw > 1000000000000 ? raw : now + Math.max(0, raw) * 1000;
485
529
  }
486
530
  if (typeof raw === "string") {
487
531
  const seconds = Number(raw.trim());
488
- if (Number.isFinite(seconds)) return now + Math.max(0, seconds) * 1e3;
532
+ if (Number.isFinite(seconds))
533
+ return now + Math.max(0, seconds) * 1000;
489
534
  const date = Date.parse(raw);
490
- if (Number.isFinite(date)) return date;
535
+ if (Number.isFinite(date))
536
+ return date;
491
537
  }
492
- return void 0;
538
+ return;
493
539
  }
494
540
  function readResetTimestamp(body, now) {
495
- if (!body || typeof body !== "object") return void 0;
541
+ if (!body || typeof body !== "object")
542
+ return;
496
543
  const root = body;
497
544
  const error = root.error && typeof root.error === "object" ? root.error : root;
498
545
  if (Array.isArray(error.details)) {
499
546
  for (const item of error.details) {
500
- if (!item || typeof item !== "object") continue;
547
+ if (!item || typeof item !== "object")
548
+ continue;
501
549
  const retryDelay = item.retryDelay;
502
550
  if (typeof retryDelay === "string") {
503
551
  const ms = parseResetsInMs(retryDelay);
504
- if (typeof ms === "number" && Number.isFinite(ms)) return now + ms;
552
+ if (typeof ms === "number" && Number.isFinite(ms))
553
+ return now + ms;
505
554
  }
506
555
  }
507
556
  }
508
- const details = !Array.isArray(error.details) && error.details && typeof error.details === "object" ? error.details : void 0;
557
+ const details = !Array.isArray(error.details) && error.details && typeof error.details === "object" ? error.details : undefined;
509
558
  const raw = error.resets_at ?? error.resetsAt ?? error.reset_at ?? error.resetAt ?? details?.resets_at ?? details?.resetsAt ?? details?.reset_at ?? details?.resetAt;
510
559
  if (typeof raw === "number" && Number.isFinite(raw)) {
511
- return raw > 1e12 ? raw : raw * 1e3;
560
+ return raw > 1000000000000 ? raw : raw * 1000;
512
561
  }
513
562
  if (typeof raw === "string") {
514
563
  const parsed = Date.parse(raw);
515
- if (Number.isFinite(parsed)) return parsed;
564
+ if (Number.isFinite(parsed))
565
+ return parsed;
516
566
  }
517
- return void 0;
567
+ return;
518
568
  }
519
569
  function parseResetAtText(value, now) {
520
- const m = value.match(
521
- /resets?\s+at\s+(\d{4}-\d{2}-\d{2}(?:[T ]\d{2}:\d{2}(?::\d{2})?(?:\.\d+)?(?:Z|[+-]\d{2}:?\d{2})?)?)/i
522
- );
523
- if (!m?.[1]) return void 0;
570
+ const m = value.match(/resets?\s+at\s+(\d{4}-\d{2}-\d{2}(?:[T ]\d{2}:\d{2}(?::\d{2})?(?:\.\d+)?(?:Z|[+-]\d{2}:?\d{2})?)?)/i);
571
+ if (!m?.[1])
572
+ return;
524
573
  const parsed = Date.parse(m[1]);
525
- return Number.isFinite(parsed) && parsed > now ? parsed : void 0;
574
+ return Number.isFinite(parsed) && parsed > now ? parsed : undefined;
526
575
  }
527
576
  function matchesPeriodicUsageLimitText(text) {
528
577
  return /(?:weekly|monthly)\s*(?:\([^)]*\)\s*)?usage\s+limit/i.test(text);
@@ -534,26 +583,26 @@ function isQuotaLimited403Body(body) {
534
583
  function parseExplicitAvailableAt(body, now, headers) {
535
584
  const headerRetryAfter = headers && typeof headers.get === "function" ? headers.get("retry-after") : headers?.["retry-after"] ?? headers?.["Retry-After"];
536
585
  const retryAfter = headerRetryAfter ? readRetryAfterTimestamp({ retryAfter: headerRetryAfter }, now) : readRetryAfterTimestamp(body, now);
537
- if (retryAfter !== void 0 && retryAfter > now) {
586
+ if (retryAfter !== undefined && retryAfter > now) {
538
587
  return clampCooldownDeadline(retryAfter, now);
539
588
  }
540
589
  const absolute = readResetTimestamp(body, now);
541
- if (absolute !== void 0 && absolute > now) {
590
+ if (absolute !== undefined && absolute > now) {
542
591
  return clampCooldownDeadline(absolute, now);
543
592
  }
544
593
  const text = typeof body === "string" ? body : JSON.stringify(body ?? "");
545
594
  const absoluteFromText = parseResetAtText(text, now);
546
- if (absoluteFromText !== void 0) {
595
+ if (absoluteFromText !== undefined) {
547
596
  return clampCooldownDeadline(absoluteFromText, now);
548
597
  }
549
598
  if (matchesPeriodicUsageLimitText(text)) {
550
599
  return clampCooldownDeadline(now + MAX_COOLDOWN_MS, now);
551
600
  }
552
601
  const relativeMs = parseResetsInMs(text);
553
- if (relativeMs !== void 0) {
602
+ if (relativeMs !== undefined) {
554
603
  return clampCooldownDeadline(now + relativeMs, now);
555
604
  }
556
- return void 0;
605
+ return;
557
606
  }
558
607
  var QUOTA_EXHAUSTED_TEXT_RE = /insufficient[_ ]?quota|quota\s*(?:(?:is|has|been|was|now|fully|completely|already|entirely)\s+)*(?:limit\s+)?(?:exhausted|depleted|used\s*up|reached|exceeded)|usage\s*limit\s*(?:reached|exceeded|exhausted)|(?:\b(?:weekly|monthly|5-?hour|5h|7-?day|7d)\s*(?:\([^)]*\)\s*)?limit\s*(?:reached|exceeded|exhausted|depleted)\b)|(?:reached|exceeded)\s+your\s+.*?(?:usage\s+)?limit|exceeded\s*your\s*(?:current\s*)?quota|insufficient[_\s-]?(?:balance|credits?)|balance\s*(?:is\s*)?(?:insufficient|too\s*low)|(?:额度|配额|用量)(?:已|已经|也)?(?:用尽|耗尽|用完|超限|不足)|(?:已达到|已达|超出|超过)[^。;,\n]{0,40}(?:用量上限|配额上限|额度上限)|余额(?:不足|不够|已用尽|已耗尽)/i;
559
608
  var NEGATED_QUOTA_TEXT_RE = /\b(?:not|no\s+longer|never|haven't|hasn't|isn't|aren't)\s+(?:(?:currently|really|actually|yet)\s+)?(?:quota\s+exhausted|limit\s+exhausted|exhausted|depleted|used\s*up|reached|exceeded|out\s+of\s+quota)\b/i;
@@ -561,17 +610,24 @@ var CAPACITY_SATURATED_TEXT_RE = /\b(?:is\s+at\s+capacity|at\s+capacity|capacity
561
610
  var NEGATED_CAPACITY_TEXT_RE = /\b(?:not|no\s+longer|never)\s+(?:(?:currently|really|actually|yet)\s+)?(?:at\s+capacity|capacity\s*(?:is\s*)?(?:saturated|exceeded|unavailable)|overloaded|over\s*capacity)\b/i;
562
611
  function isQuotaExhaustedText(body) {
563
612
  const text = typeof body === "string" ? body : JSON.stringify(body ?? "");
564
- if (!text) return false;
565
- if (/"(?:code|status_code)"\s*:\s*"?2056"?(?=\s*[,}])/.test(text)) return true;
566
- if (NEGATED_QUOTA_TEXT_RE.test(text)) return false;
613
+ if (!text)
614
+ return false;
615
+ if (/"(?:code|status_code)"\s*:\s*"?2056"?(?=\s*[,}])/.test(text))
616
+ return true;
617
+ if (NEGATED_QUOTA_TEXT_RE.test(text))
618
+ return false;
567
619
  return QUOTA_EXHAUSTED_TEXT_RE.test(text) || isQuotaLimited403Body(text);
568
620
  }
569
621
  function isCapacitySaturatedRateLimit(body, now, headers) {
570
- if (parseExplicitAvailableAt(body, now, headers) !== void 0) return false;
622
+ if (parseExplicitAvailableAt(body, now, headers) !== undefined)
623
+ return false;
571
624
  const text = typeof body === "string" ? body : JSON.stringify(body ?? "");
572
- if (!text) return false;
573
- if (isQuotaExhaustedText(text)) return false;
574
- if (NEGATED_CAPACITY_TEXT_RE.test(text)) return false;
625
+ if (!text)
626
+ return false;
627
+ if (isQuotaExhaustedText(text))
628
+ return false;
629
+ if (NEGATED_CAPACITY_TEXT_RE.test(text))
630
+ return false;
575
631
  return CAPACITY_SATURATED_TEXT_RE.test(text);
576
632
  }
577
633
  function resolveNextAvailableAt(body, now, headers) {
@@ -607,7 +663,8 @@ function mergeAvailabilityDeadline(currentDeadline, nextAvailableAt) {
607
663
  return typeof currentDeadline === "number" && Number.isFinite(currentDeadline) ? Math.max(currentDeadline, nextAvailableAt) : nextAvailableAt;
608
664
  }
609
665
  function isPublicOrSystemAgentRecord(agent) {
610
- if (!agent || typeof agent !== "object") return false;
666
+ if (!agent || typeof agent !== "object")
667
+ return false;
611
668
  for (const keyField of ["agentKey", "key", "id", "dbKey", "privateKey"]) {
612
669
  const rawKey = agent[keyField];
613
670
  if (typeof rawKey === "string") {
@@ -620,16 +677,19 @@ function isPublicOrSystemAgentRecord(agent) {
620
677
  return false;
621
678
  }
622
679
  function resolveAgentOwnerUserId(agent) {
623
- if (!agent || typeof agent !== "object") return void 0;
680
+ if (!agent || typeof agent !== "object")
681
+ return;
624
682
  if (isPublicOrSystemAgentRecord(agent)) {
625
- return void 0;
683
+ return;
626
684
  }
627
685
  for (const field of ["ownerUserId", "userId", "ownerId"]) {
628
686
  const value = agent[field];
629
687
  if (typeof value === "string") {
630
688
  const trimmed = value.trim();
631
- if (trimmed === "system" || trimmed === "pub") continue;
632
- if (trimmed) return trimmed;
689
+ if (trimmed === "system" || trimmed === "pub")
690
+ continue;
691
+ if (trimmed)
692
+ return trimmed;
633
693
  }
634
694
  }
635
695
  for (const keyField of ["agentKey", "key", "id", "dbKey", "privateKey"]) {
@@ -644,24 +704,30 @@ function resolveAgentOwnerUserId(agent) {
644
704
  }
645
705
  }
646
706
  }
647
- return void 0;
707
+ return;
648
708
  }
649
709
  function resolveCredentialCandidateKeys(key) {
650
- if (!key) return [];
710
+ if (!key)
711
+ return [];
651
712
  const trimmed = key.trim();
652
- if (!trimmed) return [];
653
- if (/\|quota:(?:gemini|3p|hydrogen|argon)$/.test(trimmed)) return [trimmed];
713
+ if (!trimmed)
714
+ return [];
715
+ if (/\|quota:(?:gemini|3p|hydrogen|argon)$/.test(trimmed))
716
+ return [trimmed];
654
717
  const candidates = [trimmed];
655
718
  const atIndex = trimmed.lastIndexOf("@");
656
719
  if (atIndex > 0) {
657
720
  const legacyKey = trimmed.slice(0, atIndex).trim();
658
- if (legacyKey && legacyKey !== trimmed) candidates.push(legacyKey);
721
+ if (legacyKey && legacyKey !== trimmed)
722
+ candidates.push(legacyKey);
659
723
  }
660
724
  return candidates;
661
725
  }
662
726
  function resolveCredentialKey(agent) {
663
- if (!agent || typeof agent !== "object") return void 0;
664
- if (isPublicOrSystemAgentRecord(agent)) return void 0;
727
+ if (!agent || typeof agent !== "object")
728
+ return;
729
+ if (isPublicOrSystemAgentRecord(agent))
730
+ return;
665
731
  let rawRef;
666
732
  for (const field of ["apiKeyRef", "credentialRef"]) {
667
733
  const value = agent[field];
@@ -673,13 +739,16 @@ function resolveCredentialKey(agent) {
673
739
  }
674
740
  }
675
741
  }
676
- if (!rawRef) return void 0;
677
- if (rawRef.includes("@")) return rawRef;
742
+ if (!rawRef)
743
+ return;
744
+ if (rawRef.includes("@"))
745
+ return rawRef;
678
746
  const owner = resolveAgentOwnerUserId(agent);
679
747
  return owner ? `${rawRef}@${owner}` : rawRef;
680
748
  }
681
749
  function resolveCredentialKeyWithFallback(agent) {
682
- if (isPublicOrSystemAgentRecord(agent)) return void 0;
750
+ if (isPublicOrSystemAgentRecord(agent))
751
+ return;
683
752
  const byRef = resolveCredentialKey(agent);
684
753
  if (byRef) {
685
754
  const ref = byRef.split("@")[0]?.trim().toLowerCase();
@@ -688,60 +757,64 @@ function resolveCredentialKeyWithFallback(agent) {
688
757
  try {
689
758
  const host = new URL(String(agent?.customProviderUrl ?? "")).hostname;
690
759
  cloudCode = /^(?:daily-|daily-sandbox-)?cloudcode-pa\.googleapis\.com$/.test(host);
691
- } catch {
692
- }
760
+ } catch {}
693
761
  if (ref === "antigravity" || ref === "gemini" || provider === "google-antigravity" || cloudCode) {
694
- const family = resolveQuotaWindowFamily(typeof agent?.model === "string" ? agent.model : void 0);
695
- if (family) return `${byRef}|quota:${family}`;
762
+ const family = resolveQuotaWindowFamily(typeof agent?.model === "string" ? agent.model : undefined);
763
+ if (family)
764
+ return `${byRef}|quota:${family}`;
696
765
  }
697
766
  return byRef;
698
767
  }
699
- if (!agent || typeof agent !== "object") return void 0;
768
+ if (!agent || typeof agent !== "object")
769
+ return;
700
770
  const endpoint = agent.customProviderUrl;
701
771
  if (typeof endpoint === "string") {
702
772
  const trimmed = endpoint.trim();
703
773
  if (trimmed) {
704
774
  try {
705
775
  const origin = new URL(trimmed).origin;
706
- if (origin && origin !== "null") return `custom-endpoint:${origin}`;
707
- } catch {
708
- }
776
+ if (origin && origin !== "null")
777
+ return `custom-endpoint:${origin}`;
778
+ } catch {}
709
779
  }
710
780
  }
711
781
  const key = agent.key;
712
- if (typeof key === "string" && key.trim()) return `custom-agent:${key.trim()}`;
713
- return void 0;
782
+ if (typeof key === "string" && key.trim())
783
+ return `custom-agent:${key.trim()}`;
784
+ return;
714
785
  }
715
786
  var AUTH_ERROR_TEXT_RE = /\b(?:unauthorized|unauthenticated|authentication_error|invalid_api_key|invalid_token|bad_api_key|access_denied)\b/i;
716
787
  var BALANCE_ERROR_TEXT_RE = /\b(?:insufficient_balance|wallet balance|coding_plan_exhausted|payment_required|arrears)\b|余额不足|额度已用尽且钱包|充值/i;
717
788
  var TEXT_5H_WINDOW_RE = /\b(?:5h|5-hour|5\s*hours?|5\s*hrs?)\b/i;
718
789
  var TEXT_WEEKLY_WINDOW_RE = /\b(?:weekly|monthly|7d|7-day|7\s*days?|30-day|month(?:ly)?|week(?:ly)?)\b/i;
719
790
  function inspectQuotaWindowExhaustion(window, now) {
720
- if (!window || typeof window !== "object") return void 0;
791
+ if (!window || typeof window !== "object")
792
+ return;
721
793
  const w = window;
722
794
  const scope = typeof w.scope === "string" ? w.scope.toLowerCase() : "";
723
- const windowSeconds = typeof w.limit_window_seconds === "number" ? w.limit_window_seconds : typeof w.window_seconds === "number" ? w.window_seconds : void 0;
724
- const usedPercent = typeof w.used_percent === "number" ? w.used_percent : typeof w.utilization === "number" ? w.utilization * 100 : void 0;
725
- const remaining = typeof w.remaining === "number" ? w.remaining : void 0;
795
+ const windowSeconds = typeof w.limit_window_seconds === "number" ? w.limit_window_seconds : typeof w.window_seconds === "number" ? w.window_seconds : undefined;
796
+ const usedPercent = typeof w.used_percent === "number" ? w.used_percent : typeof w.utilization === "number" ? w.utilization * 100 : undefined;
797
+ const remaining = typeof w.remaining === "number" ? w.remaining : undefined;
726
798
  const isZero = remaining === 0;
727
799
  const isHigh = typeof usedPercent === "number" && Number.isFinite(usedPercent) && usedPercent >= 95;
728
- if (!isZero && !isHigh) return void 0;
800
+ if (!isZero && !isHigh)
801
+ return;
729
802
  let scopeType = "limit";
730
- if (scope === "5h" || scope.includes("5h") || scope.includes("5-hour") || windowSeconds === 18e3) {
803
+ if (scope === "5h" || scope.includes("5h") || scope.includes("5-hour") || windowSeconds === 18000) {
731
804
  scopeType = "5h";
732
- } else if (scope === "7d" || scope === "weekly" || scope === "monthly" || scope.includes("7d") || scope.includes("week") || scope.includes("month") || windowSeconds === 604800 || windowSeconds === 2592e3) {
805
+ } else if (scope === "7d" || scope === "weekly" || scope === "monthly" || scope.includes("7d") || scope.includes("week") || scope.includes("month") || windowSeconds === 604800 || windowSeconds === 2592000) {
733
806
  scopeType = "weekly";
734
807
  }
735
808
  let resetAt;
736
809
  if (typeof w.resetAt === "number" && Number.isFinite(w.resetAt)) {
737
810
  resetAt = w.resetAt;
738
811
  } else if (typeof w.reset_at === "number" && Number.isFinite(w.reset_at)) {
739
- resetAt = w.reset_at >= 1e12 ? w.reset_at : w.reset_at * 1e3;
812
+ resetAt = w.reset_at >= 1000000000000 ? w.reset_at : w.reset_at * 1000;
740
813
  } else if (typeof w.resets_at === "number" && Number.isFinite(w.resets_at)) {
741
- resetAt = w.resets_at >= 1e12 ? w.resets_at : w.resets_at * 1e3;
814
+ resetAt = w.resets_at >= 1000000000000 ? w.resets_at : w.resets_at * 1000;
742
815
  }
743
816
  const resetAtIsFinite = typeof resetAt === "number" && Number.isFinite(resetAt);
744
- if (resetAtIsFinite && resetAt !== void 0 && resetAt <= now) {
817
+ if (resetAtIsFinite && resetAt !== undefined && resetAt <= now) {
745
818
  return {
746
819
  isExhausted: true,
747
820
  isActive: false,
@@ -752,7 +825,7 @@ function inspectQuotaWindowExhaustion(window, now) {
752
825
  utilizationHigh: isHigh
753
826
  };
754
827
  }
755
- if (resetAtIsFinite && resetAt !== void 0 && resetAt > now) {
828
+ if (resetAtIsFinite && resetAt !== undefined && resetAt > now) {
756
829
  return {
757
830
  isExhausted: true,
758
831
  isActive: true,
@@ -773,23 +846,28 @@ function inspectQuotaWindowExhaustion(window, now) {
773
846
  };
774
847
  }
775
848
  function resolveWindowFromQuotaSnapshot(quota, now = Date.now()) {
776
- if (!isAdmissibleQuotaSnapshot(quota, now)) return void 0;
849
+ if (!isAdmissibleQuotaSnapshot(quota, now))
850
+ return;
777
851
  const q = quota;
778
852
  const rateLimitRoot = q.rate_limit && typeof q.rate_limit === "object" ? q.rate_limit : q;
779
853
  for (const winKey of ["primary_window", "secondary_window"]) {
780
854
  const inspected = inspectQuotaWindowExhaustion(rateLimitRoot[winKey], now);
781
- if (inspected?.isActive && inspected.scopeType !== "limit") return inspected.scopeType;
855
+ if (inspected?.isActive && inspected.scopeType !== "limit")
856
+ return inspected.scopeType;
782
857
  }
783
858
  if (Array.isArray(q.windows)) {
784
859
  let hasLimit = false;
785
860
  for (const win of q.windows) {
786
861
  const inspected = inspectQuotaWindowExhaustion(win, now);
787
862
  if (inspected?.isActive) {
788
- if (inspected.scopeType === "5h" || inspected.scopeType === "weekly") return inspected.scopeType;
789
- if (inspected.scopeType === "limit") hasLimit = true;
863
+ if (inspected.scopeType === "5h" || inspected.scopeType === "weekly")
864
+ return inspected.scopeType;
865
+ if (inspected.scopeType === "limit")
866
+ hasLimit = true;
790
867
  }
791
868
  }
792
- if (hasLimit) return "limit";
869
+ if (hasLimit)
870
+ return "limit";
793
871
  }
794
872
  for (const winKey of ["primary_window", "secondary_window"]) {
795
873
  const inspected = inspectQuotaWindowExhaustion(rateLimitRoot[winKey], now);
@@ -797,7 +875,7 @@ function resolveWindowFromQuotaSnapshot(quota, now = Date.now()) {
797
875
  return "limit";
798
876
  }
799
877
  }
800
- return void 0;
878
+ return;
801
879
  }
802
880
  function classifyFailureSubclass(input, now = Date.now()) {
803
881
  let status;
@@ -809,17 +887,20 @@ function classifyFailureSubclass(input, now = Date.now()) {
809
887
  rawMessage = input;
810
888
  } else if (input && typeof input === "object") {
811
889
  const rec = input;
812
- status = typeof rec.status === "number" ? rec.status : typeof rec.statusCode === "number" ? rec.statusCode : void 0;
890
+ status = typeof rec.status === "number" ? rec.status : typeof rec.statusCode === "number" ? rec.statusCode : undefined;
813
891
  rawMessage = typeof rec.message === "string" ? rec.message : "";
814
- body = rec.body ?? ("status" in rec || "message" in rec ? void 0 : input);
892
+ body = rec.body ?? ("status" in rec || "message" in rec ? undefined : input);
815
893
  headers = rec.headers;
816
894
  quota = rec.quota;
817
895
  }
818
896
  const bodyText = typeof body === "string" ? body : JSON.stringify(body ?? "");
819
897
  const fullText = `${rawMessage} ${bodyText}`.trim();
820
- if (status === 401) return "auth";
821
- if (status === 402) return "balance";
822
- if (status === 403 && !isQuotaLimited403Body(fullText)) return "auth";
898
+ if (status === 401)
899
+ return "auth";
900
+ if (status === 402)
901
+ return "balance";
902
+ if (status === 403 && !isQuotaLimited403Body(fullText))
903
+ return "auth";
823
904
  if (AUTH_ERROR_TEXT_RE.test(fullText) && !isQuotaExhaustedText(fullText) && !BALANCE_ERROR_TEXT_RE.test(fullText)) {
824
905
  return "auth";
825
906
  }
@@ -831,7 +912,7 @@ function classifyFailureSubclass(input, now = Date.now()) {
831
912
  return "capacity";
832
913
  }
833
914
  const quotaWindowFromSnapshot = resolveWindowFromQuotaSnapshot(quota, now) ?? resolveWindowFromQuotaSnapshot(body, now);
834
- const hasConfirmedQuotaExhaustion = quotaWindowFromSnapshot !== void 0 || status === 403 && isQuotaLimited403Body(fullText) && !NEGATED_QUOTA_TEXT_RE.test(fullText) || isQuotaExhaustedText(fullText);
915
+ const hasConfirmedQuotaExhaustion = quotaWindowFromSnapshot !== undefined || status === 403 && isQuotaLimited403Body(fullText) && !NEGATED_QUOTA_TEXT_RE.test(fullText) || isQuotaExhaustedText(fullText);
835
916
  if (hasConfirmedQuotaExhaustion) {
836
917
  if (quotaWindowFromSnapshot === "5h" || !NEGATED_QUOTA_TEXT_RE.test(fullText) && TEXT_5H_WINDOW_RE.test(fullText)) {
837
918
  return "quota_5h";
@@ -841,28 +922,11 @@ function classifyFailureSubclass(input, now = Date.now()) {
841
922
  }
842
923
  return "quota_limit";
843
924
  }
844
- const isRateLimitLike = status === 429 || /\b(?:rate.?limit|too many requests|throttl(?:ed|ing)|resource_exhausted)\b/i.test(
845
- fullText
846
- );
925
+ const isRateLimitLike = status === 429 || /\b(?:rate.?limit|too many requests|throttl(?:ed|ing)|resource_exhausted)\b/i.test(fullText);
847
926
  if (isRateLimitLike) {
848
927
  return "rate_limit";
849
928
  }
850
929
  return "unknown";
851
930
  }
852
931
 
853
- export {
854
- extractQuotaSnapshot,
855
- formatQuotaSummary,
856
- DEFAULT_PROVIDER_RETRY_MS,
857
- isSubscriptionPeriodWindow,
858
- shouldClearCooldownFromQuota,
859
- isAgentUnavailableNow,
860
- resolveAgentAvailability,
861
- isQuotaExhaustedText,
862
- isCapacitySaturatedRateLimit,
863
- resolveAvailabilityAction,
864
- mergeAvailabilityDeadline,
865
- resolveCredentialCandidateKeys,
866
- resolveCredentialKeyWithFallback,
867
- classifyFailureSubclass
868
- };
932
+ export { extractQuotaSnapshot, formatQuotaSummary, DEFAULT_PROVIDER_RETRY_MS, isSubscriptionPeriodWindow, shouldClearCooldownFromQuota, isAgentUnavailableNow, resolveAgentAvailability, isQuotaExhaustedText, isCapacitySaturatedRateLimit, resolveAvailabilityAction, mergeAvailabilityDeadline, resolveCredentialCandidateKeys, resolveCredentialKeyWithFallback, classifyFailureSubclass };