/** * System prompt builder — ported from src-tauri/src/llm/prompt.rs * * Builds the LLM system prompt dynamically based on context: * - App type (email / chat / document / general) * - Custom vocabulary / dictionary terms * - Translation target language */ export type AppType = "email" | "chat" | "code" | "document" | "general"; /** * A vocabulary entry with an optional list of phonetic aliases. * * Use `soundsLike` to list the approximate spellings that the STT engine may * produce for this term. The LLM will replace any matching alias in the * transcript with the canonical `term`. * * @example * { term: 'Tauri', soundsLike: ['towery', 'tori'] } */ export interface VocabularyEntry { /** The exact term as it must appear in the output */ term: string; /** * Phonetic approximations or alternate spellings the STT engine may produce. * The LLM will treat any of these as a match and replace with `term`. */ soundsLike?: string[]; } export interface BuildPromptOptions { /** Context type — affects tone and formatting style. Default: 'general' */ appType?: AppType; /** * Custom vocabulary terms the LLM must use with exact spelling. * Accepts plain strings or `VocabularyEntry` objects with optional * `soundsLike` aliases — phonetic approximations the STT may produce. * * @example * vocabulary: [ * { term: 'Tauri', soundsLike: ['towery'] }, * 'KPI', * ] */ vocabulary?: (string | VocabularyEntry)[]; /** Whether to translate the output. Requires targetLang. */ translateEnabled?: boolean; /** BCP-47 language code for translation target (e.g. 'en', 'zh', 'ja') */ targetLang?: string; } /** * Build the LLM system prompt for voice-to-text polishing. * * @example * const prompt = buildSystemPrompt({ * appType: 'chat', * vocabulary: ['Tauri'], * translateEnabled: true, * targetLang: 'en', * }); */ export declare function buildSystemPrompt(options?: BuildPromptOptions): string; //# sourceMappingURL=prompt.d.ts.map