MCPcopy Index your code
hub / github.com/SkyworkAI/DeepResearchAgent / ImageURL

Class ImageURL

src/message/types.py:69–85  ·  view source on GitHub ↗

An image URL content part.

Source from the content-addressed store, hash-verified

67 return f'ContentPartVideo(video_url={repr(self.video_url)})'
68
69class ImageURL(BaseModel):
70 """An image URL content part."""
71 url: str = Field(description="Either a URL of the image or the base64 encoded image data.")
72 detail: Literal['auto', 'low', 'high'] = Field(default='auto', description="Specifies the detail level of the image.") # type: ignore
73 """Specifies the detail level of the image.
74 Learn more in the
75 [Vision guide](https://platform.openai.com/docs/guides/vision#low-or-high-fidelity-image-understanding).
76 """
77
78 # needed for Anthropic
79 media_type: SupportedImageMediaType = 'image/png'
80
81 def __str__(self) -> str:
82 return str(self.url)
83
84 def __repr__(self) -> str:
85 return f'ImageURL(url={repr(self.url)}, detail={repr(self.detail)}, media_type={repr(self.media_type)})'
86
87class ContentPartImage(BaseModel):
88 """An image content part."""

Callers 7

_analyze_image_fileMethod · 0.90
test_chatFunction · 0.90
test_messageFunction · 0.90

Calls

no outgoing calls

Tested by 2

test_chatFunction · 0.72
test_messageFunction · 0.72