@dxos/plugin-transcription 0.9.1-main.c7dcc2e112 → 0.10.0
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/PLUGIN.mdl +5 -5
- package/dist/lib/neutral/{TranscriptionArticle-S56VVOSF.mjs → TranscriptionArticle-FEWCWG4A.mjs} +3 -6
- package/dist/lib/neutral/TranscriptionArticle-FEWCWG4A.mjs.map +7 -0
- package/dist/lib/neutral/TranscriptionPlugin.mjs +25 -4
- package/dist/lib/neutral/TranscriptionPlugin.mjs.map +3 -3
- package/dist/lib/neutral/TranscriptionPlugin.node.mjs +3 -3
- package/dist/lib/neutral/TranscriptionPlugin.node.mjs.map +3 -3
- package/dist/lib/neutral/app-graph-builder-GQRMI22E.mjs +48 -0
- package/dist/lib/neutral/app-graph-builder-GQRMI22E.mjs.map +7 -0
- package/dist/lib/neutral/capabilities/index.mjs +17 -5
- package/dist/lib/neutral/capabilities/index.mjs.map +3 -3
- package/dist/lib/neutral/{chunk-XZVDAYM6.mjs → chunk-5BVHY75B.mjs} +2 -2
- package/dist/lib/neutral/{chunk-XZVDAYM6.mjs.map → chunk-5BVHY75B.mjs.map} +1 -1
- package/dist/lib/neutral/chunk-HNXSU7HJ.mjs +8 -0
- package/dist/lib/neutral/chunk-KOXLGGSL.mjs +30 -0
- package/dist/lib/neutral/chunk-KOXLGGSL.mjs.map +7 -0
- package/dist/lib/neutral/{chunk-2URVUJT4.mjs → chunk-MDV7NBFJ.mjs} +31 -8
- package/dist/lib/neutral/chunk-MDV7NBFJ.mjs.map +7 -0
- package/dist/lib/neutral/components/index.mjs +114 -258
- package/dist/lib/neutral/components/index.mjs.map +4 -4
- package/dist/lib/neutral/containers/index.mjs +1 -1
- package/dist/lib/neutral/{create-7NGOP7JP.mjs → create-HNHGCKZ4.mjs} +2 -2
- package/dist/lib/neutral/{enrich-message-F2AOM53F.mjs → enrich-message-DSJU4TXC.mjs} +2 -2
- package/dist/lib/neutral/entity-lookup-PCDW7NC4.mjs +25 -0
- package/dist/lib/neutral/entity-lookup-PCDW7NC4.mjs.map +7 -0
- package/dist/lib/neutral/hooks/index.mjs +93 -15
- package/dist/lib/neutral/hooks/index.mjs.map +4 -4
- package/dist/lib/neutral/index.mjs +6 -32
- package/dist/lib/neutral/markdown-extension-CCDXXY7E.mjs +16 -0
- package/dist/lib/neutral/markdown-extension-CCDXXY7E.mjs.map +7 -0
- package/dist/lib/neutral/meta.json +1 -1
- package/dist/lib/neutral/meta.mjs +1 -1
- package/dist/lib/neutral/{open-42H72C4G.mjs → open-SNMZXXYO.mjs} +4 -6
- package/dist/lib/neutral/open-SNMZXXYO.mjs.map +7 -0
- package/dist/lib/neutral/operations/index.mjs +1 -1
- package/dist/lib/neutral/pipeline-status-XMWMAUJY.mjs +17 -0
- package/dist/lib/neutral/pipeline-status-XMWMAUJY.mjs.map +7 -0
- package/dist/lib/neutral/plugin.mjs +2 -2
- package/dist/lib/neutral/recording-session-IADO7ATU.mjs +15 -0
- package/dist/lib/neutral/recording-session-IADO7ATU.mjs.map +7 -0
- package/dist/lib/neutral/{settings-DUS32HOM.mjs → settings-7KE4MABW.mjs} +3 -2
- package/dist/lib/neutral/{settings-DUS32HOM.mjs.map → settings-7KE4MABW.mjs.map} +3 -3
- package/dist/lib/neutral/skill-definition-DXNK324V.mjs +15 -0
- package/dist/lib/neutral/skill-definition-DXNK324V.mjs.map +7 -0
- package/dist/lib/neutral/skills/index.mjs +8 -0
- package/dist/lib/neutral/{summarize-45WVUPED.mjs → summarize-LBUZTOTH.mjs} +4 -4
- package/dist/lib/neutral/summarize-LBUZTOTH.mjs.map +7 -0
- package/dist/lib/neutral/{text-content-XZ3HK4OT.mjs → text-content-NOWR642C.mjs} +2 -4
- package/dist/lib/neutral/text-content-NOWR642C.mjs.map +7 -0
- package/dist/lib/neutral/transcriber-6XZHUUHK.mjs +174 -0
- package/dist/lib/neutral/transcriber-6XZHUUHK.mjs.map +7 -0
- package/dist/lib/neutral/transcription-driver-DN6ELQXZ.mjs +207 -0
- package/dist/lib/neutral/transcription-driver-DN6ELQXZ.mjs.map +7 -0
- package/dist/lib/neutral/translations.mjs +7 -0
- package/dist/lib/neutral/translations.mjs.map +2 -2
- package/dist/lib/neutral/types/index.mjs +1 -1
- package/dist/types/src/TranscriptionPlugin.d.ts.map +1 -1
- package/dist/types/src/capabilities/app-graph-builder.d.ts +5 -0
- package/dist/types/src/capabilities/app-graph-builder.d.ts.map +1 -0
- package/dist/types/src/capabilities/entity-lookup.d.ts +10 -0
- package/dist/types/src/capabilities/entity-lookup.d.ts.map +1 -0
- package/dist/types/src/capabilities/index.d.ts +7 -1
- package/dist/types/src/capabilities/index.d.ts.map +1 -1
- package/dist/types/src/capabilities/markdown-extension.d.ts +5 -0
- package/dist/types/src/capabilities/markdown-extension.d.ts.map +1 -0
- package/dist/types/src/capabilities/pipeline-status.d.ts +9 -0
- package/dist/types/src/capabilities/pipeline-status.d.ts.map +1 -0
- package/dist/types/src/capabilities/react-surface.d.ts +1 -1
- package/dist/types/src/capabilities/recording-session.d.ts +5 -0
- package/dist/types/src/capabilities/recording-session.d.ts.map +1 -0
- package/dist/types/src/capabilities/settings.d.ts +1 -3
- package/dist/types/src/capabilities/settings.d.ts.map +1 -1
- package/dist/types/src/capabilities/skill-definition.d.ts +5 -0
- package/dist/types/src/capabilities/skill-definition.d.ts.map +1 -0
- package/dist/types/src/capabilities/text-content.d.ts +1 -4
- package/dist/types/src/capabilities/transcriber.d.ts +4 -3
- package/dist/types/src/capabilities/transcriber.d.ts.map +1 -1
- package/dist/types/src/capabilities/transcription-driver.d.ts +5 -0
- package/dist/types/src/capabilities/transcription-driver.d.ts.map +1 -0
- package/dist/types/src/components/Mic/Mic.d.ts +12 -0
- package/dist/types/src/components/Mic/Mic.d.ts.map +1 -0
- package/dist/types/src/components/{Oracle/Oracle.stories.d.ts → Mic/Mic.stories.d.ts} +9 -7
- package/dist/types/src/components/Mic/Mic.stories.d.ts.map +1 -0
- package/dist/types/src/components/Mic/index.d.ts +2 -0
- package/dist/types/src/components/Mic/index.d.ts.map +1 -0
- package/dist/types/src/components/index.d.ts +1 -2
- package/dist/types/src/components/index.d.ts.map +1 -1
- package/dist/types/src/containers/TranscriptionArticle/TranscriptionArticle.d.ts.map +1 -1
- package/dist/types/src/containers/TranscriptionArticle/TranscriptionArticle.stories.d.ts +7 -0
- package/dist/types/src/containers/TranscriptionArticle/TranscriptionArticle.stories.d.ts.map +1 -1
- package/dist/types/src/hooks/index.d.ts +0 -5
- package/dist/types/src/hooks/index.d.ts.map +1 -1
- package/dist/types/src/hooks/useTranscriptionRecording.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 +4 -0
- package/dist/types/src/meta.d.ts.map +1 -1
- package/dist/types/src/normalization/message-normalizer.d.ts +2 -2
- package/dist/types/src/normalization/message-normalizer.d.ts.map +1 -1
- package/dist/types/src/normalization/normalization.d.ts +98 -733
- package/dist/types/src/normalization/normalization.d.ts.map +1 -1
- package/dist/types/src/operations/open.d.ts.map +1 -1
- package/dist/types/src/operations/summarize.d.ts.map +1 -1
- package/dist/types/src/skills/index.d.ts +2 -0
- package/dist/types/src/skills/index.d.ts.map +1 -0
- package/dist/types/src/skills/transcription-skill.d.ts +4 -0
- package/dist/types/src/skills/transcription-skill.d.ts.map +1 -0
- package/dist/types/src/stories/Keyword.stories.d.ts +51 -0
- package/dist/types/src/stories/Keyword.stories.d.ts.map +1 -0
- package/dist/types/src/stories/Pipeline.stories.d.ts +60 -0
- package/dist/types/src/stories/Pipeline.stories.d.ts.map +1 -0
- package/dist/types/src/stories/Transcription.stories.d.ts +23 -0
- package/dist/types/src/stories/Transcription.stories.d.ts.map +1 -0
- package/dist/types/src/testing/decorators.d.ts +21 -0
- package/dist/types/src/testing/decorators.d.ts.map +1 -0
- package/dist/types/src/testing/index.d.ts +1 -0
- package/dist/types/src/testing/index.d.ts.map +1 -1
- package/dist/types/src/testing/testing.d.ts +3 -9
- package/dist/types/src/testing/testing.d.ts.map +1 -1
- package/dist/types/src/{transcriber/transcription-manager.d.ts → transcription-manager.d.ts} +6 -5
- package/dist/types/src/transcription-manager.d.ts.map +1 -0
- package/dist/types/src/translations.d.ts +7 -0
- package/dist/types/src/translations.d.ts.map +1 -1
- package/dist/types/src/types/Settings.d.ts +6 -0
- package/dist/types/src/types/Settings.d.ts.map +1 -1
- package/dist/types/src/types/TranscriptOperation.d.ts +114 -1971
- package/dist/types/src/types/TranscriptOperation.d.ts.map +1 -1
- package/dist/types/src/types/TranscriptionCapabilities.d.ts +51 -13
- package/dist/types/src/types/TranscriptionCapabilities.d.ts.map +1 -1
- package/dist/types/src/util/index.d.ts +0 -2
- package/dist/types/src/util/index.d.ts.map +1 -1
- package/dist/types/tsconfig.tsbuildinfo +1 -1
- package/dx.config.ts +1 -1
- package/package.json +68 -69
- package/src/TranscriptionPlugin.node.ts +2 -2
- package/src/TranscriptionPlugin.test.ts +1 -1
- package/src/TranscriptionPlugin.tsx +31 -2
- package/src/capabilities/app-graph-builder.tsx +49 -0
- package/src/capabilities/entity-lookup.ts +32 -0
- package/src/capabilities/index.ts +7 -1
- package/src/capabilities/markdown-extension.ts +17 -0
- package/src/capabilities/pipeline-status.ts +23 -0
- package/src/capabilities/recording-session.ts +17 -0
- package/src/capabilities/settings.ts +1 -0
- package/src/capabilities/skill-definition.ts +15 -0
- package/src/capabilities/text-content.ts +1 -2
- package/src/capabilities/transcriber.ts +5 -48
- package/src/capabilities/transcription-driver.tsx +263 -0
- package/src/components/Mic/Mic.stories.tsx +66 -0
- package/src/components/Mic/Mic.tsx +136 -0
- package/src/components/Mic/index.ts +5 -0
- package/src/components/index.ts +1 -2
- package/src/containers/TranscriptionArticle/TranscriptionArticle.stories.tsx +4 -0
- package/src/containers/TranscriptionArticle/TranscriptionArticle.tsx +4 -5
- package/src/hooks/index.ts +0 -5
- package/src/hooks/useTranscriptionRecording.ts +4 -8
- package/src/index.ts +1 -5
- package/src/normalization/message-normalizer.ts +3 -3
- package/src/normalization/normalization.ts +3 -0
- package/src/operations/open.ts +2 -2
- package/src/operations/summarize.ts +2 -2
- package/src/skills/index.ts +5 -0
- package/src/skills/transcription-skill.ts +29 -0
- package/src/stories/Keyword.stories.tsx +98 -0
- package/src/stories/Pipeline.stories.tsx +361 -0
- package/src/stories/Transcription.stories.tsx +178 -0
- package/src/testing/decorators.ts +78 -0
- package/src/testing/index.ts +1 -0
- package/src/testing/testing.ts +13 -48
- package/src/{transcriber/transcription-manager.ts → transcription-manager.ts} +13 -12
- package/src/translations.ts +8 -0
- package/src/types/Settings.ts +38 -0
- package/src/types/TranscriptOperation.ts +6 -4
- package/src/types/TranscriptionCapabilities.ts +57 -21
- package/src/util/index.ts +0 -2
- package/dist/lib/neutral/TranscriptionArticle-S56VVOSF.mjs.map +0 -7
- package/dist/lib/neutral/blueprint-definition-DA4QFRYJ.mjs +0 -15
- package/dist/lib/neutral/blueprint-definition-DA4QFRYJ.mjs.map +0 -7
- package/dist/lib/neutral/blueprints/index.mjs +0 -8
- package/dist/lib/neutral/chunk-2URVUJT4.mjs.map +0 -7
- package/dist/lib/neutral/chunk-J4ONEYPJ.mjs +0 -8
- package/dist/lib/neutral/chunk-MLRJWAQH.mjs +0 -179
- package/dist/lib/neutral/chunk-MLRJWAQH.mjs.map +0 -7
- package/dist/lib/neutral/chunk-XMHH34NI.mjs +0 -318
- package/dist/lib/neutral/chunk-XMHH34NI.mjs.map +0 -7
- package/dist/lib/neutral/chunk-XOXHWMXR.mjs +0 -35
- package/dist/lib/neutral/chunk-XOXHWMXR.mjs.map +0 -7
- package/dist/lib/neutral/chunk-XWC5BBOY.mjs +0 -435
- package/dist/lib/neutral/chunk-XWC5BBOY.mjs.map +0 -7
- package/dist/lib/neutral/chunk-ZR4BH4QQ.mjs +0 -30
- package/dist/lib/neutral/chunk-ZR4BH4QQ.mjs.map +0 -7
- package/dist/lib/neutral/open-42H72C4G.mjs.map +0 -7
- package/dist/lib/neutral/summarize-45WVUPED.mjs.map +0 -7
- package/dist/lib/neutral/text-content-XZ3HK4OT.mjs.map +0 -7
- package/dist/lib/neutral/transcriber-KYV6NWI5.mjs +0 -59
- package/dist/lib/neutral/transcriber-KYV6NWI5.mjs.map +0 -7
- package/dist/types/src/blueprints/index.d.ts +0 -2
- package/dist/types/src/blueprints/index.d.ts.map +0 -1
- package/dist/types/src/blueprints/transcription-blueprint.d.ts +0 -4
- package/dist/types/src/blueprints/transcription-blueprint.d.ts.map +0 -1
- package/dist/types/src/capabilities/blueprint-definition.d.ts +0 -6
- package/dist/types/src/capabilities/blueprint-definition.d.ts.map +0 -1
- package/dist/types/src/components/Oracle/Oracle.d.ts +0 -24
- package/dist/types/src/components/Oracle/Oracle.d.ts.map +0 -1
- package/dist/types/src/components/Oracle/Oracle.stories.d.ts.map +0 -1
- package/dist/types/src/components/Oracle/index.d.ts +0 -2
- package/dist/types/src/components/Oracle/index.d.ts.map +0 -1
- package/dist/types/src/components/Transcription/Transcription.d.ts +0 -11
- package/dist/types/src/components/Transcription/Transcription.d.ts.map +0 -1
- package/dist/types/src/components/Transcription/Transcription.stories.d.ts +0 -37
- package/dist/types/src/components/Transcription/Transcription.stories.d.ts.map +0 -1
- package/dist/types/src/components/Transcription/index.d.ts +0 -2
- package/dist/types/src/components/Transcription/index.d.ts.map +0 -1
- package/dist/types/src/components/Transcription/transcription-extension.d.ts +0 -15
- package/dist/types/src/components/Transcription/transcription-extension.d.ts.map +0 -1
- package/dist/types/src/enrichment/conversation.test.d.ts +0 -2
- package/dist/types/src/enrichment/conversation.test.d.ts.map +0 -1
- package/dist/types/src/enrichment/operations.d.ts +0 -200
- package/dist/types/src/enrichment/operations.d.ts.map +0 -1
- package/dist/types/src/enrichment/parser.d.ts +0 -26
- package/dist/types/src/enrichment/parser.d.ts.map +0 -1
- package/dist/types/src/enrichment/stream-simulator.d.ts +0 -38
- package/dist/types/src/enrichment/stream-simulator.d.ts.map +0 -1
- package/dist/types/src/hooks/useAudioFile.d.ts +0 -7
- package/dist/types/src/hooks/useAudioFile.d.ts.map +0 -1
- package/dist/types/src/hooks/useAudioTrack.d.ts +0 -5
- package/dist/types/src/hooks/useAudioTrack.d.ts.map +0 -1
- package/dist/types/src/hooks/useFeedModelAdapter.d.ts +0 -12
- package/dist/types/src/hooks/useFeedModelAdapter.d.ts.map +0 -1
- package/dist/types/src/hooks/useTranscriber.d.ts +0 -7
- package/dist/types/src/hooks/useTranscriber.d.ts.map +0 -1
- package/dist/types/src/hooks/useVoiceInput.d.ts +0 -11
- package/dist/types/src/hooks/useVoiceInput.d.ts.map +0 -1
- package/dist/types/src/model/index.d.ts +0 -2
- package/dist/types/src/model/index.d.ts.map +0 -1
- package/dist/types/src/model/model.d.ts +0 -68
- package/dist/types/src/model/model.d.ts.map +0 -1
- package/dist/types/src/model/model.test.d.ts +0 -2
- package/dist/types/src/model/model.test.d.ts.map +0 -1
- package/dist/types/src/stories/FileTranscription.stories.d.ts +0 -20
- package/dist/types/src/stories/FileTranscription.stories.d.ts.map +0 -1
- package/dist/types/src/stories/KeyWordRecognition.stories.d.ts +0 -14
- package/dist/types/src/stories/KeyWordRecognition.stories.d.ts.map +0 -1
- package/dist/types/src/stories/LiveTranscription.stories.d.ts +0 -19
- package/dist/types/src/stories/LiveTranscription.stories.d.ts.map +0 -1
- package/dist/types/src/stories/ProperNounExtraction.stories.d.ts +0 -13
- package/dist/types/src/stories/ProperNounExtraction.stories.d.ts.map +0 -1
- package/dist/types/src/stories/TranscriptionStory.d.ts +0 -21
- package/dist/types/src/stories/TranscriptionStory.d.ts.map +0 -1
- package/dist/types/src/stories/common.d.ts +0 -248
- package/dist/types/src/stories/common.d.ts.map +0 -1
- package/dist/types/src/transcriber/audio-recorder.d.ts +0 -47
- package/dist/types/src/transcriber/audio-recorder.d.ts.map +0 -1
- package/dist/types/src/transcriber/index.d.ts +0 -5
- package/dist/types/src/transcriber/index.d.ts.map +0 -1
- package/dist/types/src/transcriber/media-stream-recorder.d.ts +0 -30
- package/dist/types/src/transcriber/media-stream-recorder.d.ts.map +0 -1
- package/dist/types/src/transcriber/transcriber.browser.test.d.ts +0 -2
- package/dist/types/src/transcriber/transcriber.browser.test.d.ts.map +0 -1
- package/dist/types/src/transcriber/transcriber.d.ts +0 -105
- package/dist/types/src/transcriber/transcriber.d.ts.map +0 -1
- package/dist/types/src/transcriber/transcriber.test.d.ts +0 -2
- package/dist/types/src/transcriber/transcriber.test.d.ts.map +0 -1
- package/dist/types/src/transcriber/transcription-manager.d.ts.map +0 -1
- package/dist/types/src/util/array.d.ts +0 -2
- package/dist/types/src/util/array.d.ts.map +0 -1
- package/dist/types/src/util/render-byline.d.ts +0 -4
- package/dist/types/src/util/render-byline.d.ts.map +0 -1
- package/src/blueprints/index.ts +0 -5
- package/src/blueprints/transcription-blueprint.ts +0 -29
- package/src/capabilities/blueprint-definition.ts +0 -19
- package/src/components/Oracle/Oracle.stories.tsx +0 -147
- package/src/components/Oracle/Oracle.tsx +0 -142
- package/src/components/Oracle/index.ts +0 -5
- package/src/components/Transcription/Transcription.stories.tsx +0 -213
- package/src/components/Transcription/Transcription.tsx +0 -55
- package/src/components/Transcription/index.ts +0 -5
- package/src/components/Transcription/transcription-extension.ts +0 -203
- package/src/enrichment/conversation.test.ts +0 -162
- package/src/enrichment/conversation.txt +0 -23
- package/src/enrichment/operations.ts +0 -271
- package/src/enrichment/parser.ts +0 -101
- package/src/enrichment/stream-simulator.ts +0 -125
- package/src/hooks/useAudioFile.ts +0 -88
- package/src/hooks/useAudioTrack.ts +0 -35
- package/src/hooks/useFeedModelAdapter.ts +0 -46
- package/src/hooks/useTranscriber.ts +0 -47
- package/src/hooks/useVoiceInput.ts +0 -66
- package/src/model/index.ts +0 -5
- package/src/model/model.test.ts +0 -175
- package/src/model/model.ts +0 -229
- package/src/stories/FileTranscription.stories.tsx +0 -143
- package/src/stories/KeyWordRecognition.stories.tsx +0 -132
- package/src/stories/LiveTranscription.stories.tsx +0 -99
- package/src/stories/ProperNounExtraction.stories.tsx +0 -99
- package/src/stories/TranscriptionStory.tsx +0 -101
- package/src/stories/common.ts +0 -234
- package/src/transcriber/audio-recorder.ts +0 -56
- package/src/transcriber/index.ts +0 -8
- package/src/transcriber/media-stream-recorder.ts +0 -120
- package/src/transcriber/transcriber.browser.test.ts +0 -230
- package/src/transcriber/transcriber.test.ts +0 -104
- package/src/transcriber/transcriber.ts +0 -303
- package/src/util/array.ts +0 -14
- package/src/util/render-byline.ts +0 -33
- /package/dist/lib/neutral/{chunk-J4ONEYPJ.mjs.map → chunk-HNXSU7HJ.mjs.map} +0 -0
- /package/dist/lib/neutral/{create-7NGOP7JP.mjs.map → create-HNHGCKZ4.mjs.map} +0 -0
- /package/dist/lib/neutral/{enrich-message-F2AOM53F.mjs.map → enrich-message-DSJU4TXC.mjs.map} +0 -0
- /package/dist/lib/neutral/{blueprints → skills}/index.mjs.map +0 -0
package/dx.config.ts
CHANGED
|
@@ -24,7 +24,7 @@ export default Config2.make({
|
|
|
24
24
|
An optional message enricher pipeline lets plugins annotate messages before they are
|
|
25
25
|
committed — for example, to attach speaker identity from a calls service.
|
|
26
26
|
|
|
27
|
-
The plugin ships two
|
|
27
|
+
The plugin ships two skill-compatible operations: Open (loads and formats a transcript
|
|
28
28
|
for reading by an AI assistant) and Summarize (sends the transcript text to an LLM and
|
|
29
29
|
returns a structured Markdown summary with key points, verbatim quotes, and actionable
|
|
30
30
|
tasks extracted from the conversation).
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@dxos/plugin-transcription",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.10.0",
|
|
4
4
|
"description": "Voice transcription.",
|
|
5
5
|
"homepage": "https://dxos.org",
|
|
6
6
|
"bugs": "https://github.com/dxos/dxos/issues",
|
|
@@ -12,10 +12,10 @@
|
|
|
12
12
|
"author": "DXOS.org",
|
|
13
13
|
"type": "module",
|
|
14
14
|
"imports": {
|
|
15
|
-
"#
|
|
16
|
-
"source": "./src/
|
|
17
|
-
"types": "./dist/types/src/
|
|
18
|
-
"default": "./dist/lib/neutral/
|
|
15
|
+
"#skills": {
|
|
16
|
+
"source": "./src/skills/index.ts",
|
|
17
|
+
"types": "./dist/types/src/skills/index.d.ts",
|
|
18
|
+
"default": "./dist/lib/neutral/skills/index.mjs"
|
|
19
19
|
},
|
|
20
20
|
"#capabilities": {
|
|
21
21
|
"source": "./src/capabilities/index.ts",
|
|
@@ -77,21 +77,16 @@
|
|
|
77
77
|
"default": "./dist/lib/neutral/index.mjs"
|
|
78
78
|
},
|
|
79
79
|
"./assets/PLUGIN.mdl": "./PLUGIN.mdl",
|
|
80
|
-
"./
|
|
81
|
-
"source": "./src/
|
|
82
|
-
"types": "./dist/types/src/
|
|
83
|
-
"default": "./dist/lib/neutral/
|
|
80
|
+
"./skills": {
|
|
81
|
+
"source": "./src/skills/index.ts",
|
|
82
|
+
"types": "./dist/types/src/skills/index.d.ts",
|
|
83
|
+
"default": "./dist/lib/neutral/skills/index.mjs"
|
|
84
84
|
},
|
|
85
85
|
"./components": {
|
|
86
86
|
"source": "./src/components/index.ts",
|
|
87
87
|
"types": "./dist/types/src/components/index.d.ts",
|
|
88
88
|
"default": "./dist/lib/neutral/components/index.mjs"
|
|
89
89
|
},
|
|
90
|
-
"./hooks": {
|
|
91
|
-
"source": "./src/hooks/index.ts",
|
|
92
|
-
"types": "./dist/types/src/hooks/index.d.ts",
|
|
93
|
-
"default": "./dist/lib/neutral/hooks/index.mjs"
|
|
94
|
-
},
|
|
95
90
|
"./plugin": {
|
|
96
91
|
"source": "./src/plugin.ts",
|
|
97
92
|
"types": "./dist/types/src/plugin.d.ts",
|
|
@@ -117,71 +112,75 @@
|
|
|
117
112
|
],
|
|
118
113
|
"dependencies": {
|
|
119
114
|
"@codemirror/state": "^6.6.0",
|
|
120
|
-
"@
|
|
115
|
+
"@effect-atom/atom-react": "^0.5.0",
|
|
121
116
|
"@radix-ui/react-primitive": "2.0.2",
|
|
122
117
|
"@radix-ui/react-slot": "1.1.2",
|
|
123
|
-
"
|
|
124
|
-
"
|
|
125
|
-
"
|
|
126
|
-
"
|
|
127
|
-
"@dxos/
|
|
128
|
-
"@dxos/
|
|
129
|
-
"@dxos/
|
|
130
|
-
"@dxos/
|
|
131
|
-
"@dxos/
|
|
132
|
-
"@dxos/
|
|
133
|
-
"@dxos/
|
|
134
|
-
"@dxos/
|
|
135
|
-
"@dxos/
|
|
136
|
-
"@dxos/
|
|
137
|
-
"@dxos/
|
|
138
|
-
"@dxos/
|
|
139
|
-
"@dxos/
|
|
140
|
-
"@dxos/
|
|
141
|
-
"@dxos/react-client": "0.
|
|
142
|
-
"@dxos/
|
|
143
|
-
"@dxos/react-
|
|
144
|
-
"@dxos/react-ui-
|
|
145
|
-
"@dxos/react-ui-
|
|
146
|
-
"@dxos/react-ui-graph": "0.
|
|
147
|
-
"@dxos/
|
|
148
|
-
"@dxos/
|
|
149
|
-
"@dxos/
|
|
150
|
-
"@dxos/
|
|
151
|
-
"@dxos/
|
|
152
|
-
"@dxos/
|
|
153
|
-
"@dxos/
|
|
154
|
-
"@dxos/
|
|
155
|
-
"@dxos/
|
|
118
|
+
"effect": "3.21.4",
|
|
119
|
+
"@dxos/ai": "0.10.0",
|
|
120
|
+
"@dxos/app-toolkit": "0.10.0",
|
|
121
|
+
"@dxos/app-framework": "0.10.0",
|
|
122
|
+
"@dxos/assistant": "0.10.0",
|
|
123
|
+
"@dxos/async": "0.10.0",
|
|
124
|
+
"@dxos/client": "0.10.0",
|
|
125
|
+
"@dxos/compute": "0.10.0",
|
|
126
|
+
"@dxos/config": "0.10.0",
|
|
127
|
+
"@dxos/context": "0.10.0",
|
|
128
|
+
"@dxos/echo-doc": "0.10.0",
|
|
129
|
+
"@dxos/echo": "0.10.0",
|
|
130
|
+
"@dxos/functions-runtime": "0.10.0",
|
|
131
|
+
"@dxos/invariant": "0.10.0",
|
|
132
|
+
"@dxos/log": "0.10.0",
|
|
133
|
+
"@dxos/keys": "0.10.0",
|
|
134
|
+
"@dxos/plugin-markdown": "0.10.0",
|
|
135
|
+
"@dxos/plugin-graph": "0.10.0",
|
|
136
|
+
"@dxos/react-client": "0.10.0",
|
|
137
|
+
"@dxos/react-edge-client": "0.10.0",
|
|
138
|
+
"@dxos/react-ui-audio": "0.10.0",
|
|
139
|
+
"@dxos/react-ui-components": "0.10.0",
|
|
140
|
+
"@dxos/react-ui-editor": "0.10.0",
|
|
141
|
+
"@dxos/react-ui-graph": "0.10.0",
|
|
142
|
+
"@dxos/react-ui-menu": "0.10.0",
|
|
143
|
+
"@dxos/plugin-client": "0.10.0",
|
|
144
|
+
"@dxos/effect": "0.10.0",
|
|
145
|
+
"@dxos/react-ui-transcription": "0.10.0",
|
|
146
|
+
"@dxos/schema": "0.10.0",
|
|
147
|
+
"@dxos/tracing": "0.10.0",
|
|
148
|
+
"@dxos/transcription-pipeline": "0.10.0",
|
|
149
|
+
"@dxos/types": "0.10.0",
|
|
150
|
+
"@dxos/ui-editor": "0.10.0",
|
|
151
|
+
"@dxos/util": "0.10.0"
|
|
156
152
|
},
|
|
157
153
|
"devDependencies": {
|
|
158
154
|
"@effect-atom/atom-react": "^0.5.0",
|
|
159
|
-
"@effect/platform": "0.96.
|
|
155
|
+
"@effect/platform": "0.96.2",
|
|
160
156
|
"@types/dom-speech-recognition": "^0.0.6",
|
|
161
|
-
"@types/react": "~19.2.
|
|
162
|
-
"effect": "3.21.
|
|
163
|
-
"react": "~19.2.
|
|
164
|
-
"react-dom": "~19.2.
|
|
157
|
+
"@types/react": "~19.2.17",
|
|
158
|
+
"effect": "3.21.4",
|
|
159
|
+
"react": "~19.2.7",
|
|
160
|
+
"react-dom": "~19.2.7",
|
|
165
161
|
"tailwindcss": "^4.3.0",
|
|
166
|
-
"@dxos/plugin-preview": "0.
|
|
167
|
-
"@dxos/plugin-
|
|
168
|
-
"@dxos/
|
|
169
|
-
"@dxos/plugin-theme": "0.
|
|
170
|
-
"@dxos/
|
|
171
|
-
"@dxos/react-ui
|
|
172
|
-
"@dxos/
|
|
173
|
-
"@dxos/react-ui-
|
|
174
|
-
"@dxos/
|
|
175
|
-
"@dxos/
|
|
162
|
+
"@dxos/plugin-preview": "0.10.0",
|
|
163
|
+
"@dxos/plugin-space": "0.10.0",
|
|
164
|
+
"@dxos/plugin-testing": "0.10.0",
|
|
165
|
+
"@dxos/plugin-theme": "0.10.0",
|
|
166
|
+
"@dxos/random": "0.10.0",
|
|
167
|
+
"@dxos/react-ui": "0.10.0",
|
|
168
|
+
"@dxos/react-ui-attention": "0.10.0",
|
|
169
|
+
"@dxos/react-ui-form": "0.10.0",
|
|
170
|
+
"@dxos/react-ui-list": "0.10.0",
|
|
171
|
+
"@dxos/storybook-utils": "0.10.0",
|
|
172
|
+
"@dxos/ui-theme": "0.10.0",
|
|
173
|
+
"@dxos/react-ui-syntax-highlighter": "0.10.0",
|
|
174
|
+
"@dxos/test-utils": "0.10.0"
|
|
176
175
|
},
|
|
177
176
|
"peerDependencies": {
|
|
178
177
|
"@effect-atom/atom-react": "^0.5.0",
|
|
179
|
-
"@effect/platform": "0.96.
|
|
180
|
-
"effect": "3.21.
|
|
181
|
-
"react": "~19.2.
|
|
182
|
-
"react-dom": "~19.2.
|
|
183
|
-
"@dxos/
|
|
184
|
-
"@dxos/ui
|
|
178
|
+
"@effect/platform": "0.96.2",
|
|
179
|
+
"effect": "3.21.4",
|
|
180
|
+
"react": "~19.2.7",
|
|
181
|
+
"react-dom": "~19.2.7",
|
|
182
|
+
"@dxos/ui-theme": "0.10.0",
|
|
183
|
+
"@dxos/react-ui": "0.10.0"
|
|
185
184
|
},
|
|
186
185
|
"publishConfig": {
|
|
187
186
|
"access": "public"
|
|
@@ -6,11 +6,11 @@ import { Plugin } from '@dxos/app-framework';
|
|
|
6
6
|
import { AppPlugin } from '@dxos/app-toolkit';
|
|
7
7
|
import { Transcript } from '@dxos/types';
|
|
8
8
|
|
|
9
|
-
import {
|
|
9
|
+
import { OperationHandler, SkillDefinition, TextContent } from '#capabilities';
|
|
10
10
|
import { meta } from '#meta';
|
|
11
11
|
|
|
12
12
|
export const TranscriptionPlugin = Plugin.define(meta).pipe(
|
|
13
|
-
AppPlugin.
|
|
13
|
+
AppPlugin.addSkillDefinitionModule({ activate: SkillDefinition }),
|
|
14
14
|
AppPlugin.addTextContentModule({ activate: TextContent }),
|
|
15
15
|
AppPlugin.addOperationHandlerModule({ activate: OperationHandler }),
|
|
16
16
|
AppPlugin.addSchemaModule({ schema: [Transcript.Transcript] }),
|
|
@@ -26,6 +26,6 @@ describe('TranscriptionPlugin', () => {
|
|
|
26
26
|
|
|
27
27
|
// SetupArtifactDefinition is fired by AssistantPlugin, which can't be included here due to a workspace cycle.
|
|
28
28
|
await harness.fire(AppActivationEvents.SetupArtifactDefinition);
|
|
29
|
-
expect(harness.manager.getActive()).toContain(moduleId('
|
|
29
|
+
expect(harness.manager.getActive()).toContain(moduleId('SkillDefinition'));
|
|
30
30
|
});
|
|
31
31
|
});
|
|
@@ -4,14 +4,21 @@
|
|
|
4
4
|
|
|
5
5
|
import { Plugin } from '@dxos/app-framework';
|
|
6
6
|
import { AppActivationEvents, AppPlugin } from '@dxos/app-toolkit';
|
|
7
|
+
import { MarkdownEvents } from '@dxos/plugin-markdown';
|
|
7
8
|
import { Transcript } from '@dxos/types';
|
|
8
9
|
|
|
9
10
|
import {
|
|
10
|
-
|
|
11
|
+
AppGraphBuilder,
|
|
12
|
+
EntityLookup,
|
|
13
|
+
MarkdownExtension,
|
|
11
14
|
OperationHandler,
|
|
15
|
+
PipelineStatus,
|
|
12
16
|
ReactSurface,
|
|
17
|
+
RecordingSession,
|
|
18
|
+
SkillDefinition,
|
|
13
19
|
TextContent,
|
|
14
20
|
Transcriber,
|
|
21
|
+
TranscriptionDriver,
|
|
15
22
|
TranscriptionSettings,
|
|
16
23
|
} from '#capabilities';
|
|
17
24
|
import { meta } from '#meta';
|
|
@@ -21,18 +28,40 @@ import { translations } from '#translations';
|
|
|
21
28
|
import pluginSpec from '../PLUGIN.mdl?raw';
|
|
22
29
|
|
|
23
30
|
export const TranscriptionPlugin = Plugin.define(meta).pipe(
|
|
24
|
-
AppPlugin.
|
|
31
|
+
AppPlugin.addSkillDefinitionModule({ activate: SkillDefinition }),
|
|
25
32
|
AppPlugin.addTextContentModule({ activate: TextContent }),
|
|
26
33
|
AppPlugin.addOperationHandlerModule({ activate: OperationHandler }),
|
|
27
34
|
AppPlugin.addSchemaModule({ schema: [Transcript.Transcript] }),
|
|
28
35
|
AppPlugin.addSurfaceModule({ activate: ReactSurface }),
|
|
29
36
|
AppPlugin.addTranslationsModule({ translations }),
|
|
30
37
|
AppPlugin.addSettingsModule({ activate: TranscriptionSettings }),
|
|
38
|
+
AppPlugin.addAppGraphModule({ activate: AppGraphBuilder }),
|
|
39
|
+
AppPlugin.addReactContextModule({ activate: TranscriptionDriver }),
|
|
31
40
|
Plugin.addModule({
|
|
32
41
|
id: 'transcription',
|
|
33
42
|
activatesOn: AppActivationEvents.SetupAppGraph,
|
|
34
43
|
activate: Transcriber,
|
|
35
44
|
}),
|
|
45
|
+
Plugin.addModule({
|
|
46
|
+
id: 'entity-lookup',
|
|
47
|
+
activatesOn: AppActivationEvents.SetupAppGraph,
|
|
48
|
+
activate: EntityLookup,
|
|
49
|
+
}),
|
|
50
|
+
Plugin.addModule({
|
|
51
|
+
id: 'recording-session',
|
|
52
|
+
activatesOn: AppActivationEvents.SetupSettings,
|
|
53
|
+
activate: RecordingSession,
|
|
54
|
+
}),
|
|
55
|
+
Plugin.addModule({
|
|
56
|
+
id: 'pipeline-status',
|
|
57
|
+
activatesOn: AppActivationEvents.SetupSettings,
|
|
58
|
+
activate: PipelineStatus,
|
|
59
|
+
}),
|
|
60
|
+
Plugin.addModule({
|
|
61
|
+
id: 'markdown',
|
|
62
|
+
activatesOn: MarkdownEvents.SetupExtensions,
|
|
63
|
+
activate: MarkdownExtension,
|
|
64
|
+
}),
|
|
36
65
|
AppPlugin.addPluginAssetModule({
|
|
37
66
|
asset: { pluginId: meta.profile.key, path: 'PLUGIN.mdl', content: pluginSpec, mimeType: 'application/x-mdl' },
|
|
38
67
|
}),
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
//
|
|
2
|
+
// Copyright 2026 DXOS.org
|
|
3
|
+
//
|
|
4
|
+
|
|
5
|
+
import * as Effect from 'effect/Effect';
|
|
6
|
+
import React from 'react';
|
|
7
|
+
|
|
8
|
+
import { Capability } from '@dxos/app-framework';
|
|
9
|
+
import { AppCapabilities } from '@dxos/app-toolkit';
|
|
10
|
+
import { GraphBuilder, Node, NodeMatcher } from '@dxos/plugin-graph';
|
|
11
|
+
import { Markdown } from '@dxos/plugin-markdown/types';
|
|
12
|
+
|
|
13
|
+
import { Mic } from '#components';
|
|
14
|
+
import { meta } from '#meta';
|
|
15
|
+
|
|
16
|
+
const whenMarkdownDocument = NodeMatcher.whenAll(
|
|
17
|
+
NodeMatcher.whenEchoObjectMatches,
|
|
18
|
+
NodeMatcher.whenEchoTypeMatches(Markdown.Document),
|
|
19
|
+
);
|
|
20
|
+
|
|
21
|
+
export default Capability.makeModule(
|
|
22
|
+
Effect.fnUntraced(function* () {
|
|
23
|
+
const extensions = yield* GraphBuilder.createExtension({
|
|
24
|
+
id: 'transcriptionToolbar',
|
|
25
|
+
match: (node, get) => whenMarkdownDocument(node, get),
|
|
26
|
+
// The control owns recording state, mode, device selection, and entity-extraction —
|
|
27
|
+
// interactions the action model cannot express (press-and-hold, an embedded dropdown, a
|
|
28
|
+
// live device list) — so it renders via the custom toolbar variant rather than a plain
|
|
29
|
+
// toggle action. The node is static (state lives in the control), keeping the toolbar's
|
|
30
|
+
// action atom stable across recording changes.
|
|
31
|
+
actions: (matched) =>
|
|
32
|
+
Effect.succeed([
|
|
33
|
+
Node.makeAction({
|
|
34
|
+
id: 'transcription',
|
|
35
|
+
data: () => Effect.void,
|
|
36
|
+
properties: {
|
|
37
|
+
label: ['start-recording.label', { ns: meta.profile.key }],
|
|
38
|
+
icon: 'ph--microphone--regular',
|
|
39
|
+
disposition: 'toolbar',
|
|
40
|
+
variant: 'custom',
|
|
41
|
+
render: () => <Mic docId={matched.id} />,
|
|
42
|
+
},
|
|
43
|
+
}),
|
|
44
|
+
]),
|
|
45
|
+
});
|
|
46
|
+
|
|
47
|
+
return Capability.contributes(AppCapabilities.AppGraphBuilder, extensions);
|
|
48
|
+
}),
|
|
49
|
+
);
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
//
|
|
2
|
+
// Copyright 2026 DXOS.org
|
|
3
|
+
//
|
|
4
|
+
|
|
5
|
+
import * as Effect from 'effect/Effect';
|
|
6
|
+
|
|
7
|
+
import { Capability } from '@dxos/app-framework';
|
|
8
|
+
import { AppSpace } from '@dxos/app-toolkit';
|
|
9
|
+
import { ClientCapabilities } from '@dxos/plugin-client';
|
|
10
|
+
import { type EntityLookup, makeDatabaseLookup } from '@dxos/transcription-pipeline';
|
|
11
|
+
|
|
12
|
+
import { TranscriptionCapabilities } from '#types';
|
|
13
|
+
|
|
14
|
+
/**
|
|
15
|
+
* Contributes an {@link EntityLookup} backed by the personal space's full-text index. Resolved lazily
|
|
16
|
+
* per call so it reflects the current space. Consumers (e.g. the live-transcription driver) depend on
|
|
17
|
+
* this function rather than the database — swap the backend (vector, space-aware, remote) here.
|
|
18
|
+
*/
|
|
19
|
+
export default Capability.makeModule(
|
|
20
|
+
Effect.fnUntraced(function* () {
|
|
21
|
+
const capabilities = yield* Capability.Service;
|
|
22
|
+
const lookup: EntityLookup = async (noun, context) => {
|
|
23
|
+
const client = capabilities.get(ClientCapabilities.Client);
|
|
24
|
+
const space = AppSpace.getPersonalSpace(client);
|
|
25
|
+
if (!space) {
|
|
26
|
+
return [];
|
|
27
|
+
}
|
|
28
|
+
return makeDatabaseLookup(space.db)(noun, context);
|
|
29
|
+
};
|
|
30
|
+
return Capability.contributes(TranscriptionCapabilities.EntityLookup, lookup);
|
|
31
|
+
}),
|
|
32
|
+
);
|
|
@@ -5,7 +5,13 @@
|
|
|
5
5
|
import { Capability } from '@dxos/app-framework';
|
|
6
6
|
import type { OperationHandlerSet } from '@dxos/compute';
|
|
7
7
|
|
|
8
|
-
export const
|
|
8
|
+
export const AppGraphBuilder = Capability.lazy('AppGraphBuilder', () => import('./app-graph-builder'));
|
|
9
|
+
export const EntityLookup = Capability.lazy('EntityLookup', () => import('./entity-lookup'));
|
|
10
|
+
export const MarkdownExtension = Capability.lazy('MarkdownExtension', () => import('./markdown-extension'));
|
|
11
|
+
export const PipelineStatus = Capability.lazy('PipelineStatus', () => import('./pipeline-status'));
|
|
12
|
+
export const RecordingSession = Capability.lazy('RecordingSession', () => import('./recording-session'));
|
|
13
|
+
export const TranscriptionDriver = Capability.lazy('TranscriptionDriver', () => import('./transcription-driver'));
|
|
14
|
+
export const SkillDefinition = Capability.lazy('SkillDefinition', () => import('./skill-definition'));
|
|
9
15
|
export const TextContent = Capability.lazy('TextContent', () => import('./text-content'));
|
|
10
16
|
export const OperationHandler = Capability.lazy<OperationHandlerSet.OperationHandlerSet>(
|
|
11
17
|
'OperationHandler',
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
//
|
|
2
|
+
// Copyright 2026 DXOS.org
|
|
3
|
+
//
|
|
4
|
+
|
|
5
|
+
import * as Effect from 'effect/Effect';
|
|
6
|
+
|
|
7
|
+
import { Capability } from '@dxos/app-framework';
|
|
8
|
+
import { MarkdownCapabilities } from '@dxos/plugin-markdown/types';
|
|
9
|
+
import { pendingText } from '@dxos/ui-editor';
|
|
10
|
+
|
|
11
|
+
export default Capability.makeModule(
|
|
12
|
+
Effect.fnUntraced(function* () {
|
|
13
|
+
// Every Markdown editor receives the pending-text extension so the transcription driver can
|
|
14
|
+
// inject live text into it (the driver resolves the editor via `MarkdownCapabilities.EditorViews`).
|
|
15
|
+
return Capability.contributes(MarkdownCapabilities.ExtensionProvider, [() => pendingText()]);
|
|
16
|
+
}),
|
|
17
|
+
);
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
//
|
|
2
|
+
// Copyright 2026 DXOS.org
|
|
3
|
+
//
|
|
4
|
+
|
|
5
|
+
import { Atom } from '@effect-atom/atom-react';
|
|
6
|
+
import * as Effect from 'effect/Effect';
|
|
7
|
+
|
|
8
|
+
import { Capability } from '@dxos/app-framework';
|
|
9
|
+
|
|
10
|
+
import { TranscriptionCapabilities } from '#types';
|
|
11
|
+
|
|
12
|
+
/**
|
|
13
|
+
* Observable live-transcription lifecycle phase, written by the driver and read by UI (toolbar
|
|
14
|
+
* spinner, testbench telemetry) so the mic + pipeline state can be reflected in real time.
|
|
15
|
+
*/
|
|
16
|
+
export default Capability.makeModule(
|
|
17
|
+
Effect.fnUntraced(function* () {
|
|
18
|
+
const statusAtom = Atom.make<{ phase: TranscriptionCapabilities.PipelinePhase }>({ phase: 'idle' }).pipe(
|
|
19
|
+
Atom.keepAlive,
|
|
20
|
+
);
|
|
21
|
+
return Capability.contributes(TranscriptionCapabilities.PipelineStatus, statusAtom);
|
|
22
|
+
}),
|
|
23
|
+
);
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
//
|
|
2
|
+
// Copyright 2026 DXOS.org
|
|
3
|
+
//
|
|
4
|
+
|
|
5
|
+
import { Atom } from '@effect-atom/atom-react';
|
|
6
|
+
import * as Effect from 'effect/Effect';
|
|
7
|
+
|
|
8
|
+
import { Capability } from '@dxos/app-framework';
|
|
9
|
+
|
|
10
|
+
import { TranscriptionCapabilities } from '#types';
|
|
11
|
+
|
|
12
|
+
export default Capability.makeModule(
|
|
13
|
+
Effect.fnUntraced(function* () {
|
|
14
|
+
const sessionAtom = Atom.make<TranscriptionCapabilities.RecordingSession | null>(null).pipe(Atom.keepAlive);
|
|
15
|
+
return Capability.contributes(TranscriptionCapabilities.RecordingSession, sessionAtom);
|
|
16
|
+
}),
|
|
17
|
+
);
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
//
|
|
2
|
+
// Copyright 2025 DXOS.org
|
|
3
|
+
//
|
|
4
|
+
|
|
5
|
+
import * as Effect from 'effect/Effect';
|
|
6
|
+
|
|
7
|
+
import { Capability } from '@dxos/app-framework';
|
|
8
|
+
import { AppCapabilities } from '@dxos/app-toolkit';
|
|
9
|
+
|
|
10
|
+
import { TranscriptionSkill } from '#skills';
|
|
11
|
+
|
|
12
|
+
const skillDefinition = () =>
|
|
13
|
+
Effect.succeed([Capability.contributes(AppCapabilities.SkillDefinition, TranscriptionSkill)]);
|
|
14
|
+
|
|
15
|
+
export default skillDefinition;
|
|
@@ -8,10 +8,9 @@ import { Capability } from '@dxos/app-framework';
|
|
|
8
8
|
import { AppCapabilities } from '@dxos/app-toolkit';
|
|
9
9
|
import { Feed, Filter, Obj, Query, Scope, Type } from '@dxos/echo';
|
|
10
10
|
import { getSpace } from '@dxos/react-client/echo';
|
|
11
|
+
import { renderByline } from '@dxos/react-ui-transcription';
|
|
11
12
|
import { Message, Transcript } from '@dxos/types';
|
|
12
13
|
|
|
13
|
-
import { renderByline } from '../util';
|
|
14
|
-
|
|
15
14
|
export default Capability.makeModule(
|
|
16
15
|
Effect.fnUntraced(function* () {
|
|
17
16
|
return Capability.contributes(AppCapabilities.TextContent, {
|
|
@@ -9,28 +9,12 @@ import { ClientCapabilities } from '@dxos/plugin-client';
|
|
|
9
9
|
|
|
10
10
|
import { TranscriptionCapabilities } from '#types';
|
|
11
11
|
|
|
12
|
-
import {
|
|
13
|
-
|
|
14
|
-
// TODO(burdon): Move to config?
|
|
15
|
-
|
|
16
|
-
/**
|
|
17
|
-
* Length of the chunk in ms.
|
|
18
|
-
*/
|
|
19
|
-
const RECORD_INTERVAL = 200;
|
|
20
|
-
|
|
21
|
-
/**
|
|
22
|
-
* Number of chunks to save before the user starts speaking.
|
|
23
|
-
*/
|
|
24
|
-
const PREFIXED_CHUNKS_AMOUNT = 10;
|
|
12
|
+
import { TranscriptionManagerImpl } from '../transcription-manager';
|
|
25
13
|
|
|
26
14
|
/**
|
|
27
|
-
*
|
|
28
|
-
*
|
|
29
|
-
|
|
30
|
-
const TRANSCRIBE_AFTER_CHUNKS_AMOUNT = 50;
|
|
31
|
-
|
|
32
|
-
/**
|
|
33
|
-
* Records audio while user is speaking and transcribes it after user is done speaking.
|
|
15
|
+
* Provides the higher-level transcription manager to the app-framework so other plugins can obtain it
|
|
16
|
+
* via DI. The low-level construction lives in `@dxos/react-ui-transcription`; this module is the
|
|
17
|
+
* provision seam.
|
|
34
18
|
*/
|
|
35
19
|
export default Capability.makeModule(
|
|
36
20
|
Effect.fnUntraced(function* () {
|
|
@@ -38,37 +22,11 @@ export default Capability.makeModule(
|
|
|
38
22
|
const capabilities = yield* Capability.Service;
|
|
39
23
|
const registry = yield* Capability.get(Capabilities.AtomRegistry);
|
|
40
24
|
|
|
41
|
-
const transcriberProvider: TranscriptionCapabilities.TranscriberProvider = ({
|
|
42
|
-
audioStreamTrack,
|
|
43
|
-
onSegments,
|
|
44
|
-
transcriberConfig,
|
|
45
|
-
recorderConfig,
|
|
46
|
-
transcribe,
|
|
47
|
-
}) => {
|
|
48
|
-
// Initialize audio transcription.
|
|
49
|
-
return new Transcriber({
|
|
50
|
-
config: {
|
|
51
|
-
transcribeAfterChunksAmount: TRANSCRIBE_AFTER_CHUNKS_AMOUNT,
|
|
52
|
-
prefixBufferChunksAmount: PREFIXED_CHUNKS_AMOUNT,
|
|
53
|
-
...transcriberConfig,
|
|
54
|
-
},
|
|
55
|
-
recorder: new MediaStreamRecorder({
|
|
56
|
-
mediaStreamTrack: audioStreamTrack,
|
|
57
|
-
config: {
|
|
58
|
-
interval: RECORD_INTERVAL,
|
|
59
|
-
...recorderConfig,
|
|
60
|
-
},
|
|
61
|
-
}),
|
|
62
|
-
onSegments,
|
|
63
|
-
transcribe,
|
|
64
|
-
});
|
|
65
|
-
};
|
|
66
|
-
|
|
67
25
|
const transcriptionManagerProvider: TranscriptionCapabilities.TranscriptionManagerProvider = ({
|
|
68
26
|
messageEnricher,
|
|
69
27
|
}) => {
|
|
70
28
|
const client = capabilities.get(ClientCapabilities.Client);
|
|
71
|
-
const transcriptionManager = new
|
|
29
|
+
const transcriptionManager = new TranscriptionManagerImpl({
|
|
72
30
|
edgeClient: client.edge.http,
|
|
73
31
|
messageEnricher,
|
|
74
32
|
registry,
|
|
@@ -83,7 +41,6 @@ export default Capability.makeModule(
|
|
|
83
41
|
};
|
|
84
42
|
|
|
85
43
|
return [
|
|
86
|
-
Capability.contributes(TranscriptionCapabilities.TranscriberProvider, transcriberProvider),
|
|
87
44
|
Capability.contributes(TranscriptionCapabilities.TranscriptionManagerProvider, transcriptionManagerProvider),
|
|
88
45
|
];
|
|
89
46
|
}),
|