feat: add new GPT-4.5 preview model ratios

This commit is contained in:
1808837298@qq.com
2025-02-28 19:17:15 +08:00
parent cfd3f6c073
commit d6fd50e382
11 changed files with 61 additions and 36 deletions

View File

@@ -146,7 +146,10 @@ func testChannel(channel *model.Channel, testModel string) (err error, openAIErr
return err, nil
}
modelPrice, usePrice := common.GetModelPrice(testModel, false)
modelRatio := common.GetModelRatio(testModel)
modelRatio, success := common.GetModelRatio(testModel)
if !success {
return fmt.Errorf("模型 %s 倍率未设置", testModel), nil
}
completionRatio := common.GetCompletionRatio(testModel)
ratio := modelRatio
quota := 0