pub struct ContextDiagnostic {
pub severity: DiagnosticSeverity,
pub code: String,
pub message: String,
}Expand description
A diagnostic about context or model-limit state.
Fields§
§severity: DiagnosticSeveritySeverity of the condition reported by this diagnostic.
code: StringShort code (e.g. "fallback_model_limits", "invalid_model_override").
message: StringHuman-readable explanation.
Implementations§
Source§impl ContextDiagnostic
impl ContextDiagnostic
Sourcepub fn fallback_model_limits(provider: &str, model: &str) -> Self
pub fn fallback_model_limits(provider: &str, model: &str) -> Self
Fallback limits are in use because no metadata was available.
Sourcepub fn invalid_model_override(provider: &str, model: &str, reason: &str) -> Self
pub fn invalid_model_override(provider: &str, model: &str, reason: &str) -> Self
A user override was rejected as invalid.
Trait Implementations§
Source§impl Clone for ContextDiagnostic
impl Clone for ContextDiagnostic
Source§fn clone(&self) -> ContextDiagnostic
fn clone(&self) -> ContextDiagnostic
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 ContextDiagnostic
impl Debug for ContextDiagnostic
impl Eq for ContextDiagnostic
Source§impl PartialEq for ContextDiagnostic
impl PartialEq for ContextDiagnostic
impl StructuralPartialEq for ContextDiagnostic
Auto Trait Implementations§
impl Freeze for ContextDiagnostic
impl RefUnwindSafe for ContextDiagnostic
impl Send for ContextDiagnostic
impl Sync for ContextDiagnostic
impl Unpin for ContextDiagnostic
impl UnsafeUnpin for ContextDiagnostic
impl UnwindSafe for ContextDiagnostic
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