mirror of
https://github.com/songquanpeng/one-api.git
synced 2025-11-09 02:03:42 +08:00
fix: add model to response (close #1362)
This commit is contained in:
@@ -53,6 +53,7 @@ func responseOllama2OpenAI(response *ChatResponse) *openai.TextResponse {
|
|||||||
}
|
}
|
||||||
fullTextResponse := openai.TextResponse{
|
fullTextResponse := openai.TextResponse{
|
||||||
Id: fmt.Sprintf("chatcmpl-%s", random.GetUUID()),
|
Id: fmt.Sprintf("chatcmpl-%s", random.GetUUID()),
|
||||||
|
Model: response.Model,
|
||||||
Object: "chat.completion",
|
Object: "chat.completion",
|
||||||
Created: helper.GetTimestamp(),
|
Created: helper.GetTimestamp(),
|
||||||
Choices: []openai.TextResponseChoice{choice},
|
Choices: []openai.TextResponseChoice{choice},
|
||||||
|
|||||||
Reference in New Issue
Block a user