import { BaseAgent, AgentContext, AgentResult } from "./base.js"; export class ExecutorAgent extends BaseAgent { readonly name = "executor"; readonly description = "Executes plan tasks autonomously. Never pauses for checkpoints."; readonly workflow = "execute"; async execute(context: AgentContext): Promise { const start = Date.now(); this.log("Executing tasks..."); if (context.backend) { const result = await this.executeViaBackend( context, `Execute implementation for stage ${context.stage}, phase ${context.phase}. Specification: ${context.specification}` ); return { ...result, duration_ms: Date.now() - start }; } return { success: false, output: "Execution requires an intelligence backend. Configure one with: ci init --backend", artifacts_created: [], decisions: 0, escalations: 0, duration_ms: Date.now() - start, error: "No intelligence backend available", }; } }