refactor: message content 改成 any

refactor: message content 改成 any
This commit is contained in:
Xyfacai
2025-06-07 23:05:01 +08:00
parent a26dbf5358
commit b778cd2b23
16 changed files with 319 additions and 122 deletions

View File

@@ -278,12 +278,11 @@ func difyHandler(c *gin.Context, resp *http.Response, info *relaycommon.RelayInf
Created: common.GetTimestamp(),
Usage: difyResponse.MetaData.Usage,
}
content, _ := json.Marshal(difyResponse.Answer)
choice := dto.OpenAITextResponseChoice{
Index: 0,
Message: dto.Message{
Role: "assistant",
Content: content,
Content: difyResponse.Answer,
},
FinishReason: "stop",
}