pub struct AurumEngine { /* private fields */ }Expand description
Library-facing engine: validated config + owned governor/metrics/model pools.
Implementations§
Source§impl AurumEngine
impl AurumEngine
Sourcepub fn new(config: ValidatedConfig) -> Self
pub fn new(config: ValidatedConfig) -> Self
Build from an already-validated config with default governor settings.
Sourcepub fn with_governor(config: ValidatedConfig, gov: GovernorConfig) -> Self
pub fn with_governor(config: ValidatedConfig, gov: GovernorConfig) -> Self
Build with an explicit governor profile (mobile/server/custom).
Sourcepub fn load_from_required(path: &Path) -> Result<Self>
pub fn load_from_required(path: &Path) -> Result<Self>
Load from an explicit config file path (must exist).
Sourcepub fn from_config(cfg: Config) -> Result<Self>
pub fn from_config(cfg: Config) -> Result<Self>
Validate a raw Config and wrap it.
pub fn config(&self) -> &Config
pub fn validated_config(&self) -> &ValidatedConfig
pub fn governor(&self) -> &Arc<ResourceGovernor> ⓘ
pub fn metrics(&self) -> &Arc<Metrics> ⓘ
pub fn stt_pool(&self) -> &Arc<SttContextPool> ⓘ
pub fn tts_pool(&self) -> &Arc<TtsSessionPool> ⓘ
pub fn is_closed(&self) -> bool
Sourcepub fn local_whisper(&self) -> Result<LocalWhisperProvider>
pub fn local_whisper(&self) -> Result<LocalWhisperProvider>
Local STT provider bound to this engine’s pool and governor (JOE-1784).
Sourcepub fn local_tts(&self) -> Result<LocalTtsProvider>
pub fn local_tts(&self) -> Result<LocalTtsProvider>
Local TTS provider bound to this engine’s pool and governor (JOE-1784).
Sourcepub async fn transcribe(
&self,
input: &AudioInput,
options: &TranscriptionOptions,
) -> Result<TranscriptionResult>
pub async fn transcribe( &self, input: &AudioInput, options: &TranscriptionOptions, ) -> Result<TranscriptionResult>
High-level STT from a prepared AudioInput (JOE-1787).
Sourcepub async fn transcribe_pcm(
&self,
samples: &[f32],
options: &TranscriptionOptions,
) -> Result<TranscriptionResult>
pub async fn transcribe_pcm( &self, samples: &[f32], options: &TranscriptionOptions, ) -> Result<TranscriptionResult>
High-level STT from mono PCM @ whisper sample rate (JOE-1787).
Sourcepub async fn preload_stt(&self, model: &str) -> Result<PathBuf>
pub async fn preload_stt(&self, model: &str) -> Result<PathBuf>
Preload a local STT model into this engine’s pool.
Sourcepub async fn synthesize(
&self,
text: &str,
options: &SynthesisOptions,
) -> Result<SynthesisResult>
pub async fn synthesize( &self, text: &str, options: &SynthesisOptions, ) -> Result<SynthesisResult>
High-level local TTS synthesis (JOE-1787).
Sourcepub fn clear_model_caches(&self)
pub fn clear_model_caches(&self)
Drop idle model residency in this engine’s pools (JOE-1784).
Sourcepub fn shutdown(&self)
pub fn shutdown(&self)
Mark the engine closed and clear idle model caches.
Does not touch process-global pools used by non-engine providers.
Sourcepub fn doctor(&self) -> DoctorReport
pub fn doctor(&self) -> DoctorReport
Read-only doctor report using this engine’s config.
Sourcepub fn support_bundle(&self, user_notes: Option<String>) -> SupportBundle
pub fn support_bundle(&self, user_notes: Option<String>) -> SupportBundle
Privacy-safe support bundle using this engine’s config and engine metrics.
pub fn metrics_snapshot(&self) -> MetricsSnapshot
Trait Implementations§
Source§impl Debug for AurumEngine
impl Debug for AurumEngine
Source§impl Drop for AurumEngine
impl Drop for AurumEngine
Auto Trait Implementations§
impl !Freeze for AurumEngine
impl RefUnwindSafe for AurumEngine
impl Send for AurumEngine
impl Sync for AurumEngine
impl Unpin for AurumEngine
impl UnsafeUnpin for AurumEngine
impl UnwindSafe for AurumEngine
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
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more