Add canary-tts to speech models (#603)

Co-authored-by: Peter Juhasz <juhasz.peter@uhusystems.com>
This commit is contained in:
pjuhasz
2023-11-24 11:34:25 +04:00
committed by GitHub
co-authored by Peter Juhasz
parent a130cfee26
commit f87909596f
+3 -2
View File
@@ -11,7 +11,8 @@ type SpeechModel string
const (
TTSModel1 SpeechModel = "tts-1"
TTsModel1HD SpeechModel = "tts-1-hd"
TTSModel1HD SpeechModel = "tts-1-hd"
TTSModelCanary SpeechModel = "canary-tts"
)
type SpeechVoice string
@@ -57,7 +58,7 @@ func contains[T comparable](s []T, e T) bool {
}
func isValidSpeechModel(model SpeechModel) bool {
return contains([]SpeechModel{TTSModel1, TTsModel1HD}, model)
return contains([]SpeechModel{TTSModel1, TTSModel1HD, TTSModelCanary}, model)
}
func isValidVoice(voice SpeechVoice) bool {