@compose-market/theme 0.0.2 → 0.0.3

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 (547) hide show
  1. package/dist/components/RFAComponent.d.ts +10 -0
  2. package/dist/components/RFAComponent.d.ts.map +1 -0
  3. package/dist/components/RFAComponent.js +288 -0
  4. package/dist/components/RFAComponent.js.map +1 -0
  5. package/dist/components/RFADetails.d.ts +9 -0
  6. package/dist/components/RFADetails.d.ts.map +1 -0
  7. package/dist/components/RFADetails.js +407 -0
  8. package/dist/components/RFADetails.js.map +1 -0
  9. package/dist/components/agent-card.d.ts +8 -0
  10. package/dist/components/agent-card.d.ts.map +1 -0
  11. package/dist/components/agent-card.js +216 -0
  12. package/dist/components/agent-card.js.map +1 -0
  13. package/dist/components/backpack.d.ts +21 -0
  14. package/dist/components/backpack.d.ts.map +1 -0
  15. package/dist/components/backpack.js +905 -0
  16. package/dist/components/backpack.js.map +1 -0
  17. package/dist/components/blur.d.ts +9 -0
  18. package/dist/components/blur.d.ts.map +1 -0
  19. package/dist/components/blur.js +60 -0
  20. package/dist/components/blur.js.map +1 -0
  21. package/dist/components/brand/Logo.d.ts +3 -3
  22. package/dist/components/brand/Logo.d.ts.map +1 -1
  23. package/dist/components/brand/Logo.js +37 -4
  24. package/dist/components/brand/Logo.js.map +1 -1
  25. package/dist/components/chat.d.ts +68 -0
  26. package/dist/components/chat.d.ts.map +1 -0
  27. package/dist/components/chat.js +618 -0
  28. package/dist/components/chat.js.map +1 -0
  29. package/dist/components/compose/index.d.ts +10 -0
  30. package/dist/components/compose/index.d.ts.map +1 -0
  31. package/dist/components/compose/index.js +13 -0
  32. package/dist/components/compose/index.js.map +1 -0
  33. package/dist/components/compose/nodes/agent-node.d.ts +11 -0
  34. package/dist/components/compose/nodes/agent-node.d.ts.map +1 -0
  35. package/dist/components/compose/nodes/agent-node.js +101 -0
  36. package/dist/components/compose/nodes/agent-node.js.map +1 -0
  37. package/dist/components/compose/nodes/hook-node.d.ts +11 -0
  38. package/dist/components/compose/nodes/hook-node.d.ts.map +1 -0
  39. package/dist/components/compose/nodes/hook-node.js +100 -0
  40. package/dist/components/compose/nodes/hook-node.js.map +1 -0
  41. package/dist/components/compose/nodes/index.d.ts +60 -0
  42. package/dist/components/compose/nodes/index.d.ts.map +1 -0
  43. package/dist/components/compose/nodes/index.js +22 -0
  44. package/dist/components/compose/nodes/index.js.map +1 -0
  45. package/dist/components/compose/nodes/step-node.d.ts +11 -0
  46. package/dist/components/compose/nodes/step-node.d.ts.map +1 -0
  47. package/dist/components/compose/nodes/step-node.js +88 -0
  48. package/dist/components/compose/nodes/step-node.js.map +1 -0
  49. package/dist/components/compose/nodes/trigger-node.d.ts +11 -0
  50. package/dist/components/compose/nodes/trigger-node.d.ts.map +1 -0
  51. package/dist/components/compose/nodes/trigger-node.js +92 -0
  52. package/dist/components/compose/nodes/trigger-node.js.map +1 -0
  53. package/dist/components/compose/overlay.d.ts +26 -0
  54. package/dist/components/compose/overlay.d.ts.map +1 -0
  55. package/dist/components/compose/overlay.js +48 -0
  56. package/dist/components/compose/overlay.js.map +1 -0
  57. package/dist/components/compose/pickers/agents-picker.d.ts +18 -0
  58. package/dist/components/compose/pickers/agents-picker.d.ts.map +1 -0
  59. package/dist/components/compose/pickers/agents-picker.js +180 -0
  60. package/dist/components/compose/pickers/agents-picker.js.map +1 -0
  61. package/dist/components/compose/pickers/connector-detail.d.ts +16 -0
  62. package/dist/components/compose/pickers/connector-detail.d.ts.map +1 -0
  63. package/dist/components/compose/pickers/connector-detail.js +236 -0
  64. package/dist/components/compose/pickers/connector-detail.js.map +1 -0
  65. package/dist/components/compose/pickers/connector-picker.d.ts +13 -0
  66. package/dist/components/compose/pickers/connector-picker.d.ts.map +1 -0
  67. package/dist/components/compose/pickers/connector-picker.js +101 -0
  68. package/dist/components/compose/pickers/connector-picker.js.map +1 -0
  69. package/dist/components/compose/pickers/index.d.ts +10 -0
  70. package/dist/components/compose/pickers/index.d.ts.map +1 -0
  71. package/dist/components/compose/pickers/index.js +10 -0
  72. package/dist/components/compose/pickers/index.js.map +1 -0
  73. package/dist/components/compose/pickers/trigger-picker.d.ts +13 -0
  74. package/dist/components/compose/pickers/trigger-picker.d.ts.map +1 -0
  75. package/dist/components/compose/pickers/trigger-picker.js +110 -0
  76. package/dist/components/compose/pickers/trigger-picker.js.map +1 -0
  77. package/dist/components/compose/toolbox.d.ts +24 -0
  78. package/dist/components/compose/toolbox.d.ts.map +1 -0
  79. package/dist/components/compose/toolbox.js +183 -0
  80. package/dist/components/compose/toolbox.js.map +1 -0
  81. package/dist/components/connector.d.ts +24 -0
  82. package/dist/components/connector.d.ts.map +1 -0
  83. package/dist/components/connector.js +263 -0
  84. package/dist/components/connector.js.map +1 -0
  85. package/dist/components/dispenser.d.ts +15 -0
  86. package/dist/components/dispenser.d.ts.map +1 -0
  87. package/dist/components/dispenser.js +323 -0
  88. package/dist/components/dispenser.js.map +1 -0
  89. package/dist/components/layout/AppLayout.d.ts +60 -0
  90. package/dist/components/layout/AppLayout.d.ts.map +1 -0
  91. package/dist/components/layout/AppLayout.js +265 -0
  92. package/dist/components/layout/AppLayout.js.map +1 -0
  93. package/dist/components/layout/Layout.d.ts +6 -0
  94. package/dist/components/layout/Layout.d.ts.map +1 -0
  95. package/dist/components/layout/Layout.js +186 -0
  96. package/dist/components/layout/Layout.js.map +1 -0
  97. package/dist/components/layout/Sidebar.d.ts +3 -0
  98. package/dist/components/layout/Sidebar.d.ts.map +1 -0
  99. package/dist/components/layout/Sidebar.js +160 -0
  100. package/dist/components/layout/Sidebar.js.map +1 -0
  101. package/dist/components/layout/TopBar.d.ts +6 -0
  102. package/dist/components/layout/TopBar.d.ts.map +1 -0
  103. package/dist/components/layout/TopBar.js +36 -0
  104. package/dist/components/layout/TopBar.js.map +1 -0
  105. package/dist/components/layout/index.d.ts +2 -0
  106. package/dist/components/layout/index.d.ts.map +1 -0
  107. package/dist/components/layout/index.js +2 -0
  108. package/dist/components/layout/index.js.map +1 -0
  109. package/dist/components/lyria-player.d.ts +23 -0
  110. package/dist/components/lyria-player.d.ts.map +1 -0
  111. package/dist/components/lyria-player.js +241 -0
  112. package/dist/components/lyria-player.js.map +1 -0
  113. package/dist/components/manowar-card.d.ts +8 -0
  114. package/dist/components/manowar-card.d.ts.map +1 -0
  115. package/dist/components/manowar-card.js +349 -0
  116. package/dist/components/manowar-card.js.map +1 -0
  117. package/dist/components/mirror-pane.d.ts +55 -0
  118. package/dist/components/mirror-pane.d.ts.map +1 -0
  119. package/dist/components/mirror-pane.js +330 -0
  120. package/dist/components/mirror-pane.js.map +1 -0
  121. package/dist/components/model-selector.d.ts +12 -0
  122. package/dist/components/model-selector.d.ts.map +1 -0
  123. package/dist/components/model-selector.js +148 -0
  124. package/dist/components/model-selector.js.map +1 -0
  125. package/dist/components/output.d.ts +26 -0
  126. package/dist/components/output.d.ts.map +1 -0
  127. package/dist/components/output.js +259 -0
  128. package/dist/components/output.js.map +1 -0
  129. package/dist/components/partners.d.ts +13 -0
  130. package/dist/components/partners.d.ts.map +1 -0
  131. package/dist/components/partners.js +210 -0
  132. package/dist/components/partners.js.map +1 -0
  133. package/dist/components/plugin-tester.d.ts +13 -0
  134. package/dist/components/plugin-tester.d.ts.map +1 -0
  135. package/dist/components/plugin-tester.js +907 -0
  136. package/dist/components/plugin-tester.js.map +1 -0
  137. package/dist/components/session/SessionComponents.d.ts +2 -0
  138. package/dist/components/session/SessionComponents.d.ts.map +1 -0
  139. package/dist/components/session/SessionComponents.js +2 -0
  140. package/dist/components/session/SessionComponents.js.map +1 -0
  141. package/dist/components/session/index.d.ts +2 -0
  142. package/dist/components/session/index.d.ts.map +1 -0
  143. package/dist/components/session/index.js +2 -0
  144. package/dist/components/session/index.js.map +1 -0
  145. package/dist/components/session.d.ts +3 -3
  146. package/dist/components/session.d.ts.map +1 -1
  147. package/dist/components/session.js +315 -15
  148. package/dist/components/session.js.map +1 -1
  149. package/dist/components/share-dialog.d.ts +9 -0
  150. package/dist/components/share-dialog.d.ts.map +1 -0
  151. package/dist/components/share-dialog.js +49 -0
  152. package/dist/components/share-dialog.js.map +1 -0
  153. package/dist/components/ui/accordion.d.ts +6 -0
  154. package/dist/components/ui/accordion.d.ts.map +1 -0
  155. package/dist/components/ui/accordion.js +20 -0
  156. package/dist/components/ui/accordion.js.map +1 -0
  157. package/dist/components/ui/alert-dialog.d.ts +20 -0
  158. package/dist/components/ui/alert-dialog.d.ts.map +1 -0
  159. package/dist/components/ui/alert-dialog.js +29 -0
  160. package/dist/components/ui/alert-dialog.js.map +1 -0
  161. package/dist/components/ui/alert.d.ts +5 -0
  162. package/dist/components/ui/alert.d.ts.map +1 -0
  163. package/dist/components/ui/alert.js +22 -0
  164. package/dist/components/ui/alert.js.map +1 -0
  165. package/dist/components/ui/aspect-ratio.d.ts +3 -0
  166. package/dist/components/ui/aspect-ratio.d.ts.map +1 -0
  167. package/dist/components/ui/aspect-ratio.js +4 -0
  168. package/dist/components/ui/aspect-ratio.js.map +1 -0
  169. package/dist/components/ui/avatar.d.ts +5 -0
  170. package/dist/components/ui/avatar.d.ts.map +1 -0
  171. package/dist/components/ui/avatar.js +12 -0
  172. package/dist/components/ui/avatar.js.map +1 -0
  173. package/dist/components/ui/badge.d.ts +2 -4
  174. package/dist/components/ui/badge.d.ts.map +1 -1
  175. package/dist/components/ui/badge.js +2 -2
  176. package/dist/components/ui/badge.js.map +1 -1
  177. package/dist/components/ui/breadcrumb.d.ts +16 -0
  178. package/dist/components/ui/breadcrumb.d.ts.map +1 -0
  179. package/dist/components/ui/breadcrumb.js +28 -0
  180. package/dist/components/ui/breadcrumb.js.map +1 -0
  181. package/dist/components/ui/button-group.d.ts +10 -0
  182. package/dist/components/ui/button-group.d.ts.map +1 -0
  183. package/dist/components/ui/button-group.js +27 -0
  184. package/dist/components/ui/button-group.js.map +1 -0
  185. package/dist/components/ui/button.d.ts +2 -5
  186. package/dist/components/ui/button.d.ts.map +1 -1
  187. package/dist/components/ui/button.js +1 -2
  188. package/dist/components/ui/button.js.map +1 -1
  189. package/dist/components/ui/calendar.d.ts +9 -0
  190. package/dist/components/ui/calendar.d.ts.map +1 -0
  191. package/dist/components/ui/calendar.js +78 -0
  192. package/dist/components/ui/calendar.js.map +1 -0
  193. package/dist/components/ui/card.d.ts +6 -11
  194. package/dist/components/ui/card.d.ts.map +1 -1
  195. package/dist/components/ui/card.js +6 -7
  196. package/dist/components/ui/card.js.map +1 -1
  197. package/dist/components/ui/carousel.d.ts +9 -0
  198. package/dist/components/ui/carousel.d.ts.map +1 -0
  199. package/dist/components/ui/carousel.js +110 -0
  200. package/dist/components/ui/carousel.js.map +1 -0
  201. package/dist/components/ui/chart.d.ts +28 -0
  202. package/dist/components/ui/chart.d.ts.map +1 -0
  203. package/dist/components/ui/chart.js +168 -0
  204. package/dist/components/ui/chart.js.map +1 -0
  205. package/dist/components/ui/checkbox.d.ts +3 -0
  206. package/dist/components/ui/checkbox.d.ts.map +1 -0
  207. package/dist/components/ui/checkbox.js +12 -0
  208. package/dist/components/ui/checkbox.js.map +1 -0
  209. package/dist/components/ui/collapsible.d.ts +5 -0
  210. package/dist/components/ui/collapsible.d.ts.map +1 -0
  211. package/dist/components/ui/collapsible.js +7 -0
  212. package/dist/components/ui/collapsible.js.map +1 -0
  213. package/dist/components/ui/command.d.ts +16 -0
  214. package/dist/components/ui/command.d.ts.map +1 -0
  215. package/dist/components/ui/command.js +38 -0
  216. package/dist/components/ui/command.js.map +1 -0
  217. package/dist/components/ui/context-menu.d.ts +21 -0
  218. package/dist/components/ui/context-menu.d.ts.map +1 -0
  219. package/dist/components/ui/context-menu.js +52 -0
  220. package/dist/components/ui/context-menu.js.map +1 -0
  221. package/dist/components/ui/dialog.d.ts +10 -11
  222. package/dist/components/ui/dialog.d.ts.map +1 -1
  223. package/dist/components/ui/dialog.js +15 -7
  224. package/dist/components/ui/dialog.js.map +1 -1
  225. package/dist/components/ui/drawer.d.ts +23 -0
  226. package/dist/components/ui/drawer.d.ts.map +1 -0
  227. package/dist/components/ui/drawer.js +28 -0
  228. package/dist/components/ui/drawer.js.map +1 -0
  229. package/dist/components/ui/dropdown-menu.d.ts +15 -22
  230. package/dist/components/ui/dropdown-menu.d.ts.map +1 -1
  231. package/dist/components/ui/dropdown-menu.js +28 -10
  232. package/dist/components/ui/dropdown-menu.js.map +1 -1
  233. package/dist/components/ui/empty.d.ts +10 -0
  234. package/dist/components/ui/empty.d.ts.map +1 -0
  235. package/dist/components/ui/empty.js +33 -0
  236. package/dist/components/ui/empty.js.map +1 -0
  237. package/dist/components/ui/field.d.ts +23 -0
  238. package/dist/components/ui/field.d.ts.map +1 -0
  239. package/dist/components/ui/field.js +82 -0
  240. package/dist/components/ui/field.js.map +1 -0
  241. package/dist/components/ui/form.d.ts +11 -0
  242. package/dist/components/ui/form.d.ts.map +1 -0
  243. package/dist/components/ui/form.js +71 -0
  244. package/dist/components/ui/form.js.map +1 -0
  245. package/dist/components/ui/hover-card.d.ts +5 -0
  246. package/dist/components/ui/hover-card.d.ts.map +1 -0
  247. package/dist/components/ui/hover-card.js +9 -0
  248. package/dist/components/ui/hover-card.js.map +1 -0
  249. package/dist/components/ui/input-group.d.ts +13 -0
  250. package/dist/components/ui/input-group.d.ts.map +1 -0
  251. package/dist/components/ui/input-group.js +63 -0
  252. package/dist/components/ui/input-group.js.map +1 -0
  253. package/dist/components/ui/input-otp.d.ts +6 -0
  254. package/dist/components/ui/input-otp.d.ts.map +1 -0
  255. package/dist/components/ui/input-otp.js +25 -0
  256. package/dist/components/ui/input-otp.js.map +1 -0
  257. package/dist/components/ui/input.d.ts +3 -0
  258. package/dist/components/ui/input.d.ts.map +1 -0
  259. package/dist/components/ui/input.js +8 -0
  260. package/dist/components/ui/input.js.map +1 -0
  261. package/dist/components/ui/item.d.ts +19 -0
  262. package/dist/components/ui/item.d.ts.map +1 -0
  263. package/dist/components/ui/item.js +67 -0
  264. package/dist/components/ui/item.js.map +1 -0
  265. package/dist/components/ui/kbd.d.ts +4 -0
  266. package/dist/components/ui/kbd.d.ts.map +1 -0
  267. package/dist/components/ui/kbd.js +9 -0
  268. package/dist/components/ui/kbd.js.map +1 -0
  269. package/dist/components/ui/label.d.ts +3 -0
  270. package/dist/components/ui/label.d.ts.map +1 -0
  271. package/dist/components/ui/label.js +10 -0
  272. package/dist/components/ui/label.js.map +1 -0
  273. package/dist/components/ui/menubar.d.ts +23 -0
  274. package/dist/components/ui/menubar.d.ts.map +1 -0
  275. package/dist/components/ui/menubar.js +64 -0
  276. package/dist/components/ui/menubar.js.map +1 -0
  277. package/dist/components/ui/navigation-menu.d.ts +11 -0
  278. package/dist/components/ui/navigation-menu.d.ts.map +1 -0
  279. package/dist/components/ui/navigation-menu.js +34 -0
  280. package/dist/components/ui/navigation-menu.js.map +1 -0
  281. package/dist/components/ui/network-selector.d.ts +22 -0
  282. package/dist/components/ui/network-selector.d.ts.map +1 -0
  283. package/dist/components/ui/network-selector.js +99 -0
  284. package/dist/components/ui/network-selector.js.map +1 -0
  285. package/dist/components/ui/pagination.d.ts +29 -0
  286. package/dist/components/ui/pagination.d.ts.map +1 -0
  287. package/dist/components/ui/pagination.js +32 -0
  288. package/dist/components/ui/pagination.js.map +1 -0
  289. package/dist/components/ui/popover.d.ts +6 -0
  290. package/dist/components/ui/popover.d.ts.map +1 -0
  291. package/dist/components/ui/popover.js +12 -0
  292. package/dist/components/ui/popover.js.map +1 -0
  293. package/dist/components/ui/progress.d.ts +1 -3
  294. package/dist/components/ui/progress.d.ts.map +1 -1
  295. package/dist/components/ui/progress.js +3 -2
  296. package/dist/components/ui/progress.js.map +1 -1
  297. package/dist/components/ui/radio-group.d.ts +4 -0
  298. package/dist/components/ui/radio-group.d.ts.map +1 -0
  299. package/dist/components/ui/radio-group.js +18 -0
  300. package/dist/components/ui/radio-group.js.map +1 -0
  301. package/dist/components/ui/resizable.d.ts +8 -0
  302. package/dist/components/ui/resizable.d.ts.map +1 -0
  303. package/dist/components/ui/resizable.js +13 -0
  304. package/dist/components/ui/resizable.js.map +1 -0
  305. package/dist/components/ui/scroll-area.d.ts +4 -0
  306. package/dist/components/ui/scroll-area.d.ts.map +1 -0
  307. package/dist/components/ui/scroll-area.js +19 -0
  308. package/dist/components/ui/scroll-area.js.map +1 -0
  309. package/dist/components/ui/select.d.ts +12 -0
  310. package/dist/components/ui/select.d.ts.map +1 -0
  311. package/dist/components/ui/select.js +51 -0
  312. package/dist/components/ui/select.js.map +1 -0
  313. package/dist/components/ui/separator.d.ts +3 -0
  314. package/dist/components/ui/separator.d.ts.map +1 -0
  315. package/dist/components/ui/separator.js +7 -0
  316. package/dist/components/ui/separator.js.map +1 -0
  317. package/dist/components/ui/sheet.d.ts +19 -0
  318. package/dist/components/ui/sheet.d.ts.map +1 -0
  319. package/dist/components/ui/sheet.js +46 -0
  320. package/dist/components/ui/sheet.js.map +1 -0
  321. package/dist/components/ui/sidebar.d.ts +58 -0
  322. package/dist/components/ui/sidebar.d.ts.map +1 -0
  323. package/dist/components/ui/sidebar.js +246 -0
  324. package/dist/components/ui/sidebar.js.map +1 -0
  325. package/dist/components/ui/skeleton.d.ts +3 -0
  326. package/dist/components/ui/skeleton.d.ts.map +1 -0
  327. package/dist/components/ui/skeleton.js +6 -0
  328. package/dist/components/ui/skeleton.js.map +1 -0
  329. package/dist/components/ui/slider.d.ts +3 -0
  330. package/dist/components/ui/slider.d.ts.map +1 -0
  331. package/dist/components/ui/slider.js +12 -0
  332. package/dist/components/ui/slider.js.map +1 -0
  333. package/dist/components/ui/sonner.d.ts +5 -0
  334. package/dist/components/ui/sonner.d.ts.map +1 -0
  335. package/dist/components/ui/sonner.js +16 -0
  336. package/dist/components/ui/sonner.js.map +1 -0
  337. package/dist/components/ui/spinner.d.ts +3 -0
  338. package/dist/components/ui/spinner.d.ts.map +1 -0
  339. package/dist/components/ui/spinner.js +7 -0
  340. package/dist/components/ui/spinner.js.map +1 -0
  341. package/dist/components/ui/switch.d.ts +3 -0
  342. package/dist/components/ui/switch.d.ts.map +1 -0
  343. package/dist/components/ui/switch.js +9 -0
  344. package/dist/components/ui/switch.js.map +1 -0
  345. package/dist/components/ui/table.d.ts +10 -0
  346. package/dist/components/ui/table.d.ts.map +1 -0
  347. package/dist/components/ui/table.js +22 -0
  348. package/dist/components/ui/table.js.map +1 -0
  349. package/dist/components/ui/tabs.d.ts +6 -0
  350. package/dist/components/ui/tabs.d.ts.map +1 -0
  351. package/dist/components/ui/tabs.js +13 -0
  352. package/dist/components/ui/tabs.js.map +1 -0
  353. package/dist/components/ui/textarea.d.ts +3 -0
  354. package/dist/components/ui/textarea.d.ts.map +1 -0
  355. package/dist/components/ui/textarea.js +8 -0
  356. package/dist/components/ui/textarea.js.map +1 -0
  357. package/dist/components/ui/toast.d.ts +12 -0
  358. package/dist/components/ui/toast.d.ts.map +1 -0
  359. package/dist/components/ui/toast.js +35 -0
  360. package/dist/components/ui/toast.js.map +1 -0
  361. package/dist/components/ui/toaster.d.ts +2 -0
  362. package/dist/components/ui/toaster.d.ts.map +1 -0
  363. package/dist/components/ui/toaster.js +19 -0
  364. package/dist/components/ui/toaster.js.map +1 -0
  365. package/dist/components/ui/toggle-group.d.ts +4 -0
  366. package/dist/components/ui/toggle-group.d.ts.map +1 -0
  367. package/dist/components/ui/toggle-group.js +27 -0
  368. package/dist/components/ui/toggle-group.js.map +1 -0
  369. package/dist/components/ui/toggle.d.ts +4 -0
  370. package/dist/components/ui/toggle.d.ts.map +1 -0
  371. package/dist/components/ui/toggle.js +25 -0
  372. package/dist/components/ui/toggle.js.map +1 -0
  373. package/dist/components/ui/tooltip.d.ts +6 -0
  374. package/dist/components/ui/tooltip.d.ts.map +1 -0
  375. package/dist/components/ui/tooltip.js +13 -0
  376. package/dist/components/ui/tooltip.js.map +1 -0
  377. package/dist/components/visual/ManowarField.d.ts +9 -0
  378. package/dist/components/visual/ManowarField.d.ts.map +1 -0
  379. package/dist/components/visual/ManowarField.js +111 -0
  380. package/dist/components/visual/ManowarField.js.map +1 -0
  381. package/dist/components/warp-form.d.ts +22 -0
  382. package/dist/components/warp-form.d.ts.map +1 -0
  383. package/dist/components/warp-form.js +743 -0
  384. package/dist/components/warp-form.js.map +1 -0
  385. package/dist/css/dark.css +38 -0
  386. package/dist/css/index.css +9 -0
  387. package/dist/css/index.d.ts +16 -0
  388. package/dist/css/index.d.ts.map +1 -0
  389. package/dist/css/index.js +96 -0
  390. package/dist/css/index.js.map +1 -0
  391. package/dist/css/light.css +70 -0
  392. package/dist/css/tokens.css +24 -0
  393. package/dist/hooks/use-agents.d.ts +17 -0
  394. package/dist/hooks/use-agents.d.ts.map +1 -0
  395. package/dist/hooks/use-agents.js +64 -0
  396. package/dist/hooks/use-agents.js.map +1 -0
  397. package/dist/hooks/use-api.d.ts +28 -0
  398. package/dist/hooks/use-api.d.ts.map +1 -0
  399. package/dist/hooks/use-api.js +114 -0
  400. package/dist/hooks/use-api.js.map +1 -0
  401. package/dist/hooks/use-chat.d.ts +64 -0
  402. package/dist/hooks/use-chat.d.ts.map +1 -0
  403. package/dist/hooks/use-chat.js +350 -0
  404. package/dist/hooks/use-chat.js.map +1 -0
  405. package/dist/hooks/use-coordinator.d.ts +41 -0
  406. package/dist/hooks/use-coordinator.d.ts.map +1 -0
  407. package/dist/hooks/use-coordinator.js +110 -0
  408. package/dist/hooks/use-coordinator.js.map +1 -0
  409. package/dist/hooks/use-dispenser.d.ts +68 -0
  410. package/dist/hooks/use-dispenser.d.ts.map +1 -0
  411. package/dist/hooks/use-dispenser.js +113 -0
  412. package/dist/hooks/use-dispenser.js.map +1 -0
  413. package/dist/hooks/use-lyria.d.ts +58 -0
  414. package/dist/hooks/use-lyria.d.ts.map +1 -0
  415. package/dist/hooks/use-lyria.js +254 -0
  416. package/dist/hooks/use-lyria.js.map +1 -0
  417. package/dist/hooks/use-mobile.d.ts +2 -0
  418. package/dist/hooks/use-mobile.d.ts.map +1 -0
  419. package/dist/hooks/use-mobile.js +16 -0
  420. package/dist/hooks/use-mobile.js.map +1 -0
  421. package/dist/hooks/use-model.d.ts +34 -0
  422. package/dist/hooks/use-model.d.ts.map +1 -0
  423. package/dist/hooks/use-model.js +105 -0
  424. package/dist/hooks/use-model.js.map +1 -0
  425. package/dist/hooks/use-motion-governor.d.ts +10 -0
  426. package/dist/hooks/use-motion-governor.d.ts.map +1 -0
  427. package/dist/hooks/use-motion-governor.js +63 -0
  428. package/dist/hooks/use-motion-governor.js.map +1 -0
  429. package/dist/hooks/use-multichain.d.ts +34 -0
  430. package/dist/hooks/use-multichain.d.ts.map +1 -0
  431. package/dist/hooks/use-multichain.js +120 -0
  432. package/dist/hooks/use-multichain.js.map +1 -0
  433. package/dist/hooks/use-onchain.d.ts +145 -0
  434. package/dist/hooks/use-onchain.d.ts.map +1 -0
  435. package/dist/hooks/use-onchain.js +652 -0
  436. package/dist/hooks/use-onchain.js.map +1 -0
  437. package/dist/hooks/use-registry.d.ts +140 -0
  438. package/dist/hooks/use-registry.d.ts.map +1 -0
  439. package/dist/hooks/use-registry.js +264 -0
  440. package/dist/hooks/use-registry.js.map +1 -0
  441. package/dist/hooks/use-services.d.ts +66 -0
  442. package/dist/hooks/use-services.d.ts.map +1 -0
  443. package/dist/hooks/use-services.js +216 -0
  444. package/dist/hooks/use-services.js.map +1 -0
  445. package/dist/hooks/use-session.d.ts +36 -0
  446. package/dist/hooks/use-session.d.ts.map +1 -0
  447. package/dist/hooks/use-session.js +449 -0
  448. package/dist/hooks/use-session.js.map +1 -0
  449. package/dist/hooks/use-sse.d.ts +8 -0
  450. package/dist/hooks/use-sse.d.ts.map +1 -0
  451. package/dist/hooks/use-sse.js +86 -0
  452. package/dist/hooks/use-sse.js.map +1 -0
  453. package/dist/hooks/use-tabs.d.ts +2 -0
  454. package/dist/hooks/use-tabs.d.ts.map +1 -0
  455. package/dist/hooks/use-tabs.js +43 -0
  456. package/dist/hooks/use-tabs.js.map +1 -0
  457. package/dist/hooks/use-toast.d.ts +41 -0
  458. package/dist/hooks/use-toast.d.ts.map +1 -0
  459. package/dist/hooks/use-toast.js +127 -0
  460. package/dist/hooks/use-toast.js.map +1 -0
  461. package/dist/hooks/use-triggers.d.ts +51 -0
  462. package/dist/hooks/use-triggers.d.ts.map +1 -0
  463. package/dist/hooks/use-triggers.js +212 -0
  464. package/dist/hooks/use-triggers.js.map +1 -0
  465. package/dist/hooks/use-warp.d.ts +53 -0
  466. package/dist/hooks/use-warp.d.ts.map +1 -0
  467. package/dist/hooks/use-warp.js +231 -0
  468. package/dist/hooks/use-warp.js.map +1 -0
  469. package/dist/hooks/use-workflow.d.ts +40 -0
  470. package/dist/hooks/use-workflow.d.ts.map +1 -0
  471. package/dist/hooks/use-workflow.js +358 -0
  472. package/dist/hooks/use-workflow.js.map +1 -0
  473. package/dist/index.d.ts +6 -5
  474. package/dist/index.d.ts.map +1 -1
  475. package/dist/index.js +6 -5
  476. package/dist/index.js.map +1 -1
  477. package/dist/lib/agents.d.ts +186 -0
  478. package/dist/lib/agents.d.ts.map +1 -0
  479. package/dist/lib/agents.js +633 -0
  480. package/dist/lib/agents.js.map +1 -0
  481. package/dist/lib/api.d.ts +224 -0
  482. package/dist/lib/api.d.ts.map +1 -0
  483. package/dist/lib/api.js +443 -0
  484. package/dist/lib/api.js.map +1 -0
  485. package/dist/lib/chains.d.ts +151 -0
  486. package/dist/lib/chains.d.ts.map +1 -0
  487. package/dist/lib/chains.js +297 -0
  488. package/dist/lib/chains.js.map +1 -0
  489. package/dist/lib/contracts.d.ts +960 -0
  490. package/dist/lib/contracts.d.ts.map +1 -0
  491. package/dist/lib/contracts.js +716 -0
  492. package/dist/lib/contracts.js.map +1 -0
  493. package/dist/lib/cronos/aa.d.ts +111 -0
  494. package/dist/lib/cronos/aa.d.ts.map +1 -0
  495. package/dist/lib/cronos/aa.js +312 -0
  496. package/dist/lib/cronos/aa.js.map +1 -0
  497. package/dist/lib/cronos/facilitator.d.ts +87 -0
  498. package/dist/lib/cronos/facilitator.d.ts.map +1 -0
  499. package/dist/lib/cronos/facilitator.js +183 -0
  500. package/dist/lib/cronos/facilitator.js.map +1 -0
  501. package/dist/lib/evm.d.ts +45 -0
  502. package/dist/lib/evm.d.ts.map +1 -0
  503. package/dist/lib/evm.js +78 -0
  504. package/dist/lib/evm.js.map +1 -0
  505. package/dist/lib/mockData.d.ts +26 -0
  506. package/dist/lib/mockData.d.ts.map +1 -0
  507. package/dist/lib/mockData.js +89 -0
  508. package/dist/lib/mockData.js.map +1 -0
  509. package/dist/lib/models.d.ts +122 -0
  510. package/dist/lib/models.d.ts.map +1 -0
  511. package/dist/lib/models.js +174 -0
  512. package/dist/lib/models.js.map +1 -0
  513. package/dist/lib/multimodal.d.ts +53 -0
  514. package/dist/lib/multimodal.d.ts.map +1 -0
  515. package/dist/lib/multimodal.js +204 -0
  516. package/dist/lib/multimodal.js.map +1 -0
  517. package/dist/lib/payment.d.ts +67 -0
  518. package/dist/lib/payment.d.ts.map +1 -0
  519. package/dist/lib/payment.js +236 -0
  520. package/dist/lib/payment.js.map +1 -0
  521. package/dist/lib/pinata.d.ts +140 -0
  522. package/dist/lib/pinata.d.ts.map +1 -0
  523. package/dist/lib/pinata.js +209 -0
  524. package/dist/lib/pinata.js.map +1 -0
  525. package/dist/lib/queryClient.d.ts +9 -0
  526. package/dist/lib/queryClient.d.ts.map +1 -0
  527. package/dist/lib/queryClient.js +42 -0
  528. package/dist/lib/queryClient.js.map +1 -0
  529. package/dist/lib/services.d.ts +164 -0
  530. package/dist/lib/services.d.ts.map +1 -0
  531. package/dist/lib/services.js +304 -0
  532. package/dist/lib/services.js.map +1 -0
  533. package/dist/lib/share.d.ts +12 -0
  534. package/dist/lib/share.d.ts.map +1 -0
  535. package/dist/lib/share.js +39 -0
  536. package/dist/lib/share.js.map +1 -0
  537. package/dist/lib/triggers.d.ts +128 -0
  538. package/dist/lib/triggers.d.ts.map +1 -0
  539. package/dist/lib/triggers.js +305 -0
  540. package/dist/lib/triggers.js.map +1 -0
  541. package/dist/lib/utils.d.ts +1 -1
  542. package/dist/lib/utils.d.ts.map +1 -1
  543. package/dist/tailwind/preset.d.ts +282 -0
  544. package/dist/tailwind/preset.d.ts.map +1 -0
  545. package/dist/tailwind/preset.js +144 -0
  546. package/dist/tailwind/preset.js.map +1 -0
  547. package/package.json +9 -45
@@ -0,0 +1,224 @@
1
+ /**
2
+ * API Configuration and Types
3
+ *
4
+ * - Base URL configuration for Lambda API
5
+ * - OpenAI-compatible response types (from backend)
6
+ * - SSE stream parser
7
+ * - Response handling utilities
8
+ */
9
+ export declare const API_BASE_URL: any;
10
+ export declare function apiUrl(path: string): string;
11
+ export declare function apiFetch(path: string, init?: RequestInit): Promise<Response>;
12
+ /** OpenAI API message format - for requests/responses */
13
+ export interface APIChatMessage {
14
+ role: "system" | "user" | "assistant" | "tool";
15
+ content: string | APIChatContentPart[] | null;
16
+ name?: string;
17
+ tool_calls?: ToolCall[];
18
+ tool_call_id?: string;
19
+ }
20
+ export interface APIChatContentPart {
21
+ type: "text" | "image_url";
22
+ text?: string;
23
+ image_url?: {
24
+ url: string;
25
+ detail?: "auto" | "low" | "high";
26
+ };
27
+ }
28
+ export interface ToolCall {
29
+ id: string;
30
+ type: "function";
31
+ function: {
32
+ name: string;
33
+ arguments: string;
34
+ };
35
+ }
36
+ export type MessageType = "text" | "image" | "audio" | "video" | "embedding";
37
+ /** UI message format - for frontend state management */
38
+ export interface ChatMessage {
39
+ id: string;
40
+ role: "user" | "assistant";
41
+ content: string;
42
+ timestamp: number;
43
+ type?: MessageType;
44
+ imageUrl?: string;
45
+ audioUrl?: string;
46
+ videoUrl?: string;
47
+ }
48
+ /** Attached file for uploads */
49
+ export interface AttachedFile {
50
+ file: File;
51
+ cid?: string;
52
+ url?: string;
53
+ preview?: string;
54
+ uploading: boolean;
55
+ type: "image" | "audio" | "video";
56
+ }
57
+ export interface ParsedInvoke {
58
+ toolName: string;
59
+ params: Record<string, string>;
60
+ raw: string;
61
+ }
62
+ export interface ParsedContent {
63
+ think: string | null;
64
+ invokes: ParsedInvoke[];
65
+ reply: string;
66
+ }
67
+ /**
68
+ * Parses <think> and <invoke> tags from content
69
+ * Used by UI components and hooks to understand agent state
70
+ */
71
+ export declare function parseContentTags(content: string): ParsedContent;
72
+ export interface ChatCompletionChoice {
73
+ index: number;
74
+ message: APIChatMessage;
75
+ finish_reason: "stop" | "length" | "tool_calls" | "content_filter" | null;
76
+ }
77
+ export interface TokenUsage {
78
+ prompt_tokens: number;
79
+ completion_tokens: number;
80
+ total_tokens: number;
81
+ }
82
+ export interface ChatCompletionResponse {
83
+ id: string;
84
+ object: "chat.completion";
85
+ created: number;
86
+ model: string;
87
+ choices: ChatCompletionChoice[];
88
+ usage: TokenUsage;
89
+ }
90
+ export interface ChatCompletionChunk {
91
+ id: string;
92
+ object: "chat.completion.chunk";
93
+ created: number;
94
+ model: string;
95
+ choices: {
96
+ index: number;
97
+ delta: Partial<APIChatMessage>;
98
+ finish_reason: string | null;
99
+ }[];
100
+ }
101
+ export interface ImageData {
102
+ b64_json?: string;
103
+ url?: string;
104
+ revised_prompt?: string;
105
+ }
106
+ export interface ImagesResponse {
107
+ created: number;
108
+ data: ImageData[];
109
+ }
110
+ export interface AudioTranscriptionResponse {
111
+ text: string;
112
+ language?: string;
113
+ duration?: number;
114
+ }
115
+ export interface VideoData {
116
+ url?: string;
117
+ b64_json?: string;
118
+ duration?: number;
119
+ }
120
+ export interface VideoGenerationResponse {
121
+ created: number;
122
+ data: VideoData[];
123
+ model: string;
124
+ }
125
+ export interface VideoJobResponse {
126
+ id: string;
127
+ object: "video.generation";
128
+ status: "queued" | "processing" | "completed" | "failed";
129
+ created?: number;
130
+ model?: string;
131
+ url?: string;
132
+ error?: string;
133
+ progress?: number;
134
+ }
135
+ export interface EmbeddingData {
136
+ object: "embedding";
137
+ embedding: number[];
138
+ index: number;
139
+ }
140
+ export interface EmbeddingResponse {
141
+ object: "list";
142
+ data: EmbeddingData[];
143
+ model: string;
144
+ usage: {
145
+ prompt_tokens: number;
146
+ total_tokens: number;
147
+ };
148
+ }
149
+ export interface ResponsesOutputItem {
150
+ type: string;
151
+ role?: "assistant";
152
+ text?: string;
153
+ content?: Array<{
154
+ type?: string;
155
+ text?: string;
156
+ } | Record<string, unknown>>;
157
+ image_url?: string;
158
+ audio_url?: string;
159
+ video_url?: string;
160
+ embedding?: number[];
161
+ call_id?: string;
162
+ name?: string;
163
+ arguments?: string;
164
+ }
165
+ export interface ResponsesResponse {
166
+ id: string;
167
+ object: "response";
168
+ created_at: number;
169
+ status: "completed" | "in_progress" | "failed" | "cancelled";
170
+ model: string;
171
+ output?: ResponsesOutputItem[];
172
+ usage?: {
173
+ input_tokens: number;
174
+ output_tokens: number;
175
+ total_tokens: number;
176
+ };
177
+ error?: {
178
+ message?: string;
179
+ type?: string;
180
+ code?: string;
181
+ };
182
+ job_id?: string;
183
+ }
184
+ export type MultimodalType = "text" | "image" | "audio" | "video" | "embedding";
185
+ export interface MultimodalResult {
186
+ type: MultimodalType;
187
+ success: boolean;
188
+ content?: string;
189
+ url?: string;
190
+ base64?: string;
191
+ mimeType?: string;
192
+ embeddings?: number[];
193
+ error?: string;
194
+ jobId?: string;
195
+ polling?: boolean;
196
+ }
197
+ /**
198
+ * Parse SSE stream from text/event-stream response
199
+ * Yields text content chunks as they arrive
200
+ */
201
+ export declare function parseSSEStream(reader: ReadableStreamDefaultReader<Uint8Array>): AsyncGenerator<string, void, unknown>;
202
+ export type ResponseType = "sse" | "json" | "image" | "audio" | "video" | "binary" | "text";
203
+ export declare function detectResponseType(contentType: string): ResponseType;
204
+ /**
205
+ * Parse JSON response from Lambda API into unified MultimodalResult
206
+ */
207
+ export declare function parseJsonResponse(data: unknown): MultimodalResult;
208
+ export declare const TIMEOUT_CONFIG: {
209
+ readonly FETCH_TIMEOUT_MS: undefined;
210
+ readonly VIDEO_POLL: {
211
+ readonly INTERVAL_MS: 5000;
212
+ readonly MAX_ATTEMPTS: number;
213
+ };
214
+ readonly SSE_RETRY: {
215
+ readonly INITIAL_DELAY_MS: 1000;
216
+ readonly MAX_DELAY_MS: 30000;
217
+ readonly BACKOFF_MULTIPLIER: 2;
218
+ };
219
+ readonly SESSION_POLL: {
220
+ readonly INTERVAL_MS: 2000;
221
+ readonly MAX_ATTEMPTS: 30;
222
+ };
223
+ };
224
+ //# sourceMappingURL=api.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"api.d.ts","sourceRoot":"","sources":["../../src/lib/api.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AAMH,eAAO,MAAM,YAAY,KAEO,CAAC;AAEjC,wBAAgB,MAAM,CAAC,IAAI,EAAE,MAAM,GAAG,MAAM,CAE3C;AAED,wBAAsB,QAAQ,CAAC,IAAI,EAAE,MAAM,EAAE,IAAI,CAAC,EAAE,WAAW,GAAG,OAAO,CAAC,QAAQ,CAAC,CAElF;AAMD,yDAAyD;AACzD,MAAM,WAAW,cAAc;IAC7B,IAAI,EAAE,QAAQ,GAAG,MAAM,GAAG,WAAW,GAAG,MAAM,CAAC;IAC/C,OAAO,EAAE,MAAM,GAAG,kBAAkB,EAAE,GAAG,IAAI,CAAC;IAC9C,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,UAAU,CAAC,EAAE,QAAQ,EAAE,CAAC;IACxB,YAAY,CAAC,EAAE,MAAM,CAAC;CACvB;AAED,MAAM,WAAW,kBAAkB;IACjC,IAAI,EAAE,MAAM,GAAG,WAAW,CAAC;IAC3B,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,SAAS,CAAC,EAAE;QAAE,GAAG,EAAE,MAAM,CAAC;QAAC,MAAM,CAAC,EAAE,MAAM,GAAG,KAAK,GAAG,MAAM,CAAA;KAAE,CAAC;CAC/D;AAED,MAAM,WAAW,QAAQ;IACvB,EAAE,EAAE,MAAM,CAAC;IACX,IAAI,EAAE,UAAU,CAAC;IACjB,QAAQ,EAAE;QAAE,IAAI,EAAE,MAAM,CAAC;QAAC,SAAS,EAAE,MAAM,CAAA;KAAE,CAAC;CAC/C;AAMD,MAAM,MAAM,WAAW,GAAG,MAA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YAAY,GAAG,KAAK,GAAG,MAAM,GAAG,OAAO,GAAG,OAAO,GAAG,OAAO,GAAG,QAAQ,GAAG,MAAM,CAAC;AAE5F,wBAAgB,kBAAkB,CAAC,WAAW,EAAE,MAAM,GAAG,YAAY,CAQpE;AAMD;;GAEG;AACH,wBAAgB,iBAAiB,CAAC,IAAI,EAAE,OAAO,GAAG,gBAAgB,CAkNjE;AA+ED,eAAO,MAAM,cAAc;+BACM,SAAS;;;;;;;;;;;;;;CAchC,CAAC"}
@@ -0,0 +1,443 @@
1
+ /**
2
+ * API Configuration and Types
3
+ *
4
+ * - Base URL configuration for Lambda API
5
+ * - OpenAI-compatible response types (from backend)
6
+ * - SSE stream parser
7
+ * - Response handling utilities
8
+ */
9
+ // =============================================================================
10
+ // API Configuration
11
+ // =============================================================================
12
+ export const API_BASE_URL = import.meta.env.VITE_API_URL
13
+ ? import.meta.env.VITE_API_URL.replace(/\/$/, "")
14
+ : "https://api.compose.market";
15
+ export function apiUrl(path) {
16
+ return API_BASE_URL ? `${API_BASE_URL}${path}` : path;
17
+ }
18
+ export async function apiFetch(path, init) {
19
+ return fetch(apiUrl(path), init);
20
+ }
21
+ /**
22
+ * Parses <think> and <invoke> tags from content
23
+ * Used by UI components and hooks to understand agent state
24
+ */
25
+ export function parseContentTags(content) {
26
+ if (!content)
27
+ return { think: null, invokes: [], reply: "" };
28
+ // 1. Extract Think Block
29
+ const thinkMatch = content.match(/<think>([\s\S]*?)<\/think>/i);
30
+ const think = thinkMatch?.[1]?.trim() || null;
31
+ // 2. Extract Invoke Blocks
32
+ const invokes = [];
33
+ const invokeRegex = /<invoke>([\s\S]*?)<\/invoke>/gi;
34
+ let invokeMatch;
35
+ while ((invokeMatch = invokeRegex.exec(content)) !== null) {
36
+ const raw = invokeMatch[1];
37
+ const lines = raw.trim().split('\n');
38
+ const toolName = lines[0]?.trim() || 'Unknown Tool';
39
+ const params = {};
40
+ const paramRegex = /<(\w+)>([\s\S]*?)<\/\1>/gi;
41
+ let paramMatch;
42
+ while ((paramMatch = paramRegex.exec(raw)) !== null) {
43
+ params[paramMatch[1]] = paramMatch[2].trim();
44
+ }
45
+ invokes.push({ toolName, params, raw });
46
+ }
47
+ // 3. Clean Content (Reply)
48
+ let cleanContent = content
49
+ .replace(/<think>([\s\S]*?)<\/think>/gi, '')
50
+ .replace(/<invoke>([\s\S]*?)<\/invoke>/gi, '')
51
+ .replace(/<reply>|<\/reply>/gi, '') // Legacy tags
52
+ .trim();
53
+ // Handle partial tags (cleaning up incomplete tags at the end of stream)
54
+ cleanContent = cleanContent
55
+ .replace(/<think>([\s\S]*)$/gi, '')
56
+ .replace(/<invoke>([\s\S]*)$/gi, '')
57
+ .replace(/<\/invoke>|<\/think>/gi, '')
58
+ .trim();
59
+ return {
60
+ think,
61
+ invokes,
62
+ reply: cleanContent
63
+ };
64
+ }
65
+ // =============================================================================
66
+ // SSE Stream Parser
67
+ // =============================================================================
68
+ /**
69
+ * Parse SSE stream from text/event-stream response
70
+ * Yields text content chunks as they arrive
71
+ */
72
+ export async function* parseSSEStream(reader) {
73
+ const decoder = new TextDecoder();
74
+ let buffer = "";
75
+ while (true) {
76
+ const { done, value } = await reader.read();
77
+ if (done)
78
+ break;
79
+ buffer += decoder.decode(value, { stream: true });
80
+ // Process complete lines
81
+ const lines = buffer.split("\n");
82
+ buffer = lines.pop() || ""; // Keep incomplete line in buffer
83
+ for (const line of lines) {
84
+ if (line.startsWith("data: ")) {
85
+ const data = line.slice(6).trim();
86
+ if (data === "[DONE]")
87
+ return;
88
+ try {
89
+ const parsed = JSON.parse(data);
90
+ const chatChunk = parsed;
91
+ // Chat Completions chunk
92
+ if (Array.isArray(chatChunk.choices) &&
93
+ typeof chatChunk.choices?.[0]?.delta?.content === "string") {
94
+ yield chatChunk.choices[0].delta.content;
95
+ continue;
96
+ }
97
+ // Responses stream chunk
98
+ if (parsed.type === "response.output_text.delta") {
99
+ if (typeof parsed.delta === "string") {
100
+ yield parsed.delta;
101
+ continue;
102
+ }
103
+ if (parsed.delta &&
104
+ typeof parsed.delta === "object" &&
105
+ typeof parsed.delta.text === "string") {
106
+ yield parsed.delta.text;
107
+ continue;
108
+ }
109
+ continue;
110
+ }
111
+ // Generic text-bearing event payloads
112
+ if (typeof parsed.content === "string") {
113
+ yield parsed.content;
114
+ continue;
115
+ }
116
+ if (typeof parsed.text === "string") {
117
+ yield parsed.text;
118
+ continue;
119
+ }
120
+ }
121
+ catch {
122
+ // Attempt to handle custom events wrapped in data objects
123
+ try {
124
+ const parsed = JSON.parse(data);
125
+ if (typeof parsed?.content === "string")
126
+ yield parsed.content;
127
+ else if (typeof parsed?.text === "string")
128
+ yield parsed.text;
129
+ }
130
+ catch {
131
+ // Only yield raw fallback for non-JSON payloads.
132
+ if (data && !data.startsWith("{") && !data.startsWith("["))
133
+ yield data;
134
+ }
135
+ }
136
+ }
137
+ else if (line.trim() && !line.startsWith(":")) {
138
+ // Plain text streaming (no SSE format)
139
+ yield line;
140
+ }
141
+ }
142
+ }
143
+ // Process remaining buffer
144
+ if (buffer.trim()) {
145
+ yield buffer;
146
+ }
147
+ }
148
+ export function detectResponseType(contentType) {
149
+ if (contentType.includes("text/event-stream"))
150
+ return "sse";
151
+ if (contentType.includes("text/plain"))
152
+ return "text";
153
+ if (contentType.includes("application/json"))
154
+ return "json";
155
+ if (contentType.includes("image/"))
156
+ return "image";
157
+ if (contentType.includes("audio/"))
158
+ return "audio";
159
+ if (contentType.includes("video/"))
160
+ return "video";
161
+ return "binary";
162
+ }
163
+ // =============================================================================
164
+ // Parse OpenAI-format JSON responses
165
+ // =============================================================================
166
+ /**
167
+ * Parse JSON response from Lambda API into unified MultimodalResult
168
+ */
169
+ export function parseJsonResponse(data) {
170
+ // Error response - handle first to catch errors early
171
+ if (isErrorResponse(data)) {
172
+ const err = data.error;
173
+ const msg = typeof err === "string" ? err : (err?.message || JSON.stringify(err));
174
+ return { type: "text", success: false, error: msg };
175
+ }
176
+ // Agent chat response: { output: string, messages?: [...] }
177
+ if (isAgentChatResponse(data)) {
178
+ return { type: "text", success: true, content: data.output };
179
+ }
180
+ // Manowar multimodal response: { success, type, url, mimeType }
181
+ if (isManowarMultimodalResponse(data)) {
182
+ return {
183
+ type: data.type,
184
+ success: data.success,
185
+ url: data.url, // IPFS URL from backend Pinata upload
186
+ content: data.content,
187
+ mimeType: data.mimeType,
188
+ error: data.error,
189
+ };
190
+ }
191
+ // Canonical Responses API response
192
+ if (isResponsesResponse(data)) {
193
+ if (data.error?.message) {
194
+ return { type: "text", success: false, error: data.error.message };
195
+ }
196
+ if (data.status === "failed") {
197
+ return { type: "text", success: false, error: data.error?.message || "Request failed" };
198
+ }
199
+ if (data.status === "cancelled") {
200
+ return { type: "text", success: false, error: "Request cancelled" };
201
+ }
202
+ const textParts = [];
203
+ let imageUrl;
204
+ let audioUrl;
205
+ let videoUrl;
206
+ let embedding;
207
+ const outputItems = Array.isArray(data.output) ? data.output : [];
208
+ for (const item of outputItems) {
209
+ if (item.type === "output_text" && typeof item.text === "string") {
210
+ textParts.push(item.text);
211
+ continue;
212
+ }
213
+ if (item.type === "output_text" && Array.isArray(item.content)) {
214
+ for (const part of item.content) {
215
+ if (part &&
216
+ typeof part === "object" &&
217
+ typeof part.text === "string") {
218
+ textParts.push(part.text);
219
+ }
220
+ }
221
+ continue;
222
+ }
223
+ if (item.type === "output_image" && typeof item.image_url === "string") {
224
+ imageUrl = item.image_url;
225
+ continue;
226
+ }
227
+ if (item.type === "output_audio" && typeof item.audio_url === "string") {
228
+ audioUrl = item.audio_url;
229
+ continue;
230
+ }
231
+ if (item.type === "output_video" && typeof item.video_url === "string") {
232
+ videoUrl = item.video_url;
233
+ continue;
234
+ }
235
+ if (item.type === "output_embedding" && Array.isArray(item.embedding)) {
236
+ embedding = item.embedding;
237
+ }
238
+ }
239
+ if (videoUrl) {
240
+ return { type: "video", success: true, url: videoUrl, mimeType: "video/mp4" };
241
+ }
242
+ if (imageUrl) {
243
+ return { type: "image", success: true, url: imageUrl, mimeType: "image/png" };
244
+ }
245
+ if (audioUrl) {
246
+ return { type: "audio", success: true, url: audioUrl, mimeType: "audio/mpeg" };
247
+ }
248
+ if (embedding) {
249
+ return {
250
+ type: "embedding",
251
+ success: true,
252
+ embeddings: embedding,
253
+ content: JSON.stringify(embedding),
254
+ };
255
+ }
256
+ const text = textParts.join("").trim();
257
+ if (text.length > 0) {
258
+ return { type: "text", success: true, content: text };
259
+ }
260
+ if (data.status === "in_progress" && typeof data.job_id === "string") {
261
+ return {
262
+ type: "video",
263
+ success: true,
264
+ jobId: data.job_id,
265
+ polling: true,
266
+ content: "Video generating... (in_progress)",
267
+ };
268
+ }
269
+ return { type: "text", success: true, content: "" };
270
+ }
271
+ // Chat completion
272
+ if (isChatCompletionResponse(data)) {
273
+ const rawContent = data.choices?.[0]?.message?.content;
274
+ let content;
275
+ if (typeof rawContent === "string") {
276
+ content = rawContent;
277
+ }
278
+ else if (Array.isArray(rawContent)) {
279
+ content = rawContent.map(p => p.text || "").join("");
280
+ }
281
+ else {
282
+ content = "";
283
+ }
284
+ return {
285
+ type: "text",
286
+ success: true,
287
+ content,
288
+ };
289
+ }
290
+ // Image response
291
+ if (isImagesResponse(data)) {
292
+ const item = data.data?.[0];
293
+ return {
294
+ type: "image",
295
+ success: true,
296
+ base64: item?.b64_json,
297
+ url: item?.url,
298
+ mimeType: "image/png",
299
+ };
300
+ }
301
+ // Async video job response (needs polling)
302
+ if (isVideoJobResponse(data)) {
303
+ if (data.status === "completed" && data.url) {
304
+ return {
305
+ type: "video",
306
+ success: true,
307
+ url: data.url,
308
+ mimeType: "video/mp4",
309
+ };
310
+ }
311
+ if (data.status === "failed") {
312
+ return {
313
+ type: "video",
314
+ success: false,
315
+ error: data.error || "Video generation failed",
316
+ };
317
+ }
318
+ // Job is still processing - return polling info
319
+ return {
320
+ type: "video",
321
+ success: true,
322
+ jobId: data.id,
323
+ polling: true,
324
+ content: `Video generating... (${data.status})`,
325
+ };
326
+ }
327
+ // Video response (sync - has data array)
328
+ if (isVideoResponse(data)) {
329
+ const item = data.data?.[0];
330
+ return {
331
+ type: "video",
332
+ success: true,
333
+ base64: item?.b64_json,
334
+ url: item?.url,
335
+ mimeType: "video/mp4",
336
+ };
337
+ }
338
+ // Embedding response
339
+ if (isEmbeddingResponse(data)) {
340
+ return {
341
+ type: "embedding",
342
+ success: true,
343
+ embeddings: data.data?.[0]?.embedding,
344
+ content: JSON.stringify(data.data?.[0]?.embedding),
345
+ };
346
+ }
347
+ // Transcription response
348
+ if (isTranscriptionResponse(data)) {
349
+ return {
350
+ type: "text",
351
+ success: true,
352
+ content: data.text,
353
+ };
354
+ }
355
+ // Fallback: stringify unknown
356
+ return {
357
+ type: "text",
358
+ success: true,
359
+ content: typeof data === "string" ? data : JSON.stringify(data),
360
+ };
361
+ }
362
+ // Type guards
363
+ function isChatCompletionResponse(data) {
364
+ return !!data && typeof data === "object" && "choices" in data && Array.isArray(data.choices);
365
+ }
366
+ function isImagesResponse(data) {
367
+ return !!data && typeof data === "object" && "data" in data &&
368
+ Array.isArray(data.data) &&
369
+ (data.data[0]?.b64_json !== undefined || data.data[0]?.url !== undefined);
370
+ }
371
+ function isVideoResponse(data) {
372
+ if (!data || typeof data !== "object" || !("data" in data))
373
+ return false;
374
+ const arr = data.data;
375
+ if (!Array.isArray(arr) || arr.length === 0)
376
+ return false;
377
+ // Must have video data item with either b64_json or url
378
+ const item = arr[0];
379
+ return item && (item.b64_json !== undefined || item.url !== undefined);
380
+ }
381
+ function isVideoJobResponse(data) {
382
+ if (!data || typeof data !== "object")
383
+ return false;
384
+ const d = data;
385
+ // Must have id and status, and object should be "video.generation"
386
+ return typeof d.id === "string" &&
387
+ typeof d.status === "string" &&
388
+ d.object === "video.generation";
389
+ }
390
+ function isResponsesResponse(data) {
391
+ if (!data || typeof data !== "object")
392
+ return false;
393
+ const response = data;
394
+ return response.object === "response" &&
395
+ typeof response.id === "string";
396
+ }
397
+ function isEmbeddingResponse(data) {
398
+ return !!data && typeof data === "object" && "data" in data &&
399
+ data.object === "list";
400
+ }
401
+ function isTranscriptionResponse(data) {
402
+ return !!data && typeof data === "object" && "text" in data &&
403
+ typeof data.text === "string";
404
+ }
405
+ function isErrorResponse(data) {
406
+ return !!data && typeof data === "object" && "error" in data;
407
+ }
408
+ function isAgentChatResponse(data) {
409
+ return !!data && typeof data === "object" && "output" in data &&
410
+ typeof data.output === "string";
411
+ }
412
+ function isManowarMultimodalResponse(data) {
413
+ if (!data || typeof data !== "object")
414
+ return false;
415
+ const d = data;
416
+ // Must have success (boolean) and type (valid multimodal type)
417
+ if (typeof d.success !== "boolean")
418
+ return false;
419
+ if (typeof d.type !== "string")
420
+ return false;
421
+ const validTypes = ["text", "image", "audio", "video", "embedding"];
422
+ return validTypes.includes(d.type);
423
+ }
424
+ // =============================================================================
425
+ // Global API Configuration - NO Frontend Timeouts (Always-on Pattern)
426
+ // =============================================================================
427
+ export const TIMEOUT_CONFIG = {
428
+ FETCH_TIMEOUT_MS: undefined,
429
+ VIDEO_POLL: {
430
+ INTERVAL_MS: 5000,
431
+ MAX_ATTEMPTS: parseInt(import.meta.env.VITE_VIDEO_POLL_MAX_ATTEMPTS || "900", 10),
432
+ },
433
+ SSE_RETRY: {
434
+ INITIAL_DELAY_MS: 1000,
435
+ MAX_DELAY_MS: 30000,
436
+ BACKOFF_MULTIPLIER: 2,
437
+ },
438
+ SESSION_POLL: {
439
+ INTERVAL_MS: 2000,
440
+ MAX_ATTEMPTS: 30,
441
+ },
442
+ };
443
+ //# sourceMappingURL=api.js.map