Procházet zdrojové kódy

fix: 修复ollamaChatHandler中ReasoningContent字段的赋值逻辑

somnifex před 6 měsíci
rodič
revize
1dd78b83b7
1 změnil soubory, kde provedl 1 přidání a 1 odebrání
  1. 1 1
      relay/channel/ollama/stream.go

+ 1 - 1
relay/channel/ollama/stream.go

@@ -189,7 +189,7 @@ func ollamaChatHandler(c *gin.Context, info *relaycommon.RelayInfo, resp *http.R
     if finishReason == "" { finishReason = "stop" }
 
     msg := dto.Message{Role: "assistant", Content: contentPtr(content)}
-    if rc := reasoningBuilder.String(); rc != "" { msg.ReasoningContent = &rc }
+    if rc := reasoningBuilder.String(); rc != "" { msg.ReasoningContent = rc }
     full := dto.OpenAITextResponse{
         Id:      common.GetUUID(),
         Model:   model,