pub struct SubagentConfig {
pub name: String,
pub system_prompt: String,
pub max_turns: usize,
pub timeout_ms: Option<u64>,
}Expand description
Configuration for a subagent.
Fields§
§name: StringName of the subagent (for identification).
system_prompt: StringSystem prompt for the subagent.
max_turns: usizeMaximum number of turns before stopping.
timeout_ms: Option<u64>Optional timeout in milliseconds.
Implementations§
Source§impl SubagentConfig
impl SubagentConfig
Sourcepub fn with_system_prompt(self, prompt: impl Into<String>) -> Self
pub fn with_system_prompt(self, prompt: impl Into<String>) -> Self
Set the system prompt.
Sourcepub const fn with_max_turns(self, max: usize) -> Self
pub const fn with_max_turns(self, max: usize) -> Self
Set the maximum number of turns.
Sourcepub const fn with_timeout_ms(self, timeout: u64) -> Self
pub const fn with_timeout_ms(self, timeout: u64) -> Self
Set the timeout in milliseconds.
Trait Implementations§
Source§impl Clone for SubagentConfig
impl Clone for SubagentConfig
Source§fn clone(&self) -> SubagentConfig
fn clone(&self) -> SubagentConfig
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 moreSource§impl Debug for SubagentConfig
impl Debug for SubagentConfig
Source§impl<'de> Deserialize<'de> for SubagentConfig
impl<'de> Deserialize<'de> for SubagentConfig
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for SubagentConfig
impl RefUnwindSafe for SubagentConfig
impl Send for SubagentConfig
impl Sync for SubagentConfig
impl Unpin for SubagentConfig
impl UnwindSafe for SubagentConfig
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