mirror of
https://github.com/BerriAI/litellm.git
synced 2026-10-06 02:48:13 +00:00
The SageMaker embedding handler was not using _load_credentials(), which meant aws_role_name and aws_session_name parameters were ignored. This prevented cross-account role assumption for embeddings while it worked for completions. Changes: - Replace direct boto3 client creation with _load_credentials() call - Create boto3.Session with assumed credentials - Add comprehensive unit tests for role assumption This aligns the embedding handler behavior with the completion handler, which already supports role assumption via the BaseAWSLLM.get_credentials() method. Fixes cross-account SageMaker embedding access where users need to assume a role in another account to invoke endpoints. |
||
|---|---|---|
| .. | ||
| test_sagemaker_common_utils.py | ||
| test_sagemaker_embedding_role_assumption.py | ||
| test_sagemaker_embedding_voyage.py | ||