pub struct AgentContext {
pub messages: Vec<Message>,
pub is_streaming: bool,
pub metadata: HashMap<String, Value>,
pub result: Option<AgentResponse>,
pub terminate: bool,
}Expand description
Context flowing through the agent middleware pipeline.
Fields§
§messages: Vec<Message>§is_streaming: bool§metadata: HashMap<String, Value>§result: Option<AgentResponse>The run result; populated by the terminal handler or overridden here.
terminate: boolIf set to true, the pipeline stops without running further middleware.
Implementations§
Auto Trait Implementations§
impl Freeze for AgentContext
impl RefUnwindSafe for AgentContext
impl Send for AgentContext
impl Sync for AgentContext
impl Unpin for AgentContext
impl UnsafeUnpin for AgentContext
impl UnwindSafe for AgentContext
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