From 113ed77bb950704a4f80649421e92adfc2a74d21 Mon Sep 17 00:00:00 2001 From: Martial BE Date: Tue, 12 Mar 2024 17:57:46 +0800 Subject: [PATCH] =?UTF-8?q?=F0=9F=94=A5=20del:=20delete=20invalid=20code?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- providers/azureSpeech/speech.go | 20 -------------------- 1 file changed, 20 deletions(-) diff --git a/providers/azureSpeech/speech.go b/providers/azureSpeech/speech.go index a82990ad..bf7f11f5 100644 --- a/providers/azureSpeech/speech.go +++ b/providers/azureSpeech/speech.go @@ -31,26 +31,6 @@ func CreateSSML(text string, name string, role string) string { return fmt.Sprintf(ssmlTemplate, roleAttribute, name, text) } -func getAzureVoiceMap(modelName string) (voice, role string) { - voiceMap := map[string][]string{ - "alloy": {"zh-CN-YunxiNeural"}, - "echo": {"zh-CN-YunyangNeural"}, - "fable": {"zh-CN-YunxiNeural", "Boy"}, - "onyx": {"zh-CN-YunyeNeural"}, - "nova": {"zh-CN-XiaochenNeural"}, - "shimmer": {"zh-CN-XiaohanNeural"}, - } - - if voiceMap[modelName] != nil { - voice = voiceMap[modelName][0] - if len(voiceMap[modelName]) > 1 { - role = voiceMap[modelName][1] - } - } - - return -} - func (p *AzureSpeechProvider) GetVoiceMap() map[string][]string { voiceMap := map[string][]string{ "alloy": {"zh-CN-YunxiNeural"},