pub struct BasicAgent {
pub objective: String,
pub position: String,
pub state: AgentState,
pub memory: Vec<Message>,
}
Expand description
Represents a basic agent with attributes like its objective, position, state, and memory.
§Fields
objective
: The main goal or purpose of the agent.position
: The agent’s role or title in the workflow.state
: The current state of the agent in its workflow.memory
: A log of messages or information the agent retains during its operation.
Fields§
§objective: String
§position: String
§state: AgentState
§memory: Vec<Message>
Trait Implementations§
source§impl BasicTraits for BasicAgent
impl BasicTraits for BasicAgent
source§fn update_state(&mut self, new_state: AgentState)
fn update_state(&mut self, new_state: AgentState)
source§fn get_objective(&self) -> &String
fn get_objective(&self) -> &String
source§fn get_position(&self) -> &String
fn get_position(&self) -> &String
source§fn get_state(&self) -> &AgentState
fn get_state(&self) -> &AgentState
Auto Trait Implementations§
impl Freeze for BasicAgent
impl RefUnwindSafe for BasicAgent
impl Send for BasicAgent
impl Sync for BasicAgent
impl Unpin for BasicAgent
impl UnwindSafe for BasicAgent
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