pub async fn run_agent_loop(
provider: Arc<dyn Provider>,
model: &str,
system_prompt: &str,
user_prompt: &str,
tools: Vec<ToolDefinition>,
registry: Arc<ToolRegistry>,
max_steps: usize,
timeout_secs: u64,
event_tx: Option<Sender<SwarmEvent>>,
subtask_id: String,
) -> Result<(String, usize, usize, AgentLoopExit)>Expand description
Run the agentic loop for a sub-agent with tool execution Run an agentic loop with tools - reusable for Ralph and swarm sub-agents