pub struct AgentConfig {
pub name: CompactString,
pub description: CompactString,
pub system_prompt: String,
pub model: Option<CompactString>,
pub max_iterations: usize,
pub tool_choice: ToolChoice,
pub tools: SmallVec<[CompactString; 8]>,
pub skill_tags: SmallVec<[CompactString; 4]>,
}Expand description
Serializable agent configuration.
Contains all parameters for an agent: identity, system prompt, model,
iteration limits, and tool/skill metadata. The Runtime uses tools and
skill_tags to construct the appropriate Dispatcher for this agent.
Fields§
§name: CompactStringAgent identifier.
description: CompactStringHuman-readable description.
system_prompt: StringSystem prompt sent before each LLM request.
model: Option<CompactString>Model to use from the registry. None = registry’s active/default.
max_iterations: usizeMaximum iterations before stopping.
tool_choice: ToolChoiceControls which tool the model calls.
tools: SmallVec<[CompactString; 8]>Names of tools this agent can use (resolved by Runtime into a Dispatcher).
Skill tags for matching agent capabilities.
Implementations§
Source§impl AgentConfig
impl AgentConfig
Sourcepub fn new(name: impl Into<CompactString>) -> Self
pub fn new(name: impl Into<CompactString>) -> Self
Create a new config with the given name and defaults for everything else.
Sourcepub fn system_prompt(self, prompt: impl Into<String>) -> Self
pub fn system_prompt(self, prompt: impl Into<String>) -> Self
Set the system prompt.
Sourcepub fn description(self, desc: impl Into<CompactString>) -> Self
pub fn description(self, desc: impl Into<CompactString>) -> Self
Set the description.
Sourcepub fn tool(self, name: impl Into<CompactString>) -> Self
pub fn tool(self, name: impl Into<CompactString>) -> Self
Add a tool by name.
Sourcepub fn skill_tag(self, tag: impl Into<CompactString>) -> Self
pub fn skill_tag(self, tag: impl Into<CompactString>) -> Self
Add a skill tag.
Sourcepub fn model(self, name: impl Into<CompactString>) -> Self
pub fn model(self, name: impl Into<CompactString>) -> Self
Set the model to use from the registry.
Trait Implementations§
Source§impl Clone for AgentConfig
impl Clone for AgentConfig
Source§fn clone(&self) -> AgentConfig
fn clone(&self) -> AgentConfig
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more