添加对智谱V4 API的支持

This commit is contained in:
hongsheng
2024-01-25 04:21:22 +08:00
parent 4f214c48c6
commit 31b85ded54
12 changed files with 380 additions and 4 deletions

View File

@@ -32,6 +32,8 @@ func testChannel(channel *model.Channel, request openai.ChatRequest) (err error,
fallthrough
case common.ChannelTypeZhipu:
fallthrough
case common.ChannelTypeZhipu_v4:
fallthrough
case common.ChannelTypeAli:
fallthrough
case common.ChannelType360:

View File

@@ -495,6 +495,24 @@ func init() {
Root: "chatglm_lite",
Parent: nil,
},
{
Id: "glm-4",
Object: "model",
Created: 1677649963,
OwnedBy: "zhipu_v4",
Permission: permission,
Root: "glm-4",
Parent: nil,
},
{
Id: "glm-3-turbo",
Object: "model",
Created: 1677649963,
OwnedBy: "zhipu_v4",
Permission: permission,
Root: "glm-3-turbo",
Parent: nil,
},
{
Id: "qwen-turbo",
Object: "model",