import { k as AiClientConfig, l as AiClient, o as AiChatSessionOptions, p as AiChatSession, q as PromptVariables, s as AiProvider, d as AiMessage, m as AiChatStatus, h as AiChatResponse, n as AiChatInputOptions, j as AiLogger, b as AiToolDefinition } from '../../../types-DgACCUpT.js';
export { i as AiChatChunk, g as AiChatRequest, f as AiChatRequestOptions, A as AiRole, c as AiToolCall, a as AiToolChoice, e as AiUsage, P as PromptVariableValue, R as ResolvedAiClientConfig, r as normalizePromptVariables } from '../../../types-DgACCUpT.js';
import '../../../types-CbTsi9CZ.js';

declare const createAiClient: (config: AiClientConfig) => AiClient;

declare const createChatSession: (options: AiChatSessionOptions) => AiChatSession;

interface PromptTemplateOptions {
    missingValue?: string;
    preserveUnknown?: boolean;
}
declare const applyPromptTemplate: (template: string, variables?: PromptVariables, options?: PromptTemplateOptions) => string;

declare const DEFAULT_OPENAI_BASE_URL = "https://api.openai.com/v1";
declare const DEFAULT_OPENAI_MODEL = "gpt-3.5-turbo";
declare const createOpenAICompatibleProvider: () => AiProvider;

interface UseAiChatOptions {
    client: AiClient;
    systemPrompt?: string;
    template?: string;
    initialMessages?: AiMessage[];
}
declare const useAiChat: (options: UseAiChatOptions) => {
    status: AiChatStatus;
    isLoading: boolean;
    error: Error | null;
    messages: AiMessage[];
    lastResponse: AiChatResponse | null;
    sendMessage: (input: string, requestOptions?: AiChatInputOptions) => Promise<AiChatResponse>;
    reset: () => void;
    setSystemPrompt: (prompt?: string) => void;
};

type SkillInputSchema = Record<string, any>;
interface SkillExecutionContext {
    messages?: AiMessage[];
    logger?: AiLogger;
    metadata?: Record<string, any>;
}
interface SkillDefinition<Input = any, Output = any> {
    name: string;
    description?: string;
    inputSchema?: SkillInputSchema;
    execute: (input: Input, context?: SkillExecutionContext) => Promise<Output> | Output;
}
interface SkillRegistry {
    registerSkill(skill: SkillDefinition): void;
    unregisterSkill(name: string): boolean;
    getSkill(name: string): SkillDefinition | undefined;
    listSkills(): SkillDefinition[];
    executeSkill(name: string, input: any, context?: SkillExecutionContext): Promise<any>;
    toToolDefinitions?(): AiToolDefinition[];
}

declare const skillToToolDefinition: (skill: SkillDefinition) => AiToolDefinition;
declare class InMemorySkillRegistry implements SkillRegistry {
    private skills;
    constructor(initialSkills?: SkillDefinition[]);
    registerSkill(skill: SkillDefinition): void;
    unregisterSkill(name: string): boolean;
    getSkill(name: string): SkillDefinition | undefined;
    listSkills(): SkillDefinition[];
    executeSkill(name: string, input: any, context?: SkillExecutionContext): Promise<any>;
    toToolDefinitions(): AiToolDefinition[];
}
declare const createSkillRegistry: (initialSkills?: SkillDefinition[]) => InMemorySkillRegistry;

export { AiChatInputOptions, AiChatResponse, AiChatSession, AiChatSessionOptions, AiChatStatus, AiClient, AiClientConfig, AiLogger, AiMessage, AiProvider, AiToolDefinition, DEFAULT_OPENAI_BASE_URL, DEFAULT_OPENAI_MODEL, InMemorySkillRegistry, type PromptTemplateOptions, PromptVariables, type SkillDefinition, type SkillExecutionContext, type SkillInputSchema, type SkillRegistry, type UseAiChatOptions, applyPromptTemplate, createAiClient, createChatSession, createOpenAICompatibleProvider, createSkillRegistry, skillToToolDefinition, useAiChat };
