/** * Lead-dev plan builder — internal implementation for orchestrator + hooks. * Config: features.json → multi_agent_orchestration (lead_dev_mode), NOT a separate surface. */ export declare const LEAD_DEV_RULES: readonly ["Phased plan + detailed todos; assign best subagent; monitor output; iterate fully", "Lead dev takes helm — loop test fix until complete; no permission pings", "Per-suite test triage after major changes; full suite only when individuals pass", "Lead stays main thread; subagents execute; update todos continuously", "Read all console and test output; triage fix rerun", "Never defer errors as pre-existing — add todo and resolve", "Resolve all errors before phase completion"]; export declare const SYNTHESIS_REALIGNMENT_PHASE_ID = "phase-synthesis"; export declare const MANDATORY_MAJOR_CONSULTS: readonly ["researcher", "architect-tools", "code-review"]; export type SubagentRoute = 'strategist' | 'architect-tools' | 'researcher' | 'backend-engineer' | 'frontend-engineer' | 'bug-triage' | 'code-review' | 'security-audit' | 'enforcer'; export interface LeadDevTodo { id: string; task: string; subagent: SubagentRoute; status: 'pending' | 'in_progress' | 'completed'; } export interface LeadDevPhase { id: string; name: string; goal: string; definitionOfDone: string; todos: LeadDevTodo[]; } export interface LeadDevPlanTaskInput { description: string; type?: string; } export interface LeadDevPlan { active: boolean; rules: readonly string[]; codexTerms: [59, 67, 68, 69]; description: string; complexity: number; requiresPhasedPlan: boolean; recommendedStrategy: string; mandatoryConsults: string[]; phases: LeadDevPhase[]; testProtocol: { perSuiteFirst: boolean; fullSuiteGate: boolean; hint: string; }; /** New id each synthesis plan. Receipts from an older id cannot complete s.1–s.3. */ consultCycleId?: string; } export declare function isLeadDevModeActive(): boolean; export declare function routeSubagent(taskType: string): SubagentRoute; export declare function shouldFlagFullTestSuite(command: string): boolean; /** Mandatory-consult plan for synthesis checkpoint realignment (no implementation phase). */ export declare function buildSynthesisCheckpointPlan(dueReason: string | null, projectRoot?: string): LeadDevPlan | null; export declare function buildLeadDevPlan(description: string, taskTypes?: string[], taskInputs?: LeadDevPlanTaskInput[], mcpOverallComplexity?: number, projectRoot?: string): LeadDevPlan | null; export declare function buildSessionBootContext(): Record; /** Persist plan for PreToolUse spawn_subagent gate */ export declare function persistLeadDevPlan(plan: LeadDevPlan, projectRoot?: string): string; /** @deprecated Use isLeadDevModeActive */ export declare const isAutonomyKernelActive: typeof isLeadDevModeActive; /** @deprecated Use buildLeadDevPlan */ export declare const buildAutonomyIntake: typeof buildLeadDevPlan; export declare const AUTONOMY_RULES: readonly ["Phased plan + detailed todos; assign best subagent; monitor output; iterate fully", "Lead dev takes helm — loop test fix until complete; no permission pings", "Per-suite test triage after major changes; full suite only when individuals pass", "Lead stays main thread; subagents execute; update todos continuously", "Read all console and test output; triage fix rerun", "Never defer errors as pre-existing — add todo and resolve", "Resolve all errors before phase completion"];