pub struct LlmAgentConfig {
pub system_prompt: String,
pub tools: Vec<Arc<dyn Tool>>,
pub lens: Lens,
pub llm_config: LlmConfig,
pub experience_extractor: Option<Arc<dyn ExperienceExtractor>>,
pub refresh_every_n_tool_calls: Option<usize>,
}Expand description
Configuration for an LLM-powered agent.
Clone is supported: tools and extractors are Arc-wrapped for cheap sharing
across workflow iterations (Loop) and concurrent tasks (Parallel).
Fields§
§system_prompt: StringSystem prompt that specializes this agent’s behavior.
tools: Vec<Arc<dyn Tool>>Tools this agent can invoke during the Act phase.
lens: LensHow this agent perceives the substrate.
llm_config: LlmConfigWhich LLM provider and model to use.
experience_extractor: Option<Arc<dyn ExperienceExtractor>>Optional override for experience extraction logic.
None uses the framework’s default extractor.
refresh_every_n_tool_calls: Option<usize>How often to re-perceive the substrate during the Think→Act loop.
When set to Some(n), the agent re-runs the Perceive phase every n tool calls,
picking up new experiences recorded by other agents in the same collective.
This enables real-time “shared consciousness” in parallel workflows.
None disables mid-task refresh (perceive only once at start).
Trait Implementations§
Source§impl Clone for LlmAgentConfig
impl Clone for LlmAgentConfig
Source§fn clone(&self) -> LlmAgentConfig
fn clone(&self) -> LlmAgentConfig
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreAuto Trait Implementations§
impl Freeze for LlmAgentConfig
impl !RefUnwindSafe for LlmAgentConfig
impl Send for LlmAgentConfig
impl Sync for LlmAgentConfig
impl Unpin for LlmAgentConfig
impl UnsafeUnpin for LlmAgentConfig
impl !UnwindSafe for LlmAgentConfig
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more