@qvac/sdk 0.13.1 → 0.13.3

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,12 +1,28 @@
1
1
  import { z } from "zod";
2
- export declare const TTS_LANGUAGES: readonly ["en", "es", "de", "it"];
2
+ export declare const TTS_CHATTERBOX_LANGUAGES: readonly ["en", "es", "fr", "de", "it", "pt", "nl", "pl", "tr", "sv", "da", "fi", "no", "el", "ms", "sw", "ar", "ko"];
3
+ export declare const TTS_SUPERTONIC_LANGUAGES: readonly ["en", "es", "fr", "pt", "ko"];
4
+ export declare const TTS_LANGUAGES: readonly ["en", "es", "fr", "de", "it", "pt", "nl", "pl", "tr", "sv", "da", "fi", "no", "el", "ms", "sw", "ar", "ko"];
3
5
  export declare const ttsChatterboxRuntimeConfigSchema: z.ZodObject<{
4
6
  ttsEngine: z.ZodLiteral<"chatterbox">;
5
7
  language: z.ZodEnum<{
6
8
  en: "en";
9
+ ar: "ar";
7
10
  de: "de";
8
11
  es: "es";
12
+ fi: "fi";
13
+ fr: "fr";
9
14
  it: "it";
15
+ ko: "ko";
16
+ nl: "nl";
17
+ pl: "pl";
18
+ pt: "pt";
19
+ da: "da";
20
+ el: "el";
21
+ ms: "ms";
22
+ no: "no";
23
+ sv: "sv";
24
+ tr: "tr";
25
+ sw: "sw";
10
26
  }>;
11
27
  voice: z.ZodOptional<z.ZodString>;
12
28
  useGPU: z.ZodOptional<z.ZodBoolean>;
@@ -15,9 +31,10 @@ export declare const ttsSupertonicRuntimeConfigSchema: z.ZodObject<{
15
31
  ttsEngine: z.ZodLiteral<"supertonic">;
16
32
  language: z.ZodEnum<{
17
33
  en: "en";
18
- de: "de";
19
34
  es: "es";
20
- it: "it";
35
+ fr: "fr";
36
+ ko: "ko";
37
+ pt: "pt";
21
38
  }>;
22
39
  voice: z.ZodOptional<z.ZodString>;
23
40
  ttsSpeed: z.ZodOptional<z.ZodNumber>;
@@ -28,9 +45,23 @@ export declare const ttsRuntimeConfigSchema: z.ZodUnion<readonly [z.ZodObject<{
28
45
  ttsEngine: z.ZodLiteral<"chatterbox">;
29
46
  language: z.ZodEnum<{
30
47
  en: "en";
48
+ ar: "ar";
31
49
  de: "de";
32
50
  es: "es";
51
+ fi: "fi";
52
+ fr: "fr";
33
53
  it: "it";
54
+ ko: "ko";
55
+ nl: "nl";
56
+ pl: "pl";
57
+ pt: "pt";
58
+ da: "da";
59
+ el: "el";
60
+ ms: "ms";
61
+ no: "no";
62
+ sv: "sv";
63
+ tr: "tr";
64
+ sw: "sw";
34
65
  }>;
35
66
  voice: z.ZodOptional<z.ZodString>;
36
67
  useGPU: z.ZodOptional<z.ZodBoolean>;
@@ -38,9 +69,10 @@ export declare const ttsRuntimeConfigSchema: z.ZodUnion<readonly [z.ZodObject<{
38
69
  ttsEngine: z.ZodLiteral<"supertonic">;
39
70
  language: z.ZodEnum<{
40
71
  en: "en";
41
- de: "de";
42
72
  es: "es";
43
- it: "it";
73
+ fr: "fr";
74
+ ko: "ko";
75
+ pt: "pt";
44
76
  }>;
45
77
  voice: z.ZodOptional<z.ZodString>;
46
78
  ttsSpeed: z.ZodOptional<z.ZodNumber>;
@@ -51,9 +83,23 @@ export declare const ttsChatterboxLoadConfigSchema: z.ZodObject<{
51
83
  ttsEngine: z.ZodLiteral<"chatterbox">;
52
84
  language: z.ZodEnum<{
53
85
  en: "en";
86
+ ar: "ar";
54
87
  de: "de";
55
88
  es: "es";
89
+ fi: "fi";
90
+ fr: "fr";
56
91
  it: "it";
92
+ ko: "ko";
93
+ nl: "nl";
94
+ pl: "pl";
95
+ pt: "pt";
96
+ da: "da";
97
+ el: "el";
98
+ ms: "ms";
99
+ no: "no";
100
+ sv: "sv";
101
+ tr: "tr";
102
+ sw: "sw";
57
103
  }>;
58
104
  voice: z.ZodOptional<z.ZodString>;
59
105
  useGPU: z.ZodOptional<z.ZodBoolean>;
@@ -136,9 +182,10 @@ export declare const ttsSupertonicLoadConfigSchema: z.ZodObject<{
136
182
  ttsEngine: z.ZodLiteral<"supertonic">;
137
183
  language: z.ZodEnum<{
138
184
  en: "en";
139
- de: "de";
140
185
  es: "es";
141
- it: "it";
186
+ fr: "fr";
187
+ ko: "ko";
188
+ pt: "pt";
142
189
  }>;
143
190
  voice: z.ZodOptional<z.ZodString>;
144
191
  ttsSpeed: z.ZodOptional<z.ZodNumber>;
@@ -149,9 +196,23 @@ export declare const ttsLoadConfigSchema: z.ZodUnion<readonly [z.ZodObject<{
149
196
  ttsEngine: z.ZodLiteral<"chatterbox">;
150
197
  language: z.ZodEnum<{
151
198
  en: "en";
199
+ ar: "ar";
152
200
  de: "de";
153
201
  es: "es";
202
+ fi: "fi";
203
+ fr: "fr";
154
204
  it: "it";
205
+ ko: "ko";
206
+ nl: "nl";
207
+ pl: "pl";
208
+ pt: "pt";
209
+ da: "da";
210
+ el: "el";
211
+ ms: "ms";
212
+ no: "no";
213
+ sv: "sv";
214
+ tr: "tr";
215
+ sw: "sw";
155
216
  }>;
156
217
  voice: z.ZodOptional<z.ZodString>;
157
218
  useGPU: z.ZodOptional<z.ZodBoolean>;
@@ -233,9 +294,10 @@ export declare const ttsLoadConfigSchema: z.ZodUnion<readonly [z.ZodObject<{
233
294
  ttsEngine: z.ZodLiteral<"supertonic">;
234
295
  language: z.ZodEnum<{
235
296
  en: "en";
236
- de: "de";
237
297
  es: "es";
238
- it: "it";
298
+ fr: "fr";
299
+ ko: "ko";
300
+ pt: "pt";
239
301
  }>;
240
302
  voice: z.ZodOptional<z.ZodString>;
241
303
  ttsSpeed: z.ZodOptional<z.ZodNumber>;
@@ -319,6 +381,8 @@ export declare const textToSpeechStreamResponseSchema: z.ZodObject<{
319
381
  sentenceChunk: z.ZodOptional<z.ZodString>;
320
382
  }, z.core.$strip>;
321
383
  export type TtsLanguage = (typeof TTS_LANGUAGES)[number];
384
+ export type TtsChatterboxLanguage = (typeof TTS_CHATTERBOX_LANGUAGES)[number];
385
+ export type TtsSupertonicLanguage = (typeof TTS_SUPERTONIC_LANGUAGES)[number];
322
386
  export type TtsChatterboxLoadConfig = z.infer<typeof ttsChatterboxLoadConfigSchema>;
323
387
  export type TtsSupertonicLoadConfig = z.infer<typeof ttsSupertonicLoadConfigSchema>;
324
388
  export type TtsLoadConfig = z.infer<typeof ttsLoadConfigSchema>;
@@ -1,22 +1,49 @@
1
1
  import { z } from "zod";
2
2
  import { modelSrcInputSchema } from "./model-src-utils.js";
3
- // TTS supported languages based on available models
4
- export const TTS_LANGUAGES = [
3
+ // Chatterbox multilingual supported languages (18). The engines support
4
+ // different language sets, so the language enum is validated per engine.
5
+ export const TTS_CHATTERBOX_LANGUAGES = [
5
6
  "en", // English
6
7
  "es", // Spanish
8
+ "fr", // French
7
9
  "de", // German
8
10
  "it", // Italian
11
+ "pt", // Portuguese
12
+ "nl", // Dutch
13
+ "pl", // Polish
14
+ "tr", // Turkish
15
+ "sv", // Swedish
16
+ "da", // Danish
17
+ "fi", // Finnish
18
+ "no", // Norwegian
19
+ "el", // Greek
20
+ "ms", // Malay
21
+ "sw", // Swahili
22
+ "ar", // Arabic
23
+ "ko", // Korean
9
24
  ];
10
- const ttsLanguageSchema = z.enum(TTS_LANGUAGES);
25
+ // Supertonic supported languages (subset of the Chatterbox set).
26
+ export const TTS_SUPERTONIC_LANGUAGES = [
27
+ "en", // English
28
+ "es", // Spanish
29
+ "fr", // French
30
+ "pt", // Portuguese
31
+ "ko", // Korean
32
+ ];
33
+ // Union of all TTS-supported languages across engines. Kept for backwards
34
+ // compatibility; prefer the engine-specific lists when validating a config.
35
+ export const TTS_LANGUAGES = [...TTS_CHATTERBOX_LANGUAGES];
36
+ const ttsChatterboxLanguageSchema = z.enum(TTS_CHATTERBOX_LANGUAGES);
37
+ const ttsSupertonicLanguageSchema = z.enum(TTS_SUPERTONIC_LANGUAGES);
11
38
  export const ttsChatterboxRuntimeConfigSchema = z.object({
12
39
  ttsEngine: z.literal("chatterbox"),
13
- language: ttsLanguageSchema,
40
+ language: ttsChatterboxLanguageSchema,
14
41
  voice: z.string().optional(),
15
42
  useGPU: z.boolean().optional(),
16
43
  });
17
44
  export const ttsSupertonicRuntimeConfigSchema = z.object({
18
45
  ttsEngine: z.literal("supertonic"),
19
- language: ttsLanguageSchema,
46
+ language: ttsSupertonicLanguageSchema,
20
47
  voice: z.string().optional(),
21
48
  ttsSpeed: z.number().optional(),
22
49
  ttsNumInferenceSteps: z.number().optional(),
@@ -10,14 +10,14 @@ export declare const ttsPlugin: {
10
10
  }, import("zod/v4/core").$strict>]>;
11
11
  resolveConfig(cfg: Record<string, unknown>, ctx: ResolveContext): Promise<ResolveResult<{
12
12
  ttsEngine: "supertonic";
13
- language: "en" | "de" | "es" | "it";
13
+ language: "en" | "es" | "fr" | "ko" | "pt";
14
14
  voice?: string | undefined;
15
15
  ttsSpeed?: number | undefined;
16
16
  ttsNumInferenceSteps?: number | undefined;
17
17
  useGPU?: boolean | undefined;
18
18
  } | {
19
19
  ttsEngine: "chatterbox";
20
- language: "en" | "de" | "es" | "it";
20
+ language: "en" | "ar" | "de" | "es" | "fi" | "fr" | "it" | "ko" | "nl" | "pl" | "pt" | "da" | "el" | "ms" | "no" | "sv" | "tr" | "sw";
21
21
  voice?: string | undefined;
22
22
  useGPU?: boolean | undefined;
23
23
  }, string>>;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@qvac/sdk",
3
- "version": "0.13.1",
3
+ "version": "0.13.3",
4
4
  "license": "Apache-2.0",
5
5
  "repository": {
6
6
  "type": "git",
@@ -208,7 +208,7 @@
208
208
  "dependencies": {
209
209
  "@qvac/bci-whispercpp": "^0.2.0",
210
210
  "@qvac/classification-ggml": "^0.3.1",
211
- "@qvac/decoder-audio": "^0.4.0",
211
+ "@qvac/decoder-audio": "^0.5.0",
212
212
  "@qvac/diffusion-cpp": "^0.11.2",
213
213
  "@qvac/embed-llamacpp": "^0.19.1",
214
214
  "@qvac/error": "^0.1.1",
@@ -216,7 +216,7 @@
216
216
  "@qvac/llm-llamacpp": "^0.24.0",
217
217
  "@qvac/logging": "^0.1.0",
218
218
  "@qvac/ocr-onnx": "^0.6.0",
219
- "@qvac/rag": "^0.6.2",
219
+ "@qvac/rag": "^0.6.4",
220
220
  "@qvac/registry-client": "^0.6.0",
221
221
  "@qvac/transcription-parakeet": "^0.7.1",
222
222
  "@qvac/transcription-whispercpp": "^0.9.0",