Skip to content

Commit

Permalink
fix: add role for ChatCompletionsStreamResponseChoice.Delta
Browse files Browse the repository at this point in the history
  • Loading branch information
songquanpeng committed Feb 25, 2024
1 parent dc5b781 commit 6b27d66
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions relay/channel/openai/model.go
Original file line number Diff line number Diff line change
Expand Up @@ -121,6 +121,7 @@ type ChatCompletionsStreamResponseChoice struct {
Index int `json:"index"`
Delta struct {
Content string `json:"content"`
Role string `json:"role,omitempty"`
} `json:"delta"`
FinishReason *string `json:"finish_reason,omitempty"`
}
Expand Down

0 comments on commit 6b27d66

Please sign in to comment.