@dxos/plugin-transcription 0.8.2-main.12df754 → 0.8.2-main.2f9c567

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 (193) hide show
  1. package/dist/lib/browser/{TranscriptContainer-4D4BHE7G.mjs → TranscriptContainer-3LU3XBEB.mjs} +3 -3
  2. package/dist/lib/browser/app-graph-builder-YXELPN6F.mjs +349 -0
  3. package/dist/lib/browser/app-graph-builder-YXELPN6F.mjs.map +7 -0
  4. package/dist/lib/browser/{chunk-DR3NBV6Q.mjs → chunk-GWY2Q2NE.mjs} +105 -78
  5. package/dist/lib/browser/chunk-GWY2Q2NE.mjs.map +7 -0
  6. package/dist/lib/browser/{chunk-RHHJZQPM.mjs → chunk-HNIKXVCG.mjs} +135 -117
  7. package/dist/lib/browser/chunk-HNIKXVCG.mjs.map +7 -0
  8. package/dist/lib/browser/chunk-HRDAILQX.mjs +27 -0
  9. package/dist/lib/browser/chunk-HRDAILQX.mjs.map +7 -0
  10. package/dist/lib/browser/{chunk-5BE6RTNC.mjs → chunk-LTIQFX4W.mjs} +1 -1
  11. package/dist/lib/browser/{chunk-5BE6RTNC.mjs.map → chunk-LTIQFX4W.mjs.map} +1 -1
  12. package/dist/lib/browser/{chunk-5Q3R53U3.mjs → chunk-TGOKX32G.mjs} +21 -31
  13. package/dist/lib/browser/chunk-TGOKX32G.mjs.map +7 -0
  14. package/dist/lib/browser/index.mjs +29 -17
  15. package/dist/lib/browser/index.mjs.map +3 -3
  16. package/dist/lib/browser/{intent-resolver-ZQQEH27F.mjs → intent-resolver-BBB3DWV4.mjs} +4 -4
  17. package/dist/lib/browser/{intent-resolver-ZQQEH27F.mjs.map → intent-resolver-BBB3DWV4.mjs.map} +2 -2
  18. package/dist/lib/browser/{meeting-transcription-state-5D52VTHU.mjs → meeting-transcription-state-MNA2XROE.mjs} +2 -2
  19. package/dist/lib/browser/meta.json +1 -1
  20. package/dist/lib/browser/{react-surface-HETJ5XY6.mjs → react-surface-R277DACJ.mjs} +18 -7
  21. package/dist/lib/browser/react-surface-R277DACJ.mjs.map +7 -0
  22. package/dist/lib/browser/settings-I226DZ27.mjs +24 -0
  23. package/dist/lib/browser/settings-I226DZ27.mjs.map +7 -0
  24. package/dist/lib/browser/{transcriber-SMRLU2KY.mjs → transcriber-QRSS6X6S.mjs} +4 -4
  25. package/dist/lib/browser/types/index.mjs +3 -3
  26. package/dist/lib/node/{TranscriptContainer-ZWP6UKY6.cjs → TranscriptContainer-DICOMZLM.cjs} +8 -8
  27. package/dist/lib/node/{TranscriptContainer-ZWP6UKY6.cjs.map → TranscriptContainer-DICOMZLM.cjs.map} +2 -2
  28. package/dist/lib/node/app-graph-builder-I6LYVIYY.cjs +350 -0
  29. package/dist/lib/node/app-graph-builder-I6LYVIYY.cjs.map +7 -0
  30. package/dist/lib/node/{chunk-3QEJ5EBO.cjs → chunk-34WFY7M7.cjs} +22 -32
  31. package/dist/lib/node/chunk-34WFY7M7.cjs.map +7 -0
  32. package/dist/lib/node/{chunk-KO6MKCED.cjs → chunk-4JOJCZPJ.cjs} +138 -119
  33. package/dist/lib/node/chunk-4JOJCZPJ.cjs.map +7 -0
  34. package/dist/lib/node/{chunk-HYGDHS6X.cjs → chunk-JUGOXWES.cjs} +4 -4
  35. package/dist/lib/node/{chunk-HYGDHS6X.cjs.map → chunk-JUGOXWES.cjs.map} +1 -1
  36. package/dist/lib/node/{chunk-WXG4Z2EZ.cjs → chunk-K553L7CZ.cjs} +23 -8
  37. package/dist/lib/node/chunk-K553L7CZ.cjs.map +7 -0
  38. package/dist/lib/node/{chunk-LA73IHCB.cjs → chunk-RK4BEN5E.cjs} +108 -80
  39. package/dist/lib/node/chunk-RK4BEN5E.cjs.map +7 -0
  40. package/dist/lib/node/index.cjs +46 -34
  41. package/dist/lib/node/index.cjs.map +3 -3
  42. package/dist/lib/node/{intent-resolver-VY3XWYAA.cjs → intent-resolver-7XY3WITN.cjs} +8 -8
  43. package/dist/lib/node/{intent-resolver-VY3XWYAA.cjs.map → intent-resolver-7XY3WITN.cjs.map} +2 -2
  44. package/dist/lib/node/{meeting-transcription-state-OYWCY5XE.cjs → meeting-transcription-state-5XLTMWPA.cjs} +6 -6
  45. package/dist/lib/node/meta.json +1 -1
  46. package/dist/lib/node/{react-surface-M2JQIIDY.cjs → react-surface-HUSWAORU.cjs} +20 -11
  47. package/dist/lib/node/react-surface-HUSWAORU.cjs.map +7 -0
  48. package/dist/lib/node/settings-NDMU3EWQ.cjs +38 -0
  49. package/dist/lib/node/settings-NDMU3EWQ.cjs.map +7 -0
  50. package/dist/lib/node/{transcriber-E6AAB4SU.cjs → transcriber-UZJMG44C.cjs} +10 -10
  51. package/dist/lib/node/types/index.cjs +8 -8
  52. package/dist/lib/node/types/index.cjs.map +1 -1
  53. package/dist/lib/node-esm/{TranscriptContainer-3HJ752CP.mjs → TranscriptContainer-K4E4P5T6.mjs} +3 -3
  54. package/dist/lib/node-esm/app-graph-builder-6FY2UQOH.mjs +350 -0
  55. package/dist/lib/node-esm/app-graph-builder-6FY2UQOH.mjs.map +7 -0
  56. package/dist/lib/node-esm/chunk-3I7AC3D3.mjs +28 -0
  57. package/dist/lib/node-esm/chunk-3I7AC3D3.mjs.map +7 -0
  58. package/dist/lib/node-esm/{chunk-YXZOLOFT.mjs → chunk-5E2MR5XK.mjs} +1 -1
  59. package/dist/lib/node-esm/{chunk-YXZOLOFT.mjs.map → chunk-5E2MR5XK.mjs.map} +1 -1
  60. package/dist/lib/node-esm/{chunk-SDMGJZLN.mjs → chunk-6C34FO4C.mjs} +135 -117
  61. package/dist/lib/node-esm/chunk-6C34FO4C.mjs.map +7 -0
  62. package/dist/lib/node-esm/{chunk-K3R3YK3S.mjs → chunk-CKANLRS4.mjs} +105 -78
  63. package/dist/lib/node-esm/chunk-CKANLRS4.mjs.map +7 -0
  64. package/dist/lib/node-esm/{chunk-54HDN33F.mjs → chunk-KUQ3ZTRX.mjs} +21 -31
  65. package/dist/lib/node-esm/chunk-KUQ3ZTRX.mjs.map +7 -0
  66. package/dist/lib/node-esm/index.mjs +29 -17
  67. package/dist/lib/node-esm/index.mjs.map +3 -3
  68. package/dist/lib/node-esm/{intent-resolver-FCTNJPWY.mjs → intent-resolver-ACGAPLDZ.mjs} +4 -4
  69. package/dist/lib/node-esm/{intent-resolver-FCTNJPWY.mjs.map → intent-resolver-ACGAPLDZ.mjs.map} +2 -2
  70. package/dist/lib/node-esm/{meeting-transcription-state-XMZJ45P4.mjs → meeting-transcription-state-3WOZ52BQ.mjs} +2 -2
  71. package/dist/lib/node-esm/meta.json +1 -1
  72. package/dist/lib/node-esm/{react-surface-PXFSIM6V.mjs → react-surface-G2OY4MWL.mjs} +18 -7
  73. package/dist/lib/node-esm/react-surface-G2OY4MWL.mjs.map +7 -0
  74. package/dist/lib/node-esm/settings-O7X2UQQG.mjs +25 -0
  75. package/dist/lib/node-esm/settings-O7X2UQQG.mjs.map +7 -0
  76. package/dist/lib/node-esm/{transcriber-REAGRCPY.mjs → transcriber-NVVFH7IF.mjs} +4 -4
  77. package/dist/lib/node-esm/types/index.mjs +3 -3
  78. package/dist/types/src/TranscriptionPlugin.d.ts.map +1 -1
  79. package/dist/types/src/capabilities/app-graph-builder.d.ts.map +1 -1
  80. package/dist/types/src/capabilities/capabilities.d.ts +1 -1
  81. package/dist/types/src/capabilities/capabilities.d.ts.map +1 -1
  82. package/dist/types/src/capabilities/index.d.ts +1 -0
  83. package/dist/types/src/capabilities/index.d.ts.map +1 -1
  84. package/dist/types/src/capabilities/react-surface.d.ts.map +1 -1
  85. package/dist/types/src/capabilities/settings.d.ts +4 -0
  86. package/dist/types/src/capabilities/settings.d.ts.map +1 -0
  87. package/dist/types/src/components/Transcript/Transcript.d.ts +6 -4
  88. package/dist/types/src/components/Transcript/Transcript.d.ts.map +1 -1
  89. package/dist/types/src/components/Transcript/Transcript.stories.d.ts +8 -4
  90. package/dist/types/src/components/Transcript/Transcript.stories.d.ts.map +1 -1
  91. package/dist/types/src/components/Transcript/deprecated/OldTranscript.d.ts +27 -0
  92. package/dist/types/src/components/Transcript/deprecated/OldTranscript.d.ts.map +1 -0
  93. package/dist/types/src/components/Transcript/transcript-extension.d.ts +4 -4
  94. package/dist/types/src/components/Transcript/transcript-extension.d.ts.map +1 -1
  95. package/dist/types/src/components/TranscriptContainer.d.ts.map +1 -1
  96. package/dist/types/src/components/TranscriptionSettings/TranscriptionSettings.d.ts +6 -0
  97. package/dist/types/src/components/TranscriptionSettings/TranscriptionSettings.d.ts.map +1 -0
  98. package/dist/types/src/components/TranscriptionSettings/index.d.ts +2 -0
  99. package/dist/types/src/components/TranscriptionSettings/index.d.ts.map +1 -0
  100. package/dist/types/src/components/index.d.ts +1 -0
  101. package/dist/types/src/components/index.d.ts.map +1 -1
  102. package/dist/types/src/components/transcription.stories.d.ts +6 -3
  103. package/dist/types/src/components/transcription.stories.d.ts.map +1 -1
  104. package/dist/types/src/entity-extraction/entity-extraction.d.ts +33 -7
  105. package/dist/types/src/entity-extraction/entity-extraction.d.ts.map +1 -1
  106. package/dist/types/src/hooks/useQueueModelAdapter.d.ts +2 -2
  107. package/dist/types/src/hooks/useQueueModelAdapter.d.ts.map +1 -1
  108. package/dist/types/src/model/model.d.ts +23 -23
  109. package/dist/types/src/model/model.d.ts.map +1 -1
  110. package/dist/types/src/testing/index.d.ts +2 -0
  111. package/dist/types/src/testing/index.d.ts.map +1 -0
  112. package/dist/types/src/testing/testing.d.ts +40 -0
  113. package/dist/types/src/testing/testing.d.ts.map +1 -0
  114. package/dist/types/src/transcriber/transcriber.d.ts +2 -2
  115. package/dist/types/src/transcriber/transcriber.d.ts.map +1 -1
  116. package/dist/types/src/transcriber/transcription-manager.d.ts +17 -15
  117. package/dist/types/src/transcriber/transcription-manager.d.ts.map +1 -1
  118. package/dist/types/src/translations.d.ts +3 -0
  119. package/dist/types/src/translations.d.ts.map +1 -1
  120. package/dist/types/src/types/schema.d.ts +26 -40
  121. package/dist/types/src/types/schema.d.ts.map +1 -1
  122. package/dist/types/src/types/types.d.ts +11 -7
  123. package/dist/types/src/types/types.d.ts.map +1 -1
  124. package/package.json +51 -46
  125. package/src/TranscriptionPlugin.tsx +29 -12
  126. package/src/capabilities/app-graph-builder.ts +99 -29
  127. package/src/capabilities/capabilities.ts +1 -1
  128. package/src/capabilities/index.ts +1 -0
  129. package/src/capabilities/intent-resolver.ts +2 -2
  130. package/src/capabilities/react-surface.tsx +12 -4
  131. package/src/capabilities/settings.ts +20 -0
  132. package/src/components/Transcript/Transcript.stories.tsx +71 -35
  133. package/src/components/Transcript/Transcript.tsx +37 -30
  134. package/src/components/Transcript/deprecated/{Transcript.tsx → OldTranscript.tsx} +30 -1
  135. package/src/components/Transcript/transcript-extension.ts +20 -17
  136. package/src/components/TranscriptContainer.tsx +6 -4
  137. package/src/components/TranscriptionSettings/TranscriptionSettings.tsx +26 -0
  138. package/src/components/TranscriptionSettings/index.ts +5 -0
  139. package/src/components/index.ts +1 -0
  140. package/src/components/transcription.stories.tsx +83 -29
  141. package/src/entity-extraction/entity-extraction.test.ts +75 -10
  142. package/src/entity-extraction/entity-extraction.ts +110 -55
  143. package/src/entity-extraction/system-prompt.tpl +38 -9
  144. package/src/hooks/useQueueModelAdapter.ts +44 -11
  145. package/src/model/model.test.ts +90 -44
  146. package/src/model/model.ts +59 -59
  147. package/src/testing/index.ts +5 -0
  148. package/src/testing/testing.ts +221 -0
  149. package/src/transcriber/transcriber.browser.test.ts +3 -3
  150. package/src/transcriber/transcriber.ts +19 -10
  151. package/src/transcriber/transcription-manager.ts +66 -57
  152. package/src/translations.ts +2 -0
  153. package/src/types/schema.ts +10 -31
  154. package/src/types/types.ts +17 -7
  155. package/dist/lib/browser/app-graph-builder-I4SSIQMW.mjs +0 -168
  156. package/dist/lib/browser/app-graph-builder-I4SSIQMW.mjs.map +0 -7
  157. package/dist/lib/browser/chunk-5Q3R53U3.mjs.map +0 -7
  158. package/dist/lib/browser/chunk-DR3NBV6Q.mjs.map +0 -7
  159. package/dist/lib/browser/chunk-GI5LZ4SV.mjs +0 -8
  160. package/dist/lib/browser/chunk-GI5LZ4SV.mjs.map +0 -7
  161. package/dist/lib/browser/chunk-RHHJZQPM.mjs.map +0 -7
  162. package/dist/lib/browser/react-surface-HETJ5XY6.mjs.map +0 -7
  163. package/dist/lib/node/app-graph-builder-WWC4WNTG.cjs +0 -177
  164. package/dist/lib/node/app-graph-builder-WWC4WNTG.cjs.map +0 -7
  165. package/dist/lib/node/chunk-3QEJ5EBO.cjs.map +0 -7
  166. package/dist/lib/node/chunk-KO6MKCED.cjs.map +0 -7
  167. package/dist/lib/node/chunk-LA73IHCB.cjs.map +0 -7
  168. package/dist/lib/node/chunk-WXG4Z2EZ.cjs.map +0 -7
  169. package/dist/lib/node/react-surface-M2JQIIDY.cjs.map +0 -7
  170. package/dist/lib/node-esm/app-graph-builder-PPJQAFSI.mjs +0 -169
  171. package/dist/lib/node-esm/app-graph-builder-PPJQAFSI.mjs.map +0 -7
  172. package/dist/lib/node-esm/chunk-54HDN33F.mjs.map +0 -7
  173. package/dist/lib/node-esm/chunk-K3R3YK3S.mjs.map +0 -7
  174. package/dist/lib/node-esm/chunk-SDMGJZLN.mjs.map +0 -7
  175. package/dist/lib/node-esm/chunk-XY22OP6H.mjs +0 -10
  176. package/dist/lib/node-esm/chunk-XY22OP6H.mjs.map +0 -7
  177. package/dist/lib/node-esm/react-surface-PXFSIM6V.mjs.map +0 -7
  178. package/dist/types/src/components/Transcript/deprecated/Transcript.d.ts +0 -13
  179. package/dist/types/src/components/Transcript/deprecated/Transcript.d.ts.map +0 -1
  180. package/dist/types/src/components/Transcript/testings.d.ts +0 -51
  181. package/dist/types/src/components/Transcript/testings.d.ts.map +0 -1
  182. package/dist/types/src/testing/test-data.d.ts +0 -73
  183. package/dist/types/src/testing/test-data.d.ts.map +0 -1
  184. package/src/components/Transcript/testings.ts +0 -182
  185. package/src/testing/test-data.ts +0 -314
  186. /package/dist/lib/browser/{TranscriptContainer-4D4BHE7G.mjs.map → TranscriptContainer-3LU3XBEB.mjs.map} +0 -0
  187. /package/dist/lib/browser/{meeting-transcription-state-5D52VTHU.mjs.map → meeting-transcription-state-MNA2XROE.mjs.map} +0 -0
  188. /package/dist/lib/browser/{transcriber-SMRLU2KY.mjs.map → transcriber-QRSS6X6S.mjs.map} +0 -0
  189. /package/dist/lib/node/{meeting-transcription-state-OYWCY5XE.cjs.map → meeting-transcription-state-5XLTMWPA.cjs.map} +0 -0
  190. /package/dist/lib/node/{transcriber-E6AAB4SU.cjs.map → transcriber-UZJMG44C.cjs.map} +0 -0
  191. /package/dist/lib/node-esm/{TranscriptContainer-3HJ752CP.mjs.map → TranscriptContainer-K4E4P5T6.mjs.map} +0 -0
  192. /package/dist/lib/node-esm/{meeting-transcription-state-XMZJ45P4.mjs.map → meeting-transcription-state-3WOZ52BQ.mjs.map} +0 -0
  193. /package/dist/lib/node-esm/{transcriber-REAGRCPY.mjs.map → transcriber-NVVFH7IF.mjs.map} +0 -0
@@ -26,30 +26,39 @@ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__ge
26
26
  mod
27
27
  ));
28
28
  var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
29
- var react_surface_M2JQIIDY_exports = {};
30
- __export(react_surface_M2JQIIDY_exports, {
29
+ var react_surface_HUSWAORU_exports = {};
30
+ __export(react_surface_HUSWAORU_exports, {
31
31
  default: () => react_surface_default
32
32
  });
33
- module.exports = __toCommonJS(react_surface_M2JQIIDY_exports);
34
- var import_chunk_WXG4Z2EZ = require("./chunk-WXG4Z2EZ.cjs");
35
- var import_chunk_KO6MKCED = require("./chunk-KO6MKCED.cjs");
36
- var import_chunk_3QEJ5EBO = require("./chunk-3QEJ5EBO.cjs");
37
- var import_chunk_HYGDHS6X = require("./chunk-HYGDHS6X.cjs");
33
+ module.exports = __toCommonJS(react_surface_HUSWAORU_exports);
34
+ var import_chunk_K553L7CZ = require("./chunk-K553L7CZ.cjs");
35
+ var import_chunk_4JOJCZPJ = require("./chunk-4JOJCZPJ.cjs");
36
+ var import_chunk_34WFY7M7 = require("./chunk-34WFY7M7.cjs");
37
+ var import_chunk_JUGOXWES = require("./chunk-JUGOXWES.cjs");
38
38
  var import_chunk_NVZWGFJL = require("./chunk-NVZWGFJL.cjs");
39
39
  var import_react = __toESM(require("react"));
40
40
  var import_app_framework = require("@dxos/app-framework");
41
+ var import_local_storage = require("@dxos/local-storage");
41
42
  var react_surface_default = () => (0, import_app_framework.contributes)(import_app_framework.Capabilities.ReactSurface, [
42
43
  (0, import_app_framework.createSurface)({
43
- id: `${import_chunk_NVZWGFJL.TRANSCRIPTION_PLUGIN}/article/transcript`,
44
+ id: `${import_chunk_NVZWGFJL.meta.id}/plugin-settings`,
45
+ role: "article",
46
+ filter: (data) => data.subject instanceof import_local_storage.SettingsStore && data.subject.prefix === import_chunk_NVZWGFJL.meta.id,
47
+ component: ({ data: { subject } }) => /* @__PURE__ */ import_react.default.createElement(import_chunk_K553L7CZ.TranscriptionSettings, {
48
+ settings: subject.value
49
+ })
50
+ }),
51
+ (0, import_app_framework.createSurface)({
52
+ id: `${import_chunk_NVZWGFJL.meta.id}/article/transcript`,
44
53
  role: [
45
54
  "article",
46
55
  "section"
47
56
  ],
48
- filter: (data) => (0, import_chunk_3QEJ5EBO.isTranscript)(data.subject),
49
- component: ({ data, role }) => /* @__PURE__ */ import_react.default.createElement(import_chunk_KO6MKCED.TranscriptionContainer, {
57
+ filter: (data) => (0, import_chunk_34WFY7M7.isTranscript)(data.subject),
58
+ component: ({ data, role }) => /* @__PURE__ */ import_react.default.createElement(import_chunk_4JOJCZPJ.TranscriptionContainer, {
50
59
  transcript: data.subject,
51
60
  role
52
61
  })
53
62
  })
54
63
  ]);
55
- //# sourceMappingURL=react-surface-M2JQIIDY.cjs.map
64
+ //# sourceMappingURL=react-surface-HUSWAORU.cjs.map
@@ -0,0 +1,7 @@
1
+ {
2
+ "version": 3,
3
+ "sources": ["../../../src/capabilities/react-surface.tsx"],
4
+ "sourcesContent": ["//\n// Copyright 2025 DXOS.org\n//\n\nimport React from 'react';\n\nimport { Capabilities, contributes, createSurface } from '@dxos/app-framework';\nimport { SettingsStore } from '@dxos/local-storage';\n\nimport { TranscriptionContainer, TranscriptionSettings } from '../components';\nimport { meta } from '../meta';\nimport { isTranscript, type TranscriptionSettingsProps, type TranscriptType } from '../types';\n\nexport default () =>\n contributes(Capabilities.ReactSurface, [\n createSurface({\n id: `${meta.id}/plugin-settings`,\n role: 'article',\n filter: (data): data is { subject: SettingsStore<TranscriptionSettingsProps> } =>\n data.subject instanceof SettingsStore && data.subject.prefix === meta.id,\n component: ({ data: { subject } }) => <TranscriptionSettings settings={subject.value} />,\n }),\n createSurface({\n id: `${meta.id}/article/transcript`,\n role: ['article', 'section'],\n filter: (data): data is { subject: TranscriptType } => isTranscript(data.subject),\n component: ({ data, role }) => <TranscriptionContainer transcript={data.subject} role={role} />,\n }),\n ]);\n"],
5
+ "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAIA,mBAAkB;AAElB,2BAAyD;AACzD,2BAA8B;AAM9B,IAAA,wBAAe,UACbA,kCAAYC,kCAAaC,cAAc;MACrCC,oCAAc;IACZC,IAAI,GAAGC,2BAAKD,EAAE;IACdE,MAAM;IACNC,QAAQ,CAACC,SACPA,KAAKC,mBAAmBC,sCAAiBF,KAAKC,QAAQE,WAAWN,2BAAKD;IACxEQ,WAAW,CAAC,EAAEJ,MAAM,EAAEC,QAAO,EAAE,MAAO,6BAAAI,QAAA,cAACC,6CAAAA;MAAsBC,UAAUN,QAAQO;;EACjF,CAAA;MACAb,oCAAc;IACZC,IAAI,GAAGC,2BAAKD,EAAE;IACdE,MAAM;MAAC;MAAW;;IAClBC,QAAQ,CAACC,aAA8CS,oCAAaT,KAAKC,OAAO;IAChFG,WAAW,CAAC,EAAEJ,MAAMF,KAAI,MAAO,6BAAAO,QAAA,cAACK,8CAAAA;MAAuBC,YAAYX,KAAKC;MAASH;;EACnF,CAAA;CACD;",
6
+ "names": ["contributes", "Capabilities", "ReactSurface", "createSurface", "id", "meta", "role", "filter", "data", "subject", "SettingsStore", "prefix", "component", "React", "TranscriptionSettings", "settings", "value", "isTranscript", "TranscriptionContainer", "transcript"]
7
+ }
@@ -0,0 +1,38 @@
1
+ "use strict";
2
+ var __defProp = Object.defineProperty;
3
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
4
+ var __getOwnPropNames = Object.getOwnPropertyNames;
5
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
6
+ var __export = (target, all) => {
7
+ for (var name in all)
8
+ __defProp(target, name, { get: all[name], enumerable: true });
9
+ };
10
+ var __copyProps = (to, from, except, desc) => {
11
+ if (from && typeof from === "object" || typeof from === "function") {
12
+ for (let key of __getOwnPropNames(from))
13
+ if (!__hasOwnProp.call(to, key) && key !== except)
14
+ __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
15
+ }
16
+ return to;
17
+ };
18
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
19
+ var settings_NDMU3EWQ_exports = {};
20
+ __export(settings_NDMU3EWQ_exports, {
21
+ default: () => settings_default
22
+ });
23
+ module.exports = __toCommonJS(settings_NDMU3EWQ_exports);
24
+ var import_chunk_34WFY7M7 = require("./chunk-34WFY7M7.cjs");
25
+ var import_chunk_NVZWGFJL = require("./chunk-NVZWGFJL.cjs");
26
+ var import_app_framework = require("@dxos/app-framework");
27
+ var import_live_object = require("@dxos/live-object");
28
+ var settings_default = () => {
29
+ const settings = (0, import_live_object.live)(import_chunk_34WFY7M7.TranscriptionSettingsSchema, {
30
+ entityExtraction: true
31
+ });
32
+ return (0, import_app_framework.contributes)(import_app_framework.Capabilities.Settings, {
33
+ schema: import_chunk_34WFY7M7.TranscriptionSettingsSchema,
34
+ prefix: import_chunk_NVZWGFJL.TRANSCRIPTION_PLUGIN,
35
+ value: settings
36
+ });
37
+ };
38
+ //# sourceMappingURL=settings-NDMU3EWQ.cjs.map
@@ -0,0 +1,7 @@
1
+ {
2
+ "version": 3,
3
+ "sources": ["../../../src/capabilities/settings.ts"],
4
+ "sourcesContent": ["//\n// Copyright 2025 DXOS.org\n//\n\nimport { Capabilities, contributes } from '@dxos/app-framework';\nimport { live } from '@dxos/live-object';\n\nimport { TRANSCRIPTION_PLUGIN } from '../meta';\nimport { TranscriptionSettingsSchema } from '../types';\n\nexport default () => {\n // TODO(wittjosiah): `live` currently doesn't handle schema default values.\n const settings = live(TranscriptionSettingsSchema, { entityExtraction: true });\n\n return contributes(Capabilities.Settings, {\n schema: TranscriptionSettingsSchema,\n prefix: TRANSCRIPTION_PLUGIN,\n value: settings,\n });\n};\n"],
5
+ "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;AAIA,2BAA0C;AAC1C,yBAAqB;AAKrB,IAAA,mBAAe,MAAA;AAEb,QAAMA,eAAWC,yBAAKC,mDAA6B;IAAEC,kBAAkB;EAAK,CAAA;AAE5E,aAAOC,kCAAYC,kCAAaC,UAAU;IACxCC,QAAQL;IACRM,QAAQC;IACRC,OAAOV;EACT,CAAA;AACF;",
6
+ "names": ["settings", "live", "TranscriptionSettingsSchema", "entityExtraction", "contributes", "Capabilities", "Settings", "schema", "prefix", "TRANSCRIPTION_PLUGIN", "value"]
7
+ }
@@ -16,15 +16,15 @@ var __copyProps = (to, from, except, desc) => {
16
16
  return to;
17
17
  };
18
18
  var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
19
- var transcriber_E6AAB4SU_exports = {};
20
- __export(transcriber_E6AAB4SU_exports, {
19
+ var transcriber_UZJMG44C_exports = {};
20
+ __export(transcriber_UZJMG44C_exports, {
21
21
  default: () => transcriber_default
22
22
  });
23
- module.exports = __toCommonJS(transcriber_E6AAB4SU_exports);
24
- var import_chunk_LA73IHCB = require("./chunk-LA73IHCB.cjs");
23
+ module.exports = __toCommonJS(transcriber_UZJMG44C_exports);
24
+ var import_chunk_RK4BEN5E = require("./chunk-RK4BEN5E.cjs");
25
25
  var import_chunk_J72PUQ3C = require("./chunk-J72PUQ3C.cjs");
26
- var import_chunk_3QEJ5EBO = require("./chunk-3QEJ5EBO.cjs");
27
- var import_chunk_HYGDHS6X = require("./chunk-HYGDHS6X.cjs");
26
+ var import_chunk_34WFY7M7 = require("./chunk-34WFY7M7.cjs");
27
+ var import_chunk_JUGOXWES = require("./chunk-JUGOXWES.cjs");
28
28
  var import_chunk_NVZWGFJL = require("./chunk-NVZWGFJL.cjs");
29
29
  var import_app_framework = require("@dxos/app-framework");
30
30
  var RECORD_INTERVAL = 200;
@@ -32,19 +32,19 @@ var PREFIXED_CHUNKS_AMOUNT = 10;
32
32
  var TRANSCRIBE_AFTER_CHUNKS_AMOUNT = 50;
33
33
  var transcriber_default = () => {
34
34
  const getTranscriber = ({ audioStreamTrack, onSegments, config }) => {
35
- return new import_chunk_LA73IHCB.Transcriber({
35
+ return new import_chunk_RK4BEN5E.Transcriber({
36
36
  config: {
37
37
  transcribeAfterChunksAmount: TRANSCRIBE_AFTER_CHUNKS_AMOUNT,
38
38
  prefixBufferChunksAmount: PREFIXED_CHUNKS_AMOUNT,
39
39
  ...config
40
40
  },
41
- recorder: new import_chunk_LA73IHCB.MediaStreamRecorder({
41
+ recorder: new import_chunk_RK4BEN5E.MediaStreamRecorder({
42
42
  mediaStreamTrack: audioStreamTrack,
43
43
  interval: RECORD_INTERVAL
44
44
  }),
45
45
  onSegments
46
46
  });
47
47
  };
48
- return (0, import_app_framework.contributes)(import_chunk_HYGDHS6X.TranscriptionCapabilities.Transcriber, getTranscriber);
48
+ return (0, import_app_framework.contributes)(import_chunk_JUGOXWES.TranscriptionCapabilities.Transcriber, getTranscriber);
49
49
  };
50
- //# sourceMappingURL=transcriber-E6AAB4SU.cjs.map
50
+ //# sourceMappingURL=transcriber-UZJMG44C.cjs.map
@@ -18,23 +18,23 @@ var __copyProps = (to, from, except, desc) => {
18
18
  var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
19
19
  var types_exports = {};
20
20
  __export(types_exports, {
21
- TRANSCRIPTION_URL: () => import_chunk_3QEJ5EBO.TRANSCRIPTION_URL,
22
- TranscriptBlock: () => import_chunk_3QEJ5EBO.TranscriptBlock,
23
- TranscriptSchema: () => import_chunk_3QEJ5EBO.TranscriptSchema,
24
- TranscriptType: () => import_chunk_3QEJ5EBO.TranscriptType,
25
- TranscriptionAction: () => import_chunk_3QEJ5EBO.TranscriptionAction,
26
- isTranscript: () => import_chunk_3QEJ5EBO.isTranscript
21
+ TRANSCRIPTION_URL: () => import_chunk_34WFY7M7.TRANSCRIPTION_URL,
22
+ TranscriptSchema: () => import_chunk_34WFY7M7.TranscriptSchema,
23
+ TranscriptType: () => import_chunk_34WFY7M7.TranscriptType,
24
+ TranscriptionAction: () => import_chunk_34WFY7M7.TranscriptionAction,
25
+ TranscriptionSettingsSchema: () => import_chunk_34WFY7M7.TranscriptionSettingsSchema,
26
+ isTranscript: () => import_chunk_34WFY7M7.isTranscript
27
27
  });
28
28
  module.exports = __toCommonJS(types_exports);
29
- var import_chunk_3QEJ5EBO = require("../chunk-3QEJ5EBO.cjs");
29
+ var import_chunk_34WFY7M7 = require("../chunk-34WFY7M7.cjs");
30
30
  var import_chunk_NVZWGFJL = require("../chunk-NVZWGFJL.cjs");
31
31
  // Annotate the CommonJS export names for ESM import in node:
32
32
  0 && (module.exports = {
33
33
  TRANSCRIPTION_URL,
34
- TranscriptBlock,
35
34
  TranscriptSchema,
36
35
  TranscriptType,
37
36
  TranscriptionAction,
37
+ TranscriptionSettingsSchema,
38
38
  isTranscript
39
39
  });
40
40
  //# sourceMappingURL=index.cjs.map
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
3
  "sources": ["index.cjs"],
4
- "sourcesContent": ["import {\n TRANSCRIPTION_URL,\n TranscriptBlock,\n TranscriptSchema,\n TranscriptType,\n TranscriptionAction,\n isTranscript\n} from \"../chunk-3QEJ5EBO.cjs\";\nimport \"../chunk-NVZWGFJL.cjs\";\nexport {\n TRANSCRIPTION_URL,\n TranscriptBlock,\n TranscriptSchema,\n TranscriptType,\n TranscriptionAction,\n isTranscript\n};\n//# sourceMappingURL=index.cjs.map\n"],
4
+ "sourcesContent": ["import {\n TRANSCRIPTION_URL,\n TranscriptSchema,\n TranscriptType,\n TranscriptionAction,\n TranscriptionSettingsSchema,\n isTranscript\n} from \"../chunk-34WFY7M7.cjs\";\nimport \"../chunk-NVZWGFJL.cjs\";\nexport {\n TRANSCRIPTION_URL,\n TranscriptSchema,\n TranscriptType,\n TranscriptionAction,\n TranscriptionSettingsSchema,\n isTranscript\n};\n//# sourceMappingURL=index.cjs.map\n"],
5
5
  "mappings": ";;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,4BAOO;AACP,4BAAO;",
6
6
  "names": []
7
7
  }
@@ -2,11 +2,11 @@ import { createRequire } from 'node:module';const require = createRequire(import
2
2
  import {
3
3
  TranscriptContainer_default,
4
4
  TranscriptionContainer
5
- } from "./chunk-SDMGJZLN.mjs";
6
- import "./chunk-YXZOLOFT.mjs";
5
+ } from "./chunk-6C34FO4C.mjs";
6
+ import "./chunk-5E2MR5XK.mjs";
7
7
  import "./chunk-X4DDJIVL.mjs";
8
8
  export {
9
9
  TranscriptionContainer,
10
10
  TranscriptContainer_default as default
11
11
  };
12
- //# sourceMappingURL=TranscriptContainer-3HJ752CP.mjs.map
12
+ //# sourceMappingURL=TranscriptContainer-K4E4P5T6.mjs.map
@@ -0,0 +1,350 @@
1
+ import { createRequire } from 'node:module';const require = createRequire(import.meta.url);
2
+ import {
3
+ TranscriptionManager
4
+ } from "./chunk-CKANLRS4.mjs";
5
+ import "./chunk-QMHMEKB3.mjs";
6
+ import {
7
+ TranscriptType,
8
+ TranscriptionAction
9
+ } from "./chunk-KUQ3ZTRX.mjs";
10
+ import {
11
+ TranscriptionCapabilities
12
+ } from "./chunk-5E2MR5XK.mjs";
13
+ import {
14
+ TRANSCRIPTION_PLUGIN
15
+ } from "./chunk-X4DDJIVL.mjs";
16
+
17
+ // packages/plugins/plugin-transcription/src/capabilities/app-graph-builder.ts
18
+ import { Capabilities, contributes, createIntent } from "@dxos/app-framework";
19
+ import { AIServiceEdgeClient } from "@dxos/assistant";
20
+ import { AI_SERVICE_ENDPOINT } from "@dxos/assistant/testing";
21
+ import { Filter, fullyQualifiedId, getSpace, makeRef } from "@dxos/client/echo";
22
+ import { getSchemaTypename, isInstanceOf } from "@dxos/echo-schema";
23
+ import { invariant } from "@dxos/invariant";
24
+ import { DXN as DXN2 } from "@dxos/keys";
25
+ import { log as log2 } from "@dxos/log";
26
+ import { ClientCapabilities } from "@dxos/plugin-client";
27
+ import { PLANK_COMPANION_TYPE, ATTENDABLE_PATH_SEPARATOR } from "@dxos/plugin-deck/types";
28
+ import { createExtension } from "@dxos/plugin-graph";
29
+ import { DocumentType } from "@dxos/plugin-markdown/types";
30
+ import { MeetingCapabilities } from "@dxos/plugin-meeting";
31
+ import { MeetingType } from "@dxos/plugin-meeting/types";
32
+ import { DataType as DataType2 } from "@dxos/schema";
33
+
34
+ // packages/plugins/plugin-transcription/src/entity-extraction/entity-extraction.ts
35
+ import { Schema } from "effect";
36
+ import { createTemplate, Message, structuredOutputParser } from "@dxos/artifact";
37
+ import { MixedStreamParser } from "@dxos/assistant";
38
+ import { asyncTimeout } from "@dxos/async";
39
+ import { create, ObjectId } from "@dxos/echo-schema";
40
+ import { DXN } from "@dxos/keys";
41
+ import { log } from "@dxos/log";
42
+ import { DataType } from "@dxos/schema";
43
+
44
+ // raw-loader:./system-prompt.tpl?raw
45
+ var system_prompt_default = 'You are an AI assistant specialized in processing and enhancing transcripts with contextual information.\nYour task is to analyze a given transcript and extract references to the context objects.\n\nThe context and transcript are provided in the user message in `context` and `transcript` XML tags.\n\nHere are your instructions:\n\n1. Read the transcript and context information provided above.\n\n2. Process each segment of the transcript separately.\n\n3. For each segment:\n a. Analyze the content and identify relevant information from the context.\n b. Extract a number of references to the context objects that are mentioned in the segment.\n c. Output the references in the format `{ "quote": "earnings report", "id": "01JT0JP9AX0XKGZX4MV4B69VT6" }`.\n d. If there are no references, just output an empty array.\n\n4. Maintain the exact order and structure of the original transcript segments.\n\nOutput Format:\nThe final output should be a JSON array of references.\n\nExample output structure:\n```json\n{\n "references": [\n { "quote": "earnings report", "id": "01JT0JP9AX0XKGZX4MV4B69VT6" },\n { "quote": "John", "id": "01JT0VM0VN3ZKN7GDBM8CV9BA7" }\n ]\n}\n```\n\nRemember:\n- Only quote the text that is in the transcript.\n- Analyze each segment carefully before processing it.\n- Only reference objects that appear in the context and exactly by their id, If the object is not in the context, do not insert a reference. \n\nNow, process the transcript and context provided below according to these instructions.';
46
+
47
+ // packages/plugins/plugin-transcription/src/entity-extraction/entity-extraction.ts
48
+ var __dxlog_file = "/home/runner/work/dxos/dxos/packages/plugins/plugin-transcription/src/entity-extraction/entity-extraction.ts";
49
+ var createSystemPrompt = () => {
50
+ const template = createTemplate(system_prompt_default);
51
+ return template({});
52
+ };
53
+ var ReferencedQuotes = Schema.Struct({
54
+ references: Schema.Array(Schema.Struct({
55
+ quote: Schema.String,
56
+ id: Schema.String
57
+ })).annotations({
58
+ description: "The references to the context objects that are mentioned in the transcript. quote should match the original transcript text exactly, while id is the id of the context object."
59
+ })
60
+ });
61
+ var processTranscriptMessage = async (params) => {
62
+ try {
63
+ const outputParser = structuredOutputParser(ReferencedQuotes);
64
+ const runParser = async () => {
65
+ const startTime = performance.now();
66
+ const result = outputParser.getResult(await new MixedStreamParser().parse(await params.aiService.execStream({
67
+ model: "@anthropic/claude-3-5-haiku-20241022",
68
+ systemPrompt: createSystemPrompt(),
69
+ history: [
70
+ create(Message, {
71
+ role: "user",
72
+ content: [
73
+ {
74
+ type: "text",
75
+ text: `<context>${JSON.stringify(params.context.objects)}</context>`
76
+ },
77
+ {
78
+ type: "text",
79
+ text: `<transcript>${JSON.stringify(params.message.blocks)}</transcript>`
80
+ }
81
+ ]
82
+ })
83
+ ],
84
+ tools: [
85
+ outputParser.tool
86
+ ]
87
+ })));
88
+ log.info("entity extraction result", {
89
+ refs: result.references
90
+ }, {
91
+ F: __dxlog_file,
92
+ L: 98,
93
+ S: void 0,
94
+ C: (f, a) => f(...a)
95
+ });
96
+ return {
97
+ message: create(DataType.Message, {
98
+ ...params.message,
99
+ blocks: params.message.blocks.map((block, i) => block.type !== "transcription" ? block : {
100
+ ...block,
101
+ text: postprocessText(block.text, result)
102
+ })
103
+ }),
104
+ timeElapsed: performance.now() - startTime
105
+ };
106
+ };
107
+ if (params.options?.timeout && params.options.timeout > 0) {
108
+ return await asyncTimeout(runParser(), params.options.timeout);
109
+ } else {
110
+ return await runParser();
111
+ }
112
+ } catch (error) {
113
+ if (params.options?.fallbackToRaw) {
114
+ log.warn("failed to process transcript message, falling back to raw text", {
115
+ error
116
+ }, {
117
+ F: __dxlog_file,
118
+ L: 123,
119
+ S: void 0,
120
+ C: (f, a) => f(...a)
121
+ });
122
+ return {
123
+ message: params.message,
124
+ timeElapsed: 0
125
+ };
126
+ } else {
127
+ throw error;
128
+ }
129
+ }
130
+ };
131
+ var postprocessText = (text, quotes) => {
132
+ for (const quote of quotes.references) {
133
+ if (!ObjectId.isValid(quote.id)) {
134
+ continue;
135
+ }
136
+ const regex = new RegExp(quote.quote.replace(/[.*+?^${}()|[\]\\]/g, "\\$&"), "gi");
137
+ text = text.replace(regex, `[${quote.quote}][${DXN.fromLocalObjectId(quote.id).toString()}]`);
138
+ }
139
+ return text;
140
+ };
141
+
142
+ // packages/plugins/plugin-transcription/src/capabilities/app-graph-builder.ts
143
+ var __dxlog_file2 = "/home/runner/work/dxos/dxos/packages/plugins/plugin-transcription/src/capabilities/app-graph-builder.ts";
144
+ var getMeetingTranscript = async (context, meeting) => {
145
+ const { dispatchPromise: dispatch } = context.requestCapability(Capabilities.IntentDispatcher);
146
+ const typename = getSchemaTypename(TranscriptType);
147
+ const existing = await meeting.artifacts[typename]?.load();
148
+ if (existing instanceof TranscriptType) {
149
+ return existing;
150
+ }
151
+ const space = getSpace(meeting);
152
+ invariant(space, void 0, {
153
+ F: __dxlog_file2,
154
+ L: 48,
155
+ S: void 0,
156
+ A: [
157
+ "space",
158
+ ""
159
+ ]
160
+ });
161
+ const { data } = await dispatch(createIntent(TranscriptionAction.Create, {
162
+ spaceId: space.id
163
+ }));
164
+ meeting.artifacts[typename] = makeRef(data.object);
165
+ return data?.object;
166
+ };
167
+ var app_graph_builder_default = (context) => contributes(Capabilities.AppGraphBuilder, [
168
+ createExtension({
169
+ id: `${TRANSCRIPTION_PLUGIN}/meeting-transcript`,
170
+ filter: (node) => isInstanceOf(MeetingType, node.data),
171
+ actions: ({ node }) => {
172
+ const meeting = node.data;
173
+ const state = context.requestCapability(TranscriptionCapabilities.MeetingTranscriptionState);
174
+ return [
175
+ {
176
+ id: `${fullyQualifiedId(meeting)}/action/start-stop-transcription`,
177
+ data: async () => {
178
+ const transcript = await getMeetingTranscript(context, meeting);
179
+ invariant(transcript, "Failed to create transcript", {
180
+ F: __dxlog_file2,
181
+ L: 71,
182
+ S: void 0,
183
+ A: [
184
+ "transcript",
185
+ "'Failed to create transcript'"
186
+ ]
187
+ });
188
+ const callManager = context.requestCapability(MeetingCapabilities.CallManager);
189
+ callManager.setActivity(getSchemaTypename(TranscriptType), {
190
+ queueDxn: transcript.queue.dxn.toString(),
191
+ enabled: !state.enabled
192
+ });
193
+ },
194
+ properties: {
195
+ label: state.enabled ? [
196
+ "stop transcription label",
197
+ {
198
+ ns: TRANSCRIPTION_PLUGIN
199
+ }
200
+ ] : [
201
+ "start transcription label",
202
+ {
203
+ ns: TRANSCRIPTION_PLUGIN
204
+ }
205
+ ],
206
+ icon: "ph--subtitles--regular",
207
+ disposition: "toolbar",
208
+ classNames: state.enabled ? "bg-callAlert" : ""
209
+ }
210
+ }
211
+ ];
212
+ },
213
+ connector: ({ node }) => {
214
+ const meeting = node.data;
215
+ const client = context.requestCapability(ClientCapabilities.Client);
216
+ const state = context.requestCapability(TranscriptionCapabilities.MeetingTranscriptionState);
217
+ const settings = context.requestCapability(Capabilities.SettingsStore).getStore(TRANSCRIPTION_PLUGIN).value;
218
+ const aiClient = new AIServiceEdgeClient({
219
+ endpoint: AI_SERVICE_ENDPOINT.REMOTE
220
+ });
221
+ return [
222
+ {
223
+ id: `${fullyQualifiedId(meeting)}${ATTENDABLE_PATH_SEPARATOR}${getSchemaTypename(TranscriptType)}`,
224
+ type: PLANK_COMPANION_TYPE,
225
+ data: meeting.artifacts[getSchemaTypename(TranscriptType)]?.target,
226
+ properties: {
227
+ label: [
228
+ "transcript companion label",
229
+ {
230
+ ns: TRANSCRIPTION_PLUGIN
231
+ }
232
+ ],
233
+ icon: "ph--subtitles--regular",
234
+ position: "hoist",
235
+ disposition: "hidden",
236
+ schema: TranscriptType,
237
+ getIntent: ({ space }) => createIntent(TranscriptionAction.Create, {
238
+ spaceId: space.id
239
+ }),
240
+ // TODO(burdon): Is this the right place to inisitalize the state? Change to a capability?
241
+ onJoin: async ({ meeting: meeting2 }) => {
242
+ const identity = client.halo.identity.get();
243
+ invariant(identity, void 0, {
244
+ F: __dxlog_file2,
245
+ L: 120,
246
+ S: void 0,
247
+ A: [
248
+ "identity",
249
+ ""
250
+ ]
251
+ });
252
+ const space = getSpace(meeting2);
253
+ invariant(space, void 0, {
254
+ F: __dxlog_file2,
255
+ L: 122,
256
+ S: void 0,
257
+ A: [
258
+ "space",
259
+ ""
260
+ ]
261
+ });
262
+ let messageEnricher;
263
+ if (aiClient && settings.entityExtraction) {
264
+ messageEnricher = createEntityExtractionEnricher({
265
+ aiClient,
266
+ // TODO(dmaretskyi): Have those be discovered from the schema graph or contributed by capabilities?
267
+ // This forced me to add a dependency on markdown plugin.
268
+ // This will be replaced with a vector search index anyway, so its not a big deal.
269
+ contextTypes: [
270
+ DocumentType,
271
+ DataType2.Person,
272
+ DataType2.Organization
273
+ ],
274
+ space
275
+ });
276
+ }
277
+ state.transcriptionManager = await new TranscriptionManager({
278
+ edgeClient: client.edge,
279
+ messageEnricher
280
+ }).setIdentityDid(identity.did).open();
281
+ },
282
+ onLeave: async () => {
283
+ await state.transcriptionManager?.close();
284
+ state.transcriptionManager = void 0;
285
+ state.enabled = false;
286
+ },
287
+ onCallStateUpdated: async (callState) => {
288
+ const typename = getSchemaTypename(TranscriptType);
289
+ const transcription = typename ? callState.activities?.[typename] : void 0;
290
+ if (!transcription?.payload) {
291
+ return;
292
+ }
293
+ const payload = transcription.payload;
294
+ state.enabled = !!payload.enabled;
295
+ if (payload.queueDxn) {
296
+ state.transcriptionManager?.setQueue(DXN2.parse(payload.queueDxn));
297
+ }
298
+ await state.transcriptionManager?.setEnabled(payload.enabled);
299
+ },
300
+ onMediaStateUpdated: async ([mediaState, isSpeaking]) => {
301
+ void state.transcriptionManager?.setAudioTrack(mediaState.audioTrack);
302
+ void state.transcriptionManager?.setRecording(isSpeaking);
303
+ }
304
+ }
305
+ }
306
+ ];
307
+ }
308
+ })
309
+ ]);
310
+ var createEntityExtractionEnricher = ({ aiClient, contextTypes, space }) => {
311
+ return async (message) => {
312
+ const { objects } = await space.db.query(Filter.or(...contextTypes.map((s) => Filter.schema(s)))).run();
313
+ log2.info("context", {
314
+ objects
315
+ }, {
316
+ F: __dxlog_file2,
317
+ L: 184,
318
+ S: void 0,
319
+ C: (f, a) => f(...a)
320
+ });
321
+ const { message: enhancedMessage, timeElapsed } = await processTranscriptMessage({
322
+ aiService: aiClient,
323
+ message,
324
+ context: {
325
+ objects: await Promise.all(objects.map(processContextObject))
326
+ },
327
+ options: {
328
+ timeout: ENTITY_EXTRACTOR_TIMEOUT,
329
+ fallbackToRaw: true
330
+ }
331
+ });
332
+ log2.info("entity extraction time", {
333
+ timeElapsed
334
+ }, {
335
+ F: __dxlog_file2,
336
+ L: 193,
337
+ S: void 0,
338
+ C: (f, a) => f(...a)
339
+ });
340
+ return enhancedMessage;
341
+ };
342
+ };
343
+ var processContextObject = async (object) => {
344
+ return object;
345
+ };
346
+ var ENTITY_EXTRACTOR_TIMEOUT = 25e3;
347
+ export {
348
+ app_graph_builder_default as default
349
+ };
350
+ //# sourceMappingURL=app-graph-builder-6FY2UQOH.mjs.map
@@ -0,0 +1,7 @@
1
+ {
2
+ "version": 3,
3
+ "sources": ["../../../src/capabilities/app-graph-builder.ts", "../../../src/entity-extraction/entity-extraction.ts", "raw-loader:./system-prompt.tpl?raw"],
4
+ "sourcesContent": ["//\n// Copyright 2025 DXOS.org\n//\n\nimport type { Schema } from 'effect';\n\nimport { Capabilities, contributes, createIntent, type PluginsContext } from '@dxos/app-framework';\nimport { AIServiceEdgeClient, type AIServiceClient } from '@dxos/assistant';\nimport { AI_SERVICE_ENDPOINT } from '@dxos/assistant/testing';\nimport { Filter, fullyQualifiedId, getSpace, makeRef, type Space } from '@dxos/client/echo';\nimport { getSchemaTypename, isInstanceOf, type BaseEchoObject } from '@dxos/echo-schema';\nimport { invariant } from '@dxos/invariant';\nimport { DXN } from '@dxos/keys';\nimport { log } from '@dxos/log';\nimport { ClientCapabilities } from '@dxos/plugin-client';\nimport { PLANK_COMPANION_TYPE, ATTENDABLE_PATH_SEPARATOR } from '@dxos/plugin-deck/types';\nimport { createExtension, type Node } from '@dxos/plugin-graph';\nimport { DocumentType } from '@dxos/plugin-markdown/types';\nimport { MeetingCapabilities, type CallState, type MediaState } from '@dxos/plugin-meeting';\nimport { MeetingType, type MeetingCallProperties } from '@dxos/plugin-meeting/types';\nimport { type buf } from '@dxos/protocols/buf';\nimport { type TranscriptionPayloadSchema } from '@dxos/protocols/buf/dxos/edge/calls_pb';\nimport { DataType } from '@dxos/schema';\n\nimport { TranscriptionCapabilities } from './capabilities';\nimport { processTranscriptMessage } from '../entity-extraction';\nimport { TRANSCRIPTION_PLUGIN } from '../meta';\nimport { TranscriptionManager } from '../transcriber';\nimport { TranscriptionAction, type TranscriptionSettingsProps, TranscriptType } from '../types';\n\n// TODO(wittjosiah): Factor out.\n// TODO(wittjosiah): Can we stop using protobuf for this?\ntype TranscriptionPayload = buf.MessageInitShape<typeof TranscriptionPayloadSchema>;\n\nconst getMeetingTranscript = async (\n context: PluginsContext,\n meeting: MeetingType,\n): Promise<TranscriptType | undefined> => {\n const { dispatchPromise: dispatch } = context.requestCapability(Capabilities.IntentDispatcher);\n\n const typename = getSchemaTypename(TranscriptType)!;\n const existing = await meeting.artifacts[typename]?.load();\n if (existing instanceof TranscriptType) {\n return existing;\n }\n\n const space = getSpace(meeting);\n invariant(space);\n const { data } = await dispatch(createIntent(TranscriptionAction.Create, { spaceId: space.id }));\n meeting.artifacts[typename] = makeRef(data!.object);\n return data?.object;\n};\n\n// TODO(wittjosiah): Introduce a sound that plays when transcription is activated/deactivated.\nexport default (context: PluginsContext) =>\n contributes(Capabilities.AppGraphBuilder, [\n createExtension({\n id: `${TRANSCRIPTION_PLUGIN}/meeting-transcript`,\n filter: (node): node is Node<MeetingType> => isInstanceOf(MeetingType, node.data),\n actions: ({ node }) => {\n const meeting = node.data;\n const state = context.requestCapability(TranscriptionCapabilities.MeetingTranscriptionState);\n return [\n {\n id: `${fullyQualifiedId(meeting)}/action/start-stop-transcription`,\n data: async () => {\n // NOTE: We are not saving the state of the transcription manager here.\n // We expect the state to be updated through `onCallStateUpdated` once it is propagated through Swarm.\n // This is done to avoid race conditions and to not handle optimistic updates.\n const transcript = await getMeetingTranscript(context, meeting);\n invariant(transcript, 'Failed to create transcript');\n\n const callManager = context.requestCapability(MeetingCapabilities.CallManager);\n callManager.setActivity(getSchemaTypename(TranscriptType)!, {\n queueDxn: transcript.queue.dxn.toString(),\n enabled: !state.enabled,\n });\n },\n properties: {\n label: state.enabled\n ? ['stop transcription label', { ns: TRANSCRIPTION_PLUGIN }]\n : ['start transcription label', { ns: TRANSCRIPTION_PLUGIN }],\n icon: 'ph--subtitles--regular',\n disposition: 'toolbar',\n classNames: state.enabled ? 'bg-callAlert' : '',\n },\n },\n ];\n },\n connector: ({ node }) => {\n const meeting = node.data;\n const client = context.requestCapability(ClientCapabilities.Client);\n const state = context.requestCapability(TranscriptionCapabilities.MeetingTranscriptionState);\n const settings = context\n .requestCapability(Capabilities.SettingsStore)\n .getStore<TranscriptionSettingsProps>(TRANSCRIPTION_PLUGIN)!.value;\n\n // TODO(dmaretskyi): Request via capability.\n const aiClient: AIServiceClient | undefined = new AIServiceEdgeClient({\n endpoint: AI_SERVICE_ENDPOINT.REMOTE,\n });\n\n return [\n {\n id: `${fullyQualifiedId(meeting)}${ATTENDABLE_PATH_SEPARATOR}${getSchemaTypename(TranscriptType)}`,\n type: PLANK_COMPANION_TYPE,\n data: meeting.artifacts[getSchemaTypename(TranscriptType)!]?.target,\n properties: {\n label: ['transcript companion label', { ns: TRANSCRIPTION_PLUGIN }],\n icon: 'ph--subtitles--regular',\n position: 'hoist',\n disposition: 'hidden',\n schema: TranscriptType,\n getIntent: ({ space }: { space: Space }) =>\n createIntent(TranscriptionAction.Create, { spaceId: space.id }),\n\n // TODO(burdon): Is this the right place to inisitalize the state? Change to a capability?\n onJoin: async ({ meeting }: { meeting: MeetingType; roomId: string }) => {\n const identity = client.halo.identity.get();\n invariant(identity);\n const space = getSpace(meeting);\n invariant(space);\n\n let messageEnricher;\n if (aiClient && settings.entityExtraction) {\n messageEnricher = createEntityExtractionEnricher({\n aiClient,\n // TODO(dmaretskyi): Have those be discovered from the schema graph or contributed by capabilities?\n // This forced me to add a dependency on markdown plugin.\n // This will be replaced with a vector search index anyway, so its not a big deal.\n contextTypes: [DocumentType, DataType.Person, DataType.Organization],\n space,\n });\n }\n\n // TODO(burdon): The TranscriptionManager singleton is part of the state and should just be updated here.\n state.transcriptionManager = await new TranscriptionManager({\n edgeClient: client.edge,\n messageEnricher,\n })\n .setIdentityDid(identity.did)\n .open();\n },\n onLeave: async () => {\n await state.transcriptionManager?.close();\n state.transcriptionManager = undefined;\n state.enabled = false;\n },\n onCallStateUpdated: async (callState: CallState) => {\n const typename = getSchemaTypename(TranscriptType);\n const transcription = typename ? callState.activities?.[typename] : undefined;\n if (!transcription?.payload) {\n return;\n }\n\n const payload: TranscriptionPayload = transcription.payload;\n state.enabled = !!payload.enabled;\n if (payload.queueDxn) {\n // NOTE: Must set queue before enabling transcription.\n state.transcriptionManager?.setQueue(DXN.parse(payload.queueDxn));\n }\n await state.transcriptionManager?.setEnabled(payload.enabled);\n },\n onMediaStateUpdated: async ([mediaState, isSpeaking]: [MediaState, boolean]) => {\n void state.transcriptionManager?.setAudioTrack(mediaState.audioTrack);\n void state.transcriptionManager?.setRecording(isSpeaking);\n },\n } satisfies MeetingCallProperties,\n },\n ];\n },\n }),\n ]);\n\ntype EntityExtractionEnricherFactoryOptions = {\n aiClient: AIServiceClient;\n contextTypes: Schema.Schema.AnyNoContext[];\n space: Space;\n};\n\nconst createEntityExtractionEnricher = ({ aiClient, contextTypes, space }: EntityExtractionEnricherFactoryOptions) => {\n return async (message: DataType.Message) => {\n const { objects } = await space.db.query(Filter.or(...contextTypes.map((s) => Filter.schema(s)))).run();\n log.info('context', { objects });\n\n const { message: enhancedMessage, timeElapsed } = await processTranscriptMessage({\n aiService: aiClient,\n message,\n context: { objects: await Promise.all(objects.map(processContextObject)) },\n options: { timeout: ENTITY_EXTRACTOR_TIMEOUT, fallbackToRaw: true },\n });\n\n log.info('entity extraction time', { timeElapsed });\n return enhancedMessage;\n };\n};\n\nconst processContextObject = async (object: BaseEchoObject): Promise<any> => {\n // TODO(dmaretskyi): Documents need special processing is the content is behind a ref.\n // TODO(dmaretskyi): Think about a way to handle this serialization with a decorator.\n // if (isInstanceOf(DocumentType, object)) {\n // return {\n // ...object,\n // content: await object.content.load(),\n // };\n // }\n\n return object;\n};\n\nconst ENTITY_EXTRACTOR_TIMEOUT = 25_000;\n", "//\n// Copyright 2025 DXOS.org\n//\n\nimport { Schema } from 'effect';\n\nimport { createTemplate, Message, structuredOutputParser } from '@dxos/artifact';\nimport type { AIServiceClient } from '@dxos/assistant';\nimport { MixedStreamParser } from '@dxos/assistant';\nimport { asyncTimeout } from '@dxos/async';\nimport { type BaseEchoObject, create, ObjectId } from '@dxos/echo-schema';\nimport { DXN } from '@dxos/keys';\nimport { log } from '@dxos/log';\nimport { DataType } from '@dxos/schema';\n\nimport SYSTEM_PROMPT from './system-prompt.tpl?raw';\n\ntype ProcessTranscriptMessageParams = {\n message: DataType.Message;\n aiService: AIServiceClient;\n context: {\n objects?: BaseEchoObject[];\n };\n\n options?: {\n /**\n * Timeout for the entity extraction.\n */\n timeout?: number;\n\n /**\n * Fallback to raw text if the entity extraction fails.\n * Otherwise the function will throw an error.\n * @default false\n */\n fallbackToRaw?: boolean;\n };\n};\n\ntype ProcessTranscriptMessageResult = {\n message: DataType.Message;\n timeElapsed: number;\n};\n\n/**\n * Process Handlebars template.\n */\nconst createSystemPrompt = (): string => {\n const template = createTemplate(SYSTEM_PROMPT);\n return template({});\n};\n\nconst ReferencedQuotes = Schema.Struct({\n references: Schema.Array(\n Schema.Struct({\n quote: Schema.String,\n id: Schema.String,\n }),\n ).annotations({\n description:\n 'The references to the context objects that are mentioned in the transcript. quote should match the original transcript text exactly, while id is the id of the context object.',\n }),\n});\ninterface ReferencedQuotes extends Schema.Schema.Type<typeof ReferencedQuotes> {}\n\n// TODO(dmaretskyi): Move context to a vector search index.\nexport const processTranscriptMessage = async (\n params: ProcessTranscriptMessageParams,\n): Promise<ProcessTranscriptMessageResult> => {\n try {\n const outputParser = structuredOutputParser(ReferencedQuotes);\n const runParser = async (): Promise<ProcessTranscriptMessageResult> => {\n const startTime = performance.now();\n const result = outputParser.getResult(\n await new MixedStreamParser().parse(\n await params.aiService.execStream({\n model: '@anthropic/claude-3-5-haiku-20241022',\n systemPrompt: createSystemPrompt(),\n history: [\n create(Message, {\n role: 'user',\n content: [\n {\n type: 'text',\n text: `<context>${JSON.stringify(params.context.objects)}</context>`,\n },\n {\n type: 'text',\n text: `<transcript>${JSON.stringify(params.message.blocks)}</transcript>`,\n },\n ],\n }),\n ],\n tools: [outputParser.tool],\n }),\n ),\n );\n log.info('entity extraction result', { refs: result.references });\n\n return {\n message: create(DataType.Message, {\n ...params.message,\n blocks: params.message.blocks.map((block, i) =>\n block.type !== 'transcription'\n ? block\n : {\n ...block,\n text: postprocessText(block.text, result),\n },\n ),\n }),\n timeElapsed: performance.now() - startTime,\n };\n };\n\n if (params.options?.timeout && params.options.timeout > 0) {\n return await asyncTimeout(runParser(), params.options.timeout);\n } else {\n return await runParser();\n }\n } catch (error) {\n if (params.options?.fallbackToRaw) {\n log.warn('failed to process transcript message, falling back to raw text', { error });\n return {\n message: params.message,\n timeElapsed: 0,\n };\n } else {\n throw error;\n }\n }\n};\n\n/**\n * Finds and replaces all quotes with DXNs references.\n */\n// TODO(dmaretskyi): Lookup and verifiy ids from provided context.\nexport const postprocessText = (text: string, quotes: ReferencedQuotes) => {\n for (const quote of quotes.references) {\n if (!ObjectId.isValid(quote.id)) {\n continue;\n }\n\n // Use a case-insensitive regular expression to replace the quote\n const regex = new RegExp(quote.quote.replace(/[.*+?^${}()|[\\]\\\\]/g, '\\\\$&'), 'gi');\n text = text.replace(regex, `[${quote.quote}][${DXN.fromLocalObjectId(quote.id).toString()}]`);\n }\n return text;\n};\n", "You are an AI assistant specialized in processing and enhancing transcripts with contextual information.\nYour task is to analyze a given transcript and extract references to the context objects.\n\nThe context and transcript are provided in the user message in `context` and `transcript` XML tags.\n\nHere are your instructions:\n\n1. Read the transcript and context information provided above.\n\n2. Process each segment of the transcript separately.\n\n3. For each segment:\n a. Analyze the content and identify relevant information from the context.\n b. Extract a number of references to the context objects that are mentioned in the segment.\n c. Output the references in the format `{ \"quote\": \"earnings report\", \"id\": \"01JT0JP9AX0XKGZX4MV4B69VT6\" }`.\n d. If there are no references, just output an empty array.\n\n4. Maintain the exact order and structure of the original transcript segments.\n\nOutput Format:\nThe final output should be a JSON array of references.\n\nExample output structure:\n```json\n{\n \"references\": [\n { \"quote\": \"earnings report\", \"id\": \"01JT0JP9AX0XKGZX4MV4B69VT6\" },\n { \"quote\": \"John\", \"id\": \"01JT0VM0VN3ZKN7GDBM8CV9BA7\" }\n ]\n}\n```\n\nRemember:\n- Only quote the text that is in the transcript.\n- Analyze each segment carefully before processing it.\n- Only reference objects that appear in the context and exactly by their id, If the object is not in the context, do not insert a reference. \n\nNow, process the transcript and context provided below according to these instructions."],
5
+ "mappings": ";;;;;;;;;;;;;;;;;AAMA,SAASA,cAAcC,aAAaC,oBAAyC;AAC7E,SAASC,2BAAiD;AAC1D,SAASC,2BAA2B;AACpC,SAASC,QAAQC,kBAAkBC,UAAUC,eAA2B;AACxE,SAASC,mBAAmBC,oBAAyC;AACrE,SAASC,iBAAiB;AAC1B,SAASC,OAAAA,YAAW;AACpB,SAASC,OAAAA,YAAW;AACpB,SAASC,0BAA0B;AACnC,SAASC,sBAAsBC,iCAAiC;AAChE,SAASC,uBAAkC;AAC3C,SAASC,oBAAoB;AAC7B,SAASC,2BAA4D;AACrE,SAASC,mBAA+C;AAGxD,SAASC,YAAAA,iBAAgB;;;AClBzB,SAASC,cAAc;AAEvB,SAASC,gBAAgBC,SAASC,8BAA8B;AAEhE,SAASC,yBAAyB;AAClC,SAASC,oBAAoB;AAC7B,SAA8BC,QAAQC,gBAAgB;AACtD,SAASC,WAAW;AACpB,SAASC,WAAW;AACpB,SAASC,gBAAgB;;;ACbzB;;;;AD+CA,IAAMC,qBAAqB,MAAA;AACzB,QAAMC,WAAWC,eAAeC,qBAAAA;AAChC,SAAOF,SAAS,CAAC,CAAA;AACnB;AAEA,IAAMG,mBAAmBC,OAAOC,OAAO;EACrCC,YAAYF,OAAOG,MACjBH,OAAOC,OAAO;IACZG,OAAOJ,OAAOK;IACdC,IAAIN,OAAOK;EACb,CAAA,CAAA,EACAE,YAAY;IACZC,aACE;EACJ,CAAA;AACF,CAAA;AAIO,IAAMC,2BAA2B,OACtCC,WAAAA;AAEA,MAAI;AACF,UAAMC,eAAeC,uBAAuBb,gBAAAA;AAC5C,UAAMc,YAAY,YAAA;AA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,MAAMoD,sBAAsBwB,aAAaH,UAAAA;YAChD;UACF;QACF;;IAEJ;EACF,CAAA;CACD;AAQH,IAAM3B,iCAAiC,CAAC,EAAElB,UAAUmB,cAAcnE,MAAK,MAA0C;AAC/G,SAAO,OAAOiG,YAAAA;AACZ,UAAM,EAAEC,QAAO,IAAK,MAAMlG,MAAMmG,GAAGC,MAAMC,OAAOC,GAAE,GAAInC,aAAaoC,IAAI,CAACC,MAAMH,OAAO3C,OAAO8C,CAAAA,CAAAA,CAAAA,CAAAA,EAAMC,IAAG;AACrGC,IAAAA,KAAIC,KAAK,WAAW;MAAET;IAAQ,GAAA;;;;;;AAE9B,UAAM,EAAED,SAASW,iBAAiBC,YAAW,IAAK,MAAMC,yBAAyB;MAC/EC,WAAW/D;MACXiD;MACA9G,SAAS;QAAE+G,SAAS,MAAMc,QAAQC,IAAIf,QAAQK,IAAIW,oBAAAA,CAAAA;MAAuB;MACzEC,SAAS;QAAEC,SAASC;QAA0BC,eAAe;MAAK;IACpE,CAAA;AAEAZ,IAAAA,KAAIC,KAAK,0BAA0B;MAAEE;IAAY,GAAA;;;;;;AACjD,WAAOD;EACT;AACF;AAEA,IAAMM,uBAAuB,OAAOxG,WAAAA;AAUlC,SAAOA;AACT;AAEA,IAAM2G,2BAA2B;",
6
+ "names": ["Capabilities", "contributes", "createIntent", "AIServiceEdgeClient", "AI_SERVICE_ENDPOINT", "Filter", "fullyQualifiedId", "getSpace", "makeRef", "getSchemaTypename", "isInstanceOf", "invariant", "DXN", "log", "ClientCapabilities", "PLANK_COMPANION_TYPE", "ATTENDABLE_PATH_SEPARATOR", "createExtension", "DocumentType", "MeetingCapabilities", "MeetingType", "DataType", "Schema", "createTemplate", "Message", "structuredOutputParser", "MixedStreamParser", "asyncTimeout", "create", "ObjectId", "DXN", "log", "DataType", "createSystemPrompt", "template", "createTemplate", "SYSTEM_PROMPT", "ReferencedQuotes", "Schema", "Struct", "references", "Array", "quote", "String", "id", "annotations", "description", "processTranscriptMessage", "params", "outputParser", "structuredOutputParser", "runParser", "startTime", "performance", "now", "result", "getResult", "MixedStreamParser", "parse", "aiService", "execStream", "model", "systemPrompt", "history", "create", "Message", "role", "content", "type", "text", "JSON", "stringify", "context", "objects", "message", "blocks", "tools", "tool", "log", "info", "refs", "DataType", "map", "block", "i", "postprocessText", "timeElapsed", "options", "timeout", "asyncTimeout", "error", "fallbackToRaw", "warn", "quotes", "ObjectId", "isValid", "regex", "RegExp", "replace", "DXN", "fromLocalObjectId", "toString", "getMeetingTranscript", "context", "meeting", "dispatchPromise", "dispatch", "requestCapability", "Capabilities", "IntentDispatcher", "typename", "getSchemaTypename", "TranscriptType", "existing", "artifacts", "load", "space", "getSpace", "invariant", "data", "createIntent", "TranscriptionAction", "Create", "spaceId", "id", "makeRef", "object", "contributes", "AppGraphBuilder", "createExtension", "TRANSCRIPTION_PLUGIN", "filter", "node", "isInstanceOf", "MeetingType", "actions", "state", "TranscriptionCapabilities", "MeetingTranscriptionState", "fullyQualifiedId", "transcript", "callManager", "MeetingCapabilities", "CallManager", "setActivity", "queueDxn", "queue", "dxn", "toString", "enabled", "properties", "label", "ns", "icon", "disposition", "classNames", "connector", "client", "ClientCapabilities", "Client", "settings", "SettingsStore", "getStore", "value", "aiClient", "AIServiceEdgeClient", "endpoint", "AI_SERVICE_ENDPOINT", "REMOTE", "ATTENDABLE_PATH_SEPARATOR", "type", "PLANK_COMPANION_TYPE", "target", "position", "schema", "getIntent", "onJoin", "identity", "halo", "get", "messageEnricher", "entityExtraction", "createEntityExtractionEnricher", "contextTypes", "DocumentType", "DataType", "Person", "Organization", "transcriptionManager", "TranscriptionManager", "edgeClient", "edge", "setIdentityDid", "did", "open", "onLeave", "close", "undefined", "onCallStateUpdated", "callState", "transcription", "activities", "payload", "setQueue", "DXN", "parse", "setEnabled", "onMediaStateUpdated", "mediaState", "isSpeaking", "setAudioTrack", "audioTrack", "setRecording", "message", "objects", "db", "query", "Filter", "or", "map", "s", "run", "log", "info", "enhancedMessage", "timeElapsed", "processTranscriptMessage", "aiService", "Promise", "all", "processContextObject", "options", "timeout", "ENTITY_EXTRACTOR_TIMEOUT", "fallbackToRaw"]
7
+ }