Skip to content

Commit 758fd13

Browse files
authored
fix: correct base64 data handling in image content conversion #3867 (#3868)
1 parent b800882 commit 758fd13

File tree

1 file changed

+1
-1
lines changed
  • livekit-agents/livekit/agents/llm/_provider_format

1 file changed

+1
-1
lines changed

livekit-agents/livekit/agents/llm/_provider_format/anthropic.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -104,7 +104,7 @@ def _to_image_content(image: llm.ImageContent) -> dict[str, Any]:
104104
"type": "image",
105105
"source": {
106106
"type": "base64",
107-
"data": f"data:{img.mime_type};base64,{b64_data}",
107+
"data": b64_data,
108108
"media_type": img.mime_type,
109109
},
110110
}

0 commit comments

Comments
 (0)