UNPKG

@elsikora/commitizen-plugin-commitlint-ai

Version:
40 lines (39 loc) 1.76 kB
import type { ICliInterfaceService } from '../interface/cli-interface-service.interface'; import type { IConfigService } from '../interface/config-service.interface'; import { LLMConfiguration } from '../../domain/entity/llm-configuration.entity'; import { ECommitMode } from '../../domain/enum/commit-mode.enum'; /** * Use case for configuring LLM settings */ export declare class ConfigureLLMUseCase { private readonly CLI_INTERFACE; private readonly CONFIG_SERVICE; constructor(configService: IConfigService, cliInterface: ICliInterfaceService); /** * Configure LLM settings interactively * @returns {Promise<LLMConfiguration>} Promise resolving to the new configuration */ configureInteractively(): Promise<LLMConfiguration>; /** * Get the current LLM configuration * @returns {Promise<LLMConfiguration | null>} Promise resolving to the current configuration or null if not configured */ getCurrentConfiguration(): Promise<LLMConfiguration | null>; /** * Check if the current configuration needs LLM details * @returns {Promise<boolean>} Promise resolving to true if LLM details are needed */ needsLLMDetails(): Promise<boolean>; /** * Save LLM configuration * @param {LLMConfiguration} configuration - The configuration to save * @returns {Promise<void>} Promise that resolves when configuration is saved */ saveConfiguration(configuration: LLMConfiguration): Promise<void>; /** * Update the commit mode * @param {ECommitMode} mode - The new commit mode * @returns {Promise<LLMConfiguration | null>} Promise resolving to the updated configuration */ updateMode(mode: ECommitMode): Promise<LLMConfiguration | null>; }