fix: improve error messaging and JSON schema handling in distributor and relay components

This commit is contained in:
CaIon
2025-07-26 12:11:20 +08:00
parent f610773455
commit 2cb7b9ae62
4 changed files with 22 additions and 16 deletions
+3
View File
@@ -175,6 +175,9 @@ func TextHelper(c *gin.Context) (newAPIError *types.NewAPIError) {
if err != nil {
return types.NewErrorWithStatusCode(err, types.ErrorCodeReadRequestBodyFailed, http.StatusBadRequest)
}
if common.DebugEnabled {
println("requestBody: ", string(body))
}
requestBody = bytes.NewBuffer(body)
} else {
convertedRequest, err := adaptor.ConvertOpenAIRequest(c, relayInfo, textRequest)