refactor(model): 优化模型网关的数据解析和任务处理逻辑
This commit is contained in:
@@ -148,10 +148,11 @@ func GetSkillUser(ctx context.Context, name string) (*SkillUserVO, error) {
|
||||
|
||||
// SendCallbackReq 发送回调的请求体
|
||||
type SendCallbackReq struct {
|
||||
TaskId string `json:"taskId"`
|
||||
Status string `json:"status"`
|
||||
EpicycleId int64 `json:"epicycleId"`
|
||||
ErrorMsg string `json:"errorMsg,omitempty"`
|
||||
TaskId string `json:"taskId"`
|
||||
Status string `json:"status"`
|
||||
EpicycleId int64 `json:"epicycleId"`
|
||||
Messages map[string]any `json:"messages,omitempty"`
|
||||
ErrorMsg string `json:"errorMsg,omitempty"`
|
||||
}
|
||||
|
||||
// SendCallback 向业务方发送回调
|
||||
@@ -165,6 +166,7 @@ func SendCallback(ctx context.Context, composeTask *entity.ComposeTask, epicycle
|
||||
TaskId: composeTask.TaskId,
|
||||
Status: composeTask.Status,
|
||||
ErrorMsg: composeTask.ErrorMessage,
|
||||
Messages: composeTask.ResultJson,
|
||||
EpicycleId: epicycleId,
|
||||
}
|
||||
// 3. 发送 POST 请求
|
||||
|
||||
Reference in New Issue
Block a user