Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
phsl
/
new-api
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Snippets
Members
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit
51086c3b
authored
Jun 24, 2025
by
CaIon
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
🔧
fix(model_ratio): adjust return values for gemini-2.5-pro and gemini-2.5-flash models
parent
7a4c213b
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
3 deletions
+3
-3
setting/ratio_setting/model_ratio.go
+3
-3
No files found.
setting/ratio_setting/model_ratio.go
View file @
51086c3b
...
...
@@ -501,13 +501,13 @@ func getHardcodedCompletionModelRatio(name string) (float64, bool) {
}
else
if
strings
.
HasPrefix
(
name
,
"gemini-2.0"
)
{
return
4
,
true
}
else
if
strings
.
HasPrefix
(
name
,
"gemini-2.5-pro"
)
{
// 移除preview来增加兼容性,这里假设正式版的倍率和preview一致
return
8
,
tru
e
return
8
,
fals
e
}
else
if
strings
.
HasPrefix
(
name
,
"gemini-2.5-flash"
)
{
// 处理不同的flash模型倍率
if
strings
.
HasPrefix
(
name
,
"gemini-2.5-flash-preview"
)
{
if
strings
.
HasSuffix
(
name
,
"-nothinking"
)
{
return
4
,
tru
e
return
4
,
fals
e
}
return
3.5
/
0.15
,
tru
e
return
3.5
/
0.15
,
fals
e
}
if
strings
.
HasPrefix
(
name
,
"gemini-2.5-flash-lite-preview"
)
{
return
4
,
true
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment