mirror of
https://github.com/songquanpeng/one-api.git
synced 2025-11-13 03:43:44 +08:00
refactor: add GetRatio to Adaptor
This commit is contained in:
@@ -1,27 +1,18 @@
|
||||
package groq
|
||||
|
||||
// https://console.groq.com/docs/models
|
||||
import "github.com/songquanpeng/one-api/relay/billing/ratio"
|
||||
|
||||
var ModelList = []string{
|
||||
"gemma-7b-it",
|
||||
"gemma2-9b-it",
|
||||
"llama-3.1-70b-versatile",
|
||||
"llama-3.1-8b-instant",
|
||||
"llama-3.2-11b-text-preview",
|
||||
"llama-3.2-11b-vision-preview",
|
||||
"llama-3.2-1b-preview",
|
||||
"llama-3.2-3b-preview",
|
||||
"llama-3.2-11b-vision-preview",
|
||||
"llama-3.2-90b-text-preview",
|
||||
"llama-3.2-90b-vision-preview",
|
||||
"llama-guard-3-8b",
|
||||
"llama3-70b-8192",
|
||||
"llama3-8b-8192",
|
||||
"llama3-groq-70b-8192-tool-use-preview",
|
||||
"llama3-groq-8b-8192-tool-use-preview",
|
||||
"llava-v1.5-7b-4096-preview",
|
||||
"mixtral-8x7b-32768",
|
||||
"distil-whisper-large-v3-en",
|
||||
"whisper-large-v3",
|
||||
"whisper-large-v3-turbo",
|
||||
// https://groq.com/pricing/
|
||||
// https://console.groq.com/docs/models
|
||||
var RatioMap = map[string]ratio.Ratio{
|
||||
"distil-whisper-large-v3-en": {Input: 0.02 / 3600 * 20 * ratio.USD, Output: 0},
|
||||
"gemma2-9b-it": {Input: 0.20 * ratio.MILLI_USD, Output: 0.20 * ratio.MILLI_USD},
|
||||
"llama-3.3-70b-versatile": {Input: 0.59 * ratio.MILLI_USD, Output: 0.79 * ratio.MILLI_USD},
|
||||
"llama-3.1-8b-instant": {Input: 0.05 * ratio.MILLI_USD, Output: 0.08 * ratio.MILLI_USD},
|
||||
"llama-guard-3-8b": {Input: 0.20 * ratio.MILLI_USD, Output: 0.20 * ratio.MILLI_USD},
|
||||
"llama3-70b-8192": {Input: 0.59 * ratio.MILLI_USD, Output: 0.79 * ratio.MILLI_USD},
|
||||
"llama3-8b-8192": {Input: 0.05 * ratio.MILLI_USD, Output: 0.08 * ratio.MILLI_USD},
|
||||
"mixtral-8x7b-32768": {Input: 0.24 * ratio.MILLI_USD, Output: 0.24 * ratio.MILLI_USD},
|
||||
"whisper-large-v3": {Input: 0.111 / 3600 * 20 * ratio.USD, Output: 0},
|
||||
"whisper-large-v3-turbo": {Input: 0.04 / 3600 * 20 * ratio.USD, Output: 0},
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user