feat: Integrate Aliyun TTS backend with dynamic speaker validation and listing, and adjust toast notification position.
Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
This commit is contained in:
@@ -387,14 +387,16 @@ class AliyunTTSBackend(TTSBackend):
|
||||
@staticmethod
|
||||
def _map_speaker(local_speaker: str) -> str:
|
||||
mapping = {
|
||||
"Vivian": "Cherry",
|
||||
"Serena": "Lili",
|
||||
"Uncle_Fu": "Longxiaochun",
|
||||
"Dylan": "Longxiaochun",
|
||||
"Ono_Anna": "Ono Anna",
|
||||
"Female": "Cherry",
|
||||
"Male": "Longxiaochun"
|
||||
"Male": "Ethan"
|
||||
}
|
||||
return mapping.get(local_speaker, "Cherry")
|
||||
|
||||
mapped = mapping.get(local_speaker)
|
||||
if mapped:
|
||||
return mapped
|
||||
|
||||
return local_speaker
|
||||
|
||||
|
||||
class TTSServiceFactory:
|
||||
|
||||
Reference in New Issue
Block a user