/** * Hook for LLM (Large Language Model) functionality */ /** * Options for useLLM hook */ export interface UseLLMOptions { /** Auto-initialize on mount */ autoInit?: boolean; /** Model ID to load */ model?: string; /** Default system prompt */ systemPrompt?: string; } /** * Return type for useLLM hook */ export interface UseLLMReturn { /** Send a message and get response */ chat: (text: string, options?: { systemPrompt?: string; onToken?: (token: string) => void; }) => Promise; /** Initialize the adapter */ initialize: (modelId?: string) => Promise; /** Unload model to free memory */ unload: () => Promise; /** Current state (reactive) */ readonly isReady: boolean; readonly isInitializing: boolean; readonly isGenerating: boolean; readonly currentModel: string | null; readonly error: Error | null; readonly downloadProgress: number; } /** * Hook for LLM chat * * @example * ```svelte * * * {#if llm.isInitializing} *

Loading model... {llm.downloadProgress}%

* {:else} *
* * *
*

{response}

* {/if} * ``` */ export declare function useLLM(options?: UseLLMOptions): UseLLMReturn; //# sourceMappingURL=useLLM.svelte.d.ts.map