pub trait SttProvider: Send + Sync {
// Required methods
fn provider_id(&self) -> &'static str;
fn transcribe_file<'life0, 'life1, 'async_trait>(
&'life0 self,
audio_path: &'life1 Path,
) -> Pin<Box<dyn Future<Output = Result<TranscriptionResult, AppError>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
}Expand description
Unified STT interface (async).
Provider implementations must be Send + Sync so they can be used behind
a Box<dyn SttProvider> across async boundaries.
Required Methods§
Sourcefn provider_id(&self) -> &'static str
fn provider_id(&self) -> &'static str
Returns a stable provider id for logs/telemetry.
Sourcefn transcribe_file<'life0, 'life1, 'async_trait>(
&'life0 self,
audio_path: &'life1 Path,
) -> Pin<Box<dyn Future<Output = Result<TranscriptionResult, AppError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn transcribe_file<'life0, 'life1, 'async_trait>(
&'life0 self,
audio_path: &'life1 Path,
) -> Pin<Box<dyn Future<Output = Result<TranscriptionResult, AppError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Transcribe an audio file into text.