mirror of
https://github.com/BerriAI/litellm.git
synced 2026-10-10 03:28:53 +00:00
style(anthropic): keep identity-strip rewrite ruff-format clean
This commit is contained in:
parent
defee9ad13
commit
d03238136c
1 changed files with 3 additions and 2 deletions
|
|
@ -163,9 +163,10 @@ class AnthropicMessagesConfig(BaseAnthropicMessagesConfig):
|
|||
continue
|
||||
# Only copy the block when the text changed.
|
||||
if stripped_text == text:
|
||||
filtered_list.append(content_block)
|
||||
next_block = content_block
|
||||
else:
|
||||
filtered_list.append({**content_block, "text": stripped_text}) # mutable-ok: API message payload
|
||||
next_block = {**content_block, "text": stripped_text} # mutable-ok: API message payload
|
||||
filtered_list.append(next_block)
|
||||
else:
|
||||
# Keep non-dict items as-is
|
||||
filtered_list.append(content_block)
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue