Expand description
Speech input: capture audio, recognize it and hand the text to the caller.
SpeechState owns a session and SpeechButton and SpeechWaveform
render it. Recognition and audio capture are both replaceable:
implement SpeechRecognizer to use any speech service and AudioInput
to feed audio from anywhere.
With the speech feature, a state without its own recognizer falls back to
the SystemRecognizer of macOS or Windows, and captures from the
Microphone. Linux has no system recognizer, so speech input works there
only with an application recognizer.
Structs§
- Audio
Format - The PCM format a
SpeechRecognizerconsumes. - Audio
Sink - Where an
AudioInputdelivers captured audio. - Speech
Button - The button that starts and stops a
SpeechState’s session. - Speech
Sink - Where a
SpeechRecognizerreports its session’s progress. - Speech
State - The state of a speech input: captures audio from an
AudioInput, feeds it to aSpeechRecognizerand tracks the transcript. - Speech
Waveform - A live waveform of a
SpeechState’s input levels.
Enums§
- Speech
Error - Why a speech session failed.
- Speech
Event - Events emitted by
SpeechState. - Speech
Status - Where a
SpeechStateis in its session.
Traits§
- Audio
Input - A source of audio for a
SpeechState, such as the microphone. - Recognition
Session - One running recognition, opened by
SpeechRecognizer::start. - Speech
Recognizer - Turns speech into text, e.g. by streaming audio to a cloud service.