pub struct MockStt {
pub transcript: String,
pub user_id: Arc<str>,
}Expand description
A mock STT: turns any audio chunk into a fixed final transcription. Provider implementations replace this with real backends.
Fields§
§transcript: String§user_id: Arc<str>Implementations§
Trait Implementations§
Source§impl SttService for MockStt
impl SttService for MockStt
fn name(&self) -> &str
fn start<'life0, 'life1, 'async_trait>(
&'life0 mut self,
_params: &'life1 StartParams,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Source§fn run_stt<'life0, 'async_trait>(
&'life0 mut self,
_audio: Arc<AudioFrame>,
) -> Pin<Box<dyn Future<Output = Result<Vec<Frame>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn run_stt<'life0, 'async_trait>(
&'life0 mut self,
_audio: Arc<AudioFrame>,
) -> Pin<Box<dyn Future<Output = Result<Vec<Frame>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Feed one audio chunk; transcript frames are returned for the processor to
forward downstream.
fn set_muted<'life0, 'async_trait>(
&'life0 mut self,
_muted: bool,
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Auto Trait Implementations§
impl Freeze for MockStt
impl RefUnwindSafe for MockStt
impl Send for MockStt
impl Sync for MockStt
impl Unpin for MockStt
impl UnsafeUnpin for MockStt
impl UnwindSafe for MockStt
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