pub struct AssistantStreamSnapshot { /* private fields */ }Expand description
表示 Assistants 流运行时累积出的快照。
Implementations§
Source§impl AssistantStreamSnapshot
impl AssistantStreamSnapshot
Sourcepub fn thread_raw(&self) -> Option<&Value>
pub fn thread_raw(&self) -> Option<&Value>
返回最新的 thread 原始快照。
Sourcepub fn thread<T>(&self) -> Option<T>where
T: DeserializeOwned,
pub fn thread<T>(&self) -> Option<T>where
T: DeserializeOwned,
返回最新的 thread 快照。
Sourcepub fn latest_run_raw(&self) -> Option<&Value>
pub fn latest_run_raw(&self) -> Option<&Value>
返回最新 run 的原始快照。
Sourcepub fn message_raw(&self, message_id: &str) -> Option<&Value>
pub fn message_raw(&self, message_id: &str) -> Option<&Value>
返回指定 message 的原始快照。
Sourcepub fn latest_message_raw(&self) -> Option<&Value>
pub fn latest_message_raw(&self) -> Option<&Value>
返回最新 message 的原始快照。
Sourcepub fn run<T>(&self, run_id: &str) -> Option<T>where
T: DeserializeOwned,
pub fn run<T>(&self, run_id: &str) -> Option<T>where
T: DeserializeOwned,
返回指定 run 的结构化快照。
Sourcepub fn latest_run<T>(&self) -> Option<T>where
T: DeserializeOwned,
pub fn latest_run<T>(&self) -> Option<T>where
T: DeserializeOwned,
返回最新 run 的结构化快照。
Sourcepub fn message<T>(&self, message_id: &str) -> Option<T>where
T: DeserializeOwned,
pub fn message<T>(&self, message_id: &str) -> Option<T>where
T: DeserializeOwned,
返回指定 message 的结构化快照。
Sourcepub fn latest_message<T>(&self) -> Option<T>where
T: DeserializeOwned,
pub fn latest_message<T>(&self) -> Option<T>where
T: DeserializeOwned,
返回最新 message 的结构化快照。
Sourcepub fn run_step_raw(&self, step_id: &str) -> Option<&Value>
pub fn run_step_raw(&self, step_id: &str) -> Option<&Value>
返回指定 run step 的原始快照。
Sourcepub fn latest_run_step_raw(&self) -> Option<&Value>
pub fn latest_run_step_raw(&self) -> Option<&Value>
返回最新 run step 的原始快照。
Sourcepub fn run_step<T>(&self, step_id: &str) -> Option<T>where
T: DeserializeOwned,
pub fn run_step<T>(&self, step_id: &str) -> Option<T>where
T: DeserializeOwned,
返回指定 run step 的结构化快照。
Sourcepub fn latest_run_step<T>(&self) -> Option<T>where
T: DeserializeOwned,
pub fn latest_run_step<T>(&self) -> Option<T>where
T: DeserializeOwned,
返回最新 run step 的结构化快照。
Trait Implementations§
Source§impl Clone for AssistantStreamSnapshot
impl Clone for AssistantStreamSnapshot
Source§fn clone(&self) -> AssistantStreamSnapshot
fn clone(&self) -> AssistantStreamSnapshot
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 AssistantStreamSnapshot
impl Debug for AssistantStreamSnapshot
Source§impl Default for AssistantStreamSnapshot
impl Default for AssistantStreamSnapshot
Source§fn default() -> AssistantStreamSnapshot
fn default() -> AssistantStreamSnapshot
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl Freeze for AssistantStreamSnapshot
impl RefUnwindSafe for AssistantStreamSnapshot
impl Send for AssistantStreamSnapshot
impl Sync for AssistantStreamSnapshot
impl Unpin for AssistantStreamSnapshot
impl UnsafeUnpin for AssistantStreamSnapshot
impl UnwindSafe for AssistantStreamSnapshot
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