pub struct InputMessageArgs { /* private fields */ }
Expand description
Builder for InputMessage
.
Implementations§
Source§impl InputMessageArgs
impl InputMessageArgs
pub fn kind<VALUE: Into<InputMessageType>>(&mut self, value: VALUE) -> &mut Self
Sourcepub fn role<VALUE: Into<Role>>(&mut self, value: VALUE) -> &mut Self
pub fn role<VALUE: Into<Role>>(&mut self, value: VALUE) -> &mut Self
The role of the message input.
Sourcepub fn content<VALUE: Into<InputContent>>(&mut self, value: VALUE) -> &mut Self
pub fn content<VALUE: Into<InputContent>>(&mut self, value: VALUE) -> &mut Self
Text, image, or audio input to the model, used to generate a response. Can also contain previous assistant responses.
Sourcepub fn build(&self) -> Result<InputMessage, OpenAIError>
pub fn build(&self) -> Result<InputMessage, OpenAIError>
Trait Implementations§
Source§impl Clone for InputMessageArgs
impl Clone for InputMessageArgs
Source§fn clone(&self) -> InputMessageArgs
fn clone(&self) -> InputMessageArgs
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 moreAuto Trait Implementations§
impl Freeze for InputMessageArgs
impl RefUnwindSafe for InputMessageArgs
impl Send for InputMessageArgs
impl Sync for InputMessageArgs
impl Unpin for InputMessageArgs
impl UnwindSafe for InputMessageArgs
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