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
@@ -1493,8 +1493,8 @@ type Model struct {
1493
1493
OwnedBystring`json:"owned_by"`
1494
1494
}
1495
1495
1496
-
// EmbeddingRequest represents a request structure for embeddings API.
1497
-
typeEmbeddingRequeststruct {
1496
+
// EmbeddingCompletionRequest represents a request structure for embeddings API.
1497
+
typeEmbeddingCompletionRequeststruct {
1498
1498
// Input: Input text to embed, encoded as a string or array of tokens.
1499
1499
// To embed multiple inputs in a single request, pass an array of strings or array of token arrays.
1500
1500
// The input must not exceed the max input tokens for the model (8192 tokens for text-embedding-ada-002),
@@ -1520,6 +1520,35 @@ type EmbeddingRequest struct {
1520
1520
User*string`json:"user,omitempty"`
1521
1521
}
1522
1522
1523
+
// 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
1524
+
typeEmbeddingChatRequeststruct {
1525
+
// Messages: A list of messages comprising the conversation so far.
1526
+
// Depending on the model you use, different message types (modalities) are supported,
0 commit comments