@dxos/plugin-automation 0.7.5-labs.f5080a1 → 0.7.5-main.5ae2ba8
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/AutomationPanel-ITYXSN5Z.mjs +132 -0
- package/dist/lib/browser/AutomationPanel-ITYXSN5Z.mjs.map +7 -0
- package/dist/lib/browser/{chunk-DQ7ZSYJJ.mjs → chunk-OFDNNRLE.mjs} +3 -6
- package/dist/lib/browser/{chunk-DQ7ZSYJJ.mjs.map → chunk-OFDNNRLE.mjs.map} +3 -3
- package/dist/lib/browser/chunk-U7QLNY2S.mjs +8 -0
- package/dist/lib/browser/chunk-U7QLNY2S.mjs.map +7 -0
- package/dist/lib/browser/chunk-WY2C7JY4.mjs +119 -0
- package/dist/lib/browser/chunk-WY2C7JY4.mjs.map +7 -0
- package/dist/lib/browser/complementary-panel-4CPOJL4Y.mjs +56 -0
- package/dist/lib/browser/complementary-panel-4CPOJL4Y.mjs.map +7 -0
- package/dist/lib/browser/index.mjs +22 -373
- package/dist/lib/browser/index.mjs.map +4 -4
- package/dist/lib/browser/meta.json +1 -1
- package/dist/lib/browser/react-surface-SAPMN4PF.mjs +27 -0
- package/dist/lib/browser/react-surface-SAPMN4PF.mjs.map +7 -0
- package/dist/lib/node/{chunk-OCW5GAVZ.cjs → AutomationPanel-X33HHDMQ.cjs} +19 -131
- package/dist/lib/node/AutomationPanel-X33HHDMQ.cjs.map +7 -0
- package/dist/lib/node/chunk-7Q5SNGCL.cjs +148 -0
- package/dist/lib/node/chunk-7Q5SNGCL.cjs.map +7 -0
- package/dist/lib/node/chunk-CB5OB6JH.cjs +40 -0
- package/dist/lib/node/chunk-CB5OB6JH.cjs.map +7 -0
- package/dist/lib/node/{chunk-TQEDPRY5.cjs → chunk-ORMEYEBE.cjs} +6 -9
- package/dist/lib/node/{chunk-TQEDPRY5.cjs.map → chunk-ORMEYEBE.cjs.map} +3 -3
- package/dist/lib/node/complementary-panel-ZYJJ42ZU.cjs +72 -0
- package/dist/lib/node/complementary-panel-ZYJJ42ZU.cjs.map +7 -0
- package/dist/lib/node/index.cjs +37 -374
- package/dist/lib/node/index.cjs.map +4 -4
- package/dist/lib/node/meta.json +1 -1
- package/dist/lib/node/{react-surface-HDAVE6NU.cjs → react-surface-2WRVAPGR.cjs} +9 -28
- package/dist/lib/node/react-surface-2WRVAPGR.cjs.map +7 -0
- package/dist/lib/node-esm/AutomationPanel-HY3GB4BT.mjs +133 -0
- package/dist/lib/node-esm/AutomationPanel-HY3GB4BT.mjs.map +7 -0
- package/dist/lib/node-esm/{chunk-JFHI22MF.mjs → chunk-6MUUH67V.mjs} +3 -6
- package/dist/lib/node-esm/{chunk-JFHI22MF.mjs.map → chunk-6MUUH67V.mjs.map} +3 -3
- package/dist/lib/node-esm/chunk-R3P2WPBQ.mjs +10 -0
- package/dist/lib/node-esm/chunk-R3P2WPBQ.mjs.map +7 -0
- package/dist/lib/node-esm/chunk-UDD2VA6G.mjs +120 -0
- package/dist/lib/node-esm/chunk-UDD2VA6G.mjs.map +7 -0
- package/dist/lib/node-esm/complementary-panel-S42RIIAY.mjs +57 -0
- package/dist/lib/node-esm/complementary-panel-S42RIIAY.mjs.map +7 -0
- package/dist/lib/node-esm/index.mjs +22 -373
- package/dist/lib/node-esm/index.mjs.map +4 -4
- package/dist/lib/node-esm/meta.json +1 -1
- package/dist/lib/node-esm/react-surface-QWLPOYXO.mjs +28 -0
- package/dist/lib/node-esm/react-surface-QWLPOYXO.mjs.map +7 -0
- package/dist/types/src/AutomationPlugin.d.ts.map +1 -1
- package/dist/types/src/capabilities/{ai-client.d.ts → complementary-panel.d.ts} +2 -3
- package/dist/types/src/capabilities/complementary-panel.d.ts.map +1 -0
- package/dist/types/src/capabilities/index.d.ts +1 -180
- package/dist/types/src/capabilities/index.d.ts.map +1 -1
- package/dist/types/src/capabilities/react-surface.d.ts.map +1 -1
- package/dist/types/src/components/AutomationPanel/AutomationPanel.d.ts +1 -2
- package/dist/types/src/components/AutomationPanel/AutomationPanel.d.ts.map +1 -1
- package/dist/types/src/components/AutomationPanel/AutomationPanel.stories.d.ts.map +1 -1
- package/dist/types/src/components/TriggerEditor/TriggerEditor.d.ts +1 -2
- package/dist/types/src/components/TriggerEditor/TriggerEditor.d.ts.map +1 -1
- package/dist/types/src/components/TriggerEditor/TriggerEditor.stories.d.ts.map +1 -1
- package/dist/types/src/components/index.d.ts +1 -11
- package/dist/types/src/components/index.d.ts.map +1 -1
- package/dist/types/src/index.d.ts +1 -3
- package/dist/types/src/index.d.ts.map +1 -1
- package/dist/types/src/meta.d.ts +0 -1
- package/dist/types/src/meta.d.ts.map +1 -1
- package/dist/types/src/testing/index.d.ts +0 -1
- package/dist/types/src/testing/index.d.ts.map +1 -1
- package/dist/types/src/testing/test-functions.d.ts +0 -2
- package/dist/types/src/testing/test-functions.d.ts.map +1 -1
- package/dist/types/src/translations.d.ts +2 -92
- package/dist/types/src/translations.d.ts.map +1 -1
- package/package.json +23 -71
- package/src/AutomationPlugin.tsx +9 -64
- package/src/capabilities/complementary-panel.ts +56 -0
- package/src/capabilities/index.ts +1 -5
- package/src/capabilities/react-surface.tsx +2 -16
- package/src/components/AutomationPanel/AutomationPanel.stories.tsx +1 -2
- package/src/components/AutomationPanel/AutomationPanel.tsx +56 -49
- package/src/components/TriggerEditor/TriggerEditor.stories.tsx +1 -2
- package/src/components/TriggerEditor/TriggerEditor.tsx +6 -1
- package/src/components/index.ts +0 -7
- package/src/index.ts +2 -3
- package/src/meta.ts +1 -2
- package/src/testing/index.ts +0 -1
- package/src/testing/test-functions.ts +0 -7
- package/src/translations.ts +2 -29
- package/dist/lib/browser/AutomationPanel-YPD3AGQN.mjs +0 -8
- package/dist/lib/browser/AutomationPanel-YPD3AGQN.mjs.map +0 -7
- package/dist/lib/browser/ChatContainer-ODZECATM.mjs +0 -12
- package/dist/lib/browser/ChatContainer-ODZECATM.mjs.map +0 -7
- package/dist/lib/browser/ai-client-UJLNYP7B.mjs +0 -22
- package/dist/lib/browser/ai-client-UJLNYP7B.mjs.map +0 -7
- package/dist/lib/browser/app-graph-builder-3H5TCRG4.mjs +0 -162
- package/dist/lib/browser/app-graph-builder-3H5TCRG4.mjs.map +0 -7
- package/dist/lib/browser/chunk-43WRHV2L.mjs +0 -150
- package/dist/lib/browser/chunk-43WRHV2L.mjs.map +0 -7
- package/dist/lib/browser/chunk-BQHXJZ4K.mjs +0 -15
- package/dist/lib/browser/chunk-BQHXJZ4K.mjs.map +0 -7
- package/dist/lib/browser/chunk-DL7XA62G.mjs +0 -1531
- package/dist/lib/browser/chunk-DL7XA62G.mjs.map +0 -7
- package/dist/lib/browser/chunk-PQGFC2ZO.mjs +0 -284
- package/dist/lib/browser/chunk-PQGFC2ZO.mjs.map +0 -7
- package/dist/lib/browser/chunk-Z54KIF6H.mjs +0 -242
- package/dist/lib/browser/chunk-Z54KIF6H.mjs.map +0 -7
- package/dist/lib/browser/intent-resolver-5YVZJFS3.mjs +0 -29
- package/dist/lib/browser/intent-resolver-5YVZJFS3.mjs.map +0 -7
- package/dist/lib/browser/react-surface-WRHRCEV5.mjs +0 -50
- package/dist/lib/browser/react-surface-WRHRCEV5.mjs.map +0 -7
- package/dist/lib/browser/types/index.mjs +0 -24
- package/dist/lib/browser/types/index.mjs.map +0 -7
- package/dist/lib/node/AutomationPanel-CO26O75P.cjs +0 -26
- package/dist/lib/node/AutomationPanel-CO26O75P.cjs.map +0 -7
- package/dist/lib/node/ChatContainer-5URBEXQD.cjs +0 -33
- package/dist/lib/node/ChatContainer-5URBEXQD.cjs.map +0 -7
- package/dist/lib/node/ai-client-AOB6TLNW.cjs +0 -38
- package/dist/lib/node/ai-client-AOB6TLNW.cjs.map +0 -7
- package/dist/lib/node/app-graph-builder-CDEQJEHY.cjs +0 -178
- package/dist/lib/node/app-graph-builder-CDEQJEHY.cjs.map +0 -7
- package/dist/lib/node/chunk-AWZVJZ2I.cjs +0 -34
- package/dist/lib/node/chunk-AWZVJZ2I.cjs.map +0 -7
- package/dist/lib/node/chunk-D2QQXWOY.cjs +0 -302
- package/dist/lib/node/chunk-D2QQXWOY.cjs.map +0 -7
- package/dist/lib/node/chunk-H3RSMGJG.cjs +0 -173
- package/dist/lib/node/chunk-H3RSMGJG.cjs.map +0 -7
- package/dist/lib/node/chunk-NH7STAX6.cjs +0 -1515
- package/dist/lib/node/chunk-NH7STAX6.cjs.map +0 -7
- package/dist/lib/node/chunk-OCW5GAVZ.cjs.map +0 -7
- package/dist/lib/node/intent-resolver-MJFZT5IU.cjs +0 -44
- package/dist/lib/node/intent-resolver-MJFZT5IU.cjs.map +0 -7
- package/dist/lib/node/react-surface-HDAVE6NU.cjs.map +0 -7
- package/dist/lib/node/types/index.cjs +0 -46
- package/dist/lib/node/types/index.cjs.map +0 -7
- package/dist/lib/node-esm/AutomationPanel-VQZUKPK2.mjs +0 -9
- package/dist/lib/node-esm/AutomationPanel-VQZUKPK2.mjs.map +0 -7
- package/dist/lib/node-esm/ChatContainer-23QIVDG5.mjs +0 -13
- package/dist/lib/node-esm/ChatContainer-23QIVDG5.mjs.map +0 -7
- package/dist/lib/node-esm/ai-client-RUCCJ7JZ.mjs +0 -23
- package/dist/lib/node-esm/ai-client-RUCCJ7JZ.mjs.map +0 -7
- package/dist/lib/node-esm/app-graph-builder-GR3URVNX.mjs +0 -163
- package/dist/lib/node-esm/app-graph-builder-GR3URVNX.mjs.map +0 -7
- package/dist/lib/node-esm/chunk-7JO77AAS.mjs +0 -151
- package/dist/lib/node-esm/chunk-7JO77AAS.mjs.map +0 -7
- package/dist/lib/node-esm/chunk-JJFWFS6P.mjs +0 -1532
- package/dist/lib/node-esm/chunk-JJFWFS6P.mjs.map +0 -7
- package/dist/lib/node-esm/chunk-LSSWQIQD.mjs +0 -16
- package/dist/lib/node-esm/chunk-LSSWQIQD.mjs.map +0 -7
- package/dist/lib/node-esm/chunk-NSVQZ3EH.mjs +0 -243
- package/dist/lib/node-esm/chunk-NSVQZ3EH.mjs.map +0 -7
- package/dist/lib/node-esm/chunk-VN2AFV25.mjs +0 -285
- package/dist/lib/node-esm/chunk-VN2AFV25.mjs.map +0 -7
- package/dist/lib/node-esm/intent-resolver-FCKNRTKQ.mjs +0 -30
- package/dist/lib/node-esm/intent-resolver-FCKNRTKQ.mjs.map +0 -7
- package/dist/lib/node-esm/react-surface-FZ5OFRDE.mjs +0 -51
- package/dist/lib/node-esm/react-surface-FZ5OFRDE.mjs.map +0 -7
- package/dist/lib/node-esm/types/index.mjs +0 -25
- package/dist/lib/node-esm/types/index.mjs.map +0 -7
- package/dist/types/src/artifacts.stories.d.ts +0 -16
- package/dist/types/src/artifacts.stories.d.ts.map +0 -1
- package/dist/types/src/capabilities/ai-client.d.ts.map +0 -1
- package/dist/types/src/capabilities/app-graph-builder.d.ts +0 -180
- package/dist/types/src/capabilities/app-graph-builder.d.ts.map +0 -1
- package/dist/types/src/capabilities/capabilities.d.ts +0 -5
- package/dist/types/src/capabilities/capabilities.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/components/ChatContainer/ChatContainer.d.ts +0 -7
- package/dist/types/src/components/ChatContainer/ChatContainer.d.ts.map +0 -1
- package/dist/types/src/components/ChatContainer/index.d.ts +0 -4
- package/dist/types/src/components/ChatContainer/index.d.ts.map +0 -1
- package/dist/types/src/components/MarkdownViewer/MarkdownViewer.d.ts +0 -14
- package/dist/types/src/components/MarkdownViewer/MarkdownViewer.d.ts.map +0 -1
- package/dist/types/src/components/MarkdownViewer/MarkdownViewer.stories.d.ts +0 -8
- package/dist/types/src/components/MarkdownViewer/MarkdownViewer.stories.d.ts.map +0 -1
- package/dist/types/src/components/MarkdownViewer/index.d.ts +0 -2
- package/dist/types/src/components/MarkdownViewer/index.d.ts.map +0 -1
- package/dist/types/src/components/PromptEditor/PromptEditor.d.ts +0 -10
- package/dist/types/src/components/PromptEditor/PromptEditor.d.ts.map +0 -1
- package/dist/types/src/components/PromptEditor/PromptEditor.stories.d.ts +0 -6
- package/dist/types/src/components/PromptEditor/PromptEditor.stories.d.ts.map +0 -1
- package/dist/types/src/components/PromptEditor/index.d.ts +0 -2
- package/dist/types/src/components/PromptEditor/index.d.ts.map +0 -1
- package/dist/types/src/components/PromptEditor/prompt-extension.d.ts +0 -4
- package/dist/types/src/components/PromptEditor/prompt-extension.d.ts.map +0 -1
- package/dist/types/src/components/PromptEditor/types.d.ts +0 -18
- package/dist/types/src/components/PromptEditor/types.d.ts.map +0 -1
- package/dist/types/src/components/ServiceRegistry/ServiceRegistry.d.ts +0 -6
- package/dist/types/src/components/ServiceRegistry/ServiceRegistry.d.ts.map +0 -1
- package/dist/types/src/components/ServiceRegistry/ServiceRegistry.stories.d.ts +0 -8
- package/dist/types/src/components/ServiceRegistry/ServiceRegistry.stories.d.ts.map +0 -1
- package/dist/types/src/components/ServiceRegistry/index.d.ts +0 -2
- package/dist/types/src/components/ServiceRegistry/index.d.ts.map +0 -1
- package/dist/types/src/components/Thread/ScrollContainer.d.ts +0 -15
- package/dist/types/src/components/Thread/ScrollContainer.d.ts.map +0 -1
- package/dist/types/src/components/Thread/StatusLine.d.ts +0 -11
- package/dist/types/src/components/Thread/StatusLine.d.ts.map +0 -1
- package/dist/types/src/components/Thread/StatusLine.stories.d.ts +0 -9
- package/dist/types/src/components/Thread/StatusLine.stories.d.ts.map +0 -1
- package/dist/types/src/components/Thread/Tabbed.d.ts +0 -9
- package/dist/types/src/components/Thread/Tabbed.d.ts.map +0 -1
- package/dist/types/src/components/Thread/Tabbed.stories.d.ts +0 -8
- package/dist/types/src/components/Thread/Tabbed.stories.d.ts.map +0 -1
- package/dist/types/src/components/Thread/Thread.d.ts +0 -11
- package/dist/types/src/components/Thread/Thread.d.ts.map +0 -1
- package/dist/types/src/components/Thread/Thread.stories.d.ts +0 -10
- package/dist/types/src/components/Thread/Thread.stories.d.ts.map +0 -1
- package/dist/types/src/components/Thread/ThreadMessage.d.ts +0 -12
- package/dist/types/src/components/Thread/ThreadMessage.d.ts.map +0 -1
- package/dist/types/src/components/Thread/ToggleContainer.d.ts +0 -13
- package/dist/types/src/components/Thread/ToggleContainer.d.ts.map +0 -1
- package/dist/types/src/components/Thread/ToggleContainer.stories.d.ts +0 -9
- package/dist/types/src/components/Thread/ToggleContainer.stories.d.ts.map +0 -1
- package/dist/types/src/components/Thread/index.d.ts +0 -2
- package/dist/types/src/components/Thread/index.d.ts.map +0 -1
- package/dist/types/src/hooks/email.d.ts +0 -4
- package/dist/types/src/hooks/email.d.ts.map +0 -1
- package/dist/types/src/hooks/index.d.ts +0 -6
- package/dist/types/src/hooks/index.d.ts.map +0 -1
- package/dist/types/src/hooks/invocation-handler.d.ts +0 -5
- package/dist/types/src/hooks/invocation-handler.d.ts.map +0 -1
- package/dist/types/src/hooks/processor.d.ts +0 -70
- package/dist/types/src/hooks/processor.d.ts.map +0 -1
- package/dist/types/src/hooks/processor.test.d.ts +0 -2
- package/dist/types/src/hooks/processor.test.d.ts.map +0 -1
- package/dist/types/src/hooks/useChatProcessor.d.ts +0 -7
- package/dist/types/src/hooks/useChatProcessor.d.ts.map +0 -1
- package/dist/types/src/hooks/useLocalTriggerManager.d.ts +0 -3
- package/dist/types/src/hooks/useLocalTriggerManager.d.ts.map +0 -1
- package/dist/types/src/hooks/useMessageQueue.d.ts +0 -41
- package/dist/types/src/hooks/useMessageQueue.d.ts.map +0 -1
- package/dist/types/src/hooks/useServices.d.ts +0 -7
- package/dist/types/src/hooks/useServices.d.ts.map +0 -1
- package/dist/types/src/presets.d.ts +0 -9
- package/dist/types/src/presets.d.ts.map +0 -1
- package/dist/types/src/testing/test-services.d.ts +0 -5
- package/dist/types/src/testing/test-services.d.ts.map +0 -1
- package/dist/types/src/tools/function.d.ts +0 -5
- package/dist/types/src/tools/function.d.ts.map +0 -1
- package/dist/types/src/tools/index.d.ts +0 -3
- package/dist/types/src/tools/index.d.ts.map +0 -1
- package/dist/types/src/tools/openapi.d.ts +0 -10
- package/dist/types/src/tools/openapi.d.ts.map +0 -1
- package/dist/types/src/tools/openapi.test.d.ts +0 -2
- package/dist/types/src/tools/openapi.test.d.ts.map +0 -1
- package/dist/types/src/types/index.d.ts +0 -4
- package/dist/types/src/types/index.d.ts.map +0 -1
- package/dist/types/src/types/registry.d.ts +0 -10
- package/dist/types/src/types/registry.d.ts.map +0 -1
- package/dist/types/src/types/schema.d.ts +0 -221
- package/dist/types/src/types/schema.d.ts.map +0 -1
- package/dist/types/src/types/types.d.ts +0 -18
- package/dist/types/src/types/types.d.ts.map +0 -1
- package/src/artifacts.stories.tsx +0 -241
- package/src/capabilities/ai-client.ts +0 -19
- package/src/capabilities/app-graph-builder.ts +0 -156
- package/src/capabilities/capabilities.ts +0 -12
- package/src/capabilities/intent-resolver.ts +0 -27
- package/src/components/ChatContainer/ChatContainer.tsx +0 -52
- package/src/components/ChatContainer/index.ts +0 -8
- package/src/components/MarkdownViewer/MarkdownViewer.stories.tsx +0 -56
- package/src/components/MarkdownViewer/MarkdownViewer.tsx +0 -79
- package/src/components/MarkdownViewer/index.ts +0 -5
- package/src/components/PromptEditor/PromptEditor.stories.tsx +0 -64
- package/src/components/PromptEditor/PromptEditor.tsx +0 -222
- package/src/components/PromptEditor/index.ts +0 -5
- package/src/components/PromptEditor/prompt-extension.ts +0 -43
- package/src/components/PromptEditor/types.tsx +0 -28
- package/src/components/ServiceRegistry/ServiceRegistry.stories.tsx +0 -49
- package/src/components/ServiceRegistry/ServiceRegistry.tsx +0 -75
- package/src/components/ServiceRegistry/index.ts +0 -5
- package/src/components/Thread/ScrollContainer.tsx +0 -92
- package/src/components/Thread/StatusLine.stories.tsx +0 -52
- package/src/components/Thread/StatusLine.tsx +0 -76
- package/src/components/Thread/Tabbed.stories.tsx +0 -52
- package/src/components/Thread/Tabbed.tsx +0 -72
- package/src/components/Thread/Thread.stories.tsx +0 -190
- package/src/components/Thread/Thread.tsx +0 -156
- package/src/components/Thread/ThreadMessage.tsx +0 -203
- package/src/components/Thread/ToggleContainer.stories.tsx +0 -111
- package/src/components/Thread/ToggleContainer.tsx +0 -103
- package/src/components/Thread/index.ts +0 -5
- package/src/hooks/email.ts +0 -49
- package/src/hooks/index.ts +0 -10
- package/src/hooks/invocation-handler.ts +0 -109
- package/src/hooks/processor.test.ts +0 -15
- package/src/hooks/processor.ts +0 -210
- package/src/hooks/useChatProcessor.tsx +0 -86
- package/src/hooks/useLocalTriggerManager.ts +0 -82
- package/src/hooks/useMessageQueue.ts +0 -23
- package/src/hooks/useServices.ts +0 -28
- package/src/presets.ts +0 -248
- package/src/testing/test-services.ts +0 -131
- package/src/tools/function.ts +0 -47
- package/src/tools/index.ts +0 -6
- package/src/tools/openapi.test.ts +0 -227
- package/src/tools/openapi.ts +0 -331
- package/src/types/index.ts +0 -7
- package/src/types/registry.ts +0 -26
- package/src/types/schema.ts +0 -132
- package/src/types/types.ts +0 -21
|
@@ -1,80 +1,39 @@
|
|
|
1
1
|
import {
|
|
2
|
-
AutomationPanel
|
|
3
|
-
|
|
4
|
-
PromptEditor,
|
|
5
|
-
ServiceRegistry
|
|
6
|
-
} from "./chunk-PQGFC2ZO.mjs";
|
|
2
|
+
AutomationPanel
|
|
3
|
+
} from "./chunk-U7QLNY2S.mjs";
|
|
7
4
|
import {
|
|
8
5
|
TriggerEditor
|
|
9
|
-
} from "./chunk-
|
|
10
|
-
import {
|
|
11
|
-
AiClient,
|
|
12
|
-
AppGraphBuilder,
|
|
13
|
-
IntentResolver,
|
|
14
|
-
MarkdownViewer,
|
|
15
|
-
ReactSurface,
|
|
16
|
-
Thread
|
|
17
|
-
} from "./chunk-DL7XA62G.mjs";
|
|
18
|
-
import "./chunk-BQHXJZ4K.mjs";
|
|
19
|
-
import {
|
|
20
|
-
AIChatType,
|
|
21
|
-
ApiAuthorization,
|
|
22
|
-
AutomationAction,
|
|
23
|
-
ChainInputSchema,
|
|
24
|
-
ChainInputType,
|
|
25
|
-
ChainPromptType,
|
|
26
|
-
ChainType,
|
|
27
|
-
ServiceType,
|
|
28
|
-
categoryIcons
|
|
29
|
-
} from "./chunk-43WRHV2L.mjs";
|
|
6
|
+
} from "./chunk-WY2C7JY4.mjs";
|
|
30
7
|
import {
|
|
31
8
|
AUTOMATION_PLUGIN,
|
|
32
9
|
meta
|
|
33
|
-
} from "./chunk-
|
|
10
|
+
} from "./chunk-OFDNNRLE.mjs";
|
|
34
11
|
|
|
35
12
|
// packages/plugins/experimental/plugin-automation/src/AutomationPlugin.tsx
|
|
36
|
-
import { Capabilities, contributes,
|
|
37
|
-
import { FunctionTrigger } from "@dxos/functions";
|
|
13
|
+
import { Capabilities, contributes, defineModule, definePlugin, Events } from "@dxos/app-framework";
|
|
14
|
+
import { FunctionType, FunctionTrigger } from "@dxos/functions";
|
|
38
15
|
import { ClientCapabilities, ClientEvents } from "@dxos/plugin-client";
|
|
39
|
-
import {
|
|
40
|
-
|
|
16
|
+
import { DeckEvents } from "@dxos/plugin-deck";
|
|
17
|
+
|
|
18
|
+
// packages/plugins/experimental/plugin-automation/src/capabilities/index.ts
|
|
19
|
+
import { lazy } from "@dxos/app-framework";
|
|
20
|
+
var ComplementaryPanel = lazy(() => import("./complementary-panel-4CPOJL4Y.mjs"));
|
|
21
|
+
var ReactSurface = lazy(() => import("./react-surface-SAPMN4PF.mjs"));
|
|
41
22
|
|
|
42
23
|
// packages/plugins/experimental/plugin-automation/src/translations.ts
|
|
43
24
|
var translations_default = [
|
|
44
25
|
{
|
|
45
26
|
"en-US": {
|
|
46
|
-
[AIChatType.typename]: {
|
|
47
|
-
"typename label": "AI Chat"
|
|
48
|
-
},
|
|
49
27
|
[AUTOMATION_PLUGIN]: {
|
|
50
28
|
"plugin name": "Automation",
|
|
51
|
-
"object placeholder": "New prompt",
|
|
52
|
-
"create object label": "Create prompt",
|
|
53
|
-
"create trigger label": "Create trigger",
|
|
54
|
-
"create stack section label": "Create prompt",
|
|
55
|
-
"command placeholder": "Enter slash command...",
|
|
56
|
-
"template placeholder": "Enter template...",
|
|
57
|
-
"value placeholder": "Enter value...",
|
|
58
|
-
"select preset template placeholder": "Select preset",
|
|
59
|
-
"open automation panel label": "Show Automations",
|
|
60
29
|
"automation panel label": "Automations",
|
|
61
|
-
"
|
|
62
|
-
"chat input placeholder": "Ask a question...",
|
|
63
|
-
"chat stop": "Cancel request.",
|
|
64
|
-
"function select label": "Function",
|
|
65
|
-
"function select placeholder": "Select function",
|
|
66
|
-
"function enabled": "Enabled",
|
|
67
|
-
"trigger select label": "Trigger",
|
|
68
|
-
"trigger select placeholder": "Trigger type",
|
|
30
|
+
"new trigger label": "New Trigger",
|
|
69
31
|
"trigger type timer": "Timer",
|
|
70
32
|
"trigger type webhook": "Webhook",
|
|
71
33
|
"trigger type websocket": "Websocket",
|
|
72
34
|
"trigger type subscription": "Subscription",
|
|
73
35
|
"trigger type email": "Email",
|
|
74
|
-
"trigger
|
|
75
|
-
"trigger cron": "Cron",
|
|
76
|
-
"trigger method": "Method",
|
|
77
|
-
"trigger endpoint": "Endpoint",
|
|
36
|
+
"trigger type queue": "Queue",
|
|
78
37
|
"trigger copy url": "Copy URL",
|
|
79
38
|
"trigger copy email": "Copy Email",
|
|
80
39
|
"trigger meta add": "Add",
|
|
@@ -87,345 +46,35 @@ var translations_default = [
|
|
|
87
46
|
|
|
88
47
|
// packages/plugins/experimental/plugin-automation/src/AutomationPlugin.tsx
|
|
89
48
|
var AutomationPlugin = () => definePlugin(meta, [
|
|
90
|
-
defineModule({
|
|
91
|
-
id: `${meta.id}/module/ai-client`,
|
|
92
|
-
activatesOn: ClientEvents.ClientReady,
|
|
93
|
-
activate: AiClient
|
|
94
|
-
}),
|
|
95
49
|
defineModule({
|
|
96
50
|
id: `${meta.id}/module/translations`,
|
|
97
51
|
activatesOn: Events.SetupTranslations,
|
|
98
52
|
activate: () => contributes(Capabilities.Translations, translations_default)
|
|
99
53
|
}),
|
|
100
|
-
defineModule({
|
|
101
|
-
id: `${meta.id}/module/metadata`,
|
|
102
|
-
activatesOn: Events.SetupMetadata,
|
|
103
|
-
activate: () => [
|
|
104
|
-
contributes(Capabilities.Metadata, {
|
|
105
|
-
id: ChainType.typename,
|
|
106
|
-
metadata: {
|
|
107
|
-
placeholder: [
|
|
108
|
-
"object placeholder",
|
|
109
|
-
{
|
|
110
|
-
ns: AUTOMATION_PLUGIN
|
|
111
|
-
}
|
|
112
|
-
],
|
|
113
|
-
icon: "ph--magic-wand--regular",
|
|
114
|
-
// TODO(wittjosiah): Move out of metadata.
|
|
115
|
-
loadReferences: async (chain) => await RefArray.loadAll(chain.prompts ?? [])
|
|
116
|
-
}
|
|
117
|
-
}),
|
|
118
|
-
contributes(Capabilities.Metadata, {
|
|
119
|
-
id: AIChatType.typename,
|
|
120
|
-
metadata: {
|
|
121
|
-
createObject: (props) => createIntent(AutomationAction.Create, props),
|
|
122
|
-
placeholder: [
|
|
123
|
-
"object placeholder",
|
|
124
|
-
{
|
|
125
|
-
ns: AUTOMATION_PLUGIN
|
|
126
|
-
}
|
|
127
|
-
],
|
|
128
|
-
icon: "ph--atom--regular"
|
|
129
|
-
}
|
|
130
|
-
})
|
|
131
|
-
]
|
|
132
|
-
}),
|
|
133
54
|
defineModule({
|
|
134
55
|
id: `${meta.id}/module/schema`,
|
|
135
56
|
activatesOn: ClientEvents.SetupSchema,
|
|
136
|
-
activate: () => [
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
FunctionTrigger,
|
|
141
|
-
ServiceType
|
|
142
|
-
]),
|
|
143
|
-
contributes(ClientCapabilities.Schema, [
|
|
144
|
-
AIChatType
|
|
145
|
-
])
|
|
146
|
-
]
|
|
57
|
+
activate: () => contributes(ClientCapabilities.Schema, [
|
|
58
|
+
FunctionType,
|
|
59
|
+
FunctionTrigger
|
|
60
|
+
])
|
|
147
61
|
}),
|
|
148
62
|
defineModule({
|
|
149
63
|
id: `${meta.id}/module/complementary-panels`,
|
|
150
|
-
activatesOn:
|
|
151
|
-
activate:
|
|
152
|
-
contributes(DeckCapabilities.ComplementaryPanel, {
|
|
153
|
-
id: "service-registry",
|
|
154
|
-
label: [
|
|
155
|
-
"service registry label",
|
|
156
|
-
{
|
|
157
|
-
ns: AUTOMATION_PLUGIN
|
|
158
|
-
}
|
|
159
|
-
],
|
|
160
|
-
icon: "ph--plugs--regular"
|
|
161
|
-
}),
|
|
162
|
-
contributes(DeckCapabilities.ComplementaryPanel, {
|
|
163
|
-
id: "automation",
|
|
164
|
-
label: [
|
|
165
|
-
"automation panel label",
|
|
166
|
-
{
|
|
167
|
-
ns: AUTOMATION_PLUGIN
|
|
168
|
-
}
|
|
169
|
-
],
|
|
170
|
-
icon: "ph--magic-wand--regular"
|
|
171
|
-
})
|
|
172
|
-
]
|
|
64
|
+
activatesOn: DeckEvents.SetupComplementaryPanels,
|
|
65
|
+
activate: ComplementaryPanel
|
|
173
66
|
}),
|
|
174
67
|
defineModule({
|
|
175
68
|
id: `${meta.id}/module/react-surface`,
|
|
176
|
-
activatesOn: Events.
|
|
69
|
+
activatesOn: Events.SetupReactSurface,
|
|
177
70
|
activate: ReactSurface
|
|
178
|
-
}),
|
|
179
|
-
defineModule({
|
|
180
|
-
id: `${meta.id}/module/app-graph-builder`,
|
|
181
|
-
activatesOn: Events.SetupAppGraph,
|
|
182
|
-
activate: AppGraphBuilder
|
|
183
|
-
}),
|
|
184
|
-
defineModule({
|
|
185
|
-
id: `${meta.id}/module/intent-resolver`,
|
|
186
|
-
activatesOn: Events.SetupIntents,
|
|
187
|
-
activate: IntentResolver
|
|
188
71
|
})
|
|
189
72
|
]);
|
|
190
|
-
|
|
191
|
-
// packages/plugins/experimental/plugin-automation/src/presets.ts
|
|
192
|
-
import { create } from "@dxos/live-object";
|
|
193
|
-
var str = (...text) => text.filter((value) => value !== void 0 && value !== false).flat().join("\n");
|
|
194
|
-
var chainPresets = [
|
|
195
|
-
{
|
|
196
|
-
id: "dxos.org/prompt/translate",
|
|
197
|
-
title: "Translate",
|
|
198
|
-
createPrompt: () => create(ChainPromptType, {
|
|
199
|
-
command: "say",
|
|
200
|
-
template: str(
|
|
201
|
-
// prettier-ignore
|
|
202
|
-
"Translate the following into {language}:",
|
|
203
|
-
"",
|
|
204
|
-
"---",
|
|
205
|
-
"",
|
|
206
|
-
"{input}"
|
|
207
|
-
),
|
|
208
|
-
inputs: [
|
|
209
|
-
{
|
|
210
|
-
type: ChainInputType.VALUE,
|
|
211
|
-
name: "language",
|
|
212
|
-
value: "japanese"
|
|
213
|
-
},
|
|
214
|
-
{
|
|
215
|
-
type: ChainInputType.PASS_THROUGH,
|
|
216
|
-
name: "input"
|
|
217
|
-
}
|
|
218
|
-
]
|
|
219
|
-
})
|
|
220
|
-
},
|
|
221
|
-
{
|
|
222
|
-
id: "dxos.org/prompt/chess",
|
|
223
|
-
title: "Chess",
|
|
224
|
-
createPrompt: () => create(ChainPromptType, {
|
|
225
|
-
command: "hint",
|
|
226
|
-
template: str(
|
|
227
|
-
// prettier-ignore
|
|
228
|
-
"You are a machine that is an expert chess player.",
|
|
229
|
-
"",
|
|
230
|
-
"The move history of the current game is: {history}",
|
|
231
|
-
"",
|
|
232
|
-
"Suggest the next move and very briefly explain your strategy in a couple of sentences."
|
|
233
|
-
),
|
|
234
|
-
inputs: [
|
|
235
|
-
{
|
|
236
|
-
type: ChainInputType.CONTEXT,
|
|
237
|
-
name: "history",
|
|
238
|
-
value: "object.pgn"
|
|
239
|
-
}
|
|
240
|
-
]
|
|
241
|
-
})
|
|
242
|
-
},
|
|
243
|
-
{
|
|
244
|
-
id: "dxos.org/prompt/mermaid",
|
|
245
|
-
title: "Mermaid",
|
|
246
|
-
createPrompt: () => create(ChainPromptType, {
|
|
247
|
-
command: "draw",
|
|
248
|
-
template: str(
|
|
249
|
-
// prettier-ignore
|
|
250
|
-
"Create a simplified mermaid graph representing the text below.",
|
|
251
|
-
"Do not explain anything.",
|
|
252
|
-
"",
|
|
253
|
-
"---",
|
|
254
|
-
"",
|
|
255
|
-
"{input}"
|
|
256
|
-
),
|
|
257
|
-
inputs: [
|
|
258
|
-
{
|
|
259
|
-
type: ChainInputType.PASS_THROUGH,
|
|
260
|
-
name: "input"
|
|
261
|
-
}
|
|
262
|
-
]
|
|
263
|
-
})
|
|
264
|
-
},
|
|
265
|
-
{
|
|
266
|
-
id: "dxos.org/prompt/list",
|
|
267
|
-
title: "List",
|
|
268
|
-
createPrompt: () => create(ChainPromptType, {
|
|
269
|
-
command: "list",
|
|
270
|
-
template: str(
|
|
271
|
-
// prettier-ignore
|
|
272
|
-
"You are a machine that only replies with valid, iterable RFC8259 compliant JSON in your responses.",
|
|
273
|
-
"Your entire response should be a single array of JSON objects.",
|
|
274
|
-
"",
|
|
275
|
-
"Your entire response should be a map where the key is the type and the value is a single array of JSON objects conforming to the following types:",
|
|
276
|
-
"",
|
|
277
|
-
"{schema}",
|
|
278
|
-
"",
|
|
279
|
-
"---",
|
|
280
|
-
"",
|
|
281
|
-
"{question}"
|
|
282
|
-
),
|
|
283
|
-
inputs: [
|
|
284
|
-
{
|
|
285
|
-
type: ChainInputType.SCHEMA,
|
|
286
|
-
name: "schema",
|
|
287
|
-
value: "example.com/type/project"
|
|
288
|
-
},
|
|
289
|
-
{
|
|
290
|
-
type: ChainInputType.PASS_THROUGH,
|
|
291
|
-
name: "question"
|
|
292
|
-
}
|
|
293
|
-
]
|
|
294
|
-
})
|
|
295
|
-
},
|
|
296
|
-
{
|
|
297
|
-
id: "dxos.org/prompt/base",
|
|
298
|
-
title: "RAG",
|
|
299
|
-
createPrompt: () => create(ChainPromptType, {
|
|
300
|
-
command: "rag",
|
|
301
|
-
template: str(
|
|
302
|
-
// prettier-ignore
|
|
303
|
-
"Very briefly answer the question based only on the following context and say if you don't know the answer.",
|
|
304
|
-
// 'answer the question using the following context as well as your training data:',
|
|
305
|
-
"",
|
|
306
|
-
"{context}",
|
|
307
|
-
"",
|
|
308
|
-
"---",
|
|
309
|
-
"",
|
|
310
|
-
"question: {question}"
|
|
311
|
-
),
|
|
312
|
-
inputs: [
|
|
313
|
-
{
|
|
314
|
-
type: ChainInputType.RETRIEVER,
|
|
315
|
-
name: "context"
|
|
316
|
-
},
|
|
317
|
-
{
|
|
318
|
-
type: ChainInputType.CONTEXT,
|
|
319
|
-
name: "question",
|
|
320
|
-
value: "object.text"
|
|
321
|
-
}
|
|
322
|
-
]
|
|
323
|
-
})
|
|
324
|
-
},
|
|
325
|
-
{
|
|
326
|
-
id: "dxos.org/prompt/lookup",
|
|
327
|
-
title: "Lookup",
|
|
328
|
-
createPrompt: () => create(ChainPromptType, {
|
|
329
|
-
command: "lookup",
|
|
330
|
-
template: str(
|
|
331
|
-
// prettier-ignore
|
|
332
|
-
"Lookup and very briefly summarize the following topic in one or two sentences:",
|
|
333
|
-
"",
|
|
334
|
-
"---",
|
|
335
|
-
"",
|
|
336
|
-
"{input}"
|
|
337
|
-
),
|
|
338
|
-
inputs: [
|
|
339
|
-
{
|
|
340
|
-
type: ChainInputType.CONTEXT,
|
|
341
|
-
name: "input",
|
|
342
|
-
value: "text"
|
|
343
|
-
}
|
|
344
|
-
]
|
|
345
|
-
})
|
|
346
|
-
},
|
|
347
|
-
{
|
|
348
|
-
id: "dxos.org/prompt/extract",
|
|
349
|
-
title: "Extract",
|
|
350
|
-
createPrompt: () => create(ChainPromptType, {
|
|
351
|
-
command: "extract",
|
|
352
|
-
template: str(
|
|
353
|
-
// prettier-ignore
|
|
354
|
-
"List all people and companies mentioned in the text below.",
|
|
355
|
-
"",
|
|
356
|
-
"You are a machine that only replies with valid, iterable RFC8259 compliant JSON in your responses.",
|
|
357
|
-
"Your entire response should be a map where the key is the type and the value is a single array of JSON objects conforming to the following types:",
|
|
358
|
-
"",
|
|
359
|
-
"{contact}",
|
|
360
|
-
"{company}",
|
|
361
|
-
"",
|
|
362
|
-
"---",
|
|
363
|
-
"",
|
|
364
|
-
"{input}"
|
|
365
|
-
),
|
|
366
|
-
inputs: [
|
|
367
|
-
{
|
|
368
|
-
type: ChainInputType.SCHEMA,
|
|
369
|
-
name: "contact",
|
|
370
|
-
value: "example.com/type/contact"
|
|
371
|
-
},
|
|
372
|
-
{
|
|
373
|
-
type: ChainInputType.SCHEMA,
|
|
374
|
-
name: "company",
|
|
375
|
-
value: "example.com/type/organization"
|
|
376
|
-
},
|
|
377
|
-
{
|
|
378
|
-
type: ChainInputType.CONTEXT,
|
|
379
|
-
name: "input",
|
|
380
|
-
value: "text"
|
|
381
|
-
}
|
|
382
|
-
]
|
|
383
|
-
})
|
|
384
|
-
},
|
|
385
|
-
{
|
|
386
|
-
id: "dxos.org/prompt/discord",
|
|
387
|
-
title: "Summarize",
|
|
388
|
-
createPrompt: () => create(ChainPromptType, {
|
|
389
|
-
command: "summarize",
|
|
390
|
-
template: str(
|
|
391
|
-
// prettier-ignore
|
|
392
|
-
"Summarize what the team is working on and format it as a markdown table without any explanation.",
|
|
393
|
-
"",
|
|
394
|
-
"---",
|
|
395
|
-
"",
|
|
396
|
-
"{context}"
|
|
397
|
-
),
|
|
398
|
-
inputs: [
|
|
399
|
-
{
|
|
400
|
-
type: ChainInputType.RESOLVER,
|
|
401
|
-
name: "context",
|
|
402
|
-
value: "discord.messages.recent"
|
|
403
|
-
}
|
|
404
|
-
]
|
|
405
|
-
})
|
|
406
|
-
}
|
|
407
|
-
];
|
|
408
73
|
export {
|
|
409
|
-
AIChatType,
|
|
410
74
|
AUTOMATION_PLUGIN,
|
|
411
|
-
ApiAuthorization,
|
|
412
|
-
AutomationAction,
|
|
413
75
|
AutomationPanel,
|
|
414
76
|
AutomationPlugin,
|
|
415
|
-
ChainInputSchema,
|
|
416
|
-
ChainInputType,
|
|
417
|
-
ChainPromptType,
|
|
418
|
-
ChainType,
|
|
419
|
-
ChatContainer,
|
|
420
|
-
MarkdownViewer,
|
|
421
|
-
PromptEditor,
|
|
422
|
-
ServiceRegistry,
|
|
423
|
-
ServiceType,
|
|
424
|
-
Thread,
|
|
425
77
|
TriggerEditor,
|
|
426
|
-
|
|
427
|
-
chainPresets,
|
|
428
|
-
meta,
|
|
429
|
-
str
|
|
78
|
+
meta
|
|
430
79
|
};
|
|
431
80
|
//# sourceMappingURL=index.mjs.map
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
|
-
"sources": ["../../../src/AutomationPlugin.tsx", "../../../src/
|
|
4
|
-
"sourcesContent": ["//\n// Copyright 2023 DXOS.org\n//\n\nimport { Capabilities, contributes, createIntent, defineModule, definePlugin, Events } from '@dxos/app-framework';\nimport { FunctionTrigger } from '@dxos/functions';\nimport { ClientCapabilities, ClientEvents } from '@dxos/plugin-client';\nimport { DeckCapabilities } from '@dxos/plugin-deck';\nimport { RefArray } from '@dxos/react-client/echo';\n\nimport { AiClient, AppGraphBuilder, IntentResolver, ReactSurface } from './capabilities';\nimport { AUTOMATION_PLUGIN, meta } from './meta';\nimport translations from './translations';\nimport { AutomationAction, ChainPromptType, ChainType, AIChatType, ServiceType } from './types';\n\n// TODO(wittjosiah): Rename to AssistantPlugin?\nexport const AutomationPlugin = () =>\n definePlugin(meta, [\n defineModule({\n id: `${meta.id}/module/ai-client`,\n activatesOn: ClientEvents.ClientReady,\n activate: AiClient,\n }),\n defineModule({\n id: `${meta.id}/module/translations`,\n activatesOn: Events.SetupTranslations,\n activate: () => contributes(Capabilities.Translations, translations),\n }),\n defineModule({\n id: `${meta.id}/module/metadata`,\n activatesOn: Events.SetupMetadata,\n activate: () => [\n contributes(Capabilities.Metadata, {\n id: ChainType.typename,\n metadata: {\n placeholder: ['object placeholder', { ns: AUTOMATION_PLUGIN }],\n icon: 'ph--magic-wand--regular',\n // TODO(wittjosiah): Move out of metadata.\n loadReferences: async (chain: ChainType) => await RefArray.loadAll(chain.prompts ?? []),\n },\n }),\n contributes(Capabilities.Metadata, {\n id: AIChatType.typename,\n metadata: {\n createObject: (props: { name?: string }) => createIntent(AutomationAction.Create, props),\n placeholder: ['object placeholder', { ns: AUTOMATION_PLUGIN }],\n icon: 'ph--atom--regular',\n },\n }),\n ],\n }),\n defineModule({\n id: `${meta.id}/module/schema`,\n activatesOn: ClientEvents.SetupSchema,\n activate: () => [\n contributes(ClientCapabilities.SystemSchema, [ChainType, ChainPromptType, FunctionTrigger, ServiceType]),\n contributes(ClientCapabilities.Schema, [AIChatType]),\n ],\n }),\n defineModule({\n id: `${meta.id}/module/complementary-panels`,\n activatesOn: Events.Startup,\n activate: () => [\n contributes(DeckCapabilities.ComplementaryPanel, {\n id: 'service-registry',\n label: ['service registry label', { ns: AUTOMATION_PLUGIN }],\n icon: 'ph--plugs--regular',\n }),\n contributes(DeckCapabilities.ComplementaryPanel, {\n id: 'automation',\n label: ['automation panel label', { ns: AUTOMATION_PLUGIN }],\n icon: 'ph--magic-wand--regular',\n }),\n ],\n }),\n defineModule({\n id: `${meta.id}/module/react-surface`,\n activatesOn: Events.SetupSurfaces,\n activate: ReactSurface,\n }),\n defineModule({\n id: `${meta.id}/module/app-graph-builder`,\n activatesOn: Events.SetupAppGraph,\n activate: AppGraphBuilder,\n }),\n defineModule({\n id: `${meta.id}/module/intent-resolver`,\n activatesOn: Events.SetupIntents,\n activate: IntentResolver,\n }),\n ]);\n", "//\n// Copyright 2023 DXOS.org\n//\n\nimport { AUTOMATION_PLUGIN } from './meta';\nimport { AIChatType } from './types';\n\nexport default [\n {\n 'en-US': {\n [AIChatType.typename]: {\n 'typename label': 'AI Chat',\n },\n [AUTOMATION_PLUGIN]: {\n 'plugin name': 'Automation',\n 'object placeholder': 'New prompt',\n 'create object label': 'Create prompt',\n 'create trigger label': 'Create trigger',\n 'create stack section label': 'Create prompt',\n 'command placeholder': 'Enter slash command...',\n 'template placeholder': 'Enter template...',\n 'value placeholder': 'Enter value...',\n 'select preset template placeholder': 'Select preset',\n 'open automation panel label': 'Show Automations',\n 'automation panel label': 'Automations',\n 'service registry label': 'Service Registry',\n\n 'chat input placeholder': 'Ask a question...',\n 'chat stop': 'Cancel request.',\n\n 'function select label': 'Function',\n 'function select placeholder': 'Select function',\n 'function enabled': 'Enabled',\n\n 'trigger select label': 'Trigger',\n 'trigger select placeholder': 'Trigger type',\n\n 'trigger type timer': 'Timer',\n 'trigger type webhook': 'Webhook',\n 'trigger type websocket': 'Websocket',\n 'trigger type subscription': 'Subscription',\n 'trigger type email': 'Email',\n\n 'trigger filter': 'Filter',\n 'trigger cron': 'Cron',\n 'trigger method': 'Method',\n 'trigger endpoint': 'Endpoint',\n\n 'trigger copy url': 'Copy URL',\n 'trigger copy email': 'Copy Email',\n\n 'trigger meta add': 'Add',\n 'trigger meta remove': 'Remove',\n 'trigger meta prop name placeholder': 'New meta property name',\n },\n },\n },\n];\n", "//\n// Copyright 2024 DXOS.org\n//\n\nimport { create } from '@dxos/live-object';\n\nimport { ChainInputType, ChainPromptType } from './types';\n\nexport const str = (...text: (string | undefined | boolean)[]): string =>\n text\n .filter((value) => value !== undefined && value !== false)\n .flat()\n .join('\\n');\n\nexport type Preset = {\n id: string;\n title: string;\n createPrompt: () => ChainPromptType;\n};\n\nexport const chainPresets: Preset[] = [\n {\n id: 'dxos.org/prompt/translate',\n title: 'Translate',\n createPrompt: () =>\n create(ChainPromptType, {\n command: 'say',\n template: str(\n // prettier-ignore\n 'Translate the following into {language}:',\n '',\n '---',\n '',\n '{input}',\n ),\n inputs: [\n {\n type: ChainInputType.VALUE,\n name: 'language',\n value: 'japanese',\n },\n {\n type: ChainInputType.PASS_THROUGH,\n name: 'input',\n },\n // TODO(burdon): Message.\n // {\n // type: ChainInputType.CONTEXT,\n // name: 'input',\n // value: 'object.text',\n // },\n ],\n }),\n },\n {\n id: 'dxos.org/prompt/chess',\n title: 'Chess',\n createPrompt: () =>\n create(ChainPromptType, {\n command: 'hint',\n template: str(\n // prettier-ignore\n 'You are a machine that is an expert chess player.',\n '',\n 'The move history of the current game is: {history}',\n '',\n 'Suggest the next move and very briefly explain your strategy in a couple of sentences.',\n ),\n inputs: [\n {\n type: ChainInputType.CONTEXT,\n name: 'history',\n value: 'object.pgn',\n },\n ],\n }),\n },\n {\n id: 'dxos.org/prompt/mermaid',\n title: 'Mermaid',\n createPrompt: () =>\n create(ChainPromptType, {\n command: 'draw',\n template: str(\n // prettier-ignore\n 'Create a simplified mermaid graph representing the text below.',\n 'Do not explain anything.',\n '',\n '---',\n '',\n '{input}',\n ),\n inputs: [\n {\n type: ChainInputType.PASS_THROUGH,\n name: 'input',\n },\n ],\n }),\n },\n {\n id: 'dxos.org/prompt/list',\n title: 'List',\n createPrompt: () =>\n create(ChainPromptType, {\n command: 'list',\n template: str(\n // prettier-ignore\n 'You are a machine that only replies with valid, iterable RFC8259 compliant JSON in your responses.',\n 'Your entire response should be a single array of JSON objects.',\n '',\n 'Your entire response should be a map where the key is the type and the value is a single array of JSON objects conforming to the following types:',\n '',\n '{schema}',\n '',\n '---',\n '',\n '{question}',\n ),\n inputs: [\n {\n type: ChainInputType.SCHEMA,\n name: 'schema',\n value: 'example.com/type/project',\n },\n {\n type: ChainInputType.PASS_THROUGH,\n name: 'question',\n },\n ],\n }),\n },\n {\n id: 'dxos.org/prompt/base',\n title: 'RAG',\n createPrompt: () =>\n create(ChainPromptType, {\n command: 'rag',\n template: str(\n // prettier-ignore\n \"Very briefly answer the question based only on the following context and say if you don't know the answer.\",\n // 'answer the question using the following context as well as your training data:',\n '',\n '{context}',\n '',\n '---',\n '',\n 'question: {question}',\n ),\n inputs: [\n {\n type: ChainInputType.RETRIEVER,\n name: 'context',\n },\n {\n type: ChainInputType.CONTEXT,\n name: 'question',\n value: 'object.text',\n },\n ],\n }),\n },\n {\n id: 'dxos.org/prompt/lookup',\n title: 'Lookup',\n createPrompt: () =>\n create(ChainPromptType, {\n command: 'lookup',\n template: str(\n // prettier-ignore\n 'Lookup and very briefly summarize the following topic in one or two sentences:',\n '',\n '---',\n '',\n '{input}',\n ),\n inputs: [\n {\n type: ChainInputType.CONTEXT,\n name: 'input',\n value: 'text',\n },\n ],\n }),\n },\n {\n id: 'dxos.org/prompt/extract',\n title: 'Extract',\n createPrompt: () =>\n create(ChainPromptType, {\n command: 'extract',\n template: str(\n // prettier-ignore\n 'List all people and companies mentioned in the text below.',\n '',\n 'You are a machine that only replies with valid, iterable RFC8259 compliant JSON in your responses.',\n 'Your entire response should be a map where the key is the type and the value is a single array of JSON objects conforming to the following types:',\n '',\n '{contact}',\n '{company}',\n '',\n '---',\n '',\n '{input}',\n ),\n inputs: [\n {\n type: ChainInputType.SCHEMA,\n name: 'contact',\n value: 'example.com/type/contact',\n },\n {\n type: ChainInputType.SCHEMA,\n name: 'company',\n value: 'example.com/type/organization',\n },\n {\n type: ChainInputType.CONTEXT,\n name: 'input',\n value: 'text',\n },\n ],\n }),\n },\n {\n id: 'dxos.org/prompt/discord',\n title: 'Summarize',\n createPrompt: () =>\n create(ChainPromptType, {\n command: 'summarize',\n template: str(\n // prettier-ignore\n 'Summarize what the team is working on and format it as a markdown table without any explanation.',\n '',\n '---',\n '',\n '{context}',\n ),\n inputs: [\n {\n type: ChainInputType.RESOLVER,\n name: 'context',\n value: 'discord.messages.recent',\n },\n ],\n }),\n },\n];\n"],
|
|
5
|
-
"mappings": "
|
|
6
|
-
"names": ["Capabilities", "contributes", "
|
|
3
|
+
"sources": ["../../../src/AutomationPlugin.tsx", "../../../src/capabilities/index.ts", "../../../src/translations.ts"],
|
|
4
|
+
"sourcesContent": ["//\n// Copyright 2023 DXOS.org\n//\n\nimport { Capabilities, contributes, defineModule, definePlugin, Events } from '@dxos/app-framework';\nimport { FunctionType, FunctionTrigger } from '@dxos/functions';\nimport { ClientCapabilities, ClientEvents } from '@dxos/plugin-client';\nimport { DeckEvents } from '@dxos/plugin-deck';\n\nimport { ComplementaryPanel, ReactSurface } from './capabilities';\nimport { meta } from './meta';\nimport translations from './translations';\n\nexport const AutomationPlugin = () =>\n definePlugin(meta, [\n defineModule({\n id: `${meta.id}/module/translations`,\n activatesOn: Events.SetupTranslations,\n activate: () => contributes(Capabilities.Translations, translations),\n }),\n defineModule({\n id: `${meta.id}/module/schema`,\n activatesOn: ClientEvents.SetupSchema,\n activate: () => contributes(ClientCapabilities.Schema, [FunctionType, FunctionTrigger]),\n }),\n defineModule({\n id: `${meta.id}/module/complementary-panels`,\n activatesOn: DeckEvents.SetupComplementaryPanels,\n activate: ComplementaryPanel,\n }),\n defineModule({\n id: `${meta.id}/module/react-surface`,\n activatesOn: Events.SetupReactSurface,\n activate: ReactSurface,\n }),\n ]);\n", "//\n// Copyright 2025 DXOS.org\n//\n\nimport { lazy } from '@dxos/app-framework';\n\nexport const ComplementaryPanel = lazy(() => import('./complementary-panel'));\nexport const ReactSurface = lazy(() => import('./react-surface'));\n", "//\n// Copyright 2023 DXOS.org\n//\n\nimport { AUTOMATION_PLUGIN } from './meta';\n\nexport default [\n {\n 'en-US': {\n [AUTOMATION_PLUGIN]: {\n 'plugin name': 'Automation',\n 'automation panel label': 'Automations',\n\n 'new trigger label': 'New Trigger',\n 'trigger type timer': 'Timer',\n 'trigger type webhook': 'Webhook',\n 'trigger type websocket': 'Websocket',\n 'trigger type subscription': 'Subscription',\n 'trigger type email': 'Email',\n 'trigger type queue': 'Queue',\n\n 'trigger copy url': 'Copy URL',\n 'trigger copy email': 'Copy Email',\n\n 'trigger meta add': 'Add',\n 'trigger meta remove': 'Remove',\n 'trigger meta prop name placeholder': 'New meta property name',\n },\n },\n },\n];\n"],
|
|
5
|
+
"mappings": ";;;;;;;;;;;;AAIA,SAASA,cAAcC,aAAaC,cAAcC,cAAcC,cAAc;AAC9E,SAASC,cAAcC,uBAAuB;AAC9C,SAASC,oBAAoBC,oBAAoB;AACjD,SAASC,kBAAkB;;;ACH3B,SAASC,YAAY;AAEd,IAAMC,qBAAqBC,KAAK,MAAM,OAAO,oCAAA,CAAA;AAC7C,IAAMC,eAAeD,KAAK,MAAM,OAAO,8BAAA,CAAA;;;ACD9C,IAAA,uBAAe;EACb;IACE,SAAS;MACP,CAACE,iBAAAA,GAAoB;QACnB,eAAe;QACf,0BAA0B;QAE1B,qBAAqB;QACrB,sBAAsB;QACtB,wBAAwB;QACxB,0BAA0B;QAC1B,6BAA6B;QAC7B,sBAAsB;QACtB,sBAAsB;QAEtB,oBAAoB;QACpB,sBAAsB;QAEtB,oBAAoB;QACpB,uBAAuB;QACvB,sCAAsC;MACxC;IACF;EACF;;;;AFhBK,IAAMC,mBAAmB,MAC9BC,aAAaC,MAAM;EACjBC,aAAa;IACXC,IAAI,GAAGF,KAAKE,EAAE;IACdC,aAAaC,OAAOC;IACpBC,UAAU,MAAMC,YAAYC,aAAaC,cAAcC,oBAAAA;EACzD,CAAA;EACAT,aAAa;IACXC,IAAI,GAAGF,KAAKE,EAAE;IACdC,aAAaQ,aAAaC;IAC1BN,UAAU,MAAMC,YAAYM,mBAAmBC,QAAQ;MAACC;MAAcC;KAAgB;EACxF,CAAA;EACAf,aAAa;IACXC,IAAI,GAAGF,KAAKE,EAAE;IACdC,aAAac,WAAWC;IACxBZ,UAAUa;EACZ,CAAA;EACAlB,aAAa;IACXC,IAAI,GAAGF,KAAKE,EAAE;IACdC,aAAaC,OAAOgB;IACpBd,UAAUe;EACZ,CAAA;CACD;",
|
|
6
|
+
"names": ["Capabilities", "contributes", "defineModule", "definePlugin", "Events", "FunctionType", "FunctionTrigger", "ClientCapabilities", "ClientEvents", "DeckEvents", "lazy", "ComplementaryPanel", "lazy", "ReactSurface", "AUTOMATION_PLUGIN", "AutomationPlugin", "definePlugin", "meta", "defineModule", "id", "activatesOn", "Events", "SetupTranslations", "activate", "contributes", "Capabilities", "Translations", "translations", "ClientEvents", "SetupSchema", "ClientCapabilities", "Schema", "FunctionType", "FunctionTrigger", "DeckEvents", "SetupComplementaryPanels", "ComplementaryPanel", "SetupReactSurface", "ReactSurface"]
|
|
7
7
|
}
|