Skip to content

Commit 6d066bb

Browse files
authored
Support Attachments in MessageRequest (#890)
* add attachments in MessageRequest * Move tools const to message * remove const, just use assistanttool const
1 parent f5e6e0e commit 6d066bb

File tree

1 file changed

+5
-4
lines changed

1 file changed

+5
-4
lines changed

messages.go

+5-4
Original file line numberDiff line numberDiff line change
@@ -52,10 +52,11 @@ type ImageFile struct {
5252
}
5353

5454
type MessageRequest struct {
55-
Role string `json:"role"`
56-
Content string `json:"content"`
57-
FileIds []string `json:"file_ids,omitempty"` //nolint:revive // backwards-compatibility
58-
Metadata map[string]any `json:"metadata,omitempty"`
55+
Role string `json:"role"`
56+
Content string `json:"content"`
57+
FileIds []string `json:"file_ids,omitempty"` //nolint:revive // backwards-compatibility
58+
Metadata map[string]any `json:"metadata,omitempty"`
59+
Attachments []ThreadAttachment `json:"attachments,omitempty"`
5960
}
6061

6162
type MessageFile struct {

0 commit comments

Comments
 (0)