@dxos/plugin-assistant 0.8.4-main.7ace549 → 0.8.4-main.8baae0fced

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 (811) hide show
  1. package/LICENSE +102 -5
  2. package/README.md +1 -1
  3. package/dist/lib/neutral/AgentArticle-ZHWYIH64.mjs +166 -0
  4. package/dist/lib/neutral/AgentArticle-ZHWYIH64.mjs.map +7 -0
  5. package/dist/lib/neutral/AgentProperties-W6LD56IB.mjs +40 -0
  6. package/dist/lib/neutral/AgentProperties-W6LD56IB.mjs.map +7 -0
  7. package/dist/lib/neutral/AssistantPlugin.mjs +10 -0
  8. package/dist/lib/neutral/AssistantPlugin.node.mjs +59 -0
  9. package/dist/lib/neutral/AssistantPlugin.node.mjs.map +7 -0
  10. package/dist/lib/neutral/AssistantPlugin.workerd.mjs +40 -0
  11. package/dist/lib/neutral/AssistantPlugin.workerd.mjs.map +7 -0
  12. package/dist/lib/neutral/AssistantSettings-GG52BLKS.mjs +40 -0
  13. package/dist/lib/neutral/AssistantSettings-GG52BLKS.mjs.map +7 -0
  14. package/dist/lib/neutral/BlueprintArticle-U7LUBFOS.mjs +27 -0
  15. package/dist/lib/neutral/BlueprintArticle-U7LUBFOS.mjs.map +7 -0
  16. package/dist/lib/neutral/ChatArticle-WVAFZPVI.mjs +8 -0
  17. package/dist/lib/neutral/ChatCompanion-DFRMRUK3.mjs +133 -0
  18. package/dist/lib/neutral/ChatCompanion-DFRMRUK3.mjs.map +7 -0
  19. package/dist/lib/neutral/ChatDialog-QKZLG7SQ.mjs +72 -0
  20. package/dist/lib/neutral/ChatDialog-QKZLG7SQ.mjs.map +7 -0
  21. package/dist/lib/neutral/PlanArticle-TS5ULWYS.mjs +28 -0
  22. package/dist/lib/neutral/PlanArticle-TS5ULWYS.mjs.map +7 -0
  23. package/dist/lib/neutral/RoutineArticle-EZKJR3KV.mjs +119 -0
  24. package/dist/lib/neutral/RoutineArticle-EZKJR3KV.mjs.map +7 -0
  25. package/dist/lib/neutral/RoutineList-CLDXGQUD.mjs +48 -0
  26. package/dist/lib/neutral/RoutineList-CLDXGQUD.mjs.map +7 -0
  27. package/dist/lib/neutral/RoutineProperties-FISLMW2R.mjs +17 -0
  28. package/dist/lib/neutral/RoutineProperties-FISLMW2R.mjs.map +7 -0
  29. package/dist/lib/neutral/TracePanel-STGKU65N.mjs +125 -0
  30. package/dist/lib/neutral/TracePanel-STGKU65N.mjs.map +7 -0
  31. package/dist/lib/neutral/TriggerStatus-WTFYUIG5.mjs +92 -0
  32. package/dist/lib/neutral/TriggerStatus-WTFYUIG5.mjs.map +7 -0
  33. package/dist/lib/neutral/ai-service-7SQH5S4F.mjs +34 -0
  34. package/dist/lib/neutral/ai-service-7SQH5S4F.mjs.map +7 -0
  35. package/dist/lib/neutral/app-graph-builder-B6FDKG57.mjs +199 -0
  36. package/dist/lib/neutral/app-graph-builder-B6FDKG57.mjs.map +7 -0
  37. package/dist/lib/neutral/blueprint-definition-VXJYQ5AE.mjs +32 -0
  38. package/dist/lib/neutral/blueprint-definition-VXJYQ5AE.mjs.map +7 -0
  39. package/dist/lib/neutral/blueprints/index.mjs +8 -0
  40. package/dist/lib/neutral/capabilities/index.mjs +35 -0
  41. package/dist/lib/neutral/capabilities/index.mjs.map +7 -0
  42. package/dist/lib/{browser/chunk-WBG5PTSX.mjs → neutral/chunk-4IXVWSOO.mjs} +9 -9
  43. package/dist/lib/neutral/chunk-4IXVWSOO.mjs.map +7 -0
  44. package/dist/lib/neutral/chunk-5AZPD56S.mjs +8 -0
  45. package/dist/lib/neutral/chunk-5AZPD56S.mjs.map +7 -0
  46. package/dist/lib/neutral/chunk-5H6UJHLF.mjs +30 -0
  47. package/dist/lib/neutral/chunk-5H6UJHLF.mjs.map +7 -0
  48. package/dist/lib/neutral/chunk-IZQWGJNG.mjs +380 -0
  49. package/dist/lib/neutral/chunk-IZQWGJNG.mjs.map +7 -0
  50. package/dist/lib/neutral/chunk-OWFOSXKR.mjs +98 -0
  51. package/dist/lib/neutral/chunk-OWFOSXKR.mjs.map +7 -0
  52. package/dist/lib/neutral/chunk-SLIPV6NN.mjs +106 -0
  53. package/dist/lib/neutral/chunk-SLIPV6NN.mjs.map +7 -0
  54. package/dist/lib/neutral/companion-chat-provisioner-2Y6PRSDK.mjs +116 -0
  55. package/dist/lib/neutral/companion-chat-provisioner-2Y6PRSDK.mjs.map +7 -0
  56. package/dist/lib/neutral/components/index.mjs +2371 -0
  57. package/dist/lib/neutral/components/index.mjs.map +7 -0
  58. package/dist/lib/neutral/containers/index.mjs +29 -0
  59. package/dist/lib/neutral/containers/index.mjs.map +7 -0
  60. package/dist/lib/neutral/create-chat-QQZURUBW.mjs +71 -0
  61. package/dist/lib/neutral/create-chat-QQZURUBW.mjs.map +7 -0
  62. package/dist/lib/neutral/create-object-RVJO3ZP6.mjs +90 -0
  63. package/dist/lib/neutral/create-object-RVJO3ZP6.mjs.map +7 -0
  64. package/dist/lib/neutral/edge-model-resolver-XDNBZ3US.mjs +21 -0
  65. package/dist/lib/neutral/edge-model-resolver-XDNBZ3US.mjs.map +7 -0
  66. package/dist/lib/neutral/ensure-companion-chat-5S4LZM2H.mjs +58 -0
  67. package/dist/lib/neutral/ensure-companion-chat-5S4LZM2H.mjs.map +7 -0
  68. package/dist/lib/neutral/execution-graph/index.mjs +658 -0
  69. package/dist/lib/neutral/execution-graph/index.mjs.map +7 -0
  70. package/dist/lib/neutral/hooks/index.mjs +938 -0
  71. package/dist/lib/neutral/hooks/index.mjs.map +7 -0
  72. package/dist/lib/neutral/index.mjs +32 -0
  73. package/dist/lib/neutral/local-model-resolver-I2BENFFS.mjs +24 -0
  74. package/dist/lib/neutral/local-model-resolver-I2BENFFS.mjs.map +7 -0
  75. package/dist/lib/neutral/markdown-KTBFOMFM.mjs +110 -0
  76. package/dist/lib/neutral/markdown-KTBFOMFM.mjs.map +7 -0
  77. package/dist/lib/neutral/meta.json +1 -0
  78. package/dist/lib/neutral/meta.mjs +12 -0
  79. package/dist/lib/neutral/migrations-7DEMVBOG.mjs +28 -0
  80. package/dist/lib/neutral/migrations-7DEMVBOG.mjs.map +7 -0
  81. package/dist/lib/neutral/on-create-space-Q2R7OSP6.mjs +19 -0
  82. package/dist/lib/neutral/on-create-space-Q2R7OSP6.mjs.map +7 -0
  83. package/dist/lib/neutral/operation-handler-SF36MOB5.mjs +13 -0
  84. package/dist/lib/neutral/operation-handler-SF36MOB5.mjs.map +7 -0
  85. package/dist/lib/neutral/operations/index.mjs +8 -0
  86. package/dist/lib/neutral/operations/index.mjs.map +7 -0
  87. package/dist/lib/neutral/plugin.mjs +16 -0
  88. package/dist/lib/neutral/plugin.mjs.map +7 -0
  89. package/dist/lib/neutral/react-surface-T4R65UJU.mjs +174 -0
  90. package/dist/lib/neutral/react-surface-T4R65UJU.mjs.map +7 -0
  91. package/dist/lib/neutral/resolve-navigation-targets-VXBSWV5L.mjs +20 -0
  92. package/dist/lib/neutral/resolve-navigation-targets-VXBSWV5L.mjs.map +7 -0
  93. package/dist/lib/neutral/run-prompt-in-new-chat-KPXN5YJ2.mjs +102 -0
  94. package/dist/lib/neutral/run-prompt-in-new-chat-KPXN5YJ2.mjs.map +7 -0
  95. package/dist/lib/neutral/set-current-chat-ZFDCYK5I.mjs +48 -0
  96. package/dist/lib/neutral/set-current-chat-ZFDCYK5I.mjs.map +7 -0
  97. package/dist/lib/neutral/settings-W4BLWQ53.mjs +28 -0
  98. package/dist/lib/neutral/settings-W4BLWQ53.mjs.map +7 -0
  99. package/dist/lib/neutral/state-H3G7QCU6.mjs +28 -0
  100. package/dist/lib/neutral/state-H3G7QCU6.mjs.map +7 -0
  101. package/dist/lib/neutral/testing.mjs +8 -0
  102. package/dist/lib/neutral/testing.mjs.map +7 -0
  103. package/dist/lib/neutral/toggle-trace-panel-debug-JGTB6KVJ.mjs +21 -0
  104. package/dist/lib/neutral/toggle-trace-panel-debug-JGTB6KVJ.mjs.map +7 -0
  105. package/dist/lib/neutral/toolkit-GVWXPDLJ.mjs +14 -0
  106. package/dist/lib/neutral/toolkit-GVWXPDLJ.mjs.map +7 -0
  107. package/dist/lib/neutral/translations.mjs +175 -0
  108. package/dist/lib/neutral/translations.mjs.map +7 -0
  109. package/dist/lib/neutral/types/index.mjs +20 -0
  110. package/dist/lib/neutral/types/index.mjs.map +7 -0
  111. package/dist/lib/neutral/update-chat-name-ENXRUMDJ.mjs +54 -0
  112. package/dist/lib/neutral/update-chat-name-ENXRUMDJ.mjs.map +7 -0
  113. package/dist/types/src/AssistantPlugin.d.ts +3 -1
  114. package/dist/types/src/AssistantPlugin.d.ts.map +1 -1
  115. package/dist/types/src/AssistantPlugin.node.d.ts +4 -0
  116. package/dist/types/src/AssistantPlugin.node.d.ts.map +1 -0
  117. package/dist/types/src/AssistantPlugin.test.d.ts +2 -0
  118. package/dist/types/src/AssistantPlugin.test.d.ts.map +1 -0
  119. package/dist/types/src/AssistantPlugin.workerd.d.ts +4 -0
  120. package/dist/types/src/AssistantPlugin.workerd.d.ts.map +1 -0
  121. package/dist/types/src/blueprints/assistant/blueprint.d.ts +4 -0
  122. package/dist/types/src/blueprints/assistant/blueprint.d.ts.map +1 -0
  123. package/dist/types/src/blueprints/assistant/blueprint.node.test.d.ts +2 -0
  124. package/dist/types/src/blueprints/assistant/blueprint.node.test.d.ts.map +1 -0
  125. package/dist/types/src/blueprints/assistant/index.d.ts +2 -0
  126. package/dist/types/src/blueprints/assistant/index.d.ts.map +1 -0
  127. package/dist/types/src/blueprints/index.d.ts +2 -0
  128. package/dist/types/src/blueprints/index.d.ts.map +1 -0
  129. package/dist/types/src/capabilities/ai-service.d.ts +5 -2
  130. package/dist/types/src/capabilities/ai-service.d.ts.map +1 -1
  131. package/dist/types/src/capabilities/app-graph-builder.d.ts +4 -2
  132. package/dist/types/src/capabilities/app-graph-builder.d.ts.map +1 -1
  133. package/dist/types/src/capabilities/blueprint-definition.d.ts +4 -6
  134. package/dist/types/src/capabilities/blueprint-definition.d.ts.map +1 -1
  135. package/dist/types/src/capabilities/companion-chat-provisioner.d.ts +9 -0
  136. package/dist/types/src/capabilities/companion-chat-provisioner.d.ts.map +1 -0
  137. package/dist/types/src/capabilities/create-object.d.ts +31 -0
  138. package/dist/types/src/capabilities/create-object.d.ts.map +1 -0
  139. package/dist/types/src/capabilities/edge-model-resolver.d.ts +6 -3
  140. package/dist/types/src/capabilities/edge-model-resolver.d.ts.map +1 -1
  141. package/dist/types/src/capabilities/index.d.ts +55 -13
  142. package/dist/types/src/capabilities/index.d.ts.map +1 -1
  143. package/dist/types/src/capabilities/local-model-resolver.d.ts +9 -3
  144. package/dist/types/src/capabilities/local-model-resolver.d.ts.map +1 -1
  145. package/dist/types/src/capabilities/markdown.d.ts +5 -0
  146. package/dist/types/src/capabilities/markdown.d.ts.map +1 -0
  147. package/dist/types/src/capabilities/migrations.d.ts +6 -0
  148. package/dist/types/src/capabilities/migrations.d.ts.map +1 -0
  149. package/dist/types/src/capabilities/operation-handler.d.ts +6 -0
  150. package/dist/types/src/capabilities/operation-handler.d.ts.map +1 -0
  151. package/dist/types/src/capabilities/react-surface.d.ts +3 -2
  152. package/dist/types/src/capabilities/react-surface.d.ts.map +1 -1
  153. package/dist/types/src/capabilities/settings.d.ts +4 -2
  154. package/dist/types/src/capabilities/settings.d.ts.map +1 -1
  155. package/dist/types/src/capabilities/state.d.ts +19 -2
  156. package/dist/types/src/capabilities/state.d.ts.map +1 -1
  157. package/dist/types/src/capabilities/toolkit.d.ts +4 -2
  158. package/dist/types/src/capabilities/toolkit.d.ts.map +1 -1
  159. package/dist/types/src/components/AgentProperties/AgentProperties.d.ts +7 -0
  160. package/dist/types/src/components/AgentProperties/AgentProperties.d.ts.map +1 -0
  161. package/dist/types/src/components/AgentProperties/AgentProperties.stories.d.ts +15 -0
  162. package/dist/types/src/components/AgentProperties/AgentProperties.stories.d.ts.map +1 -0
  163. package/dist/types/src/components/AgentProperties/index.d.ts +2 -0
  164. package/dist/types/src/components/AgentProperties/index.d.ts.map +1 -0
  165. package/dist/types/src/components/AssistantSettings/AssistantSettings.d.ts +4 -4
  166. package/dist/types/src/components/AssistantSettings/AssistantSettings.d.ts.map +1 -1
  167. package/dist/types/src/components/AssistantSettings/AssistantSettings.stories.d.ts +15 -0
  168. package/dist/types/src/components/AssistantSettings/AssistantSettings.stories.d.ts.map +1 -0
  169. package/dist/types/src/components/AssistantSettings/index.d.ts +1 -1
  170. package/dist/types/src/components/AssistantSettings/index.d.ts.map +1 -1
  171. package/dist/types/src/components/Chat/Chat.d.ts +42 -43
  172. package/dist/types/src/components/Chat/Chat.d.ts.map +1 -1
  173. package/dist/types/src/components/Chat/context.d.ts +29 -0
  174. package/dist/types/src/components/Chat/context.d.ts.map +1 -0
  175. package/dist/types/src/components/Chat/events.d.ts +1 -1
  176. package/dist/types/src/components/Chat/events.d.ts.map +1 -1
  177. package/dist/types/src/components/ChatPrompt/ChatActions.d.ts +2 -1
  178. package/dist/types/src/components/ChatPrompt/ChatActions.d.ts.map +1 -1
  179. package/dist/types/src/components/ChatPrompt/ChatMcpErrors.d.ts +12 -0
  180. package/dist/types/src/components/ChatPrompt/ChatMcpErrors.d.ts.map +1 -0
  181. package/dist/types/src/components/ChatPrompt/ChatOptions.d.ts +10 -6
  182. package/dist/types/src/components/ChatPrompt/ChatOptions.d.ts.map +1 -1
  183. package/dist/types/src/components/ChatPrompt/ChatOptions.stories.d.ts +19 -0
  184. package/dist/types/src/components/ChatPrompt/ChatOptions.stories.d.ts.map +1 -0
  185. package/dist/types/src/components/ChatPrompt/ChatPresets.d.ts.map +1 -1
  186. package/dist/types/src/components/ChatPrompt/ChatPrompt.d.ts +28 -0
  187. package/dist/types/src/components/ChatPrompt/ChatPrompt.d.ts.map +1 -0
  188. package/dist/types/src/components/ChatPrompt/ChatReferences.d.ts +5 -5
  189. package/dist/types/src/components/ChatPrompt/ChatReferences.d.ts.map +1 -1
  190. package/dist/types/src/components/ChatPrompt/ChatStatus.d.ts +20 -0
  191. package/dist/types/src/components/ChatPrompt/ChatStatus.d.ts.map +1 -0
  192. package/dist/types/src/components/ChatPrompt/ChatStatusIndicator.d.ts.map +1 -1
  193. package/dist/types/src/components/ChatPrompt/index.d.ts +3 -0
  194. package/dist/types/src/components/ChatPrompt/index.d.ts.map +1 -1
  195. package/dist/types/src/components/ChatThread/Anchor.stories.d.ts +14 -0
  196. package/dist/types/src/components/ChatThread/Anchor.stories.d.ts.map +1 -0
  197. package/dist/types/src/components/ChatThread/ChatThread.d.ts +8 -5
  198. package/dist/types/src/components/ChatThread/ChatThread.d.ts.map +1 -1
  199. package/dist/types/src/components/ChatThread/ChatThread.stories.d.ts +11 -316
  200. package/dist/types/src/components/ChatThread/ChatThread.stories.d.ts.map +1 -1
  201. package/dist/types/src/components/ChatThread/Link.d.ts.map +1 -1
  202. package/dist/types/src/components/ChatThread/MarkdownStream.stories.d.ts +42 -0
  203. package/dist/types/src/components/ChatThread/MarkdownStream.stories.d.ts.map +1 -0
  204. package/dist/types/src/components/ChatThread/registry.d.ts +19 -1
  205. package/dist/types/src/components/ChatThread/registry.d.ts.map +1 -1
  206. package/dist/types/src/components/ChatThread/sync.d.ts +45 -18
  207. package/dist/types/src/components/ChatThread/sync.d.ts.map +1 -1
  208. package/dist/types/src/components/ChatThread/tool-widget-state.d.ts +18 -0
  209. package/dist/types/src/components/ChatThread/tool-widget-state.d.ts.map +1 -0
  210. package/dist/types/src/components/ChatThread/tool-widget-state.test.d.ts +2 -0
  211. package/dist/types/src/components/ChatThread/tool-widget-state.test.d.ts.map +1 -0
  212. package/dist/types/src/components/ChatThread/widgets/FallbackWidget.d.ts +8 -0
  213. package/dist/types/src/components/ChatThread/widgets/FallbackWidget.d.ts.map +1 -0
  214. package/dist/types/src/components/ChatThread/widgets/ReasoningWidget.d.ts +25 -0
  215. package/dist/types/src/components/ChatThread/widgets/ReasoningWidget.d.ts.map +1 -0
  216. package/dist/types/src/components/ChatThread/widgets/ReasoningWidget.stories.d.ts +18 -0
  217. package/dist/types/src/components/ChatThread/widgets/ReasoningWidget.stories.d.ts.map +1 -0
  218. package/dist/types/src/components/ChatThread/widgets/ReferenceWidget.d.ts +9 -0
  219. package/dist/types/src/components/ChatThread/widgets/ReferenceWidget.d.ts.map +1 -0
  220. package/dist/types/src/components/ChatThread/widgets/SelectWidget.d.ts +14 -0
  221. package/dist/types/src/components/ChatThread/widgets/SelectWidget.d.ts.map +1 -0
  222. package/dist/types/src/components/ChatThread/widgets/StatsWidget.d.ts +12 -0
  223. package/dist/types/src/components/ChatThread/widgets/StatsWidget.d.ts.map +1 -0
  224. package/dist/types/src/components/ChatThread/widgets/StatusWidget.d.ts +12 -0
  225. package/dist/types/src/components/ChatThread/widgets/StatusWidget.d.ts.map +1 -0
  226. package/dist/types/src/components/ChatThread/widgets/SuggestionWidget.d.ts +11 -0
  227. package/dist/types/src/components/ChatThread/widgets/SuggestionWidget.d.ts.map +1 -0
  228. package/dist/types/src/components/ChatThread/widgets/SummaryWidget.d.ts +5 -0
  229. package/dist/types/src/components/ChatThread/widgets/SummaryWidget.d.ts.map +1 -0
  230. package/dist/types/src/components/ChatThread/widgets/ToolWidget.d.ts +9 -0
  231. package/dist/types/src/components/ChatThread/widgets/ToolWidget.d.ts.map +1 -0
  232. package/dist/types/src/components/ChatThread/widgets/ToolWidget.stories.d.ts +15 -0
  233. package/dist/types/src/components/ChatThread/widgets/ToolWidget.stories.d.ts.map +1 -0
  234. package/dist/types/src/components/ChatThread/widgets/defaults.d.ts +5 -0
  235. package/dist/types/src/components/ChatThread/widgets/defaults.d.ts.map +1 -0
  236. package/dist/types/src/components/ChatThread/widgets/index.d.ts +10 -0
  237. package/dist/types/src/components/ChatThread/widgets/index.d.ts.map +1 -0
  238. package/dist/types/src/components/ProcessTree/ProcessTree.d.ts +11 -0
  239. package/dist/types/src/components/ProcessTree/ProcessTree.d.ts.map +1 -0
  240. package/dist/types/src/components/ProcessTree/ProcessTree.stories.d.ts +7 -0
  241. package/dist/types/src/components/ProcessTree/ProcessTree.stories.d.ts.map +1 -0
  242. package/dist/types/src/components/ProcessTree/index.d.ts +2 -0
  243. package/dist/types/src/components/ProcessTree/index.d.ts.map +1 -0
  244. package/dist/types/src/components/RoutineProperties/RoutineProperties.d.ts +7 -0
  245. package/dist/types/src/components/RoutineProperties/RoutineProperties.d.ts.map +1 -0
  246. package/dist/types/src/components/RoutineProperties/RoutineProperties.stories.d.ts +15 -0
  247. package/dist/types/src/components/RoutineProperties/RoutineProperties.stories.d.ts.map +1 -0
  248. package/dist/types/src/components/RoutineProperties/index.d.ts +2 -0
  249. package/dist/types/src/components/RoutineProperties/index.d.ts.map +1 -0
  250. package/dist/types/src/components/TaskList/TaskList.d.ts +10 -0
  251. package/dist/types/src/components/TaskList/TaskList.d.ts.map +1 -0
  252. package/dist/types/src/components/TaskList/TaskList.stories.d.ts +16 -0
  253. package/dist/types/src/components/TaskList/TaskList.stories.d.ts.map +1 -0
  254. package/dist/types/src/components/TaskList/index.d.ts +2 -0
  255. package/dist/types/src/components/TaskList/index.d.ts.map +1 -0
  256. package/dist/types/src/components/TemplateEditor/TemplateEditor.d.ts +6 -5
  257. package/dist/types/src/components/TemplateEditor/TemplateEditor.d.ts.map +1 -1
  258. package/dist/types/src/components/TemplateEditor/TemplateEditor.stories.d.ts +1 -305
  259. package/dist/types/src/components/TemplateEditor/TemplateEditor.stories.d.ts.map +1 -1
  260. package/dist/types/src/components/TemplateEditor/TemplateForm.d.ts +12 -3
  261. package/dist/types/src/components/TemplateEditor/TemplateForm.d.ts.map +1 -1
  262. package/dist/types/src/components/TemplateEditor/TemplateForm.stories.d.ts +2 -306
  263. package/dist/types/src/components/TemplateEditor/TemplateForm.stories.d.ts.map +1 -1
  264. package/dist/types/src/components/TemplateEditor/extensions/handlebars-extension.d.ts.map +1 -1
  265. package/dist/types/src/components/TemplateEditor/extensions/xml-extension.d.ts.map +1 -1
  266. package/dist/types/src/components/ToolBlock/ToolBlock.d.ts +5 -14
  267. package/dist/types/src/components/ToolBlock/ToolBlock.d.ts.map +1 -1
  268. package/dist/types/src/components/Toolbox/Toolbox.d.ts +14 -13
  269. package/dist/types/src/components/Toolbox/Toolbox.d.ts.map +1 -1
  270. package/dist/types/src/components/Toolbox/Toolbox.stories.d.ts +1 -305
  271. package/dist/types/src/components/Toolbox/Toolbox.stories.d.ts.map +1 -1
  272. package/dist/types/src/components/index.d.ts +6 -6
  273. package/dist/types/src/components/index.d.ts.map +1 -1
  274. package/dist/types/src/containers/AgentArticle/AgentArticle.d.ts +6 -0
  275. package/dist/types/src/containers/AgentArticle/AgentArticle.d.ts.map +1 -0
  276. package/dist/types/src/containers/AgentArticle/AgentArticle.stories.d.ts +21 -0
  277. package/dist/types/src/containers/AgentArticle/AgentArticle.stories.d.ts.map +1 -0
  278. package/dist/types/src/containers/AgentArticle/index.d.ts +2 -0
  279. package/dist/types/src/containers/AgentArticle/index.d.ts.map +1 -0
  280. package/dist/types/src/containers/AgentProperties/AgentProperties.d.ts +6 -0
  281. package/dist/types/src/containers/AgentProperties/AgentProperties.d.ts.map +1 -0
  282. package/dist/types/src/containers/AgentProperties/index.d.ts +2 -0
  283. package/dist/types/src/containers/AgentProperties/index.d.ts.map +1 -0
  284. package/dist/types/src/containers/BlueprintArticle/BlueprintArticle.d.ts +6 -0
  285. package/dist/types/src/containers/BlueprintArticle/BlueprintArticle.d.ts.map +1 -0
  286. package/dist/types/src/containers/BlueprintArticle/index.d.ts +2 -0
  287. package/dist/types/src/containers/BlueprintArticle/index.d.ts.map +1 -0
  288. package/dist/types/src/containers/ChatArticle/ChatArticle.d.ts +12 -0
  289. package/dist/types/src/containers/ChatArticle/ChatArticle.d.ts.map +1 -0
  290. package/dist/types/src/containers/ChatArticle/ChatArticle.stories.d.ts +15 -0
  291. package/dist/types/src/containers/ChatArticle/ChatArticle.stories.d.ts.map +1 -0
  292. package/dist/types/src/containers/ChatArticle/index.d.ts +2 -0
  293. package/dist/types/src/containers/ChatArticle/index.d.ts.map +1 -0
  294. package/dist/types/src/containers/ChatCompanion/ChatCompanion.d.ts +18 -0
  295. package/dist/types/src/containers/ChatCompanion/ChatCompanion.d.ts.map +1 -0
  296. package/dist/types/src/containers/ChatCompanion/index.d.ts +2 -0
  297. package/dist/types/src/containers/ChatCompanion/index.d.ts.map +1 -0
  298. package/dist/types/src/{components → containers/ChatDialog}/ChatDialog.d.ts +2 -3
  299. package/dist/types/src/containers/ChatDialog/ChatDialog.d.ts.map +1 -0
  300. package/dist/types/src/containers/ChatDialog/index.d.ts +2 -0
  301. package/dist/types/src/containers/ChatDialog/index.d.ts.map +1 -0
  302. package/dist/types/src/containers/PlanArticle/PlanArticle.d.ts +6 -0
  303. package/dist/types/src/containers/PlanArticle/PlanArticle.d.ts.map +1 -0
  304. package/dist/types/src/containers/PlanArticle/index.d.ts +2 -0
  305. package/dist/types/src/containers/PlanArticle/index.d.ts.map +1 -0
  306. package/dist/types/src/containers/RoutineArticle/RoutineArticle.d.ts +6 -0
  307. package/dist/types/src/containers/RoutineArticle/RoutineArticle.d.ts.map +1 -0
  308. package/dist/types/src/containers/RoutineArticle/RoutineArticle.stories.d.ts +15 -0
  309. package/dist/types/src/containers/RoutineArticle/RoutineArticle.stories.d.ts.map +1 -0
  310. package/dist/types/src/containers/RoutineArticle/index.d.ts +2 -0
  311. package/dist/types/src/containers/RoutineArticle/index.d.ts.map +1 -0
  312. package/dist/types/src/containers/RoutineList/RoutineList.d.ts +6 -0
  313. package/dist/types/src/containers/RoutineList/RoutineList.d.ts.map +1 -0
  314. package/dist/types/src/containers/RoutineList/RoutineList.stories.d.ts +21 -0
  315. package/dist/types/src/containers/RoutineList/RoutineList.stories.d.ts.map +1 -0
  316. package/dist/types/src/containers/RoutineList/index.d.ts +2 -0
  317. package/dist/types/src/containers/RoutineList/index.d.ts.map +1 -0
  318. package/dist/types/src/containers/TracePanel/TracePanel.d.ts +8 -0
  319. package/dist/types/src/containers/TracePanel/TracePanel.d.ts.map +1 -0
  320. package/dist/types/src/containers/TracePanel/TracePanel.stories.d.ts +15 -0
  321. package/dist/types/src/containers/TracePanel/TracePanel.stories.d.ts.map +1 -0
  322. package/dist/types/src/containers/TracePanel/dxn-extractor.d.ts +19 -0
  323. package/dist/types/src/containers/TracePanel/dxn-extractor.d.ts.map +1 -0
  324. package/dist/types/src/containers/TracePanel/dxn-extractor.test.d.ts +2 -0
  325. package/dist/types/src/containers/TracePanel/dxn-extractor.test.d.ts.map +1 -0
  326. package/dist/types/src/containers/TracePanel/index.d.ts +4 -0
  327. package/dist/types/src/containers/TracePanel/index.d.ts.map +1 -0
  328. package/dist/types/src/containers/TracePanel/testing/index.d.ts +3 -0
  329. package/dist/types/src/containers/TracePanel/testing/index.d.ts.map +1 -0
  330. package/dist/types/src/containers/TracePanel/testing/simulated-agent.d.ts +14 -0
  331. package/dist/types/src/containers/TracePanel/testing/simulated-agent.d.ts.map +1 -0
  332. package/dist/types/src/containers/TracePanel/testing/snapshot-playback.d.ts +12 -0
  333. package/dist/types/src/containers/TracePanel/testing/snapshot-playback.d.ts.map +1 -0
  334. package/dist/types/src/containers/TriggerStatus/TriggerStatus.d.ts +5 -0
  335. package/dist/types/src/containers/TriggerStatus/TriggerStatus.d.ts.map +1 -0
  336. package/dist/types/src/containers/TriggerStatus/index.d.ts +2 -0
  337. package/dist/types/src/containers/TriggerStatus/index.d.ts.map +1 -0
  338. package/dist/types/src/containers/index.d.ts +13 -0
  339. package/dist/types/src/containers/index.d.ts.map +1 -0
  340. package/dist/types/src/execution-graph/execution-graph.d.ts +108 -0
  341. package/dist/types/src/execution-graph/execution-graph.d.ts.map +1 -0
  342. package/dist/types/src/execution-graph/execution-graph.test.d.ts +2 -0
  343. package/dist/types/src/execution-graph/execution-graph.test.d.ts.map +1 -0
  344. package/dist/types/src/execution-graph/index.d.ts +3 -0
  345. package/dist/types/src/execution-graph/index.d.ts.map +1 -0
  346. package/dist/types/src/execution-graph/remote-snapshot.test.d.ts +2 -0
  347. package/dist/types/src/execution-graph/remote-snapshot.test.d.ts.map +1 -0
  348. package/dist/types/src/execution-graph/span-tree.d.ts +76 -0
  349. package/dist/types/src/execution-graph/span-tree.d.ts.map +1 -0
  350. package/dist/types/src/execution-graph/span-tree.test.d.ts +2 -0
  351. package/dist/types/src/execution-graph/span-tree.test.d.ts.map +1 -0
  352. package/dist/types/src/execution-graph/testing/collect-trace-events.d.ts +40 -0
  353. package/dist/types/src/execution-graph/testing/collect-trace-events.d.ts.map +1 -0
  354. package/dist/types/src/execution-graph/testing/index.d.ts +2 -0
  355. package/dist/types/src/execution-graph/testing/index.d.ts.map +1 -0
  356. package/dist/types/src/extensions/index.d.ts +2 -0
  357. package/dist/types/src/extensions/index.d.ts.map +1 -0
  358. package/dist/types/src/extensions/prompt-extension.d.ts +10 -0
  359. package/dist/types/src/extensions/prompt-extension.d.ts.map +1 -0
  360. package/dist/types/src/feed-logger.d.ts +13 -0
  361. package/dist/types/src/feed-logger.d.ts.map +1 -0
  362. package/dist/types/src/hooks/index.d.ts +2 -0
  363. package/dist/types/src/hooks/index.d.ts.map +1 -1
  364. package/dist/types/src/hooks/useBlueprintRegistry.d.ts +9 -9
  365. package/dist/types/src/hooks/useBlueprintRegistry.d.ts.map +1 -1
  366. package/dist/types/src/hooks/useChatKeymap.d.ts +12 -0
  367. package/dist/types/src/hooks/useChatKeymap.d.ts.map +1 -0
  368. package/dist/types/src/hooks/useChatProcessor.d.ts +8 -7
  369. package/dist/types/src/hooks/useChatProcessor.d.ts.map +1 -1
  370. package/dist/types/src/hooks/useChatServices.d.ts +9 -8
  371. package/dist/types/src/hooks/useChatServices.d.ts.map +1 -1
  372. package/dist/types/src/hooks/useChatToolbarActions.d.ts +3 -3
  373. package/dist/types/src/hooks/useChatToolbarActions.d.ts.map +1 -1
  374. package/dist/types/src/hooks/useContextBinder.d.ts +4 -3
  375. package/dist/types/src/hooks/useContextBinder.d.ts.map +1 -1
  376. package/dist/types/src/hooks/useContextObjects.d.ts +8 -8
  377. package/dist/types/src/hooks/useContextObjects.d.ts.map +1 -1
  378. package/dist/types/src/hooks/useDebug.d.ts +10 -0
  379. package/dist/types/src/hooks/useDebug.d.ts.map +1 -0
  380. package/dist/types/src/hooks/useFilteredTypes.d.ts +2 -3
  381. package/dist/types/src/hooks/useFilteredTypes.d.ts.map +1 -1
  382. package/dist/types/src/hooks/useFlush.d.ts +1 -1
  383. package/dist/types/src/hooks/useFlush.d.ts.map +1 -1
  384. package/dist/types/src/hooks/usePresets.d.ts +1 -1
  385. package/dist/types/src/hooks/usePresets.d.ts.map +1 -1
  386. package/dist/types/src/hooks/useReferencesProvider.d.ts.map +1 -1
  387. package/dist/types/src/index.d.ts +1 -6
  388. package/dist/types/src/index.d.ts.map +1 -1
  389. package/dist/types/src/meta.d.ts +4 -2
  390. package/dist/types/src/meta.d.ts.map +1 -1
  391. package/dist/types/src/operations/create-chat.d.ts +5 -0
  392. package/dist/types/src/operations/create-chat.d.ts.map +1 -0
  393. package/dist/types/src/operations/ensure-companion-chat.d.ts +5 -0
  394. package/dist/types/src/operations/ensure-companion-chat.d.ts.map +1 -0
  395. package/dist/types/src/operations/index.d.ts +3 -0
  396. package/dist/types/src/operations/index.d.ts.map +1 -0
  397. package/dist/types/src/operations/on-create-space.d.ts +5 -0
  398. package/dist/types/src/operations/on-create-space.d.ts.map +1 -0
  399. package/dist/types/src/operations/prompt.node.test.d.ts +2 -0
  400. package/dist/types/src/operations/prompt.node.test.d.ts.map +1 -0
  401. package/dist/types/src/operations/resolve-navigation-targets.d.ts +15 -0
  402. package/dist/types/src/operations/resolve-navigation-targets.d.ts.map +1 -0
  403. package/dist/types/src/operations/run-prompt-in-new-chat.d.ts +5 -0
  404. package/dist/types/src/operations/run-prompt-in-new-chat.d.ts.map +1 -0
  405. package/dist/types/src/operations/set-current-chat.d.ts +5 -0
  406. package/dist/types/src/operations/set-current-chat.d.ts.map +1 -0
  407. package/dist/types/src/operations/toggle-trace-panel-debug.d.ts +5 -0
  408. package/dist/types/src/operations/toggle-trace-panel-debug.d.ts.map +1 -0
  409. package/dist/types/src/operations/update-chat-name.d.ts +5 -0
  410. package/dist/types/src/operations/update-chat-name.d.ts.map +1 -0
  411. package/dist/types/src/plugin.d.ts +4 -0
  412. package/dist/types/src/plugin.d.ts.map +1 -0
  413. package/dist/types/src/processor/index.d.ts +0 -1
  414. package/dist/types/src/processor/index.d.ts.map +1 -1
  415. package/dist/types/src/processor/presets.d.ts +1 -1
  416. package/dist/types/src/processor/presets.d.ts.map +1 -1
  417. package/dist/types/src/processor/processor.d.ts +84 -34
  418. package/dist/types/src/processor/processor.d.ts.map +1 -1
  419. package/dist/types/src/processor/processor.node.test.d.ts +2 -0
  420. package/dist/types/src/processor/processor.node.test.d.ts.map +1 -0
  421. package/dist/types/src/testing/index.d.ts +2 -0
  422. package/dist/types/src/testing/index.d.ts.map +1 -1
  423. package/dist/types/src/testing/snapshot.d.ts +21 -0
  424. package/dist/types/src/testing/snapshot.d.ts.map +1 -0
  425. package/dist/types/src/testing/test-generator.d.ts +2 -2
  426. package/dist/types/src/testing/test-generator.d.ts.map +1 -1
  427. package/dist/types/src/testing/test-generator.test.d.ts +2 -0
  428. package/dist/types/src/testing/test-generator.test.d.ts.map +1 -0
  429. package/dist/types/src/testing/test-sequence.d.ts +3 -3
  430. package/dist/types/src/testing/test-sequence.d.ts.map +1 -1
  431. package/dist/types/src/testing/test-services.d.ts +1 -1
  432. package/dist/types/src/testing/test-services.d.ts.map +1 -1
  433. package/dist/types/src/testing/test-trace.d.ts +5 -0
  434. package/dist/types/src/testing/test-trace.d.ts.map +1 -0
  435. package/dist/types/src/testing/trace-timeline.node.test.d.ts +2 -0
  436. package/dist/types/src/testing/trace-timeline.node.test.d.ts.map +1 -0
  437. package/dist/types/src/testing.d.ts +2 -0
  438. package/dist/types/src/testing.d.ts.map +1 -0
  439. package/dist/types/src/translations.d.ts +2 -305
  440. package/dist/types/src/translations.d.ts.map +1 -1
  441. package/dist/types/src/types/Assistant.d.ts +34 -42
  442. package/dist/types/src/types/Assistant.d.ts.map +1 -1
  443. package/dist/types/src/types/AssistantCapabilities.d.ts +30 -0
  444. package/dist/types/src/types/AssistantCapabilities.d.ts.map +1 -0
  445. package/dist/types/src/types/AssistantEvents.d.ts +3 -0
  446. package/dist/types/src/types/AssistantEvents.d.ts.map +1 -0
  447. package/dist/types/src/types/AssistantOperation.d.ts +144 -0
  448. package/dist/types/src/types/AssistantOperation.d.ts.map +1 -0
  449. package/dist/types/src/types/Settings.d.ts +27 -0
  450. package/dist/types/src/types/Settings.d.ts.map +1 -0
  451. package/dist/types/src/types/index.d.ts +4 -2
  452. package/dist/types/src/types/index.d.ts.map +1 -1
  453. package/dist/types/src/types/service.d.ts +11 -260
  454. package/dist/types/src/types/service.d.ts.map +1 -1
  455. package/dist/types/src/util/suggestions.d.ts +9 -0
  456. package/dist/types/src/util/suggestions.d.ts.map +1 -0
  457. package/dist/types/src/util/suggestions.test.d.ts +2 -0
  458. package/dist/types/src/util/suggestions.test.d.ts.map +1 -0
  459. package/dist/types/tsconfig.tsbuildinfo +1 -1
  460. package/package.json +203 -109
  461. package/src/AssistantPlugin.node.ts +66 -0
  462. package/src/AssistantPlugin.test.ts +49 -0
  463. package/src/AssistantPlugin.ts +126 -0
  464. package/src/AssistantPlugin.workerd.ts +41 -0
  465. package/src/blueprints/assistant/blueprint.node.test.ts +46 -0
  466. package/src/blueprints/assistant/blueprint.ts +31 -0
  467. package/src/blueprints/assistant/index.ts +5 -0
  468. package/src/{components/ChatProgress → blueprints}/index.ts +1 -1
  469. package/src/capabilities/ai-service.ts +34 -17
  470. package/src/capabilities/app-graph-builder.ts +174 -187
  471. package/src/capabilities/blueprint-definition.ts +47 -57
  472. package/src/capabilities/companion-chat-provisioner.ts +163 -0
  473. package/src/capabilities/create-object.ts +102 -0
  474. package/src/capabilities/edge-model-resolver.ts +22 -14
  475. package/src/capabilities/index.ts +23 -15
  476. package/src/capabilities/local-model-resolver.ts +31 -13
  477. package/src/capabilities/markdown.ts +40 -0
  478. package/src/capabilities/migrations.ts +28 -0
  479. package/src/capabilities/operation-handler.ts +16 -0
  480. package/src/capabilities/react-surface.tsx +161 -73
  481. package/src/capabilities/settings.ts +24 -12
  482. package/src/capabilities/state.ts +26 -13
  483. package/src/capabilities/toolkit.ts +7 -11
  484. package/src/components/AgentProperties/AgentProperties.stories.tsx +74 -0
  485. package/src/components/AgentProperties/AgentProperties.tsx +104 -0
  486. package/src/components/AgentProperties/index.ts +5 -0
  487. package/src/components/AssistantSettings/AssistantSettings.stories.tsx +35 -0
  488. package/src/components/AssistantSettings/AssistantSettings.tsx +30 -99
  489. package/src/components/AssistantSettings/index.ts +2 -2
  490. package/src/components/Chat/Chat.tsx +128 -259
  491. package/src/components/Chat/context.ts +39 -0
  492. package/src/components/Chat/events.ts +1 -1
  493. package/src/components/ChatPrompt/ChatActions.tsx +34 -14
  494. package/src/components/ChatPrompt/ChatMcpErrors.tsx +50 -0
  495. package/src/components/ChatPrompt/ChatOptions.stories.tsx +136 -0
  496. package/src/components/ChatPrompt/ChatOptions.tsx +298 -87
  497. package/src/components/ChatPrompt/ChatPrompt.tsx +182 -0
  498. package/src/components/ChatPrompt/ChatReferences.tsx +23 -14
  499. package/src/components/ChatPrompt/ChatStatus.tsx +123 -0
  500. package/src/components/ChatPrompt/ChatStatusIndicator.tsx +2 -2
  501. package/src/components/ChatPrompt/index.ts +3 -0
  502. package/src/components/ChatThread/Anchor.stories.tsx +95 -0
  503. package/src/components/ChatThread/ChatThread.stories.tsx +71 -80
  504. package/src/components/ChatThread/ChatThread.tsx +50 -24
  505. package/src/components/ChatThread/DEBUG.md +41 -0
  506. package/src/components/ChatThread/Link.tsx +3 -3
  507. package/src/components/ChatThread/MarkdownStream.stories.tsx +281 -0
  508. package/src/components/ChatThread/registry.tsx +171 -55
  509. package/src/components/ChatThread/sync.test.ts +193 -25
  510. package/src/components/ChatThread/sync.ts +94 -92
  511. package/src/components/ChatThread/testing/reasoning.md +25 -0
  512. package/src/components/ChatThread/testing/thinking.md +21 -0
  513. package/src/components/ChatThread/testing/thread-1.md +30 -0
  514. package/src/components/ChatThread/testing/{thread.md → thread-2.md} +19 -0
  515. package/src/components/ChatThread/testing/thread-widgets.md +79 -0
  516. package/src/components/ChatThread/tool-widget-state.test.ts +34 -0
  517. package/src/components/ChatThread/tool-widget-state.ts +48 -0
  518. package/src/components/ChatThread/widgets/FallbackWidget.tsx +26 -0
  519. package/src/components/ChatThread/widgets/ReasoningWidget.stories.tsx +68 -0
  520. package/src/components/ChatThread/widgets/ReasoningWidget.ts +133 -0
  521. package/src/components/ChatThread/widgets/ReferenceWidget.ts +33 -0
  522. package/src/components/ChatThread/widgets/SelectWidget.ts +39 -0
  523. package/src/components/ChatThread/widgets/StatsWidget.ts +31 -0
  524. package/src/components/ChatThread/widgets/StatusWidget.ts +53 -0
  525. package/src/components/ChatThread/widgets/SuggestionWidget.ts +41 -0
  526. package/src/components/ChatThread/widgets/SummaryWidget.tsx +27 -0
  527. package/src/components/ChatThread/widgets/ToolWidget.stories.tsx +55 -0
  528. package/src/components/ChatThread/widgets/ToolWidget.tsx +156 -0
  529. package/src/components/ChatThread/widgets/defaults.ts +8 -0
  530. package/src/components/ChatThread/widgets/index.ts +13 -0
  531. package/src/components/ProcessTree/ProcessTree.stories.tsx +83 -0
  532. package/src/components/ProcessTree/ProcessTree.tsx +119 -0
  533. package/src/components/ProcessTree/index.ts +5 -0
  534. package/src/components/RoutineProperties/RoutineProperties.stories.tsx +59 -0
  535. package/src/components/RoutineProperties/RoutineProperties.tsx +23 -0
  536. package/src/components/RoutineProperties/index.ts +5 -0
  537. package/src/components/TaskList/TaskList.stories.tsx +44 -0
  538. package/src/components/TaskList/TaskList.tsx +45 -0
  539. package/src/components/TaskList/index.ts +5 -0
  540. package/src/components/TemplateEditor/TemplateEditor.stories.tsx +8 -12
  541. package/src/components/TemplateEditor/TemplateEditor.tsx +53 -42
  542. package/src/components/TemplateEditor/TemplateForm.stories.tsx +21 -15
  543. package/src/components/TemplateEditor/TemplateForm.tsx +111 -86
  544. package/src/components/TemplateEditor/extensions/handlebars-extension.ts +15 -10
  545. package/src/components/ToolBlock/ToolBlock.tsx +25 -24
  546. package/src/components/Toolbox/Toolbox.stories.tsx +16 -18
  547. package/src/components/Toolbox/Toolbox.tsx +73 -68
  548. package/src/components/index.ts +6 -7
  549. package/src/containers/AgentArticle/AgentArticle.stories.tsx +120 -0
  550. package/src/containers/AgentArticle/AgentArticle.tsx +197 -0
  551. package/src/containers/AgentArticle/index.ts +5 -0
  552. package/src/containers/AgentProperties/AgentProperties.tsx +43 -0
  553. package/src/containers/AgentProperties/index.ts +5 -0
  554. package/src/containers/BlueprintArticle/BlueprintArticle.tsx +29 -0
  555. package/src/containers/BlueprintArticle/index.ts +5 -0
  556. package/src/containers/ChatArticle/ChatArticle.stories.tsx +76 -0
  557. package/src/containers/ChatArticle/ChatArticle.tsx +107 -0
  558. package/src/containers/ChatArticle/index.ts +5 -0
  559. package/src/containers/ChatCompanion/ChatCompanion.tsx +133 -0
  560. package/src/containers/ChatCompanion/index.ts +5 -0
  561. package/src/{components → containers/ChatDialog}/ChatDialog.tsx +14 -23
  562. package/src/containers/ChatDialog/index.ts +5 -0
  563. package/src/containers/PlanArticle/PlanArticle.tsx +33 -0
  564. package/src/containers/PlanArticle/index.ts +5 -0
  565. package/src/containers/RoutineArticle/RoutineArticle.stories.tsx +75 -0
  566. package/src/containers/RoutineArticle/RoutineArticle.tsx +109 -0
  567. package/src/containers/RoutineArticle/index.ts +5 -0
  568. package/src/containers/RoutineList/RoutineList.stories.tsx +130 -0
  569. package/src/containers/RoutineList/RoutineList.tsx +50 -0
  570. package/src/containers/RoutineList/index.ts +5 -0
  571. package/src/containers/TracePanel/TracePanel.stories.tsx +319 -0
  572. package/src/containers/TracePanel/TracePanel.tsx +177 -0
  573. package/src/containers/TracePanel/dxn-extractor.test.ts +153 -0
  574. package/src/containers/TracePanel/dxn-extractor.ts +178 -0
  575. package/src/containers/TracePanel/index.ts +9 -0
  576. package/src/containers/TracePanel/testing/index.ts +6 -0
  577. package/src/containers/TracePanel/testing/simulated-agent.ts +114 -0
  578. package/src/containers/TracePanel/testing/snapshot-playback.ts +45 -0
  579. package/src/containers/TriggerStatus/TriggerStatus.tsx +129 -0
  580. package/src/containers/TriggerStatus/index.ts +5 -0
  581. package/src/containers/index.ts +17 -0
  582. package/src/execution-graph/SPEC.md +678 -0
  583. package/src/execution-graph/execution-graph.test.ts +799 -0
  584. package/src/execution-graph/execution-graph.ts +714 -0
  585. package/src/execution-graph/index.ts +24 -0
  586. package/src/execution-graph/remote-snapshot.test.ts +116 -0
  587. package/src/execution-graph/span-tree.test.ts +249 -0
  588. package/src/execution-graph/span-tree.ts +259 -0
  589. package/src/execution-graph/testing/collect-trace-events.ts +74 -0
  590. package/src/execution-graph/testing/index.ts +5 -0
  591. package/src/extensions/index.ts +5 -0
  592. package/src/extensions/prompt-extension.ts +111 -0
  593. package/src/{queue-logger.ts → feed-logger.ts} +46 -22
  594. package/src/hooks/index.ts +2 -0
  595. package/src/hooks/useBlueprintRegistry.ts +48 -28
  596. package/src/hooks/useChatKeymap.ts +52 -0
  597. package/src/hooks/useChatProcessor.ts +59 -25
  598. package/src/hooks/useChatServices.ts +14 -37
  599. package/src/hooks/useChatToolbarActions.ts +97 -99
  600. package/src/hooks/useContextBinder.ts +22 -9
  601. package/src/hooks/useContextObjects.ts +17 -25
  602. package/src/hooks/useDebug.ts +38 -0
  603. package/src/hooks/useFilteredTypes.ts +8 -9
  604. package/src/hooks/usePresets.ts +2 -1
  605. package/src/hooks/useReferencesProvider.ts +5 -9
  606. package/src/index.ts +1 -7
  607. package/src/meta.ts +9 -6
  608. package/src/operations/create-chat.ts +84 -0
  609. package/src/operations/ensure-companion-chat.ts +63 -0
  610. package/src/operations/index.ts +16 -0
  611. package/src/operations/on-create-space.ts +24 -0
  612. package/src/operations/prompt.node.test.ts +80 -0
  613. package/src/operations/resolve-navigation-targets.ts +26 -0
  614. package/src/operations/run-prompt-in-new-chat.ts +113 -0
  615. package/src/operations/set-current-chat.ts +49 -0
  616. package/src/operations/toggle-trace-panel-debug.ts +27 -0
  617. package/src/operations/update-chat-name.ts +61 -0
  618. package/src/plugin.ts +11 -0
  619. package/src/processor/index.ts +0 -1
  620. package/src/processor/presets.ts +11 -3
  621. package/src/processor/processor.node.test.ts +41 -0
  622. package/src/processor/processor.ts +276 -159
  623. package/src/testing/data/trace-timeline-multiple.dx.json +1 -0
  624. package/src/testing/data/trace-timeline-remote.dx.json +1 -0
  625. package/src/testing/data/trace-timeline.dx.json +4657 -0
  626. package/src/testing/index.ts +2 -0
  627. package/src/testing/snapshot.ts +35 -0
  628. package/src/testing/test-generator.test.ts +70 -0
  629. package/src/testing/test-generator.ts +214 -191
  630. package/src/testing/test-sequence.ts +6 -6
  631. package/src/testing/test-services.ts +9 -7
  632. package/src/testing/test-trace.ts +20 -0
  633. package/src/testing/trace-timeline.conversations.json +1 -0
  634. package/src/testing/trace-timeline.node.conversations.json +1 -0
  635. package/src/testing/trace-timeline.node.test.ts +251 -0
  636. package/src/testing.ts +9 -0
  637. package/src/translations.ts +159 -90
  638. package/src/types/Assistant.ts +17 -54
  639. package/src/types/AssistantCapabilities.ts +35 -0
  640. package/src/types/AssistantEvents.ts +11 -0
  641. package/src/types/AssistantOperation.ts +141 -0
  642. package/src/types/Settings.ts +82 -0
  643. package/src/types/index.ts +8 -2
  644. package/src/types/service.ts +14 -11
  645. package/src/util/suggestions.test.ts +52 -0
  646. package/src/util/suggestions.ts +42 -0
  647. package/dist/lib/browser/BlueprintArticle-BWSLH6LG.mjs +0 -36
  648. package/dist/lib/browser/BlueprintArticle-BWSLH6LG.mjs.map +0 -7
  649. package/dist/lib/browser/ChatCompanion-OSZZZSWV.mjs +0 -158
  650. package/dist/lib/browser/ChatCompanion-OSZZZSWV.mjs.map +0 -7
  651. package/dist/lib/browser/ChatContainer-2W6FNSJD.mjs +0 -77
  652. package/dist/lib/browser/ChatContainer-2W6FNSJD.mjs.map +0 -7
  653. package/dist/lib/browser/ChatDialog-XQ3KDYWE.mjs +0 -90
  654. package/dist/lib/browser/ChatDialog-XQ3KDYWE.mjs.map +0 -7
  655. package/dist/lib/browser/PromptArticle-Q7JYGFQV.mjs +0 -59
  656. package/dist/lib/browser/PromptArticle-Q7JYGFQV.mjs.map +0 -7
  657. package/dist/lib/browser/ai-service-ERTZBTP3.mjs +0 -19
  658. package/dist/lib/browser/ai-service-ERTZBTP3.mjs.map +0 -7
  659. package/dist/lib/browser/app-graph-builder-LM6GVHQO.mjs +0 -199
  660. package/dist/lib/browser/app-graph-builder-LM6GVHQO.mjs.map +0 -7
  661. package/dist/lib/browser/blueprint-definition-VBEOXNBS.mjs +0 -12
  662. package/dist/lib/browser/chunk-2BOE3OTW.mjs +0 -262
  663. package/dist/lib/browser/chunk-2BOE3OTW.mjs.map +0 -7
  664. package/dist/lib/browser/chunk-5JZRYQZL.mjs +0 -229
  665. package/dist/lib/browser/chunk-5JZRYQZL.mjs.map +0 -7
  666. package/dist/lib/browser/chunk-7ZJIXQ2Y.mjs +0 -335
  667. package/dist/lib/browser/chunk-7ZJIXQ2Y.mjs.map +0 -7
  668. package/dist/lib/browser/chunk-LRE4VEZV.mjs +0 -16
  669. package/dist/lib/browser/chunk-LRE4VEZV.mjs.map +0 -7
  670. package/dist/lib/browser/chunk-NC2QNMBF.mjs +0 -176
  671. package/dist/lib/browser/chunk-NC2QNMBF.mjs.map +0 -7
  672. package/dist/lib/browser/chunk-PWSTPQUY.mjs +0 -1929
  673. package/dist/lib/browser/chunk-PWSTPQUY.mjs.map +0 -7
  674. package/dist/lib/browser/chunk-WBG5PTSX.mjs.map +0 -7
  675. package/dist/lib/browser/edge-model-resolver-O6OFYIO2.mjs +0 -18
  676. package/dist/lib/browser/edge-model-resolver-O6OFYIO2.mjs.map +0 -7
  677. package/dist/lib/browser/index.mjs +0 -374
  678. package/dist/lib/browser/index.mjs.map +0 -7
  679. package/dist/lib/browser/intent-resolver-EEYS2GJF.mjs +0 -143
  680. package/dist/lib/browser/intent-resolver-EEYS2GJF.mjs.map +0 -7
  681. package/dist/lib/browser/local-model-resolver-34MVHRKD.mjs +0 -17
  682. package/dist/lib/browser/local-model-resolver-34MVHRKD.mjs.map +0 -7
  683. package/dist/lib/browser/meta.json +0 -1
  684. package/dist/lib/browser/react-surface-ECKZNDSU.mjs +0 -98
  685. package/dist/lib/browser/react-surface-ECKZNDSU.mjs.map +0 -7
  686. package/dist/lib/browser/repair-3MZXLUHO.mjs +0 -44
  687. package/dist/lib/browser/repair-3MZXLUHO.mjs.map +0 -7
  688. package/dist/lib/browser/settings-HD5WA24I.mjs +0 -23
  689. package/dist/lib/browser/settings-HD5WA24I.mjs.map +0 -7
  690. package/dist/lib/browser/state-GG7Z3NB7.mjs +0 -25
  691. package/dist/lib/browser/state-GG7Z3NB7.mjs.map +0 -7
  692. package/dist/lib/browser/toolkit-VYDAWNE4.mjs +0 -17
  693. package/dist/lib/browser/toolkit-VYDAWNE4.mjs.map +0 -7
  694. package/dist/lib/browser/types/index.mjs +0 -19
  695. package/dist/lib/node-esm/BlueprintArticle-R2XYBRCK.mjs +0 -37
  696. package/dist/lib/node-esm/BlueprintArticle-R2XYBRCK.mjs.map +0 -7
  697. package/dist/lib/node-esm/ChatCompanion-IUMU7WRQ.mjs +0 -159
  698. package/dist/lib/node-esm/ChatCompanion-IUMU7WRQ.mjs.map +0 -7
  699. package/dist/lib/node-esm/ChatContainer-CTUNUEU3.mjs +0 -78
  700. package/dist/lib/node-esm/ChatContainer-CTUNUEU3.mjs.map +0 -7
  701. package/dist/lib/node-esm/ChatDialog-X42ASXQD.mjs +0 -91
  702. package/dist/lib/node-esm/ChatDialog-X42ASXQD.mjs.map +0 -7
  703. package/dist/lib/node-esm/PromptArticle-IV7O5UZ3.mjs +0 -60
  704. package/dist/lib/node-esm/PromptArticle-IV7O5UZ3.mjs.map +0 -7
  705. package/dist/lib/node-esm/ai-service-MUYLV3NT.mjs +0 -20
  706. package/dist/lib/node-esm/ai-service-MUYLV3NT.mjs.map +0 -7
  707. package/dist/lib/node-esm/app-graph-builder-6XUAGTRS.mjs +0 -200
  708. package/dist/lib/node-esm/app-graph-builder-6XUAGTRS.mjs.map +0 -7
  709. package/dist/lib/node-esm/blueprint-definition-RDCLLIQH.mjs +0 -13
  710. package/dist/lib/node-esm/chunk-25GMMNY5.mjs +0 -178
  711. package/dist/lib/node-esm/chunk-25GMMNY5.mjs.map +0 -7
  712. package/dist/lib/node-esm/chunk-3Q22TTXW.mjs +0 -264
  713. package/dist/lib/node-esm/chunk-3Q22TTXW.mjs.map +0 -7
  714. package/dist/lib/node-esm/chunk-CKW4IYLY.mjs +0 -336
  715. package/dist/lib/node-esm/chunk-CKW4IYLY.mjs.map +0 -7
  716. package/dist/lib/node-esm/chunk-E4JSYCWZ.mjs +0 -230
  717. package/dist/lib/node-esm/chunk-E4JSYCWZ.mjs.map +0 -7
  718. package/dist/lib/node-esm/chunk-HSLMI22Q.mjs +0 -11
  719. package/dist/lib/node-esm/chunk-WE6KTH72.mjs +0 -25
  720. package/dist/lib/node-esm/chunk-WE6KTH72.mjs.map +0 -7
  721. package/dist/lib/node-esm/chunk-YWFWT57N.mjs +0 -17
  722. package/dist/lib/node-esm/chunk-YWFWT57N.mjs.map +0 -7
  723. package/dist/lib/node-esm/chunk-Z37USO4K.mjs +0 -1930
  724. package/dist/lib/node-esm/chunk-Z37USO4K.mjs.map +0 -7
  725. package/dist/lib/node-esm/edge-model-resolver-2ARXDOYS.mjs +0 -19
  726. package/dist/lib/node-esm/edge-model-resolver-2ARXDOYS.mjs.map +0 -7
  727. package/dist/lib/node-esm/index.mjs +0 -375
  728. package/dist/lib/node-esm/index.mjs.map +0 -7
  729. package/dist/lib/node-esm/intent-resolver-4SRYLDK5.mjs +0 -144
  730. package/dist/lib/node-esm/intent-resolver-4SRYLDK5.mjs.map +0 -7
  731. package/dist/lib/node-esm/local-model-resolver-TP2NTSAX.mjs +0 -18
  732. package/dist/lib/node-esm/local-model-resolver-TP2NTSAX.mjs.map +0 -7
  733. package/dist/lib/node-esm/meta.json +0 -1
  734. package/dist/lib/node-esm/react-surface-NLIG5VAI.mjs +0 -99
  735. package/dist/lib/node-esm/react-surface-NLIG5VAI.mjs.map +0 -7
  736. package/dist/lib/node-esm/repair-RER5H7Y6.mjs +0 -45
  737. package/dist/lib/node-esm/repair-RER5H7Y6.mjs.map +0 -7
  738. package/dist/lib/node-esm/settings-YJQVKHH5.mjs +0 -24
  739. package/dist/lib/node-esm/settings-YJQVKHH5.mjs.map +0 -7
  740. package/dist/lib/node-esm/state-FSUHFMDM.mjs +0 -26
  741. package/dist/lib/node-esm/state-FSUHFMDM.mjs.map +0 -7
  742. package/dist/lib/node-esm/toolkit-HFJZLVIR.mjs +0 -18
  743. package/dist/lib/node-esm/toolkit-HFJZLVIR.mjs.map +0 -7
  744. package/dist/lib/node-esm/types/index.mjs +0 -20
  745. package/dist/types/src/capabilities/capabilities.d.ts +0 -10
  746. package/dist/types/src/capabilities/capabilities.d.ts.map +0 -1
  747. package/dist/types/src/capabilities/intent-resolver.d.ts +0 -4
  748. package/dist/types/src/capabilities/intent-resolver.d.ts.map +0 -1
  749. package/dist/types/src/capabilities/repair.d.ts +0 -4
  750. package/dist/types/src/capabilities/repair.d.ts.map +0 -1
  751. package/dist/types/src/components/BlueprintArticle.d.ts +0 -7
  752. package/dist/types/src/components/BlueprintArticle.d.ts.map +0 -1
  753. package/dist/types/src/components/ChatCompanion.d.ts +0 -13
  754. package/dist/types/src/components/ChatCompanion.d.ts.map +0 -1
  755. package/dist/types/src/components/ChatContainer.d.ts +0 -14
  756. package/dist/types/src/components/ChatContainer.d.ts.map +0 -1
  757. package/dist/types/src/components/ChatDialog.d.ts.map +0 -1
  758. package/dist/types/src/components/ChatProgress/ChatProgress.d.ts +0 -7
  759. package/dist/types/src/components/ChatProgress/ChatProgress.d.ts.map +0 -1
  760. package/dist/types/src/components/ChatProgress/index.d.ts +0 -2
  761. package/dist/types/src/components/ChatProgress/index.d.ts.map +0 -1
  762. package/dist/types/src/components/ChatThread/reducers.d.ts +0 -40
  763. package/dist/types/src/components/ChatThread/reducers.d.ts.map +0 -1
  764. package/dist/types/src/components/PromptArticle.d.ts +0 -7
  765. package/dist/types/src/components/PromptArticle.d.ts.map +0 -1
  766. package/dist/types/src/events.d.ts +0 -4
  767. package/dist/types/src/events.d.ts.map +0 -1
  768. package/dist/types/src/functions/analysis.d.ts +0 -5
  769. package/dist/types/src/functions/analysis.d.ts.map +0 -1
  770. package/dist/types/src/functions/index.d.ts +0 -4
  771. package/dist/types/src/functions/index.d.ts.map +0 -1
  772. package/dist/types/src/functions/object-list.d.ts +0 -10
  773. package/dist/types/src/functions/object-list.d.ts.map +0 -1
  774. package/dist/types/src/functions/object-load.d.ts +0 -8
  775. package/dist/types/src/functions/object-load.d.ts.map +0 -1
  776. package/dist/types/src/processor/processor.test.d.ts +0 -2
  777. package/dist/types/src/processor/processor.test.d.ts.map +0 -1
  778. package/dist/types/src/processor/update-name.d.ts +0 -10
  779. package/dist/types/src/processor/update-name.d.ts.map +0 -1
  780. package/dist/types/src/queue-logger.d.ts +0 -11
  781. package/dist/types/src/queue-logger.d.ts.map +0 -1
  782. package/dist/types/src/types/AssistantAction.d.ts +0 -129
  783. package/dist/types/src/types/AssistantAction.d.ts.map +0 -1
  784. package/dist/types/src/types/defs.d.ts +0 -2
  785. package/dist/types/src/types/defs.d.ts.map +0 -1
  786. package/src/AssistantPlugin.tsx +0 -164
  787. package/src/capabilities/capabilities.ts +0 -17
  788. package/src/capabilities/intent-resolver.ts +0 -135
  789. package/src/capabilities/repair.ts +0 -49
  790. package/src/components/BlueprintArticle.tsx +0 -29
  791. package/src/components/ChatCompanion.tsx +0 -155
  792. package/src/components/ChatContainer.tsx +0 -61
  793. package/src/components/ChatProgress/ChatProgress.tsx +0 -67
  794. package/src/components/ChatThread/reducers.ts +0 -151
  795. package/src/components/PromptArticle.tsx +0 -51
  796. package/src/events.ts +0 -11
  797. package/src/functions/analysis.ts +0 -22
  798. package/src/functions/index.ts +0 -7
  799. package/src/functions/object-list.ts +0 -48
  800. package/src/functions/object-load.ts +0 -45
  801. package/src/processor/processor.test.ts +0 -71
  802. package/src/processor/update-name.ts +0 -56
  803. package/src/types/AssistantAction.ts +0 -79
  804. package/src/types/defs.ts +0 -5
  805. /package/dist/lib/{browser/blueprint-definition-VBEOXNBS.mjs.map → neutral/AssistantPlugin.mjs.map} +0 -0
  806. /package/dist/lib/{browser/chunk-J5LGTIGS.mjs.map → neutral/ChatArticle-WVAFZPVI.mjs.map} +0 -0
  807. /package/dist/lib/{browser/types → neutral/blueprints}/index.mjs.map +0 -0
  808. /package/dist/lib/{browser → neutral}/chunk-J5LGTIGS.mjs +0 -0
  809. /package/dist/lib/{node-esm/blueprint-definition-RDCLLIQH.mjs.map → neutral/chunk-J5LGTIGS.mjs.map} +0 -0
  810. /package/dist/lib/{node-esm/types → neutral}/index.mjs.map +0 -0
  811. /package/dist/lib/{node-esm/chunk-HSLMI22Q.mjs.map → neutral/meta.mjs.map} +0 -0
@@ -3,42 +3,40 @@
3
3
  //
4
4
 
5
5
  import { type Meta, type StoryObj } from '@storybook/react-vite';
6
+ import * as Effect from 'effect/Effect';
6
7
  import React from 'react';
7
8
 
8
- import { IntentPlugin, SettingsPlugin } from '@dxos/app-framework';
9
9
  import { withPluginManager } from '@dxos/app-framework/testing';
10
- import { capabilities } from '@dxos/assistant-toolkit';
11
- import { ChessPlugin } from '@dxos/plugin-chess';
12
- import { ClientPlugin } from '@dxos/plugin-client';
13
- import { MapPlugin } from '@dxos/plugin-map';
14
- import { SpacePlugin } from '@dxos/plugin-space';
15
- import { TablePlugin } from '@dxos/plugin-table';
16
- import { withTheme } from '@dxos/react-ui/testing';
10
+ import { capabilities } from '@dxos/assistant-toolkit/testing';
11
+ import { ChessPlugin } from '@dxos/plugin-chess/testing';
12
+ import { ClientPlugin } from '@dxos/plugin-client/testing';
13
+ import { initializeIdentity } from '@dxos/plugin-client/testing';
14
+ import { MapPlugin } from '@dxos/plugin-map/testing';
15
+ import { TablePlugin } from '@dxos/plugin-table/testing';
16
+ import { corePlugins } from '@dxos/plugin-testing';
17
17
 
18
- import { translations } from '../../translations';
18
+ import { translations } from '#translations';
19
19
 
20
20
  import { Toolbox, type ToolboxProps } from './Toolbox';
21
21
 
22
22
  const DefaultStory = (props: ToolboxProps) => {
23
- return <Toolbox {...props} classNames='is-[30rem] bs-[15rem] rounded-sm border border-separator plb-1' />;
23
+ return <Toolbox {...props} classNames='h-[15rem] w-[30rem] py-1 rounded-xs border border-separator' />;
24
24
  };
25
25
 
26
26
  const meta = {
27
- title: 'plugins/plugin-assistant/Toolbox',
27
+ title: 'plugins/plugin-assistant/components/Toolbox',
28
28
  component: Toolbox as any,
29
29
  render: DefaultStory,
30
30
  decorators: [
31
- withTheme,
32
31
  withPluginManager({
33
32
  plugins: [
33
+ ...corePlugins(),
34
34
  ClientPlugin({
35
- onClientInitialized: async ({ client }) => {
36
- await client.halo.createIdentity();
37
- },
35
+ onClientInitialized: ({ client }) =>
36
+ Effect.gen(function* () {
37
+ yield* initializeIdentity(client);
38
+ }),
38
39
  }),
39
- SpacePlugin({}),
40
- SettingsPlugin(),
41
- IntentPlugin(),
42
40
  ChessPlugin(),
43
41
  MapPlugin(),
44
42
  TablePlugin(),
@@ -2,86 +2,91 @@
2
2
  // Copyright 2025 DXOS.org
3
3
  //
4
4
 
5
- import React, { type FC, Fragment, useEffect, useState } from 'react';
5
+ import React, { Fragment, useEffect, useState } from 'react';
6
6
 
7
- import { type Blueprint } from '@dxos/blueprints';
8
- import { type Ref } from '@dxos/echo';
9
- import { Function } from '@dxos/functions';
7
+ import { type Blueprint } from '@dxos/compute';
8
+ import { Operation } from '@dxos/compute';
9
+ import { type Database, Filter, type Ref } from '@dxos/echo';
10
10
  import { log } from '@dxos/log';
11
- import { Filter, type Space, useQuery } from '@dxos/react-client/echo';
12
- import { type ThemedClassName } from '@dxos/react-ui';
13
- import { useTranslation } from '@dxos/react-ui';
14
- import { mx } from '@dxos/react-ui-theme';
11
+ import { useQuery } from '@dxos/react-client/echo';
12
+ import { ScrollArea, type ThemedClassName } from '@dxos/react-ui';
13
+ import { composable, composableProps, mx } from '@dxos/ui-theme';
14
+
15
+ import { ServiceType } from '#types';
15
16
 
16
- import { meta } from '../../meta';
17
17
  import { type AiChatProcessor } from '../../processor';
18
- import { ServiceType } from '../../types';
19
18
 
20
- export type ToolboxProps = ThemedClassName<{
19
+ export type ToolboxProps = {
21
20
  services?: { service: ServiceType }[];
22
- functions?: Function.Function[];
21
+ functions?: Operation.PersistentOperation[];
23
22
  // TODO(burdon): Combine into single array.
24
- blueprints?: readonly Ref.Ref<Blueprint.Blueprint>[];
23
+ blueprints?: readonly Blueprint.Blueprint[];
25
24
  activeBlueprints?: readonly Ref.Ref<Blueprint.Blueprint>[];
26
- }>;
27
-
28
- export const Toolbox = ({ classNames, functions, services, blueprints, activeBlueprints }: ToolboxProps) => {
29
- const { t } = useTranslation(meta.id);
30
-
31
- return (
32
- <div className={mx('flex flex-col overflow-y-auto box-content', classNames)}>
33
- {blueprints && blueprints.length > 0 && (
34
- <Section
35
- title='Blueprints'
36
- items={blueprints.map(({ target }) => ({
37
- name: target?.name ?? '',
38
- description: target?.description ?? '',
39
- subitems: target?.tools.map((toolId) => ({ name: `∙ ${safeToolId(toolId)}` })),
40
- }))}
41
- />
42
- )}
43
-
44
- {activeBlueprints && activeBlueprints.length > 0 && (
45
- <Section
46
- title='Blueprints'
47
- items={activeBlueprints.map(({ target }) => ({
48
- name: target?.name ?? '',
49
- description: target?.description ?? '',
50
- subitems: target?.tools.map((toolId) => ({ name: `∙ ${safeToolId(toolId)}` })),
51
- }))}
52
- />
53
- )}
54
-
55
- {services && services.length > 0 && (
56
- <Section
57
- title='Services'
58
- items={services.map(({ service: { serviceId, name, description } }) => ({
59
- name: name ?? serviceId,
60
- description,
61
- // subitems: tools.map(({ name, description }) => ({ name: `∙ ${name}`, description })),
62
- }))}
63
- />
64
- )}
65
-
66
- {functions && functions.length > 0 && (
67
- <Section title='Functions' items={functions.map(({ name, description }) => ({ name, description }))} />
68
- )}
69
- </div>
70
- );
71
25
  };
72
26
 
73
- const Section: FC<{
27
+ export const Toolbox = composable<HTMLDivElement, ToolboxProps>(
28
+ ({ functions, services, blueprints, activeBlueprints, ...props }, forwardedRef) => {
29
+ return (
30
+ <ScrollArea.Root {...composableProps(props)} thin orientation='vertical' ref={forwardedRef}>
31
+ <ScrollArea.Viewport>
32
+ {blueprints && blueprints.length > 0 && (
33
+ <Section
34
+ title='Blueprints'
35
+ items={blueprints.map(({ name, description, tools }) => ({
36
+ name,
37
+ description,
38
+ subitems: tools.map((toolId) => ({ name: `∙ ${safeToolId(toolId)}` })),
39
+ }))}
40
+ />
41
+ )}
42
+
43
+ {activeBlueprints && activeBlueprints.length > 0 && (
44
+ <Section
45
+ title='Blueprints'
46
+ items={activeBlueprints.map(({ target }) => ({
47
+ name: target?.name ?? '',
48
+ description: target?.description ?? '',
49
+ subitems: target?.tools.map((toolId) => ({ name: `∙ ${safeToolId(toolId)}` })),
50
+ }))}
51
+ />
52
+ )}
53
+
54
+ {services && services.length > 0 && (
55
+ <Section
56
+ title='Services'
57
+ items={services.map(({ service: { serviceId, name, description } }) => ({
58
+ name: name ?? serviceId,
59
+ description,
60
+ // subitems: tools.map(({ name, description }) => ({ name: `∙ ${name}`, description })),
61
+ }))}
62
+ />
63
+ )}
64
+
65
+ {functions && functions.length > 0 && (
66
+ <Section title='Functions' items={functions.map(({ name, description }) => ({ name, description }))} />
67
+ )}
68
+ </ScrollArea.Viewport>
69
+ </ScrollArea.Root>
70
+ );
71
+ },
72
+ );
73
+
74
+ Toolbox.displayName = 'Toolbox';
75
+
76
+ type SectionProps = {
74
77
  title: string;
75
78
  items: { name: string; description?: string; subitems?: { name: string; description?: string }[] }[];
76
79
  striped?: boolean;
77
- }> = ({ title, items, striped }) => {
80
+ };
81
+
82
+ const Section = ({ title, items, striped }: SectionProps) => {
78
83
  const stripeClassNames = 'odd:bg-neutral-50 dark:odd:bg-neutral-800';
79
84
  const gridClassNames = 'grid grid-cols-[8rem_1fr]';
80
- const subGridClassNames = mx('col-span-full grid grid-cols-subgrid text-xs pli-2', striped && stripeClassNames);
85
+ const subGridClassNames = mx('col-span-full grid grid-cols-subgrid text-xs px-2', striped && stripeClassNames);
81
86
 
82
87
  return (
83
88
  <div>
84
- <h1 className='pli-2 text-sm'>{title}</h1>
89
+ <h1 className='px-2 text-sm'>{title}</h1>
85
90
  <div className={gridClassNames}>
86
91
  {items.map(({ name, description, subitems }, i) => (
87
92
  <Fragment key={i}>
@@ -104,14 +109,14 @@ const Section: FC<{
104
109
  );
105
110
  };
106
111
 
107
- export type ToolboxContainerProps = ThemedClassName<{
108
- space?: Space;
112
+ export type ToolboxPanelProps = ThemedClassName<{
113
+ db?: Database.Database;
109
114
  processor?: AiChatProcessor;
110
115
  }>;
111
116
 
112
- export const ToolboxContainer = ({ classNames, space, processor }: ToolboxContainerProps) => {
117
+ export const ToolboxPanel = ({ classNames, db, processor }: ToolboxPanelProps) => {
113
118
  // Registered services.
114
- const services = useQuery(space, Filter.type(ServiceType));
119
+ const services = useQuery(db, Filter.type(ServiceType));
115
120
  const [serviceTools, setServiceTools] = useState<{ service: ServiceType }[]>([]);
116
121
  useEffect(() => {
117
122
  log('creating service tools...', { services: services.length });
@@ -125,12 +130,12 @@ export const ToolboxContainer = ({ classNames, space, processor }: ToolboxContai
125
130
  }, [services]);
126
131
 
127
132
  // Deployed functions.
128
- const functions = useQuery(space, Filter.type(Function.Function));
133
+ const functions = useQuery(db, Filter.type(Operation.PersistentOperation));
129
134
 
130
135
  return (
131
136
  <Toolbox
132
137
  classNames={classNames}
133
- blueprints={processor?.context.blueprints.value}
138
+ blueprints={processor?.context.getBlueprints()}
134
139
  services={serviceTools}
135
140
  functions={functions}
136
141
  />
@@ -2,15 +2,14 @@
2
2
  // Copyright 2023 DXOS.org
3
3
  //
4
4
 
5
- import { lazy } from 'react';
5
+ import { type ComponentType, lazy } from 'react';
6
6
 
7
- export * from './AssistantSettings';
7
+ export * from './AgentProperties';
8
8
  export * from './Chat';
9
+ export * from './ProcessTree';
10
+ export * from './TaskList';
9
11
  export * from './TemplateEditor';
10
12
  export * from './Toolbox';
11
13
 
12
- export const BlueprintArticle = lazy(() => import('./BlueprintArticle'));
13
- export const ChatCompanion = lazy(() => import('./ChatCompanion'));
14
- export const ChatContainer = lazy(() => import('./ChatContainer'));
15
- export const ChatDialog = lazy(() => import('./ChatDialog'));
16
- export const PromptArticle = lazy(() => import('./PromptArticle'));
14
+ export const AssistantSettings: ComponentType<any> = lazy(() => import('./AssistantSettings'));
15
+ export const RoutineProperties: ComponentType<any> = lazy(() => import('./RoutineProperties'));
@@ -0,0 +1,120 @@
1
+ //
2
+ // Copyright 2026 DXOS.org
3
+ //
4
+
5
+ import { type Meta, type StoryObj } from '@storybook/react-vite';
6
+ import * as Effect from 'effect/Effect';
7
+ import React from 'react';
8
+
9
+ import { withPluginManager } from '@dxos/app-framework/testing';
10
+ import { Plan, Agent } from '@dxos/assistant-toolkit';
11
+ import { Filter, Obj, Ref } from '@dxos/echo';
12
+ import { AutomationPlugin } from '@dxos/plugin-automation/testing';
13
+ import { ClientPlugin } from '@dxos/plugin-client/testing';
14
+ import { initializeIdentity } from '@dxos/plugin-client/testing';
15
+ import { PreviewPlugin } from '@dxos/plugin-preview/testing';
16
+ import { StorybookPlugin, corePlugins } from '@dxos/plugin-testing';
17
+ import { random } from '@dxos/random';
18
+ import { useQuery, useSpaces } from '@dxos/react-client/echo';
19
+ import { Loading, withTheme } from '@dxos/react-ui/testing';
20
+ import { Text } from '@dxos/schema';
21
+ import { createObjectFactory, TypeSpec } from '@dxos/schema/testing';
22
+ import { Message, Organization, Person } from '@dxos/types';
23
+
24
+ import { createMessage } from '#testing';
25
+ import { translations } from '#translations';
26
+
27
+ import { AssistantPlugin } from '../../AssistantPlugin';
28
+ import { AgentArticle } from './AgentArticle';
29
+
30
+ random.seed(1);
31
+
32
+ type DefaultStoryProps = {
33
+ spec?: TypeSpec[];
34
+ inputs?: boolean;
35
+ };
36
+
37
+ const DefaultStory = (_: DefaultStoryProps) => {
38
+ const [space] = useSpaces();
39
+ const [agent] = useQuery(space?.db, Filter.type(Agent.Agent));
40
+ if (!agent) {
41
+ return <Loading />;
42
+ }
43
+
44
+ return <AgentArticle role='article' subject={agent} attendableId='story' />;
45
+ };
46
+
47
+ const meta = {
48
+ title: 'plugins/plugin-assistant/containers/AgentArticle',
49
+ render: DefaultStory,
50
+ decorators: [
51
+ withTheme(),
52
+ withPluginManager<DefaultStoryProps>(({ args: { spec = [], inputs } }) => ({
53
+ plugins: [
54
+ ...corePlugins(),
55
+ ClientPlugin({
56
+ types: [Agent.Agent, Message.Message, Plan.Plan, Text.Text, Organization.Organization, Person.Person],
57
+ onClientInitialized: ({ client }) =>
58
+ Effect.gen(function* () {
59
+ yield* initializeIdentity(client);
60
+ const [space] = client.spaces.get();
61
+ yield* Effect.promise(() => space.waitUntilReady());
62
+
63
+ const factory = createObjectFactory(space.db, random as any);
64
+ const artifacts = yield* Effect.promise(() => factory(spec));
65
+
66
+ const inputQueue = space.queues.create();
67
+ if (inputs) {
68
+ yield* Effect.promise(() =>
69
+ inputQueue.append([
70
+ createMessage('user', [{ _tag: 'text', text: 'Summarize the current artifacts.' }]),
71
+ createMessage('assistant', [
72
+ { _tag: 'text', text: 'Here is a quick overview of the organizations and contacts in context.' },
73
+ ]),
74
+ createMessage('user', [{ _tag: 'text', text: 'Flag anything that needs follow-up.' }]),
75
+ ]),
76
+ );
77
+ }
78
+
79
+ space.db.add(
80
+ Obj.make(Agent.Agent, {
81
+ instructions: Ref.make(Text.make()),
82
+ plan: Ref.make(Plan.makePlan({ tasks: [] })),
83
+ artifacts: artifacts.map((obj) => ({
84
+ name: Obj.getLabel(obj) ?? 'Artifact',
85
+ data: Ref.make(obj),
86
+ })),
87
+ feed: Ref.fromDXN(inputQueue.dxn),
88
+ subscriptions: [],
89
+ }),
90
+ );
91
+ }),
92
+ }),
93
+ AutomationPlugin(),
94
+ AssistantPlugin(),
95
+ PreviewPlugin(),
96
+ StorybookPlugin({}),
97
+ ],
98
+ })),
99
+ ],
100
+ parameters: {
101
+ layout: 'fullscreen',
102
+ translations,
103
+ },
104
+ } satisfies Meta<DefaultStoryProps>;
105
+
106
+ export default meta;
107
+
108
+ type Story = StoryObj<typeof meta>;
109
+
110
+ export const Default: Story = {
111
+ args: {
112
+ inputs: true,
113
+ spec: [
114
+ { type: Organization.Organization, count: 10 },
115
+ { type: Person.Person, count: 10 },
116
+ ],
117
+ },
118
+ };
119
+
120
+ export const Empty: Story = {};
@@ -0,0 +1,197 @@
1
+ //
2
+ // Copyright 2026 DXOS.org
3
+ //
4
+
5
+ import { Atom, useAtomValue } from '@effect-atom/atom-react';
6
+ import * as Effect from 'effect/Effect';
7
+ import * as Function from 'effect/Function';
8
+ import * as Option from 'effect/Option';
9
+ import React, { forwardRef, useCallback, useMemo, useState } from 'react';
10
+
11
+ import { Surface, useSpaceCallback } from '@dxos/app-framework/ui';
12
+ import { AppSurface, useObjectMenuItems } from '@dxos/app-toolkit/ui';
13
+ import { Agent } from '@dxos/assistant-toolkit';
14
+ import { Annotation, Database, Feed, Filter, Obj, Query, Ref } from '@dxos/echo';
15
+ import { AtomObj, AtomRef } from '@dxos/echo-atom';
16
+ import { QueueService } from '@dxos/functions';
17
+ import { useQuery } from '@dxos/react-client/echo';
18
+ import { Card, Message, Panel, ScrollArea, Toolbar, useTranslation } from '@dxos/react-ui';
19
+ import { Masonry } from '@dxos/react-ui-masonry';
20
+ import { Menu } from '@dxos/react-ui-menu';
21
+ import { Focus, Mosaic, type MosaicTileProps } from '@dxos/react-ui-mosaic';
22
+ import { composable } from '@dxos/ui-theme';
23
+ import { isNonNullable } from '@dxos/util';
24
+
25
+ import { meta } from '#meta';
26
+
27
+ type Tab = 'artifacts' | 'inputs';
28
+
29
+ export type AgentArticleProps = AppSurface.ObjectArticleProps<Agent.Agent>;
30
+
31
+ export const AgentArticle = ({ role, subject: agent }: AgentArticleProps) => {
32
+ const { t } = useTranslation(meta.id);
33
+ const [tab, setTab] = useState<Tab>('artifacts');
34
+ const [viewport, setViewport] = useState<HTMLElement | null>(null);
35
+
36
+ const spaceId = Obj.getDatabase(agent)?.spaceId;
37
+ // TODO(burdon): Clear input queue also.
38
+ const resetHistory = useSpaceCallback(
39
+ spaceId,
40
+ [QueueService, Feed.FeedService, Database.Service] as const,
41
+ Effect.fnUntraced(function* () {
42
+ yield* Agent.resetChatHistory(agent);
43
+ if (!agent.feed) {
44
+ const queue = yield* QueueService.createQueue();
45
+ Obj.update(agent, (agent) => {
46
+ agent.feed = Ref.fromDXN(queue.dxn);
47
+ });
48
+ }
49
+ }),
50
+ [agent],
51
+ );
52
+ const handleResetHistory = useCallback(async () => {
53
+ await resetHistory();
54
+ }, [resetHistory]);
55
+
56
+ const artifacts = useAtomValue(
57
+ useMemo(
58
+ () =>
59
+ AtomObj.make(agent).pipe((agent) =>
60
+ Atom.make((get) => {
61
+ return get(agent)
62
+ .artifacts.map((artifact) => get(AtomRef.make(artifact.data)))
63
+ .filter(isNonNullable);
64
+ }),
65
+ ),
66
+ [agent],
67
+ ),
68
+ );
69
+
70
+ const inputFeed = useAtomValue(
71
+ AtomObj.make(agent).pipe((_) =>
72
+ Atom.make((get) =>
73
+ Option.fromNullable(get(_).feed).pipe(Option.map(AtomRef.make), Option.map(get), Option.getOrUndefined),
74
+ ),
75
+ ),
76
+ );
77
+
78
+ const db = Obj.getDatabase(agent);
79
+ const inputObjects = useQuery(
80
+ db,
81
+ inputFeed ? Query.select(Filter.everything()).from(inputFeed) : Query.select(Filter.nothing()),
82
+ );
83
+
84
+ return (
85
+ <Panel.Root role={role}>
86
+ <Panel.Toolbar asChild>
87
+ <Toolbar.Root>
88
+ <Toolbar.ToggleGroup type='single' value={tab} onValueChange={(value) => value && setTab(value as Tab)}>
89
+ <Toolbar.ToggleGroupIconItem value='artifacts' label={t('artifacts.label')} icon='ph--cube--regular' />
90
+ <Toolbar.ToggleGroupIconItem value='inputs' label={t('inputs.label')} icon='ph--queue--regular' />
91
+ </Toolbar.ToggleGroup>
92
+ <Toolbar.Separator />
93
+ <Toolbar.IconButton
94
+ icon='ph--trash--regular'
95
+ label={t('reset-history.button')}
96
+ onCanPlay={handleResetHistory}
97
+ />
98
+ </Toolbar.Root>
99
+ </Panel.Toolbar>
100
+ <Panel.Content className='dx-container flex flex-col'>
101
+ {tab === 'artifacts' && (
102
+ <>
103
+ {artifacts.length === 0 && (
104
+ <Message.Root classNames='m-2' valence='info'>
105
+ <Message.Title>{t('project-empty-spec.message')}</Message.Title>
106
+ <Message.Content>{t('project-empty-spec.description')}</Message.Content>
107
+ </Message.Root>
108
+ )}
109
+
110
+ <Masonry.Root Tile={MasonryArtifactTile}>
111
+ <Masonry.Content padding thin centered>
112
+ <Masonry.Viewport items={artifacts} getId={(item: Obj.Unknown) => item.id} />
113
+ </Masonry.Content>
114
+ </Masonry.Root>
115
+ </>
116
+ )}
117
+
118
+ {tab === 'inputs' && (
119
+ <Mosaic.Container asChild withFocus autoScroll={viewport} classNames='dx-document'>
120
+ <ScrollArea.Root orientation='vertical' padding thin centered>
121
+ <ScrollArea.Viewport ref={setViewport}>
122
+ <Mosaic.VirtualStack
123
+ Tile={StackTile}
124
+ classNames='gap-2'
125
+ draggable={false}
126
+ estimateSize={() => 160}
127
+ gap={8}
128
+ getId={(item: Obj.Unknown) => item.id}
129
+ getScrollElement={() => viewport}
130
+ items={inputObjects}
131
+ />
132
+ </ScrollArea.Viewport>
133
+ </ScrollArea.Root>
134
+ </Mosaic.Container>
135
+ )}
136
+ </Panel.Content>
137
+ </Panel.Root>
138
+ );
139
+ };
140
+
141
+ const ArtifactTileCard = composable<HTMLDivElement, { data: Obj.Unknown }>(({ data, ...props }, forwardedRef) => {
142
+ const objectMenuItems = useObjectMenuItems(data);
143
+ const icon = Function.pipe(
144
+ Obj.getSchema(data),
145
+ Option.fromNullable,
146
+ Option.flatMap(Annotation.IconAnnotation.get),
147
+ Option.map(({ icon }) => icon),
148
+ Option.getOrElse(() => 'ph--placeholder--regular'),
149
+ );
150
+
151
+ return (
152
+ <Card.Root {...props} ref={forwardedRef} data-testid='board-item' fullWidth>
153
+ <Card.Toolbar>
154
+ <Card.IconBlock padding>
155
+ <Card.Icon icon={icon} />
156
+ </Card.IconBlock>
157
+ <Card.Title>{Obj.getLabel(data)}</Card.Title>
158
+ {/* TODO(wittjosiah): Reconcile with Card.Menu. */}
159
+ <Card.IconBlock padding>
160
+ <Menu.Trigger asChild disabled={!objectMenuItems?.length}>
161
+ <Toolbar.IconButton iconOnly variant='ghost' icon='ph--dots-three-vertical--regular' label='Actions' />
162
+ </Menu.Trigger>
163
+ <Menu.Content items={objectMenuItems} />
164
+ </Card.IconBlock>
165
+ </Card.Toolbar>
166
+ <Card.Content>
167
+ <Surface.Surface
168
+ type={AppSurface.Card}
169
+ limit={1}
170
+ data={{ subject: data } satisfies AppSurface.ObjectCardData}
171
+ />
172
+ </Card.Content>
173
+ </Card.Root>
174
+ );
175
+ });
176
+
177
+ ArtifactTileCard.displayName = 'ArtifactTileCard';
178
+
179
+ const MasonryArtifactTile = ({ data }: { data: Obj.Unknown; index: number }) => (
180
+ <Menu.Root>
181
+ <ArtifactTileCard data={data} />
182
+ </Menu.Root>
183
+ );
184
+
185
+ const StackTile = forwardRef<HTMLDivElement, MosaicTileProps<Obj.Unknown>>(
186
+ ({ data, location, debug, current }, forwardedRef) => (
187
+ <Menu.Root>
188
+ <Mosaic.Tile asChild id={data.id} data={data} location={location} debug={debug}>
189
+ <Focus.Item asChild current={current}>
190
+ <ArtifactTileCard ref={forwardedRef} data={data} />
191
+ </Focus.Item>
192
+ </Mosaic.Tile>
193
+ </Menu.Root>
194
+ ),
195
+ );
196
+
197
+ StackTile.displayName = 'StackTile';
@@ -0,0 +1,5 @@
1
+ //
2
+ // Copyright 2026 DXOS.org
3
+ //
4
+
5
+ export { AgentArticle as default } from './AgentArticle';
@@ -0,0 +1,43 @@
1
+ //
2
+ // Copyright 2025 DXOS.org
3
+ //
4
+
5
+ import React, { useEffect } from 'react';
6
+
7
+ import { useSpaceCallback } from '@dxos/app-framework/ui';
8
+ import { type AppSurface } from '@dxos/app-toolkit/ui';
9
+ import { Agent, SyncTriggers } from '@dxos/assistant-toolkit';
10
+ import { Operation } from '@dxos/compute';
11
+ import { Obj, Ref } from '@dxos/echo';
12
+ import { log } from '@dxos/log';
13
+
14
+ import { AgentProperties as AgentPropertiesComponent } from '#components';
15
+
16
+ export type AgentPropertiesProps = AppSurface.ObjectPropertiesProps<Agent.Agent>;
17
+
18
+ export const AgentProperties = ({ subject: agent }: AgentPropertiesProps) => {
19
+ const spaceId = Obj.getDatabase(agent)?.spaceId;
20
+
21
+ // TODO(burdon): Factor this out?
22
+ const syncTriggers = useSpaceCallback(
23
+ spaceId,
24
+ [] as const,
25
+ () => Operation.invoke(SyncTriggers, { agent: Ref.make(agent) }),
26
+ [agent],
27
+ );
28
+
29
+ // Sync triggers whenever the agent mutates (e.g., subscriptions change).
30
+ useEffect(() => {
31
+ if (!spaceId) {
32
+ return;
33
+ }
34
+
35
+ return Obj.subscribe(agent, () => {
36
+ queueMicrotask(() => {
37
+ syncTriggers().catch((err) => log.catch(err));
38
+ });
39
+ });
40
+ }, [spaceId, agent, syncTriggers]);
41
+
42
+ return <AgentPropertiesComponent agent={agent} />;
43
+ };
@@ -0,0 +1,5 @@
1
+ //
2
+ // Copyright 2026 DXOS.org
3
+ //
4
+
5
+ export { AgentProperties as default } from './AgentProperties';
@@ -0,0 +1,29 @@
1
+ //
2
+ // Copyright 2025 DXOS.org
3
+ //
4
+
5
+ import React from 'react';
6
+
7
+ import { type AppSurface } from '@dxos/app-toolkit/ui';
8
+ import { type Blueprint } from '@dxos/compute';
9
+ import { Panel, Toolbar } from '@dxos/react-ui';
10
+ import { useAttention } from '@dxos/react-ui-attention';
11
+
12
+ import { TemplateEditor } from '#components';
13
+
14
+ export type BlueprintArticleProps = AppSurface.ObjectArticleProps<Blueprint.Blueprint>;
15
+
16
+ export const BlueprintArticle = ({ role, attendableId, subject }: BlueprintArticleProps) => {
17
+ const { hasAttention } = useAttention(attendableId);
18
+
19
+ return (
20
+ <Panel.Root role={role} classNames='dx-document'>
21
+ <Panel.Toolbar asChild>
22
+ <Toolbar.Root disabled={!hasAttention} />
23
+ </Panel.Toolbar>
24
+ <Panel.Content asChild>
25
+ <TemplateEditor id={subject.id} template={subject.instructions} />
26
+ </Panel.Content>
27
+ </Panel.Root>
28
+ );
29
+ };
@@ -0,0 +1,5 @@
1
+ //
2
+ // Copyright 2025 DXOS.org
3
+ //
4
+
5
+ export { BlueprintArticle as default } from './BlueprintArticle';