pub struct MultimodalInput {
pub multimodal_marker: bool,
pub text: String,
pub images: Vec<MultimodalImage>,
}Expand description
Multimodal input format for encoding images in string input
When sending images to an LLM callable, encode the input as:
{
"__multimodal__": true,
"text": "Describe this image",
"images": [
{"data": "<base64>", "mime_type": "image/jpeg"}
]
}Fields§
§multimodal_marker: bool§text: StringThe text portion of the message
images: Vec<MultimodalImage>Base64-encoded images with mime types
Implementations§
Trait Implementations§
Source§impl Clone for MultimodalInput
impl Clone for MultimodalInput
Source§fn clone(&self) -> MultimodalInput
fn clone(&self) -> MultimodalInput
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for MultimodalInput
impl Debug for MultimodalInput
Source§impl<'de> Deserialize<'de> for MultimodalInput
impl<'de> Deserialize<'de> for MultimodalInput
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
Auto Trait Implementations§
impl Freeze for MultimodalInput
impl RefUnwindSafe for MultimodalInput
impl Send for MultimodalInput
impl Sync for MultimodalInput
impl Unpin for MultimodalInput
impl UnsafeUnpin for MultimodalInput
impl UnwindSafe for MultimodalInput
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