pub struct MemoryObservation {Show 19 fields
pub observation_id: ObservationId,
pub session_id: SessionId,
pub turn_id: TurnId,
pub subject: EntityRef,
pub predicate: CanonicalPredicate,
pub value: MemoryValue,
pub canonical_statement: String,
pub kind: MemoryKind,
pub explicitness: Explicitness,
pub confidence: f32,
pub persistence: ProposedPersistence,
pub temporal_scope: TemporalScope,
pub valid_from: Option<DateTime<Utc>>,
pub expected_expiry: Option<DateTime<Utc>>,
pub transcript_evidence: TranscriptEvidence,
pub speaker_attribution: SpeakerAttribution,
pub sensitivity: SensitivityClass,
pub mutation_intent: Option<MutationIntent>,
pub search_terms: Vec<String>,
}Expand description
A structured interpretation of one specific user statement.
An observation is evidence, not a fact. It becomes a fact only after consolidation and reconciliation accept it.
Fields§
§observation_id: ObservationIdIdentifier for this observation.
session_id: SessionIdLogical session it was drawn from.
turn_id: TurnIdTurn it was drawn from.
subject: EntityRefWho or what the statement is about.
predicate: CanonicalPredicateCanonical predicate.
value: MemoryValueValue side of the triple.
canonical_statement: StringOne-sentence natural-language rendering.
kind: MemoryKindProposed memory kind.
explicitness: ExplicitnessHow directly it was stated.
confidence: f32Extractor confidence in [0, 1].
persistence: ProposedPersistenceProposed retention.
temporal_scope: TemporalScopeExpected temporal scope.
valid_from: Option<DateTime<Utc>>When the fact started holding, if stated.
expected_expiry: Option<DateTime<Utc>>When the fact is expected to stop holding.
transcript_evidence: TranscriptEvidenceThe transcript span this was drawn from.
speaker_attribution: SpeakerAttributionWho said it.
sensitivity: SensitivityClassPrivacy classification.
mutation_intent: Option<MutationIntent>Whether this observation is a memory command rather than a statement.
search_terms: Vec<String>Terms a user might later search this fact by, in any language they use.
Lexical retrieval can only match words that are present. A fact stored as “The user is vegetarian” is unreachable from “mera khaana ka preference kya hai” — the languages share no token — unless the fact carries the vocabulary the question will use. This is that vocabulary.
Implementations§
Source§impl MemoryObservation
impl MemoryObservation
Sourcepub fn fingerprint(&self) -> FactFingerprint
pub fn fingerprint(&self) -> FactFingerprint
The fingerprint this observation would produce.
Trait Implementations§
Source§impl Clone for MemoryObservation
impl Clone for MemoryObservation
Source§fn clone(&self) -> MemoryObservation
fn clone(&self) -> MemoryObservation
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for MemoryObservation
impl Debug for MemoryObservation
Source§impl<'de> Deserialize<'de> for MemoryObservation
impl<'de> Deserialize<'de> for MemoryObservation
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 JsonSchema for MemoryObservation
impl JsonSchema for MemoryObservation
Source§fn schema_name() -> String
fn schema_name() -> String
Source§fn schema_id() -> Cow<'static, str>
fn schema_id() -> Cow<'static, str>
Source§fn json_schema(generator: &mut SchemaGenerator) -> Schema
fn json_schema(generator: &mut SchemaGenerator) -> Schema
§fn is_referenceable() -> bool
fn is_referenceable() -> bool
$ref keyword. Read moreSource§impl PartialEq for MemoryObservation
impl PartialEq for MemoryObservation
Source§impl Serialize for MemoryObservation
impl Serialize for MemoryObservation
impl StructuralPartialEq for MemoryObservation
Auto Trait Implementations§
impl Freeze for MemoryObservation
impl RefUnwindSafe for MemoryObservation
impl Send for MemoryObservation
impl Sync for MemoryObservation
impl Unpin for MemoryObservation
impl UnwindSafe for MemoryObservation
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> FromSample<S> for S
impl<S> FromSample<S> for S
fn from_sample_(s: S) -> S
§impl<T> FutureExt for T
impl<T> FutureExt for T
§fn with_context(self, otel_cx: Context) -> WithContext<Self>
fn with_context(self, otel_cx: Context) -> WithContext<Self>
§fn with_current_context(self) -> WithContext<Self>
fn with_current_context(self) -> WithContext<Self>
§impl<T> FutureExt for T
impl<T> FutureExt for T
§fn with_context(self, otel_cx: Context) -> WithContext<Self>
fn with_context(self, otel_cx: Context) -> WithContext<Self>
§fn with_current_context(self) -> WithContext<Self>
fn with_current_context(self) -> WithContext<Self>
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
T in a tonic::Request§impl<L> LayerExt<L> for L
impl<L> LayerExt<L> for L
§fn named_layer<S>(&self, service: S) -> Layered<<L as Layer<S>>::Service, S>where
L: Layer<S>,
fn named_layer<S>(&self, service: S) -> Layered<<L as Layer<S>>::Service, S>where
L: Layer<S>,
Layered].