/** * SingleStepEnforcer Types * * Defines types for enforcing single-step execution in Phase 4. * Prevents agents from making multiple changes in a single operation. * * @see TSK-FR-013 - SingleStepEnforcer型定義 * @see REQ-FR-090〜092 - SingleStepEnforcer * @trace DES-MUSUBIX-FR-001 DES-ORCH-003 */ /** * Step type classification */ export type StepType = 'file-create' | 'file-modify' | 'file-delete' | 'test-run' | 'command-execute' | 'review' | 'other'; /** * Step status */ export type StepStatus = 'pending' | 'in-progress' | 'completed' | 'failed' | 'blocked'; /** * Step definition */ export interface StepDefinition { /** Unique step identifier */ readonly id: string; /** Step name */ readonly name: string; /** Step description */ readonly description: string; /** Step type */ readonly type: StepType; /** Target file or resource */ readonly target?: string; /** Dependencies on other steps */ readonly dependencies?: readonly string[]; /** Expected duration in ms */ readonly expectedDurationMs?: number; } /** * Step execution result */ export interface StepExecutionResult { /** Step that was executed */ readonly step: StepDefinition; /** Execution status */ readonly status: StepStatus; /** Result message */ readonly message: string; /** Error details if failed */ readonly error?: string; /** Actual duration in ms */ readonly durationMs: number; /** Timestamp */ readonly completedAt: Date; /** Files affected */ readonly affectedFiles?: readonly string[]; /** Changes made */ readonly changes?: readonly StepChange[]; } /** * Individual change within a step */ export interface StepChange { /** Type of change */ readonly type: 'add' | 'modify' | 'delete'; /** File path */ readonly file: string; /** Lines added */ readonly linesAdded?: number; /** Lines removed */ readonly linesRemoved?: number; } /** * Step validation result */ export interface StepValidationResult { /** Whether step is valid */ readonly valid: boolean; /** Validation errors */ readonly errors: readonly string[]; /** Validation warnings */ readonly warnings: readonly string[]; } /** * SingleStepEnforcer configuration */ export interface SingleStepConfig { /** Maximum files per step */ readonly maxFilesPerStep: number; /** Maximum lines changed per step */ readonly maxLinesPerStep: number; /** Whether to allow multi-file operations */ readonly allowMultiFile: boolean; /** Step timeout in ms */ readonly stepTimeoutMs: number; /** Whether to require confirmation between steps */ readonly requireConfirmation: boolean; } /** * Default SingleStepEnforcer configuration */ export declare const DEFAULT_SINGLE_STEP_CONFIG: SingleStepConfig; /** * Create a step definition */ export declare function createStepDefinition(params: Omit & { id?: string; }): StepDefinition; /** * Create a step execution result */ export declare function createStepExecutionResult(params: Omit & { completedAt?: Date; }): StepExecutionResult; /** * Create SingleStepEnforcer configuration */ export declare function createSingleStepConfig(overrides?: Partial): SingleStepConfig; //# sourceMappingURL=StepDefinition.d.ts.map