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
fix(anthropic-bridge): add cast-ok reason for assistant content payload cast
shivam08277000ac70
diff --git a/litellm/llms/anthropic/experimental_pass_through/adapters/transformation.py b/litellm/llms/anthropic/experimental_pass_through/adapters/transformation.pyindex 6b47b010cc6..76c56f6ed46 100644--- a/litellm/llms/anthropic/experimental_pass_through/adapters/transformation.py+++ b/litellm/llms/anthropic/experimental_pass_through/adapters/transformation.py@@ -506,7 +506,7 @@ class LiteLLMAnthropicMessagesAdapter:if isinstance(m.get("content"), str):assistant_message_str = str(m.get("content", ""))elif isinstance(m.get("content"), list):- for content in cast(list, m.get("content", [])):+ for content in cast(list, m.get("content", [])): # cast-ok: untrusted client payloadif isinstance(content, str):assistant_message_str = str(content)elif isinstance(content, dict):