/**
 * CapabilityPackState — lifecycle store for Capability Packs.
 *
 * Story 1.4 — OpenLife v1.3 Agent OS Integration.
 *
 * Owns the `draft → tested → active → deprecated` state machine and the
 * append-only audit ledger at `.openlife/capability-lifecycle.jsonl`.
 *
 * Promotion rules:
 *   draft → tested     : requires `validatedBy` (test/checklist name)
 *   tested → active    : requires explicit `actor` (canonization)
 *   active → deprecated: anytime
 *   anyState → deprecated: anytime (for emergency disabling)
 *
 * Never auto-promotes — every transition is an explicit call with an actor.
 *
 * Uses AtomicWriter for both the per-pack status file and the JSONL ledger,
 * surviving kill -9 (same contract as MissionCheckpointStore, Story 6.2).
 */
import { CapabilityStatus } from './CapabilityPackSchema';
export interface LifecycleTransition {
    packId: string;
    from: CapabilityStatus;
    to: CapabilityStatus;
    actor: string;
    reason?: string;
    validatedBy?: string;
    at: string;
}
export interface PackLifecycleStatus {
    packId: string;
    status: CapabilityStatus;
    updatedAt: string;
    updatedBy: string;
    history: LifecycleTransition[];
}
export interface PromoteResult {
    ok: boolean;
    status?: PackLifecycleStatus;
    error?: string;
}
export interface CapabilityPackStateOptions {
    stateDir?: string;
}
export declare class CapabilityPackStateStore {
    private readonly stateDir;
    private readonly ledgerFile;
    constructor(opts?: CapabilityPackStateOptions);
    private statusFile;
    read(packId: string): PackLifecycleStatus | null;
    /**
     * Initialize a pack at status `draft`. Idempotent — if a status file
     * already exists, returns it unchanged.
     */
    init(packId: string, actor: string): PackLifecycleStatus;
    promote(opts: {
        packId: string;
        to: CapabilityStatus;
        actor: string;
        reason?: string;
        validatedBy?: string;
    }): PromoteResult;
    /** List all known packs and their current lifecycle status. */
    list(): PackLifecycleStatus[];
}
