import { CapabilityRegistryManager } from './capability-registry.js'; import type { AgentDefinition, AgentVerification, SpawnedAgentTrustLevel, ModificationProposal, ModificationApproval, ProposalStatus } from './types.js'; export interface PendingAgentApproval { readonly proposal: ModificationProposal; readonly verification: AgentVerification; readonly agentDefinition: AgentDefinition; } export declare class AgentSpawner { private promptAnalyzer; private coverageAnalyzer; private registry; private pendingApprovals; constructor(registry: CapabilityRegistryManager); /** * Propose a new agent. Runs full verification: * 1. Prompt safety analysis * 2. Domain coverage analysis * 3. Trust inheritance validation * 4. Tool access analysis * * Returns the verification result and queues for human approval. */ propose(agent: AgentDefinition, parentTrust: SpawnedAgentTrustLevel | 'human', justification: { capability_gap: string; evidence: string[]; expected_impact: string; risk_assessment: string; }, opts?: { useLLMAnalysis?: boolean; }): Promise<{ proposalId: string; verification: AgentVerification; status: ProposalStatus; }>; /** * List all pending agent approvals. */ listPending(): PendingAgentApproval[]; /** * Get a specific pending approval. */ getPending(proposalId: string): PendingAgentApproval | undefined; /** * Approve a pending agent proposal. * Returns the approved agent definition ready for spawning. */ approve(proposalId: string, approvedBy: string, reasoning: string): { approval: ModificationApproval; agent: AgentDefinition; }; /** * Reject a pending agent proposal. */ reject(proposalId: string, rejectedBy: string, reasoning: string): ModificationApproval; private validateTrustInheritance; }