pub struct CortiqRuntime { /* private fields */ }Expand description
Main runtime managing model state, active task, and metrics.
Implementations§
Source§impl CortiqRuntime
impl CortiqRuntime
Sourcepub async fn switch_task(&self, task_name: &str) -> Result<SwitchResult, Error>
pub async fn switch_task(&self, task_name: &str) -> Result<SwitchResult, Error>
Switch to a different task mask.
Sourcepub async fn status(&self) -> RuntimeStatus
pub async fn status(&self) -> RuntimeStatus
Get current runtime status.
Sourcepub fn masks(&self) -> &MaskCatalog
pub fn masks(&self) -> &MaskCatalog
Get mask catalog.
Sourcepub async fn active_mask(&self) -> Option<TaskMask>
pub async fn active_mask(&self) -> Option<TaskMask>
Snapshot of the currently active task mask (None = dense).
Sourcepub async fn record_generation(
&self,
gen_tokens: usize,
elapsed_ms: f64,
ttft_ms: f64,
)
pub async fn record_generation( &self, gen_tokens: usize, elapsed_ms: f64, ttft_ms: f64, )
Record a finished generation into the performance metrics.
Auto Trait Implementations§
impl !RefUnwindSafe for CortiqRuntime
impl !UnwindSafe for CortiqRuntime
impl Freeze for CortiqRuntime
impl Send for CortiqRuntime
impl Sync for CortiqRuntime
impl Unpin for CortiqRuntime
impl UnsafeUnpin for CortiqRuntime
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