feat(model): add audio ratios for new TTS models and adjust default values
This commit is contained in:
parent
75a6a0ba2b
commit
7bbb7f8114
@ -311,6 +311,10 @@ var defaultAudioCompletionRatio = map[string]float64{
|
|||||||
"gpt-4o-realtime": 2,
|
"gpt-4o-realtime": 2,
|
||||||
"gpt-4o-mini-realtime": 2,
|
"gpt-4o-mini-realtime": 2,
|
||||||
"gpt-4o-mini-tts": 1,
|
"gpt-4o-mini-tts": 1,
|
||||||
|
"tts-1": 0,
|
||||||
|
"tts-1-hd": 0,
|
||||||
|
"tts-1-1106": 0,
|
||||||
|
"tts-1-hd-1106": 0,
|
||||||
}
|
}
|
||||||
|
|
||||||
var (
|
var (
|
||||||
@ -656,7 +660,7 @@ func GetAudioRatio(name string) float64 {
|
|||||||
if ratio, ok := audioRatioMap[name]; ok {
|
if ratio, ok := audioRatioMap[name]; ok {
|
||||||
return ratio
|
return ratio
|
||||||
}
|
}
|
||||||
return 20
|
return 1
|
||||||
}
|
}
|
||||||
|
|
||||||
func GetAudioCompletionRatio(name string) float64 {
|
func GetAudioCompletionRatio(name string) float64 {
|
||||||
@ -667,7 +671,7 @@ func GetAudioCompletionRatio(name string) float64 {
|
|||||||
|
|
||||||
return ratio
|
return ratio
|
||||||
}
|
}
|
||||||
return 2
|
return 1
|
||||||
}
|
}
|
||||||
|
|
||||||
func ModelRatio2JSONString() string {
|
func ModelRatio2JSONString() string {
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user