/**
 * One-time migration to consolidate provenance files into the unified
 * `.cleo/rcasd/{epicId}/` structure with stage subdirectories.
 *
 * Migrates files from:
 *   - `.cleo/consensus/` → `rcasd/{epicId}/consensus/`
 *   - `.cleo/contributions/` → `rcasd/{epicId}/contributions/`
 *   - `.cleo/rcasd/T####_*.md` (loose) → `rcasd/{epicId}/research/`
 *   - Suffixed dirs like `T4881_install-channels` → `T4881`
 *
 * @task T5200
 * @epic T4798
 */
interface MoveRecord {
    from: string;
    to: string;
    type: 'move' | 'rename';
    status: 'success' | 'skipped' | 'error';
    reason?: string;
}
interface MigrationResult {
    moves: MoveRecord[];
    totalMoved: number;
    totalSkipped: number;
    totalErrors: number;
    dryRun: boolean;
}
interface ConsolidateOptions {
    dryRun?: boolean;
    cwd?: string;
}
/**
 * Extract an epic/task ID from file content by searching for:
 *   1. `@task T####` or `@epic T####` annotations (highest priority)
 *   2. JSON `"task"`, `"epicId"`, or `"taskId"` fields
 *   3. First `T####` at a word boundary (fallback)
 */
export declare function resolveEpicFromContent(content: string): string | null;
/**
 * Extract an epic ID from a filename pattern like `T####-*` or `T####_*`.
 */
export declare function resolveEpicFromFilename(filename: string): string | null;
/**
 * Rename suffixed epic directories (e.g. `T4881_install-channels` → `T4881`).
 */
export declare function normalizeDirectoryNames(options?: ConsolidateOptions): MoveRecord[];
/**
 * Migrate `.cleo/consensus/` files to appropriate epic's consensus/ subdirectory.
 *
 * - T4869-checkpoint-consensus.json → rcasd/T4869/consensus/
 * - Agent finding files and CONSENSUS-REPORT.md → resolve epic from content
 * - phase1-best-practices-evidence.md → resolve epic from content → research/
 */
export declare function migrateConsensusFiles(options?: ConsolidateOptions): MoveRecord[];
/**
 * Migrate `.cleo/contributions/` files to appropriate epic's contributions/ subdirectory.
 *
 * Files follow the pattern `T####-session-*.json` with epicId in content.
 */
export declare function migrateContributionFiles(options?: ConsolidateOptions): MoveRecord[];
/**
 * Migrate loose `T####_*.md` files from `.cleo/rcasd/` root into
 * `rcasd/{epicId}/research/` subdirectories.
 */
export declare function migrateLooseFiles(options?: ConsolidateOptions): MoveRecord[];
/**
 * Consolidate all provenance files into the unified `.cleo/rcasd/{epicId}/`
 * structure with stage subdirectories.
 *
 * Performs migrations in order:
 *   1. Rename suffixed directories (T4881_install-channels → T4881)
 *   2. Move consensus files to appropriate epic's consensus/ subdirectory
 *   3. Move contribution files to appropriate epic's contributions/ subdirectory
 *   4. Move loose research files to appropriate epic's research/ subdirectory
 *
 * @param options.dryRun - If true, log planned moves without executing them
 * @param options.cwd - Optional working directory override
 */
export declare function consolidateRcasd(options?: ConsolidateOptions): MigrationResult;
export {};
//# sourceMappingURL=consolidate-rcasd.d.ts.map