@dxos/plugin-assistant 0.8.4-main.1f223c7 → 0.8.4-main.2244d791bb
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/BlueprintArticle-6SP2ZWJ2.mjs +30 -0
- package/dist/lib/browser/BlueprintArticle-6SP2ZWJ2.mjs.map +7 -0
- package/dist/lib/browser/ChatCompanion-KGPU4DLI.mjs +200 -0
- package/dist/lib/browser/ChatCompanion-KGPU4DLI.mjs.map +7 -0
- package/dist/lib/browser/ChatContainer-IHPTKMDK.mjs +73 -0
- package/dist/lib/browser/ChatContainer-IHPTKMDK.mjs.map +7 -0
- package/dist/lib/browser/ChatDialog-VALCOM3W.mjs +85 -0
- package/dist/lib/browser/ChatDialog-VALCOM3W.mjs.map +7 -0
- package/dist/lib/browser/InitiativeContainer-LQHJLTPE.mjs +264 -0
- package/dist/lib/browser/InitiativeContainer-LQHJLTPE.mjs.map +7 -0
- package/dist/lib/browser/PromptArticle-YJ5E2YYE.mjs +65 -0
- package/dist/lib/browser/PromptArticle-YJ5E2YYE.mjs.map +7 -0
- package/dist/lib/browser/ai-service-CY2BYPH6.mjs +22 -0
- package/dist/lib/browser/ai-service-CY2BYPH6.mjs.map +7 -0
- package/dist/lib/browser/app-graph-builder-MUZGUQSC.mjs +234 -0
- package/dist/lib/browser/app-graph-builder-MUZGUQSC.mjs.map +7 -0
- package/dist/lib/browser/blueprint-definition-4D42KBDM.mjs +33 -0
- package/dist/lib/browser/blueprint-definition-4D42KBDM.mjs.map +7 -0
- package/dist/lib/browser/blueprints/index.mjs +8 -0
- package/dist/lib/browser/chunk-6BVCG5SJ.mjs +230 -0
- package/dist/lib/browser/chunk-6BVCG5SJ.mjs.map +7 -0
- package/dist/lib/browser/chunk-DKQMSMBN.mjs +326 -0
- package/dist/lib/browser/chunk-DKQMSMBN.mjs.map +7 -0
- package/dist/lib/browser/chunk-EXVT7D4B.mjs +23 -0
- package/dist/lib/browser/chunk-EXVT7D4B.mjs.map +7 -0
- package/dist/lib/browser/chunk-JYY5AD65.mjs +286 -0
- package/dist/lib/browser/chunk-JYY5AD65.mjs.map +7 -0
- package/dist/lib/browser/chunk-MEM7ET2A.mjs +174 -0
- package/dist/lib/browser/chunk-MEM7ET2A.mjs.map +7 -0
- package/dist/lib/browser/chunk-THZPCE3E.mjs +1968 -0
- package/dist/lib/browser/chunk-THZPCE3E.mjs.map +7 -0
- package/dist/lib/browser/edge-model-resolver-YTMFQEN5.mjs +21 -0
- package/dist/lib/browser/edge-model-resolver-YTMFQEN5.mjs.map +7 -0
- package/dist/lib/browser/index.mjs +277 -223
- package/dist/lib/browser/index.mjs.map +4 -4
- package/dist/lib/browser/local-model-resolver-CGRQH37T.mjs +20 -0
- package/dist/lib/browser/local-model-resolver-CGRQH37T.mjs.map +7 -0
- package/dist/lib/browser/meta.json +1 -1
- package/dist/lib/browser/operation-resolver-MB7OQBPT.mjs +130 -0
- package/dist/lib/browser/operation-resolver-MB7OQBPT.mjs.map +7 -0
- package/dist/lib/browser/react-surface-UHDDX6N3.mjs +125 -0
- package/dist/lib/browser/react-surface-UHDDX6N3.mjs.map +7 -0
- package/dist/lib/browser/repair-IRXDYF4R.mjs +51 -0
- package/dist/lib/browser/repair-IRXDYF4R.mjs.map +7 -0
- package/dist/lib/browser/settings-XF6GKHCG.mjs +33 -0
- package/dist/lib/browser/settings-XF6GKHCG.mjs.map +7 -0
- package/dist/lib/browser/state-OYDPWLKA.mjs +26 -0
- package/dist/lib/browser/state-OYDPWLKA.mjs.map +7 -0
- package/dist/lib/browser/toolkit-IDXQCSTX.mjs +19 -0
- package/dist/lib/browser/toolkit-IDXQCSTX.mjs.map +7 -0
- package/dist/lib/browser/types/index.mjs +8 -4
- package/dist/lib/node-esm/BlueprintArticle-7LI6UXKZ.mjs +31 -0
- package/dist/lib/node-esm/BlueprintArticle-7LI6UXKZ.mjs.map +7 -0
- package/dist/lib/node-esm/ChatCompanion-XY3MAAKH.mjs +201 -0
- package/dist/lib/node-esm/ChatCompanion-XY3MAAKH.mjs.map +7 -0
- package/dist/lib/node-esm/ChatContainer-3YXC4HOK.mjs +74 -0
- package/dist/lib/node-esm/ChatContainer-3YXC4HOK.mjs.map +7 -0
- package/dist/lib/node-esm/ChatDialog-UAYXP3UM.mjs +86 -0
- package/dist/lib/node-esm/ChatDialog-UAYXP3UM.mjs.map +7 -0
- package/dist/lib/node-esm/InitiativeContainer-EAUOSH36.mjs +265 -0
- package/dist/lib/node-esm/InitiativeContainer-EAUOSH36.mjs.map +7 -0
- package/dist/lib/node-esm/PromptArticle-U2IYPLFR.mjs +66 -0
- package/dist/lib/node-esm/PromptArticle-U2IYPLFR.mjs.map +7 -0
- package/dist/lib/node-esm/ai-service-ZI3A6RVG.mjs +23 -0
- package/dist/lib/node-esm/ai-service-ZI3A6RVG.mjs.map +7 -0
- package/dist/lib/node-esm/app-graph-builder-4QN5M6PD.mjs +235 -0
- package/dist/lib/node-esm/app-graph-builder-4QN5M6PD.mjs.map +7 -0
- package/dist/lib/node-esm/blueprint-definition-EJOAZFY5.mjs +34 -0
- package/dist/lib/node-esm/blueprint-definition-EJOAZFY5.mjs.map +7 -0
- package/dist/lib/node-esm/blueprints/index.mjs +9 -0
- package/dist/lib/node-esm/chunk-3DG7AJES.mjs +1969 -0
- package/dist/lib/node-esm/chunk-3DG7AJES.mjs.map +7 -0
- package/dist/lib/node-esm/chunk-75PHXBN3.mjs +327 -0
- package/dist/lib/node-esm/chunk-75PHXBN3.mjs.map +7 -0
- package/dist/lib/node-esm/chunk-CTHGEJJA.mjs +176 -0
- package/dist/lib/node-esm/chunk-CTHGEJJA.mjs.map +7 -0
- package/dist/lib/node-esm/chunk-JMBYVUD6.mjs +288 -0
- package/dist/lib/node-esm/chunk-JMBYVUD6.mjs.map +7 -0
- package/dist/lib/node-esm/chunk-LB72WG6R.mjs +231 -0
- package/dist/lib/node-esm/chunk-LB72WG6R.mjs.map +7 -0
- package/dist/lib/node-esm/chunk-POWB2BPC.mjs +25 -0
- package/dist/lib/node-esm/chunk-POWB2BPC.mjs.map +7 -0
- package/dist/lib/node-esm/edge-model-resolver-CMJ3KNLQ.mjs +22 -0
- package/dist/lib/node-esm/edge-model-resolver-CMJ3KNLQ.mjs.map +7 -0
- package/dist/lib/node-esm/index.mjs +277 -223
- package/dist/lib/node-esm/index.mjs.map +4 -4
- package/dist/lib/node-esm/local-model-resolver-FFDAKOXN.mjs +21 -0
- package/dist/lib/node-esm/local-model-resolver-FFDAKOXN.mjs.map +7 -0
- package/dist/lib/node-esm/meta.json +1 -1
- package/dist/lib/node-esm/operation-resolver-VWNTUHQQ.mjs +131 -0
- package/dist/lib/node-esm/operation-resolver-VWNTUHQQ.mjs.map +7 -0
- package/dist/lib/node-esm/react-surface-DTOXFPWM.mjs +126 -0
- package/dist/lib/node-esm/react-surface-DTOXFPWM.mjs.map +7 -0
- package/dist/lib/node-esm/repair-DMI55PON.mjs +52 -0
- package/dist/lib/node-esm/repair-DMI55PON.mjs.map +7 -0
- package/dist/lib/node-esm/settings-NGGZA7S7.mjs +34 -0
- package/dist/lib/node-esm/settings-NGGZA7S7.mjs.map +7 -0
- package/dist/lib/node-esm/state-VSCPGN7R.mjs +27 -0
- package/dist/lib/node-esm/state-VSCPGN7R.mjs.map +7 -0
- package/dist/lib/node-esm/toolkit-JPRJRDDB.mjs +20 -0
- package/dist/lib/node-esm/toolkit-JPRJRDDB.mjs.map +7 -0
- package/dist/lib/node-esm/types/index.mjs +8 -4
- package/dist/types/src/AssistantPlugin.d.ts +2 -1
- package/dist/types/src/AssistantPlugin.d.ts.map +1 -1
- package/dist/types/src/blueprints/assistant/blueprint.d.ts +4 -0
- package/dist/types/src/blueprints/assistant/blueprint.d.ts.map +1 -0
- package/dist/types/src/blueprints/assistant/functions/index.d.ts +25 -0
- package/dist/types/src/blueprints/assistant/functions/index.d.ts.map +1 -0
- package/dist/types/src/{functions/list.d.ts → blueprints/assistant/functions/object-list.d.ts} +3 -3
- package/dist/types/src/blueprints/assistant/functions/object-list.d.ts.map +1 -0
- package/dist/types/src/{functions/load.d.ts → blueprints/assistant/functions/object-load.d.ts} +3 -3
- package/dist/types/src/blueprints/assistant/functions/object-load.d.ts.map +1 -0
- package/dist/types/src/blueprints/assistant/functions/object-search.d.ts +10 -0
- package/dist/types/src/blueprints/assistant/functions/object-search.d.ts.map +1 -0
- package/dist/types/src/blueprints/assistant/index.d.ts +2 -0
- package/dist/types/src/blueprints/assistant/index.d.ts.map +1 -0
- package/dist/types/src/blueprints/index.d.ts +2 -0
- package/dist/types/src/blueprints/index.d.ts.map +1 -0
- package/dist/types/src/capabilities/ai-service/ai-service.d.ts +6 -0
- package/dist/types/src/capabilities/ai-service/ai-service.d.ts.map +1 -0
- package/dist/types/src/capabilities/ai-service/index.d.ts +3 -0
- package/dist/types/src/capabilities/ai-service/index.d.ts.map +1 -0
- package/dist/types/src/capabilities/app-graph-builder/app-graph-builder.d.ts +6 -0
- package/dist/types/src/capabilities/app-graph-builder/app-graph-builder.d.ts.map +1 -0
- package/dist/types/src/capabilities/app-graph-builder/index.d.ts +3 -0
- package/dist/types/src/capabilities/app-graph-builder/index.d.ts.map +1 -0
- package/dist/types/src/capabilities/blueprint-definition/blueprint-definition.d.ts +6 -0
- package/dist/types/src/capabilities/blueprint-definition/blueprint-definition.d.ts.map +1 -0
- package/dist/types/src/capabilities/blueprint-definition/index.d.ts +3 -0
- package/dist/types/src/capabilities/blueprint-definition/index.d.ts.map +1 -0
- package/dist/types/src/capabilities/edge-model-resolver/edge-model-resolver.d.ts +7 -0
- package/dist/types/src/capabilities/edge-model-resolver/edge-model-resolver.d.ts.map +1 -0
- package/dist/types/src/capabilities/edge-model-resolver/index.d.ts +3 -0
- package/dist/types/src/capabilities/edge-model-resolver/index.d.ts.map +1 -0
- package/dist/types/src/capabilities/index.d.ts +10 -12
- package/dist/types/src/capabilities/index.d.ts.map +1 -1
- package/dist/types/src/capabilities/local-model-resolver/index.d.ts +3 -0
- package/dist/types/src/capabilities/local-model-resolver/index.d.ts.map +1 -0
- package/dist/types/src/capabilities/local-model-resolver/local-model-resolver.d.ts +13 -0
- package/dist/types/src/capabilities/local-model-resolver/local-model-resolver.d.ts.map +1 -0
- package/dist/types/src/capabilities/operation-resolver/index.d.ts +3 -0
- package/dist/types/src/capabilities/operation-resolver/index.d.ts.map +1 -0
- package/dist/types/src/capabilities/operation-resolver/operation-resolver.d.ts +5 -0
- package/dist/types/src/capabilities/operation-resolver/operation-resolver.d.ts.map +1 -0
- package/dist/types/src/capabilities/react-surface/index.d.ts +3 -0
- package/dist/types/src/capabilities/react-surface/index.d.ts.map +1 -0
- package/dist/types/src/capabilities/react-surface/react-surface.d.ts +5 -0
- package/dist/types/src/capabilities/react-surface/react-surface.d.ts.map +1 -0
- package/dist/types/src/capabilities/repair/index.d.ts +3 -0
- package/dist/types/src/capabilities/repair/index.d.ts.map +1 -0
- package/dist/types/src/capabilities/repair/repair.d.ts +6 -0
- package/dist/types/src/capabilities/repair/repair.d.ts.map +1 -0
- package/dist/types/src/capabilities/settings/index.d.ts +15 -0
- package/dist/types/src/capabilities/settings/index.d.ts.map +1 -0
- package/dist/types/src/capabilities/settings/settings.d.ts +18 -0
- package/dist/types/src/capabilities/settings/settings.d.ts.map +1 -0
- package/dist/types/src/capabilities/state/index.d.ts +11 -0
- package/dist/types/src/capabilities/state/index.d.ts.map +1 -0
- package/dist/types/src/capabilities/state/state.d.ts +13 -0
- package/dist/types/src/capabilities/state/state.d.ts.map +1 -0
- package/dist/types/src/capabilities/toolkit/index.d.ts +3 -0
- package/dist/types/src/capabilities/toolkit/index.d.ts.map +1 -0
- package/dist/types/src/capabilities/toolkit/toolkit.d.ts +6 -0
- package/dist/types/src/capabilities/toolkit/toolkit.d.ts.map +1 -0
- package/dist/types/src/components/AssistantSettings/AssistantSettings.d.ts +4 -2
- package/dist/types/src/components/AssistantSettings/AssistantSettings.d.ts.map +1 -1
- package/dist/types/src/components/BlueprintArticle.d.ts +7 -0
- package/dist/types/src/components/BlueprintArticle.d.ts.map +1 -0
- package/dist/types/src/components/Chat/Chat.d.ts +26 -13
- package/dist/types/src/components/Chat/Chat.d.ts.map +1 -1
- package/dist/types/src/components/Chat/events.d.ts +5 -1
- package/dist/types/src/components/Chat/events.d.ts.map +1 -1
- package/dist/types/src/components/ChatCompanion.d.ts +4 -4
- package/dist/types/src/components/ChatCompanion.d.ts.map +1 -1
- package/dist/types/src/components/ChatContainer.d.ts +14 -6
- package/dist/types/src/components/ChatContainer.d.ts.map +1 -1
- package/dist/types/src/components/ChatDialog.d.ts +2 -2
- package/dist/types/src/components/ChatDialog.d.ts.map +1 -1
- package/dist/types/src/components/ChatProgress/ChatProgress.d.ts +2 -2
- package/dist/types/src/components/ChatProgress/ChatProgress.d.ts.map +1 -1
- package/dist/types/src/components/ChatPrompt/ChatActions.d.ts.map +1 -1
- package/dist/types/src/components/ChatPrompt/ChatOptions.d.ts +3 -3
- package/dist/types/src/components/ChatPrompt/ChatOptions.d.ts.map +1 -1
- package/dist/types/src/components/ChatPrompt/ChatReferences.d.ts +3 -3
- package/dist/types/src/components/ChatPrompt/ChatReferences.d.ts.map +1 -1
- package/dist/types/src/components/ChatThread/ChatThread.d.ts +7 -8
- package/dist/types/src/components/ChatThread/ChatThread.d.ts.map +1 -1
- package/dist/types/src/components/ChatThread/ChatThread.stories.d.ts +247 -74
- package/dist/types/src/components/ChatThread/ChatThread.stories.d.ts.map +1 -1
- package/dist/types/src/components/ChatThread/registry.d.ts +1 -1
- package/dist/types/src/components/ChatThread/registry.d.ts.map +1 -1
- package/dist/types/src/components/ChatThread/sync.d.ts +12 -6
- package/dist/types/src/components/ChatThread/sync.d.ts.map +1 -1
- package/dist/types/src/components/InitiativeContainer/InitiativeContainer.d.ts +7 -0
- package/dist/types/src/components/InitiativeContainer/InitiativeContainer.d.ts.map +1 -0
- package/dist/types/src/components/InitiativeContainer/index.d.ts +3 -0
- package/dist/types/src/components/InitiativeContainer/index.d.ts.map +1 -0
- package/dist/types/src/components/PromptArticle.d.ts +7 -0
- package/dist/types/src/components/PromptArticle.d.ts.map +1 -0
- package/dist/types/src/components/TemplateEditor/TemplateEditor.d.ts +2 -1
- package/dist/types/src/components/TemplateEditor/TemplateEditor.d.ts.map +1 -1
- package/dist/types/src/components/TemplateEditor/TemplateEditor.stories.d.ts +230 -61
- package/dist/types/src/components/TemplateEditor/TemplateEditor.stories.d.ts.map +1 -1
- package/dist/types/src/components/TemplateEditor/TemplateForm.d.ts +12 -2
- package/dist/types/src/components/TemplateEditor/TemplateForm.d.ts.map +1 -1
- package/dist/types/src/components/TemplateEditor/TemplateForm.stories.d.ts +231 -62
- 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 -0
- package/dist/types/src/components/TemplateEditor/extensions/index.d.ts +3 -0
- package/dist/types/src/components/TemplateEditor/extensions/index.d.ts.map +1 -0
- package/dist/types/src/components/TemplateEditor/extensions/xml-extension.d.ts +8 -0
- package/dist/types/src/components/TemplateEditor/extensions/xml-extension.d.ts.map +1 -0
- package/dist/types/src/components/ToolBlock/ToolBlock.d.ts +10 -8
- package/dist/types/src/components/ToolBlock/ToolBlock.d.ts.map +1 -1
- package/dist/types/src/components/Toolbox/Toolbox.d.ts +6 -7
- package/dist/types/src/components/Toolbox/Toolbox.d.ts.map +1 -1
- package/dist/types/src/components/Toolbox/Toolbox.stories.d.ts +230 -61
- package/dist/types/src/components/Toolbox/Toolbox.stories.d.ts.map +1 -1
- package/dist/types/src/components/TriggerStatus/TriggerStatus.d.ts +4 -0
- package/dist/types/src/components/TriggerStatus/TriggerStatus.d.ts.map +1 -0
- package/dist/types/src/components/TriggerStatus/index.d.ts +2 -0
- package/dist/types/src/components/TriggerStatus/index.d.ts.map +1 -0
- package/dist/types/src/components/Typewriter/AssistantToolbar.d.ts +12 -0
- package/dist/types/src/components/Typewriter/AssistantToolbar.d.ts.map +1 -0
- package/dist/types/src/components/Typewriter/Typewriter.d.ts +11 -0
- package/dist/types/src/components/Typewriter/Typewriter.d.ts.map +1 -0
- package/dist/types/src/components/Typewriter/Typewriter.stories.d.ts +7 -0
- package/dist/types/src/components/Typewriter/Typewriter.stories.d.ts.map +1 -0
- package/dist/types/src/components/Typewriter/assistant-extension.d.ts +5 -0
- package/dist/types/src/components/Typewriter/assistant-extension.d.ts.map +1 -0
- package/dist/types/src/components/Typewriter/index.d.ts +2 -0
- package/dist/types/src/components/Typewriter/index.d.ts.map +1 -0
- package/dist/types/src/components/index.d.ts +10 -10
- package/dist/types/src/components/index.d.ts.map +1 -1
- package/dist/types/src/hooks/index.d.ts +2 -3
- package/dist/types/src/hooks/index.d.ts.map +1 -1
- package/dist/types/src/hooks/useBlueprintRegistry.d.ts +5 -4
- package/dist/types/src/hooks/useBlueprintRegistry.d.ts.map +1 -1
- package/dist/types/src/hooks/useChatProcessor.d.ts +6 -3
- package/dist/types/src/hooks/useChatProcessor.d.ts.map +1 -1
- package/dist/types/src/hooks/useChatServices.d.ts +6 -6
- package/dist/types/src/hooks/useChatServices.d.ts.map +1 -1
- package/dist/types/src/hooks/useChatToolbarActions.d.ts +8 -0
- package/dist/types/src/hooks/useChatToolbarActions.d.ts.map +1 -0
- package/dist/types/src/hooks/useContextBinder.d.ts +2 -2
- package/dist/types/src/hooks/useContextBinder.d.ts.map +1 -1
- package/dist/types/src/hooks/useContextObjects.d.ts +7 -7
- package/dist/types/src/hooks/useContextObjects.d.ts.map +1 -1
- package/dist/types/src/hooks/useFilteredTypes.d.ts +3 -0
- package/dist/types/src/hooks/useFilteredTypes.d.ts.map +1 -0
- package/dist/types/src/hooks/useReferencesProvider.d.ts.map +1 -1
- package/dist/types/src/index.d.ts +3 -1
- package/dist/types/src/index.d.ts.map +1 -1
- package/dist/types/src/meta.d.ts +3 -4
- package/dist/types/src/meta.d.ts.map +1 -1
- package/dist/types/src/processor/index.d.ts +1 -0
- package/dist/types/src/processor/index.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 +26 -20
- package/dist/types/src/processor/processor.d.ts.map +1 -1
- package/dist/types/src/processor/update-name.d.ts +10 -0
- package/dist/types/src/processor/update-name.d.ts.map +1 -0
- package/dist/types/src/queue-logger.d.ts.map +1 -1
- package/dist/types/src/testing/index.d.ts +0 -2
- package/dist/types/src/testing/index.d.ts.map +1 -1
- package/dist/types/src/testing/test-generator.d.ts +6 -5
- package/dist/types/src/testing/test-generator.d.ts.map +1 -1
- package/dist/types/src/testing/test-services.d.ts +2 -2
- package/dist/types/src/testing/test-services.d.ts.map +1 -1
- package/dist/types/src/translations.d.ts +358 -26
- package/dist/types/src/translations.d.ts.map +1 -1
- package/dist/types/src/types/Assistant.d.ts +8 -30
- package/dist/types/src/types/Assistant.d.ts.map +1 -1
- package/dist/types/src/types/AssistantAction.d.ts +91 -101
- package/dist/types/src/types/AssistantAction.d.ts.map +1 -1
- package/dist/types/src/types/capabilities.d.ts +33 -0
- package/dist/types/src/types/capabilities.d.ts.map +1 -0
- package/dist/types/src/types/events.d.ts +5 -0
- package/dist/types/src/types/events.d.ts.map +1 -0
- package/dist/types/src/types/index.d.ts +4 -1
- package/dist/types/src/types/index.d.ts.map +1 -1
- package/dist/types/src/types/service.d.ts +14 -216
- package/dist/types/src/types/service.d.ts.map +1 -1
- package/dist/types/tsconfig.tsbuildinfo +1 -1
- package/package.json +121 -116
- package/src/AssistantPlugin.tsx +148 -148
- package/src/blueprints/assistant/blueprint.ts +34 -0
- package/src/blueprints/assistant/functions/index.ts +13 -0
- package/src/{functions/list.ts → blueprints/assistant/functions/object-list.ts} +10 -7
- package/src/blueprints/assistant/functions/object-load.ts +44 -0
- package/src/blueprints/assistant/functions/object-search.ts +46 -0
- package/src/blueprints/assistant/index.ts +5 -0
- package/src/{components/Toolbar → blueprints}/index.ts +1 -1
- package/src/capabilities/ai-service/ai-service.ts +30 -0
- package/src/capabilities/ai-service/index.ts +7 -0
- package/src/capabilities/app-graph-builder/app-graph-builder.ts +200 -0
- package/src/capabilities/app-graph-builder/index.ts +7 -0
- package/src/capabilities/blueprint-definition/blueprint-definition.ts +46 -0
- package/src/capabilities/blueprint-definition/index.ts +7 -0
- package/src/capabilities/edge-model-resolver/edge-model-resolver.ts +33 -0
- package/src/capabilities/edge-model-resolver/index.ts +7 -0
- package/src/capabilities/index.ts +10 -15
- package/src/capabilities/local-model-resolver/index.ts +7 -0
- package/src/capabilities/local-model-resolver/local-model-resolver.ts +38 -0
- package/src/capabilities/operation-resolver/index.ts +7 -0
- package/src/capabilities/operation-resolver/operation-resolver.ts +112 -0
- package/src/capabilities/react-surface/index.ts +7 -0
- package/src/capabilities/react-surface/react-surface.tsx +111 -0
- package/src/capabilities/repair/index.ts +7 -0
- package/src/capabilities/repair/repair.ts +62 -0
- package/src/capabilities/settings/index.ts +7 -0
- package/src/capabilities/settings/settings.ts +31 -0
- package/src/capabilities/state/index.ts +7 -0
- package/src/capabilities/state/state.ts +27 -0
- package/src/capabilities/toolkit/index.ts +7 -0
- package/src/capabilities/toolkit/toolkit.ts +27 -0
- package/src/components/AssistantSettings/AssistantSettings.tsx +28 -20
- package/src/components/BlueprintArticle.tsx +28 -0
- package/src/components/Chat/Chat.tsx +222 -153
- package/src/components/Chat/events.ts +7 -1
- package/src/components/ChatCompanion.tsx +201 -86
- package/src/components/ChatContainer.tsx +48 -31
- package/src/components/ChatDialog.tsx +15 -8
- package/src/components/ChatProgress/ChatProgress.tsx +6 -21
- package/src/components/ChatPrompt/ChatActions.tsx +11 -5
- package/src/components/ChatPrompt/ChatOptions.tsx +104 -99
- package/src/components/ChatPrompt/ChatReferences.tsx +7 -8
- package/src/components/ChatPrompt/ChatStatusIndicator.tsx +1 -1
- package/src/components/ChatThread/ChatThread.stories.tsx +63 -43
- package/src/components/ChatThread/ChatThread.tsx +38 -35
- package/src/components/ChatThread/Link.tsx +4 -4
- package/src/components/ChatThread/registry.tsx +43 -41
- package/src/components/ChatThread/sync.test.ts +34 -18
- package/src/components/ChatThread/sync.ts +61 -14
- package/src/components/ChatThread/testing/thread.md +37 -0
- package/src/components/InitiativeContainer/InitiativeContainer.tsx +340 -0
- package/src/components/InitiativeContainer/index.ts +6 -0
- package/src/components/PromptArticle.tsx +58 -0
- package/src/components/TemplateEditor/TemplateEditor.stories.tsx +16 -8
- package/src/components/TemplateEditor/TemplateEditor.tsx +26 -14
- package/src/components/TemplateEditor/TemplateForm.stories.tsx +17 -11
- package/src/components/TemplateEditor/TemplateForm.tsx +77 -30
- package/src/components/TemplateEditor/extensions/handlebars-extension.ts +274 -0
- package/src/components/TemplateEditor/extensions/index.ts +6 -0
- package/src/components/TemplateEditor/extensions/xml-extension.ts +64 -0
- package/src/components/ToolBlock/ToolBlock.tsx +40 -49
- package/src/components/Toolbox/Toolbox.stories.tsx +11 -15
- package/src/components/Toolbox/Toolbox.tsx +54 -56
- package/src/components/TriggerStatus/TriggerStatus.tsx +142 -0
- package/src/components/{SequenceEditor → TriggerStatus}/index.ts +1 -1
- package/src/components/Typewriter/AssistantToolbar.tsx +161 -0
- package/src/components/Typewriter/Typewriter.stories.tsx +83 -0
- package/src/components/Typewriter/Typewriter.tsx +54 -0
- package/src/components/Typewriter/assistant-extension.tsx +144 -0
- package/src/components/Typewriter/index.ts +5 -0
- package/src/components/index.ts +13 -7
- package/src/hooks/index.ts +2 -3
- package/src/hooks/useBlueprintRegistry.ts +48 -20
- package/src/hooks/useChatProcessor.ts +27 -15
- package/src/hooks/useChatServices.ts +19 -20
- package/src/hooks/useChatToolbarActions.ts +122 -0
- package/src/hooks/useContextBinder.ts +21 -7
- package/src/hooks/useContextObjects.ts +13 -25
- package/src/hooks/useFilteredTypes.ts +37 -0
- package/src/hooks/useReferencesProvider.ts +5 -8
- package/src/index.ts +3 -1
- package/src/meta.ts +11 -8
- package/src/processor/index.ts +1 -0
- package/src/processor/presets.ts +2 -2
- package/src/processor/processor.test.ts +24 -29
- package/src/processor/processor.ts +90 -96
- package/src/processor/update-name.ts +58 -0
- package/src/queue-logger.ts +8 -9
- package/src/testing/index.ts +0 -2
- package/src/testing/test-generator.ts +19 -14
- package/src/testing/test-services.ts +10 -14
- package/src/translations.ts +51 -18
- package/src/types/Assistant.ts +5 -38
- package/src/types/AssistantAction.ts +68 -54
- package/src/types/capabilities.ts +27 -0
- package/src/types/events.ts +11 -0
- package/src/types/index.ts +6 -1
- package/src/types/service.ts +25 -14
- package/dist/lib/browser/BlueprintContainer-BFNN6K46.mjs +0 -29
- package/dist/lib/browser/BlueprintContainer-BFNN6K46.mjs.map +0 -7
- package/dist/lib/browser/ChatCompanion-DOVN34C7.mjs +0 -126
- package/dist/lib/browser/ChatCompanion-DOVN34C7.mjs.map +0 -7
- package/dist/lib/browser/ChatContainer-XIVJTCC2.mjs +0 -75
- package/dist/lib/browser/ChatContainer-XIVJTCC2.mjs.map +0 -7
- package/dist/lib/browser/ChatDialog-EJJMK3WL.mjs +0 -88
- package/dist/lib/browser/ChatDialog-EJJMK3WL.mjs.map +0 -7
- package/dist/lib/browser/SequenceContainer-TF5QNXYM.mjs +0 -150
- package/dist/lib/browser/SequenceContainer-TF5QNXYM.mjs.map +0 -7
- package/dist/lib/browser/ai-service-YC2EQPHA.mjs +0 -22
- package/dist/lib/browser/ai-service-YC2EQPHA.mjs.map +0 -7
- package/dist/lib/browser/app-graph-builder-3C43MLCD.mjs +0 -153
- package/dist/lib/browser/app-graph-builder-3C43MLCD.mjs.map +0 -7
- package/dist/lib/browser/blueprint-definition-VHFSRTEJ.mjs +0 -12
- package/dist/lib/browser/chunk-C4Q2RYQM.mjs +0 -1974
- package/dist/lib/browser/chunk-C4Q2RYQM.mjs.map +0 -7
- package/dist/lib/browser/chunk-EZUSNS2J.mjs +0 -19
- package/dist/lib/browser/chunk-EZUSNS2J.mjs.map +0 -7
- package/dist/lib/browser/chunk-GLWD66TA.mjs +0 -161
- package/dist/lib/browser/chunk-GLWD66TA.mjs.map +0 -7
- package/dist/lib/browser/chunk-O4LUJEDV.mjs +0 -20
- package/dist/lib/browser/chunk-O4LUJEDV.mjs.map +0 -7
- package/dist/lib/browser/chunk-PQI3MGDN.mjs +0 -169
- package/dist/lib/browser/chunk-PQI3MGDN.mjs.map +0 -7
- package/dist/lib/browser/chunk-QD4UUISH.mjs +0 -299
- package/dist/lib/browser/chunk-QD4UUISH.mjs.map +0 -7
- package/dist/lib/browser/chunk-R6LRGW3I.mjs +0 -216
- package/dist/lib/browser/chunk-R6LRGW3I.mjs.map +0 -7
- package/dist/lib/browser/chunk-SMIVXXAI.mjs +0 -202
- package/dist/lib/browser/chunk-SMIVXXAI.mjs.map +0 -7
- package/dist/lib/browser/compute-runtime-X6IREJN3.mjs +0 -155
- package/dist/lib/browser/compute-runtime-X6IREJN3.mjs.map +0 -7
- package/dist/lib/browser/edge-model-resolver-JNEB355N.mjs +0 -22
- package/dist/lib/browser/edge-model-resolver-JNEB355N.mjs.map +0 -7
- package/dist/lib/browser/intent-resolver-I6M3ZDAS.mjs +0 -112
- package/dist/lib/browser/intent-resolver-I6M3ZDAS.mjs.map +0 -7
- package/dist/lib/browser/local-model-resolver-EUXSRZ7X.mjs +0 -21
- package/dist/lib/browser/local-model-resolver-EUXSRZ7X.mjs.map +0 -7
- package/dist/lib/browser/react-surface-E4NAGB6R.mjs +0 -109
- package/dist/lib/browser/react-surface-E4NAGB6R.mjs.map +0 -7
- package/dist/lib/browser/settings-36V3VUMW.mjs +0 -23
- package/dist/lib/browser/settings-36V3VUMW.mjs.map +0 -7
- package/dist/lib/browser/state-AINRYS5W.mjs +0 -21
- package/dist/lib/browser/state-AINRYS5W.mjs.map +0 -7
- package/dist/lib/browser/toolkit-MPUS3U64.mjs +0 -191
- package/dist/lib/browser/toolkit-MPUS3U64.mjs.map +0 -7
- package/dist/lib/node-esm/BlueprintContainer-X4MRBKDR.mjs +0 -30
- package/dist/lib/node-esm/BlueprintContainer-X4MRBKDR.mjs.map +0 -7
- package/dist/lib/node-esm/ChatCompanion-ICWYVPRD.mjs +0 -127
- package/dist/lib/node-esm/ChatCompanion-ICWYVPRD.mjs.map +0 -7
- package/dist/lib/node-esm/ChatContainer-LMMMQD4K.mjs +0 -76
- package/dist/lib/node-esm/ChatContainer-LMMMQD4K.mjs.map +0 -7
- package/dist/lib/node-esm/ChatDialog-UUE3F7BT.mjs +0 -89
- package/dist/lib/node-esm/ChatDialog-UUE3F7BT.mjs.map +0 -7
- package/dist/lib/node-esm/SequenceContainer-UXOVZPZO.mjs +0 -151
- package/dist/lib/node-esm/SequenceContainer-UXOVZPZO.mjs.map +0 -7
- package/dist/lib/node-esm/ai-service-XUMZVFCK.mjs +0 -23
- package/dist/lib/node-esm/ai-service-XUMZVFCK.mjs.map +0 -7
- package/dist/lib/node-esm/app-graph-builder-NM3JDLQ2.mjs +0 -154
- package/dist/lib/node-esm/app-graph-builder-NM3JDLQ2.mjs.map +0 -7
- package/dist/lib/node-esm/blueprint-definition-4E6XTLVN.mjs +0 -13
- package/dist/lib/node-esm/chunk-4WLFSXZG.mjs +0 -170
- package/dist/lib/node-esm/chunk-4WLFSXZG.mjs.map +0 -7
- package/dist/lib/node-esm/chunk-7YOGZI66.mjs +0 -203
- package/dist/lib/node-esm/chunk-7YOGZI66.mjs.map +0 -7
- package/dist/lib/node-esm/chunk-LVTG5JTW.mjs +0 -217
- package/dist/lib/node-esm/chunk-LVTG5JTW.mjs.map +0 -7
- package/dist/lib/node-esm/chunk-QG2KT3AT.mjs +0 -163
- package/dist/lib/node-esm/chunk-QG2KT3AT.mjs.map +0 -7
- package/dist/lib/node-esm/chunk-V44ZG7CU.mjs +0 -1975
- package/dist/lib/node-esm/chunk-V44ZG7CU.mjs.map +0 -7
- package/dist/lib/node-esm/chunk-VFY2JG62.mjs +0 -22
- package/dist/lib/node-esm/chunk-VFY2JG62.mjs.map +0 -7
- package/dist/lib/node-esm/chunk-XD4CDA4R.mjs +0 -20
- package/dist/lib/node-esm/chunk-XD4CDA4R.mjs.map +0 -7
- package/dist/lib/node-esm/chunk-YU62ZWJN.mjs +0 -300
- package/dist/lib/node-esm/chunk-YU62ZWJN.mjs.map +0 -7
- package/dist/lib/node-esm/compute-runtime-NRHLLTSC.mjs +0 -156
- package/dist/lib/node-esm/compute-runtime-NRHLLTSC.mjs.map +0 -7
- package/dist/lib/node-esm/edge-model-resolver-UE5TLLJZ.mjs +0 -23
- package/dist/lib/node-esm/edge-model-resolver-UE5TLLJZ.mjs.map +0 -7
- package/dist/lib/node-esm/intent-resolver-VIINHFMT.mjs +0 -113
- package/dist/lib/node-esm/intent-resolver-VIINHFMT.mjs.map +0 -7
- package/dist/lib/node-esm/local-model-resolver-JBEFVVZA.mjs +0 -22
- package/dist/lib/node-esm/local-model-resolver-JBEFVVZA.mjs.map +0 -7
- package/dist/lib/node-esm/react-surface-5WQLRTCH.mjs +0 -110
- package/dist/lib/node-esm/react-surface-5WQLRTCH.mjs.map +0 -7
- package/dist/lib/node-esm/settings-7ZCZ6AS5.mjs +0 -24
- package/dist/lib/node-esm/settings-7ZCZ6AS5.mjs.map +0 -7
- package/dist/lib/node-esm/state-EQS5KP6M.mjs +0 -22
- package/dist/lib/node-esm/state-EQS5KP6M.mjs.map +0 -7
- package/dist/lib/node-esm/toolkit-PKVYDZ4H.mjs +0 -192
- package/dist/lib/node-esm/toolkit-PKVYDZ4H.mjs.map +0 -7
- package/dist/types/src/capabilities/ai-service.d.ts +0 -5
- package/dist/types/src/capabilities/ai-service.d.ts.map +0 -1
- package/dist/types/src/capabilities/app-graph-builder.d.ts +0 -4
- package/dist/types/src/capabilities/app-graph-builder.d.ts.map +0 -1
- package/dist/types/src/capabilities/blueprint-definition.d.ts +0 -7
- package/dist/types/src/capabilities/blueprint-definition.d.ts.map +0 -1
- package/dist/types/src/capabilities/capabilities.d.ts +0 -32
- package/dist/types/src/capabilities/capabilities.d.ts.map +0 -1
- package/dist/types/src/capabilities/compute-runtime.d.ts +0 -5
- package/dist/types/src/capabilities/compute-runtime.d.ts.map +0 -1
- package/dist/types/src/capabilities/edge-model-resolver.d.ts +0 -4
- package/dist/types/src/capabilities/edge-model-resolver.d.ts.map +0 -1
- package/dist/types/src/capabilities/intent-resolver.d.ts +0 -4
- package/dist/types/src/capabilities/intent-resolver.d.ts.map +0 -1
- package/dist/types/src/capabilities/local-model-resolver.d.ts +0 -10
- package/dist/types/src/capabilities/local-model-resolver.d.ts.map +0 -1
- package/dist/types/src/capabilities/react-surface.d.ts +0 -4
- package/dist/types/src/capabilities/react-surface.d.ts.map +0 -1
- package/dist/types/src/capabilities/settings.d.ts +0 -4
- package/dist/types/src/capabilities/settings.d.ts.map +0 -1
- package/dist/types/src/capabilities/state.d.ts +0 -4
- package/dist/types/src/capabilities/state.d.ts.map +0 -1
- package/dist/types/src/capabilities/toolkit.d.ts +0 -4
- package/dist/types/src/capabilities/toolkit.d.ts.map +0 -1
- package/dist/types/src/components/BlueprintContainer.d.ts +0 -8
- package/dist/types/src/components/BlueprintContainer.d.ts.map +0 -1
- package/dist/types/src/components/ChatThread/reducers.d.ts +0 -40
- package/dist/types/src/components/ChatThread/reducers.d.ts.map +0 -1
- package/dist/types/src/components/PromptSettings.d.ts +0 -6
- package/dist/types/src/components/PromptSettings.d.ts.map +0 -1
- package/dist/types/src/components/SequenceContainer.d.ts +0 -8
- package/dist/types/src/components/SequenceContainer.d.ts.map +0 -1
- package/dist/types/src/components/SequenceEditor/SequenceEditor.d.ts +0 -13
- package/dist/types/src/components/SequenceEditor/SequenceEditor.d.ts.map +0 -1
- package/dist/types/src/components/SequenceEditor/SequenceEditor.stories.d.ts +0 -267
- package/dist/types/src/components/SequenceEditor/SequenceEditor.stories.d.ts.map +0 -1
- package/dist/types/src/components/SequenceEditor/index.d.ts +0 -2
- package/dist/types/src/components/SequenceEditor/index.d.ts.map +0 -1
- package/dist/types/src/components/TemplateEditor/handlebars-extension.d.ts.map +0 -1
- package/dist/types/src/components/Toolbar/Toolbar.d.ts +0 -5
- package/dist/types/src/components/Toolbar/Toolbar.d.ts.map +0 -1
- package/dist/types/src/components/Toolbar/index.d.ts +0 -2
- package/dist/types/src/components/Toolbar/index.d.ts.map +0 -1
- package/dist/types/src/components/Toolbar/useChatToolbarActions.d.ts +0 -11
- package/dist/types/src/components/Toolbar/useChatToolbarActions.d.ts.map +0 -1
- package/dist/types/src/events.d.ts +0 -4
- package/dist/types/src/events.d.ts.map +0 -1
- package/dist/types/src/execution-graph/execution-graph.d.ts +0 -21
- package/dist/types/src/execution-graph/execution-graph.d.ts.map +0 -1
- package/dist/types/src/execution-graph/index.d.ts +0 -2
- package/dist/types/src/execution-graph/index.d.ts.map +0 -1
- package/dist/types/src/functions/analysis.d.ts +0 -5
- package/dist/types/src/functions/analysis.d.ts.map +0 -1
- package/dist/types/src/functions/index.d.ts +0 -4
- package/dist/types/src/functions/index.d.ts.map +0 -1
- package/dist/types/src/functions/list.d.ts.map +0 -1
- package/dist/types/src/functions/load.d.ts.map +0 -1
- package/dist/types/src/hooks/useComputeRuntimeCallback.d.ts +0 -8
- package/dist/types/src/hooks/useComputeRuntimeCallback.d.ts.map +0 -1
- package/dist/types/src/hooks/useExecutionGraph.d.ts +0 -6
- package/dist/types/src/hooks/useExecutionGraph.d.ts.map +0 -1
- package/dist/types/src/hooks/useItemTypes.d.ts +0 -4
- package/dist/types/src/hooks/useItemTypes.d.ts.map +0 -1
- package/dist/types/src/stories/Chat.stories.d.ts +0 -30
- package/dist/types/src/stories/Chat.stories.d.ts.map +0 -1
- package/dist/types/src/stories/components/BlueprintContainer.d.ts +0 -4
- package/dist/types/src/stories/components/BlueprintContainer.d.ts.map +0 -1
- package/dist/types/src/stories/components/ChatContainer.d.ts +0 -4
- package/dist/types/src/stories/components/ChatContainer.d.ts.map +0 -1
- package/dist/types/src/stories/components/ChessContainer.d.ts +0 -4
- package/dist/types/src/stories/components/ChessContainer.d.ts.map +0 -1
- package/dist/types/src/stories/components/CommentsContainer.d.ts +0 -4
- package/dist/types/src/stories/components/CommentsContainer.d.ts.map +0 -1
- package/dist/types/src/stories/components/DebugCard.d.ts +0 -8
- package/dist/types/src/stories/components/DebugCard.d.ts.map +0 -1
- package/dist/types/src/stories/components/GraphContainer.d.ts +0 -6
- package/dist/types/src/stories/components/GraphContainer.d.ts.map +0 -1
- package/dist/types/src/stories/components/InvocationsContainer.d.ts +0 -4
- package/dist/types/src/stories/components/InvocationsContainer.d.ts.map +0 -1
- package/dist/types/src/stories/components/LoggingContainer.d.ts +0 -7
- package/dist/types/src/stories/components/LoggingContainer.d.ts.map +0 -1
- package/dist/types/src/stories/components/MessageContainer.d.ts +0 -4
- package/dist/types/src/stories/components/MessageContainer.d.ts.map +0 -1
- package/dist/types/src/stories/components/PromptContainer.d.ts +0 -6
- package/dist/types/src/stories/components/PromptContainer.d.ts.map +0 -1
- package/dist/types/src/stories/components/ResearchInputStack.d.ts +0 -4
- package/dist/types/src/stories/components/ResearchInputStack.d.ts.map +0 -1
- package/dist/types/src/stories/components/ResearchOutputStack.d.ts +0 -4
- package/dist/types/src/stories/components/ResearchOutputStack.d.ts.map +0 -1
- package/dist/types/src/stories/components/TasksContainer.d.ts +0 -4
- package/dist/types/src/stories/components/TasksContainer.d.ts.map +0 -1
- package/dist/types/src/stories/components/TokenManagerContainer.d.ts +0 -3
- package/dist/types/src/stories/components/TokenManagerContainer.d.ts.map +0 -1
- package/dist/types/src/stories/components/TriggersContainer.d.ts +0 -14
- package/dist/types/src/stories/components/TriggersContainer.d.ts.map +0 -1
- package/dist/types/src/stories/components/index.d.ts +0 -16
- package/dist/types/src/stories/components/index.d.ts.map +0 -1
- package/dist/types/src/stories/components/types.d.ts +0 -7
- package/dist/types/src/stories/components/types.d.ts.map +0 -1
- package/dist/types/src/stories/testing/data.d.ts +0 -9
- package/dist/types/src/stories/testing/data.d.ts.map +0 -1
- package/dist/types/src/stories/testing/index.d.ts +0 -3
- package/dist/types/src/stories/testing/index.d.ts.map +0 -1
- package/dist/types/src/stories/testing/schema.d.ts +0 -7
- package/dist/types/src/stories/testing/schema.d.ts.map +0 -1
- package/dist/types/src/stories/testing/testing.d.ts +0 -48
- package/dist/types/src/stories/testing/testing.d.ts.map +0 -1
- package/dist/types/src/testing/test-data.d.ts +0 -14
- package/dist/types/src/testing/test-data.d.ts.map +0 -1
- package/dist/types/src/testing/test-functions.d.ts +0 -6
- package/dist/types/src/testing/test-functions.d.ts.map +0 -1
- package/src/capabilities/ai-service.ts +0 -28
- package/src/capabilities/app-graph-builder.ts +0 -162
- package/src/capabilities/blueprint-definition.ts +0 -58
- package/src/capabilities/capabilities.ts +0 -71
- package/src/capabilities/compute-runtime.ts +0 -124
- package/src/capabilities/edge-model-resolver.ts +0 -27
- package/src/capabilities/intent-resolver.ts +0 -94
- package/src/capabilities/local-model-resolver.ts +0 -32
- package/src/capabilities/react-surface.tsx +0 -91
- package/src/capabilities/settings.ts +0 -19
- package/src/capabilities/state.ts +0 -20
- package/src/capabilities/toolkit.ts +0 -163
- package/src/components/BlueprintContainer.tsx +0 -24
- package/src/components/ChatThread/reducers.ts +0 -151
- package/src/components/PromptSettings.tsx +0 -90
- package/src/components/SequenceContainer.tsx +0 -131
- package/src/components/SequenceEditor/SequenceEditor.stories.tsx +0 -33
- package/src/components/SequenceEditor/SequenceEditor.tsx +0 -50
- package/src/components/TemplateEditor/handlebars-extension.ts +0 -165
- package/src/components/Toolbar/Toolbar.tsx +0 -21
- package/src/components/Toolbar/useChatToolbarActions.ts +0 -126
- package/src/events.ts +0 -11
- package/src/execution-graph/execution-graph.ts +0 -211
- package/src/execution-graph/index.ts +0 -5
- package/src/functions/analysis.ts +0 -20
- package/src/functions/index.ts +0 -7
- package/src/functions/load.ts +0 -42
- package/src/hooks/useComputeRuntimeCallback.ts +0 -25
- package/src/hooks/useExecutionGraph.ts +0 -20
- package/src/hooks/useItemTypes.ts +0 -37
- package/src/stories/Chat.stories.tsx +0 -657
- package/src/stories/components/BlueprintContainer.tsx +0 -34
- package/src/stories/components/ChatContainer.tsx +0 -74
- package/src/stories/components/ChessContainer.tsx +0 -17
- package/src/stories/components/CommentsContainer.tsx +0 -25
- package/src/stories/components/DebugCard.tsx +0 -61
- package/src/stories/components/GraphContainer.tsx +0 -119
- package/src/stories/components/InvocationsContainer.tsx +0 -17
- package/src/stories/components/LoggingContainer.tsx +0 -33
- package/src/stories/components/MessageContainer.tsx +0 -22
- package/src/stories/components/PromptContainer.tsx +0 -52
- package/src/stories/components/ResearchInputStack.tsx +0 -30
- package/src/stories/components/ResearchOutputStack.tsx +0 -29
- package/src/stories/components/TasksContainer.tsx +0 -49
- package/src/stories/components/TokenManagerContainer.tsx +0 -14
- package/src/stories/components/TriggersContainer.tsx +0 -75
- package/src/stories/components/index.ts +0 -20
- package/src/stories/components/types.ts +0 -11
- package/src/stories/testing/data.ts +0 -142
- package/src/stories/testing/index.ts +0 -6
- package/src/stories/testing/schema.ts +0 -17
- package/src/stories/testing/testing.tsx +0 -279
- package/src/testing/test-data.ts +0 -245
- package/src/testing/test-functions.ts +0 -16
- /package/dist/lib/browser/{blueprint-definition-VHFSRTEJ.mjs.map → blueprints/index.mjs.map} +0 -0
- /package/dist/lib/node-esm/{blueprint-definition-4E6XTLVN.mjs.map → blueprints/index.mjs.map} +0 -0
- /package/dist/types/src/components/TemplateEditor/{handlebars-extension.d.ts → extensions/handlebars-extension.d.ts} +0 -0
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
//
|
|
2
|
+
// Copyright 2025 DXOS.org
|
|
3
|
+
//
|
|
4
|
+
|
|
5
|
+
import * as Effect from 'effect/Effect';
|
|
6
|
+
import * as Exit from 'effect/Exit';
|
|
7
|
+
import * as Fiber from 'effect/Fiber';
|
|
8
|
+
import * as Runtime from 'effect/Runtime';
|
|
9
|
+
|
|
10
|
+
import { AiService, DEFAULT_EDGE_MODEL, type ModelName } from '@dxos/ai';
|
|
11
|
+
import { type AiConversation, AiSession } from '@dxos/assistant';
|
|
12
|
+
import { type Chat } from '@dxos/assistant-toolkit';
|
|
13
|
+
import { Obj } from '@dxos/echo';
|
|
14
|
+
import { throwCause } from '@dxos/effect';
|
|
15
|
+
import { trim } from '@dxos/util';
|
|
16
|
+
|
|
17
|
+
import { type AiChatServices } from './processor';
|
|
18
|
+
|
|
19
|
+
/**
|
|
20
|
+
* Update the current chat's name.
|
|
21
|
+
*/
|
|
22
|
+
// TODO(burdon): Convert this into a plugin tool.
|
|
23
|
+
export const updateName = async (
|
|
24
|
+
runtime: Runtime.Runtime<AiChatServices>,
|
|
25
|
+
conversation: AiConversation,
|
|
26
|
+
chat: Chat.Chat,
|
|
27
|
+
model: ModelName = DEFAULT_EDGE_MODEL,
|
|
28
|
+
): Promise<void> => {
|
|
29
|
+
const history = await conversation.getHistory();
|
|
30
|
+
const system = trim`
|
|
31
|
+
It is extremely important that you respond only with the title and nothing else.
|
|
32
|
+
If you cannot do this effectively respond with "New Chat".
|
|
33
|
+
`;
|
|
34
|
+
const prompt = 'Suggest a name for this chat';
|
|
35
|
+
|
|
36
|
+
const fiber = Effect.gen(this, function* () {
|
|
37
|
+
const session = new AiSession();
|
|
38
|
+
return yield* session.run({ system, prompt, history });
|
|
39
|
+
}).pipe(
|
|
40
|
+
Effect.provide(AiService.model(model)),
|
|
41
|
+
Effect.tap((messages) => {
|
|
42
|
+
// TODO(burdon): Parse response (should update via tool).
|
|
43
|
+
const message = messages.find((message) => message.sender.role === 'assistant');
|
|
44
|
+
const title = message?.blocks.find((block) => block._tag === 'text')?.text;
|
|
45
|
+
if (title) {
|
|
46
|
+
Obj.change(chat, (c) => {
|
|
47
|
+
c.name = title;
|
|
48
|
+
});
|
|
49
|
+
}
|
|
50
|
+
}),
|
|
51
|
+
Runtime.runFork(runtime), // Run in the background.
|
|
52
|
+
);
|
|
53
|
+
|
|
54
|
+
const response = await fiber.pipe(Fiber.join, Effect.runPromiseExit);
|
|
55
|
+
if (!Exit.isSuccess(response)) {
|
|
56
|
+
throwCause(response.cause);
|
|
57
|
+
}
|
|
58
|
+
};
|
package/src/queue-logger.ts
CHANGED
|
@@ -5,14 +5,10 @@
|
|
|
5
5
|
import { type Queue, Ref, type Space, getSpace } from '@dxos/client/echo';
|
|
6
6
|
import { type Sequence, type SequenceEvent, type SequenceLogger } from '@dxos/conductor';
|
|
7
7
|
import { DXN, Key, Obj } from '@dxos/echo';
|
|
8
|
-
import {
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
InvocationTraceEventType,
|
|
13
|
-
InvocationTraceStartEvent,
|
|
14
|
-
TraceEvent,
|
|
15
|
-
} from '@dxos/functions';
|
|
8
|
+
import { InvocationTraceEndEvent, InvocationTraceEventType, InvocationTraceStartEvent } from '@dxos/functions-runtime';
|
|
9
|
+
import { TraceEvent } from '@dxos/functions-runtime';
|
|
10
|
+
import { InvocationOutcome } from '@dxos/functions-runtime';
|
|
11
|
+
import { type InvocationTraceEvent } from '@dxos/functions-runtime';
|
|
16
12
|
import { invariant } from '@dxos/invariant';
|
|
17
13
|
import { QueueSubspaceTags } from '@dxos/keys';
|
|
18
14
|
|
|
@@ -27,7 +23,10 @@ export class QueueLogger implements SequenceLogger {
|
|
|
27
23
|
let dxn = this._space.properties.invocationTraceQueue?.dxn;
|
|
28
24
|
if (!dxn) {
|
|
29
25
|
dxn = DXN.fromQueue(QueueSubspaceTags.TRACE, this._space.id, Key.ObjectId.random());
|
|
30
|
-
|
|
26
|
+
const newDxn = dxn;
|
|
27
|
+
Obj.change(this._space.properties, (p) => {
|
|
28
|
+
p.invocationTraceQueue = Ref.fromDXN(newDxn);
|
|
29
|
+
});
|
|
31
30
|
}
|
|
32
31
|
this._invocationTraceQueue = this._space.queues.get(dxn);
|
|
33
32
|
}
|
package/src/testing/index.ts
CHANGED
|
@@ -2,24 +2,25 @@
|
|
|
2
2
|
// Copyright 2025 DXOS.org
|
|
3
3
|
//
|
|
4
4
|
|
|
5
|
-
import
|
|
5
|
+
import * as Effect from 'effect/Effect';
|
|
6
6
|
|
|
7
7
|
import { Obj } from '@dxos/echo';
|
|
8
|
-
import {
|
|
8
|
+
import { Database } from '@dxos/echo';
|
|
9
|
+
import { ContextQueueService } from '@dxos/functions';
|
|
9
10
|
import { faker } from '@dxos/random';
|
|
10
11
|
import { renderObjectLink } from '@dxos/react-ui-components';
|
|
11
|
-
import { type ContentBlock,
|
|
12
|
+
import { type Actor, type ContentBlock, Message, Organization } from '@dxos/types';
|
|
12
13
|
import { trim } from '@dxos/util';
|
|
13
14
|
|
|
14
|
-
export const createMessage = (role:
|
|
15
|
-
return Obj.make(
|
|
15
|
+
export const createMessage = (role: Actor.Role, blocks: ContentBlock.Any[]): Message.Message => {
|
|
16
|
+
return Obj.make(Message.Message, {
|
|
16
17
|
created: new Date().toISOString(),
|
|
17
18
|
sender: { role },
|
|
18
19
|
blocks,
|
|
19
20
|
});
|
|
20
21
|
};
|
|
21
22
|
|
|
22
|
-
export type MessageGenerator = Effect.Effect<void, never,
|
|
23
|
+
export type MessageGenerator = Effect.Effect<void, never, Database.Service | ContextQueueService>;
|
|
23
24
|
|
|
24
25
|
export const createMessageGenerator = (): MessageGenerator[] => [
|
|
25
26
|
Effect.gen(function* () {
|
|
@@ -70,9 +71,9 @@ export const createMessageGenerator = (): MessageGenerator[] => [
|
|
|
70
71
|
[
|
|
71
72
|
faker.lorem.paragraph(),
|
|
72
73
|
'',
|
|
73
|
-
...Array.from({
|
|
74
|
-
(
|
|
75
|
-
),
|
|
74
|
+
...Array.from({
|
|
75
|
+
length: faker.number.int({ min: 3, max: 5 }),
|
|
76
|
+
}).map((_, idx) => `${idx + 1}. ${faker.lorem.paragraph()}`),
|
|
76
77
|
].join('\n') + '\n',
|
|
77
78
|
},
|
|
78
79
|
]),
|
|
@@ -145,11 +146,11 @@ export const createMessageGenerator = (): MessageGenerator[] => [
|
|
|
145
146
|
|
|
146
147
|
Effect.gen(function* () {
|
|
147
148
|
const { queue } = yield* ContextQueueService;
|
|
148
|
-
const { db } = yield*
|
|
149
|
-
const obj1 = db.add(Obj.make(
|
|
150
|
-
// const obj2 = db.add(Obj.make(
|
|
151
|
-
// const obj3 = db.add(Obj.make(
|
|
152
|
-
// const obj4 = db.add(Obj.make(
|
|
149
|
+
const { db } = yield* Database.Service;
|
|
150
|
+
const obj1 = db.add(Obj.make(Organization.Organization, { name: 'DXOS' }));
|
|
151
|
+
// const obj2 = db.add(Obj.make(Person.Person, { fullName: 'Alice' }));
|
|
152
|
+
// const obj3 = db.add(Obj.make(Person.Person, { fullName: 'Bob' }));
|
|
153
|
+
// const obj4 = db.add(Obj.make(Person.Person, { fullName: 'Charlie' }));
|
|
153
154
|
yield* Effect.promise(() =>
|
|
154
155
|
queue.append([
|
|
155
156
|
createMessage('assistant', [
|
|
@@ -188,6 +189,7 @@ export const createMessageGenerator = (): MessageGenerator[] => [
|
|
|
188
189
|
toolCallId: '1234',
|
|
189
190
|
name: 'search',
|
|
190
191
|
input: JSON.stringify({}),
|
|
192
|
+
providerExecuted: false,
|
|
191
193
|
},
|
|
192
194
|
]),
|
|
193
195
|
createMessage('user', [
|
|
@@ -196,6 +198,7 @@ export const createMessageGenerator = (): MessageGenerator[] => [
|
|
|
196
198
|
toolCallId: '1234',
|
|
197
199
|
name: 'search',
|
|
198
200
|
result: 'This is a tool result.',
|
|
201
|
+
providerExecuted: false,
|
|
199
202
|
},
|
|
200
203
|
]),
|
|
201
204
|
]),
|
|
@@ -218,6 +221,7 @@ export const createMessageGenerator = (): MessageGenerator[] => [
|
|
|
218
221
|
toolCallId: '4567',
|
|
219
222
|
name: 'create',
|
|
220
223
|
input: JSON.stringify({}),
|
|
224
|
+
providerExecuted: false,
|
|
221
225
|
},
|
|
222
226
|
]),
|
|
223
227
|
createMessage('user', [
|
|
@@ -226,6 +230,7 @@ export const createMessageGenerator = (): MessageGenerator[] => [
|
|
|
226
230
|
toolCallId: '4567',
|
|
227
231
|
name: 'create',
|
|
228
232
|
result: 'This is a tool result.',
|
|
233
|
+
providerExecuted: false,
|
|
229
234
|
},
|
|
230
235
|
]),
|
|
231
236
|
createMessage('assistant', [
|
|
@@ -2,18 +2,14 @@
|
|
|
2
2
|
// Copyright 2025 DXOS.org
|
|
3
3
|
//
|
|
4
4
|
|
|
5
|
-
import { Obj } from '@dxos/echo';
|
|
5
|
+
import { Obj, type Type } from '@dxos/echo';
|
|
6
6
|
|
|
7
|
-
import {
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
type ServiceQuery,
|
|
11
|
-
ServiceType,
|
|
12
|
-
categoryIcons,
|
|
13
|
-
} from '../types';
|
|
7
|
+
import { type ApiAuthorization, type BaseServiceRegistry, ServiceType, categoryIcons } from '../types';
|
|
8
|
+
|
|
9
|
+
const ServiceTypeSchema = ServiceType as unknown as Type.Obj.Any;
|
|
14
10
|
|
|
15
11
|
export class MockServiceRegistry implements BaseServiceRegistry {
|
|
16
|
-
async queryServices(
|
|
12
|
+
async queryServices(): Promise<ServiceType[]> {
|
|
17
13
|
return TEST_SERVICES;
|
|
18
14
|
}
|
|
19
15
|
}
|
|
@@ -54,7 +50,7 @@ const VISUAL_CROSSING_CREDENTIALS: ApiAuthorization = {
|
|
|
54
50
|
// - e.g., https://github.com/konfig-sdks/openapi-examples/blob/main/xkcd/openapi.yaml
|
|
55
51
|
|
|
56
52
|
const TEST_SERVICES: ServiceType[] = [
|
|
57
|
-
Obj.make(
|
|
53
|
+
Obj.make(ServiceTypeSchema, {
|
|
58
54
|
serviceId: 'amadeus.com/service/FlightSearch',
|
|
59
55
|
name: 'Amadeus Flight Search',
|
|
60
56
|
description: 'Search for local and international flights.',
|
|
@@ -68,7 +64,7 @@ const TEST_SERVICES: ServiceType[] = [
|
|
|
68
64
|
],
|
|
69
65
|
}),
|
|
70
66
|
|
|
71
|
-
Obj.make(
|
|
67
|
+
Obj.make(ServiceTypeSchema, {
|
|
72
68
|
serviceId: 'amadeus.com/service/HotelSearch',
|
|
73
69
|
name: 'Amadeus Hotel Search',
|
|
74
70
|
description: 'Search for local and international hotels.',
|
|
@@ -82,7 +78,7 @@ const TEST_SERVICES: ServiceType[] = [
|
|
|
82
78
|
],
|
|
83
79
|
}),
|
|
84
80
|
|
|
85
|
-
Obj.make(
|
|
81
|
+
Obj.make(ServiceTypeSchema, {
|
|
86
82
|
serviceId: 'visualcrossing.com/service/Weather',
|
|
87
83
|
name: 'Visual Crossing Weather',
|
|
88
84
|
description: 'Search for global weather forecasts.',
|
|
@@ -97,7 +93,7 @@ const TEST_SERVICES: ServiceType[] = [
|
|
|
97
93
|
}),
|
|
98
94
|
|
|
99
95
|
// TODO(burdon): Needs auth.
|
|
100
|
-
Obj.make(
|
|
96
|
+
Obj.make(ServiceTypeSchema, {
|
|
101
97
|
serviceId: 'abstractapi.com/service/GeoLocation',
|
|
102
98
|
name: 'Abstract GeoLocation',
|
|
103
99
|
description: 'Get the location of any IP address.',
|
|
@@ -115,7 +111,7 @@ const TEST_SERVICES: ServiceType[] = [
|
|
|
115
111
|
//
|
|
116
112
|
|
|
117
113
|
...Array.from({ length: 20 }, (_, i) =>
|
|
118
|
-
Obj.make(
|
|
114
|
+
Obj.make(ServiceTypeSchema, {
|
|
119
115
|
serviceId: `example.com/service/test-${i}`,
|
|
120
116
|
name: `Test ${i}`,
|
|
121
117
|
description: `Test ${i}`,
|
package/src/translations.ts
CHANGED
|
@@ -2,12 +2,13 @@
|
|
|
2
2
|
// Copyright 2023 DXOS.org
|
|
3
3
|
//
|
|
4
4
|
|
|
5
|
-
import {
|
|
5
|
+
import { Chat, Initiative } from '@dxos/assistant-toolkit';
|
|
6
|
+
import { Blueprint, Prompt } from '@dxos/blueprints';
|
|
6
7
|
import { Sequence } from '@dxos/conductor';
|
|
8
|
+
import { Type } from '@dxos/echo';
|
|
7
9
|
import { type Resource } from '@dxos/react-ui';
|
|
8
10
|
|
|
9
11
|
import { meta } from './meta';
|
|
10
|
-
import { Assistant } from './types';
|
|
11
12
|
|
|
12
13
|
// TODO(burdon): Standardize translation names.
|
|
13
14
|
export const translations = [
|
|
@@ -22,6 +23,17 @@ export const translations = [
|
|
|
22
23
|
'object name placeholder': 'New blueprint',
|
|
23
24
|
'rename object label': 'Rename blueprint',
|
|
24
25
|
'delete object label': 'Delete blueprint',
|
|
26
|
+
'object deleted label': 'Blueprint deleted',
|
|
27
|
+
},
|
|
28
|
+
[Type.getTypename(Prompt.Prompt)]: {
|
|
29
|
+
'typename label': 'Prompt',
|
|
30
|
+
'typename label_zero': 'Prompts',
|
|
31
|
+
'typename label_one': 'Prompt',
|
|
32
|
+
'typename label_other': 'Prompts',
|
|
33
|
+
'object name placeholder': 'New prompt',
|
|
34
|
+
'rename object label': 'Rename prompt',
|
|
35
|
+
'delete object label': 'Delete prompt',
|
|
36
|
+
'object deleted label': 'Prompt deleted',
|
|
25
37
|
},
|
|
26
38
|
// TODO(burdon): From conductor.
|
|
27
39
|
[Sequence.typename]: {
|
|
@@ -32,12 +44,24 @@ export const translations = [
|
|
|
32
44
|
'object name placeholder': 'New sequence',
|
|
33
45
|
'rename object label': 'Rename sequence',
|
|
34
46
|
'delete object label': 'Delete sequence',
|
|
47
|
+
'object deleted label': 'Sequence deleted',
|
|
35
48
|
},
|
|
36
|
-
[
|
|
49
|
+
[Chat.Chat.typename]: {
|
|
37
50
|
'typename label': 'AI Chat',
|
|
38
51
|
'object name placeholder': 'New AI Chat',
|
|
39
52
|
'rename object label': 'Rename AI Chat',
|
|
40
53
|
'delete object label': 'Delete AI Chat',
|
|
54
|
+
'object deleted label': 'AI Chat deleted',
|
|
55
|
+
},
|
|
56
|
+
[Initiative.Initiative.typename]: {
|
|
57
|
+
'typename label': 'Initiative',
|
|
58
|
+
'typename label_zero': 'Initiatives',
|
|
59
|
+
'typename label_one': 'Initiative',
|
|
60
|
+
'typename label_other': 'Initiatives',
|
|
61
|
+
'object name placeholder': 'New initiative',
|
|
62
|
+
'rename object label': 'Rename initiative',
|
|
63
|
+
'delete object label': 'Delete initiative',
|
|
64
|
+
'object deleted label': 'Initiative deleted',
|
|
41
65
|
},
|
|
42
66
|
// TODO(burdon): Reconcile with react-ui-chat.
|
|
43
67
|
[meta.id]: {
|
|
@@ -61,36 +85,35 @@ export const translations = [
|
|
|
61
85
|
'type filter placeholder': 'Type',
|
|
62
86
|
'any type filter label': 'Any',
|
|
63
87
|
'no blueprint message': 'No active blueprints',
|
|
64
|
-
'
|
|
65
|
-
'
|
|
66
|
-
'error label': '
|
|
88
|
+
'tool call label': 'Calling tool...',
|
|
89
|
+
'tool result label': 'Success',
|
|
90
|
+
'tool error label': 'Tool call failed',
|
|
67
91
|
|
|
68
|
-
'
|
|
92
|
+
'invocations label': 'Invocations',
|
|
69
93
|
|
|
70
94
|
'assistant dialog title': 'Assistant',
|
|
71
95
|
'open assistant label': 'Open assistant',
|
|
96
|
+
'reset blueprints label': 'Reset blueprints',
|
|
72
97
|
|
|
73
98
|
'no tools': 'No tools are configured',
|
|
74
99
|
'no results': 'No results',
|
|
75
100
|
|
|
76
|
-
'button
|
|
77
|
-
'button
|
|
78
|
-
'
|
|
79
|
-
'button
|
|
80
|
-
'button save': 'Save',
|
|
81
|
-
'button run': 'Run',
|
|
82
|
-
'button new thread': 'New Chat',
|
|
101
|
+
'cancel button': 'Cancel',
|
|
102
|
+
'save button': 'Save',
|
|
103
|
+
'new thread button': 'New Chat',
|
|
104
|
+
'rename thread button': 'Rename Chat',
|
|
83
105
|
'chat history label': 'Chat History',
|
|
106
|
+
'chat update name label': 'Update AI Chat name',
|
|
84
107
|
|
|
85
108
|
'toolkit label': 'Toolkit',
|
|
86
109
|
'summary label': 'Summary',
|
|
87
110
|
|
|
88
111
|
'search placeholder': 'Search...',
|
|
89
112
|
'prompt placeholder': 'Enter question or command...',
|
|
90
|
-
'
|
|
91
|
-
'
|
|
92
|
-
'button
|
|
93
|
-
'
|
|
113
|
+
'context objects button': 'Add to context',
|
|
114
|
+
'context settings button': 'Chat settings',
|
|
115
|
+
'microphone button': 'Click to speak',
|
|
116
|
+
'cancel processing button': 'Stop processing',
|
|
94
117
|
'blueprints in context title': 'Blueprints',
|
|
95
118
|
'objects in context title': 'Content',
|
|
96
119
|
'remove object in context label': 'Remove document',
|
|
@@ -101,6 +124,16 @@ export const translations = [
|
|
|
101
124
|
'settings llm provider label': 'LLM provider',
|
|
102
125
|
'settings edge llm model label': 'Remote language model',
|
|
103
126
|
'settings ollama llm model label': 'Ollama language model',
|
|
127
|
+
|
|
128
|
+
// Trigger status
|
|
129
|
+
'trigger status disabled label': 'Triggers disabled',
|
|
130
|
+
'trigger status idle label': 'Triggers idle',
|
|
131
|
+
'trigger status running label': 'Trigger running',
|
|
132
|
+
'trigger status error label': 'Trigger error',
|
|
133
|
+
'trigger runtime label': 'Trigger Runtime',
|
|
134
|
+
'trigger runtime description': 'Enable automatic trigger execution',
|
|
135
|
+
'trigger last invocation label': 'Last run',
|
|
136
|
+
'trigger duration label': 'Duration',
|
|
104
137
|
},
|
|
105
138
|
},
|
|
106
139
|
},
|
package/src/types/Assistant.ts
CHANGED
|
@@ -2,48 +2,15 @@
|
|
|
2
2
|
// Copyright 2024 DXOS.org
|
|
3
3
|
//
|
|
4
4
|
|
|
5
|
-
import
|
|
5
|
+
import * as Schema from 'effect/Schema';
|
|
6
6
|
|
|
7
|
-
import {
|
|
8
|
-
import { Type } from '@dxos/echo';
|
|
9
|
-
import { LabelAnnotation } from '@dxos/echo-schema';
|
|
7
|
+
import { Chat as ChatModule } from '@dxos/assistant-toolkit';
|
|
10
8
|
|
|
11
9
|
import { LLM_PROVIDERS } from './defs';
|
|
12
10
|
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
export const Chat = Schema.Struct({
|
|
17
|
-
id: Type.ObjectId,
|
|
18
|
-
name: Schema.optional(Schema.String),
|
|
19
|
-
queue: Type.Ref(Queue),
|
|
20
|
-
// TODO(dmaretskyi): Eventually this and the message queue will be the same.
|
|
21
|
-
traceQueue: Schema.optional(Type.Ref(Queue)),
|
|
22
|
-
}).pipe(
|
|
23
|
-
Type.Obj({
|
|
24
|
-
typename: 'dxos.org/type/assistant/Chat',
|
|
25
|
-
version: '0.2.0',
|
|
26
|
-
}),
|
|
27
|
-
LabelAnnotation.set(['name']),
|
|
28
|
-
);
|
|
29
|
-
|
|
30
|
-
export interface Chat extends Schema.Schema.Type<typeof Chat> {}
|
|
31
|
-
|
|
32
|
-
/**
|
|
33
|
-
* Relation between a Chat and companion objects (e.g., artifacts).
|
|
34
|
-
*/
|
|
35
|
-
export const CompanionTo = Schema.Struct({
|
|
36
|
-
id: Type.ObjectId,
|
|
37
|
-
}).pipe(
|
|
38
|
-
Type.Relation({
|
|
39
|
-
typename: 'dxos.org/relation/assistant/CompanionTo',
|
|
40
|
-
version: '0.1.0',
|
|
41
|
-
source: Chat,
|
|
42
|
-
target: Type.Expando,
|
|
43
|
-
}),
|
|
44
|
-
);
|
|
45
|
-
|
|
46
|
-
export interface CompanionTo extends Schema.Schema.Type<typeof CompanionTo> {}
|
|
11
|
+
// Re-export Chat schema for backward compatibility.
|
|
12
|
+
export const Chat = ChatModule.Chat;
|
|
13
|
+
export type Chat = ChatModule.Chat;
|
|
47
14
|
|
|
48
15
|
/**
|
|
49
16
|
* Plugin settings.
|
|
@@ -2,61 +2,75 @@
|
|
|
2
2
|
// Copyright 2024 DXOS.org
|
|
3
3
|
//
|
|
4
4
|
|
|
5
|
-
import
|
|
5
|
+
import * as Schema from 'effect/Schema';
|
|
6
6
|
|
|
7
|
-
import {
|
|
8
|
-
import {
|
|
9
|
-
import {
|
|
10
|
-
import {
|
|
7
|
+
import { Capability } from '@dxos/app-framework';
|
|
8
|
+
import { Chat } from '@dxos/assistant-toolkit';
|
|
9
|
+
import { SpaceSchema } from '@dxos/client/echo';
|
|
10
|
+
import { Database, Type } from '@dxos/echo';
|
|
11
|
+
import { Operation } from '@dxos/operation';
|
|
12
|
+
import { Collection } from '@dxos/schema';
|
|
11
13
|
|
|
12
14
|
import { meta } from '../meta';
|
|
13
15
|
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
})
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
})
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
}
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
16
|
+
// Operations
|
|
17
|
+
const ASSISTANT_OPERATION = `${meta.id}/operation`;
|
|
18
|
+
|
|
19
|
+
export namespace AssistantOperation {
|
|
20
|
+
export const OnCreateSpace = Operation.make({
|
|
21
|
+
meta: { key: `${ASSISTANT_OPERATION}/on-create-space`, name: 'On Create Space' },
|
|
22
|
+
services: [Capability.Service],
|
|
23
|
+
schema: {
|
|
24
|
+
input: Schema.Struct({
|
|
25
|
+
space: SpaceSchema,
|
|
26
|
+
rootCollection: Collection.Collection,
|
|
27
|
+
}),
|
|
28
|
+
output: Schema.Void,
|
|
29
|
+
},
|
|
30
|
+
});
|
|
31
|
+
|
|
32
|
+
export const CreateChat = Operation.make({
|
|
33
|
+
meta: { key: `${ASSISTANT_OPERATION}/create-chat`, name: 'Create Chat' },
|
|
34
|
+
services: [Capability.Service],
|
|
35
|
+
schema: {
|
|
36
|
+
input: Schema.Struct({
|
|
37
|
+
db: Database.Database,
|
|
38
|
+
name: Schema.optional(Schema.String),
|
|
39
|
+
/** If false, chat is created in-memory only and not added to space. Defaults to true. */
|
|
40
|
+
addToSpace: Schema.optional(Schema.Boolean),
|
|
41
|
+
}),
|
|
42
|
+
output: Schema.Struct({
|
|
43
|
+
object: Chat.Chat,
|
|
44
|
+
}),
|
|
45
|
+
},
|
|
46
|
+
});
|
|
47
|
+
|
|
48
|
+
export const UpdateChatName = Operation.make({
|
|
49
|
+
meta: { key: `${ASSISTANT_OPERATION}/update-chat-name`, name: 'Update Chat Name' },
|
|
50
|
+
services: [Capability.Service],
|
|
51
|
+
schema: {
|
|
52
|
+
input: Schema.Struct({
|
|
53
|
+
chat: Chat.Chat,
|
|
54
|
+
}),
|
|
55
|
+
output: Schema.Void,
|
|
56
|
+
},
|
|
57
|
+
});
|
|
58
|
+
|
|
59
|
+
export const SetCurrentChat = Operation.make({
|
|
60
|
+
meta: { key: `${ASSISTANT_OPERATION}/set-current-chat`, name: 'Set Current Chat' },
|
|
61
|
+
services: [Capability.Service],
|
|
62
|
+
schema: {
|
|
63
|
+
input: Schema.Struct({
|
|
64
|
+
companionTo: Type.Obj,
|
|
65
|
+
chat: Chat.Chat.pipe(Schema.optional),
|
|
66
|
+
}),
|
|
67
|
+
output: Schema.Void,
|
|
68
|
+
},
|
|
69
|
+
});
|
|
70
|
+
|
|
71
|
+
export const BlueprintForm = Schema.Struct({
|
|
72
|
+
key: Schema.String,
|
|
73
|
+
name: Schema.String,
|
|
74
|
+
description: Schema.optional(Schema.String),
|
|
75
|
+
});
|
|
76
|
+
}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
//
|
|
2
|
+
// Copyright 2025 DXOS.org
|
|
3
|
+
//
|
|
4
|
+
|
|
5
|
+
import { type Atom } from '@effect-atom/atom-react';
|
|
6
|
+
import * as Schema from 'effect/Schema';
|
|
7
|
+
|
|
8
|
+
import { Capability } from '@dxos/app-framework';
|
|
9
|
+
|
|
10
|
+
import { meta } from '../meta';
|
|
11
|
+
|
|
12
|
+
import { type Assistant } from './';
|
|
13
|
+
|
|
14
|
+
export namespace AssistantCapabilities {
|
|
15
|
+
export const Settings = Capability.make<Atom.Writable<Assistant.Settings>>(`${meta.id}/capability/settings`);
|
|
16
|
+
|
|
17
|
+
export const StateSchema = Schema.mutable(
|
|
18
|
+
Schema.Struct({
|
|
19
|
+
/** Map of primary object dxn to current chat dxn. */
|
|
20
|
+
currentChat: Schema.Record({ key: Schema.String, value: Schema.UndefinedOr(Schema.String) }),
|
|
21
|
+
}),
|
|
22
|
+
);
|
|
23
|
+
|
|
24
|
+
export type AssistantState = Schema.Schema.Type<typeof StateSchema>;
|
|
25
|
+
|
|
26
|
+
export const State = Capability.make<Atom.Writable<AssistantState>>(`${meta.id}/capability/state`);
|
|
27
|
+
}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
//
|
|
2
|
+
// Copyright 2025 DXOS.org
|
|
3
|
+
//
|
|
4
|
+
|
|
5
|
+
import { ActivationEvent } from '@dxos/app-framework';
|
|
6
|
+
|
|
7
|
+
import { meta } from '../meta';
|
|
8
|
+
|
|
9
|
+
export namespace AssistantEvents {
|
|
10
|
+
export const SetupAiServiceProviders = ActivationEvent.make(`${meta.id}/event/setup-ai-service-providers`);
|
|
11
|
+
}
|
package/src/types/index.ts
CHANGED
|
@@ -2,8 +2,13 @@
|
|
|
2
2
|
// Copyright 2024 DXOS.org
|
|
3
3
|
//
|
|
4
4
|
|
|
5
|
+
// Re-export Chat type from assistant-toolkit for public API type declarations.
|
|
6
|
+
export type { Chat as ChatType } from '@dxos/assistant-toolkit';
|
|
7
|
+
|
|
5
8
|
export * as Assistant from './Assistant';
|
|
6
|
-
export
|
|
9
|
+
export { AssistantOperation } from './AssistantAction';
|
|
7
10
|
|
|
11
|
+
export * from './capabilities';
|
|
8
12
|
export * from './defs';
|
|
13
|
+
export * from './events';
|
|
9
14
|
export * from './service';
|