修改豆包请求日志输出

This commit is contained in:
junleea 2025-04-02 13:30:05 +08:00
parent a59ee739ac
commit b6d3d35b53
1 changed files with 2 additions and 2 deletions

View File

@ -90,8 +90,6 @@ func DouBaoV2(modelParam proto.ModelParam, imCtx *proto.IMParamContext) {
if err != nil { if err != nil {
log.Println("get doubao session history message error:", err) log.Println("get doubao session history message error:", err)
} }
messagesStr, _ := json.Marshal(messages)
log.Println("doubao messages:", string(messagesStr))
req := model.CreateChatCompletionRequest{ req := model.CreateChatCompletionRequest{
Model: modelParam.Model, Model: modelParam.Model,
@ -100,6 +98,8 @@ func DouBaoV2(modelParam proto.ModelParam, imCtx *proto.IMParamContext) {
IncludeUsage: true, IncludeUsage: true,
}, },
} }
messagesStr, _ := json.Marshal(req)
log.Println("doubao req messages:", string(messagesStr))
stream, err := doubaoClient.CreateChatCompletionStream(ctx, req) stream, err := doubaoClient.CreateChatCompletionStream(ctx, req)
if err != nil { if err != nil {