pub struct NamedAgentDefinition {
pub name: String,
pub system_prompt: String,
pub tools: Option<Vec<String>>,
pub model: Option<String>,
}Expand description
A named subagent type ([capabilities.subagents.agents.<name>], §3.1) —
the CC “subagent definition” shape: its own system prompt, an optionally
NARROWED tool set (a spawned child’s tool surface is always the
intersection of the parent’s already-enabled tools and this list — see
Agent::run_spawn_subagent’s doc comment for why it can only narrow,
never widen), and an optional model override.
Fields§
§name: StringThe name the model passes as spawn_subagent’s agent_type arg.
system_prompt: StringThe child’s system prompt (replaces the parent’s).
tools: Option<Vec<String>>If Some, the child’s enabled-tool set is narrowed to the
intersection of this list and the parent’s own enabled tools.
None inherits the parent’s tool set unchanged.
model: Option<String>If Some, the child runs this model instead of the parent’s.
Trait Implementations§
Source§impl Clone for NamedAgentDefinition
impl Clone for NamedAgentDefinition
Source§fn clone(&self) -> NamedAgentDefinition
fn clone(&self) -> NamedAgentDefinition
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · 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 NamedAgentDefinition
impl Debug for NamedAgentDefinition
Source§impl Default for NamedAgentDefinition
impl Default for NamedAgentDefinition
Source§fn default() -> NamedAgentDefinition
fn default() -> NamedAgentDefinition
Returns the “default value” for a type. Read more
impl Eq for NamedAgentDefinition
Source§impl PartialEq for NamedAgentDefinition
impl PartialEq for NamedAgentDefinition
impl StructuralPartialEq for NamedAgentDefinition
Auto Trait Implementations§
impl Freeze for NamedAgentDefinition
impl RefUnwindSafe for NamedAgentDefinition
impl Send for NamedAgentDefinition
impl Sync for NamedAgentDefinition
impl Unpin for NamedAgentDefinition
impl UnsafeUnpin for NamedAgentDefinition
impl UnwindSafe for NamedAgentDefinition
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.