mirror of
https://github.com/QuantumNous/new-api.git
synced 2026-04-18 14:37:27 +00:00
fix : Gemini embedding model only embeds the first text in a batch
This commit is contained in:
@@ -216,10 +216,14 @@ type GeminiEmbeddingRequest struct {
|
||||
OutputDimensionality int `json:"outputDimensionality,omitempty"`
|
||||
}
|
||||
|
||||
type GeminiEmbeddingResponse struct {
|
||||
Embedding ContentEmbedding `json:"embedding"`
|
||||
type GeminiBatchEmbeddingRequest struct {
|
||||
Requests []*GeminiEmbeddingRequest `json:"requests"`
|
||||
}
|
||||
|
||||
type ContentEmbedding struct {
|
||||
type GeminiEmbedding struct {
|
||||
Values []float64 `json:"values"`
|
||||
}
|
||||
|
||||
type GeminiBatchEmbeddingResponse struct {
|
||||
Embeddings []*GeminiEmbedding `json:"embeddings"`
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user