pub enum DefaultsOrigin {
User,
AutoDetected,
Published,
Measured,
}Expand description
Whether a model’s stored inference_defaults were set by the user or
written automatically at import time.
Model.inference_defaults is populated two ways: a user explicitly
tunes it (gglib model update --presence-penalty …, or the WebUI edit
form), or crate::services’s import path auto-writes
InferenceConfig::reasoning_profile onto any model carrying the
reasoning tag — a reasonable guess, not a user decision. Both end up in
the same column with nothing distinguishing them, which meant an
auto-written guess silently outranked the user’s own global settings in
the resolution ladder (InferenceConfig::resolve_with_profile) exactly
as if the user had tuned it themselves.
This type tracks which one actually happened, so resolution can rank
AutoDetected below global settings while a real
User choice keeps outranking them.
Variants§
User
Set explicitly by the user — a CLI flag, a model-update request, or a
WebUI edit. Outranks global settings, same as before this type
existed.
AutoDetected
Written automatically at import time from the model’s reasoning
tag, never reviewed by a person. Ranks below global settings.
Published
Read at import time from the model author’s own
generation_config.json on HuggingFace.
Ranks exactly where Self::AutoDetected does — below global
settings — and is a distinct variant because of what it is, not where
it sits. Both are written without a person reviewing them, so neither
may outrank a setting somebody chose.
It never coexists with AutoDetected: the import prefers this when
it can fetch one, because a published recipe is evidence about this
model where InferenceConfig::reasoning_profile is a generic guess
keyed off a tag. So “above generic tag guesses” holds by replacement
rather than by rank, and no new ladder rung is needed to express it.
Kept apart from User for the reason that distinction exists at all:
this is not a value anybody in this installation decided, so the
agentic-turn ceiling may still cap it and global settings still win.
Measured
Written by a tune sweep: the winner of a measured comparison on this model, this quant, this hardware — not a person’s choice, and not a guess either.
Ranks exactly where Self::AutoDetected does — below global
settings. The principle that puts it there is the ladder’s oldest one:
nothing a person chose may be outranked by anything a person did not,
and an automated apply is not a person. Like Self::Published, it
never coexists with the other below-global origins: applying a winner
overwrites inference_defaults, so “above the guesses” holds by
replacement rather than by rank.
Unlike both of them, the agentic-turn ceiling never caps it. The sweep resolves its candidates against this model’s real context (#748) precisely so the winner transfers to production; a ceiling capping the stored winner would un-measure it on exactly the turns it was measured for. The ceiling exists to bound values nobody examined — a measured temperature is the most examined value in the system.
Trait Implementations§
Source§impl Clone for DefaultsOrigin
impl Clone for DefaultsOrigin
Source§fn clone(&self) -> DefaultsOrigin
fn clone(&self) -> DefaultsOrigin
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for DefaultsOrigin
impl Debug for DefaultsOrigin
Source§impl<'de> Deserialize<'de> for DefaultsOrigin
impl<'de> Deserialize<'de> for DefaultsOrigin
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>,
Source§impl Display for DefaultsOrigin
impl Display for DefaultsOrigin
Source§impl FromStr for DefaultsOrigin
impl FromStr for DefaultsOrigin
Source§impl PartialEq for DefaultsOrigin
impl PartialEq for DefaultsOrigin
Source§fn eq(&self, other: &DefaultsOrigin) -> bool
fn eq(&self, other: &DefaultsOrigin) -> bool
self and other values to be equal, and is used by ==.