/**
 * V2 → V3 pattern detection.
 *
 * Analyses a project directory and returns a structured report of every v2
 * artefact that needs to be migrated to v3 (framework-agnostic Hono).
 * No files are modified here.
 */
export type Severity = 'auto' | 'guided' | 'manual';
export interface V3Finding {
    id: string;
    severity: Severity;
    message: string;
    file?: string;
    hint?: string;
}
/** Classification of agent complexity */
export type AgentComplexity = 'simple' | 'complex';
/** Detected agent file */
export interface AgentFile {
    /** Absolute path */
    path: string;
    /** Relative path from project root */
    relativePath: string;
    /** Agent name passed to createAgent() */
    name: string;
    /** Whether the agent is simple (handler+schema only) or complex */
    complexity: AgentComplexity;
    /** Reason for complexity classification (if complex) */
    complexityReason?: string;
    /** Whether the agent uses schema validation */
    hasSchema: boolean;
    /** Services accessed via ctx.* */
    ctxServices: string[];
}
/** Detected service usage in a file */
export interface ServiceUsage {
    /** Absolute path */
    path: string;
    /** Relative path from project root */
    relativePath: string;
    /** Services used: 'kv' | 'vector' | 'stream' | 'queue' | 'email' | 'task' | 'schedule' | 'sandbox' | 'logger' */
    services: string[];
    /** Access pattern: 'ctx' (agent context) | 'c.var' (Hono context) */
    accessPattern: 'ctx' | 'c.var';
}
/** Outdated package that needs version update */
export interface V3OutdatedPackage {
    name: string;
    currentVersion: string;
    section: 'dependencies' | 'devDependencies';
}
export interface V3DetectionResult {
    projectDir: string;
    findings: V3Finding[];
    /** Whether the project has @agentuity/runtime in package.json */
    hasRuntimeDep: boolean;
    /** Version of @agentuity/runtime if found */
    runtimeVersion?: string;
    /** Absolute path to app.ts, if found */
    appTsPath?: string;
    /** Whether app.ts uses createApp from @agentuity/runtime */
    hasCreateApp: boolean;
    /** Properties passed to createApp() */
    createAppProps: string[];
    /** Detected agent files */
    agentFiles: AgentFile[];
    /** Whether src/agent/index.ts barrel exists */
    hasAgentBarrel: boolean;
    /** Service usage across all scanned files */
    serviceUsages: ServiceUsage[];
    /** Deduplicated set of all services used anywhere */
    allServicesUsed: string[];
    /** Whether src/web/ exists (SPA) */
    hasFrontend: boolean;
    /** Whether agentuity.config.ts exists */
    hasAgentuityConfig: boolean;
    /** Whether vite.config.ts exists */
    hasViteConfig: boolean;
    /** @agentuity/* packages that need version upgrade */
    outdatedPackages: V3OutdatedPackage[];
    /** Whether @agentuity/react is used */
    hasReactPackage: boolean;
    /** Whether @agentuity/frontend is used */
    hasFrontendPackage: boolean;
}
/** Map from service name to package */
export declare const SERVICE_PACKAGE_MAP: Record<string, {
    pkg: string;
    client: string;
}>;
export declare function detectV3(projectDir: string): Promise<V3DetectionResult>;
//# sourceMappingURL=detect-v3.d.ts.map