pub struct Model { /* private fields */ }Expand description
A loaded transcription model.
Implementations§
Source§impl Model
impl Model
Sourcepub fn load(path: impl AsRef<Path>) -> Result<Model>
pub fn load(path: impl AsRef<Path>) -> Result<Model>
Load a GGUF model from disk with default options.
Sourcepub fn load_with(
path: impl AsRef<Path>,
options: &ModelOptions,
) -> Result<Model>
pub fn load_with( path: impl AsRef<Path>, options: &ModelOptions, ) -> Result<Model>
Load a GGUF model from disk with explicit options.
Sourcepub fn session(&self) -> Result<Session>
pub fn session(&self) -> Result<Session>
Open a session bound to this model with default session options.
Sourcepub fn session_with(&self, options: &SessionOptions) -> Result<Session>
pub fn session_with(&self, options: &SessionOptions) -> Result<Session>
Open a session bound to this model with explicit options.
Sourcepub fn capabilities(&self) -> Capabilities
pub fn capabilities(&self) -> Capabilities
The model’s immutable capabilities.
Sourcepub fn accepts_ext(&self, slot: ExtSlot, kind: u32) -> bool
pub fn accepts_ext(&self, slot: ExtSlot, kind: u32) -> bool
Whether this model accepts the given family-extension kind in slot.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Model
impl RefUnwindSafe for Model
impl Send for Model
impl Sync for Model
impl Unpin for Model
impl UnsafeUnpin for Model
impl UnwindSafe for Model
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