diff --git a/src/pipecat/processors/aggregators/openai_llm_context.py b/src/pipecat/processors/aggregators/openai_llm_context.py index c86045fab..f099c372d 100644 --- a/src/pipecat/processors/aggregators/openai_llm_context.py +++ b/src/pipecat/processors/aggregators/openai_llm_context.py @@ -127,6 +127,8 @@ class OpenAILLMContext: if item["type"] == "image_url": if item["image_url"]["url"].startswith("data:image/"): item["image_url"]["url"] = "data:image/..." + if "mime_type" in msg and msg["mime_type"].startswith("image/"): + msg["data"] = "..." msgs.append(msg) return json.dumps(msgs)