litellm/tests/unit/llms/bedrock/embed
chaznm 7f08cd7b03
fix(bedrock): accept the OpenAI SDK default encoding_format on Nova embeddings (#53755)
* fix(bedrock): accept encoding_format float and base64 on Nova embeddings

* fix(bedrock): return base64 Nova embeddings when the caller asks for base64

Older openai-node releases base64-decode every default-path embedding, so a float list became zero vectors. A base64 request now gets little-endian float32 bytes in base64, a float request keeps the list, and a non-string encoding_format takes the unsupported-param path instead of a 500.

* test(bedrock): check every Nova base64 vector keeps its input order

The base64 test now sends two inputs, so it fails if vectors are reordered or only the first is encoded. A new test keeps an upstream base64 string unchanged. Also drops the helper's docstring.

* test(bedrock): check base64 survives drop_params on Nova and an async job's placeholder is a string

---------

Co-authored-by: mateo-berri <277851410+mateo-berri@users.noreply.github.com>
2026-11-23 10:00:50 -08:00
..
__init__.py test: move tests/test_litellm/llms into tests/unit/llms (#43191) 2026-09-25 12:43:23 -07:00
test_amazon_nova_transformation.py fix(bedrock): accept the OpenAI SDK default encoding_format on Nova embeddings (#53755) 2026-11-23 10:00:50 -08:00
test_bedrock_async_invoke_embedding.py refactor(llms): expose public names for private provider helpers (#45037) 2026-10-07 08:49:25 -07:00
test_bedrock_embedding.py fix(bedrock): bill Nova embedding audio and video by the clip's length (#53307) 2026-11-21 20:01:56 +00:00
test_embedding.py test: move tests/test_litellm/llms into tests/unit/llms (#43191) 2026-09-25 12:43:23 -07:00
test_twelvelabs_marengo_3_transformation.py refactor(llms): expose public names for private provider helpers (#45037) 2026-10-07 08:49:25 -07:00