@dxos/plugin-transcription 0.8.4-main.fcfe5033a5 → 0.8.4-staging.60fe92afc8

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (319) hide show
  1. package/LICENSE +102 -5
  2. package/PLUGIN.mdl +401 -0
  3. package/README.md +1 -1
  4. package/dist/lib/neutral/TranscriptionArticle-L6XANBH5.mjs +54 -0
  5. package/dist/lib/neutral/TranscriptionArticle-L6XANBH5.mjs.map +7 -0
  6. package/dist/lib/neutral/TranscriptionPlugin.mjs +46 -0
  7. package/dist/lib/neutral/TranscriptionPlugin.mjs.map +7 -0
  8. package/dist/lib/neutral/TranscriptionPlugin.node.mjs +25 -0
  9. package/dist/lib/neutral/TranscriptionPlugin.node.mjs.map +7 -0
  10. package/dist/lib/neutral/TranscriptionPlugin.workerd.mjs +21 -0
  11. package/dist/lib/neutral/TranscriptionPlugin.workerd.mjs.map +7 -0
  12. package/dist/lib/neutral/blueprint-definition-DA4QFRYJ.mjs +15 -0
  13. package/dist/lib/neutral/blueprint-definition-DA4QFRYJ.mjs.map +7 -0
  14. package/dist/lib/neutral/blueprints/index.mjs +8 -0
  15. package/dist/lib/neutral/capabilities/index.mjs +17 -0
  16. package/dist/lib/neutral/capabilities/index.mjs.map +7 -0
  17. package/dist/lib/neutral/chunk-FHNI26QW.mjs +45 -0
  18. package/dist/lib/neutral/chunk-FHNI26QW.mjs.map +7 -0
  19. package/dist/lib/{browser/chunk-HOOPZ7EM.mjs → neutral/chunk-KAEXRX3Y.mjs} +1 -1
  20. package/dist/lib/{browser/chunk-KOX4WNAR.mjs → neutral/chunk-KMT3BMMQ.mjs} +35 -22
  21. package/dist/lib/neutral/chunk-KMT3BMMQ.mjs.map +7 -0
  22. package/dist/lib/neutral/chunk-KXJZEYS7.mjs +8 -0
  23. package/dist/lib/neutral/chunk-KXJZEYS7.mjs.map +7 -0
  24. package/dist/lib/neutral/chunk-MLRJWAQH.mjs +179 -0
  25. package/dist/lib/neutral/chunk-MLRJWAQH.mjs.map +7 -0
  26. package/dist/lib/neutral/chunk-TO77KAQK.mjs +298 -0
  27. package/dist/lib/neutral/chunk-TO77KAQK.mjs.map +7 -0
  28. package/dist/lib/neutral/chunk-TX3NQISZ.mjs +435 -0
  29. package/dist/lib/neutral/chunk-TX3NQISZ.mjs.map +7 -0
  30. package/dist/lib/{browser/blueprints/index.mjs → neutral/chunk-ZR4BH4QQ.mjs} +5 -6
  31. package/dist/lib/neutral/chunk-ZR4BH4QQ.mjs.map +7 -0
  32. package/dist/lib/neutral/components/index.mjs +269 -0
  33. package/dist/lib/neutral/components/index.mjs.map +7 -0
  34. package/dist/lib/neutral/containers/index.mjs +9 -0
  35. package/dist/lib/neutral/containers/index.mjs.map +7 -0
  36. package/dist/lib/{browser/create-BTWYQ6IM.mjs → neutral/create-RVR7VC33.mjs} +5 -5
  37. package/dist/lib/neutral/create-RVR7VC33.mjs.map +7 -0
  38. package/dist/lib/neutral/hooks/index.mjs +19 -0
  39. package/dist/lib/neutral/index.mjs +44 -0
  40. package/dist/lib/neutral/meta.json +1 -0
  41. package/dist/lib/neutral/meta.mjs +8 -0
  42. package/dist/lib/neutral/meta.mjs.map +7 -0
  43. package/dist/lib/{browser/open-CYRYIEZI.mjs → neutral/open-A5KXKRH4.mjs} +7 -7
  44. package/dist/lib/neutral/open-A5KXKRH4.mjs.map +7 -0
  45. package/dist/lib/neutral/operation-handler-NXMOAXFP.mjs +13 -0
  46. package/dist/lib/neutral/operation-handler-NXMOAXFP.mjs.map +7 -0
  47. package/dist/lib/neutral/operations/index.mjs +8 -0
  48. package/dist/lib/neutral/operations/index.mjs.map +7 -0
  49. package/dist/lib/neutral/plugin.mjs +16 -0
  50. package/dist/lib/neutral/plugin.mjs.map +7 -0
  51. package/dist/lib/neutral/react-surface-YMZRO242.mjs +26 -0
  52. package/dist/lib/neutral/react-surface-YMZRO242.mjs.map +7 -0
  53. package/dist/lib/{browser/summarize-X2ZYTN7S.mjs → neutral/summarize-5XPPMVTE.mjs} +9 -11
  54. package/dist/lib/neutral/summarize-5XPPMVTE.mjs.map +7 -0
  55. package/dist/lib/neutral/text-content-KBB37HSM.mjs +30 -0
  56. package/dist/lib/neutral/text-content-KBB37HSM.mjs.map +7 -0
  57. package/dist/lib/neutral/transcriber-OGSF3XO5.mjs +59 -0
  58. package/dist/lib/neutral/transcriber-OGSF3XO5.mjs.map +7 -0
  59. package/dist/lib/neutral/translations.mjs +24 -0
  60. package/dist/lib/neutral/translations.mjs.map +7 -0
  61. package/dist/lib/neutral/types/index.mjs +10 -0
  62. package/dist/lib/neutral/types/index.mjs.map +7 -0
  63. package/dist/types/src/TranscriptionPlugin.d.ts +1 -0
  64. package/dist/types/src/TranscriptionPlugin.d.ts.map +1 -1
  65. package/dist/types/src/TranscriptionPlugin.node.d.ts +4 -0
  66. package/dist/types/src/TranscriptionPlugin.node.d.ts.map +1 -0
  67. package/dist/types/src/TranscriptionPlugin.test.d.ts +2 -0
  68. package/dist/types/src/TranscriptionPlugin.test.d.ts.map +1 -0
  69. package/dist/types/src/TranscriptionPlugin.workerd.d.ts +4 -0
  70. package/dist/types/src/TranscriptionPlugin.workerd.d.ts.map +1 -0
  71. package/dist/types/src/blueprints/transcription-blueprint.d.ts +2 -2
  72. package/dist/types/src/blueprints/transcription-blueprint.d.ts.map +1 -1
  73. package/dist/types/src/capabilities/blueprint-definition.d.ts +1 -1
  74. package/dist/types/src/capabilities/blueprint-definition.d.ts.map +1 -1
  75. package/dist/types/src/capabilities/index.d.ts +8 -3
  76. package/dist/types/src/capabilities/index.d.ts.map +1 -1
  77. package/dist/types/src/capabilities/operation-handler.d.ts +1 -1
  78. package/dist/types/src/capabilities/operation-handler.d.ts.map +1 -1
  79. package/dist/types/src/capabilities/react-surface.d.ts.map +1 -1
  80. package/dist/types/src/capabilities/text-content.d.ts +8 -0
  81. package/dist/types/src/capabilities/text-content.d.ts.map +1 -0
  82. package/dist/types/src/capabilities/transcriber.d.ts +1 -1
  83. package/dist/types/src/capabilities/transcriber.d.ts.map +1 -1
  84. package/dist/types/src/components/Oracle/Oracle.d.ts +24 -0
  85. package/dist/types/src/components/Oracle/Oracle.d.ts.map +1 -0
  86. package/dist/types/src/components/Oracle/Oracle.stories.d.ts +32 -0
  87. package/dist/types/src/components/Oracle/Oracle.stories.d.ts.map +1 -0
  88. package/dist/types/src/components/Oracle/index.d.ts +2 -0
  89. package/dist/types/src/components/Oracle/index.d.ts.map +1 -0
  90. package/dist/types/src/components/Transcription/Transcription.d.ts +1 -8
  91. package/dist/types/src/components/Transcription/Transcription.d.ts.map +1 -1
  92. package/dist/types/src/components/Transcription/Transcription.stories.d.ts +20 -23
  93. package/dist/types/src/components/Transcription/Transcription.stories.d.ts.map +1 -1
  94. package/dist/types/src/components/Transcription/transcription-extension.d.ts.map +1 -1
  95. package/dist/types/src/components/index.d.ts +1 -0
  96. package/dist/types/src/components/index.d.ts.map +1 -1
  97. package/dist/types/src/containers/TranscriptionArticle/TranscriptionArticle.d.ts +6 -0
  98. package/dist/types/src/containers/TranscriptionArticle/TranscriptionArticle.d.ts.map +1 -0
  99. package/dist/types/src/containers/TranscriptionArticle/TranscriptionArticle.stories.d.ts +28 -0
  100. package/dist/types/src/containers/TranscriptionArticle/TranscriptionArticle.stories.d.ts.map +1 -0
  101. package/dist/types/src/containers/TranscriptionArticle/index.d.ts +2 -0
  102. package/dist/types/src/containers/TranscriptionArticle/index.d.ts.map +1 -0
  103. package/dist/types/src/containers/index.d.ts +1 -1
  104. package/dist/types/src/containers/index.d.ts.map +1 -1
  105. package/dist/types/src/enrichment/conversation.test.d.ts +2 -0
  106. package/dist/types/src/enrichment/conversation.test.d.ts.map +1 -0
  107. package/dist/types/src/enrichment/operations.d.ts +200 -0
  108. package/dist/types/src/enrichment/operations.d.ts.map +1 -0
  109. package/dist/types/src/enrichment/parser.d.ts +26 -0
  110. package/dist/types/src/enrichment/parser.d.ts.map +1 -0
  111. package/dist/types/src/enrichment/stream-simulator.d.ts +38 -0
  112. package/dist/types/src/enrichment/stream-simulator.d.ts.map +1 -0
  113. package/dist/types/src/hooks/index.d.ts +2 -1
  114. package/dist/types/src/hooks/index.d.ts.map +1 -1
  115. package/dist/types/src/hooks/useAudioFile.d.ts.map +1 -1
  116. package/dist/types/src/hooks/useAudioTrack.d.ts.map +1 -1
  117. package/dist/types/src/hooks/useFeedModelAdapter.d.ts +12 -0
  118. package/dist/types/src/hooks/useFeedModelAdapter.d.ts.map +1 -0
  119. package/dist/types/src/hooks/useTranscriber.d.ts +1 -1
  120. package/dist/types/src/hooks/useTranscriber.d.ts.map +1 -1
  121. package/dist/types/src/hooks/useTranscriptionRecording.d.ts +12 -0
  122. package/dist/types/src/hooks/useTranscriptionRecording.d.ts.map +1 -0
  123. package/dist/types/src/hooks/useVoiceInput.d.ts.map +1 -1
  124. package/dist/types/src/index.d.ts +2 -3
  125. package/dist/types/src/index.d.ts.map +1 -1
  126. package/dist/types/src/meta.d.ts +1 -1
  127. package/dist/types/src/meta.d.ts.map +1 -1
  128. package/dist/types/src/model/model.d.ts +2 -2
  129. package/dist/types/src/model/model.d.ts.map +1 -1
  130. package/dist/types/src/{segments-normalization → normalization}/index.d.ts +1 -1
  131. package/dist/types/src/normalization/index.d.ts.map +1 -0
  132. package/dist/types/src/{segments-normalization → normalization}/message-normalizer.d.ts +7 -5
  133. package/dist/types/src/normalization/message-normalizer.d.ts.map +1 -0
  134. package/dist/types/src/{operations/definitions.d.ts → normalization/normalization.d.ts} +464 -547
  135. package/dist/types/src/normalization/normalization.d.ts.map +1 -0
  136. package/dist/types/src/normalization/normalization.test.d.ts.map +1 -0
  137. package/dist/types/src/normalization/utils.d.ts.map +1 -0
  138. package/dist/types/src/operations/create.d.ts +3 -3
  139. package/dist/types/src/operations/create.d.ts.map +1 -1
  140. package/dist/types/src/operations/index.d.ts +1 -2
  141. package/dist/types/src/operations/index.d.ts.map +1 -1
  142. package/dist/types/src/operations/open.d.ts +3 -3
  143. package/dist/types/src/operations/open.d.ts.map +1 -1
  144. package/dist/types/src/operations/summarize.d.ts +3 -3
  145. package/dist/types/src/operations/summarize.d.ts.map +1 -1
  146. package/dist/types/src/plugin.d.ts +4 -0
  147. package/dist/types/src/plugin.d.ts.map +1 -0
  148. package/dist/types/src/stories/FileTranscription.stories.d.ts +20 -0
  149. package/dist/types/src/stories/FileTranscription.stories.d.ts.map +1 -0
  150. package/dist/types/src/stories/KeyWordRecognition.stories.d.ts.map +1 -0
  151. package/dist/types/src/{components/stories/MicrophoneTranscription.stories.d.ts → stories/LiveTranscription.stories.d.ts} +5 -5
  152. package/dist/types/src/stories/LiveTranscription.stories.d.ts.map +1 -0
  153. package/dist/types/src/stories/TranscriptionStory.d.ts +21 -0
  154. package/dist/types/src/stories/TranscriptionStory.d.ts.map +1 -0
  155. package/dist/types/src/stories/common.d.ts +248 -0
  156. package/dist/types/src/stories/common.d.ts.map +1 -0
  157. package/dist/types/src/testing/testing.d.ts +5 -6
  158. package/dist/types/src/testing/testing.d.ts.map +1 -1
  159. package/dist/types/src/transcriber/index.d.ts +1 -1
  160. package/dist/types/src/transcriber/index.d.ts.map +1 -1
  161. package/dist/types/src/transcriber/media-stream-recorder.d.ts.map +1 -1
  162. package/dist/types/src/transcriber/transcriber.d.ts +58 -3
  163. package/dist/types/src/transcriber/transcriber.d.ts.map +1 -1
  164. package/dist/types/src/transcriber/transcriber.test.d.ts +2 -0
  165. package/dist/types/src/transcriber/transcriber.test.d.ts.map +1 -0
  166. package/dist/types/src/transcriber/transcription-manager.d.ts +6 -4
  167. package/dist/types/src/transcriber/transcription-manager.d.ts.map +1 -1
  168. package/dist/types/src/translations.d.ts +9 -8
  169. package/dist/types/src/translations.d.ts.map +1 -1
  170. package/dist/types/src/types/TranscriptOperation.d.ts +1670 -0
  171. package/dist/types/src/types/TranscriptOperation.d.ts.map +1 -0
  172. package/dist/types/src/types/TranscriptionCapabilities.d.ts +17 -0
  173. package/dist/types/src/types/TranscriptionCapabilities.d.ts.map +1 -0
  174. package/dist/types/src/types/index.d.ts +2 -2
  175. package/dist/types/src/types/index.d.ts.map +1 -1
  176. package/dist/types/src/util/array.d.ts.map +1 -1
  177. package/dist/types/src/util/get-time-str.d.ts.map +1 -1
  178. package/dist/types/src/util/monitor-audio-level.d.ts.map +1 -1
  179. package/dist/types/src/util/render-byline.d.ts.map +1 -1
  180. package/dist/types/tsconfig.tsbuildinfo +1 -1
  181. package/package.json +136 -102
  182. package/src/TranscriptionPlugin.node.ts +20 -0
  183. package/src/TranscriptionPlugin.test.ts +31 -0
  184. package/src/TranscriptionPlugin.tsx +11 -31
  185. package/src/TranscriptionPlugin.workerd.ts +18 -0
  186. package/src/blueprints/transcription-blueprint.ts +3 -4
  187. package/src/capabilities/blueprint-definition.ts +6 -4
  188. package/src/capabilities/index.ts +9 -2
  189. package/src/capabilities/operation-handler.ts +1 -1
  190. package/src/capabilities/react-surface.tsx +2 -2
  191. package/src/capabilities/text-content.ts +33 -0
  192. package/src/capabilities/transcriber.ts +9 -5
  193. package/src/components/Oracle/Oracle.stories.tsx +147 -0
  194. package/src/components/Oracle/Oracle.tsx +142 -0
  195. package/src/components/Oracle/index.ts +5 -0
  196. package/src/components/Transcription/Transcription.stories.tsx +117 -153
  197. package/src/components/Transcription/Transcription.tsx +8 -17
  198. package/src/components/index.ts +1 -0
  199. package/src/containers/TranscriptionArticle/TranscriptionArticle.stories.tsx +61 -0
  200. package/src/containers/TranscriptionArticle/TranscriptionArticle.tsx +62 -0
  201. package/src/containers/TranscriptionArticle/index.ts +5 -0
  202. package/src/containers/index.ts +1 -1
  203. package/src/enrichment/conversation.test.ts +162 -0
  204. package/src/enrichment/conversation.txt +23 -0
  205. package/src/enrichment/operations.ts +271 -0
  206. package/src/enrichment/parser.ts +101 -0
  207. package/src/enrichment/stream-simulator.ts +125 -0
  208. package/src/hooks/index.ts +2 -1
  209. package/src/hooks/useAudioTrack.ts +1 -1
  210. package/src/hooks/useFeedModelAdapter.ts +46 -0
  211. package/src/hooks/useTranscriber.ts +7 -5
  212. package/src/hooks/useTranscriptionRecording.ts +87 -0
  213. package/src/hooks/useVoiceInput.ts +1 -1
  214. package/src/index.ts +4 -5
  215. package/src/meta.ts +28 -6
  216. package/src/model/model.test.ts +5 -5
  217. package/src/model/model.ts +3 -3
  218. package/src/{segments-normalization → normalization}/message-normalizer.ts +25 -17
  219. package/src/{segments-normalization → normalization}/normalization.test.ts +4 -38
  220. package/src/{segments-normalization → normalization}/normalization.ts +8 -9
  221. package/src/operations/create.ts +3 -3
  222. package/src/operations/index.ts +1 -3
  223. package/src/operations/open.ts +3 -3
  224. package/src/operations/summarize.ts +7 -7
  225. package/src/plugin.ts +11 -0
  226. package/src/stories/FileTranscription.stories.tsx +143 -0
  227. package/src/{components/stories → stories}/KeyWordRecognition.stories.tsx +36 -36
  228. package/src/stories/LiveTranscription.stories.tsx +153 -0
  229. package/src/stories/TranscriptionStory.tsx +101 -0
  230. package/src/stories/common.ts +233 -0
  231. package/src/testing/testing.ts +22 -34
  232. package/src/transcriber/index.ts +1 -1
  233. package/src/transcriber/transcriber.test.ts +104 -0
  234. package/src/transcriber/transcriber.ts +100 -55
  235. package/src/transcriber/transcription-manager.ts +14 -9
  236. package/src/translations.ts +3 -0
  237. package/src/{operations/definitions.ts → types/TranscriptOperation.ts} +14 -9
  238. package/src/types/TranscriptionCapabilities.ts +39 -0
  239. package/src/types/index.ts +2 -2
  240. package/src/vite-env.d.ts +10 -0
  241. package/dist/lib/browser/blueprints/index.mjs.map +0 -7
  242. package/dist/lib/browser/chunk-5LWSJZTZ.mjs +0 -17
  243. package/dist/lib/browser/chunk-5LWSJZTZ.mjs.map +0 -7
  244. package/dist/lib/browser/chunk-KOX4WNAR.mjs.map +0 -7
  245. package/dist/lib/browser/create-BTWYQ6IM.mjs.map +0 -7
  246. package/dist/lib/browser/index.mjs +0 -1213
  247. package/dist/lib/browser/index.mjs.map +0 -7
  248. package/dist/lib/browser/meta.json +0 -1
  249. package/dist/lib/browser/open-CYRYIEZI.mjs.map +0 -7
  250. package/dist/lib/browser/operations/index.mjs +0 -13
  251. package/dist/lib/browser/operations/index.mjs.map +0 -7
  252. package/dist/lib/browser/summarize-X2ZYTN7S.mjs.map +0 -7
  253. package/dist/lib/browser/types/index.mjs +0 -10
  254. package/dist/lib/node-esm/blueprints/index.mjs +0 -32
  255. package/dist/lib/node-esm/blueprints/index.mjs.map +0 -7
  256. package/dist/lib/node-esm/chunk-HSLMI22Q.mjs +0 -11
  257. package/dist/lib/node-esm/chunk-MT5I4NH5.mjs +0 -112
  258. package/dist/lib/node-esm/chunk-MT5I4NH5.mjs.map +0 -7
  259. package/dist/lib/node-esm/chunk-NVM2QUMX.mjs +0 -37
  260. package/dist/lib/node-esm/chunk-NVM2QUMX.mjs.map +0 -7
  261. package/dist/lib/node-esm/chunk-X74WYCCE.mjs +0 -19
  262. package/dist/lib/node-esm/chunk-X74WYCCE.mjs.map +0 -7
  263. package/dist/lib/node-esm/create-MLUFPST2.mjs +0 -22
  264. package/dist/lib/node-esm/create-MLUFPST2.mjs.map +0 -7
  265. package/dist/lib/node-esm/index.mjs +0 -1214
  266. package/dist/lib/node-esm/index.mjs.map +0 -7
  267. package/dist/lib/node-esm/meta.json +0 -1
  268. package/dist/lib/node-esm/open-5IOC2U4Z.mjs +0 -28
  269. package/dist/lib/node-esm/open-5IOC2U4Z.mjs.map +0 -7
  270. package/dist/lib/node-esm/operations/index.mjs +0 -14
  271. package/dist/lib/node-esm/operations/index.mjs.map +0 -7
  272. package/dist/lib/node-esm/summarize-IORITU7T.mjs +0 -80
  273. package/dist/lib/node-esm/summarize-IORITU7T.mjs.map +0 -7
  274. package/dist/lib/node-esm/types/index.mjs +0 -11
  275. package/dist/types/src/components/stories/FileTranscription.stories.d.ts +0 -18
  276. package/dist/types/src/components/stories/FileTranscription.stories.d.ts.map +0 -1
  277. package/dist/types/src/components/stories/KeyWordRecognition.stories.d.ts.map +0 -1
  278. package/dist/types/src/components/stories/MicrophoneTranscription.stories.d.ts.map +0 -1
  279. package/dist/types/src/components/stories/TranscriptionStory.d.ts +0 -12
  280. package/dist/types/src/components/stories/TranscriptionStory.d.ts.map +0 -1
  281. package/dist/types/src/components/stories/useIsSpeaking.d.ts +0 -3
  282. package/dist/types/src/components/stories/useIsSpeaking.d.ts.map +0 -1
  283. package/dist/types/src/containers/TranscriptionContainer/TranscriptionContainer.d.ts +0 -6
  284. package/dist/types/src/containers/TranscriptionContainer/TranscriptionContainer.d.ts.map +0 -1
  285. package/dist/types/src/containers/TranscriptionContainer/index.d.ts +0 -2
  286. package/dist/types/src/containers/TranscriptionContainer/index.d.ts.map +0 -1
  287. package/dist/types/src/hooks/useQueueModelAdapter.d.ts +0 -8
  288. package/dist/types/src/hooks/useQueueModelAdapter.d.ts.map +0 -1
  289. package/dist/types/src/operations/definitions.d.ts.map +0 -1
  290. package/dist/types/src/segments-normalization/index.d.ts.map +0 -1
  291. package/dist/types/src/segments-normalization/message-normalizer.d.ts.map +0 -1
  292. package/dist/types/src/segments-normalization/normalization.d.ts +0 -364
  293. package/dist/types/src/segments-normalization/normalization.d.ts.map +0 -1
  294. package/dist/types/src/segments-normalization/normalization.test.d.ts.map +0 -1
  295. package/dist/types/src/segments-normalization/utils.d.ts.map +0 -1
  296. package/dist/types/src/types/capabilities.d.ts +0 -18
  297. package/dist/types/src/types/capabilities.d.ts.map +0 -1
  298. package/dist/types/src/types/types.d.ts +0 -5
  299. package/dist/types/src/types/types.d.ts.map +0 -1
  300. package/src/components/stories/FileTranscription.stories.tsx +0 -250
  301. package/src/components/stories/MicrophoneTranscription.stories.tsx +0 -264
  302. package/src/components/stories/TranscriptionStory.tsx +0 -43
  303. package/src/components/stories/useIsSpeaking.tsx +0 -40
  304. package/src/containers/TranscriptionContainer/TranscriptionContainer.tsx +0 -35
  305. package/src/containers/TranscriptionContainer/index.ts +0 -5
  306. package/src/hooks/useQueueModelAdapter.ts +0 -66
  307. package/src/types/capabilities.ts +0 -34
  308. package/src/types/types.ts +0 -9
  309. package/dist/lib/{browser/types → neutral/blueprints}/index.mjs.map +0 -0
  310. package/dist/lib/{browser → neutral}/chunk-J5LGTIGS.mjs +0 -0
  311. package/dist/lib/{browser → neutral}/chunk-J5LGTIGS.mjs.map +0 -0
  312. package/dist/lib/{browser/chunk-HOOPZ7EM.mjs.map → neutral/chunk-KAEXRX3Y.mjs.map} +0 -0
  313. package/dist/lib/{node-esm/types → neutral/hooks}/index.mjs.map +0 -0
  314. package/dist/lib/{node-esm/chunk-HSLMI22Q.mjs.map → neutral/index.mjs.map} +0 -0
  315. package/dist/types/src/{segments-normalization → normalization}/normalization.test.d.ts +0 -0
  316. package/dist/types/src/{segments-normalization → normalization}/utils.d.ts +0 -0
  317. package/dist/types/src/{components/stories → stories}/KeyWordRecognition.stories.d.ts +0 -0
  318. package/src/{segments-normalization → normalization}/index.ts +1 -1
  319. /package/src/{segments-normalization → normalization}/utils.ts +0 -0
@@ -10,12 +10,15 @@ import { log } from '@dxos/log';
10
10
  import { trace } from '@dxos/tracing';
11
11
  import { type ContentBlock } from '@dxos/types';
12
12
 
13
- import { TRANSCRIPTION_URL } from '#types';
14
-
15
13
  import { mergeFloat64Arrays } from '../util';
16
14
  import { type AudioChunk, type AudioRecorder } from './audio-recorder';
17
15
 
18
- type WhisperWord = {
16
+ /**
17
+ * Endpoint to the calls service.
18
+ */
19
+ const DEFAULT_TRANSCRIPTION_URL = 'https://calls-service.dxos.workers.dev';
20
+
21
+ export type WhisperWord = {
19
22
  word: string;
20
23
 
21
24
  /**
@@ -29,7 +32,7 @@ type WhisperWord = {
29
32
  end: number;
30
33
  };
31
34
 
32
- type WhisperSegment = {
35
+ export type WhisperSegment = {
33
36
  text: string;
34
37
 
35
38
  /**
@@ -61,8 +64,20 @@ export type TranscribeConfig = {
61
64
  * This is needed to catch the beginning of the user's speech.
62
65
  */
63
66
  prefixBufferChunksAmount: number;
67
+
68
+ /**
69
+ * Override the transcription endpoint base URL.
70
+ * Defaults to the DXOS calls service.
71
+ */
72
+ endpoint?: string;
64
73
  };
65
74
 
75
+ /**
76
+ * Function that converts a base64-encoded WAV payload into Whisper segments.
77
+ * Allows callers to swap in alternative providers or mock the transport.
78
+ */
79
+ export type TranscribeFn = (audio: string) => Promise<WhisperSegment[]>;
80
+
66
81
  export type TranscriberProps = {
67
82
  config: TranscribeConfig;
68
83
  recorder: AudioRecorder;
@@ -71,6 +86,10 @@ export type TranscriberProps = {
71
86
  * @param segments - The transcribed segments.
72
87
  */
73
88
  onSegments: (segments: ContentBlock.Transcript[]) => Promise<void>;
89
+ /**
90
+ * Optional override of the transcription transport. When provided, supersedes `config.endpoint`.
91
+ */
92
+ transcribe?: TranscribeFn;
74
93
  };
75
94
 
76
95
  /**
@@ -80,22 +99,24 @@ export type TranscriberProps = {
80
99
  */
81
100
  export class Transcriber extends Resource {
82
101
  private _audioChunks: AudioChunk[] = [];
83
- private _lastUsedTimestamp = 0;
102
+ private _lastTimestamp = 0;
84
103
 
85
104
  private readonly _openTrigger = new Trigger({ autoReset: true });
86
105
 
87
106
  private readonly _config: TranscribeConfig;
88
107
  private readonly _recorder: AudioRecorder;
89
108
  private readonly _onSegments: TranscriberProps['onSegments'];
109
+ private readonly _transcribeFn?: TranscribeFn;
90
110
 
91
111
  private _recording = false;
92
112
  private _transcribeTask?: DeferredTask = undefined;
93
113
 
94
- constructor({ config, recorder, onSegments }: TranscriberProps) {
114
+ constructor({ config, recorder, onSegments, transcribe }: TranscriberProps) {
95
115
  super();
96
116
  this._config = config;
97
117
  this._recorder = recorder;
98
118
  this._onSegments = onSegments;
119
+ this._transcribeFn = transcribe;
99
120
  }
100
121
 
101
122
  protected override async _open(ctx: Context): Promise<void> {
@@ -192,67 +213,91 @@ export class Transcriber extends Resource {
192
213
  @trace.span({ showInBrowserTimeline: true })
193
214
  private async _fetchTranscription(audio: string): Promise<WhisperSegment[]> {
194
215
  if (audio.length === 0) {
195
- this._audioChunks = [];
196
216
  throw new Error('No audio to send for transcribing');
197
217
  }
198
218
 
199
- const response = await fetch(`${TRANSCRIPTION_URL}/transcribe`, {
200
- method: 'POST',
201
- body: JSON.stringify({ audio }),
202
- headers: {
203
- 'Content-Type': 'application/json',
204
- },
205
- });
206
-
207
- if (!response.ok) {
208
- this._audioChunks = [];
209
- throw new Error(`Transcription failed: ${response.statusText}`);
219
+ let segments: unknown;
220
+ if (this._transcribeFn) {
221
+ segments = await this._transcribeFn(audio);
222
+ } else {
223
+ // TODO(burdon): Create separate endpoint?
224
+ const endpoint = this._config.endpoint ?? DEFAULT_TRANSCRIPTION_URL;
225
+ const response = await fetch(`${endpoint}/transcribe`, {
226
+ method: 'POST',
227
+ body: JSON.stringify({ audio }),
228
+ headers: {
229
+ 'Content-Type': 'application/json',
230
+ },
231
+ });
232
+
233
+ if (!response.ok) {
234
+ throw new Error(`Transcription failed: ${response.statusText}`);
235
+ }
236
+
237
+ ({ segments } = (await response.json()) as { segments?: unknown });
210
238
  }
211
239
 
212
- const { segments } = (await response.json()) as {
213
- segments: WhisperSegment[];
214
- };
215
-
216
- log.info('transcription response', {
217
- segments: segments.length,
218
- string: segments.map((segments) => segments.text).join(' '),
219
- });
240
+ if (!Array.isArray(segments)) {
241
+ throw new Error('Transcription response payload is invalid');
242
+ }
220
243
 
221
- return segments;
244
+ log.info('transcription response', { segments: segments.length });
245
+ return segments as WhisperSegment[];
222
246
  }
223
247
 
224
248
  private _alignSegments(segments: WhisperSegment[], originalChunks: AudioChunk[]): ContentBlock.Transcript[] {
225
- // Absolute zero for all relative timestamps in the segments.
226
- const zeroTimestamp = originalChunks.at(0)!.timestamp;
227
-
228
- const filteredSegments = segments
229
- // Use segments that end after the last used timestamp.
230
- // Segments could overlap, so we need to filter words that starts after the last used timestamp.
231
- .filter((segment) => zeroTimestamp + segment.end * 1_000 >= this._lastUsedTimestamp)
232
- // Use words that starts after the last used timestamp.
233
- .map((segment) => {
234
- const words = segment.words.filter((word) => zeroTimestamp + word.start * 1_000 >= this._lastUsedTimestamp);
235
- return {
236
- ...segment,
237
- words,
238
- text: words.map((word) => word.word).join(''),
239
- start: words.at(0)?.start ?? segment.end,
240
- };
241
- })
242
- .filter((segment) => segment.words.length > 0);
243
-
244
- if (filteredSegments.length === 0) {
245
- return [];
249
+ const result = alignWhisperSegments(segments, originalChunks, this._lastTimestamp);
250
+ if (result.lastTimestamp !== undefined) {
251
+ this._lastTimestamp = result.lastTimestamp;
246
252
  }
247
253
 
248
- // Update last timestamp.
249
- this._lastUsedTimestamp = zeroTimestamp + filteredSegments.at(-1)!.end * 1_000;
254
+ return result.transcripts;
255
+ }
256
+ }
257
+
258
+ /**
259
+ * Pure helper that filters and absolute-timestamps Whisper segments against a chunk timeline.
260
+ * Exported for testing.
261
+ *
262
+ * @param segments - Raw segments returned by the Whisper service for `originalChunks`.
263
+ * @param originalChunks - Chunks fed into the transcription request (used for the zero timestamp).
264
+ * @param lastTimestamp - Most recent absolute timestamp already emitted; segments whose end
265
+ * falls strictly before this point are deduped out, as are individual words whose start does.
266
+ */
267
+ export const alignWhisperSegments = (
268
+ segments: WhisperSegment[],
269
+ originalChunks: AudioChunk[],
270
+ lastTimestamp: number,
271
+ ): { transcripts: ContentBlock.Transcript[]; lastTimestamp?: number } => {
272
+ if (originalChunks.length === 0) {
273
+ return { transcripts: [] };
274
+ }
275
+
276
+ const zeroTimestamp = originalChunks[0].timestamp;
277
+
278
+ const filteredSegments = segments
279
+ .filter((segment) => zeroTimestamp + segment.end * 1_000 >= lastTimestamp)
280
+ .map((segment) => {
281
+ const words = segment.words.filter((word) => zeroTimestamp + word.start * 1_000 >= lastTimestamp);
282
+ return {
283
+ ...segment,
284
+ words,
285
+ text: words.map((word) => word.word).join(''),
286
+ start: words.at(0)?.start ?? segment.end,
287
+ };
288
+ })
289
+ .filter((segment) => segment.words.length > 0);
290
+
291
+ if (filteredSegments.length === 0) {
292
+ return { transcripts: [] };
293
+ }
250
294
 
251
- // Add absolute timestamp to each segment.
252
- return filteredSegments.map((segment) => ({
295
+ return {
296
+ lastTimestamp: zeroTimestamp + filteredSegments.at(-1)!.end * 1_000,
297
+ transcripts: filteredSegments.map((segment) => ({
253
298
  _tag: 'transcript',
254
299
  started: new Date(zeroTimestamp + segment.start * 1_000).toISOString(),
255
300
  text: segment.text.trim(),
256
- }));
257
- }
258
- }
301
+ })),
302
+ };
303
+ };
@@ -3,11 +3,14 @@
3
3
  //
4
4
 
5
5
  import { Atom, type Registry } from '@effect-atom/atom-react';
6
+ import * as Effect from 'effect/Effect';
7
+ import * as Layer from 'effect/Layer';
6
8
 
7
9
  import { synchronized } from '@dxos/async';
10
+ import { createFeedServiceLayer, type Space } from '@dxos/client/echo';
8
11
  import { Resource } from '@dxos/context';
9
- import { Obj } from '@dxos/echo';
10
- import { type Queue } from '@dxos/echo-db';
12
+ import { Feed, Obj } from '@dxos/echo';
13
+ import { EffectEx } from '@dxos/effect';
11
14
  import { type EdgeHttpClient } from '@dxos/react-edge-client';
12
15
  import { type ContentBlock, Message } from '@dxos/types';
13
16
 
@@ -37,7 +40,7 @@ export type TranscriptionManagerOptions = {
37
40
  registry: Registry.Registry;
38
41
 
39
42
  /**
40
- * Enrich the message before it is written to the transcription queue.
43
+ * Enrich the message before it is written to the transcription feed.
41
44
  */
42
45
  messageEnricher?: TranscriptMessageEnricher;
43
46
  };
@@ -53,7 +56,8 @@ export class TranscriptionManager extends Resource {
53
56
  private _identityDid?: string = undefined;
54
57
  private _mediaRecorder?: MediaStreamRecorder = undefined;
55
58
  private _transcriber?: Transcriber = undefined;
56
- private _queue?: Queue<Message.Message> = undefined;
59
+ private _feed?: Feed.Feed = undefined;
60
+ private _feedServiceLayer?: Layer.Layer<Feed.FeedService> = undefined;
57
61
  private _enabledAtom = Atom.make(false);
58
62
 
59
63
  constructor(options: TranscriptionManagerOptions) {
@@ -71,8 +75,9 @@ export class TranscriptionManager extends Resource {
71
75
  return this._registry.get(this._enabledAtom);
72
76
  }
73
77
 
74
- setQueue(queue: Queue<Message.Message>): this {
75
- this._queue = queue;
78
+ setFeed(space: Space, feed: Feed.Feed): this {
79
+ this._feed = feed;
80
+ this._feedServiceLayer = createFeedServiceLayer(space.queues);
76
81
  return this;
77
82
  }
78
83
 
@@ -132,7 +137,7 @@ export class TranscriptionManager extends Resource {
132
137
  return;
133
138
  }
134
139
 
135
- // Reinitialize transcriber if queue or media stream track has changed.
140
+ // Reinitialize transcriber if feed or media stream track has changed.
136
141
  let needReinit = false;
137
142
  if (this._audioStreamTrack !== this._mediaRecorder?.mediaStreamTrack) {
138
143
  this._mediaRecorder = new MediaStreamRecorder({
@@ -161,7 +166,7 @@ export class TranscriptionManager extends Resource {
161
166
  }
162
167
 
163
168
  private async _onSegments(segments: ContentBlock.Transcript[]): Promise<void> {
164
- if (!this.isOpen || !this._queue) {
169
+ if (!this.isOpen || !this._feed || !this._feedServiceLayer) {
165
170
  return;
166
171
  }
167
172
 
@@ -175,6 +180,6 @@ export class TranscriptionManager extends Resource {
175
180
  block = await this._messageEnricher(block);
176
181
  }
177
182
 
178
- await this._queue.append([block]);
183
+ await Feed.append(this._feed, [block]).pipe(Effect.provide(this._feedServiceLayer), EffectEx.runAndForwardErrors);
179
184
  }
180
185
  }
@@ -17,6 +17,9 @@ export const translations = [
17
17
  'bookmark.button': 'Bookmark',
18
18
  'scroll-to-end.label': 'Scroll to latest',
19
19
 
20
+ 'start-recording.label': 'Start recording',
21
+ 'stop-recording.label': 'Stop recording',
22
+
20
23
  'settings.entity-extraction.label': 'Entity extraction',
21
24
  },
22
25
  },
@@ -2,31 +2,33 @@
2
2
  // Copyright 2025 DXOS.org
3
3
  //
4
4
 
5
+ // @import-as-namespace
6
+
5
7
  import * as Schema from 'effect/Schema';
6
8
 
7
9
  import { AiService } from '@dxos/ai';
8
10
  import { SpaceSchema } from '@dxos/client/echo';
9
- import { Database, Feed, Ref } from '@dxos/echo';
10
- import { Operation } from '@dxos/operation';
11
+ import { Operation } from '@dxos/compute';
12
+ import { Database, Feed, Ref, Type, DXN } from '@dxos/echo';
11
13
  import { Message, Transcript } from '@dxos/types';
12
14
 
13
15
  import { meta } from '#meta';
14
16
 
15
- const TRANSCRIPT_OPERATION = `${meta.id}.operation`;
17
+ const makeKey = (name: string) => DXN.make(`${meta.id}.operation.${name}`);
16
18
 
17
19
  export const Create = Operation.make({
18
- meta: { key: `${TRANSCRIPT_OPERATION}.create`, name: 'Create Transcript' },
20
+ meta: { key: makeKey('create'), name: 'Create Transcript', icon: 'ph--microphone--regular' },
19
21
  input: Schema.Struct({
20
22
  name: Schema.optional(Schema.String),
21
23
  space: SpaceSchema,
22
24
  }),
23
25
  output: Schema.Struct({
24
- object: Transcript.Transcript,
26
+ object: Type.getSchema(Transcript.Transcript),
25
27
  }),
26
28
  });
27
29
 
28
30
  export const MessageWithRangeId = Schema.extend(
29
- Message.Message,
31
+ Type.getSchema(Message.Message),
30
32
  Schema.Struct({
31
33
  rangeId: Schema.optional(Schema.Array(Schema.String)).annotations({
32
34
  description: 'The IDs of the messages that contain the sentences.',
@@ -38,9 +40,10 @@ export type MessageWithRangeIdType = Schema.Schema.Type<typeof MessageWithRangeI
38
40
 
39
41
  export const Open = Operation.make({
40
42
  meta: {
41
- key: 'org.dxos.function.transcription.open',
43
+ key: DXN.make('org.dxos.function.transcription.open'),
42
44
  name: 'Open',
43
45
  description: 'Opens and reads the contents of a transcription object.',
46
+ icon: 'ph--folder-open--regular',
44
47
  },
45
48
  input: Schema.Struct({
46
49
  transcript: Ref.Ref(Transcript.Transcript).annotations({
@@ -55,9 +58,10 @@ export const Open = Operation.make({
55
58
 
56
59
  export const Summarize = Operation.make({
57
60
  meta: {
58
- key: 'org.dxos.function.transcription.summarize',
61
+ key: DXN.make('org.dxos.function.transcription.summarize'),
59
62
  name: 'Summarize',
60
63
  description: 'Summarize a transcript of a meeting.',
64
+ icon: 'ph--text-align-left--regular',
61
65
  },
62
66
  input: Schema.Struct({
63
67
  transcript: Schema.String.annotations({
@@ -91,9 +95,10 @@ export const SentenceNormalizationOutput = Schema.Struct({
91
95
 
92
96
  export const SentenceNormalization = Operation.make({
93
97
  meta: {
94
- key: 'org.dxos.function.transcription.sentence-normalization',
98
+ key: DXN.make('org.dxos.function.transcription.sentenceNormalization'),
95
99
  name: 'Sentence Normalization',
96
100
  description: 'Post process of transcription for sentence normalization',
101
+ icon: 'ph--text-t--regular',
97
102
  },
98
103
  input: SentenceNormalizationInput,
99
104
  output: SentenceNormalizationOutput,
@@ -0,0 +1,39 @@
1
+ //
2
+ // Copyright 2025 DXOS.org
3
+ //
4
+
5
+ // @import-as-namespace
6
+
7
+ import { Capability } from '@dxos/app-framework';
8
+
9
+ import { meta } from '#meta';
10
+
11
+ import {
12
+ type MediaStreamRecorderProps,
13
+ type Transcriber as TranscriberType,
14
+ type TranscriberProps,
15
+ type TranscriptMessageEnricher,
16
+ type TranscriptionManager as TranscriptionManagerType,
17
+ } from '../transcriber';
18
+
19
+ export type TranscriberProviderProps = {
20
+ audioStreamTrack: MediaStreamTrack;
21
+ recorderConfig?: Partial<MediaStreamRecorderProps['config']>;
22
+ transcriberConfig?: Partial<TranscriberProps['config']>;
23
+ onSegments: TranscriberProps['onSegments'];
24
+ transcribe?: TranscriberProps['transcribe'];
25
+ };
26
+
27
+ export type TranscriberProvider = (props: TranscriberProviderProps) => TranscriberType;
28
+
29
+ export type TranscriptionManagerProviderProps = {
30
+ messageEnricher?: TranscriptMessageEnricher;
31
+ };
32
+
33
+ export type TranscriptionManagerProvider = (props: TranscriptionManagerProviderProps) => TranscriptionManagerType;
34
+
35
+ export const TranscriberProvider = Capability.make<TranscriberProvider>(`${meta.id}.capability.transcriber`);
36
+
37
+ export const TranscriptionManagerProvider = Capability.make<TranscriptionManagerProvider>(
38
+ `${meta.id}.capability.transcription-manager`,
39
+ );
@@ -2,5 +2,5 @@
2
2
  // Copyright 2025 DXOS.org
3
3
  //
4
4
 
5
- export * from './capabilities';
6
- export * from './types';
5
+ export * as TranscriptionCapabilities from './TranscriptionCapabilities';
6
+ export * as TranscriptOperation from './TranscriptOperation';
@@ -0,0 +1,10 @@
1
+ /// <reference types="vite/client" />
2
+
3
+ //
4
+ // Copyright 2026 DXOS.org
5
+ //
6
+
7
+ declare module '*.mdl?raw' {
8
+ const content: string;
9
+ export default content;
10
+ }
@@ -1,7 +0,0 @@
1
- {
2
- "version": 3,
3
- "sources": ["../../../../src/blueprints/transcription-blueprint.ts"],
4
- "sourcesContent": ["//\n// Copyright 2025 DXOS.org\n//\n\nimport { type AppCapabilities } from '@dxos/app-toolkit';\nimport { Blueprint, Template } from '@dxos/blueprints';\nimport { trim } from '@dxos/util';\n\nimport { TranscriptOperation } from '#operations';\n\nconst BLUEPRINT_KEY = 'org.dxos.blueprint.transcription';\n\nconst make = () =>\n Blueprint.make({\n key: BLUEPRINT_KEY,\n name: 'Transcription',\n tools: Blueprint.toolDefinitions({ operations: [TranscriptOperation.Open, TranscriptOperation.Summarize] }),\n instructions: Template.make({\n source: trim`\n You can open and summarize a meeting transcript.\n `,\n }),\n });\n\nconst blueprint: AppCapabilities.BlueprintDefinition = {\n key: BLUEPRINT_KEY,\n make,\n};\n\nexport default blueprint;\n"],
5
- "mappings": ";;;AAKA,SAASA,WAAWC,gBAAgB;AACpC,SAASC,YAAY;AAErB,SAASC,2BAA2B;AAEpC,IAAMC,gBAAgB;AAEtB,IAAMC,OAAO,MACXC,UAAUD,KAAK;EACbE,KAAKH;EACLI,MAAM;EACNC,OAAOH,UAAUI,gBAAgB;IAAEC,YAAY;MAACC,oBAAoBC;MAAMD,oBAAoBE;;EAAW,CAAA;EACzGC,cAAcC,SAASX,KAAK;IAC1BY,QAAQC;;;EAGV,CAAA;AACF,CAAA;AAEF,IAAMC,YAAiD;EACrDZ,KAAKH;EACLC;AACF;AAEA,IAAA,kCAAec;",
6
- "names": ["Blueprint", "Template", "trim", "TranscriptOperation", "BLUEPRINT_KEY", "make", "Blueprint", "key", "name", "tools", "toolDefinitions", "operations", "TranscriptOperation", "Open", "Summarize", "instructions", "Template", "source", "trim", "blueprint"]
7
- }
@@ -1,17 +0,0 @@
1
- // src/types/capabilities.ts
2
- import { Capability } from "@dxos/app-framework";
3
- import { meta } from "#meta";
4
- (function(TranscriptionCapabilities2) {
5
- TranscriptionCapabilities2.Transcriber = Capability.make(`${meta.id}.capability.transcriber`);
6
- TranscriptionCapabilities2.TranscriptionManager = Capability.make(`${meta.id}.capability.transcription-manager`);
7
- })(TranscriptionCapabilities || (TranscriptionCapabilities = {}));
8
- var TranscriptionCapabilities;
9
-
10
- // src/types/types.ts
11
- var TRANSCRIPTION_URL = "https://calls-service.dxos.workers.dev";
12
-
13
- export {
14
- TranscriptionCapabilities,
15
- TRANSCRIPTION_URL
16
- };
17
- //# sourceMappingURL=chunk-5LWSJZTZ.mjs.map
@@ -1,7 +0,0 @@
1
- {
2
- "version": 3,
3
- "sources": ["../../../src/types/capabilities.ts", "../../../src/types/types.ts"],
4
- "sourcesContent": ["//\n// Copyright 2025 DXOS.org\n//\n\nimport { Capability } from '@dxos/app-framework';\n\nimport { meta } from '#meta';\n\nimport {\n type MediaStreamRecorderProps,\n type Transcriber,\n type TranscriberProps,\n type TranscriptMessageEnricher,\n type TranscriptionManager,\n} from '../transcriber';\n\nexport namespace TranscriptionCapabilities {\n export type GetTranscriberProps = {\n audioStreamTrack: MediaStreamTrack;\n recorderConfig?: Partial<MediaStreamRecorderProps['config']>;\n transcriberConfig?: Partial<TranscriberProps['config']>;\n onSegments: TranscriberProps['onSegments'];\n };\n export type GetTranscriber = (props: GetTranscriberProps) => Transcriber;\n export const Transcriber = Capability.make<GetTranscriber>(`${meta.id}.capability.transcriber`);\n\n export type GetTranscriptionManagerProps = {\n messageEnricher?: TranscriptMessageEnricher;\n };\n export type GetTranscriptionManager = (props: GetTranscriptionManagerProps) => TranscriptionManager;\n export const TranscriptionManager = Capability.make<GetTranscriptionManager>(\n `${meta.id}.capability.transcription-manager`,\n );\n}\n", "//\n// Copyright 2025 DXOS.org\n//\n\n/**\n * Endpoint to the calls service.\n */\n// TODO(burdon): Reconfigure/move.\nexport const TRANSCRIPTION_URL = 'https://calls-service.dxos.workers.dev';\n"],
5
- "mappings": ";AAIA,SAASA,kBAAkB;AAE3B,SAASC,YAAY;UAUJC,4BAAAA;6BAQFC,cAAcC,WAAWC,KAAqB,GAAGC,KAAKC,EAAE,yBAAyB;6BAMjFC,uBAAuBJ,WAAWC,KAC7C,GAAGC,KAAKC,EAAE,mCAAmC;AAEjD,GAjBiBL,8BAAAA,4BAAAA,CAAAA,EAAAA;;;;ACRV,IAAMO,oBAAoB;",
6
- "names": ["Capability", "meta", "TranscriptionCapabilities", "Transcriber", "Capability", "make", "meta", "id", "TranscriptionManager", "TRANSCRIPTION_URL"]
7
- }
@@ -1,7 +0,0 @@
1
- {
2
- "version": 3,
3
- "sources": ["../../../src/operations/definitions.ts"],
4
- "sourcesContent": ["//\n// Copyright 2025 DXOS.org\n//\n\nimport * as Schema from 'effect/Schema';\n\nimport { AiService } from '@dxos/ai';\nimport { SpaceSchema } from '@dxos/client/echo';\nimport { Database, Feed, Ref } from '@dxos/echo';\nimport { Operation } from '@dxos/operation';\nimport { Message, Transcript } from '@dxos/types';\n\nimport { meta } from '#meta';\n\nconst TRANSCRIPT_OPERATION = `${meta.id}.operation`;\n\nexport const Create = Operation.make({\n meta: { key: `${TRANSCRIPT_OPERATION}.create`, name: 'Create Transcript' },\n input: Schema.Struct({\n name: Schema.optional(Schema.String),\n space: SpaceSchema,\n }),\n output: Schema.Struct({\n object: Transcript.Transcript,\n }),\n});\n\nexport const MessageWithRangeId = Schema.extend(\n Message.Message,\n Schema.Struct({\n rangeId: Schema.optional(Schema.Array(Schema.String)).annotations({\n description: 'The IDs of the messages that contain the sentences.',\n }),\n }),\n);\n\nexport type MessageWithRangeIdType = Schema.Schema.Type<typeof MessageWithRangeId>;\n\nexport const Open = Operation.make({\n meta: {\n key: 'org.dxos.function.transcription.open',\n name: 'Open',\n description: 'Opens and reads the contents of a transcription object.',\n },\n input: Schema.Struct({\n transcript: Ref.Ref(Transcript.Transcript).annotations({\n description: 'The ID of the transcription object.',\n }),\n }),\n output: Schema.Struct({\n content: Schema.String,\n }),\n services: [Database.Service, Feed.FeedService],\n});\n\nexport const Summarize = Operation.make({\n meta: {\n key: 'org.dxos.function.transcription.summarize',\n name: 'Summarize',\n description: 'Summarize a transcript of a meeting.',\n },\n input: Schema.Struct({\n transcript: Schema.String.annotations({\n description: 'The transcript of the meeting.',\n }),\n notes: Schema.optional(Schema.String).annotations({\n description: 'Additional notes from the participants.',\n }),\n }),\n output: Schema.Struct({\n summary: Schema.String.annotations({\n description: 'The summary of the transcript.',\n }),\n }),\n services: [AiService.AiService],\n});\n\nexport const SentenceNormalizationInput = Schema.Struct({\n messages: Schema.Array(MessageWithRangeId).annotations({\n description: 'Messages to normalize into sentences.',\n }),\n});\n\nexport type SentenceNormalizationInputType = Schema.Schema.Type<typeof SentenceNormalizationInput>;\n\nexport const SentenceNormalizationOutput = Schema.Struct({\n sentences: Schema.Array(MessageWithRangeId.pipe(Schema.mutable)).pipe(Schema.mutable).annotations({\n description: 'The sentences of the transcript.',\n }),\n});\n\nexport const SentenceNormalization = Operation.make({\n meta: {\n key: 'org.dxos.function.transcription.sentence-normalization',\n name: 'Sentence Normalization',\n description: 'Post process of transcription for sentence normalization',\n },\n input: SentenceNormalizationInput,\n output: SentenceNormalizationOutput,\n services: [],\n});\n"],
5
- "mappings": ";;;;;AAAA;;;;;;;;;;AAIA,YAAYA,YAAY;AAExB,SAASC,iBAAiB;AAC1B,SAASC,mBAAmB;AAC5B,SAASC,UAAUC,MAAMC,WAAW;AACpC,SAASC,iBAAiB;AAC1B,SAASC,SAASC,kBAAkB;AAEpC,SAASC,YAAY;AAErB,IAAMC,uBAAuB,GAAGC,KAAKC,EAAE;AAEhC,IAAMC,SAASC,UAAUC,KAAK;EACnCJ,MAAM;IAAEK,KAAK,GAAGN,oBAAAA;IAA+BO,MAAM;EAAoB;EACzEC,OAAcC,cAAO;IACnBF,MAAaG,gBAAgBC,aAAM;IACnCC,OAAOC;EACT,CAAA;EACAC,QAAeL,cAAO;IACpBM,QAAQC,WAAWA;EACrB,CAAA;AACF,CAAA;AAEO,IAAMC,qBAA4BC,cACvCC,QAAQA,SACDV,cAAO;EACZW,SAAgBV,gBAAgBW,aAAaV,aAAM,CAAA,EAAGW,YAAY;IAChEC,aAAa;EACf,CAAA;AACF,CAAA,CAAA;AAKK,IAAMC,OAAOpB,UAAUC,KAAK;EACjCJ,MAAM;IACJK,KAAK;IACLC,MAAM;IACNgB,aAAa;EACf;EACAf,OAAcC,cAAO;IACnBgB,YAAYC,IAAIA,IAAIV,WAAWA,UAAU,EAAEM,YAAY;MACrDC,aAAa;IACf,CAAA;EACF,CAAA;EACAT,QAAeL,cAAO;IACpBkB,SAAgBhB;EAClB,CAAA;EACAiB,UAAU;IAACC,SAASC;IAASC,KAAKC;;AACpC,CAAA;AAEO,IAAMC,YAAY7B,UAAUC,KAAK;EACtCJ,MAAM;IACJK,KAAK;IACLC,MAAM;IACNgB,aAAa;EACf;EACAf,OAAcC,cAAO;IACnBgB,YAAmBd,cAAOW,YAAY;MACpCC,aAAa;IACf,CAAA;IACAW,OAAcxB,gBAAgBC,aAAM,EAAEW,YAAY;MAChDC,aAAa;IACf,CAAA;EACF,CAAA;EACAT,QAAeL,cAAO;IACpB0B,SAAgBxB,cAAOW,YAAY;MACjCC,aAAa;IACf,CAAA;EACF,CAAA;EACAK,UAAU;IAACQ,UAAUA;;AACvB,CAAA;AAEO,IAAMC,6BAAoC5B,cAAO;EACtD6B,UAAiBjB,aAAMJ,kBAAAA,EAAoBK,YAAY;IACrDC,aAAa;EACf,CAAA;AACF,CAAA;AAIO,IAAMgB,8BAAqC9B,cAAO;EACvD+B,WAAkBnB,aAAMJ,mBAAmBwB,KAAYC,cAAO,CAAA,EAAGD,KAAYC,cAAO,EAAEpB,YAAY;IAChGC,aAAa;EACf,CAAA;AACF,CAAA;AAEO,IAAMoB,wBAAwBvC,UAAUC,KAAK;EAClDJ,MAAM;IACJK,KAAK;IACLC,MAAM;IACNgB,aAAa;EACf;EACAf,OAAO6B;EACPvB,QAAQyB;EACRX,UAAU,CAAA;AACZ,CAAA;",
6
- "names": ["Schema", "AiService", "SpaceSchema", "Database", "Feed", "Ref", "Operation", "Message", "Transcript", "meta", "TRANSCRIPT_OPERATION", "meta", "id", "Create", "Operation", "make", "key", "name", "input", "Struct", "optional", "String", "space", "SpaceSchema", "output", "object", "Transcript", "MessageWithRangeId", "extend", "Message", "rangeId", "Array", "annotations", "description", "Open", "transcript", "Ref", "content", "services", "Database", "Service", "Feed", "FeedService", "Summarize", "notes", "summary", "AiService", "SentenceNormalizationInput", "messages", "SentenceNormalizationOutput", "sentences", "pipe", "mutable", "SentenceNormalization"]
7
- }
@@ -1,7 +0,0 @@
1
- {
2
- "version": 3,
3
- "sources": ["../../../src/operations/create.ts"],
4
- "sourcesContent": ["//\n// Copyright 2025 DXOS.org\n//\n\nimport * as Effect from 'effect/Effect';\n\nimport { Feed, Ref } from '@dxos/echo';\nimport { Operation } from '@dxos/operation';\nimport { Transcript } from '@dxos/types';\n\nimport { Create } from './definitions';\n\nconst handler: Operation.WithHandler<typeof Create> = Create.pipe(\n Operation.withHandler(\n Effect.fn(function* ({ space }) {\n const feed = space.db.add(Feed.make());\n return {\n object: Transcript.make(Ref.make(feed)),\n };\n }),\n ),\n);\n\nexport default handler;\n"],
5
- "mappings": ";;;;;;AAIA,YAAYA,YAAY;AAExB,SAASC,MAAMC,WAAW;AAC1B,SAASC,iBAAiB;AAC1B,SAASC,kBAAkB;AAI3B,IAAMC,UAAgDC,OAAOC,KAC3DC,UAAUC,YACDC,UAAG,WAAW,EAAEC,MAAK,GAAE;AAC5B,QAAMC,OAAOD,MAAME,GAAGC,IAAIC,KAAKC,KAAI,CAAA;AACnC,SAAO;IACLC,QAAQC,WAAWF,KAAKG,IAAIH,KAAKJ,IAAAA,CAAAA;EACnC;AACF,CAAA,CAAA,CAAA;AAIJ,IAAA,iBAAeP;",
6
- "names": ["Effect", "Feed", "Ref", "Operation", "Transcript", "handler", "Create", "pipe", "Operation", "withHandler", "fn", "space", "feed", "db", "add", "Feed", "make", "object", "Transcript", "Ref"]
7
- }