pub struct ImageURL {
pub url: Option<String>,
pub detail: Option<ImageDetailLevel>,
}Expand description
Image URL structure for image prompts.
This follows OpenAI’s Chat Completion API’s image URL format.
Corresponds to ImageURL TypedDict in Python.
Fields§
§url: Option<String>Either a URL of the image or the base64 encoded image data.
detail: Option<ImageDetailLevel>Specifies the detail level of the image.
Can be auto, low, or high.
Implementations§
Trait Implementations§
Source§impl<'de> Deserialize<'de> for ImageURL
impl<'de> Deserialize<'de> for ImageURL
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
impl StructuralPartialEq for ImageURL
Auto Trait Implementations§
impl Freeze for ImageURL
impl RefUnwindSafe for ImageURL
impl Send for ImageURL
impl Sync for ImageURL
impl Unpin for ImageURL
impl UnwindSafe for ImageURL
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more