pub struct FetchConfig {
pub cache: CacheConfig,
pub default_quant: Option<QuantType>,
pub auto_pull: bool,
pub max_concurrent: usize,
pub verify_integrity: bool,
pub eviction_policy: EvictionPolicy,
}Expand description
Fetcher configuration
Fields§
§cache: CacheConfigCache configuration
default_quant: Option<QuantType>Preferred quantization (used when not specified in model ref)
auto_pull: boolWhether to auto-pull missing models
max_concurrent: usizeMaximum concurrent downloads
verify_integrity: boolVerify model integrity after download
eviction_policy: EvictionPolicyEviction policy
Implementations§
Source§impl FetchConfig
impl FetchConfig
Sourcepub fn with_cache(self, cache: CacheConfig) -> Self
pub fn with_cache(self, cache: CacheConfig) -> Self
Set cache configuration
Sourcepub fn with_default_quant(self, quant: QuantType) -> Self
pub fn with_default_quant(self, quant: QuantType) -> Self
Set default quantization
Sourcepub fn with_auto_pull(self, enabled: bool) -> Self
pub fn with_auto_pull(self, enabled: bool) -> Self
Enable/disable auto-pull
Sourcepub fn with_eviction_policy(self, policy: EvictionPolicy) -> Self
pub fn with_eviction_policy(self, policy: EvictionPolicy) -> Self
Set eviction policy
Trait Implementations§
Source§impl Clone for FetchConfig
impl Clone for FetchConfig
Source§fn clone(&self) -> FetchConfig
fn clone(&self) -> FetchConfig
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for FetchConfig
impl Debug for FetchConfig
Source§impl Default for FetchConfig
impl Default for FetchConfig
Source§impl<'de> Deserialize<'de> for FetchConfig
impl<'de> Deserialize<'de> for FetchConfig
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for FetchConfig
impl RefUnwindSafe for FetchConfig
impl Send for FetchConfig
impl Sync for FetchConfig
impl Unpin for FetchConfig
impl UnsafeUnpin for FetchConfig
impl UnwindSafe for FetchConfig
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