@assistant-ui/core 0.2.4 → 0.2.5

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 (827) hide show
  1. package/dist/adapters/attachment.d.ts +43 -39
  2. package/dist/adapters/attachment.d.ts.map +1 -1
  3. package/dist/adapters/attachment.js +148 -183
  4. package/dist/adapters/attachment.js.map +1 -1
  5. package/dist/adapters/directive-formatter.d.ts +6 -2
  6. package/dist/adapters/directive-formatter.d.ts.map +1 -1
  7. package/dist/adapters/directive-formatter.js +36 -33
  8. package/dist/adapters/directive-formatter.js.map +1 -1
  9. package/dist/adapters/feedback.d.ts +9 -6
  10. package/dist/adapters/feedback.d.ts.map +1 -1
  11. package/dist/adapters/feedback.js +0 -2
  12. package/dist/adapters/index.d.ts +9 -13
  13. package/dist/adapters/index.js +5 -6
  14. package/dist/adapters/speech.d.ts +66 -63
  15. package/dist/adapters/speech.d.ts.map +1 -1
  16. package/dist/adapters/speech.js +170 -174
  17. package/dist/adapters/speech.js.map +1 -1
  18. package/dist/adapters/suggestion.d.ts +9 -6
  19. package/dist/adapters/suggestion.d.ts.map +1 -1
  20. package/dist/adapters/suggestion.js +0 -2
  21. package/dist/adapters/thread-history.d.ts +40 -37
  22. package/dist/adapters/thread-history.d.ts.map +1 -1
  23. package/dist/adapters/thread-history.js +0 -2
  24. package/dist/adapters/trigger.d.ts +9 -8
  25. package/dist/adapters/trigger.d.ts.map +1 -1
  26. package/dist/adapters/trigger.js +0 -2
  27. package/dist/adapters/voice.d.ts +46 -42
  28. package/dist/adapters/voice.d.ts.map +1 -1
  29. package/dist/adapters/voice.js +98 -107
  30. package/dist/adapters/voice.js.map +1 -1
  31. package/dist/index.d.ts +45 -53
  32. package/dist/index.js +16 -20
  33. package/dist/internal.d.ts +37 -8
  34. package/dist/internal.js +34 -18
  35. package/dist/model-context/frame/host.d.ts +23 -19
  36. package/dist/model-context/frame/host.d.ts.map +1 -1
  37. package/dist/model-context/frame/host.js +121 -135
  38. package/dist/model-context/frame/host.js.map +1 -1
  39. package/dist/model-context/frame/provider.d.ts +20 -16
  40. package/dist/model-context/frame/provider.d.ts.map +1 -1
  41. package/dist/model-context/frame/provider.js +115 -126
  42. package/dist/model-context/frame/provider.js.map +1 -1
  43. package/dist/model-context/frame/types.d.ts +25 -22
  44. package/dist/model-context/frame/types.d.ts.map +1 -1
  45. package/dist/model-context/frame/types.js +5 -1
  46. package/dist/model-context/frame/types.js.map +1 -1
  47. package/dist/model-context/registry-handles.d.ts +13 -9
  48. package/dist/model-context/registry-handles.d.ts.map +1 -1
  49. package/dist/model-context/registry-handles.js +0 -2
  50. package/dist/model-context/registry.d.ts +19 -15
  51. package/dist/model-context/registry.d.ts.map +1 -1
  52. package/dist/model-context/registry.js +93 -107
  53. package/dist/model-context/registry.js.map +1 -1
  54. package/dist/model-context/tool.d.ts +6 -2
  55. package/dist/model-context/tool.d.ts.map +1 -1
  56. package/dist/model-context/tool.js +30 -27
  57. package/dist/model-context/tool.js.map +1 -1
  58. package/dist/model-context/types.d.ts +37 -33
  59. package/dist/model-context/types.d.ts.map +1 -1
  60. package/dist/model-context/types.js +24 -38
  61. package/dist/model-context/types.js.map +1 -1
  62. package/dist/react/AssistantProvider.d.ts +12 -8
  63. package/dist/react/AssistantProvider.d.ts.map +1 -1
  64. package/dist/react/AssistantProvider.js +16 -9
  65. package/dist/react/AssistantProvider.js.map +1 -1
  66. package/dist/react/AssistantRuntimeProvider.d.ts +26 -18
  67. package/dist/react/AssistantRuntimeProvider.d.ts.map +1 -1
  68. package/dist/react/AssistantRuntimeProvider.js +33 -25
  69. package/dist/react/AssistantRuntimeProvider.js.map +1 -1
  70. package/dist/react/RuntimeAdapter.d.ts +5 -2
  71. package/dist/react/RuntimeAdapter.d.ts.map +1 -1
  72. package/dist/react/RuntimeAdapter.js +11 -11
  73. package/dist/react/RuntimeAdapter.js.map +1 -1
  74. package/dist/react/adapters/LocalStorageThreadListAdapter.d.ts +14 -11
  75. package/dist/react/adapters/LocalStorageThreadListAdapter.d.ts.map +1 -1
  76. package/dist/react/adapters/LocalStorageThreadListAdapter.js +136 -147
  77. package/dist/react/adapters/LocalStorageThreadListAdapter.js.map +1 -1
  78. package/dist/react/adapters/TitleGenerationAdapter.d.ts +8 -4
  79. package/dist/react/adapters/TitleGenerationAdapter.d.ts.map +1 -1
  80. package/dist/react/adapters/TitleGenerationAdapter.js +13 -13
  81. package/dist/react/adapters/TitleGenerationAdapter.js.map +1 -1
  82. package/dist/react/client/DataRenderers.d.ts +6 -2
  83. package/dist/react/client/DataRenderers.d.ts.map +1 -1
  84. package/dist/react/client/DataRenderers.js +53 -51
  85. package/dist/react/client/DataRenderers.js.map +1 -1
  86. package/dist/react/client/Interactables.d.ts +6 -2
  87. package/dist/react/client/Interactables.d.ts.map +1 -1
  88. package/dist/react/client/Interactables.js +251 -257
  89. package/dist/react/client/Interactables.js.map +1 -1
  90. package/dist/react/client/Tools.d.ts +13 -14
  91. package/dist/react/client/Tools.d.ts.map +1 -1
  92. package/dist/react/client/Tools.js +57 -68
  93. package/dist/react/client/Tools.js.map +1 -1
  94. package/dist/react/client/interactable-model-context.d.ts +10 -6
  95. package/dist/react/client/interactable-model-context.d.ts.map +1 -1
  96. package/dist/react/client/interactable-model-context.js +51 -59
  97. package/dist/react/client/interactable-model-context.js.map +1 -1
  98. package/dist/react/index.d.ts +95 -90
  99. package/dist/react/index.js +88 -96
  100. package/dist/react/model-context/makeAssistantDataUI.d.ts +9 -6
  101. package/dist/react/model-context/makeAssistantDataUI.d.ts.map +1 -1
  102. package/dist/react/model-context/makeAssistantDataUI.js +17 -13
  103. package/dist/react/model-context/makeAssistantDataUI.js.map +1 -1
  104. package/dist/react/model-context/makeAssistantTool.d.ts +9 -6
  105. package/dist/react/model-context/makeAssistantTool.d.ts.map +1 -1
  106. package/dist/react/model-context/makeAssistantTool.js +18 -14
  107. package/dist/react/model-context/makeAssistantTool.js.map +1 -1
  108. package/dist/react/model-context/makeAssistantToolUI.d.ts +9 -6
  109. package/dist/react/model-context/makeAssistantToolUI.d.ts.map +1 -1
  110. package/dist/react/model-context/makeAssistantToolUI.js +19 -15
  111. package/dist/react/model-context/makeAssistantToolUI.js.map +1 -1
  112. package/dist/react/model-context/toolbox.d.ts +13 -11
  113. package/dist/react/model-context/toolbox.d.ts.map +1 -1
  114. package/dist/react/model-context/toolbox.js +0 -2
  115. package/dist/react/model-context/useAssistantContext.d.ts +5 -3
  116. package/dist/react/model-context/useAssistantContext.d.ts.map +1 -1
  117. package/dist/react/model-context/useAssistantContext.js +13 -14
  118. package/dist/react/model-context/useAssistantContext.js.map +1 -1
  119. package/dist/react/model-context/useAssistantDataUI.d.ts +9 -7
  120. package/dist/react/model-context/useAssistantDataUI.d.ts.map +1 -1
  121. package/dist/react/model-context/useAssistantDataUI.js +19 -12
  122. package/dist/react/model-context/useAssistantDataUI.js.map +1 -1
  123. package/dist/react/model-context/useAssistantInstructions.d.ts +5 -3
  124. package/dist/react/model-context/useAssistantInstructions.d.ts.map +1 -1
  125. package/dist/react/model-context/useAssistantInstructions.js +18 -16
  126. package/dist/react/model-context/useAssistantInstructions.js.map +1 -1
  127. package/dist/react/model-context/useAssistantInteractable.d.ts +12 -8
  128. package/dist/react/model-context/useAssistantInteractable.d.ts.map +1 -1
  129. package/dist/react/model-context/useAssistantInteractable.js +36 -26
  130. package/dist/react/model-context/useAssistantInteractable.js.map +1 -1
  131. package/dist/react/model-context/useAssistantTool.d.ts +9 -6
  132. package/dist/react/model-context/useAssistantTool.d.ts.map +1 -1
  133. package/dist/react/model-context/useAssistantTool.js +48 -47
  134. package/dist/react/model-context/useAssistantTool.js.map +1 -1
  135. package/dist/react/model-context/useAssistantToolUI.d.ts +9 -7
  136. package/dist/react/model-context/useAssistantToolUI.d.ts.map +1 -1
  137. package/dist/react/model-context/useAssistantToolUI.js +22 -15
  138. package/dist/react/model-context/useAssistantToolUI.js.map +1 -1
  139. package/dist/react/model-context/useInlineRender.d.ts +7 -3
  140. package/dist/react/model-context/useInlineRender.d.ts.map +1 -1
  141. package/dist/react/model-context/useInlineRender.js +12 -12
  142. package/dist/react/model-context/useInlineRender.js.map +1 -1
  143. package/dist/react/model-context/useInteractableState.d.ts +9 -7
  144. package/dist/react/model-context/useInteractableState.d.ts.map +1 -1
  145. package/dist/react/model-context/useInteractableState.js +29 -31
  146. package/dist/react/model-context/useInteractableState.js.map +1 -1
  147. package/dist/react/model-context/useToolArgsStatus.d.ts +7 -7
  148. package/dist/react/model-context/useToolArgsStatus.d.ts.map +1 -1
  149. package/dist/react/model-context/useToolArgsStatus.js +44 -50
  150. package/dist/react/model-context/useToolArgsStatus.js.map +1 -1
  151. package/dist/react/primitive-hooks/useActionBarCopy.d.ts +13 -7
  152. package/dist/react/primitive-hooks/useActionBarCopy.d.ts.map +1 -1
  153. package/dist/react/primitive-hooks/useActionBarCopy.js +31 -23
  154. package/dist/react/primitive-hooks/useActionBarCopy.js.map +1 -1
  155. package/dist/react/primitive-hooks/useActionBarEdit.d.ts +6 -3
  156. package/dist/react/primitive-hooks/useActionBarEdit.d.ts.map +1 -1
  157. package/dist/react/primitive-hooks/useActionBarEdit.js +13 -7
  158. package/dist/react/primitive-hooks/useActionBarEdit.js.map +1 -1
  159. package/dist/react/primitive-hooks/useActionBarFeedback.d.ts +9 -6
  160. package/dist/react/primitive-hooks/useActionBarFeedback.d.ts.map +1 -1
  161. package/dist/react/primitive-hooks/useActionBarFeedback.js +22 -14
  162. package/dist/react/primitive-hooks/useActionBarFeedback.js.map +1 -1
  163. package/dist/react/primitive-hooks/useActionBarReload.d.ts +6 -3
  164. package/dist/react/primitive-hooks/useActionBarReload.d.ts.map +1 -1
  165. package/dist/react/primitive-hooks/useActionBarReload.js +13 -9
  166. package/dist/react/primitive-hooks/useActionBarReload.js.map +1 -1
  167. package/dist/react/primitive-hooks/useActionBarSpeak.d.ts +6 -3
  168. package/dist/react/primitive-hooks/useActionBarSpeak.d.ts.map +1 -1
  169. package/dist/react/primitive-hooks/useActionBarSpeak.js +15 -11
  170. package/dist/react/primitive-hooks/useActionBarSpeak.js.map +1 -1
  171. package/dist/react/primitive-hooks/useActionBarStopSpeaking.d.ts +6 -3
  172. package/dist/react/primitive-hooks/useActionBarStopSpeaking.d.ts.map +1 -1
  173. package/dist/react/primitive-hooks/useActionBarStopSpeaking.js +13 -7
  174. package/dist/react/primitive-hooks/useActionBarStopSpeaking.js.map +1 -1
  175. package/dist/react/primitive-hooks/useBranchPickerNext.d.ts +6 -3
  176. package/dist/react/primitive-hooks/useBranchPickerNext.d.ts.map +1 -1
  177. package/dist/react/primitive-hooks/useBranchPickerNext.js +17 -14
  178. package/dist/react/primitive-hooks/useBranchPickerNext.js.map +1 -1
  179. package/dist/react/primitive-hooks/useBranchPickerPrevious.d.ts +6 -3
  180. package/dist/react/primitive-hooks/useBranchPickerPrevious.d.ts.map +1 -1
  181. package/dist/react/primitive-hooks/useBranchPickerPrevious.js +17 -14
  182. package/dist/react/primitive-hooks/useBranchPickerPrevious.js.map +1 -1
  183. package/dist/react/primitive-hooks/useComposerAddAttachment.d.ts +8 -4
  184. package/dist/react/primitive-hooks/useComposerAddAttachment.d.ts.map +1 -1
  185. package/dist/react/primitive-hooks/useComposerAddAttachment.js +13 -7
  186. package/dist/react/primitive-hooks/useComposerAddAttachment.js.map +1 -1
  187. package/dist/react/primitive-hooks/useComposerCancel.d.ts +6 -3
  188. package/dist/react/primitive-hooks/useComposerCancel.d.ts.map +1 -1
  189. package/dist/react/primitive-hooks/useComposerCancel.js +13 -7
  190. package/dist/react/primitive-hooks/useComposerCancel.js.map +1 -1
  191. package/dist/react/primitive-hooks/useComposerDictate.d.ts +6 -3
  192. package/dist/react/primitive-hooks/useComposerDictate.d.ts.map +1 -1
  193. package/dist/react/primitive-hooks/useComposerDictate.js +13 -9
  194. package/dist/react/primitive-hooks/useComposerDictate.js.map +1 -1
  195. package/dist/react/primitive-hooks/useComposerSend.d.ts +8 -4
  196. package/dist/react/primitive-hooks/useComposerSend.d.ts.map +1 -1
  197. package/dist/react/primitive-hooks/useComposerSend.js +13 -8
  198. package/dist/react/primitive-hooks/useComposerSend.js.map +1 -1
  199. package/dist/react/primitive-hooks/useEditComposerCancel.d.ts +5 -2
  200. package/dist/react/primitive-hooks/useEditComposerCancel.d.ts.map +1 -1
  201. package/dist/react/primitive-hooks/useEditComposerCancel.js +9 -6
  202. package/dist/react/primitive-hooks/useEditComposerCancel.js.map +1 -1
  203. package/dist/react/primitive-hooks/useEditComposerSend.d.ts +6 -3
  204. package/dist/react/primitive-hooks/useEditComposerSend.d.ts.map +1 -1
  205. package/dist/react/primitive-hooks/useEditComposerSend.js +13 -7
  206. package/dist/react/primitive-hooks/useEditComposerSend.js.map +1 -1
  207. package/dist/react/primitive-hooks/useMessageBranching.d.ts +8 -5
  208. package/dist/react/primitive-hooks/useMessageBranching.d.ts.map +1 -1
  209. package/dist/react/primitive-hooks/useMessageBranching.js +16 -11
  210. package/dist/react/primitive-hooks/useMessageBranching.js.map +1 -1
  211. package/dist/react/primitive-hooks/useMessageError.d.ts +4 -1
  212. package/dist/react/primitive-hooks/useMessageError.d.ts.map +1 -1
  213. package/dist/react/primitive-hooks/useMessageError.js +6 -5
  214. package/dist/react/primitive-hooks/useMessageError.js.map +1 -1
  215. package/dist/react/primitive-hooks/useMessageReload.d.ts +6 -3
  216. package/dist/react/primitive-hooks/useMessageReload.d.ts.map +1 -1
  217. package/dist/react/primitive-hooks/useMessageReload.js +13 -7
  218. package/dist/react/primitive-hooks/useMessageReload.js.map +1 -1
  219. package/dist/react/primitive-hooks/useSuggestionTrigger.d.ts +14 -7
  220. package/dist/react/primitive-hooks/useSuggestionTrigger.d.ts.map +1 -1
  221. package/dist/react/primitive-hooks/useSuggestionTrigger.js +33 -28
  222. package/dist/react/primitive-hooks/useSuggestionTrigger.js.map +1 -1
  223. package/dist/react/primitive-hooks/useThreadIsEmpty.d.ts +4 -1
  224. package/dist/react/primitive-hooks/useThreadIsEmpty.d.ts.map +1 -1
  225. package/dist/react/primitive-hooks/useThreadIsEmpty.js +6 -2
  226. package/dist/react/primitive-hooks/useThreadIsEmpty.js.map +1 -1
  227. package/dist/react/primitive-hooks/useThreadIsRunning.d.ts +4 -1
  228. package/dist/react/primitive-hooks/useThreadIsRunning.d.ts.map +1 -1
  229. package/dist/react/primitive-hooks/useThreadIsRunning.js +6 -2
  230. package/dist/react/primitive-hooks/useThreadIsRunning.js.map +1 -1
  231. package/dist/react/primitive-hooks/useThreadListItemArchive.d.ts +5 -2
  232. package/dist/react/primitive-hooks/useThreadListItemArchive.d.ts.map +1 -1
  233. package/dist/react/primitive-hooks/useThreadListItemArchive.js +9 -6
  234. package/dist/react/primitive-hooks/useThreadListItemArchive.js.map +1 -1
  235. package/dist/react/primitive-hooks/useThreadListItemDelete.d.ts +5 -2
  236. package/dist/react/primitive-hooks/useThreadListItemDelete.d.ts.map +1 -1
  237. package/dist/react/primitive-hooks/useThreadListItemDelete.js +9 -6
  238. package/dist/react/primitive-hooks/useThreadListItemDelete.js.map +1 -1
  239. package/dist/react/primitive-hooks/useThreadListItemTrigger.d.ts +5 -2
  240. package/dist/react/primitive-hooks/useThreadListItemTrigger.d.ts.map +1 -1
  241. package/dist/react/primitive-hooks/useThreadListItemTrigger.js +9 -6
  242. package/dist/react/primitive-hooks/useThreadListItemTrigger.js.map +1 -1
  243. package/dist/react/primitive-hooks/useThreadListItemUnarchive.d.ts +5 -2
  244. package/dist/react/primitive-hooks/useThreadListItemUnarchive.d.ts.map +1 -1
  245. package/dist/react/primitive-hooks/useThreadListItemUnarchive.js +9 -6
  246. package/dist/react/primitive-hooks/useThreadListItemUnarchive.js.map +1 -1
  247. package/dist/react/primitive-hooks/useThreadListLoadMore.d.ts +6 -3
  248. package/dist/react/primitive-hooks/useThreadListLoadMore.d.ts.map +1 -1
  249. package/dist/react/primitive-hooks/useThreadListLoadMore.js +13 -7
  250. package/dist/react/primitive-hooks/useThreadListLoadMore.js.map +1 -1
  251. package/dist/react/primitive-hooks/useThreadListNew.d.ts +5 -2
  252. package/dist/react/primitive-hooks/useThreadListNew.d.ts.map +1 -1
  253. package/dist/react/primitive-hooks/useThreadListNew.js +9 -6
  254. package/dist/react/primitive-hooks/useThreadListNew.js.map +1 -1
  255. package/dist/react/primitive-hooks/useThreadMessages.d.ts +6 -2
  256. package/dist/react/primitive-hooks/useThreadMessages.d.ts.map +1 -1
  257. package/dist/react/primitive-hooks/useThreadMessages.js +6 -2
  258. package/dist/react/primitive-hooks/useThreadMessages.js.map +1 -1
  259. package/dist/react/primitive-hooks/useVoice.d.ts +12 -8
  260. package/dist/react/primitive-hooks/useVoice.d.ts.map +1 -1
  261. package/dist/react/primitive-hooks/useVoice.js +25 -21
  262. package/dist/react/primitive-hooks/useVoice.js.map +1 -1
  263. package/dist/react/primitives/chainOfThought/ChainOfThoughtParts.d.ts +26 -27
  264. package/dist/react/primitives/chainOfThought/ChainOfThoughtParts.d.ts.map +1 -1
  265. package/dist/react/primitives/chainOfThought/ChainOfThoughtParts.js +30 -28
  266. package/dist/react/primitives/chainOfThought/ChainOfThoughtParts.js.map +1 -1
  267. package/dist/react/primitives/composer/ComposerAttachments.d.ts +27 -26
  268. package/dist/react/primitives/composer/ComposerAttachments.d.ts.map +1 -1
  269. package/dist/react/primitives/composer/ComposerAttachments.js +44 -48
  270. package/dist/react/primitives/composer/ComposerAttachments.js.map +1 -1
  271. package/dist/react/primitives/composer/ComposerIf.d.ts +12 -13
  272. package/dist/react/primitives/composer/ComposerIf.d.ts.map +1 -1
  273. package/dist/react/primitives/composer/ComposerIf.js +16 -17
  274. package/dist/react/primitives/composer/ComposerIf.js.map +1 -1
  275. package/dist/react/primitives/composer/ComposerQueue.d.ts +16 -13
  276. package/dist/react/primitives/composer/ComposerQueue.d.ts.map +1 -1
  277. package/dist/react/primitives/composer/ComposerQueue.js +31 -23
  278. package/dist/react/primitives/composer/ComposerQueue.js.map +1 -1
  279. package/dist/react/primitives/generativeUI/GenerativeUI.d.ts +64 -0
  280. package/dist/react/primitives/generativeUI/GenerativeUI.d.ts.map +1 -0
  281. package/dist/react/primitives/generativeUI/GenerativeUI.js +91 -0
  282. package/dist/react/primitives/generativeUI/GenerativeUI.js.map +1 -0
  283. package/dist/react/primitives/message/MessageAttachments.d.ts +27 -26
  284. package/dist/react/primitives/message/MessageAttachments.d.ts.map +1 -1
  285. package/dist/react/primitives/message/MessageAttachments.js +47 -52
  286. package/dist/react/primitives/message/MessageAttachments.js.map +1 -1
  287. package/dist/react/primitives/message/MessageGroupedParts.d.ts +73 -66
  288. package/dist/react/primitives/message/MessageGroupedParts.d.ts.map +1 -1
  289. package/dist/react/primitives/message/MessageGroupedParts.js +64 -61
  290. package/dist/react/primitives/message/MessageGroupedParts.js.map +1 -1
  291. package/dist/react/primitives/message/MessageParts.d.ts +147 -145
  292. package/dist/react/primitives/message/MessageParts.d.ts.map +1 -1
  293. package/dist/react/primitives/message/MessageParts.js +358 -335
  294. package/dist/react/primitives/message/MessageParts.js.map +1 -1
  295. package/dist/react/primitives/message/MessageQuote.d.ts +11 -8
  296. package/dist/react/primitives/message/MessageQuote.d.ts.map +1 -1
  297. package/dist/react/primitives/message/MessageQuote.js +24 -21
  298. package/dist/react/primitives/message/MessageQuote.js.map +1 -1
  299. package/dist/react/primitives/messagePart/MessagePartInProgress.d.ts +8 -4
  300. package/dist/react/primitives/messagePart/MessagePartInProgress.d.ts.map +1 -1
  301. package/dist/react/primitives/messagePart/MessagePartInProgress.js +6 -3
  302. package/dist/react/primitives/messagePart/MessagePartInProgress.js.map +1 -1
  303. package/dist/react/primitives/part/PartMessages.d.ts +16 -13
  304. package/dist/react/primitives/part/PartMessages.d.ts.map +1 -1
  305. package/dist/react/primitives/part/PartMessages.js +45 -41
  306. package/dist/react/primitives/part/PartMessages.js.map +1 -1
  307. package/dist/react/primitives/thread/ThreadMessages.d.ts +40 -55
  308. package/dist/react/primitives/thread/ThreadMessages.d.ts.map +1 -1
  309. package/dist/react/primitives/thread/ThreadMessages.js +58 -92
  310. package/dist/react/primitives/thread/ThreadMessages.js.map +1 -1
  311. package/dist/react/primitives/thread/ThreadSuggestions.d.ts +25 -25
  312. package/dist/react/primitives/thread/ThreadSuggestions.d.ts.map +1 -1
  313. package/dist/react/primitives/thread/ThreadSuggestions.js +39 -35
  314. package/dist/react/primitives/thread/ThreadSuggestions.js.map +1 -1
  315. package/dist/react/primitives/threadList/ThreadListItems.d.ts +27 -26
  316. package/dist/react/primitives/threadList/ThreadListItems.d.ts.map +1 -1
  317. package/dist/react/primitives/threadList/ThreadListItems.js +47 -23
  318. package/dist/react/primitives/threadList/ThreadListItems.js.map +1 -1
  319. package/dist/react/primitives/threadListItem/ThreadListItemTitle.d.ts +10 -6
  320. package/dist/react/primitives/threadListItem/ThreadListItemTitle.d.ts.map +1 -1
  321. package/dist/react/primitives/threadListItem/ThreadListItemTitle.js +7 -4
  322. package/dist/react/primitives/threadListItem/ThreadListItemTitle.js.map +1 -1
  323. package/dist/react/providers/AttachmentByIndexProvider.d.ts +9 -5
  324. package/dist/react/providers/AttachmentByIndexProvider.d.ts.map +1 -1
  325. package/dist/react/providers/AttachmentByIndexProvider.js +30 -20
  326. package/dist/react/providers/AttachmentByIndexProvider.js.map +1 -1
  327. package/dist/react/providers/ChainOfThoughtByIndicesProvider.d.ts +8 -4
  328. package/dist/react/providers/ChainOfThoughtByIndicesProvider.d.ts.map +1 -1
  329. package/dist/react/providers/ChainOfThoughtByIndicesProvider.js +19 -17
  330. package/dist/react/providers/ChainOfThoughtByIndicesProvider.js.map +1 -1
  331. package/dist/react/providers/ChainOfThoughtPartByIndexProvider.d.ts +7 -3
  332. package/dist/react/providers/ChainOfThoughtPartByIndexProvider.d.ts.map +1 -1
  333. package/dist/react/providers/ChainOfThoughtPartByIndexProvider.js +18 -11
  334. package/dist/react/providers/ChainOfThoughtPartByIndexProvider.js.map +1 -1
  335. package/dist/react/providers/MessageByIndexProvider.d.ts +7 -3
  336. package/dist/react/providers/MessageByIndexProvider.d.ts.map +1 -1
  337. package/dist/react/providers/MessageByIndexProvider.js +25 -16
  338. package/dist/react/providers/MessageByIndexProvider.js.map +1 -1
  339. package/dist/react/providers/PartByIndexProvider.d.ts +7 -3
  340. package/dist/react/providers/PartByIndexProvider.d.ts.map +1 -1
  341. package/dist/react/providers/PartByIndexProvider.js +18 -11
  342. package/dist/react/providers/PartByIndexProvider.js.map +1 -1
  343. package/dist/react/providers/QueueItemByIndexProvider.d.ts +8 -4
  344. package/dist/react/providers/QueueItemByIndexProvider.d.ts.map +1 -1
  345. package/dist/react/providers/QueueItemByIndexProvider.js +14 -10
  346. package/dist/react/providers/QueueItemByIndexProvider.js.map +1 -1
  347. package/dist/react/providers/ReadonlyThreadProvider.d.ts +11 -7
  348. package/dist/react/providers/ReadonlyThreadProvider.d.ts.map +1 -1
  349. package/dist/react/providers/ReadonlyThreadProvider.js +46 -42
  350. package/dist/react/providers/ReadonlyThreadProvider.js.map +1 -1
  351. package/dist/react/providers/SuggestionByIndexProvider.d.ts +8 -4
  352. package/dist/react/providers/SuggestionByIndexProvider.d.ts.map +1 -1
  353. package/dist/react/providers/SuggestionByIndexProvider.js +14 -10
  354. package/dist/react/providers/SuggestionByIndexProvider.js.map +1 -1
  355. package/dist/react/providers/TextMessagePartProvider.d.ts +8 -4
  356. package/dist/react/providers/TextMessagePartProvider.d.ts.map +1 -1
  357. package/dist/react/providers/TextMessagePartProvider.js +29 -22
  358. package/dist/react/providers/TextMessagePartProvider.js.map +1 -1
  359. package/dist/react/providers/ThreadListItemByIndexProvider.d.ts +8 -4
  360. package/dist/react/providers/ThreadListItemByIndexProvider.d.ts.map +1 -1
  361. package/dist/react/providers/ThreadListItemByIndexProvider.js +22 -11
  362. package/dist/react/providers/ThreadListItemByIndexProvider.js.map +1 -1
  363. package/dist/react/providers/ThreadListItemRuntimeProvider.d.ts +8 -4
  364. package/dist/react/providers/ThreadListItemRuntimeProvider.d.ts.map +1 -1
  365. package/dist/react/providers/ThreadListItemRuntimeProvider.js +12 -8
  366. package/dist/react/providers/ThreadListItemRuntimeProvider.js.map +1 -1
  367. package/dist/react/runtimes/RemoteThreadListHookInstanceManager.d.ts +119 -109
  368. package/dist/react/runtimes/RemoteThreadListHookInstanceManager.d.ts.map +1 -1
  369. package/dist/react/runtimes/RemoteThreadListHookInstanceManager.js +123 -129
  370. package/dist/react/runtimes/RemoteThreadListHookInstanceManager.js.map +1 -1
  371. package/dist/react/runtimes/RemoteThreadListThreadListRuntimeCore.d.ts +147 -135
  372. package/dist/react/runtimes/RemoteThreadListThreadListRuntimeCore.d.ts.map +1 -1
  373. package/dist/react/runtimes/RemoteThreadListThreadListRuntimeCore.js +460 -515
  374. package/dist/react/runtimes/RemoteThreadListThreadListRuntimeCore.js.map +1 -1
  375. package/dist/react/runtimes/RuntimeAdapterProvider.d.ts +19 -15
  376. package/dist/react/runtimes/RuntimeAdapterProvider.d.ts.map +1 -1
  377. package/dist/react/runtimes/RuntimeAdapterProvider.js +16 -9
  378. package/dist/react/runtimes/RuntimeAdapterProvider.js.map +1 -1
  379. package/dist/react/runtimes/cloud/AssistantCloudThreadHistoryAdapter.d.ts +8 -4
  380. package/dist/react/runtimes/cloud/AssistantCloudThreadHistoryAdapter.d.ts.map +1 -1
  381. package/dist/react/runtimes/cloud/AssistantCloudThreadHistoryAdapter.js +372 -485
  382. package/dist/react/runtimes/cloud/AssistantCloudThreadHistoryAdapter.js.map +1 -1
  383. package/dist/react/runtimes/cloud/CloudFileAttachmentAdapter.d.ts +19 -13
  384. package/dist/react/runtimes/cloud/CloudFileAttachmentAdapter.d.ts.map +1 -1
  385. package/dist/react/runtimes/cloud/CloudFileAttachmentAdapter.js +83 -80
  386. package/dist/react/runtimes/cloud/CloudFileAttachmentAdapter.js.map +1 -1
  387. package/dist/react/runtimes/cloud/auiV0.d.ts +61 -58
  388. package/dist/react/runtimes/cloud/auiV0.d.ts.map +1 -1
  389. package/dist/react/runtimes/cloud/auiV0.js +80 -87
  390. package/dist/react/runtimes/cloud/auiV0.js.map +1 -1
  391. package/dist/react/runtimes/cloud/useCloudThreadListAdapter.d.ts +10 -7
  392. package/dist/react/runtimes/cloud/useCloudThreadListAdapter.d.ts.map +1 -1
  393. package/dist/react/runtimes/cloud/useCloudThreadListAdapter.js +101 -101
  394. package/dist/react/runtimes/cloud/useCloudThreadListAdapter.js.map +1 -1
  395. package/dist/react/runtimes/createMessageConverter.d.ts +23 -14
  396. package/dist/react/runtimes/createMessageConverter.d.ts.map +1 -1
  397. package/dist/react/runtimes/createMessageConverter.js +43 -46
  398. package/dist/react/runtimes/createMessageConverter.js.map +1 -1
  399. package/dist/react/runtimes/external-message-converter.d.ts +40 -31
  400. package/dist/react/runtimes/external-message-converter.d.ts.map +1 -1
  401. package/dist/react/runtimes/external-message-converter.js +222 -296
  402. package/dist/react/runtimes/external-message-converter.js.map +1 -1
  403. package/dist/react/runtimes/useExternalStoreRuntime.d.ts +7 -3
  404. package/dist/react/runtimes/useExternalStoreRuntime.d.ts.map +1 -1
  405. package/dist/react/runtimes/useExternalStoreRuntime.js +18 -15
  406. package/dist/react/runtimes/useExternalStoreRuntime.js.map +1 -1
  407. package/dist/react/runtimes/useLocalRuntime.d.ts +41 -26
  408. package/dist/react/runtimes/useLocalRuntime.d.ts.map +1 -1
  409. package/dist/react/runtimes/useLocalRuntime.js +58 -67
  410. package/dist/react/runtimes/useLocalRuntime.js.map +1 -1
  411. package/dist/react/runtimes/useRemoteThreadListRuntime.d.ts +7 -3
  412. package/dist/react/runtimes/useRemoteThreadListRuntime.d.ts.map +1 -1
  413. package/dist/react/runtimes/useRemoteThreadListRuntime.js +51 -62
  414. package/dist/react/runtimes/useRemoteThreadListRuntime.js.map +1 -1
  415. package/dist/react/runtimes/useToolInvocations.d.ts +39 -34
  416. package/dist/react/runtimes/useToolInvocations.d.ts.map +1 -1
  417. package/dist/react/runtimes/useToolInvocations.js +371 -481
  418. package/dist/react/runtimes/useToolInvocations.js.map +1 -1
  419. package/dist/react/types/MessagePartComponentTypes.d.ts +65 -41
  420. package/dist/react/types/MessagePartComponentTypes.d.ts.map +1 -1
  421. package/dist/react/types/MessagePartComponentTypes.js +0 -2
  422. package/dist/react/types/scopes/dataRenderers.d.ts +15 -11
  423. package/dist/react/types/scopes/dataRenderers.d.ts.map +1 -1
  424. package/dist/react/types/scopes/dataRenderers.js +0 -2
  425. package/dist/react/types/scopes/interactables.d.ts +44 -42
  426. package/dist/react/types/scopes/interactables.d.ts.map +1 -1
  427. package/dist/react/types/scopes/interactables.js +0 -2
  428. package/dist/react/types/scopes/tools.d.ts +16 -12
  429. package/dist/react/types/scopes/tools.d.ts.map +1 -1
  430. package/dist/react/types/scopes/tools.js +0 -2
  431. package/dist/react/types/store-augmentation.d.ts +11 -9
  432. package/dist/react/types/store-augmentation.d.ts.map +1 -1
  433. package/dist/react/types/store-augmentation.js +0 -2
  434. package/dist/react/utils/getMessageQuote.d.ts +9 -6
  435. package/dist/react/utils/getMessageQuote.d.ts.map +1 -1
  436. package/dist/react/utils/getMessageQuote.js +8 -5
  437. package/dist/react/utils/getMessageQuote.js.map +1 -1
  438. package/dist/react/utils/groupParts.d.ts +22 -19
  439. package/dist/react/utils/groupParts.d.ts.map +1 -1
  440. package/dist/react/utils/groupParts.js +62 -89
  441. package/dist/react/utils/groupParts.js.map +1 -1
  442. package/dist/runtime/api/assistant-runtime.d.ts +32 -28
  443. package/dist/runtime/api/assistant-runtime.d.ts.map +1 -1
  444. package/dist/runtime/api/assistant-runtime.js +25 -22
  445. package/dist/runtime/api/assistant-runtime.js.map +1 -1
  446. package/dist/runtime/api/attachment-runtime.d.ts +48 -45
  447. package/dist/runtime/api/attachment-runtime.d.ts.map +1 -1
  448. package/dist/runtime/api/attachment-runtime.js +55 -52
  449. package/dist/runtime/api/attachment-runtime.js.map +1 -1
  450. package/dist/runtime/api/bindings.d.ts +30 -25
  451. package/dist/runtime/api/bindings.d.ts.map +1 -1
  452. package/dist/runtime/api/bindings.js +0 -2
  453. package/dist/runtime/api/composer-runtime.d.ts +184 -182
  454. package/dist/runtime/api/composer-runtime.d.ts.map +1 -1
  455. package/dist/runtime/api/composer-runtime.js +239 -245
  456. package/dist/runtime/api/composer-runtime.js.map +1 -1
  457. package/dist/runtime/api/message-part-runtime.d.ts +29 -27
  458. package/dist/runtime/api/message-part-runtime.d.ts.map +1 -1
  459. package/dist/runtime/api/message-part-runtime.js +61 -65
  460. package/dist/runtime/api/message-part-runtime.js.map +1 -1
  461. package/dist/runtime/api/message-runtime.d.ts +91 -80
  462. package/dist/runtime/api/message-runtime.d.ts.map +1 -1
  463. package/dist/runtime/api/message-runtime.js +169 -194
  464. package/dist/runtime/api/message-runtime.js.map +1 -1
  465. package/dist/runtime/api/paths.d.ts +57 -54
  466. package/dist/runtime/api/paths.d.ts.map +1 -1
  467. package/dist/runtime/api/paths.js +0 -2
  468. package/dist/runtime/api/thread-list-item-runtime.d.ts +68 -61
  469. package/dist/runtime/api/thread-list-item-runtime.d.ts.map +1 -1
  470. package/dist/runtime/api/thread-list-item-runtime.js +85 -84
  471. package/dist/runtime/api/thread-list-item-runtime.js.map +1 -1
  472. package/dist/runtime/api/thread-list-runtime.d.ts +57 -48
  473. package/dist/runtime/api/thread-list-runtime.d.ts.map +1 -1
  474. package/dist/runtime/api/thread-list-runtime.js +160 -147
  475. package/dist/runtime/api/thread-list-runtime.js.map +1 -1
  476. package/dist/runtime/api/thread-runtime.d.ts +278 -272
  477. package/dist/runtime/api/thread-runtime.d.ts.map +1 -1
  478. package/dist/runtime/api/thread-runtime.js +244 -244
  479. package/dist/runtime/api/thread-runtime.js.map +1 -1
  480. package/dist/runtime/base/base-assistant-runtime-core.d.ts +13 -9
  481. package/dist/runtime/base/base-assistant-runtime-core.d.ts.map +1 -1
  482. package/dist/runtime/base/base-assistant-runtime-core.js +13 -9
  483. package/dist/runtime/base/base-assistant-runtime-core.js.map +1 -1
  484. package/dist/runtime/base/base-composer-runtime-core.d.ts +60 -57
  485. package/dist/runtime/base/base-composer-runtime-core.d.ts.map +1 -1
  486. package/dist/runtime/base/base-composer-runtime-core.js +348 -392
  487. package/dist/runtime/base/base-composer-runtime-core.js.map +1 -1
  488. package/dist/runtime/base/base-thread-runtime-core.d.ts +89 -84
  489. package/dist/runtime/base/base-thread-runtime-core.d.ts.map +1 -1
  490. package/dist/runtime/base/base-thread-runtime-core.js +349 -357
  491. package/dist/runtime/base/base-thread-runtime-core.js.map +1 -1
  492. package/dist/runtime/base/default-edit-composer-runtime-core.d.ts +37 -30
  493. package/dist/runtime/base/default-edit-composer-runtime-core.d.ts.map +1 -1
  494. package/dist/runtime/base/default-edit-composer-runtime-core.js +70 -77
  495. package/dist/runtime/base/default-edit-composer-runtime-core.js.map +1 -1
  496. package/dist/runtime/base/default-thread-composer-runtime-core.d.ts +25 -21
  497. package/dist/runtime/base/default-thread-composer-runtime-core.d.ts.map +1 -1
  498. package/dist/runtime/base/default-thread-composer-runtime-core.js +51 -48
  499. package/dist/runtime/base/default-thread-composer-runtime-core.js.map +1 -1
  500. package/dist/runtime/interfaces/assistant-runtime-core.d.ts +12 -8
  501. package/dist/runtime/interfaces/assistant-runtime-core.d.ts.map +1 -1
  502. package/dist/runtime/interfaces/assistant-runtime-core.js +0 -2
  503. package/dist/runtime/interfaces/composer-runtime-core.d.ts +70 -67
  504. package/dist/runtime/interfaces/composer-runtime-core.d.ts.map +1 -1
  505. package/dist/runtime/interfaces/composer-runtime-core.js +0 -2
  506. package/dist/runtime/interfaces/thread-list-runtime-core.d.ts +45 -39
  507. package/dist/runtime/interfaces/thread-list-runtime-core.d.ts.map +1 -1
  508. package/dist/runtime/interfaces/thread-list-runtime-core.js +0 -2
  509. package/dist/runtime/interfaces/thread-runtime-core.d.ts +149 -145
  510. package/dist/runtime/interfaces/thread-runtime-core.d.ts.map +1 -1
  511. package/dist/runtime/interfaces/thread-runtime-core.js +0 -2
  512. package/dist/runtime/internal.d.ts +19 -23
  513. package/dist/runtime/internal.js +18 -22
  514. package/dist/runtime/utils/auto-status.d.ts +8 -4
  515. package/dist/runtime/utils/auto-status.d.ts.map +1 -1
  516. package/dist/runtime/utils/auto-status.js +18 -22
  517. package/dist/runtime/utils/auto-status.js.map +1 -1
  518. package/dist/runtime/utils/chat-model-adapter.d.ts +34 -31
  519. package/dist/runtime/utils/chat-model-adapter.d.ts.map +1 -1
  520. package/dist/runtime/utils/chat-model-adapter.js +0 -2
  521. package/dist/runtime/utils/external-store-message.d.ts +9 -5
  522. package/dist/runtime/utils/external-store-message.d.ts.map +1 -1
  523. package/dist/runtime/utils/external-store-message.js +21 -21
  524. package/dist/runtime/utils/external-store-message.js.map +1 -1
  525. package/dist/runtime/utils/message-repository.d.ts +48 -42
  526. package/dist/runtime/utils/message-repository.d.ts.map +1 -1
  527. package/dist/runtime/utils/message-repository.js +213 -267
  528. package/dist/runtime/utils/message-repository.js.map +1 -1
  529. package/dist/runtime/utils/thread-message-like.d.ts +41 -39
  530. package/dist/runtime/utils/thread-message-like.d.ts.map +1 -1
  531. package/dist/runtime/utils/thread-message-like.js +125 -139
  532. package/dist/runtime/utils/thread-message-like.js.map +1 -1
  533. package/dist/runtimes/assistant-transport/utils.d.ts +4 -1
  534. package/dist/runtimes/assistant-transport/utils.d.ts.map +1 -1
  535. package/dist/runtimes/assistant-transport/utils.js +9 -5
  536. package/dist/runtimes/assistant-transport/utils.js.map +1 -1
  537. package/dist/runtimes/external-store/external-store-adapter.d.ts +100 -97
  538. package/dist/runtimes/external-store/external-store-adapter.d.ts.map +1 -1
  539. package/dist/runtimes/external-store/external-store-adapter.js +0 -2
  540. package/dist/runtimes/external-store/external-store-runtime-core.d.ts +9 -5
  541. package/dist/runtimes/external-store/external-store-runtime-core.d.ts.map +1 -1
  542. package/dist/runtimes/external-store/external-store-runtime-core.js +16 -13
  543. package/dist/runtimes/external-store/external-store-runtime-core.js.map +1 -1
  544. package/dist/runtimes/external-store/external-store-thread-list-runtime-core.d.ts +46 -40
  545. package/dist/runtimes/external-store/external-store-thread-list-runtime-core.d.ts.map +1 -1
  546. package/dist/runtimes/external-store/external-store-thread-list-runtime-core.js +141 -171
  547. package/dist/runtimes/external-store/external-store-thread-list-runtime-core.js.map +1 -1
  548. package/dist/runtimes/external-store/external-store-thread-runtime-core.d.ts +53 -47
  549. package/dist/runtimes/external-store/external-store-thread-runtime-core.d.ts.map +1 -1
  550. package/dist/runtimes/external-store/external-store-thread-runtime-core.js +212 -288
  551. package/dist/runtimes/external-store/external-store-thread-runtime-core.js.map +1 -1
  552. package/dist/runtimes/external-store/thread-message-converter.d.ts +9 -5
  553. package/dist/runtimes/external-store/thread-message-converter.d.ts.map +1 -1
  554. package/dist/runtimes/external-store/thread-message-converter.js +14 -11
  555. package/dist/runtimes/external-store/thread-message-converter.js.map +1 -1
  556. package/dist/runtimes/internal.d.ts +15 -19
  557. package/dist/runtimes/internal.js +13 -17
  558. package/dist/runtimes/local/local-runtime-core.d.ts +11 -7
  559. package/dist/runtimes/local/local-runtime-core.d.ts.map +1 -1
  560. package/dist/runtimes/local/local-runtime-core.js +18 -18
  561. package/dist/runtimes/local/local-runtime-core.js.map +1 -1
  562. package/dist/runtimes/local/local-runtime-options.d.ts +27 -23
  563. package/dist/runtimes/local/local-runtime-options.d.ts.map +1 -1
  564. package/dist/runtimes/local/local-runtime-options.js +0 -2
  565. package/dist/runtimes/local/local-thread-list-runtime-core.d.ts +46 -42
  566. package/dist/runtimes/local/local-thread-list-runtime-core.d.ts.map +1 -1
  567. package/dist/runtimes/local/local-thread-list-runtime-core.js +84 -83
  568. package/dist/runtimes/local/local-thread-list-runtime-core.js.map +1 -1
  569. package/dist/runtimes/local/local-thread-runtime-core.d.ts +80 -59
  570. package/dist/runtimes/local/local-thread-runtime-core.d.ts.map +1 -1
  571. package/dist/runtimes/local/local-thread-runtime-core.js +342 -424
  572. package/dist/runtimes/local/local-thread-runtime-core.js.map +1 -1
  573. package/dist/runtimes/local/should-continue.d.ts +6 -2
  574. package/dist/runtimes/local/should-continue.d.ts.map +1 -1
  575. package/dist/runtimes/local/should-continue.js +7 -12
  576. package/dist/runtimes/local/should-continue.js.map +1 -1
  577. package/dist/runtimes/readonly/ReadonlyThreadRuntimeCore.d.ts +96 -92
  578. package/dist/runtimes/readonly/ReadonlyThreadRuntimeCore.d.ts.map +1 -1
  579. package/dist/runtimes/readonly/ReadonlyThreadRuntimeCore.js +164 -176
  580. package/dist/runtimes/readonly/ReadonlyThreadRuntimeCore.js.map +1 -1
  581. package/dist/runtimes/remote-thread-list/adapter/in-memory.d.ts +15 -11
  582. package/dist/runtimes/remote-thread-list/adapter/in-memory.d.ts.map +1 -1
  583. package/dist/runtimes/remote-thread-list/adapter/in-memory.js +33 -28
  584. package/dist/runtimes/remote-thread-list/adapter/in-memory.js.map +1 -1
  585. package/dist/runtimes/remote-thread-list/empty-thread-core.d.ts +6 -2
  586. package/dist/runtimes/remote-thread-list/empty-thread-core.d.ts.map +1 -1
  587. package/dist/runtimes/remote-thread-list/empty-thread-core.js +152 -160
  588. package/dist/runtimes/remote-thread-list/empty-thread-core.js.map +1 -1
  589. package/dist/runtimes/remote-thread-list/optimistic-state.d.ts +27 -27
  590. package/dist/runtimes/remote-thread-list/optimistic-state.d.ts.map +1 -1
  591. package/dist/runtimes/remote-thread-list/optimistic-state.js +63 -73
  592. package/dist/runtimes/remote-thread-list/optimistic-state.js.map +1 -1
  593. package/dist/runtimes/remote-thread-list/remote-thread-state.d.ts +46 -43
  594. package/dist/runtimes/remote-thread-list/remote-thread-state.d.ts.map +1 -1
  595. package/dist/runtimes/remote-thread-list/remote-thread-state.js +81 -91
  596. package/dist/runtimes/remote-thread-list/remote-thread-state.js.map +1 -1
  597. package/dist/runtimes/remote-thread-list/types.d.ts +65 -61
  598. package/dist/runtimes/remote-thread-list/types.d.ts.map +1 -1
  599. package/dist/runtimes/remote-thread-list/types.js +0 -2
  600. package/dist/store/clients/chain-of-thought-client.d.ts +16 -12
  601. package/dist/store/clients/chain-of-thought-client.d.ts.map +1 -1
  602. package/dist/store/clients/chain-of-thought-client.js +24 -15
  603. package/dist/store/clients/chain-of-thought-client.js.map +1 -1
  604. package/dist/store/clients/model-context-client.d.ts +6 -2
  605. package/dist/store/clients/model-context-client.d.ts.map +1 -1
  606. package/dist/store/clients/model-context-client.js +32 -26
  607. package/dist/store/clients/model-context-client.js.map +1 -1
  608. package/dist/store/clients/no-op-composer-client.d.ts +8 -4
  609. package/dist/store/clients/no-op-composer-client.d.ts.map +1 -1
  610. package/dist/store/clients/no-op-composer-client.js +67 -63
  611. package/dist/store/clients/no-op-composer-client.js.map +1 -1
  612. package/dist/store/clients/runtime-adapter.d.ts +8 -4
  613. package/dist/store/clients/runtime-adapter.d.ts.map +1 -1
  614. package/dist/store/clients/runtime-adapter.js +33 -33
  615. package/dist/store/clients/runtime-adapter.js.map +1 -1
  616. package/dist/store/clients/suggestions.d.ts +12 -8
  617. package/dist/store/clients/suggestions.d.ts.map +1 -1
  618. package/dist/store/clients/suggestions.js +28 -32
  619. package/dist/store/clients/suggestions.js.map +1 -1
  620. package/dist/store/clients/thread-message-client.d.ts +13 -9
  621. package/dist/store/clients/thread-message-client.d.ts.map +1 -1
  622. package/dist/store/clients/thread-message-client.js +95 -105
  623. package/dist/store/clients/thread-message-client.js.map +1 -1
  624. package/dist/store/index.d.ts +18 -18
  625. package/dist/store/index.js +6 -8
  626. package/dist/store/internal.d.ts +9 -9
  627. package/dist/store/internal.js +9 -9
  628. package/dist/store/runtime-clients/attachment-runtime-client.d.ts +9 -5
  629. package/dist/store/runtime-clients/attachment-runtime-client.d.ts.map +1 -1
  630. package/dist/store/runtime-clients/attachment-runtime-client.js +12 -8
  631. package/dist/store/runtime-clients/attachment-runtime-client.js.map +1 -1
  632. package/dist/store/runtime-clients/composer-runtime-client.d.ts +14 -10
  633. package/dist/store/runtime-clients/composer-runtime-client.d.ts.map +1 -1
  634. package/dist/store/runtime-clients/composer-runtime-client.js +86 -89
  635. package/dist/store/runtime-clients/composer-runtime-client.js.map +1 -1
  636. package/dist/store/runtime-clients/message-part-runtime-client.d.ts +9 -5
  637. package/dist/store/runtime-clients/message-part-runtime-client.d.ts.map +1 -1
  638. package/dist/store/runtime-clients/message-part-runtime-client.js +13 -9
  639. package/dist/store/runtime-clients/message-part-runtime-client.js.map +1 -1
  640. package/dist/store/runtime-clients/message-runtime-client.d.ts +12 -8
  641. package/dist/store/runtime-clients/message-runtime-client.d.ts.map +1 -1
  642. package/dist/store/runtime-clients/message-runtime-client.js +66 -70
  643. package/dist/store/runtime-clients/message-runtime-client.js.map +1 -1
  644. package/dist/store/runtime-clients/tap-subscribable.d.ts +6 -2
  645. package/dist/store/runtime-clients/tap-subscribable.d.ts.map +1 -1
  646. package/dist/store/runtime-clients/tap-subscribable.js +14 -10
  647. package/dist/store/runtime-clients/tap-subscribable.js.map +1 -1
  648. package/dist/store/runtime-clients/thread-list-item-runtime-client.d.ts +9 -5
  649. package/dist/store/runtime-clients/thread-list-item-runtime-client.d.ts.map +1 -1
  650. package/dist/store/runtime-clients/thread-list-item-runtime-client.js +33 -38
  651. package/dist/store/runtime-clients/thread-list-item-runtime-client.js.map +1 -1
  652. package/dist/store/runtime-clients/thread-list-runtime-client.d.ts +12 -8
  653. package/dist/store/runtime-clients/thread-list-runtime-client.d.ts.map +1 -1
  654. package/dist/store/runtime-clients/thread-list-runtime-client.js +53 -53
  655. package/dist/store/runtime-clients/thread-list-runtime-client.js.map +1 -1
  656. package/dist/store/runtime-clients/thread-runtime-client.d.ts +9 -5
  657. package/dist/store/runtime-clients/thread-runtime-client.d.ts.map +1 -1
  658. package/dist/store/runtime-clients/thread-runtime-client.js +93 -85
  659. package/dist/store/runtime-clients/thread-runtime-client.js.map +1 -1
  660. package/dist/store/scope-registration.d.ts +29 -27
  661. package/dist/store/scope-registration.d.ts.map +1 -1
  662. package/dist/store/scope-registration.js +0 -2
  663. package/dist/store/scopes/attachment.d.ts +23 -19
  664. package/dist/store/scopes/attachment.d.ts.map +1 -1
  665. package/dist/store/scopes/attachment.js +0 -2
  666. package/dist/store/scopes/chain-of-thought.d.ts +36 -33
  667. package/dist/store/scopes/chain-of-thought.d.ts.map +1 -1
  668. package/dist/store/scopes/chain-of-thought.js +0 -2
  669. package/dist/store/scopes/composer.d.ts +118 -115
  670. package/dist/store/scopes/composer.d.ts.map +1 -1
  671. package/dist/store/scopes/composer.js +0 -2
  672. package/dist/store/scopes/message.d.ts +81 -81
  673. package/dist/store/scopes/message.d.ts.map +1 -1
  674. package/dist/store/scopes/message.js +0 -2
  675. package/dist/store/scopes/model-context.d.ts +14 -10
  676. package/dist/store/scopes/model-context.d.ts.map +1 -1
  677. package/dist/store/scopes/model-context.js +0 -2
  678. package/dist/store/scopes/part.d.ts +42 -39
  679. package/dist/store/scopes/part.d.ts.map +1 -1
  680. package/dist/store/scopes/part.js +0 -2
  681. package/dist/store/scopes/queue-item.d.ts +18 -15
  682. package/dist/store/scopes/queue-item.d.ts.map +1 -1
  683. package/dist/store/scopes/queue-item.js +0 -2
  684. package/dist/store/scopes/suggestion.d.ts +17 -14
  685. package/dist/store/scopes/suggestion.d.ts.map +1 -1
  686. package/dist/store/scopes/suggestion.js +0 -2
  687. package/dist/store/scopes/suggestions.d.ts +18 -14
  688. package/dist/store/scopes/suggestions.d.ts.map +1 -1
  689. package/dist/store/scopes/suggestions.js +0 -2
  690. package/dist/store/scopes/thread-list-item.d.ts +62 -56
  691. package/dist/store/scopes/thread-list-item.d.ts.map +1 -1
  692. package/dist/store/scopes/thread-list-item.js +0 -2
  693. package/dist/store/scopes/thread.d.ts +151 -149
  694. package/dist/store/scopes/thread.d.ts.map +1 -1
  695. package/dist/store/scopes/thread.js +0 -2
  696. package/dist/store/scopes/threads.d.ts +36 -30
  697. package/dist/store/scopes/threads.d.ts.map +1 -1
  698. package/dist/store/scopes/threads.js +0 -2
  699. package/dist/subscribable/subscribable.d.ts +62 -58
  700. package/dist/subscribable/subscribable.d.ts.map +1 -1
  701. package/dist/subscribable/subscribable.js +196 -220
  702. package/dist/subscribable/subscribable.js.map +1 -1
  703. package/dist/tests/remote-thread-list-test-helpers.d.ts +13 -9
  704. package/dist/tests/remote-thread-list-test-helpers.d.ts.map +1 -1
  705. package/dist/tests/remote-thread-list-test-helpers.js +49 -42
  706. package/dist/tests/remote-thread-list-test-helpers.js.map +1 -1
  707. package/dist/types/attachment.d.ts +35 -32
  708. package/dist/types/attachment.d.ts.map +1 -1
  709. package/dist/types/attachment.js +0 -2
  710. package/dist/types/directive.d.ts +15 -13
  711. package/dist/types/directive.d.ts.map +1 -1
  712. package/dist/types/directive.js +0 -2
  713. package/dist/types/index.d.ts +7 -7
  714. package/dist/types/index.js +0 -2
  715. package/dist/types/message.d.ts +238 -214
  716. package/dist/types/message.d.ts.map +1 -1
  717. package/dist/types/message.js +6 -2
  718. package/dist/types/message.js.map +1 -1
  719. package/dist/types/quote.d.ts +6 -3
  720. package/dist/types/quote.d.ts.map +1 -1
  721. package/dist/types/quote.js +0 -2
  722. package/dist/types/trigger.d.ts +14 -10
  723. package/dist/types/trigger.d.ts.map +1 -1
  724. package/dist/types/trigger.js +0 -2
  725. package/dist/types/unsubscribe.d.ts +4 -1
  726. package/dist/types/unsubscribe.d.ts.map +1 -1
  727. package/dist/types/unsubscribe.js +0 -2
  728. package/dist/utils/composite-context-provider.d.ts +11 -8
  729. package/dist/utils/composite-context-provider.d.ts.map +1 -1
  730. package/dist/utils/composite-context-provider.js +31 -28
  731. package/dist/utils/composite-context-provider.js.map +1 -1
  732. package/dist/utils/id.d.ts +8 -5
  733. package/dist/utils/id.d.ts.map +1 -1
  734. package/dist/utils/id.js +9 -5
  735. package/dist/utils/id.js.map +1 -1
  736. package/dist/utils/json/is-json-equal.d.ts +4 -1
  737. package/dist/utils/json/is-json-equal.d.ts.map +1 -1
  738. package/dist/utils/json/is-json-equal.js +20 -25
  739. package/dist/utils/json/is-json-equal.js.map +1 -1
  740. package/dist/utils/json/is-json.d.ts +9 -5
  741. package/dist/utils/json/is-json.d.ts.map +1 -1
  742. package/dist/utils/json/is-json.js +17 -28
  743. package/dist/utils/json/is-json.js.map +1 -1
  744. package/dist/utils/text.d.ts +6 -2
  745. package/dist/utils/text.d.ts.map +1 -1
  746. package/dist/utils/text.js +6 -3
  747. package/dist/utils/text.js.map +1 -1
  748. package/package.json +12 -12
  749. package/src/index.ts +3 -0
  750. package/src/react/index.ts +17 -0
  751. package/src/react/primitives/generativeUI/GenerativeUI.tsx +182 -0
  752. package/src/react/primitives/message/MessageParts.tsx +50 -1
  753. package/src/react/runtimes/RemoteThreadListHookInstanceManager.tsx +11 -7
  754. package/src/react/runtimes/RemoteThreadListThreadListRuntimeCore.tsx +7 -2
  755. package/src/react/runtimes/cloud/auiV0.ts +1 -1
  756. package/src/react/types/MessagePartComponentTypes.ts +26 -0
  757. package/src/runtime/api/thread-list-item-runtime.ts +3 -3
  758. package/src/runtime/api/thread-list-runtime.ts +9 -3
  759. package/src/runtime/base/base-thread-runtime-core.ts +8 -0
  760. package/src/runtime/interfaces/thread-list-runtime-core.ts +4 -1
  761. package/src/runtime/interfaces/thread-runtime-core.ts +6 -5
  762. package/src/runtime/utils/thread-message-like.ts +11 -3
  763. package/src/runtimes/external-store/external-store-thread-list-runtime-core.ts +4 -1
  764. package/src/store/runtime-clients/thread-list-runtime-client.ts +2 -2
  765. package/src/store/scopes/thread-list-item.ts +1 -1
  766. package/src/store/scopes/threads.ts +1 -1
  767. package/src/tests/RemoteThreadListThreadListRuntimeCore-switchToThread-unarchive.test.ts +88 -0
  768. package/src/tests/external-store-thread-runtime-core.test.ts +83 -0
  769. package/src/types/index.ts +3 -0
  770. package/src/types/message.ts +49 -1
  771. package/dist/adapters/feedback.js.map +0 -1
  772. package/dist/adapters/index.d.ts.map +0 -1
  773. package/dist/adapters/index.js.map +0 -1
  774. package/dist/adapters/suggestion.js.map +0 -1
  775. package/dist/adapters/thread-history.js.map +0 -1
  776. package/dist/adapters/trigger.js.map +0 -1
  777. package/dist/index.d.ts.map +0 -1
  778. package/dist/index.js.map +0 -1
  779. package/dist/internal.d.ts.map +0 -1
  780. package/dist/internal.js.map +0 -1
  781. package/dist/model-context/registry-handles.js.map +0 -1
  782. package/dist/react/index.d.ts.map +0 -1
  783. package/dist/react/index.js.map +0 -1
  784. package/dist/react/model-context/toolbox.js.map +0 -1
  785. package/dist/react/types/MessagePartComponentTypes.js.map +0 -1
  786. package/dist/react/types/scopes/dataRenderers.js.map +0 -1
  787. package/dist/react/types/scopes/interactables.js.map +0 -1
  788. package/dist/react/types/scopes/tools.js.map +0 -1
  789. package/dist/react/types/store-augmentation.js.map +0 -1
  790. package/dist/runtime/api/bindings.js.map +0 -1
  791. package/dist/runtime/api/paths.js.map +0 -1
  792. package/dist/runtime/interfaces/assistant-runtime-core.js.map +0 -1
  793. package/dist/runtime/interfaces/composer-runtime-core.js.map +0 -1
  794. package/dist/runtime/interfaces/thread-list-runtime-core.js.map +0 -1
  795. package/dist/runtime/interfaces/thread-runtime-core.js.map +0 -1
  796. package/dist/runtime/internal.d.ts.map +0 -1
  797. package/dist/runtime/internal.js.map +0 -1
  798. package/dist/runtime/utils/chat-model-adapter.js.map +0 -1
  799. package/dist/runtimes/external-store/external-store-adapter.js.map +0 -1
  800. package/dist/runtimes/internal.d.ts.map +0 -1
  801. package/dist/runtimes/internal.js.map +0 -1
  802. package/dist/runtimes/local/local-runtime-options.js.map +0 -1
  803. package/dist/runtimes/remote-thread-list/types.js.map +0 -1
  804. package/dist/store/index.d.ts.map +0 -1
  805. package/dist/store/index.js.map +0 -1
  806. package/dist/store/internal.d.ts.map +0 -1
  807. package/dist/store/internal.js.map +0 -1
  808. package/dist/store/scope-registration.js.map +0 -1
  809. package/dist/store/scopes/attachment.js.map +0 -1
  810. package/dist/store/scopes/chain-of-thought.js.map +0 -1
  811. package/dist/store/scopes/composer.js.map +0 -1
  812. package/dist/store/scopes/message.js.map +0 -1
  813. package/dist/store/scopes/model-context.js.map +0 -1
  814. package/dist/store/scopes/part.js.map +0 -1
  815. package/dist/store/scopes/queue-item.js.map +0 -1
  816. package/dist/store/scopes/suggestion.js.map +0 -1
  817. package/dist/store/scopes/suggestions.js.map +0 -1
  818. package/dist/store/scopes/thread-list-item.js.map +0 -1
  819. package/dist/store/scopes/thread.js.map +0 -1
  820. package/dist/store/scopes/threads.js.map +0 -1
  821. package/dist/types/attachment.js.map +0 -1
  822. package/dist/types/directive.js.map +0 -1
  823. package/dist/types/index.d.ts.map +0 -1
  824. package/dist/types/index.js.map +0 -1
  825. package/dist/types/quote.js.map +0 -1
  826. package/dist/types/trigger.js.map +0 -1
  827. package/dist/types/unsubscribe.js.map +0 -1
@@ -1,53 +1,56 @@
1
- export class AttachmentRuntimeImpl {
2
- _core;
3
- get path() {
4
- return this._core.path;
5
- }
6
- constructor(_core) {
7
- this._core = _core;
8
- this.__internal_bindMethods();
9
- }
10
- __internal_bindMethods() {
11
- this.getState = this.getState.bind(this);
12
- this.remove = this.remove.bind(this);
13
- this.subscribe = this.subscribe.bind(this);
14
- }
15
- getState() {
16
- return this._core.getState();
17
- }
18
- subscribe(callback) {
19
- return this._core.subscribe(callback);
20
- }
21
- }
22
- class ComposerAttachmentRuntime extends AttachmentRuntimeImpl {
23
- _composerApi;
24
- constructor(core, _composerApi) {
25
- super(core);
26
- this._composerApi = _composerApi;
27
- }
28
- remove() {
29
- const core = this._composerApi.getState();
30
- if (!core)
31
- throw new Error("Composer is not available");
32
- return core.removeAttachment(this.getState().id);
33
- }
34
- }
35
- export class ThreadComposerAttachmentRuntimeImpl extends ComposerAttachmentRuntime {
36
- get source() {
37
- return "thread-composer";
38
- }
39
- }
40
- export class EditComposerAttachmentRuntimeImpl extends ComposerAttachmentRuntime {
41
- get source() {
42
- return "edit-composer";
43
- }
44
- }
45
- export class MessageAttachmentRuntimeImpl extends AttachmentRuntimeImpl {
46
- get source() {
47
- return "message";
48
- }
49
- remove() {
50
- throw new Error("Message attachments cannot be removed");
51
- }
52
- }
1
+ //#region src/runtime/api/attachment-runtime.ts
2
+ var AttachmentRuntimeImpl = class {
3
+ _core;
4
+ get path() {
5
+ return this._core.path;
6
+ }
7
+ constructor(_core) {
8
+ this._core = _core;
9
+ this.__internal_bindMethods();
10
+ }
11
+ __internal_bindMethods() {
12
+ this.getState = this.getState.bind(this);
13
+ this.remove = this.remove.bind(this);
14
+ this.subscribe = this.subscribe.bind(this);
15
+ }
16
+ getState() {
17
+ return this._core.getState();
18
+ }
19
+ subscribe(callback) {
20
+ return this._core.subscribe(callback);
21
+ }
22
+ };
23
+ var ComposerAttachmentRuntime = class extends AttachmentRuntimeImpl {
24
+ _composerApi;
25
+ constructor(core, _composerApi) {
26
+ super(core);
27
+ this._composerApi = _composerApi;
28
+ }
29
+ remove() {
30
+ const core = this._composerApi.getState();
31
+ if (!core) throw new Error("Composer is not available");
32
+ return core.removeAttachment(this.getState().id);
33
+ }
34
+ };
35
+ var ThreadComposerAttachmentRuntimeImpl = class extends ComposerAttachmentRuntime {
36
+ get source() {
37
+ return "thread-composer";
38
+ }
39
+ };
40
+ var EditComposerAttachmentRuntimeImpl = class extends ComposerAttachmentRuntime {
41
+ get source() {
42
+ return "edit-composer";
43
+ }
44
+ };
45
+ var MessageAttachmentRuntimeImpl = class extends AttachmentRuntimeImpl {
46
+ get source() {
47
+ return "message";
48
+ }
49
+ remove() {
50
+ throw new Error("Message attachments cannot be removed");
51
+ }
52
+ };
53
+ //#endregion
54
+ export { AttachmentRuntimeImpl, EditComposerAttachmentRuntimeImpl, MessageAttachmentRuntimeImpl, ThreadComposerAttachmentRuntimeImpl };
55
+
53
56
  //# sourceMappingURL=attachment-runtime.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"attachment-runtime.js","sourceRoot":"","sources":["../../../src/runtime/api/attachment-runtime.ts"],"names":[],"mappings":"AA0CA,MAAM,OAAgB,qBAAqB;IAUrB;IANpB,IAAW,IAAI;QACb,OAAO,IAAI,CAAC,KAAK,CAAC,IAAI,CAAC;IACzB,CAAC;IAID,YAAoB,KAAwC;QAAxC,UAAK,GAAL,KAAK,CAAmC;QAC1D,IAAI,CAAC,sBAAsB,EAAE,CAAC;IAChC,CAAC;IAES,sBA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,CAAC;IAC3D,CAAC;CACF"}
1
+ {"version":3,"file":"attachment-runtime.js","names":[],"sources":["../../../src/runtime/api/attachment-runtime.ts"],"sourcesContent":["import type { Attachment, CompleteAttachment } from \"../../types/attachment\";\nimport type { Unsubscribe } from \"../../types/unsubscribe\";\nimport type { SubscribableWithState } from \"../../subscribable/subscribable\";\n\nimport type { ComposerRuntimeCoreBinding } from \"./bindings\";\nimport type { AttachmentRuntimePath } from \"./paths\";\n\ntype MessageAttachmentState = CompleteAttachment & {\n readonly source: \"message\";\n};\n\ntype ThreadComposerAttachmentState = Attachment & {\n readonly source: \"thread-composer\";\n};\n\ntype EditComposerAttachmentState = Attachment & {\n readonly source: \"edit-composer\";\n};\n\nexport type AttachmentState =\n | ThreadComposerAttachmentState\n | EditComposerAttachmentState\n | MessageAttachmentState;\n\ntype AttachmentSnapshotBinding<Source extends AttachmentRuntimeSource> =\n SubscribableWithState<\n AttachmentState & { source: Source },\n AttachmentRuntimePath & { attachmentSource: Source }\n >;\n\ntype AttachmentRuntimeSource = AttachmentState[\"source\"];\n\nexport type AttachmentRuntime<\n TSource extends AttachmentRuntimeSource = AttachmentRuntimeSource,\n> = {\n readonly path: AttachmentRuntimePath & { attachmentSource: TSource };\n readonly source: TSource;\n getState(): AttachmentState & { source: TSource };\n remove(): Promise<void>;\n subscribe(callback: () => void): Unsubscribe;\n};\n\nexport abstract class AttachmentRuntimeImpl<\n Source extends AttachmentRuntimeSource = AttachmentRuntimeSource,\n> implements AttachmentRuntime\n{\n public get path() {\n return this._core.path;\n }\n\n public abstract get source(): Source;\n\n constructor(private _core: AttachmentSnapshotBinding<Source>) {\n this.__internal_bindMethods();\n }\n\n protected __internal_bindMethods() {\n this.getState = this.getState.bind(this);\n this.remove = this.remove.bind(this);\n this.subscribe = this.subscribe.bind(this);\n }\n\n public getState(): AttachmentState & { source: Source } {\n return this._core.getState();\n }\n\n public abstract remove(): Promise<void>;\n\n public subscribe(callback: () => void) {\n return this._core.subscribe(callback);\n }\n}\n\nabstract class ComposerAttachmentRuntime<\n Source extends \"thread-composer\" | \"edit-composer\",\n> extends AttachmentRuntimeImpl<Source> {\n constructor(\n core: AttachmentSnapshotBinding<Source>,\n private _composerApi: ComposerRuntimeCoreBinding,\n ) {\n super(core);\n }\n\n public remove() {\n const core = this._composerApi.getState();\n if (!core) throw new Error(\"Composer is not available\");\n return core.removeAttachment(this.getState().id);\n }\n}\n\nexport class ThreadComposerAttachmentRuntimeImpl extends ComposerAttachmentRuntime<\"thread-composer\"> {\n public get source(): \"thread-composer\" {\n return \"thread-composer\";\n }\n}\n\nexport class EditComposerAttachmentRuntimeImpl extends ComposerAttachmentRuntime<\"edit-composer\"> {\n public get source(): \"edit-composer\" {\n return \"edit-composer\";\n }\n}\n\nexport class MessageAttachmentRuntimeImpl extends AttachmentRuntimeImpl<\"message\"> {\n public get source(): \"message\" {\n return \"message\";\n }\n\n public remove(): never {\n throw new Error(\"Message attachments cannot be removed\");\n }\n}\n"],"mappings":";AA0CA,IAAsB,wBAAtB,MAGA;CAOsB;CANpB,IAAW,OAAO;EAChB,OAAO,KAAK,MAAM;CACpB;CAIA,YAAY,OAAkD;EAA1C,KAAA,QAAA;EAClB,KAAK,uBAAuB;CAC9B;CAEA,yBAAmC;EACjC,KAAK,WAAW,KAAK,SAAS,KAAK,IAAI;EACvC,KAAK,SAAS,KAAK,OAAO,KAAK,IAAI;EACnC,KAAK,YAAY,KAAK,UAAU,KAAK,IAAI;CAC3C;CAEA,WAAwD;EACtD,OAAO,KAAK,MAAM,SAAS;CAC7B;CAIA,UAAiB,UAAsB;EACrC,OAAO,KAAK,MAAM,UAAU,QAAQ;CACtC;AACF;AAEA,IAAe,4BAAf,cAEU,sBAA8B;CAG5B;CAFV,YACE,MACA,cACA;EACA,MAAM,IAAI;EAFF,KAAA,eAAA;CAGV;CAEA,SAAgB;EACd,MAAM,OAAO,KAAK,aAAa,SAAS;EACxC,IAAI,CAAC,MAAM,MAAM,IAAI,MAAM,2BAA2B;EACtD,OAAO,KAAK,iBAAiB,KAAK,SAAS,EAAE,EAAE;CACjD;AACF;AAEA,IAAa,sCAAb,cAAyD,0BAA6C;CACpG,IAAW,SAA4B;EACrC,OAAO;CACT;AACF;AAEA,IAAa,oCAAb,cAAuD,0BAA2C;CAChG,IAAW,SAA0B;EACnC,OAAO;CACT;AACF;AAEA,IAAa,+BAAb,cAAkD,sBAAiC;CACjF,IAAW,SAAoB;EAC7B,OAAO;CACT;CAEA,SAAuB;EACrB,MAAM,IAAI,MAAM,uCAAuC;CACzD;AACF"}
@@ -1,30 +1,35 @@
1
- import type { ThreadMessage } from "../../types/message.js";
2
- import type { SubscribableWithState } from "../../subscribable/subscribable.js";
3
- import type { ComposerRuntimeCore, EditComposerRuntimeCore, ThreadComposerRuntimeCore } from "../interfaces/composer-runtime-core.js";
4
- import type { SpeechState } from "../interfaces/thread-runtime-core.js";
5
- import type { ComposerRuntimePath, MessageRuntimePath } from "./paths.js";
6
- export type ComposerRuntimeCoreBinding = SubscribableWithState<ComposerRuntimeCore | undefined, ComposerRuntimePath>;
7
- export type ThreadComposerRuntimeCoreBinding = SubscribableWithState<ThreadComposerRuntimeCore | undefined, ComposerRuntimePath & {
8
- composerSource: "thread";
1
+ import { ThreadMessage } from "../../types/message.js";
2
+ import { ComposerRuntimeCore, EditComposerRuntimeCore, ThreadComposerRuntimeCore } from "../interfaces/composer-runtime-core.js";
3
+ import { SpeechState } from "../interfaces/thread-runtime-core.js";
4
+ import { ComposerRuntimePath, MessageRuntimePath } from "./paths.js";
5
+ import { ThreadListItemStatus } from "../interfaces/thread-list-runtime-core.js";
6
+ import { SubscribableWithState } from "../../subscribable/subscribable.js";
7
+
8
+ //#region src/runtime/api/bindings.d.ts
9
+ type ComposerRuntimeCoreBinding = SubscribableWithState<ComposerRuntimeCore | undefined, ComposerRuntimePath>;
10
+ type ThreadComposerRuntimeCoreBinding = SubscribableWithState<ThreadComposerRuntimeCore | undefined, ComposerRuntimePath & {
11
+ composerSource: "thread";
9
12
  }>;
10
- export type EditComposerRuntimeCoreBinding = SubscribableWithState<EditComposerRuntimeCore | undefined, ComposerRuntimePath & {
11
- composerSource: "edit";
13
+ type EditComposerRuntimeCoreBinding = SubscribableWithState<EditComposerRuntimeCore | undefined, ComposerRuntimePath & {
14
+ composerSource: "edit";
12
15
  }>;
13
- export type MessageStateBinding = SubscribableWithState<ThreadMessage & {
14
- readonly parentId: string | null;
15
- readonly index: number;
16
- readonly isLast: boolean;
17
- readonly branchNumber: number;
18
- readonly branchCount: number;
19
- readonly speech: SpeechState | undefined;
16
+ type MessageStateBinding = SubscribableWithState<ThreadMessage & {
17
+ readonly parentId: string | null;
18
+ readonly index: number;
19
+ readonly isLast: boolean;
20
+ readonly branchNumber: number;
21
+ readonly branchCount: number;
22
+ readonly speech: SpeechState | undefined;
20
23
  }, MessageRuntimePath>;
21
- export type ThreadListItemState = {
22
- readonly isMain: boolean;
23
- readonly id: string;
24
- readonly remoteId: string | undefined;
25
- readonly externalId: string | undefined;
26
- readonly status: import("../interfaces/thread-list-runtime-core").ThreadListItemStatus;
27
- readonly title?: string | undefined;
28
- readonly custom?: Record<string, unknown> | undefined;
24
+ type ThreadListItemState = {
25
+ readonly isMain: boolean;
26
+ readonly id: string;
27
+ readonly remoteId: string | undefined;
28
+ readonly externalId: string | undefined;
29
+ readonly status: ThreadListItemStatus;
30
+ readonly title?: string | undefined;
31
+ readonly custom?: Record<string, unknown> | undefined;
29
32
  };
33
+ //#endregion
34
+ export { ComposerRuntimeCoreBinding, EditComposerRuntimeCoreBinding, MessageStateBinding, ThreadComposerRuntimeCoreBinding, ThreadListItemState };
30
35
  //# sourceMappingURL=bindings.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"bindings.d.ts","sourceRoot":"","sources":["../../../src/runtime/api/bindings.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,aAAa,EAAE,+BAA4B;AACzD,OAAO,KAAK,EAAE,qBAAqB,EAAE,2CAAwC;AAC7E,OAAO,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AC,KAAK,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;IACpC,QAAQ,CAAC,MAAM,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,GAAG,SAAS,CAAC;CACvD,CAAC"}
1
+ {"version":3,"file":"bindings.d.ts","names":[],"sources":["../../../src/runtime/api/bindings.ts"],"mappings":";;;;;;;;KAUY,0BAAA,GAA6B,qBAAA,CACvC,mBAAA,cACA,mBAAA;AAAA,KAGU,gCAAA,GAAmC,qBAAA,CAC7C,yBAAA,cACA,mBAAA;EAAwB,cAAA;AAAA;AAAA,KAGd,8BAAA,GAAiC,qBAAA,CAC3C,uBAAA,cACA,mBAAA;EAAwB,cAAA;AAAA;AAAA,KAGd,mBAAA,GAAsB,qBAAA,CAChC,aAAA;EAAA,SACW,QAAA;EAAA,SACA,KAAA;EAAA,SACA,MAAA;EAAA,SACA,YAAA;EAAA,SACA,WAAA;EAAA,SACA,MAAA,EAAQ,WAAA;AAAA,GAEnB,kBAAA;AAAA,KAGU,mBAAA;EAAA,SACD,MAAA;EAAA,SACA,EAAA;EAAA,SACA,QAAA;EAAA,SACA,UAAA;EAAA,SACA,MAAA,EALoB,oBAAA;EAAA,SAMpB,KAAA;EAAA,SACA,MAAA,GAAS,MAAM;AAAA"}
@@ -1,2 +0,0 @@
1
- export {};
2
- //# sourceMappingURL=bindings.js.map
@@ -1,193 +1,195 @@
1
- import type { Attachment, CreateAttachment } from "../../types/attachment.js";
2
- import type { MessageRole } from "../../types/message.js";
3
- import type { QuoteInfo } from "../../types/quote.js";
4
- import type { Unsubscribe } from "../../types/unsubscribe.js";
5
- import type { RunConfig } from "../../types/message.js";
6
- import type { ComposerRuntimeEventCallback, ComposerRuntimeEventType, DictationState, SendOptions } from "../interfaces/composer-runtime-core.js";
7
- import type { ThreadComposerRuntimeCoreBinding, EditComposerRuntimeCoreBinding, ComposerRuntimeCoreBinding } from "./bindings.js";
8
- import type { ComposerRuntimePath } from "./paths.js";
9
- import { type AttachmentRuntime, EditComposerAttachmentRuntimeImpl, ThreadComposerAttachmentRuntimeImpl } from "./attachment-runtime.js";
10
- export type { ThreadComposerRuntimeCoreBinding, EditComposerRuntimeCoreBinding, ComposerRuntimeCoreBinding, };
1
+ import { MessageRole, RunConfig } from "../../types/message.js";
2
+ import { Attachment, CreateAttachment } from "../../types/attachment.js";
3
+ import { Unsubscribe } from "../../types/unsubscribe.js";
4
+ import { QuoteInfo } from "../../types/quote.js";
5
+ import { ComposerRuntimeEventCallback, ComposerRuntimeEventType, DictationState, SendOptions } from "../interfaces/composer-runtime-core.js";
6
+ import { ComposerRuntimePath } from "./paths.js";
7
+ import { ComposerRuntimeCoreBinding, EditComposerRuntimeCoreBinding, ThreadComposerRuntimeCoreBinding } from "./bindings.js";
8
+ import { AttachmentRuntime, EditComposerAttachmentRuntimeImpl, ThreadComposerAttachmentRuntimeImpl } from "./attachment-runtime.js";
9
+
10
+ //#region src/runtime/api/composer-runtime.d.ts
11
11
  type BaseComposerState = {
12
- readonly canCancel: boolean;
13
- readonly canSend: boolean;
14
- readonly isEditing: boolean;
15
- readonly isEmpty: boolean;
16
- readonly text: string;
17
- readonly role: MessageRole;
18
- readonly attachments: readonly Attachment[];
19
- readonly runConfig: RunConfig;
20
- readonly attachmentAccept: string;
21
- /**
22
- * The current state of dictation.
23
- * Undefined when dictation is not active.
24
- */
25
- readonly dictation: DictationState | undefined;
26
- /**
27
- * The currently quoted text, if any.
28
- * Undefined when no quote is set.
29
- */
30
- readonly quote: QuoteInfo | undefined;
12
+ readonly canCancel: boolean;
13
+ readonly canSend: boolean;
14
+ readonly isEditing: boolean;
15
+ readonly isEmpty: boolean;
16
+ readonly text: string;
17
+ readonly role: MessageRole;
18
+ readonly attachments: readonly Attachment[];
19
+ readonly runConfig: RunConfig;
20
+ readonly attachmentAccept: string;
21
+ /**
22
+ * The current state of dictation.
23
+ * Undefined when dictation is not active.
24
+ */
25
+ readonly dictation: DictationState | undefined;
26
+ /**
27
+ * The currently quoted text, if any.
28
+ * Undefined when no quote is set.
29
+ */
30
+ readonly quote: QuoteInfo | undefined;
31
31
  };
32
- export type ThreadComposerState = BaseComposerState & {
33
- readonly type: "thread";
32
+ type ThreadComposerState = BaseComposerState & {
33
+ readonly type: "thread";
34
34
  };
35
- export type EditComposerState = BaseComposerState & {
36
- readonly type: "edit";
37
- readonly parentId: string | null;
38
- readonly sourceId: string | null;
35
+ type EditComposerState = BaseComposerState & {
36
+ readonly type: "edit";
37
+ readonly parentId: string | null;
38
+ readonly sourceId: string | null;
39
39
  };
40
- export type ComposerState = ThreadComposerState | EditComposerState;
41
- export type ComposerRuntime = {
42
- readonly path: ComposerRuntimePath;
43
- readonly type: "edit" | "thread";
44
- /**
45
- * Get the current state of the composer. Includes any data that has been added to the composer.
46
- */
47
- getState(): ComposerState;
48
- /**
49
- * Add an attachment to the composer. Accepts either a standard File object
50
- * (processed through the AttachmentAdapter) or a CreateAttachment descriptor
51
- * for external-source attachments (URLs, API data, CMS references). External
52
- * descriptors bypass the adapter's `add()` step but still respect
53
- * `adapter.accept` when an adapter is configured; without an adapter they
54
- * are added as-is.
55
- * @param fileOrAttachment The file or attachment descriptor to add.
56
- */
57
- addAttachment(fileOrAttachment: File | CreateAttachment): Promise<void>;
58
- /**
59
- * Set the text of the composer.
60
- * @param text The text to set in the composer.
61
- */
62
- setText(text: string): void;
63
- /**
64
- * Set the role of the composer. For instance, if you'd like a specific message to have the 'assistant' role, you can do so here.
65
- * @param role The role to set in the composer.
66
- */
67
- setRole(role: MessageRole): void;
68
- /**
69
- * Set the run config of the composer. This is used to send custom configuration data to the model.
70
- * Within your backend, you can use the `runConfig` object.
71
- * Example:
72
- * ```ts
73
- * composerRuntime.setRunConfig({
74
- * custom: { customField: "customValue" }
75
- * });
76
- * ```
77
- * @param runConfig The run config to set in the composer.
78
- */
79
- setRunConfig(runConfig: RunConfig): void;
80
- /**
81
- * Reset the composer. This will clear the entire state of the composer, including all text and attachments.
82
- */
83
- reset(): Promise<void>;
84
- /**
85
- * Clear all attachments from the composer.
86
- */
87
- clearAttachments(): Promise<void>;
88
- /**
89
- * Send a message. This will send whatever text or attachments are in the composer.
90
- * @param options Optional send options. Use `{ startRun: true }` to force starting a new run.
91
- */
92
- send(options?: SendOptions): void;
93
- /**
94
- * Cancel the current run. In edit mode, this will exit edit mode.
95
- */
96
- cancel(): void;
97
- /**
98
- * Listens for changes to the composer state.
99
- * @param callback The callback to call when the composer state changes.
100
- */
101
- subscribe(callback: () => void): Unsubscribe;
102
- /**
103
- * Get an attachment by index.
104
- * @param idx The index of the attachment to get.
105
- */
106
- getAttachmentByIndex(idx: number): AttachmentRuntime;
107
- /**
108
- * Start dictation to convert voice to text input.
109
- * Requires a DictationAdapter to be configured.
110
- */
111
- startDictation(): void;
112
- /**
113
- * Stop the current dictation session.
114
- */
115
- stopDictation(): void;
116
- /**
117
- * Set a quote for the next message. Pass undefined to clear.
118
- * @param quote The quote info to set, or undefined to clear.
119
- */
120
- setQuote(quote: QuoteInfo | undefined): void;
121
- /**
122
- * @deprecated This API is still under active development and might change without notice.
123
- */
124
- unstable_on<E extends ComposerRuntimeEventType>(event: E, callback: ComposerRuntimeEventCallback<E>): Unsubscribe;
40
+ type ComposerState = ThreadComposerState | EditComposerState;
41
+ type ComposerRuntime = {
42
+ readonly path: ComposerRuntimePath;
43
+ readonly type: "edit" | "thread";
44
+ /**
45
+ * Get the current state of the composer. Includes any data that has been added to the composer.
46
+ */
47
+ getState(): ComposerState;
48
+ /**
49
+ * Add an attachment to the composer. Accepts either a standard File object
50
+ * (processed through the AttachmentAdapter) or a CreateAttachment descriptor
51
+ * for external-source attachments (URLs, API data, CMS references). External
52
+ * descriptors bypass the adapter's `add()` step but still respect
53
+ * `adapter.accept` when an adapter is configured; without an adapter they
54
+ * are added as-is.
55
+ * @param fileOrAttachment The file or attachment descriptor to add.
56
+ */
57
+ addAttachment(fileOrAttachment: File | CreateAttachment): Promise<void>;
58
+ /**
59
+ * Set the text of the composer.
60
+ * @param text The text to set in the composer.
61
+ */
62
+ setText(text: string): void;
63
+ /**
64
+ * Set the role of the composer. For instance, if you'd like a specific message to have the 'assistant' role, you can do so here.
65
+ * @param role The role to set in the composer.
66
+ */
67
+ setRole(role: MessageRole): void;
68
+ /**
69
+ * Set the run config of the composer. This is used to send custom configuration data to the model.
70
+ * Within your backend, you can use the `runConfig` object.
71
+ * Example:
72
+ * ```ts
73
+ * composerRuntime.setRunConfig({
74
+ * custom: { customField: "customValue" }
75
+ * });
76
+ * ```
77
+ * @param runConfig The run config to set in the composer.
78
+ */
79
+ setRunConfig(runConfig: RunConfig): void;
80
+ /**
81
+ * Reset the composer. This will clear the entire state of the composer, including all text and attachments.
82
+ */
83
+ reset(): Promise<void>;
84
+ /**
85
+ * Clear all attachments from the composer.
86
+ */
87
+ clearAttachments(): Promise<void>;
88
+ /**
89
+ * Send a message. This will send whatever text or attachments are in the composer.
90
+ * @param options Optional send options. Use `{ startRun: true }` to force starting a new run.
91
+ */
92
+ send(options?: SendOptions): void;
93
+ /**
94
+ * Cancel the current run. In edit mode, this will exit edit mode.
95
+ */
96
+ cancel(): void;
97
+ /**
98
+ * Listens for changes to the composer state.
99
+ * @param callback The callback to call when the composer state changes.
100
+ */
101
+ subscribe(callback: () => void): Unsubscribe;
102
+ /**
103
+ * Get an attachment by index.
104
+ * @param idx The index of the attachment to get.
105
+ */
106
+ getAttachmentByIndex(idx: number): AttachmentRuntime;
107
+ /**
108
+ * Start dictation to convert voice to text input.
109
+ * Requires a DictationAdapter to be configured.
110
+ */
111
+ startDictation(): void;
112
+ /**
113
+ * Stop the current dictation session.
114
+ */
115
+ stopDictation(): void;
116
+ /**
117
+ * Set a quote for the next message. Pass undefined to clear.
118
+ * @param quote The quote info to set, or undefined to clear.
119
+ */
120
+ setQuote(quote: QuoteInfo | undefined): void;
121
+ /**
122
+ * @deprecated This API is still under active development and might change without notice.
123
+ */
124
+ unstable_on<E extends ComposerRuntimeEventType>(event: E, callback: ComposerRuntimeEventCallback<E>): Unsubscribe;
125
125
  };
126
- export declare abstract class ComposerRuntimeImpl implements ComposerRuntime {
127
- protected _core: ComposerRuntimeCoreBinding;
128
- get path(): ComposerRuntimePath;
129
- abstract get type(): "edit" | "thread";
130
- constructor(_core: ComposerRuntimeCoreBinding);
131
- protected __internal_bindMethods(): void;
132
- abstract getState(): ComposerState;
133
- setText(text: string): void;
134
- setRunConfig(runConfig: RunConfig): void;
135
- addAttachment(fileOrAttachment: File | CreateAttachment): Promise<void>;
136
- reset(): Promise<void>;
137
- clearAttachments(): Promise<void>;
138
- send(options?: SendOptions): void;
139
- cancel(): void;
140
- setRole(role: MessageRole): void;
141
- startDictation(): void;
142
- stopDictation(): void;
143
- setQuote(quote: QuoteInfo | undefined): void;
144
- subscribe(callback: () => void): Unsubscribe;
145
- private _eventSubscriptionSubjects;
146
- unstable_on<E extends ComposerRuntimeEventType>(event: E, callback: ComposerRuntimeEventCallback<E>): Unsubscribe;
147
- abstract getAttachmentByIndex(idx: number): AttachmentRuntime;
126
+ declare abstract class ComposerRuntimeImpl implements ComposerRuntime {
127
+ protected _core: ComposerRuntimeCoreBinding;
128
+ get path(): ComposerRuntimePath;
129
+ abstract get type(): "edit" | "thread";
130
+ constructor(_core: ComposerRuntimeCoreBinding);
131
+ protected __internal_bindMethods(): void;
132
+ abstract getState(): ComposerState;
133
+ setText(text: string): void;
134
+ setRunConfig(runConfig: RunConfig): void;
135
+ addAttachment(fileOrAttachment: File | CreateAttachment): Promise<void>;
136
+ reset(): Promise<void>;
137
+ clearAttachments(): Promise<void>;
138
+ send(options?: SendOptions): void;
139
+ cancel(): void;
140
+ setRole(role: MessageRole): void;
141
+ startDictation(): void;
142
+ stopDictation(): void;
143
+ setQuote(quote: QuoteInfo | undefined): void;
144
+ subscribe(callback: () => void): Unsubscribe;
145
+ private _eventSubscriptionSubjects;
146
+ unstable_on<E extends ComposerRuntimeEventType>(event: E, callback: ComposerRuntimeEventCallback<E>): Unsubscribe;
147
+ abstract getAttachmentByIndex(idx: number): AttachmentRuntime;
148
148
  }
149
- export type ThreadComposerRuntime = Omit<ComposerRuntime, "getState" | "getAttachmentByIndex"> & {
150
- readonly path: ComposerRuntimePath & {
151
- composerSource: "thread";
152
- };
153
- readonly type: "thread";
154
- getState(): ThreadComposerState;
155
- getAttachmentByIndex(idx: number): AttachmentRuntime & {
156
- source: "thread-composer";
157
- };
149
+ type ThreadComposerRuntime = Omit<ComposerRuntime, "getState" | "getAttachmentByIndex"> & {
150
+ readonly path: ComposerRuntimePath & {
151
+ composerSource: "thread";
152
+ };
153
+ readonly type: "thread";
154
+ getState(): ThreadComposerState;
155
+ getAttachmentByIndex(idx: number): AttachmentRuntime & {
156
+ source: "thread-composer";
157
+ };
158
158
  };
159
- export declare class ThreadComposerRuntimeImpl extends ComposerRuntimeImpl implements ThreadComposerRuntime {
160
- get path(): ComposerRuntimePath & {
161
- composerSource: "thread";
162
- };
163
- get type(): "thread";
164
- private _getState;
165
- constructor(core: ThreadComposerRuntimeCoreBinding);
166
- getState(): ThreadComposerState;
167
- getAttachmentByIndex(idx: number): ThreadComposerAttachmentRuntimeImpl;
159
+ declare class ThreadComposerRuntimeImpl extends ComposerRuntimeImpl implements ThreadComposerRuntime {
160
+ get path(): ComposerRuntimePath & {
161
+ composerSource: "thread";
162
+ };
163
+ get type(): "thread";
164
+ private _getState;
165
+ constructor(core: ThreadComposerRuntimeCoreBinding);
166
+ getState(): ThreadComposerState;
167
+ getAttachmentByIndex(idx: number): ThreadComposerAttachmentRuntimeImpl;
168
168
  }
169
- export type EditComposerRuntime = Omit<ComposerRuntime, "getState" | "getAttachmentByIndex"> & {
170
- readonly path: ComposerRuntimePath & {
171
- composerSource: "edit";
172
- };
173
- readonly type: "edit";
174
- getState(): EditComposerState;
175
- beginEdit(): void;
176
- getAttachmentByIndex(idx: number): AttachmentRuntime & {
177
- source: "edit-composer";
178
- };
169
+ type EditComposerRuntime = Omit<ComposerRuntime, "getState" | "getAttachmentByIndex"> & {
170
+ readonly path: ComposerRuntimePath & {
171
+ composerSource: "edit";
172
+ };
173
+ readonly type: "edit";
174
+ getState(): EditComposerState;
175
+ beginEdit(): void;
176
+ getAttachmentByIndex(idx: number): AttachmentRuntime & {
177
+ source: "edit-composer";
178
+ };
179
179
  };
180
- export declare class EditComposerRuntimeImpl extends ComposerRuntimeImpl implements EditComposerRuntime {
181
- private _beginEdit;
182
- get path(): ComposerRuntimePath & {
183
- composerSource: "edit";
184
- };
185
- get type(): "edit";
186
- private _getState;
187
- constructor(core: EditComposerRuntimeCoreBinding, _beginEdit: () => void);
188
- __internal_bindMethods(): void;
189
- getState(): EditComposerState;
190
- beginEdit(): void;
191
- getAttachmentByIndex(idx: number): EditComposerAttachmentRuntimeImpl;
180
+ declare class EditComposerRuntimeImpl extends ComposerRuntimeImpl implements EditComposerRuntime {
181
+ private _beginEdit;
182
+ get path(): ComposerRuntimePath & {
183
+ composerSource: "edit";
184
+ };
185
+ get type(): "edit";
186
+ private _getState;
187
+ constructor(core: EditComposerRuntimeCoreBinding, _beginEdit: () => void);
188
+ __internal_bindMethods(): void;
189
+ getState(): EditComposerState;
190
+ beginEdit(): void;
191
+ getAttachmentByIndex(idx: number): EditComposerAttachmentRuntimeImpl;
192
192
  }
193
+ //#endregion
194
+ export { ComposerRuntime, type ComposerRuntimeCoreBinding, ComposerRuntimeImpl, ComposerState, EditComposerRuntime, type EditComposerRuntimeCoreBinding, EditComposerRuntimeImpl, EditComposerState, ThreadComposerRuntime, type ThreadComposerRuntimeCoreBinding, ThreadComposerRuntimeImpl, ThreadComposerState };
193
195
  //# sourceMappingURL=composer-runtime.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"composer-runtime.d.ts","sourceRoot":"","sources":["../../../src/runtime/api/composer-runtime.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,UAAU,EAAE,gBAAgB,EAAE,kCAA+B;AAC3E,OAAO,KAAK,EAAE,WAAW,EAAE,+BAA4B;AACvD,OAAO,KAAK,EAAE,SAAS,EA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