@absolutejs/voice 0.0.22-beta.496 → 0.0.22-beta.497
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.js +1 -0
- package/dist/testing/index.js +1 -0
- package/dist/types.d.ts +14 -0
- package/package.json +1 -1
package/dist/index.js
CHANGED
package/dist/testing/index.js
CHANGED
package/dist/types.d.ts
CHANGED
|
@@ -49,12 +49,18 @@ export type VoiceLexiconEntry = {
|
|
|
49
49
|
metadata?: Record<string, unknown>;
|
|
50
50
|
pronunciation?: string;
|
|
51
51
|
};
|
|
52
|
+
export type VoiceTranscriptSentiment = {
|
|
53
|
+
label: "negative" | "neutral" | "positive" | (string & {});
|
|
54
|
+
metadata?: Record<string, unknown>;
|
|
55
|
+
score?: number;
|
|
56
|
+
};
|
|
52
57
|
export type Transcript = {
|
|
53
58
|
id: string;
|
|
54
59
|
text: string;
|
|
55
60
|
isFinal: boolean;
|
|
56
61
|
confidence?: number;
|
|
57
62
|
language?: string;
|
|
63
|
+
sentiment?: VoiceTranscriptSentiment;
|
|
58
64
|
speaker?: string | number;
|
|
59
65
|
startedAtMs?: number;
|
|
60
66
|
endedAtMs?: number;
|
|
@@ -172,9 +178,16 @@ export type TTSAdapterSession = {
|
|
|
172
178
|
export declare const ttsAdapterSessionCanCancel: (session: TTSAdapterSession) => session is TTSAdapterSession & {
|
|
173
179
|
cancel: (reason?: string) => Promise<void>;
|
|
174
180
|
};
|
|
181
|
+
export type VoiceTTSProsody = {
|
|
182
|
+
emphasis?: number;
|
|
183
|
+
pitch?: number;
|
|
184
|
+
speed?: number;
|
|
185
|
+
style?: string;
|
|
186
|
+
};
|
|
175
187
|
export type TTSAdapterOpenOptions = {
|
|
176
188
|
sessionId: string;
|
|
177
189
|
lexicon?: VoiceLexiconEntry[];
|
|
190
|
+
prosody?: VoiceTTSProsody;
|
|
178
191
|
signal?: AbortSignal;
|
|
179
192
|
};
|
|
180
193
|
export type TTSAdapter<TOptions extends TTSAdapterOpenOptions = TTSAdapterOpenOptions> = {
|
|
@@ -739,6 +752,7 @@ export type CreateVoiceSessionOptions<TContext = unknown, TSession extends Voice
|
|
|
739
752
|
semanticTurnDetector?: import("./semanticTurn").VoiceSemanticTurnDetector;
|
|
740
753
|
assistantMode?: import("./assistantMode").VoiceAssistantMode;
|
|
741
754
|
modalities?: ReadonlyArray<"audio" | "text">;
|
|
755
|
+
prosody?: VoiceTTSProsody;
|
|
742
756
|
reconnect: Required<VoiceReconnectConfig>;
|
|
743
757
|
phraseHints?: VoicePhraseHint[];
|
|
744
758
|
sessionMetadata?: Record<string, unknown>;
|