/** * useVoice Hook - React hook for voice interactions * * Wraps VoiceManager to provide text-to-speech and speech-to-text * capabilities with React state management. * * Requirements: 8.5 */ export interface UseVoiceReturn { /** Speak text using TTS */ speak: (text: string) => Promise; /** Start listening for speech input */ startListening: () => Promise; /** Stop listening for speech input */ stopListening: () => Promise; /** Ask a question and get spoken response */ ask: (question: string) => Promise; /** Whether currently speaking */ isSpeaking: boolean; /** Whether currently listening */ isListening: boolean; /** Voice availability status */ isAvailable: { tts: boolean; stt: boolean; both: boolean; }; /** Set TTS language */ setLanguage: (language: string) => Promise; /** Set TTS speech rate (0.0 to 1.0) */ setRate: (rate: number) => Promise; /** Set TTS pitch (0.5 to 2.0) */ setPitch: (pitch: number) => Promise; /** Stop all voice operations */ stopAll: () => Promise; } /** * React hook for voice interactions * * @returns Object with voice control functions and state * * @example * ```tsx * const { speak, startListening, isListening, isSpeaking } = useVoice() * * // Speak text * await speak('Hello, how can I help you?') * * // Listen for input * const userInput = await startListening() * console.log('User said:', userInput) * * // Ask a question * const answer = await ask('What is your name?') * console.log('User answered:', answer) * ``` */ export declare function useVoice(): UseVoiceReturn; //# sourceMappingURL=useVoice.d.ts.map