pub struct SpeechToText { /* private fields */ }Expand description
Streaming speech-to-text engine.
Currently a stub – real sherpa-rs integration after VP.
Implementations§
Source§impl SpeechToText
impl SpeechToText
pub fn new(model_path: PathBuf, language: String) -> Self
Sourcepub fn process(&mut self, _samples: &[f32]) -> Vec<SttResult>
pub fn process(&mut self, _samples: &[f32]) -> Vec<SttResult>
Process audio samples and return transcription results.
Sourcepub fn finalize(&mut self) -> Option<SttResult>
pub fn finalize(&mut self) -> Option<SttResult>
Finalize the current utterance and get the final result.
pub fn model_path(&self) -> &Path
pub fn language(&self) -> &str
Auto Trait Implementations§
impl Freeze for SpeechToText
impl RefUnwindSafe for SpeechToText
impl Send for SpeechToText
impl Sync for SpeechToText
impl Unpin for SpeechToText
impl UnsafeUnpin for SpeechToText
impl UnwindSafe for SpeechToText
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more