pub struct WriteInferenceConfig {
pub contradiction_threshold: f32,
pub obsolete_threshold: f32,
pub related_min: f32,
pub related_max: f32,
pub correction_threshold: f32,
pub confidence_decay_factor: f32,
pub confidence_floor: f32,
pub value_update_enabled: bool,
pub value_update_min_similarity: f32,
pub value_update_prefix_share: f32,
pub value_update_max_tail: usize,
}Expand description
Configuration for write-time inference thresholds.
Fields§
§contradiction_threshold: f32Similarity above which two memories may contradict (default: 0.95).
obsolete_threshold: f32Similarity above which an older memory is marked obsolete (default: 0.85).
Minimum similarity for creating a Related edge (default: 0.6).
Maximum similarity for creating a Related edge (default: 0.85).
correction_threshold: f32Minimum similarity for a Correction to supersede (default: 0.5).
confidence_decay_factor: f32Multiplier applied to original confidence on correction (default: 0.5).
confidence_floor: f32Minimum confidence after decay (default: 0.1).
value_update_enabled: boolWhether the value-update rule runs: a new memory that shares an older same-owner memory’s sentence frame (long common token prefix) but ends in a different value supersedes it, so “favorite coffee is a cortado” followed by “favorite coffee is a flat white” keeps only the correction. This is the cheap, LLM-free slice of contradiction handling; unlike bare cosine (which cannot tell paraphrase from contradiction and was removed at ~0% precision), the shared-frame test only fires on the update shape.
value_update_min_similarity: f32Minimum embedding similarity for the value-update rule (default: 0.88).
Minimum fraction of the longer memory’s tokens that must be a shared prefix for the pair to count as the same sentence frame (default: 0.6).
value_update_max_tail: usizeMaximum differing tail tokens for a value update (default: 4). Larger tails mean genuinely different statements, not a value change.
Trait Implementations§
Source§impl Clone for WriteInferenceConfig
impl Clone for WriteInferenceConfig
Source§fn clone(&self) -> WriteInferenceConfig
fn clone(&self) -> WriteInferenceConfig
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more