/**
 * Stage 0.5 orchestrator: combines vertical detection + user_preference helpers
 * into a single decision payload that the agent activation flow can act on.
 *
 * The orchestrator is pure: callers supply already-scanned filesystem entries
 * (FileSignal[]), and this module returns
 *   - the recommended next action (auto-confirm / ask-disambiguation / ask-default-fallback / skipped)
 *   - the operator-facing copy the agent should display
 *   - a ready-to-store user_preference payload for the chosen path
 *
 * Filesystem IO and actual `store_structured` calls live in the agent-side
 * runner (CLI, MCP server, or hook). This separation keeps Stage 0.5 testable
 * end-to-end without spinning up SQLite or the MCP transport.
 */
import { type FileSignal, type VerticalDetectionOptions, type VerticalDetectionResult } from "./vertical_detection.js";
import { type OnboardingMode, type PreferenceCategory, type UserPreferenceRecord } from "./user_preference.js";
export type StageZeroFiveAction = "skipped" | "auto_confirm" | "ask_disambiguation" | "fallback_personal_agent";
export interface StageZeroFiveInput {
    /** Whether the operator granted permission to scan filenames/folders. */
    permissionGranted: boolean;
    /** Shallow filesystem scan, already collected by the caller. */
    entries: readonly FileSignal[];
    /** Optional pre-existing onboarding choices to fold into the preference. */
    onboardingMode?: OnboardingMode;
    preferenceCategories?: PreferenceCategory[];
    /** Optional canonical_name for the operator (defaults to install username). */
    canonicalName?: string;
    /** Tuning knob; passed straight through to the detection scorer. */
    detectionOptions?: VerticalDetectionOptions;
}
export interface StageZeroFiveDecision {
    action: StageZeroFiveAction;
    detection: VerticalDetectionResult | null;
    /**
     * Slug to confirm with the operator (auto_confirm/ask_disambiguation) or
     * the slug to default-fallback to (fallback_personal_agent). `null` when the
     * stage was skipped.
     */
    recommendedVertical: string | null;
    /** Slug list for an ambiguous tie (always >= 2 entries when set). */
    ambiguousCandidates: string[];
    /** Operator-facing message the agent SHOULD render before doing anything. */
    promptCopy: string;
    /**
     * user_preference payload the agent SHOULD persist via `store_structured`.
     * Always returned (even on `skipped`) so the agent can record the operator's
     * decision history regardless of branch.
     */
    userPreference: UserPreferenceRecord;
    /**
     * Suggested CLI invocation for installing the recommended pack. `null` for
     * `skipped` and `fallback_personal_agent` (which has no native schemas).
     */
    packInstallCommand: string | null;
}
/**
 * Run Stage 0.5 of the activation flow against an already-scanned directory.
 * Does NOT perform IO. Caller decides whether to actually display copy and
 * persist the resulting payload.
 */
export declare function runStageZeroFive(input: StageZeroFiveInput): StageZeroFiveDecision;
//# sourceMappingURL=stage_zero_five.d.ts.map