Merge pull request #941 from pyrater/staging

Added stop to lip sync when user stops TTS early
This commit is contained in:
Cohee 2023-08-15 13:38:18 +03:00 committed by GitHub
commit 6e0a50b71a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 4 additions and 0 deletions

View File

@ -29,6 +29,9 @@
},
"vits": {
"id": "tts_models/en/ljspeech/vits"
},
"speedy-speech": {
"id": "tts_models/en/ljspeech/speedy-speech"
}
},
"vctk": {

View File

@ -327,6 +327,7 @@ function onAudioControlClicked() {
// Not pausing, doing a full stop to anything TTS is doing. Better UX as pause is not as useful
if (!audioElement.paused || isTtsProcessing()) {
resetTtsPlayback()
talkingAnimation(false);
} else {
// Default play behavior if not processing or playing is to play the last message.
ttsJobQueue.push(context.chat[context.chat.length - 1])