渠道模型列表与测试端点,修复探测无配额误判
This commit is contained in:
@@ -451,6 +451,36 @@
|
||||
}
|
||||
}
|
||||
},
|
||||
"/api/v1/ai-channels/{id}/models": {
|
||||
"get": {
|
||||
"security": [
|
||||
{
|
||||
"BearerAuth": []
|
||||
}
|
||||
],
|
||||
"tags": [
|
||||
"AI 管理"
|
||||
],
|
||||
"summary": "渠道模型缓存列表",
|
||||
"parameters": [
|
||||
{
|
||||
"type": "integer",
|
||||
"description": "渠道 ID",
|
||||
"name": "id",
|
||||
"in": "path",
|
||||
"required": true
|
||||
}
|
||||
],
|
||||
"responses": {
|
||||
"200": {
|
||||
"description": "OK",
|
||||
"schema": {
|
||||
"$ref": "#/definitions/internal_api.itemsResponse-oci-portal_internal_model_AiModelCache"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"/api/v1/ai-channels/{id}/probe": {
|
||||
"post": {
|
||||
"security": [
|
||||
@@ -511,6 +541,51 @@
|
||||
}
|
||||
}
|
||||
},
|
||||
"/api/v1/ai-channels/{id}/test-model": {
|
||||
"post": {
|
||||
"security": [
|
||||
{
|
||||
"BearerAuth": []
|
||||
}
|
||||
],
|
||||
"tags": [
|
||||
"AI 管理"
|
||||
],
|
||||
"summary": "测试渠道模型(max_tokens=16 试调;通过即设为探测验证模型并按需置渠道可用)",
|
||||
"parameters": [
|
||||
{
|
||||
"type": "integer",
|
||||
"description": "渠道 ID",
|
||||
"name": "id",
|
||||
"in": "path",
|
||||
"required": true
|
||||
},
|
||||
{
|
||||
"description": "模型名",
|
||||
"name": "body",
|
||||
"in": "body",
|
||||
"required": true,
|
||||
"schema": {
|
||||
"$ref": "#/definitions/internal_api.testChannelModelRequest"
|
||||
}
|
||||
}
|
||||
],
|
||||
"responses": {
|
||||
"200": {
|
||||
"description": "OK",
|
||||
"schema": {
|
||||
"$ref": "#/definitions/oci-portal_internal_model.AiChannel"
|
||||
}
|
||||
},
|
||||
"502": {
|
||||
"description": "试调未通过",
|
||||
"schema": {
|
||||
"$ref": "#/definitions/internal_api.errorResponse"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"/api/v1/ai-content-logs": {
|
||||
"get": {
|
||||
"security": [
|
||||
@@ -6725,6 +6800,17 @@
|
||||
}
|
||||
}
|
||||
},
|
||||
"internal_api.testChannelModelRequest": {
|
||||
"type": "object",
|
||||
"required": [
|
||||
"model"
|
||||
],
|
||||
"properties": {
|
||||
"model": {
|
||||
"type": "string"
|
||||
}
|
||||
}
|
||||
},
|
||||
"internal_api.tokenResponse": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
@@ -7914,6 +8000,10 @@
|
||||
"lastProbeAt": {
|
||||
"type": "string"
|
||||
},
|
||||
"modelCount": {
|
||||
"description": "ModelCount 是渠道模型缓存计数,列表查询回填,不落库",
|
||||
"type": "integer"
|
||||
},
|
||||
"name": {
|
||||
"type": "string"
|
||||
},
|
||||
@@ -7926,6 +8016,10 @@
|
||||
"probeError": {
|
||||
"type": "string"
|
||||
},
|
||||
"probeModel": {
|
||||
"description": "ProbeModel 是用户测试通过后固定的探测验证模型名;探测时置于候选首位",
|
||||
"type": "string"
|
||||
},
|
||||
"probeStatus": {
|
||||
"description": "ok / no_service / no_quota / error",
|
||||
"type": "string"
|
||||
|
||||
Reference in New Issue
Block a user