/**
 * Create Feature Use Case
 *
 * Creates a new feature entity with a git worktree for isolated development,
 * initializes the spec directory with YAML templates, then spawns the
 * feature agent to begin autonomous SDLC processing.
 *
 * Business Rules:
 * - Metadata generation delegated to MetadataGenerator service
 * - Slug uniqueness delegated to SlugResolver service
 * - Full user input is preserved as-is in spec.yaml
 * - A git worktree is created at ~/.shep/repos/HASH/wt/SLUG/
 * - Spec YAML files are scaffolded at WORKTREE/specs/NNN-SLUG/
 * - Feature agent is spawned with the spec dir path
 * - specPath is persisted on the Feature record
 * - Initial lifecycle is Requirements
 */
import type { Feature } from '../../../../domain/generated/output.js';
import type { IFeatureRepository } from '../../../ports/output/repositories/feature-repository.interface.js';
import type { IWorktreeService } from '../../../ports/output/services/worktree-service.interface.js';
import type { IFeatureAgentProcessService } from '../../../ports/output/agents/feature-agent-process.interface.js';
import type { IAgentRunRepository } from '../../../ports/output/agents/agent-run-repository.interface.js';
import type { ISpecInitializerService } from '../../../ports/output/services/spec-initializer.interface.js';
import type { IRepositoryRepository } from '../../../ports/output/repositories/repository-repository.interface.js';
import type { IGitPrService } from '../../../ports/output/services/git-pr-service.interface.js';
import type { IAgentValidator } from '../../../ports/output/agents/agent-validator.interface.js';
import type { ISkillInjectorService } from '../../../ports/output/services/skill-injector.interface.js';
import type { ISettingsRepository } from '../../../ports/output/repositories/settings.repository.interface.js';
import type { ILogger } from '../../../ports/output/services/logger.interface.js';
import type { IAttachmentStorageService } from '../../../ports/output/services/feature-attachment-storage.interface.js';
import { MetadataGenerator } from './metadata-generator.js';
import { SlugResolver } from './slug-resolver.js';
import type { CreateFeatureInput, CreateFeatureResult, CreateRecordResult } from './types.js';
export declare class CreateFeatureUseCase {
    private readonly featureRepo;
    private readonly worktreeService;
    private readonly agentProcess;
    private readonly runRepository;
    private readonly specInitializer;
    private readonly metadataGenerator;
    private readonly slugResolver;
    private readonly repositoryRepo;
    private readonly gitPrService;
    private readonly attachmentStorage;
    private readonly agentValidator;
    private readonly skillInjector;
    private readonly settingsRepository;
    private readonly logger;
    constructor(featureRepo: IFeatureRepository, worktreeService: IWorktreeService, agentProcess: IFeatureAgentProcessService, runRepository: IAgentRunRepository, specInitializer: ISpecInitializerService, metadataGenerator: MetadataGenerator, slugResolver: SlugResolver, repositoryRepo: IRepositoryRepository, gitPrService: IGitPrService, attachmentStorage: IAttachmentStorageService, agentValidator: IAgentValidator, skillInjector: ISkillInjectorService, settingsRepository: ISettingsRepository, logger: ILogger);
    /**
     * Load settings from the repository, throwing if unavailable. Replaces the
     * former getSettings() module-level singleton import — application layer
     * must not reach into infrastructure directly.
     */
    private loadSettingsOrThrow;
    /**
     * Full synchronous execution: creates record, initializes worktree/spec, spawns agent.
     * Used by the CLI which shows a spinner and needs everything done before returning.
     */
    execute(input: CreateFeatureInput): Promise<CreateFeatureResult>;
    /**
     * Phase 1 (fast): Creates the feature + agent run records in DB and returns immediately.
     * The feature has a real UUID and a preliminary slug derived from the provided name.
     * No AI calls, no git operations — just DB writes.
     */
    createRecord(input: CreateFeatureInput): Promise<CreateRecordResult>;
    /**
     * Phase 2 (slow): AI metadata generation, git worktree, spec init, agent spawn.
     * Updates the feature record with refined metadata, branch, and specPath.
     */
    initializeAndSpawn(feature: Feature, input: CreateFeatureInput, shouldSpawn: boolean): Promise<{
        warning?: string;
        updatedFeature: Feature;
    }>;
}
//# sourceMappingURL=create-feature.use-case.d.ts.map