Struct async_openai::types::CreateThreadAndRunRequestArgs
source · pub struct CreateThreadAndRunRequestArgs { /* private fields */ }
Expand description
Builder for CreateThreadAndRunRequest
.
Implementations§
source§impl CreateThreadAndRunRequestArgs
impl CreateThreadAndRunRequestArgs
sourcepub fn assistant_id<VALUE: Into<String>>(&mut self, value: VALUE) -> &mut Self
pub fn assistant_id<VALUE: Into<String>>(&mut self, value: VALUE) -> &mut Self
The ID of the assistant to use to execute this run.
sourcepub fn thread<VALUE: Into<CreateThreadRequest>>(
&mut self,
value: VALUE
) -> &mut Self
pub fn thread<VALUE: Into<CreateThreadRequest>>( &mut self, value: VALUE ) -> &mut Self
If no thread is provided, an empty thread will be created.
sourcepub fn model<VALUE: Into<String>>(&mut self, value: VALUE) -> &mut Self
pub fn model<VALUE: Into<String>>(&mut self, value: VALUE) -> &mut Self
The ID of the Model to be used to execute this run. If a value is provided here, it will override the model associated with the assistant. If not, the model associated with the assistant will be used.
sourcepub fn instructions<VALUE: Into<String>>(&mut self, value: VALUE) -> &mut Self
pub fn instructions<VALUE: Into<String>>(&mut self, value: VALUE) -> &mut Self
Override the default system message of the assistant. This is useful for modifying the behavior on a per-run basis.
sourcepub fn tools<VALUE: Into<Vec<AssistantTools>>>(
&mut self,
value: VALUE
) -> &mut Self
pub fn tools<VALUE: Into<Vec<AssistantTools>>>( &mut self, value: VALUE ) -> &mut Self
Override the tools the assistant can use for this run. This is useful for modifying the behavior on a per-run basis.
pub fn metadata<VALUE: Into<HashMap<String, Value>>>( &mut self, value: VALUE ) -> &mut Self
sourcepub fn build(&self) -> Result<CreateThreadAndRunRequest, OpenAIError>
pub fn build(&self) -> Result<CreateThreadAndRunRequest, OpenAIError>
Trait Implementations§
source§impl Clone for CreateThreadAndRunRequestArgs
impl Clone for CreateThreadAndRunRequestArgs
source§fn clone(&self) -> CreateThreadAndRunRequestArgs
fn clone(&self) -> CreateThreadAndRunRequestArgs
Returns a copy 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 RefUnwindSafe for CreateThreadAndRunRequestArgs
impl Send for CreateThreadAndRunRequestArgs
impl Sync for CreateThreadAndRunRequestArgs
impl Unpin for CreateThreadAndRunRequestArgs
impl UnwindSafe for CreateThreadAndRunRequestArgs
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