pub struct ModelSpec {
pub file: String,
pub url: String,
pub size: u64,
pub sha256: Option<String>,
pub facts: ModelFacts,
}Expand description
One model file: where it comes from and what it must hash to.
The size and digest are what let crate::prepare reject a
truncated or corrupt file before a runtime ever opens it.
Fields§
§file: StringFile name under the models directory.
url: StringSource the file is downloaded from when it is absent.
size: u64Exact byte length of the complete file.
sha256: Option<String>Lowercase hex SHA-256 of the complete file, where one exists.
None is a file whose upstream publishes no digest - a model
downloaded from the feed’s own doc tables - and its check is the
size alone. Nothing may describe such a file as verified.
facts: ModelFactsDescribed facts about the checkpoint, for readers that draw a model rather than run it. The normalizer is in no catalogue, so for it this is the only place these facts exist.
Implementations§
Source§impl ModelSpec
impl ModelSpec
Sourcepub fn cohere_transcribe_q4_k_m() -> Self
pub fn cohere_transcribe_q4_k_m() -> Self
Cohere Transcribe, Q4_K_M quantisation. The default ASR model.
Sourcepub fn s1_mini_f16() -> Self
pub fn s1_mini_f16() -> Self
S1-mini, f16. The default normalizer.
Trait Implementations§
impl Eq for ModelSpec
impl StructuralPartialEq for ModelSpec
Auto Trait Implementations§
impl Freeze for ModelSpec
impl RefUnwindSafe for ModelSpec
impl Send for ModelSpec
impl Sync for ModelSpec
impl Unpin for ModelSpec
impl UnsafeUnpin for ModelSpec
impl UnwindSafe for ModelSpec
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> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<S, T> Duplex<S> for Twhere
T: FromSample<S> + ToSample<S>,
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.