support google voice cloning (#956)

* support google voice cloning

* wip
This commit is contained in:
Hoan Luu Huu
2024-11-04 19:10:52 +07:00
committed by GitHub
parent 1efb198f72
commit e800cca961
4 changed files with 234 additions and 128 deletions

View File

@@ -336,7 +336,9 @@ module.exports = function(srf, logger) {
if (arr) {
const google_custom_voice_sid = arr[1];
const [custom_voice] = await lookupGoogleCustomVoice(google_custom_voice_sid);
if (custom_voice) {
//google voice cloning key has size 200kb, jambonz should not resolve the voice here that the app's calling
//webhook will receive big payload, tts-task should resolve the voice later.
if (!custom_voice.use_voice_cloning_key) {
app2.speech_synthesis_voice = {
reportedUsage: custom_voice.reported_usage,
model: custom_voice.model