diff --git a/litellm/llms/vertex_ai/gemini_embeddings/batch_embed_content_handler.py b/litellm/llms/vertex_ai/gemini_embeddings/batch_embed_content_handler.py index 38fdbd8f1b..1743122753 100644 --- a/litellm/llms/vertex_ai/gemini_embeddings/batch_embed_content_handler.py +++ b/litellm/llms/vertex_ai/gemini_embeddings/batch_embed_content_handler.py @@ -48,7 +48,7 @@ class GoogleBatchEmbeddings(VertexLLM): def _resolve_file_references( self, - input: EmbeddingInput, + input: Union[EmbeddingInput, List[str]], api_key: str, sync_handler: HTTPHandler, ) -> Dict[str, Dict[str, str]]: @@ -87,7 +87,7 @@ class GoogleBatchEmbeddings(VertexLLM): async def _async_resolve_file_references( self, - input: EmbeddingInput, + input: Union[EmbeddingInput, List[str]], api_key: str, async_handler: AsyncHTTPHandler, ) -> Dict[str, Dict[str, str]]: diff --git a/litellm/llms/vertex_ai/gemini_embeddings/batch_embed_content_transformation.py b/litellm/llms/vertex_ai/gemini_embeddings/batch_embed_content_transformation.py index a1a53a4e71..11457fc924 100644 --- a/litellm/llms/vertex_ai/gemini_embeddings/batch_embed_content_transformation.py +++ b/litellm/llms/vertex_ai/gemini_embeddings/batch_embed_content_transformation.py @@ -361,7 +361,7 @@ def process_response( has_nested = isinstance(input, list) and any(isinstance(e, list) for e in input) if _is_multimodal_input(input) or has_nested: input_list = input if isinstance(input, list) else [input] - text_elements = [] + text_elements: List[str] = [] for e in input_list: if isinstance(e, list): text_elements.extend(