feat support Whisper TTS (#523)

* feat support openai

* update speech utils version
This commit is contained in:
Hoan Luu Huu
2023-11-09 21:51:20 +07:00
committed by GitHub
parent 31559cbb3b
commit 87632c549e
4 changed files with 326 additions and 8 deletions

View File

@@ -94,6 +94,10 @@ const speechMapper = (cred) => {
} else if ('assemblyai' === obj.vendor) {
const o = JSON.parse(decrypt(credential));
obj.api_key = o.api_key;
} else if ('whisper' === obj.vendor) {
const o = JSON.parse(decrypt(credential));
obj.api_key = o.api_key;
obj.model_id = o.model_id;
} else if (obj.vendor.startsWith('custom:')) {
const o = JSON.parse(decrypt(credential));
obj.auth_token = o.auth_token;