/**
 * Transition Engine
 *
 * Manages the development state machine and determines appropriate phase transitions.
 * Analyzes conversation context and user input to make intelligent phase decisions.
 */
import type { ConversationState } from './types.js';
export interface TransitionContext {
    currentPhase: string;
    projectPath: string;
    conversationId: string;
    userInput?: string;
    context?: string;
    conversationSummary?: string;
    recentMessages?: Array<{
        role: string;
        content: string;
    }>;
}
export interface TransitionResult {
    newPhase: string;
    instructions: string;
    transitionReason: string;
    isModeled: boolean;
}
export declare class TransitionEngine {
    private stateMachineLoader;
    private workflowManager;
    private conversationManager?;
    constructor(projectPath: string);
    /**
     * Set the conversation manager (dependency injection)
     */
    setConversationManager(conversationManager: {
        hasInteractions: (conversationId: string) => Promise<boolean>;
        getConversationState: (conversationId: string) => Promise<ConversationState | null>;
    }): void;
    /**
     * Get the loaded state machine for the current project
     */
    getStateMachine(projectPath: string, workflowName?: string): import("./state-machine-types.js").YamlStateMachine;
    /**
     * Check if this is the first call from initial state based on database interactions
     */
    private isFirstCallFromInitialState;
    /**
     * Generate instructions for defining phase entrance criteria
     */
    private generateCriteriaDefinitionInstructions;
    /**
     * Get phase-specific instructions for continuing work in current phase
     */
    private getContinuePhaseInstructions;
    /**
     * Get the first development phase from the state machine
     */
    private getFirstDevelopmentPhase;
    /**
     * Analyze context and determine appropriate phase transition
     */
    analyzePhaseTransition(context: TransitionContext): Promise<TransitionResult>;
    /**
     * Handle explicit phase transition request
     */
    handleExplicitTransition(currentPhase: string, targetPhase: string, projectPath: string, reason?: string, workflowName?: string): TransitionResult;
    /**
     * Capitalize phase name for display
     */
    private capitalizePhase;
    /**
     * Filter transitions based on agent role (for crowd workflows)
     * Returns transitions applicable to the current agent
     */
    filterTransitionsByRole<T extends {
        role?: string;
    }>(transitions: T[], agentRole?: string): T[];
}
