pub trait TranscribeEngine: InferenceEngine {
// Required methods
fn transcribe_file<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
path: &'life1 str,
language: Option<&'life2 str>,
) -> Pin<Box<dyn Future<Output = Result<String>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait;
fn transcribe_bytes<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
data: &'life1 [u8],
language: Option<&'life2 str>,
) -> Pin<Box<dyn Future<Output = Result<String>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait;
}Expand description
Speech-to-text (Whisper) engine.
Backs /v1/audio/transcriptions.
Required Methods§
Sourcefn transcribe_file<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
path: &'life1 str,
language: Option<&'life2 str>,
) -> Pin<Box<dyn Future<Output = Result<String>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn transcribe_file<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
path: &'life1 str,
language: Option<&'life2 str>,
) -> Pin<Box<dyn Future<Output = Result<String>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Transcribe audio file → text.
Sourcefn transcribe_bytes<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
data: &'life1 [u8],
language: Option<&'life2 str>,
) -> Pin<Box<dyn Future<Output = Result<String>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn transcribe_bytes<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
data: &'life1 [u8],
language: Option<&'life2 str>,
) -> Pin<Box<dyn Future<Output = Result<String>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Transcribe audio bytes (WAV / etc.) → text.
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".