@onereach/step-voice 7.0.9-processttschunk.20 → 7.0.9-processttschunk.21

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.
@@ -1,14 +1,18 @@
1
1
  import VoiceStep, { TODO, VoiceEvent } from './voice';
2
2
  interface INPUT {
3
- voiceId: string;
3
+ /** Required when `chunksStreamingEnabled` is true (ElevenLabs stream). */
4
+ voiceId?: string;
4
5
  infiniteProcessing: boolean;
5
6
  asr: TODO;
6
7
  endpointing: number;
7
- voiceSettings: any;
8
- queryParams: any;
8
+ /** Required when `chunksStreamingEnabled` is true; may be a getter function. */
9
+ voiceSettings?: any;
10
+ /** Required when `chunksStreamingEnabled` is true; may be a getter function. */
11
+ queryParams?: any;
9
12
  minConfidence: number;
10
13
  /** `true` → ElevenLabs stream (`playbackMode: 'chunks'`). `false` → synthesize + playback per phrase (`phrases`). */
11
14
  chunksStreamingEnabled: boolean;
15
+ /** Used when `chunksStreamingEnabled` is false — must expose `getSettings(call.tts)` (or equivalent) for `phraseTtsSettings`. */
12
16
  tts?: TODO;
13
17
  confirmationConfidence?: number;
14
18
  }
@@ -15,8 +15,6 @@ class StartTTSChunksProcessing extends voice_1.default {
15
15
  }
16
16
  }
17
17
  };
18
- const voiceSettings = await getSettings.call(this);
19
- const queryParams = await getParams.call(this);
20
18
  const base = {
21
19
  grammar,
22
20
  minConfidence,
@@ -24,6 +22,8 @@ class StartTTSChunksProcessing extends voice_1.default {
24
22
  };
25
23
  let params;
26
24
  if (chunksStreamingEnabled) {
25
+ const voiceSettings = await getSettings.call(this);
26
+ const queryParams = await getParams.call(this);
27
27
  params = {
28
28
  ...base,
29
29
  playbackMode: 'chunks',
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@onereach/step-voice",
3
- "version": "7.0.9-processttschunk.20",
3
+ "version": "7.0.9-processttschunk.21",
4
4
  "author": "Roman Zolotarov <roman.zolotarov@onereach.com>",
5
5
  "contributors": [
6
6
  "Roman Zolotarov",