import { type MachineCommandOutput as CommandOutput } from "./machine-setup-detection.js";
export { buildMachineGuidanceContext, filterMachineGuidance } from "./machine-advisory-guidance.js";
export interface MachineAdvisoryTool {
    name: string;
    description: string;
    phase: string;
    installed: boolean;
    version: string;
}
export interface MachineAdvisoryMcpTokenServer {
    name: string;
    claude: boolean;
    codex: boolean;
    copilot: boolean;
}
export interface MachineAdvisoryMcpInventory {
    claudeTotal: number;
    codexTotal: number;
    copilotTotal: number;
    tokenServers: MachineAdvisoryMcpTokenServer[];
}
export interface MachineAdvisoryOptimizationLayer {
    name: string;
    savings: string;
    claude: boolean;
    codex: boolean;
    copilot: boolean;
}
export interface MachineAdvisorySetupPhaseItem {
    name: string;
    description: string;
    location: string;
    active: boolean;
}
export interface MachineAdvisorySetupPhase {
    phase: string;
    items: MachineAdvisorySetupPhaseItem[];
}
export interface MachineAdvisoryConfigHealth {
    path: string;
    healthy: boolean;
    description: string;
}
export type MachineAdvisorySectionName = "inventory" | "mcpInventory" | "optimizationLayers" | "setupPhases" | "configHealth" | "usage" | "guidance";
export interface MachineAdvisorySectionState {
    status: "fresh" | "cached" | "partial";
    updatedAt: string;
    reason?: string;
}
export interface MachineAdvisoryClaudeUsageDay {
    date: string;
    inputTokens: number;
    outputTokens: number;
    cacheCreationTokens: number;
    cacheReadTokens: number;
    totalTokens: number;
    totalCost: number | null;
    modelsUsed: string[];
}
export interface MachineAdvisoryCodexUsageDay {
    date: string;
    inputTokens: number;
    outputTokens: number;
    cachedInputTokens: number;
    reasoningOutputTokens: number;
    sessions: number;
}
export interface MachineAdvisoryUsage {
    days: number;
    claude: {
        available: boolean;
        days: MachineAdvisoryClaudeUsageDay[];
        totals: {
            inputTokens: number;
            outputTokens: number;
            cacheCreationTokens: number;
            cacheReadTokens: number;
            totalTokens: number;
            totalCost: number | null;
            cacheHitRatio: number | null;
        };
        note: string;
    };
    codex: {
        available: boolean;
        days: MachineAdvisoryCodexUsageDay[];
        totals: {
            inputTokens: number;
            outputTokens: number;
            cachedInputTokens: number;
            reasoningOutputTokens: number;
            sessions: number;
            totalTokens: number;
            cacheHitRatio: number | null;
        };
        note: string;
    };
    copilot: {
        available: boolean;
        note: string;
    };
}
export interface MachineAdvisoryGuidance {
    id: string;
    section: MachineAdvisorySectionName;
    priority: "critical" | "recommended" | "optional";
    group: "critical-issues" | "improvements" | "optional-optimizations";
    severity: "info" | "warn";
    message: string;
    impact: string;
    reason?: string;
    fixCommand?: string;
    hintCommand?: string;
}
export interface MachineAdvisorySystemHealth {
    criticalCount: number;
    warningCount: number;
    okCount: number;
}
export interface MachineAdvisoryOptimizationScoreRuntime {
    label: "planning" | "execution" | "assistant";
    score: number;
    earnedPoints: number;
    maxPoints: number;
    activeSignals: string[];
    missingSignals: string[];
}
export interface MachineAdvisoryOptimizationScore {
    planning: MachineAdvisoryOptimizationScoreRuntime;
    execution: MachineAdvisoryOptimizationScoreRuntime;
    assistant: MachineAdvisoryOptimizationScoreRuntime;
}
export interface MachineAdvisorySetupSummary {
    installedTools: {
        readyCount: number;
        totalCount: number;
    };
    healthyConfigs: {
        readyCount: number;
        totalCount: number;
    };
    activeTokenLayers: string[];
    readyRuntimes: {
        planning: boolean;
        execution: boolean;
        assistant: boolean;
    };
}
export interface MachineGuidanceContext {
    taskType?: string | null;
    workflowStep?: string | null;
    validationFailed?: boolean;
    evalPrecisionLow?: boolean;
    executionRetriesTriggered?: boolean;
}
export interface MachineAdvisoryState {
    artifactType: "kiwi-control/machine-advisory";
    version: 3;
    generatedBy: string;
    windowDays: number;
    updatedAt: string;
    stale: boolean;
    sections: Record<MachineAdvisorySectionName, MachineAdvisorySectionState>;
    inventory: MachineAdvisoryTool[];
    mcpInventory: MachineAdvisoryMcpInventory;
    optimizationLayers: MachineAdvisoryOptimizationLayer[];
    setupPhases: MachineAdvisorySetupPhase[];
    configHealth: MachineAdvisoryConfigHealth[];
    skillsCount: number;
    copilotPlugins: string[];
    usage: MachineAdvisoryUsage;
    systemHealth: MachineAdvisorySystemHealth;
    optimizationScore: MachineAdvisoryOptimizationScore;
    setupSummary: MachineAdvisorySetupSummary;
    guidance: MachineAdvisoryGuidance[];
    note: string;
}
export interface MachineDoctorFinding {
    level: "error" | "warn";
    category: string;
    reason: string;
    fixCommand: string;
}
export interface MachineAdvisoryBuildOptions {
    forceRefresh?: boolean;
    homeRoot?: string;
    now?: Date;
    commandRunner?: (command: string, args: string[]) => Promise<CommandOutput>;
    ccusagePayload?: {
        daily?: Array<Record<string, unknown>>;
    } | null;
    fastMode?: boolean;
    section?: MachineAdvisorySectionName;
}
export declare function loadMachineAdvisory(options?: MachineAdvisoryBuildOptions): Promise<MachineAdvisoryState>;
export declare function buildMachineAdvisory(options?: MachineAdvisoryBuildOptions): Promise<MachineAdvisoryState>;
export declare function loadMachineAdvisorySection(section: MachineAdvisorySectionName, options?: MachineAdvisoryBuildOptions): Promise<{
    section: MachineAdvisorySectionName;
    meta: MachineAdvisorySectionState;
    data: unknown;
}>;
export declare function buildMachineDoctorFindings(state: MachineAdvisoryState, homeRoot?: string): MachineDoctorFinding[];
//# sourceMappingURL=machine-advisory.d.ts.map