pub enum BuiltinAgentDefinition {
Planner,
Implementer,
}Expand description
Built-in role contracts for a planner-to-implementer workflow.
These definitions do not dispatch work, select a model, or change ordinary
session turns. A workflow may use the same session Smart
crate::AgentSelection for both roles. Assignments, isolated
conversations, and result handoff must be supplied by the workflow before
these contracts can govern execution.
Variants§
Planner
Inspects the workspace and proposes a plan without making changes.
Implementer
Implements an explicitly accepted plan within session permissions.
Implementations§
Source§impl BuiltinAgentDefinition
impl BuiltinAgentDefinition
Sourcepub fn id(self) -> &'static str
pub fn id(self) -> &'static str
Stable role identity, separate from provider kind or personality ID.
Sourcepub fn display_name(self) -> &'static str
pub fn display_name(self) -> &'static str
Human-readable role name for transcripts and status displays.
Sourcepub fn instructions(self) -> &'static str
pub fn instructions(self) -> &'static str
Static application instructions, without interpolated user or model data.
A caller must preserve the protocol’s policy and response schema when delivering these instructions. Prompt text does not enforce permissions.
Sourcepub fn context_requirement(self) -> AgentContextRequirement
pub fn context_requirement(self) -> AgentContextRequirement
Explicit inputs required in the role’s own conversation context.
Sourcepub fn output_kind(self) -> AgentOutputKind
pub fn output_kind(self) -> AgentOutputKind
Expected answer content, using the existing response protocol.
Sourcepub fn permission_mode(
self,
session_permission_mode: PermissionMode,
) -> PermissionMode
pub fn permission_mode( self, session_permission_mode: PermissionMode, ) -> PermissionMode
Restricts session permissions for this role without granting new access.
Callers must pass this mode through worker/runtime permission enforcement; resolving a value alone does not sandbox a run. Worker execution policy remains an independent restriction. Implementers retain read-only sessions and the session’s existing auto-address-comments behavior unchanged.