mirror of
https://github.com/BerriAI/litellm.git
synced 2026-09-19 00:01:29 +00:00
### Background The Gemini batchEmbedContents response handler hardcoded `index=0` for every embedding in the response. Any consumer relying on the OpenAI-format `index` field to match embeddings back to inputs would silently get wrong associations. ### Changes Use `enumerate` in `process_response` so each embedding gets its positional index instead of 0. ### Test Plan Added unit test asserting sequential indices and correct vector ordering for a 3-element batch response. |
||
|---|---|---|
| .. | ||
| a2a_protocol/providers/pydantic_ai_agents | ||
| integrations/helicone | ||
| litellm_core_utils | ||
| llms | ||
| proxy | ||
| test_batch_completion_models_all_responses.py | ||
| test_bedrock_extended_beta_models.py | ||
| test_bedrock_nemotron_super.py | ||
| test_no_hardcoded_secrets.py | ||
| test_proxy_auth.py | ||
| test_router_retry_backoff_headers.py | ||
| test_stream_chunk_builder_images.py | ||