pub enum FakeReply {
Text(String),
TextWithReasoning {
content: String,
reasoning: String,
},
ToolCalls {
content: String,
calls: Vec<ToolCall>,
},
WithUsage {
reply: Box<FakeReply>,
usage: Usage,
},
Error(ProviderError),
}Expand description
One turn of reply from the script.
Variants§
Text(String)
Plain text reply (FinishReason::Stop).
TextWithReasoning
Text + reasoning (thinking-model scenario; reasoning is carried back verbatim in the history).
ToolCalls
Text + requests to call several tools (multiple requests from the same turn stay in one message); the text may be empty.
Fields
WithUsage
Specifies this turn’s usage (default zero); wraps a base reply variant. Use it when a test needs to assert concrete token counts (e.g. the Agent’s summation); existing script styles keep working unchanged.
Error(ProviderError)
This turn fails outright; the error is returned to the caller as-is.
Implementations§
Trait Implementations§
impl Eq for FakeReply
impl StructuralPartialEq for FakeReply
Auto Trait Implementations§
impl Freeze for FakeReply
impl RefUnwindSafe for FakeReply
impl Send for FakeReply
impl Sync for FakeReply
impl Unpin for FakeReply
impl UnsafeUnpin for FakeReply
impl UnwindSafe for FakeReply
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.