Merge pull request #1500 from antecanis8/gemini_batchembedcontents
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