pub struct SkillExecutor { /* private fields */ }Expand description
Skill executor handles the execution of skills in various modes
Implementations§
Source§impl SkillExecutor
impl SkillExecutor
Sourcepub fn new(registry: Arc<RwLock<SkillRegistry>>) -> Self
pub fn new(registry: Arc<RwLock<SkillRegistry>>) -> Self
Create a new skill executor
Sourcepub async fn execute_by_name(
&self,
skill_name: &str,
args: HashMap<String, String>,
) -> Result<SkillResult>
pub async fn execute_by_name( &self, skill_name: &str, args: HashMap<String, String>, ) -> Result<SkillResult>
Execute a skill by name
Loads the skill from registry and executes it with the given arguments.
Sourcepub async fn execute(
&self,
skill: &Skill,
args: HashMap<String, String>,
) -> Result<SkillResult>
pub async fn execute( &self, skill: &Skill, args: HashMap<String, String>, ) -> Result<SkillResult>
Execute a skill
Dispatches to the appropriate execution mode based on skill metadata.
Sourcepub async fn prepare_subagent(
&self,
skill: &Skill,
available_tool_names: &[String],
args: HashMap<String, String>,
) -> Result<SubagentPrepared>
pub async fn prepare_subagent( &self, skill: &Skill, available_tool_names: &[String], args: HashMap<String, String>, ) -> Result<SubagentPrepared>
Prepare a subagent execution context.
Returns task description, filtered tool names, and system prompt. Caller (who has AgentPool access) converts this into a Task + AgentContext.
Sourcepub async fn prepare_script(
&self,
skill: &Skill,
available_tool_names: &[String],
args: HashMap<String, String>,
) -> Result<ScriptPrepared>
pub async fn prepare_script( &self, skill: &Skill, available_tool_names: &[String], args: HashMap<String, String>, ) -> Result<ScriptPrepared>
Prepare a script execution.
Returns the rendered script and filtered tool names. Caller (who has OrchestratorTool access) handles execution.
Sourcepub async fn get_execution_mode(
&self,
skill_name: &str,
) -> Result<SkillExecutionMode>
pub async fn get_execution_mode( &self, skill_name: &str, ) -> Result<SkillExecutionMode>
Get the execution mode for a skill
Auto Trait Implementations§
impl Freeze for SkillExecutor
impl !RefUnwindSafe for SkillExecutor
impl Send for SkillExecutor
impl Sync for SkillExecutor
impl Unpin for SkillExecutor
impl UnsafeUnpin for SkillExecutor
impl !UnwindSafe for SkillExecutor
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