feat: support gpt-4o-mini-realtime-preview
This commit is contained in:
@@ -32,30 +32,34 @@ var defaultModelRatio = map[string]float64{
|
|||||||
"gpt-4-0613": 15,
|
"gpt-4-0613": 15,
|
||||||
"gpt-4-32k": 30,
|
"gpt-4-32k": 30,
|
||||||
//"gpt-4-32k-0314": 30, //deprecated
|
//"gpt-4-32k-0314": 30, //deprecated
|
||||||
"gpt-4-32k-0613": 30,
|
"gpt-4-32k-0613": 30,
|
||||||
"gpt-4-1106-preview": 5, // $10 / 1M tokens
|
"gpt-4-1106-preview": 5, // $10 / 1M tokens
|
||||||
"gpt-4-0125-preview": 5, // $10 / 1M tokens
|
"gpt-4-0125-preview": 5, // $10 / 1M tokens
|
||||||
"gpt-4-turbo-preview": 5, // $10 / 1M tokens
|
"gpt-4-turbo-preview": 5, // $10 / 1M tokens
|
||||||
"gpt-4-vision-preview": 5, // $10 / 1M tokens
|
"gpt-4-vision-preview": 5, // $10 / 1M tokens
|
||||||
"gpt-4-1106-vision-preview": 5, // $10 / 1M tokens
|
"gpt-4-1106-vision-preview": 5, // $10 / 1M tokens
|
||||||
"chatgpt-4o-latest": 2.5, // $5 / 1M tokens
|
"chatgpt-4o-latest": 2.5, // $5 / 1M tokens
|
||||||
"gpt-4o": 1.25, // $2.5 / 1M tokens
|
"gpt-4o": 1.25, // $2.5 / 1M tokens
|
||||||
"gpt-4o-audio-preview": 1.25, // $2.5 / 1M tokens
|
"gpt-4o-audio-preview": 1.25, // $2.5 / 1M tokens
|
||||||
"gpt-4o-audio-preview-2024-10-01": 1.25, // $2.5 / 1M tokens
|
"gpt-4o-audio-preview-2024-10-01": 1.25, // $2.5 / 1M tokens
|
||||||
"gpt-4o-2024-05-13": 2.5, // $5 / 1M tokens
|
"gpt-4o-2024-05-13": 2.5, // $5 / 1M tokens
|
||||||
"gpt-4o-2024-08-06": 1.25, // $2.5 / 1M tokens
|
"gpt-4o-2024-08-06": 1.25, // $2.5 / 1M tokens
|
||||||
"gpt-4o-2024-11-20": 1.25, // $2.5 / 1M tokens
|
"gpt-4o-2024-11-20": 1.25, // $2.5 / 1M tokens
|
||||||
"gpt-4o-realtime-preview": 2.5,
|
"gpt-4o-realtime-preview": 2.5,
|
||||||
"o1": 7.5,
|
"gpt-4o-realtime-preview-2024-10-01": 2.5,
|
||||||
"o1-2024-12-17": 7.5,
|
"gpt-4o-realtime-preview-2024-12-17": 2.5,
|
||||||
"o1-preview": 7.5,
|
"gpt-4o-mini-realtime-preview": 0.3,
|
||||||
"o1-preview-2024-09-12": 7.5,
|
"gpt-4o-mini-realtime-preview-2024-12-17": 0.3,
|
||||||
"o1-mini": 1.5,
|
"o1": 7.5,
|
||||||
"o1-mini-2024-09-12": 1.5,
|
"o1-2024-12-17": 7.5,
|
||||||
"gpt-4o-mini": 0.075,
|
"o1-preview": 7.5,
|
||||||
"gpt-4o-mini-2024-07-18": 0.075,
|
"o1-preview-2024-09-12": 7.5,
|
||||||
"gpt-4-turbo": 5, // $0.01 / 1K tokens
|
"o1-mini": 1.5,
|
||||||
"gpt-4-turbo-2024-04-09": 5, // $0.01 / 1K tokens
|
"o1-mini-2024-09-12": 1.5,
|
||||||
|
"gpt-4o-mini": 0.075,
|
||||||
|
"gpt-4o-mini-2024-07-18": 0.075,
|
||||||
|
"gpt-4-turbo": 5, // $0.01 / 1K tokens
|
||||||
|
"gpt-4-turbo-2024-04-09": 5, // $0.01 / 1K tokens
|
||||||
//"gpt-3.5-turbo-0301": 0.75, //deprecated
|
//"gpt-3.5-turbo-0301": 0.75, //deprecated
|
||||||
"gpt-3.5-turbo": 0.25,
|
"gpt-3.5-turbo": 0.25,
|
||||||
"gpt-3.5-turbo-0613": 0.75,
|
"gpt-3.5-turbo-0613": 0.75,
|
||||||
@@ -431,6 +435,8 @@ func GetAudioRatio(name string) float64 {
|
|||||||
return 20
|
return 20
|
||||||
} else if strings.HasPrefix(name, "gpt-4o-audio") {
|
} else if strings.HasPrefix(name, "gpt-4o-audio") {
|
||||||
return 40
|
return 40
|
||||||
|
} else if strings.HasPrefix(name, "gpt-4o-mini-realtime") {
|
||||||
|
return 10 / 0.6
|
||||||
}
|
}
|
||||||
return 20
|
return 20
|
||||||
}
|
}
|
||||||
@@ -438,6 +444,8 @@ func GetAudioRatio(name string) float64 {
|
|||||||
func GetAudioCompletionRatio(name string) float64 {
|
func GetAudioCompletionRatio(name string) float64 {
|
||||||
if strings.HasPrefix(name, "gpt-4o-realtime") {
|
if strings.HasPrefix(name, "gpt-4o-realtime") {
|
||||||
return 2
|
return 2
|
||||||
|
} else if strings.HasPrefix(name, "gpt-4o-mini-realtime") {
|
||||||
|
return 2
|
||||||
}
|
}
|
||||||
return 2
|
return 2
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -15,7 +15,8 @@ var ModelList = []string{
|
|||||||
"o1-mini", "o1-mini-2024-09-12",
|
"o1-mini", "o1-mini-2024-09-12",
|
||||||
"o1", "o1-2024-12-17",
|
"o1", "o1-2024-12-17",
|
||||||
"gpt-4o-audio-preview", "gpt-4o-audio-preview-2024-10-01",
|
"gpt-4o-audio-preview", "gpt-4o-audio-preview-2024-10-01",
|
||||||
"gpt-4o-realtime-preview", "gpt-4o-realtime-preview-2024-10-01",
|
"gpt-4o-realtime-preview", "gpt-4o-realtime-preview-2024-10-01", "gpt-4o-realtime-preview-2024-12-17",
|
||||||
|
"gpt-4o-mini-realtime-preview", "gpt-4o-mini-realtime-preview-2024-12-17",
|
||||||
"text-embedding-ada-002", "text-embedding-3-small", "text-embedding-3-large",
|
"text-embedding-ada-002", "text-embedding-3-small", "text-embedding-3-large",
|
||||||
"text-curie-001", "text-babbage-001", "text-ada-001",
|
"text-curie-001", "text-babbage-001", "text-ada-001",
|
||||||
"text-moderation-latest", "text-moderation-stable",
|
"text-moderation-latest", "text-moderation-stable",
|
||||||
|
|||||||
Reference in New Issue
Block a user