fix: add missing fields in tool_calls (#558)
This commit is contained in:
2
chat.go
2
chat.go
@@ -71,6 +71,8 @@ type ChatCompletionMessage struct {
|
|||||||
}
|
}
|
||||||
|
|
||||||
type ToolCall struct {
|
type ToolCall struct {
|
||||||
|
// Index is not nil only in chat completion chunk object
|
||||||
|
Index *int `json:"index,omitempty"`
|
||||||
ID string `json:"id"`
|
ID string `json:"id"`
|
||||||
Type ToolType `json:"type"`
|
Type ToolType `json:"type"`
|
||||||
Function FunctionCall `json:"function"`
|
Function FunctionCall `json:"function"`
|
||||||
|
|||||||
Reference in New Issue
Block a user