Struct PromptContext
pub struct PromptContext<'a> {
pub workspace_dir: &'a Path,
pub agent_workspace_dir: &'a Path,
pub model_name: &'a str,
pub tools: &'a [Box<dyn Tool>],
pub skills: &'a [Skill],
pub skills_prompt_mode: SkillsPromptInjectionMode,
pub identity_config: Option<&'a IdentityConfig>,
pub dispatcher_instructions: &'a str,
pub sends_native_tool_specs: bool,
pub security_summary: Option<String>,
pub autonomy_level: AutonomyLevel,
pub shell_profile: Option<ShellProfile>,
}Fields§
§workspace_dir: &'a Path§agent_workspace_dir: &'a Path§model_name: &'a str§tools: &'a [Box<dyn Tool>]§skills: &'a [Skill]§skills_prompt_mode: SkillsPromptInjectionMode§identity_config: Option<&'a IdentityConfig>§dispatcher_instructions: &'a str§sends_native_tool_specs: boolTrue when the provider request carries native tool specs. In that mode the prompt must not duplicate the same tool catalog in prose.
security_summary: Option<String>Pre-rendered security policy summary for inclusion in the Safety prompt section. When present, the LLM sees the concrete constraints (allowed commands, forbidden paths, autonomy level) so it can plan tool calls without trial-and-error. See
autonomy_level: AutonomyLevelAutonomy level from config. Controls whether the safety section includes “ask before acting” instructions. Full autonomy omits them so the model executes tools directly without simulating approval.
shell_profile: Option<ShellProfile>The shell the runtime adapter will spawn, or None for a shell-less
runtime (which omits the Shell: field and the dialect guidance).
Resolved from RuntimeAdapter::shell_profile so the reported shell
cannot drift from the executed one.
Auto Trait Implementations§
impl<'a> !RefUnwindSafe for PromptContext<'a>
impl<'a> !UnwindSafe for PromptContext<'a>
impl<'a> Freeze for PromptContext<'a>
impl<'a> Send for PromptContext<'a>
impl<'a> Sync for PromptContext<'a>
impl<'a> Unpin for PromptContext<'a>
impl<'a> UnsafeUnpin for PromptContext<'a>
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
§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