pub trait SpeechToTextProvider: Send + Sync {
type Config: ProviderConfig;
type Response: SpeechToTextResponse;
type Error: ProviderError;
// Required method
fn speech_to_text<'life0, 'async_trait>(
&'life0 self,
request: SpeechToTextRequest,
) -> Pin<Box<dyn Future<Output = Result<Self::Response, Self::Error>> + Send + 'async_trait>>
where 'life0: 'async_trait,
Self: 'async_trait;
}
Expand description
Optional trait for providers that support speech-to-text.
Required Associated Types§
Sourcetype Config: ProviderConfig
type Config: ProviderConfig
Provider-specific configuration type
Sourcetype Response: SpeechToTextResponse
type Response: SpeechToTextResponse
Provider-specific response type
Sourcetype Error: ProviderError
type Error: ProviderError
Provider-specific error type