This commit is contained in:
lpf
2026-03-03 10:36:53 +08:00
parent 35b0ad1bfd
commit bd93c12edc
30 changed files with 1311 additions and 262 deletions

View File

@@ -51,7 +51,7 @@ func (p *HTTPProvider) Chat(ctx context.Context, messages []Message, tools []Too
return nil, fmt.Errorf("API base not configured")
}
logger.DebugCF("provider", "HTTP chat request", map[string]interface{}{
logger.DebugCF("provider", logger.C0133, map[string]interface{}{
"api_base": p.apiBase,
"protocol": p.protocol,
"model": model,
@@ -421,7 +421,7 @@ func (p *HTTPProvider) callChatCompletionsStream(ctx context.Context, messages [
}
body, _ := json.Marshal(map[string]interface{}{
"choices": []map[string]interface{}{{
"message": map[string]interface{}{"content": fullText.String()},
"message": map[string]interface{}{"content": fullText.String()},
"finish_reason": "stop",
}},
})