pub enum LifecycleEvent {
AgentStarted {
agent_id: String,
task_description: String,
},
AgentCompleted {
agent_id: String,
iterations: u32,
summary: String,
},
AgentFailed {
agent_id: String,
error: String,
iterations: u32,
},
ToolBeforeExecute {
agent_id: Option<String>,
tool_name: String,
args: Value,
},
ToolAfterExecute {
agent_id: Option<String>,
tool_name: String,
success: bool,
duration_ms: u64,
},
ProviderRequest {
agent_id: Option<String>,
provider: String,
model: String,
},
ProviderResponse {
agent_id: Option<String>,
provider: String,
model: String,
input_tokens: u64,
output_tokens: u64,
duration_ms: u64,
},
ValidationStarted {
agent_id: String,
checks: Vec<String>,
},
ValidationCompleted {
agent_id: String,
passed: bool,
issues: Vec<String>,
},
}Expand description
Events emitted during framework operation.
Variants§
AgentStarted
An agent has been created and is about to start.
Fields
AgentCompleted
An agent completed its task successfully.
Fields
AgentFailed
An agent failed to complete its task.
Fields
ToolBeforeExecute
A tool is about to be executed.
Fields
ToolAfterExecute
A tool has finished executing.
Fields
ProviderRequest
A request is about to be sent to an AI provider.
Fields
ProviderResponse
A response was received from an AI provider.
Fields
ValidationStarted
Validation has started for an agent’s work.
Fields
ValidationCompleted
Validation completed for an agent’s work.
Implementations§
Trait Implementations§
Source§impl Clone for LifecycleEvent
impl Clone for LifecycleEvent
Source§fn clone(&self) -> LifecycleEvent
fn clone(&self) -> LifecycleEvent
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 LifecycleEvent
impl RefUnwindSafe for LifecycleEvent
impl Send for LifecycleEvent
impl Sync for LifecycleEvent
impl Unpin for LifecycleEvent
impl UnsafeUnpin for LifecycleEvent
impl UnwindSafe for LifecycleEvent
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