@dxos/plugin-assistant 0.8.4-main.9be5663bfe → 0.8.4-main.abd8ff62ef
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.
- package/dist/lib/browser/AssistantSettings-GG52BLKS.mjs +40 -0
- package/dist/lib/browser/AssistantSettings-GG52BLKS.mjs.map +7 -0
- package/dist/lib/browser/blueprints/index.mjs +26 -3
- package/dist/lib/browser/blueprints/index.mjs.map +4 -4
- package/dist/lib/browser/{chunk-ATHYBVGN.mjs → chunk-DVOOFAWU.mjs} +4 -5
- package/dist/lib/browser/chunk-DVOOFAWU.mjs.map +7 -0
- package/dist/lib/browser/chunk-M55MBYG7.mjs +932 -0
- package/dist/lib/browser/chunk-M55MBYG7.mjs.map +7 -0
- package/dist/lib/browser/{chunk-RUV2WOQH.mjs → chunk-SEMCG4ZK.mjs} +58 -17
- package/dist/lib/browser/chunk-SEMCG4ZK.mjs.map +7 -0
- package/dist/lib/browser/chunk-VK53MITK.mjs +2300 -0
- package/dist/lib/browser/chunk-VK53MITK.mjs.map +7 -0
- package/dist/lib/browser/cli/index.mjs +73 -0
- package/dist/lib/browser/cli/index.mjs.map +7 -0
- package/dist/lib/browser/components/index.mjs +20 -0
- package/dist/lib/browser/components/index.mjs.map +7 -0
- package/dist/lib/browser/{create-chat-LBZHGVSN.mjs → create-chat-E2ZLVTLP.mjs} +4 -13
- package/dist/lib/browser/create-chat-E2ZLVTLP.mjs.map +7 -0
- package/dist/lib/browser/{ensure-companion-chat-FR4AWZ2P.mjs → ensure-companion-chat-7GDMXSQW.mjs} +4 -4
- package/dist/lib/browser/ensure-companion-chat-7GDMXSQW.mjs.map +7 -0
- package/dist/lib/browser/hooks/index.mjs +39 -0
- package/dist/lib/browser/hooks/index.mjs.map +7 -0
- package/dist/lib/browser/index.mjs +43 -3233
- package/dist/lib/browser/index.mjs.map +4 -4
- package/dist/lib/browser/meta.json +1 -1
- package/dist/lib/browser/{on-create-space-54RNX5JI.mjs → on-create-space-4J3KTNAJ.mjs} +3 -3
- package/dist/lib/browser/{on-create-space-54RNX5JI.mjs.map → on-create-space-4J3KTNAJ.mjs.map} +1 -1
- package/dist/lib/browser/operations/index.mjs +3 -3
- package/dist/lib/browser/operations/index.mjs.map +3 -3
- package/dist/lib/browser/{resolve-navigation-targets-NZOD66NY.mjs → resolve-navigation-targets-3ZPQE6SZ.mjs} +3 -3
- package/dist/lib/browser/{resolve-navigation-targets-NZOD66NY.mjs.map → resolve-navigation-targets-3ZPQE6SZ.mjs.map} +1 -1
- package/dist/lib/browser/{run-prompt-in-new-chat-4YQ37XIS.mjs → run-prompt-in-new-chat-AA3KPBDN.mjs} +9 -39
- package/dist/lib/browser/run-prompt-in-new-chat-AA3KPBDN.mjs.map +7 -0
- package/dist/lib/browser/{set-current-chat-WJI3WAVM.mjs → set-current-chat-P4VHI3YF.mjs} +4 -4
- package/dist/lib/browser/set-current-chat-P4VHI3YF.mjs.map +7 -0
- package/dist/lib/browser/translations.mjs +172 -0
- package/dist/lib/browser/translations.mjs.map +7 -0
- package/dist/lib/browser/types/index.mjs +1 -3
- package/dist/lib/browser/{update-chat-name-3Y36KFAS.mjs → update-chat-name-VWKNUON7.mjs} +7 -22
- package/dist/lib/browser/update-chat-name-VWKNUON7.mjs.map +7 -0
- package/dist/lib/node-esm/AssistantSettings-23A5IMHS.mjs +41 -0
- package/dist/lib/node-esm/AssistantSettings-23A5IMHS.mjs.map +7 -0
- package/dist/lib/node-esm/blueprints/index.mjs +26 -3
- package/dist/lib/node-esm/blueprints/index.mjs.map +4 -4
- package/dist/lib/node-esm/chunk-FWC3ZGPH.mjs +933 -0
- package/dist/lib/node-esm/chunk-FWC3ZGPH.mjs.map +7 -0
- package/dist/lib/node-esm/chunk-JKEB3NFZ.mjs +2302 -0
- package/dist/lib/node-esm/chunk-JKEB3NFZ.mjs.map +7 -0
- package/dist/lib/node-esm/{chunk-PXAJSTGZ.mjs → chunk-MBDVPB4V.mjs} +4 -5
- package/dist/lib/node-esm/chunk-MBDVPB4V.mjs.map +7 -0
- package/dist/lib/node-esm/{chunk-PY4X6FJT.mjs → chunk-XAFVSEUJ.mjs} +58 -17
- package/dist/lib/node-esm/chunk-XAFVSEUJ.mjs.map +7 -0
- package/dist/lib/node-esm/cli/index.mjs +74 -0
- package/dist/lib/node-esm/cli/index.mjs.map +7 -0
- package/dist/lib/node-esm/components/index.mjs +21 -0
- package/dist/lib/node-esm/components/index.mjs.map +7 -0
- package/dist/lib/node-esm/{create-chat-3BEG4R6J.mjs → create-chat-UQQ3542N.mjs} +4 -13
- package/dist/lib/node-esm/create-chat-UQQ3542N.mjs.map +7 -0
- package/dist/lib/node-esm/{ensure-companion-chat-BLP7NT32.mjs → ensure-companion-chat-LVCPD4DJ.mjs} +4 -4
- package/dist/lib/node-esm/ensure-companion-chat-LVCPD4DJ.mjs.map +7 -0
- package/dist/lib/node-esm/hooks/index.mjs +40 -0
- package/dist/lib/node-esm/hooks/index.mjs.map +7 -0
- package/dist/lib/node-esm/index.mjs +43 -3233
- package/dist/lib/node-esm/index.mjs.map +4 -4
- package/dist/lib/node-esm/meta.json +1 -1
- package/dist/lib/node-esm/{on-create-space-YRPZ6HZY.mjs → on-create-space-M63UBTTT.mjs} +3 -3
- package/dist/lib/node-esm/{on-create-space-YRPZ6HZY.mjs.map → on-create-space-M63UBTTT.mjs.map} +1 -1
- package/dist/lib/node-esm/operations/index.mjs +3 -3
- package/dist/lib/node-esm/operations/index.mjs.map +3 -3
- package/dist/lib/node-esm/{resolve-navigation-targets-3PPK7XLH.mjs → resolve-navigation-targets-HO77CAFT.mjs} +3 -3
- package/dist/lib/node-esm/{resolve-navigation-targets-3PPK7XLH.mjs.map → resolve-navigation-targets-HO77CAFT.mjs.map} +1 -1
- package/dist/lib/node-esm/{run-prompt-in-new-chat-2IJBSDTM.mjs → run-prompt-in-new-chat-RIRYYYPK.mjs} +9 -39
- package/dist/lib/node-esm/run-prompt-in-new-chat-RIRYYYPK.mjs.map +7 -0
- package/dist/lib/node-esm/{set-current-chat-KBMMZULR.mjs → set-current-chat-Z7GJ52VX.mjs} +4 -4
- package/dist/lib/node-esm/set-current-chat-Z7GJ52VX.mjs.map +7 -0
- package/dist/lib/node-esm/translations.mjs +173 -0
- package/dist/lib/node-esm/translations.mjs.map +7 -0
- package/dist/lib/node-esm/types/index.mjs +1 -3
- package/dist/lib/node-esm/{update-chat-name-HM2P4NSI.mjs → update-chat-name-GV4HX32Z.mjs} +7 -22
- package/dist/lib/node-esm/update-chat-name-GV4HX32Z.mjs.map +7 -0
- package/dist/types/src/AssistantPlugin.d.ts +1 -0
- package/dist/types/src/AssistantPlugin.d.ts.map +1 -1
- package/dist/types/src/AssistantPlugin.node.d.ts +4 -0
- package/dist/types/src/AssistantPlugin.node.d.ts.map +1 -0
- package/dist/types/src/AssistantPlugin.test.d.ts +2 -0
- package/dist/types/src/AssistantPlugin.test.d.ts.map +1 -0
- package/dist/types/src/blueprints/assistant/blueprint.d.ts +2 -2
- package/dist/types/src/blueprints/assistant/blueprint.d.ts.map +1 -1
- package/dist/types/src/capabilities/ai-service.d.ts.map +1 -1
- package/dist/types/src/capabilities/app-graph-builder.d.ts.map +1 -1
- package/dist/types/src/capabilities/blueprint-definition.d.ts.map +1 -1
- package/dist/types/src/capabilities/companion-chat-provisioner.d.ts.map +1 -1
- package/dist/types/src/capabilities/edge-model-resolver.d.ts.map +1 -1
- package/dist/types/src/capabilities/index.d.ts +5 -17
- package/dist/types/src/capabilities/index.d.ts.map +1 -1
- package/dist/types/src/capabilities/local-model-resolver.d.ts +6 -3
- package/dist/types/src/capabilities/local-model-resolver.d.ts.map +1 -1
- package/dist/types/src/capabilities/markdown.d.ts +1 -1
- package/dist/types/src/capabilities/markdown.d.ts.map +1 -1
- package/dist/types/src/capabilities/migrations.d.ts +1 -1
- package/dist/types/src/capabilities/migrations.d.ts.map +1 -1
- package/dist/types/src/capabilities/operation-handler.d.ts +1 -1
- package/dist/types/src/capabilities/operation-handler.d.ts.map +1 -1
- package/dist/types/src/capabilities/react-surface.d.ts.map +1 -1
- package/dist/types/src/capabilities/settings.d.ts +1 -13
- package/dist/types/src/capabilities/settings.d.ts.map +1 -1
- package/dist/types/src/capabilities/state.d.ts.map +1 -1
- package/dist/types/src/capabilities/toolkit.d.ts.map +1 -1
- package/dist/types/src/cli/index.d.ts +2 -0
- package/dist/types/src/cli/index.d.ts.map +1 -0
- package/dist/types/src/cli/plugin.d.ts +10 -0
- package/dist/types/src/cli/plugin.d.ts.map +1 -0
- package/dist/types/src/components/AssistantSettings/AssistantSettings.d.ts +1 -1
- package/dist/types/src/components/AssistantSettings/AssistantSettings.d.ts.map +1 -1
- package/dist/types/src/components/AssistantSettings/AssistantSettings.stories.d.ts +1 -539
- package/dist/types/src/components/AssistantSettings/AssistantSettings.stories.d.ts.map +1 -1
- package/dist/types/src/components/Chat/Chat.d.ts +32 -42
- package/dist/types/src/components/Chat/Chat.d.ts.map +1 -1
- package/dist/types/src/components/Chat/context.d.ts +29 -0
- package/dist/types/src/components/Chat/context.d.ts.map +1 -0
- package/dist/types/src/components/ChatPrompt/ChatActions.d.ts.map +1 -1
- package/dist/types/src/components/ChatPrompt/ChatMcpErrors.d.ts +12 -0
- package/dist/types/src/components/ChatPrompt/ChatMcpErrors.d.ts.map +1 -0
- package/dist/types/src/components/ChatPrompt/ChatOptions.d.ts +6 -2
- package/dist/types/src/components/ChatPrompt/ChatOptions.d.ts.map +1 -1
- package/dist/types/src/components/ChatPrompt/ChatOptions.stories.d.ts +19 -0
- package/dist/types/src/components/ChatPrompt/ChatOptions.stories.d.ts.map +1 -0
- package/dist/types/src/components/ChatPrompt/ChatPresets.d.ts.map +1 -1
- package/dist/types/src/components/ChatPrompt/ChatPrompt.d.ts +28 -0
- package/dist/types/src/components/ChatPrompt/ChatPrompt.d.ts.map +1 -0
- package/dist/types/src/components/ChatPrompt/ChatReferences.d.ts.map +1 -1
- package/dist/types/src/components/ChatPrompt/ChatStatus.d.ts +20 -0
- package/dist/types/src/components/ChatPrompt/ChatStatus.d.ts.map +1 -0
- package/dist/types/src/components/ChatPrompt/ChatStatusIndicator.d.ts.map +1 -1
- package/dist/types/src/components/ChatPrompt/index.d.ts +3 -0
- package/dist/types/src/components/ChatPrompt/index.d.ts.map +1 -1
- package/dist/types/src/components/ChatThread/Anchor.stories.d.ts +14 -0
- package/dist/types/src/components/ChatThread/Anchor.stories.d.ts.map +1 -0
- package/dist/types/src/components/ChatThread/ChatThread.d.ts +6 -3
- package/dist/types/src/components/ChatThread/ChatThread.d.ts.map +1 -1
- package/dist/types/src/components/ChatThread/ChatThread.stories.d.ts +4 -541
- package/dist/types/src/components/ChatThread/ChatThread.stories.d.ts.map +1 -1
- package/dist/types/src/components/ChatThread/Link.d.ts.map +1 -1
- package/dist/types/src/components/ChatThread/MarkdownStream.stories.d.ts +9 -540
- package/dist/types/src/components/ChatThread/MarkdownStream.stories.d.ts.map +1 -1
- package/dist/types/src/components/ChatThread/registry.d.ts +18 -0
- package/dist/types/src/components/ChatThread/registry.d.ts.map +1 -1
- package/dist/types/src/components/ChatThread/sync.d.ts +40 -14
- package/dist/types/src/components/ChatThread/sync.d.ts.map +1 -1
- package/dist/types/src/components/ChatThread/tool-widget-state.d.ts.map +1 -1
- package/dist/types/src/components/ChatThread/widgets/FallbackWidget.d.ts +4 -4
- package/dist/types/src/components/ChatThread/widgets/FallbackWidget.d.ts.map +1 -1
- package/dist/types/src/components/ChatThread/widgets/ReasoningWidget.d.ts.map +1 -1
- package/dist/types/src/components/ChatThread/widgets/ReasoningWidget.stories.d.ts.map +1 -1
- package/dist/types/src/components/ChatThread/widgets/ReferenceWidget.d.ts.map +1 -1
- package/dist/types/src/components/ChatThread/widgets/SelectWidget.d.ts.map +1 -1
- package/dist/types/src/components/ChatThread/widgets/StatsWidget.d.ts.map +1 -1
- package/dist/types/src/components/ChatThread/widgets/StatusWidget.d.ts.map +1 -1
- package/dist/types/src/components/ChatThread/widgets/SuggestionWidget.d.ts.map +1 -1
- package/dist/types/src/components/ChatThread/widgets/SummaryWidget.d.ts.map +1 -1
- package/dist/types/src/components/ChatThread/widgets/ToolWidget.d.ts.map +1 -1
- package/dist/types/src/components/ChatThread/widgets/ToolWidget.stories.d.ts +1 -539
- package/dist/types/src/components/ChatThread/widgets/ToolWidget.stories.d.ts.map +1 -1
- package/dist/types/src/components/ChatThread/widgets/defaults.d.ts +5 -0
- package/dist/types/src/components/ChatThread/widgets/defaults.d.ts.map +1 -0
- package/dist/types/src/components/ChatThread/widgets/index.d.ts +1 -2
- package/dist/types/src/components/ChatThread/widgets/index.d.ts.map +1 -1
- package/dist/types/src/components/ProcessTree/ProcessTree.d.ts +2 -1
- package/dist/types/src/components/ProcessTree/ProcessTree.d.ts.map +1 -1
- package/dist/types/src/components/ProcessTree/ProcessTree.stories.d.ts +0 -1
- package/dist/types/src/components/ProcessTree/ProcessTree.stories.d.ts.map +1 -1
- package/dist/types/src/components/TemplateEditor/TemplateEditor.d.ts +2 -2
- package/dist/types/src/components/TemplateEditor/TemplateEditor.d.ts.map +1 -1
- package/dist/types/src/components/TemplateEditor/TemplateEditor.stories.d.ts +1 -539
- package/dist/types/src/components/TemplateEditor/TemplateEditor.stories.d.ts.map +1 -1
- package/dist/types/src/components/TemplateEditor/TemplateForm.d.ts +3 -3
- package/dist/types/src/components/TemplateEditor/TemplateForm.d.ts.map +1 -1
- package/dist/types/src/components/TemplateEditor/TemplateForm.stories.d.ts +1 -539
- package/dist/types/src/components/TemplateEditor/TemplateForm.stories.d.ts.map +1 -1
- package/dist/types/src/components/TemplateEditor/extensions/handlebars-extension.d.ts.map +1 -1
- package/dist/types/src/components/TemplateEditor/extensions/xml-extension.d.ts.map +1 -1
- package/dist/types/src/components/ToolBlock/ToolBlock.d.ts +4 -4
- package/dist/types/src/components/ToolBlock/ToolBlock.d.ts.map +1 -1
- package/dist/types/src/components/Toolbox/Toolbox.d.ts +3 -3
- package/dist/types/src/components/Toolbox/Toolbox.d.ts.map +1 -1
- package/dist/types/src/components/Toolbox/Toolbox.stories.d.ts +1 -539
- package/dist/types/src/components/Toolbox/Toolbox.stories.d.ts.map +1 -1
- package/dist/types/src/containers/AgentArticle/AgentArticle.d.ts +2 -2
- package/dist/types/src/containers/AgentArticle/AgentArticle.d.ts.map +1 -1
- package/dist/types/src/containers/AgentArticle/AgentArticle.stories.d.ts +7 -540
- package/dist/types/src/containers/AgentArticle/AgentArticle.stories.d.ts.map +1 -1
- package/dist/types/src/containers/AgentProperties/AgentProperties.d.ts +1 -1
- package/dist/types/src/containers/AgentProperties/AgentProperties.d.ts.map +1 -1
- package/dist/types/src/containers/AgentProperties/AgentProperties.stories.d.ts +1 -539
- package/dist/types/src/containers/AgentProperties/AgentProperties.stories.d.ts.map +1 -1
- package/dist/types/src/containers/BlueprintArticle/BlueprintArticle.d.ts +1 -1
- package/dist/types/src/containers/BlueprintArticle/BlueprintArticle.d.ts.map +1 -1
- package/dist/types/src/containers/ChatCompanion/ChatCompanion.d.ts +1 -1
- package/dist/types/src/containers/ChatContainer/ChatContainer.d.ts.map +1 -1
- package/dist/types/src/containers/ChatDialog/ChatDialog.d.ts.map +1 -1
- package/dist/types/src/containers/RoutineArticle/RoutineArticle.d.ts +6 -0
- package/dist/types/src/containers/RoutineArticle/RoutineArticle.d.ts.map +1 -0
- package/dist/types/src/containers/RoutineArticle/index.d.ts +2 -0
- package/dist/types/src/containers/RoutineArticle/index.d.ts.map +1 -0
- package/dist/types/src/containers/RoutineList/RoutineList.d.ts +6 -0
- package/dist/types/src/containers/RoutineList/RoutineList.d.ts.map +1 -0
- package/dist/types/src/containers/RoutineList/RoutineList.stories.d.ts +21 -0
- package/dist/types/src/containers/RoutineList/RoutineList.stories.d.ts.map +1 -0
- package/dist/types/src/containers/RoutineList/index.d.ts +2 -0
- package/dist/types/src/containers/RoutineList/index.d.ts.map +1 -0
- package/dist/types/src/containers/TracePanel/TracePanel.d.ts +6 -4
- package/dist/types/src/containers/TracePanel/TracePanel.d.ts.map +1 -1
- package/dist/types/src/containers/TracePanel/TracePanel.stories.d.ts +13 -0
- package/dist/types/src/containers/TracePanel/TracePanel.stories.d.ts.map +1 -0
- package/dist/types/src/containers/TracePanel/dxn-extractor.d.ts +1 -1
- package/dist/types/src/containers/TracePanel/dxn-extractor.d.ts.map +1 -1
- package/dist/types/src/containers/TracePanel/execution-graph.d.ts +97 -0
- package/dist/types/src/containers/TracePanel/execution-graph.d.ts.map +1 -0
- package/dist/types/src/containers/TracePanel/execution-graph.test.d.ts +2 -0
- package/dist/types/src/containers/TracePanel/execution-graph.test.d.ts.map +1 -0
- package/dist/types/src/containers/TracePanel/index.d.ts.map +1 -1
- package/dist/types/src/containers/TracePanel/testing/index.d.ts +3 -0
- package/dist/types/src/containers/TracePanel/testing/index.d.ts.map +1 -0
- package/dist/types/src/containers/TracePanel/testing/simulated-agent.d.ts +14 -0
- package/dist/types/src/containers/TracePanel/testing/simulated-agent.d.ts.map +1 -0
- package/dist/types/src/containers/TracePanel/testing/snapshot-playback.d.ts +12 -0
- package/dist/types/src/containers/TracePanel/testing/snapshot-playback.d.ts.map +1 -0
- package/dist/types/src/containers/TriggerStatus/TriggerStatus.d.ts +3 -2
- package/dist/types/src/containers/TriggerStatus/TriggerStatus.d.ts.map +1 -1
- package/dist/types/src/containers/TriggerStatus/index.d.ts +1 -1
- package/dist/types/src/containers/TriggerStatus/index.d.ts.map +1 -1
- package/dist/types/src/containers/index.d.ts +2 -2
- package/dist/types/src/containers/index.d.ts.map +1 -1
- package/dist/types/src/extensions/prompt-extension.d.ts.map +1 -1
- package/dist/types/src/hooks/index.d.ts +2 -0
- package/dist/types/src/hooks/index.d.ts.map +1 -1
- package/dist/types/src/hooks/useBlueprintRegistry.d.ts +1 -1
- package/dist/types/src/hooks/useBlueprintRegistry.d.ts.map +1 -1
- package/dist/types/src/hooks/useChatKeymap.d.ts +12 -0
- package/dist/types/src/hooks/useChatKeymap.d.ts.map +1 -0
- package/dist/types/src/hooks/useChatProcessor.d.ts +1 -1
- package/dist/types/src/hooks/useChatProcessor.d.ts.map +1 -1
- package/dist/types/src/hooks/useChatServices.d.ts.map +1 -1
- package/dist/types/src/hooks/useChatToolbarActions.d.ts.map +1 -1
- package/dist/types/src/hooks/useContextBinder.d.ts.map +1 -1
- package/dist/types/src/hooks/useContextObjects.d.ts.map +1 -1
- package/dist/types/src/hooks/useDebug.d.ts +10 -0
- package/dist/types/src/hooks/useDebug.d.ts.map +1 -0
- package/dist/types/src/hooks/useFilteredTypes.d.ts.map +1 -1
- package/dist/types/src/hooks/useFlush.d.ts +1 -1
- package/dist/types/src/hooks/useFlush.d.ts.map +1 -1
- package/dist/types/src/hooks/usePresets.d.ts.map +1 -1
- package/dist/types/src/hooks/useReferencesProvider.d.ts.map +1 -1
- package/dist/types/src/index.d.ts +3 -5
- package/dist/types/src/index.d.ts.map +1 -1
- package/dist/types/src/operations/create-chat.d.ts +1 -1
- package/dist/types/src/operations/create-chat.d.ts.map +1 -1
- package/dist/types/src/operations/definitions.d.ts +24 -19
- package/dist/types/src/operations/definitions.d.ts.map +1 -1
- package/dist/types/src/operations/ensure-companion-chat.d.ts +1 -1
- package/dist/types/src/operations/ensure-companion-chat.d.ts.map +1 -1
- package/dist/types/src/operations/index.d.ts +1 -1
- package/dist/types/src/operations/index.d.ts.map +1 -1
- package/dist/types/src/operations/on-create-space.d.ts +1 -1
- package/dist/types/src/operations/on-create-space.d.ts.map +1 -1
- package/dist/types/src/operations/prompt.test.d.ts +2 -0
- package/dist/types/src/operations/prompt.test.d.ts.map +1 -0
- package/dist/types/src/operations/resolve-navigation-targets.d.ts +1 -1
- package/dist/types/src/operations/resolve-navigation-targets.d.ts.map +1 -1
- package/dist/types/src/operations/run-prompt-in-new-chat.d.ts +1 -1
- package/dist/types/src/operations/run-prompt-in-new-chat.d.ts.map +1 -1
- package/dist/types/src/operations/set-current-chat.d.ts +1 -1
- package/dist/types/src/operations/set-current-chat.d.ts.map +1 -1
- package/dist/types/src/operations/update-chat-name.d.ts +1 -1
- package/dist/types/src/operations/update-chat-name.d.ts.map +1 -1
- package/dist/types/src/processor/presets.d.ts +1 -1
- package/dist/types/src/processor/presets.d.ts.map +1 -1
- package/dist/types/src/processor/processor.d.ts +25 -7
- package/dist/types/src/processor/processor.d.ts.map +1 -1
- package/dist/types/src/queue-logger.d.ts.map +1 -1
- package/dist/types/src/testing/index.d.ts +1 -0
- package/dist/types/src/testing/index.d.ts.map +1 -1
- package/dist/types/src/testing/test-generator.d.ts.map +1 -1
- package/dist/types/src/testing/test-generator.test.d.ts +2 -0
- package/dist/types/src/testing/test-generator.test.d.ts.map +1 -0
- package/dist/types/src/testing/test-services.d.ts.map +1 -1
- package/dist/types/src/testing/test-trace.d.ts +5 -0
- package/dist/types/src/testing/test-trace.d.ts.map +1 -0
- package/dist/types/src/testing/trace-timeline.test.d.ts +2 -0
- package/dist/types/src/testing/trace-timeline.test.d.ts.map +1 -0
- package/dist/types/src/translations.d.ts +2 -539
- package/dist/types/src/translations.d.ts.map +1 -1
- package/dist/types/src/types/Assistant.d.ts +22 -6
- package/dist/types/src/types/Assistant.d.ts.map +1 -1
- package/dist/types/src/types/Settings.d.ts +22 -6
- package/dist/types/src/types/Settings.d.ts.map +1 -1
- package/dist/types/src/types/capabilities.d.ts +1 -13
- package/dist/types/src/types/capabilities.d.ts.map +1 -1
- package/dist/types/src/types/events.d.ts.map +1 -1
- package/dist/types/src/types/index.d.ts +0 -1
- package/dist/types/src/types/index.d.ts.map +1 -1
- package/dist/types/src/types/service.d.ts +1 -1
- package/dist/types/src/types/service.d.ts.map +1 -1
- package/dist/types/tsconfig.tsbuildinfo +1 -1
- package/package.json +113 -99
- package/src/AssistantPlugin.node.ts +125 -0
- package/src/AssistantPlugin.test.ts +35 -0
- package/src/AssistantPlugin.tsx +22 -16
- package/src/blueprints/assistant/blueprint.test.ts +3 -3
- package/src/blueprints/assistant/blueprint.ts +3 -3
- package/src/capabilities/app-graph-builder.ts +5 -61
- package/src/capabilities/blueprint-definition.ts +2 -4
- package/src/capabilities/index.ts +2 -1
- package/src/capabilities/local-model-resolver.ts +14 -4
- package/src/capabilities/markdown.ts +1 -1
- package/src/capabilities/migrations.ts +1 -7
- package/src/capabilities/operation-handler.ts +1 -1
- package/src/capabilities/react-surface.tsx +38 -28
- package/src/capabilities/toolkit.ts +2 -2
- package/src/{components/Typewriter → cli}/index.ts +1 -1
- package/src/cli/plugin.ts +83 -0
- package/src/components/AssistantSettings/AssistantSettings.stories.tsx +3 -2
- package/src/components/AssistantSettings/AssistantSettings.tsx +22 -111
- package/src/components/Chat/Chat.tsx +82 -286
- package/src/components/Chat/context.ts +39 -0
- package/src/components/ChatPrompt/ChatActions.tsx +10 -10
- package/src/components/ChatPrompt/ChatMcpErrors.tsx +50 -0
- package/src/components/ChatPrompt/ChatOptions.stories.tsx +136 -0
- package/src/components/ChatPrompt/ChatOptions.tsx +229 -37
- package/src/components/ChatPrompt/ChatPrompt.tsx +182 -0
- package/src/components/ChatPrompt/ChatReferences.tsx +1 -1
- package/src/components/ChatPrompt/ChatStatus.tsx +123 -0
- package/src/components/ChatPrompt/index.ts +3 -0
- package/src/components/ChatThread/Anchor.stories.tsx +95 -0
- package/src/components/ChatThread/ChatThread.stories.tsx +39 -29
- package/src/components/ChatThread/ChatThread.tsx +36 -21
- package/src/components/ChatThread/DEBUG.md +41 -0
- package/src/components/ChatThread/MarkdownStream.stories.tsx +43 -5
- package/src/components/ChatThread/registry.tsx +72 -24
- package/src/components/ChatThread/sync.test.ts +175 -15
- package/src/components/ChatThread/sync.ts +87 -102
- package/src/components/ChatThread/testing/reasoning.md +25 -0
- package/src/components/ChatThread/widgets/FallbackWidget.tsx +2 -2
- package/src/components/ChatThread/widgets/ReasoningWidget.stories.tsx +1 -1
- package/src/components/ChatThread/widgets/ReasoningWidget.ts +6 -6
- package/src/components/ChatThread/widgets/ReferenceWidget.ts +3 -1
- package/src/components/ChatThread/widgets/SelectWidget.ts +3 -1
- package/src/components/ChatThread/widgets/StatsWidget.ts +3 -1
- package/src/components/ChatThread/widgets/StatusWidget.ts +3 -3
- package/src/components/ChatThread/widgets/SuggestionWidget.ts +1 -1
- package/src/components/ChatThread/widgets/SummaryWidget.tsx +3 -2
- package/src/components/ChatThread/widgets/ToolWidget.stories.tsx +3 -2
- package/src/components/ChatThread/widgets/ToolWidget.tsx +2 -2
- package/src/components/ChatThread/widgets/defaults.ts +8 -0
- package/src/components/ChatThread/widgets/index.ts +1 -2
- package/src/components/ProcessTree/ProcessTree.stories.tsx +12 -38
- package/src/components/ProcessTree/ProcessTree.tsx +70 -37
- package/src/components/TemplateEditor/TemplateEditor.stories.tsx +3 -2
- package/src/components/TemplateEditor/TemplateEditor.tsx +5 -5
- package/src/components/TemplateEditor/TemplateForm.stories.tsx +4 -3
- package/src/components/TemplateEditor/TemplateForm.tsx +3 -3
- package/src/components/TemplateEditor/extensions/handlebars-extension.ts +1 -1
- package/src/components/ToolBlock/ToolBlock.tsx +2 -2
- package/src/components/Toolbox/Toolbox.stories.tsx +2 -1
- package/src/components/Toolbox/Toolbox.tsx +2 -2
- package/src/containers/AgentArticle/AgentArticle.stories.tsx +40 -25
- package/src/containers/AgentArticle/AgentArticle.tsx +96 -53
- package/src/containers/AgentProperties/AgentProperties.stories.tsx +14 -4
- package/src/containers/AgentProperties/AgentProperties.tsx +46 -88
- package/src/containers/BlueprintArticle/BlueprintArticle.tsx +1 -1
- package/src/containers/ChatCompanion/ChatCompanion.tsx +1 -1
- package/src/containers/ChatContainer/ChatContainer.tsx +16 -6
- package/src/containers/ChatDialog/ChatDialog.tsx +3 -9
- package/src/containers/{PromptArticle/PromptArticle.tsx → RoutineArticle/RoutineArticle.tsx} +4 -4
- package/src/containers/RoutineArticle/index.ts +5 -0
- package/src/containers/{PromptList/PromptList.stories.tsx → RoutineList/RoutineList.stories.tsx} +11 -10
- package/src/containers/{PromptList/PromptList.tsx → RoutineList/RoutineList.tsx} +6 -5
- package/src/containers/RoutineList/index.ts +5 -0
- package/src/containers/TracePanel/TracePanel.stories.tsx +278 -0
- package/src/containers/TracePanel/TracePanel.tsx +95 -318
- package/src/containers/TracePanel/dxn-extractor.test.ts +7 -7
- package/src/containers/TracePanel/dxn-extractor.ts +4 -4
- package/src/containers/TracePanel/execution-graph.test.ts +382 -0
- package/src/containers/TracePanel/execution-graph.ts +579 -0
- package/src/containers/TracePanel/testing/index.ts +6 -0
- package/src/containers/TracePanel/testing/simulated-agent.ts +114 -0
- package/src/containers/TracePanel/testing/snapshot-playback.ts +45 -0
- package/src/containers/TriggerStatus/TriggerStatus.tsx +19 -34
- package/src/containers/TriggerStatus/index.ts +1 -1
- package/src/containers/index.ts +2 -2
- package/src/hooks/index.ts +2 -0
- package/src/hooks/useBlueprintRegistry.ts +1 -1
- package/src/hooks/useChatKeymap.ts +52 -0
- package/src/hooks/useChatProcessor.ts +11 -11
- package/src/hooks/useDebug.ts +38 -0
- package/src/index.ts +8 -6
- package/src/operations/create-chat.ts +1 -2
- package/src/operations/definitions.ts +3 -4
- package/src/operations/ensure-companion-chat.ts +1 -1
- package/src/operations/index.ts +1 -1
- package/src/operations/on-create-space.ts +1 -1
- package/src/operations/prompt.test.ts +77 -0
- package/src/operations/resolve-navigation-targets.ts +1 -1
- package/src/operations/run-prompt-in-new-chat.ts +2 -3
- package/src/operations/set-current-chat.ts +1 -1
- package/src/operations/update-chat-name.ts +2 -2
- package/src/processor/presets.ts +9 -1
- package/src/processor/processor.test.ts +4 -4
- package/src/processor/processor.ts +43 -27
- package/src/queue-logger.ts +19 -8
- package/src/testing/data/trace-timeline.dx.json +4657 -0
- package/src/testing/index.ts +1 -0
- package/src/testing/test-generator.test.ts +81 -0
- package/src/testing/test-generator.ts +46 -40
- package/src/testing/test-trace.ts +20 -0
- package/src/testing/trace-timeline.conversations.json +1 -0
- package/src/testing/trace-timeline.test.ts +249 -0
- package/src/translations.ts +49 -34
- package/src/types/Assistant.ts +11 -0
- package/src/types/Settings.ts +63 -8
- package/src/types/index.ts +0 -1
- package/src/types/service.ts +1 -1
- package/dist/lib/browser/AssistantSettings-7QMO3LGF.mjs +0 -97
- package/dist/lib/browser/AssistantSettings-7QMO3LGF.mjs.map +0 -7
- package/dist/lib/browser/chunk-ATHYBVGN.mjs.map +0 -7
- package/dist/lib/browser/chunk-EZRS3J25.mjs +0 -30
- package/dist/lib/browser/chunk-EZRS3J25.mjs.map +0 -7
- package/dist/lib/browser/chunk-RUV2WOQH.mjs.map +0 -7
- package/dist/lib/browser/create-chat-LBZHGVSN.mjs.map +0 -7
- package/dist/lib/browser/ensure-companion-chat-FR4AWZ2P.mjs.map +0 -7
- package/dist/lib/browser/run-prompt-in-new-chat-4YQ37XIS.mjs.map +0 -7
- package/dist/lib/browser/set-current-chat-WJI3WAVM.mjs.map +0 -7
- package/dist/lib/browser/update-chat-name-3Y36KFAS.mjs.map +0 -7
- package/dist/lib/node-esm/AssistantSettings-UVUTKO7E.mjs +0 -98
- package/dist/lib/node-esm/AssistantSettings-UVUTKO7E.mjs.map +0 -7
- package/dist/lib/node-esm/chunk-NZIKC7AN.mjs +0 -32
- package/dist/lib/node-esm/chunk-NZIKC7AN.mjs.map +0 -7
- package/dist/lib/node-esm/chunk-PXAJSTGZ.mjs.map +0 -7
- package/dist/lib/node-esm/chunk-PY4X6FJT.mjs.map +0 -7
- package/dist/lib/node-esm/create-chat-3BEG4R6J.mjs.map +0 -7
- package/dist/lib/node-esm/ensure-companion-chat-BLP7NT32.mjs.map +0 -7
- package/dist/lib/node-esm/run-prompt-in-new-chat-2IJBSDTM.mjs.map +0 -7
- package/dist/lib/node-esm/set-current-chat-KBMMZULR.mjs.map +0 -7
- package/dist/lib/node-esm/update-chat-name-HM2P4NSI.mjs.map +0 -7
- package/dist/types/src/components/ChatProgress/ChatProgress.d.ts +0 -10
- package/dist/types/src/components/ChatProgress/ChatProgress.d.ts.map +0 -1
- package/dist/types/src/components/ChatProgress/index.d.ts +0 -2
- package/dist/types/src/components/ChatProgress/index.d.ts.map +0 -1
- package/dist/types/src/components/ChatThread/widgets/PromptWidget.d.ts +0 -14
- package/dist/types/src/components/ChatThread/widgets/PromptWidget.d.ts.map +0 -1
- package/dist/types/src/components/Typewriter/AssistantToolbar.d.ts +0 -12
- package/dist/types/src/components/Typewriter/AssistantToolbar.d.ts.map +0 -1
- package/dist/types/src/components/Typewriter/Typewriter.d.ts +0 -11
- package/dist/types/src/components/Typewriter/Typewriter.d.ts.map +0 -1
- package/dist/types/src/components/Typewriter/Typewriter.stories.d.ts +0 -7
- package/dist/types/src/components/Typewriter/Typewriter.stories.d.ts.map +0 -1
- package/dist/types/src/components/Typewriter/assistant-extension.d.ts +0 -5
- package/dist/types/src/components/Typewriter/assistant-extension.d.ts.map +0 -1
- package/dist/types/src/components/Typewriter/index.d.ts +0 -2
- package/dist/types/src/components/Typewriter/index.d.ts.map +0 -1
- package/dist/types/src/containers/PromptArticle/PromptArticle.d.ts +0 -6
- package/dist/types/src/containers/PromptArticle/PromptArticle.d.ts.map +0 -1
- package/dist/types/src/containers/PromptArticle/index.d.ts +0 -2
- package/dist/types/src/containers/PromptArticle/index.d.ts.map +0 -1
- package/dist/types/src/containers/PromptList/PromptList.d.ts +0 -6
- package/dist/types/src/containers/PromptList/PromptList.d.ts.map +0 -1
- package/dist/types/src/containers/PromptList/PromptList.stories.d.ts +0 -559
- package/dist/types/src/containers/PromptList/PromptList.stories.d.ts.map +0 -1
- package/dist/types/src/containers/PromptList/index.d.ts +0 -2
- package/dist/types/src/containers/PromptList/index.d.ts.map +0 -1
- package/dist/types/src/types/defs.d.ts +0 -2
- package/dist/types/src/types/defs.d.ts.map +0 -1
- package/src/blueprints/assistant/blueprint.conversations.json +0 -1
- package/src/components/ChatProgress/ChatProgress.tsx +0 -56
- package/src/components/ChatProgress/index.ts +0 -5
- package/src/components/ChatThread/widgets/PromptWidget.ts +0 -28
- package/src/components/Typewriter/AssistantToolbar.tsx +0 -161
- package/src/components/Typewriter/Typewriter.stories.tsx +0 -86
- package/src/components/Typewriter/Typewriter.tsx +0 -50
- package/src/components/Typewriter/assistant-extension.tsx +0 -141
- package/src/containers/PromptArticle/index.ts +0 -5
- package/src/containers/PromptList/index.ts +0 -5
- package/src/types/defs.ts +0 -5
|
@@ -37,7 +37,7 @@ const DefaultStory = ({ text }: DefaultStoryProps) => {
|
|
|
37
37
|
};
|
|
38
38
|
|
|
39
39
|
const meta = {
|
|
40
|
-
title: 'plugins/plugin-assistant/components/
|
|
40
|
+
title: 'plugins/plugin-assistant/components/ChatWidgets/ReasoningWidget',
|
|
41
41
|
component: DefaultStory,
|
|
42
42
|
decorators: [withTheme(), withLayout({ layout: 'column' })],
|
|
43
43
|
parameters: {
|
|
@@ -6,6 +6,8 @@ import { WidgetType } from '@codemirror/view';
|
|
|
6
6
|
|
|
7
7
|
import { Domino } from '@dxos/ui';
|
|
8
8
|
|
|
9
|
+
import { styles } from './defaults';
|
|
10
|
+
|
|
9
11
|
/**
|
|
10
12
|
* Props used to derive a stable key for a reasoning block across CodeMirror widget rebuilds.
|
|
11
13
|
* CodeMirror does not assign persistent IDs to widgets; streaming re-runs the factory each tick.
|
|
@@ -36,15 +38,15 @@ export class ReasoningWidget extends WidgetType {
|
|
|
36
38
|
}
|
|
37
39
|
|
|
38
40
|
override toDOM() {
|
|
39
|
-
|
|
40
|
-
.classNames(
|
|
41
|
+
return Domino.of('div')
|
|
42
|
+
.classNames(styles.padding)
|
|
41
43
|
.append(
|
|
42
44
|
Domino.of('div')
|
|
43
|
-
.classNames('relative overflow-hidden p-px
|
|
45
|
+
.classNames('relative overflow-hidden p-px', styles.border)
|
|
44
46
|
.attributes({ 'data-trail-container': '' })
|
|
45
47
|
.append(
|
|
46
48
|
Domino.of('div')
|
|
47
|
-
.classNames('relative z-10 bg-base-surface rounded-sm text-sm text-
|
|
49
|
+
.classNames('relative z-10 bg-base-surface rounded-sm text-sm text-subdued px-2 py-1')
|
|
48
50
|
.append(
|
|
49
51
|
Domino.of('div')
|
|
50
52
|
.classNames('max-h-[5lh] overflow-y-auto')
|
|
@@ -54,8 +56,6 @@ export class ReasoningWidget extends WidgetType {
|
|
|
54
56
|
Domino.of('div').attributes({ 'data-id': this.#pos }),
|
|
55
57
|
),
|
|
56
58
|
).root;
|
|
57
|
-
|
|
58
|
-
return root;
|
|
59
59
|
}
|
|
60
60
|
|
|
61
61
|
override updateDOM(dom: HTMLElement) {
|
|
@@ -6,6 +6,8 @@ import { WidgetType } from '@codemirror/view';
|
|
|
6
6
|
|
|
7
7
|
import { Domino } from '@dxos/ui';
|
|
8
8
|
|
|
9
|
+
import { styles } from './defaults';
|
|
10
|
+
|
|
9
11
|
export class ReferenceWidget extends WidgetType {
|
|
10
12
|
constructor(
|
|
11
13
|
private text: string,
|
|
@@ -20,7 +22,7 @@ export class ReferenceWidget extends WidgetType {
|
|
|
20
22
|
|
|
21
23
|
override toDOM() {
|
|
22
24
|
return Domino.of('div')
|
|
23
|
-
.classNames(
|
|
25
|
+
.classNames(styles.padding)
|
|
24
26
|
.append(
|
|
25
27
|
Domino.of('dx-anchor' as any)
|
|
26
28
|
.classNames('dx-tag--anchor')
|
|
@@ -6,6 +6,8 @@ import { WidgetType } from '@codemirror/view';
|
|
|
6
6
|
|
|
7
7
|
import { Domino } from '@dxos/ui';
|
|
8
8
|
|
|
9
|
+
import { styles } from './defaults';
|
|
10
|
+
|
|
9
11
|
/**
|
|
10
12
|
* Simple prompt widget.
|
|
11
13
|
*/
|
|
@@ -24,7 +26,7 @@ export class SelectWidget extends WidgetType {
|
|
|
24
26
|
override toDOM() {
|
|
25
27
|
return Domino.of('div')
|
|
26
28
|
.attributes({ role: 'group' })
|
|
27
|
-
.classNames('flex flex-wrap
|
|
29
|
+
.classNames(styles.padding, 'flex flex-wrap gap-1')
|
|
28
30
|
.append(
|
|
29
31
|
...this.options.map((option) =>
|
|
30
32
|
Domino.of('button')
|
|
@@ -6,6 +6,8 @@ import { WidgetType } from '@codemirror/view';
|
|
|
6
6
|
|
|
7
7
|
import { Domino } from '@dxos/ui';
|
|
8
8
|
|
|
9
|
+
import { styles } from './defaults';
|
|
10
|
+
|
|
9
11
|
/**
|
|
10
12
|
* Simple stats widget.
|
|
11
13
|
*/
|
|
@@ -19,7 +21,7 @@ export class StatsWidget extends WidgetType {
|
|
|
19
21
|
}
|
|
20
22
|
|
|
21
23
|
override toDOM() {
|
|
22
|
-
return Domino.of('div').classNames('
|
|
24
|
+
return Domino.of('div').classNames(styles.padding, 'text-sm text-placeholder').text(this.text).root;
|
|
23
25
|
}
|
|
24
26
|
|
|
25
27
|
override updateDOM(dom: HTMLElement) {
|
|
@@ -5,7 +5,8 @@
|
|
|
5
5
|
import { WidgetType } from '@codemirror/view';
|
|
6
6
|
|
|
7
7
|
import { Domino } from '@dxos/ui';
|
|
8
|
-
|
|
8
|
+
|
|
9
|
+
import { styles } from './defaults';
|
|
9
10
|
|
|
10
11
|
/**
|
|
11
12
|
* Props used to derive a stable key for a reasoning block across CodeMirror widget rebuilds.
|
|
@@ -38,8 +39,7 @@ export class StatusWidget extends WidgetType {
|
|
|
38
39
|
|
|
39
40
|
override toDOM() {
|
|
40
41
|
return Domino.of('div')
|
|
41
|
-
.classNames(
|
|
42
|
-
.attributes({ [XML_WIDGET_DATA_ATTR]: '' })
|
|
42
|
+
.classNames(styles.padding)
|
|
43
43
|
.append(
|
|
44
44
|
Domino.of('div')
|
|
45
45
|
.classNames('relative overflow-hidden rounded-sm')
|
|
@@ -19,7 +19,7 @@ export class SuggestionWidget extends WidgetType {
|
|
|
19
19
|
}
|
|
20
20
|
|
|
21
21
|
override toDOM() {
|
|
22
|
-
// NOTE: Container must have `dx-size-container` to support cqi.
|
|
22
|
+
// NOTE: Container must have `dx-inline-size-container` (or `dx-size-container`) to support cqi.
|
|
23
23
|
return Domino.of('span')
|
|
24
24
|
.classNames(mx('inline-flex max-w-[calc(100cqi-8px)] my-1 pe-2 overflow-hidden'))
|
|
25
25
|
.append(
|
|
@@ -11,15 +11,16 @@ import { type XmlWidgetProps } from '@dxos/ui-editor';
|
|
|
11
11
|
import { meta } from '#meta';
|
|
12
12
|
|
|
13
13
|
import { MessageThreadContext } from '../sync';
|
|
14
|
+
import { styles } from './defaults';
|
|
14
15
|
|
|
15
16
|
export const SummaryWidget = ({ children }: XmlWidgetProps<MessageThreadContext>) => {
|
|
16
17
|
const { t } = useTranslation(meta.id);
|
|
17
18
|
|
|
18
19
|
return (
|
|
19
|
-
<TogglePanel.Root classNames=
|
|
20
|
+
<TogglePanel.Root classNames={styles.border}>
|
|
20
21
|
<TogglePanel.Header classNames='text-sm bg-group-surface'>{t('summary.label')}</TogglePanel.Header>
|
|
21
22
|
<TogglePanel.Content>
|
|
22
|
-
<div role='none' className='p-1 text-sm text-
|
|
23
|
+
<div role='none' className='p-1 text-sm text-subdued'>
|
|
23
24
|
{children}
|
|
24
25
|
</div>
|
|
25
26
|
</TogglePanel.Content>
|
|
@@ -7,7 +7,8 @@ import { type Meta, type StoryObj } from '@storybook/react-vite';
|
|
|
7
7
|
import { withLayout, withTheme } from '@dxos/react-ui/testing';
|
|
8
8
|
import { type ContentBlock } from '@dxos/types';
|
|
9
9
|
|
|
10
|
-
import { translations } from '
|
|
10
|
+
import { translations } from '#translations';
|
|
11
|
+
|
|
11
12
|
import { ToolWidget, type ToolWidgetProps } from './ToolWidget';
|
|
12
13
|
|
|
13
14
|
const baseWidgetProps = {
|
|
@@ -33,7 +34,7 @@ const toolCallAndResult: ContentBlock.Any[] = [
|
|
|
33
34
|
];
|
|
34
35
|
|
|
35
36
|
const meta = {
|
|
36
|
-
title: 'plugins/plugin-assistant/components/
|
|
37
|
+
title: 'plugins/plugin-assistant/components/ChatWidgets/ToolWidget',
|
|
37
38
|
component: ToolWidget,
|
|
38
39
|
decorators: [withTheme(), withLayout({ layout: 'column' })],
|
|
39
40
|
parameters: {
|
|
@@ -7,7 +7,7 @@ import React, { useCallback, useEffect, useMemo, useRef, useState } from 'react'
|
|
|
7
7
|
|
|
8
8
|
import { useTranslation } from '@dxos/react-ui';
|
|
9
9
|
import { NumericTabs, TextCrawl, TogglePanel, type TogglePanelRootProps } from '@dxos/react-ui-components';
|
|
10
|
-
import {
|
|
10
|
+
import { JsonHighlighter } from '@dxos/react-ui-syntax-highlighter';
|
|
11
11
|
import { type ContentBlock, type Message } from '@dxos/types';
|
|
12
12
|
import { type XmlWidgetProps } from '@dxos/ui-editor';
|
|
13
13
|
import { isNonNullable, safeParseJson } from '@dxos/util';
|
|
@@ -140,7 +140,7 @@ const ToolPanel = ({ items, onChangeOpen }: ToolPanelProps) => {
|
|
|
140
140
|
selected={selected}
|
|
141
141
|
onSelect={handleSelect}
|
|
142
142
|
/>
|
|
143
|
-
<
|
|
143
|
+
<JsonHighlighter
|
|
144
144
|
data={items[selected]?.content}
|
|
145
145
|
classNames='p-1 text-xs bg-transparent'
|
|
146
146
|
replacer={{
|
|
@@ -3,12 +3,11 @@
|
|
|
3
3
|
//
|
|
4
4
|
|
|
5
5
|
export * from './FallbackWidget';
|
|
6
|
-
export * from './PromptWidget';
|
|
7
6
|
export * from './ReasoningWidget';
|
|
8
7
|
export * from './ReferenceWidget';
|
|
9
8
|
export * from './SelectWidget';
|
|
10
9
|
export * from './StatsWidget';
|
|
10
|
+
export * from './StatusWidget';
|
|
11
11
|
export * from './SummaryWidget';
|
|
12
12
|
export * from './SuggestionWidget';
|
|
13
13
|
export * from './ToolWidget';
|
|
14
|
-
export * from './StatusWidget';
|
|
@@ -6,24 +6,14 @@ import { type Meta, type StoryObj } from '@storybook/react-vite';
|
|
|
6
6
|
import * as Option from 'effect/Option';
|
|
7
7
|
|
|
8
8
|
import { Process } from '@dxos/functions-runtime';
|
|
9
|
+
import { log } from '@dxos/log';
|
|
9
10
|
import { withLayout, withTheme } from '@dxos/react-ui/testing';
|
|
10
11
|
|
|
11
|
-
import {
|
|
12
|
+
import { makeProcess } from '#testing';
|
|
12
13
|
|
|
13
|
-
|
|
14
|
-
overrides: Partial<Process.Info> & Pick<Process.Info, 'pid' | 'state'> & { name: string },
|
|
15
|
-
): Process.Info => ({
|
|
16
|
-
parentPid: null,
|
|
17
|
-
key: `test.process.${overrides.name}`,
|
|
18
|
-
params: { name: overrides.name, target: null },
|
|
19
|
-
error: null,
|
|
20
|
-
startedAt: Date.now() - 10_000,
|
|
21
|
-
completedAt: Option.none(),
|
|
22
|
-
metrics: { wallTime: 0, inputCount: 0, outputCount: 0 },
|
|
23
|
-
...overrides,
|
|
24
|
-
});
|
|
14
|
+
import { ProcessTree } from './ProcessTree';
|
|
25
15
|
|
|
26
|
-
const
|
|
16
|
+
const processes: Process.Info[] = [
|
|
27
17
|
makeProcess({
|
|
28
18
|
pid: Process.ID.make('97793611-815e-4a67-bc04-60fa67b2c987'),
|
|
29
19
|
name: 'Trigger watcher',
|
|
@@ -73,7 +63,7 @@ const seedProcesses: Process.Info[] = [
|
|
|
73
63
|
const meta: Meta<typeof ProcessTree> = {
|
|
74
64
|
title: 'plugins/plugin-assistant/components/ProcessTree',
|
|
75
65
|
component: ProcessTree,
|
|
76
|
-
decorators: [withLayout({ layout: 'column', classNames: 'w-(--dx-complementary-sidebar-size)' })
|
|
66
|
+
decorators: [withTheme(), withLayout({ layout: 'column', classNames: 'w-(--dx-complementary-sidebar-size)' })],
|
|
77
67
|
} satisfies Meta<typeof ProcessTree>;
|
|
78
68
|
|
|
79
69
|
export default meta;
|
|
@@ -82,28 +72,12 @@ type Story = StoryObj<typeof meta>;
|
|
|
82
72
|
|
|
83
73
|
export const Default: Story = {
|
|
84
74
|
args: {
|
|
85
|
-
processes:
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
makeProcess({
|
|
93
|
-
pid: Process.ID.make('1344bac8-745b-44a6-9af6-dc19509a7844'),
|
|
94
|
-
name: 'Agent alpha',
|
|
95
|
-
state: Process.State.RUNNING,
|
|
96
|
-
}),
|
|
97
|
-
makeProcess({
|
|
98
|
-
pid: Process.ID.make('b7c9787a-6705-47dc-a197-d37f1adfa338'),
|
|
99
|
-
name: 'Agent beta',
|
|
100
|
-
state: Process.State.RUNNING,
|
|
101
|
-
}),
|
|
102
|
-
makeProcess({
|
|
103
|
-
pid: Process.ID.make('43493533-a94c-4072-b18f-c0e0fd806bf5'),
|
|
104
|
-
name: 'Agent gamma',
|
|
105
|
-
state: Process.State.RUNNING,
|
|
106
|
-
}),
|
|
107
|
-
],
|
|
75
|
+
processes: processes,
|
|
76
|
+
onProcessSelect: (process) => {
|
|
77
|
+
log.info('select', process);
|
|
78
|
+
},
|
|
79
|
+
onProcessTerminate: (process) => {
|
|
80
|
+
log.info('terminate', process);
|
|
81
|
+
},
|
|
108
82
|
},
|
|
109
83
|
};
|
|
@@ -3,41 +3,47 @@
|
|
|
3
3
|
//
|
|
4
4
|
|
|
5
5
|
import * as Match from 'effect/Match';
|
|
6
|
+
import * as Option from 'effect/Option';
|
|
6
7
|
import React from 'react';
|
|
7
8
|
|
|
8
9
|
import { Process } from '@dxos/functions-runtime';
|
|
9
|
-
import { Icon, ScrollArea, Treegrid } from '@dxos/react-ui';
|
|
10
|
+
import { Icon, IconButton, ScrollArea, Tooltip, Treegrid } from '@dxos/react-ui';
|
|
10
11
|
import { composable, composableProps, mx } from '@dxos/ui-theme';
|
|
12
|
+
import { Unit } from '@dxos/util';
|
|
11
13
|
|
|
12
14
|
export type ProcessTreeProps = {
|
|
15
|
+
// TODO(burdon): Atom.
|
|
13
16
|
processes: readonly Process.Info[];
|
|
14
17
|
onProcessSelect?: (process: Process.Info) => void;
|
|
18
|
+
onProcessTerminate?: (process: Process.Info) => void;
|
|
15
19
|
};
|
|
16
20
|
|
|
17
21
|
export const ProcessTree = composable<HTMLDivElement, ProcessTreeProps>(
|
|
18
|
-
({ processes, onProcessSelect, ...props }, forwardedRef) => {
|
|
19
|
-
const
|
|
22
|
+
({ processes, onProcessSelect, onProcessTerminate, ...props }, forwardedRef) => {
|
|
23
|
+
const sortedProcesses = [
|
|
20
24
|
...processes.filter((process) => [Process.State.RUNNING, Process.State.HYBERNATING].includes(process.state)),
|
|
21
25
|
...processes.filter((process) => [Process.State.IDLE].includes(process.state)).slice(0, 3),
|
|
22
|
-
...processes
|
|
23
|
-
.
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
26
|
+
...processes.filter((process) =>
|
|
27
|
+
[Process.State.SUCCEEDED, Process.State.FAILED, Process.State.TERMINATED].includes(process.state),
|
|
28
|
+
),
|
|
29
|
+
].sort((a, b) => {
|
|
30
|
+
const aCompletedAt = Option.getOrElse(a.completedAt, () => Infinity);
|
|
31
|
+
const bCompletedAt = Option.getOrElse(b.completedAt, () => Infinity);
|
|
32
|
+
return bCompletedAt - aCompletedAt;
|
|
33
|
+
});
|
|
28
34
|
|
|
29
35
|
return (
|
|
30
36
|
<ScrollArea.Root {...composableProps(props, { classNames: 'dx-expander' })} thin ref={forwardedRef}>
|
|
31
37
|
<ScrollArea.Viewport>
|
|
32
38
|
<Treegrid.Root gridTemplateColumns='1fr'>
|
|
33
|
-
{
|
|
39
|
+
{sortedProcesses
|
|
34
40
|
.filter((process) => process.parentPid === null)
|
|
35
41
|
.map((process) => {
|
|
36
|
-
const activeChildren = filteredProcesses.filter(
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
);
|
|
42
|
+
// const activeChildren = filteredProcesses.filter(
|
|
43
|
+
// (candidate) =>
|
|
44
|
+
// candidate.parentPid?.toString() === process.pid.toString() &&
|
|
45
|
+
// candidate.state === Process.State.RUNNING,
|
|
46
|
+
// );
|
|
41
47
|
return (
|
|
42
48
|
<Treegrid.Row
|
|
43
49
|
key={process.pid.toString()}
|
|
@@ -46,33 +52,60 @@ export const ProcessTree = composable<HTMLDivElement, ProcessTreeProps>(
|
|
|
46
52
|
>
|
|
47
53
|
<Treegrid.Cell
|
|
48
54
|
indent
|
|
49
|
-
classNames=
|
|
55
|
+
classNames={mx(
|
|
56
|
+
'grid grid-cols-[min-content_1fr_min-content_min-content] items-center gap-1 min-w-0',
|
|
57
|
+
onProcessSelect && 'dx-hover',
|
|
58
|
+
)}
|
|
50
59
|
onClick={() => onProcessSelect?.(process)}
|
|
51
60
|
>
|
|
52
|
-
<
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
Match.
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
61
|
+
<Tooltip.Trigger className='p-1' content={process.state.toString()}>
|
|
62
|
+
<Icon
|
|
63
|
+
size={4}
|
|
64
|
+
classNames={mx(
|
|
65
|
+
process.state === Process.State.RUNNING && 'animate-spin',
|
|
66
|
+
process.state === Process.State.FAILED && 'text-error-text',
|
|
67
|
+
process.state === Process.State.SUCCEEDED && 'text-success-text',
|
|
68
|
+
)}
|
|
69
|
+
icon={Match.value(process.state).pipe(
|
|
70
|
+
Match.when(Process.State.RUNNING, () => 'ph--spinner-gap--regular'),
|
|
71
|
+
Match.when(Process.State.SUCCEEDED, () => 'ph--check-circle--regular'),
|
|
72
|
+
Match.when(Process.State.FAILED, () => 'ph--warning--regular'),
|
|
73
|
+
Match.when(Process.State.HYBERNATING, () => 'ph--spinner--regular'),
|
|
74
|
+
Match.when(Process.State.IDLE, () => 'ph--hourglass--regular'),
|
|
75
|
+
Match.when(Process.State.TERMINATING, () => 'ph--x-circle--regular'),
|
|
76
|
+
Match.when(Process.State.TERMINATED, () => 'ph--x-circle--regular'),
|
|
77
|
+
Match.orElse(() => 'ph--spinner-gap--regular'),
|
|
78
|
+
)}
|
|
79
|
+
/>
|
|
80
|
+
</Tooltip.Trigger>
|
|
70
81
|
<div role='none' className='flex items-center gap-2 text-xs overflow-hidden'>
|
|
71
|
-
|
|
72
|
-
|
|
82
|
+
{/* TODO(burdon): Name is too long (and not informative). */}
|
|
83
|
+
<span className='truncate text-description select-none'>
|
|
84
|
+
{process.params.name ?? process.pid.toString()}
|
|
85
|
+
</span>
|
|
86
|
+
{/* {activeChildren.length > 0 && (
|
|
73
87
|
<span className='text-xs text-description ml-1'>{activeChildren[0].params.name}</span>
|
|
74
|
-
)}
|
|
88
|
+
)} */}
|
|
75
89
|
</div>
|
|
90
|
+
{([Process.State.FAILED, Process.State.SUCCEEDED].includes(process.state) && (
|
|
91
|
+
<div className='text-xs text-description tabular-nums'>
|
|
92
|
+
{Unit.Millisecond(process.metrics.wallTime).toString()}
|
|
93
|
+
</div>
|
|
94
|
+
)) || <div />}
|
|
95
|
+
{onProcessTerminate && (
|
|
96
|
+
<IconButton
|
|
97
|
+
classNames='min-h-0 p-1'
|
|
98
|
+
icon='ph--x--regular'
|
|
99
|
+
iconOnly
|
|
100
|
+
variant='ghost'
|
|
101
|
+
size={4}
|
|
102
|
+
label='Actions'
|
|
103
|
+
onClick={(event) => {
|
|
104
|
+
event.stopPropagation();
|
|
105
|
+
onProcessTerminate?.(process);
|
|
106
|
+
}}
|
|
107
|
+
/>
|
|
108
|
+
)}
|
|
76
109
|
</Treegrid.Cell>
|
|
77
110
|
</Treegrid.Row>
|
|
78
111
|
);
|
|
@@ -6,13 +6,14 @@ import { type Meta, type StoryObj } from '@storybook/react-vite';
|
|
|
6
6
|
import React, { useState } from 'react';
|
|
7
7
|
|
|
8
8
|
import { createSystemPrompt } from '@dxos/assistant';
|
|
9
|
-
import { Blueprint, Template } from '@dxos/
|
|
9
|
+
import { Blueprint, Template } from '@dxos/compute';
|
|
10
10
|
import { useClient } from '@dxos/react-client';
|
|
11
11
|
import { withClientProvider } from '@dxos/react-client/testing';
|
|
12
12
|
import { withLayout, withTheme } from '@dxos/react-ui/testing';
|
|
13
13
|
import { trim } from '@dxos/util';
|
|
14
14
|
|
|
15
|
-
import { translations } from '
|
|
15
|
+
import { translations } from '#translations';
|
|
16
|
+
|
|
16
17
|
import { TemplateEditor, type TemplateEditorProps } from './TemplateEditor';
|
|
17
18
|
|
|
18
19
|
const FENCE = '```';
|
|
@@ -6,7 +6,7 @@ import { defaultHighlightStyle, syntaxHighlighting } from '@codemirror/language'
|
|
|
6
6
|
import { composeRefs } from '@radix-ui/react-compose-refs';
|
|
7
7
|
import React from 'react';
|
|
8
8
|
|
|
9
|
-
import { type Template } from '@dxos/
|
|
9
|
+
import { type Template } from '@dxos/compute';
|
|
10
10
|
import { createDocAccessor } from '@dxos/echo-db';
|
|
11
11
|
import { useThemeContext, useTranslation } from '@dxos/react-ui';
|
|
12
12
|
import { useTextEditor } from '@dxos/react-ui-editor';
|
|
@@ -35,17 +35,17 @@ export const TemplateEditor = composable<HTMLDivElement, TemplateEditorProps>(
|
|
|
35
35
|
const { t } = useTranslation(meta.id);
|
|
36
36
|
const { themeMode } = useThemeContext();
|
|
37
37
|
const { parentRef } = useTextEditor(() => {
|
|
38
|
-
const
|
|
39
|
-
if (!
|
|
38
|
+
const target = template.source?.target;
|
|
39
|
+
if (!target) {
|
|
40
40
|
return {};
|
|
41
41
|
}
|
|
42
42
|
|
|
43
43
|
return {
|
|
44
|
-
initialValue:
|
|
44
|
+
initialValue: target.content ?? '',
|
|
45
45
|
extensions: [
|
|
46
46
|
createDataExtensions({
|
|
47
47
|
id,
|
|
48
|
-
text: createDocAccessor(
|
|
48
|
+
text: createDocAccessor(target, ['content']),
|
|
49
49
|
}),
|
|
50
50
|
createBasicExtensions({
|
|
51
51
|
bracketMatching: false,
|
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
import { type Meta } from '@storybook/react-vite';
|
|
6
6
|
import React, { useCallback, useState } from 'react';
|
|
7
7
|
|
|
8
|
-
import { Blueprint, Template } from '@dxos/
|
|
8
|
+
import { Blueprint, Template } from '@dxos/compute';
|
|
9
9
|
import { Obj } from '@dxos/echo';
|
|
10
10
|
import { invariant } from '@dxos/invariant';
|
|
11
11
|
import { useClient } from '@dxos/react-client';
|
|
@@ -13,7 +13,8 @@ import { withClientProvider } from '@dxos/react-client/testing';
|
|
|
13
13
|
import { withLayout, withTheme } from '@dxos/react-ui/testing';
|
|
14
14
|
import { trim } from '@dxos/util';
|
|
15
15
|
|
|
16
|
-
import { translations } from '
|
|
16
|
+
import { translations } from '#translations';
|
|
17
|
+
|
|
17
18
|
import { type TemplateChangeCallback, TemplateForm } from './TemplateForm';
|
|
18
19
|
|
|
19
20
|
const TEMPLATE = trim`
|
|
@@ -42,7 +43,7 @@ const DefaultStory = () => {
|
|
|
42
43
|
|
|
43
44
|
const handleChange: TemplateChangeCallback = useCallback(
|
|
44
45
|
(mutate) => {
|
|
45
|
-
Obj.
|
|
46
|
+
Obj.update(blueprint, (blueprint) => mutate(blueprint.instructions));
|
|
46
47
|
},
|
|
47
48
|
[blueprint],
|
|
48
49
|
);
|
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
import type * as Schema from 'effect/Schema';
|
|
6
6
|
import React, { Fragment, useCallback, useEffect } from 'react';
|
|
7
7
|
|
|
8
|
-
import { type Template } from '@dxos/
|
|
8
|
+
import { type Template } from '@dxos/compute';
|
|
9
9
|
import { type Obj } from '@dxos/echo';
|
|
10
10
|
import { Input, Select, useTranslation } from '@dxos/react-ui';
|
|
11
11
|
import { isNonNullable } from '@dxos/util';
|
|
@@ -15,7 +15,7 @@ import { meta } from '#meta';
|
|
|
15
15
|
import { TemplateEditor } from './TemplateEditor';
|
|
16
16
|
|
|
17
17
|
/**
|
|
18
|
-
* Callback type for mutating template within a parent object's Obj.
|
|
18
|
+
* Callback type for mutating template within a parent object's Obj.update context.
|
|
19
19
|
*/
|
|
20
20
|
export type TemplateChangeCallback = (mutate: (template: Obj.Mutable<Template.Template>) => void) => void;
|
|
21
21
|
|
|
@@ -25,7 +25,7 @@ export type TemplateFormProps = {
|
|
|
25
25
|
schema?: Schema.Schema<any, any, any>;
|
|
26
26
|
commandEditable?: boolean;
|
|
27
27
|
/**
|
|
28
|
-
* Callback to mutate the template. Should wrap mutations in parent's Obj.
|
|
28
|
+
* Callback to mutate the template. Should wrap mutations in parent's Obj.update.
|
|
29
29
|
* If not provided, the component is read-only.
|
|
30
30
|
*/
|
|
31
31
|
onChange?: TemplateChangeCallback;
|
|
@@ -7,7 +7,7 @@ import React, { useCallback, useEffect, useMemo, useRef, useState } from 'react'
|
|
|
7
7
|
|
|
8
8
|
import { useTranslation } from '@dxos/react-ui';
|
|
9
9
|
import { NumericTabs, TextCrawl, TogglePanel, type TogglePanelRootProps } from '@dxos/react-ui-components';
|
|
10
|
-
import {
|
|
10
|
+
import { JsonHighlighter } from '@dxos/react-ui-syntax-highlighter';
|
|
11
11
|
import { type ContentBlock, type Message } from '@dxos/types';
|
|
12
12
|
import { type XmlWidgetProps } from '@dxos/ui-editor';
|
|
13
13
|
import { isNonNullable, safeParseJson } from '@dxos/util';
|
|
@@ -129,7 +129,7 @@ const ToolPanel = ({ items, onChangeOpen }: ToolPanelProps) => {
|
|
|
129
129
|
</TogglePanel.Header>
|
|
130
130
|
<TogglePanel.Content classNames='grid grid-cols-[32px_1fr]'>
|
|
131
131
|
<NumericTabs ref={tabsRef} classNames='p-1' length={items.length} selected={selected} onSelect={handleSelect} />
|
|
132
|
-
<
|
|
132
|
+
<JsonHighlighter
|
|
133
133
|
data={items[selected]?.content}
|
|
134
134
|
classNames='p-1 text-xs bg-transparent'
|
|
135
135
|
replacer={{
|
|
@@ -15,7 +15,8 @@ import { MapPlugin } from '@dxos/plugin-map';
|
|
|
15
15
|
import { TablePlugin } from '@dxos/plugin-table';
|
|
16
16
|
import { corePlugins } from '@dxos/plugin-testing';
|
|
17
17
|
|
|
18
|
-
import { translations } from '
|
|
18
|
+
import { translations } from '#translations';
|
|
19
|
+
|
|
19
20
|
import { Toolbox, type ToolboxProps } from './Toolbox';
|
|
20
21
|
|
|
21
22
|
const DefaultStory = (props: ToolboxProps) => {
|
|
@@ -4,10 +4,10 @@
|
|
|
4
4
|
|
|
5
5
|
import React, { Fragment, useEffect, useState } from 'react';
|
|
6
6
|
|
|
7
|
-
import { type Blueprint } from '@dxos/
|
|
7
|
+
import { type Blueprint } from '@dxos/compute';
|
|
8
|
+
import { Operation } from '@dxos/compute';
|
|
8
9
|
import { type Database, type Ref } from '@dxos/echo';
|
|
9
10
|
import { log } from '@dxos/log';
|
|
10
|
-
import { Operation } from '@dxos/operation';
|
|
11
11
|
import { Filter, useQuery } from '@dxos/react-client/echo';
|
|
12
12
|
import { ScrollArea, type ThemedClassName } from '@dxos/react-ui';
|
|
13
13
|
import { composable, composableProps, mx } from '@dxos/ui-theme';
|