pub struct Agent { /* private fields */ }Expand description
Stable public entry point for agent execution.
Wraps an AgentRuntime and provides:
Agent::execute()— run the agent loop on a sessionAgent::storage()— access the shared storage backend
Clone is cheap (inner is Arc).
Implementations§
Source§impl Agent
impl Agent
Sourcepub fn from_runtime(runtime: Arc<AgentRuntime>) -> Self
pub fn from_runtime(runtime: Arc<AgentRuntime>) -> Self
Wrap an existing AgentRuntime in an Agent.
Sourcepub fn builder() -> AgentBuilder
pub fn builder() -> AgentBuilder
Return a new builder.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Agent
impl !RefUnwindSafe for Agent
impl Send for Agent
impl Sync for Agent
impl Unpin for Agent
impl UnsafeUnpin for Agent
impl !UnwindSafe for Agent
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