mirror of
https://github.com/router-for-me/CLIProxyAPI.git
synced 2026-02-03 13:00:52 +08:00
feat(registry): Add display names and descriptions for iFlow models
This commit is contained in:
@@ -3,10 +3,7 @@
|
|||||||
// when registering their supported models.
|
// when registering their supported models.
|
||||||
package registry
|
package registry
|
||||||
|
|
||||||
import (
|
import "time"
|
||||||
"strings"
|
|
||||||
"time"
|
|
||||||
)
|
|
||||||
|
|
||||||
// GetClaudeModels returns the standard Claude model definitions
|
// GetClaudeModels returns the standard Claude model definitions
|
||||||
func GetClaudeModels() []*ModelInfo {
|
func GetClaudeModels() []*ModelInfo {
|
||||||
@@ -327,36 +324,42 @@ func GetQwenModels() []*ModelInfo {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// GetIFlowModels returns supported models for iFlow OAuth accounts.
|
// GetIFlowModels returns supported models for iFlow OAuth accounts.
|
||||||
|
|
||||||
func GetIFlowModels() []*ModelInfo {
|
func GetIFlowModels() []*ModelInfo {
|
||||||
created := time.Now().Unix()
|
created := time.Now().Unix()
|
||||||
entries := []string{
|
entries := []struct {
|
||||||
"tstars2.0",
|
ID string
|
||||||
"qwen3-coder-plus",
|
DisplayName string
|
||||||
"qwen3-coder",
|
Description string
|
||||||
"qwen3-max",
|
}{
|
||||||
"qwen3-vl-plus",
|
{ID: "tstars2.0", DisplayName: "TStars-2.0", Description: "iFlow TStars-2.0 multimodal assistant"},
|
||||||
"qwen3-max-preview",
|
{ID: "qwen3-coder-plus", DisplayName: "Qwen3-Coder-Plus", Description: "Qwen3 Coder Plus code generation"},
|
||||||
"kimi-k2-0905",
|
{ID: "qwen3-coder", DisplayName: "Qwen3-Coder-480B-A35B", Description: "Qwen3 Coder 480B A35B"},
|
||||||
"glm-4.5",
|
{ID: "qwen3-max", DisplayName: "Qwen3-Max", Description: "Qwen3 flagship model"},
|
||||||
"kimi-k2",
|
{ID: "qwen3-vl-plus", DisplayName: "Qwen3-VL-Plus", Description: "Qwen3 multimodal vision-language"},
|
||||||
"deepseek-v3.2",
|
{ID: "qwen3-max-preview", DisplayName: "Qwen3-Max-Preview", Description: "Qwen3 Max preview build"},
|
||||||
"deepseek-v3.1",
|
{ID: "kimi-k2-0905", DisplayName: "Kimi-K2-Instruct-0905", Description: "Moonshot Kimi K2 instruct 0905"},
|
||||||
"deepseek-r1",
|
{ID: "glm-4.5", DisplayName: "GLM-4.5", Description: "Zhipu GLM 4.5 general model"},
|
||||||
"deepseek-v3",
|
{ID: "kimi-k2", DisplayName: "Kimi-K2", Description: "Moonshot Kimi K2 general model"},
|
||||||
"qwen3-32b",
|
{ID: "deepseek-v3.2", DisplayName: "DeepSeek-V3.2-Exp", Description: "DeepSeek V3.2 experimental"},
|
||||||
"qwen3-235b-a22b-thinking-2507",
|
{ID: "deepseek-v3.1", DisplayName: "DeepSeek-V3.1-Terminus", Description: "DeepSeek V3.1 Terminus"},
|
||||||
"qwen3-235b-a22b-instruct",
|
{ID: "deepseek-r1", DisplayName: "DeepSeek-R1", Description: "DeepSeek reasoning model R1"},
|
||||||
"qwen3-235b",
|
{ID: "deepseek-v3", DisplayName: "DeepSeek-V3-671B", Description: "DeepSeek V3 671B"},
|
||||||
|
{ID: "qwen3-32b", DisplayName: "Qwen3-32B", Description: "Qwen3 32B"},
|
||||||
|
{ID: "qwen3-235b-a22b-thinking-2507", DisplayName: "Qwen3-235B-A22B-Thinking", Description: "Qwen3 235B A22B Thinking (2507)"},
|
||||||
|
{ID: "qwen3-235b-a22b-instruct", DisplayName: "Qwen3-235B-A22B-Instruct", Description: "Qwen3 235B A22B Instruct"},
|
||||||
|
{ID: "qwen3-235b", DisplayName: "Qwen3-235B-A22B", Description: "Qwen3 235B A22B"},
|
||||||
}
|
}
|
||||||
models := make([]*ModelInfo, 0, len(entries))
|
models := make([]*ModelInfo, 0, len(entries))
|
||||||
for _, id := range entries {
|
for _, entry := range entries {
|
||||||
models = append(models, &ModelInfo{
|
models = append(models, &ModelInfo{
|
||||||
ID: id,
|
ID: entry.ID,
|
||||||
Object: "model",
|
Object: "model",
|
||||||
Created: created,
|
Created: created,
|
||||||
OwnedBy: "iflow",
|
OwnedBy: "iflow",
|
||||||
Type: "iflow",
|
Type: "iflow",
|
||||||
DisplayName: strings.ToUpper(id),
|
DisplayName: entry.DisplayName,
|
||||||
|
Description: entry.Description,
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
return models
|
return models
|
||||||
|
|||||||
Reference in New Issue
Block a user