The fastest, litest AI Gateway. Rust core with Python SDK. Call 100+ LLM APIs in OpenAI (or native) format with cost tracking, guardrails, load balancing, and logging [Bedrock, Azure, OpenAI, Anthropic, OpenAI, VertexAI, vLLM, Nvidia NIM]
Python ai-gatewayanthropicazure-openaibedrockgatewaylangchainlitellmllmllm-gatewayllmopsmcp-gatewayopenaiopenai-proxyrustrust-aivertex-ai
test bedrock embedding tests marengo
Ishaan Jaffer7a41c0952995
diff --git a/litellm/llms/bedrock/embed/twelvelabs_marengo_transformation.py b/litellm/llms/bedrock/embed/twelvelabs_marengo_transformation.pyindex 0d25440cd72..ecbe0278995 100644--- a/litellm/llms/bedrock/embed/twelvelabs_marengo_transformation.py+++ b/litellm/llms/bedrock/embed/twelvelabs_marengo_transformation.py@@ -89,10 +89,8 @@ class TwelveLabsMarengoEmbeddingConfig:- Audio inputs (async-invoke only)- S3 URLs for all media types (async-invoke only)"""- if inference_params.get("inputType"):- input_type = inference_params["inputType"]- else:- raise ValueError("input_type is required")+ # Get input_type or default to "text"+ input_type = inference_params.get("inputType") or inference_params.get("input_type") or "text"# Validate that async-invoke is used for video/audioif input_type in ["video", "audio"] and not async_invoke_route:@@ -136,6 +134,7 @@ class TwelveLabsMarengoEmbeddingConfig:for k, v in inference_params.items():if k not in ["inputType",+ "input_type", # Exclude both camelCase and snake_case"inputText","mediaSource","bucketOwner", # Don't include bucketOwner in the requestdiff --git a/tests/llm_translation/test_bedrock_embedding.py b/tests/llm_translation/test_bedrock_embedding.pyindex 0a4e24a82f3..88918674aaa 100644--- a/tests/llm_translation/test_bedrock_embedding.py+++ b/tests/llm_translation/test_bedrock_embedding.py@@ -140,7 +140,8 @@ def test_e2e_bedrock_embedding_image_twelvelabs_marengo():response = litellm.embedding(model="bedrock/us.twelvelabs.marengo-embed-2-7-v1:0",input=[duck_img_base64],- aws_region_name="us-east-1"+ aws_region_name="us-east-1",+ input_type="image")# Validate response structure