Struct AgentInfo
pub struct AgentInfo {Show 17 fields
pub name: String,
pub parent: Option<String>,
pub description: Option<String>,
pub file: PathBuf,
pub model_alias: String,
pub model_fallback: Option<String>,
pub model_choices: Vec<String>,
pub reasoning_effort: Option<ReasoningEffort>,
pub prompt: String,
pub tools: Vec<String>,
pub skills: Vec<String>,
pub preloaded: Vec<String>,
pub when: Vec<(String, Vec<String>)>,
pub tools_loading: ToolsLoading,
pub retry: Vec<(String, RetryDef)>,
pub plugins: Vec<String>,
pub limits: Limits,
}Expand description
What one bound agent is, without its LlmAgent (which does not expose it). Two definitions
that bind to equal AgentInfos make equal agents; that is how the tests compare an embedded
agent with the same files read from a directory.
Fields§
§name: StringThe name the agent is registered under: the root’s name, then <parent>/<name>.
parent: Option<String>The registration name of the parent; None for the root.
description: Option<String>The frontmatter description: what a parent reads as the subagent’s tool description.
file: PathBufThe agent’s file, relative to the source root.
model_alias: StringThe gateway alias its model calls use.
model_fallback: Option<String>The alias its run continues on when its model is locked, resolved from its folder, its preset and its model’s profile (ADR 0064, amended 2026-11-23).
model_choices: Vec<String>The aliases a message may pick for its run (BoundDef::allow_model_choice): the models
with a profile that this agent can be bound to, its own left out. Empty unless allowed.
reasoning_effort: Option<ReasoningEffort>The reasoning effort its model calls ask for by default, resolved from its folder, its
model_preset, the model profile and the profile’s preset (ADR 0063 decision 4), or None
when none of them sets one.
prompt: StringThe system prompt the model sees: the instructions with the vars substituted, then the
instructions of its eager MCP servers, then the skills catalog and the preloaded skills.
A server with a when adds its section to a run, when the run loads it.
tools: Vec<String>The names of its tools, in the order the model is shown them: its own, then load_skill
and read_skill_file when it has skills to load and files to read, then one per local
subagent (the subagent’s name: the entries of info() whose parent is this agent). An
MCP server with a when contributes its tools here too: a run that does not load it is not
shown them.
skills: Vec<String>The skills it may use, in the order of its skills: (by name for all).
preloaded: Vec<String>The subset of skills whose body is in the prompt (preload_skills:).
when: Vec<(String, Vec<String>)>The MCP servers whose when loads them only when the run’s task mentions one of their
keywords: the server and its keywords, in name order. Empty for an agent whose servers are
all eager. It is part of the info because a definition that differs only here behaves
differently: its tools are withheld from a run the task does not select, and its
instructions are added only to such a run.
tools_loading: ToolsLoadingtools_loading of its file (ADR 0066, decision 1): whether every tool is offered or a run
loads them in groups. An eager agent with a when server withholds nothing.
retry: Vec<(String, RetryDef)>retry: of its file: the retry policy per tool, by name, as the file says it (ADR 0061).
Each is one of tools. Part of the info because an agent that retries a
tool differently behaves differently.
plugins: Vec<String>The plugins the agent runs, by registered name, in order: its parent’s first (ADR 0050, slice H6).
limits: LimitsThe loop’s limits, with max_output_tokens resolved for the
agent’s model (ADR 0064): the folder’s value, its preset’s, the profile’s, the fallback,
then clamped to the model’s limit and window.
Trait Implementations§
impl Eq for AgentInfo
impl StructuralPartialEq for AgentInfo
Auto Trait Implementations§
impl Freeze for AgentInfo
impl RefUnwindSafe for AgentInfo
impl Send for AgentInfo
impl Sync for AgentInfo
impl Unpin for AgentInfo
impl UnsafeUnpin for AgentInfo
impl UnwindSafe for AgentInfo
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,
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§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§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
T in a tonic::Request§impl<L> LayerExt<L> for L
impl<L> LayerExt<L> for L
§fn named_layer<S>(&self, service: S) -> Layered<<L as Layer<S>>::Service, S>where
L: Layer<S>,
fn named_layer<S>(&self, service: S) -> Layered<<L as Layer<S>>::Service, S>where
L: Layer<S>,
Layered].