pub enum MemorySource {
Agent,
User,
System,
Import,
Sync,
}Expand description
Enumerates the five values accepted by the memories.source CHECK constraint.
Adding a new variant requires:
- Updating the DDL CHECK constraint in
migrations/V001__init.sql. - Running a migration that backfills any pre-existing values
(
UPDATE memories SET source='agent' WHERE source NOT IN (...)). - Bumping
crate::constants::CURRENT_SCHEMA_VERSION.
Variants§
Agent
Mutated by an LLM agent (remember, edit, rename, body-enrich).
User
Mutated by a human operator.
System
Mutated by an internal migration or system job.
Import
Inserted by bulk import (ingest). Rows written before v1.2.0 may also
come from the retired --mode claude-code / --mode codex frontends.
Sync
Inserted by an external sync job.
Implementations§
Source§impl MemorySource
impl MemorySource
Sourcepub const ALL: &'static [MemorySource]
pub const ALL: &'static [MemorySource]
Returns every variant as a static slice, useful for error messages and docs.
Trait Implementations§
Source§impl Clone for MemorySource
impl Clone for MemorySource
Source§fn clone(&self) -> MemorySource
fn clone(&self) -> MemorySource
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreimpl Copy for MemorySource
Source§impl Debug for MemorySource
impl Debug for MemorySource
Source§impl<'de> Deserialize<'de> for MemorySource
impl<'de> Deserialize<'de> for MemorySource
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 MemorySource
impl Display for MemorySource
impl Eq for MemorySource
Source§impl Hash for MemorySource
impl Hash for MemorySource
Source§impl PartialEq for MemorySource
impl PartialEq for MemorySource
Source§impl Serialize for MemorySource
impl Serialize for MemorySource
impl StructuralPartialEq for MemorySource
Source§impl TryFrom<&str> for MemorySource
Parses a stored memories.source string back into a typed variant.
impl TryFrom<&str> for MemorySource
Parses a stored memories.source string back into a typed variant.
§Errors
Returns AppError::Validation when the input is not one of the five
canonical values. The error message lists every accepted value so the
caller can self-correct without consulting the schema.
Auto Trait Implementations§
impl Freeze for MemorySource
impl RefUnwindSafe for MemorySource
impl Send for MemorySource
impl Sync for MemorySource
impl Unpin for MemorySource
impl UnsafeUnpin for MemorySource
impl UnwindSafe for MemorySource
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<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.impl<T> ErasedDestructor for Twhere
T: 'static,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§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 moreSource§impl<T> Pointable for T
impl<T> Pointable for T
Source§impl<T> PolicyExt for Twhere
T: ?Sized,
impl<T> PolicyExt for Twhere
T: ?Sized,
Source§impl<T> ToStringFallible for Twhere
T: Display,
impl<T> ToStringFallible for Twhere
T: Display,
Source§fn try_to_string(&self) -> Result<String, TryReserveError>
fn try_to_string(&self) -> Result<String, TryReserveError>
ToString::to_string, but without panic on OOM.