litellm/tests/pass_through_unit_tests
jaideeppyne ab78459097 fix(cohere): handle multimodal inputs in token counting and guardrails
Response transformation crashed with TypeError when counting tokens for
multimodal (dict-shaped) embedding inputs, since encoding.encode() was
called directly on the dict instead of its text parts. Also removed a
dead, equally-buggy duplicate of the same loop in _transform_response.

Separately, the embeddings guardrail handler silently skipped multimodal
dict inputs instead of scanning them, letting prohibited text/image
content bypass the configured guardrail. It now extracts and scans the
text parts while leaving image parts untouched.
2026-08-13 09:01:47 +05:30
..
messages_api_structured_output fix(cohere): handle multimodal inputs in token counting and guardrails 2026-08-13 09:01:47 +05:30
base_anthropic_messages_prompt_caching_test.py fix(cohere): handle multimodal inputs in token counting and guardrails 2026-08-13 09:01:47 +05:30
base_anthropic_messages_tool_search_test.py fix(cohere): handle multimodal inputs in token counting and guardrails 2026-08-13 09:01:47 +05:30
base_anthropic_unified_messages_test.py fix(cohere): handle multimodal inputs in token counting and guardrails 2026-08-13 09:01:47 +05:30
conftest.py fix(cohere): handle multimodal inputs in token counting and guardrails 2026-08-13 09:01:47 +05:30
test_anthropic_messages_passthrough.py fix(cohere): handle multimodal inputs in token counting and guardrails 2026-08-13 09:01:47 +05:30
test_anthropic_messages_prompt_caching.py fix(cohere): handle multimodal inputs in token counting and guardrails 2026-08-13 09:01:47 +05:30
test_anthropic_messages_tool_search.py fix(cohere): handle multimodal inputs in token counting and guardrails 2026-08-13 09:01:47 +05:30
test_assemblyai_unit_tests_passthrough.py fix(cohere): handle multimodal inputs in token counting and guardrails 2026-08-13 09:01:47 +05:30
test_bedrock_anthropic_messages_test.py fix(cohere): handle multimodal inputs in token counting and guardrails 2026-08-13 09:01:47 +05:30
test_bedrock_tool_use_beta_header.py fix(cohere): handle multimodal inputs in token counting and guardrails 2026-08-13 09:01:47 +05:30
test_claude_code_marketplace.py fix(cohere): handle multimodal inputs in token counting and guardrails 2026-08-13 09:01:47 +05:30
test_context_management_polyfill.py fix(cohere): handle multimodal inputs in token counting and guardrails 2026-08-13 09:01:47 +05:30
test_custom_logger_passthrough.py fix(cohere): handle multimodal inputs in token counting and guardrails 2026-08-13 09:01:47 +05:30
test_pass_through_unit_tests.py fix(cohere): handle multimodal inputs in token counting and guardrails 2026-08-13 09:01:47 +05:30
test_passthrough_managed_ids.py fix(cohere): handle multimodal inputs in token counting and guardrails 2026-08-13 09:01:47 +05:30
test_passthrough_registry_updates.py fix(cohere): handle multimodal inputs in token counting and guardrails 2026-08-13 09:01:47 +05:30
test_unit_test_anthropic_pass_through.py fix(cohere): handle multimodal inputs in token counting and guardrails 2026-08-13 09:01:47 +05:30
test_unit_test_passthrough_router.py fix(cohere): handle multimodal inputs in token counting and guardrails 2026-08-13 09:01:47 +05:30
test_unit_test_streaming.py fix(cohere): handle multimodal inputs in token counting and guardrails 2026-08-13 09:01:47 +05:30
test_vertex_ai_anthropic_streaming_cost_injection.py fix(cohere): handle multimodal inputs in token counting and guardrails 2026-08-13 09:01:47 +05:30
test_vertex_ai_live_passthrough.py fix(cohere): handle multimodal inputs in token counting and guardrails 2026-08-13 09:01:47 +05:30
test_websearch_interception_e2e.py fix(cohere): handle multimodal inputs in token counting and guardrails 2026-08-13 09:01:47 +05:30