mirror of
https://github.com/BerriAI/litellm.git
synced 2026-09-07 08:26:10 +00:00
fix: litellm_core_utils/prompt_templates/factory.py:3431
This commit is contained in:
parent
7329fa8e7a
commit
b85f1f2e6d
2 changed files with 2 additions and 2 deletions
|
|
@ -3427,7 +3427,7 @@ def _deduplicate_bedrock_content_blocks(
|
|||
deduplicated: List[BedrockContentBlock] = []
|
||||
for block in blocks:
|
||||
keyed = block.get(block_key)
|
||||
if keyed is not None:
|
||||
if keyed is not None and isinstance(keyed, dict):
|
||||
block_id = keyed.get(id_key)
|
||||
if block_id:
|
||||
if block_id in seen_ids:
|
||||
|
|
|
|||
|
|
@ -74,7 +74,7 @@ class AnthropicMessagesHandler(BaseTranslation):
|
|||
if messages is None:
|
||||
return data
|
||||
|
||||
chat_completion_compatible_request = (
|
||||
chat_completion_compatible_request, tool_name_mapping = (
|
||||
LiteLLMAnthropicMessagesAdapter().translate_anthropic_to_openai(
|
||||
anthropic_message_request=cast(AnthropicMessagesRequest, data)
|
||||
)
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue