You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: internal/apischema/openai/openai.go
+31-2Lines changed: 31 additions & 2 deletions
Original file line number
Diff line number
Diff line change
@@ -1498,8 +1498,8 @@ type Model struct {
1498
1498
OwnedBystring`json:"owned_by"`
1499
1499
}
1500
1500
1501
-
// EmbeddingRequest represents a request structure for embeddings API.
1502
-
typeEmbeddingRequeststruct {
1501
+
// EmbeddingCompletionRequest represents a request structure for embeddings API.
1502
+
typeEmbeddingCompletionRequeststruct {
1503
1503
// Input: Input text to embed, encoded as a string or array of tokens.
1504
1504
// To embed multiple inputs in a single request, pass an array of strings or array of token arrays.
1505
1505
// The input must not exceed the max input tokens for the model (8192 tokens for text-embedding-ada-002),
@@ -1525,6 +1525,35 @@ type EmbeddingRequest struct {
1525
1525
User*string`json:"user,omitempty"`
1526
1526
}
1527
1527
1528
+
// EmbeddingChatRequest represents a request structure for embeddings API. This is not a standard openai, but just extend the request to have messages/chat like completion requests
1529
+
typeEmbeddingChatRequeststruct {
1530
+
// Messages: A list of messages comprising the conversation so far.
1531
+
// Depending on the model you use, different message types (modalities) are supported,
0 commit comments