mirror of
https://github.com/songquanpeng/one-api.git
synced 2025-11-17 13:43:42 +08:00
✨ feat: support Groq (#107)
This commit is contained in:
@@ -197,6 +197,7 @@ const (
|
||||
ChannelTypeDeepseek = 28
|
||||
ChannelTypeMoonshot = 29
|
||||
ChannelTypeMistral = 30
|
||||
ChannelTypeGroq = 31
|
||||
)
|
||||
|
||||
var ChannelBaseURLs = []string{
|
||||
@@ -231,6 +232,7 @@ var ChannelBaseURLs = []string{
|
||||
"https://api.deepseek.com", //28
|
||||
"https://api.moonshot.cn", //29
|
||||
"https://api.mistral.ai", //30
|
||||
"https://api.groq.com/openai", //30
|
||||
}
|
||||
|
||||
const (
|
||||
|
||||
@@ -183,6 +183,14 @@ func init() {
|
||||
"mistral-medium-latest": {[]float64{1.35, 4.05}, ChannelTypeMistral}, // 2.7$ / 1M tokens 8.1$ / 1M tokens 0.0027$ / 1k tokens
|
||||
"mistral-large-latest": {[]float64{4, 12}, ChannelTypeMistral}, // 8$ / 1M tokens 24$ / 1M tokens 0.008$ / 1k tokens
|
||||
"mistral-embed": {[]float64{0.05, 0.05}, ChannelTypeMistral}, // 0.1$ / 1M tokens 0.1$ / 1M tokens 0.0001$ / 1k tokens
|
||||
|
||||
// $0.70/$0.80 /1M Tokens 0.0007$ / 1k tokens
|
||||
"llama2-70b-4096": {[]float64{0.35, 0.4}, ChannelTypeGroq},
|
||||
// $0.10/$0.10 /1M Tokens 0.0001$ / 1k tokens
|
||||
"llama2-7b-2048": {[]float64{0.05, 0.05}, ChannelTypeGroq},
|
||||
"gemma-7b-it": {[]float64{0.05, 0.05}, ChannelTypeGroq},
|
||||
// $0.27/$0.27 /1M Tokens 0.00027$ / 1k tokens
|
||||
"mixtral-8x7b-32768": {[]float64{0.135, 0.135}, ChannelTypeGroq},
|
||||
}
|
||||
|
||||
ModelRatio = make(map[string][]float64)
|
||||
|
||||
Reference in New Issue
Block a user