Update main.ts
Browse files
main.ts
CHANGED
|
@@ -17,13 +17,10 @@ async function fetchVoiceList() {
|
|
| 17 |
|
| 18 |
async function synthesizeSpeech(model: string, voice: string, text: string) {
|
| 19 |
let voiceName;
|
| 20 |
-
let rate = 0;
|
| 21 |
-
let pitch = 0;
|
| 22 |
|
| 23 |
if (model.includes("tts")) {
|
| 24 |
-
rate = 0.1;
|
| 25 |
-
pitch = -0.1;
|
| 26 |
-
|
| 27 |
switch (voice) {
|
| 28 |
case "alloy":
|
| 29 |
voiceName = "zh-CN-XiaoyiNeural";
|
|
|
|
| 17 |
|
| 18 |
async function synthesizeSpeech(model: string, voice: string, text: string) {
|
| 19 |
let voiceName;
|
| 20 |
+
let rate = -0.1;
|
| 21 |
+
let pitch = 0.1;
|
| 22 |
|
| 23 |
if (model.includes("tts")) {
|
|
|
|
|
|
|
|
|
|
| 24 |
switch (voice) {
|
| 25 |
case "alloy":
|
| 26 |
voiceName = "zh-CN-XiaoyiNeural";
|