pub enum MemoryTier {
Working,
Episodic,
Semantic,
}Expand description
The engine’s tier and route-visible memory row (rightkit-memory-core), used unchanged at
the backend boundary: one declaration for the engine and its clients. The wire shape is the
same as the row this crate declared before 0.1.0 of rightkit-memory-client.
The tier a memory entry lives in. Tiers form a hierarchy where entries can be
promoted from Working -> Episodic -> Semantic.
Variants§
Implementations§
Source§impl MemoryTier
impl MemoryTier
Sourcepub fn rank(self) -> u8
pub fn rank(self) -> u8
Ordinal rank used to decide whether a promotion moves to a higher tier.
Sourcepub const fn as_str(self) -> &'static str
pub const fn as_str(self) -> &'static str
The tier’s wire name (Working, Episodic, Semantic), as serde writes it.
Sourcepub fn parse(value: &str) -> Option<MemoryTier>
pub fn parse(value: &str) -> Option<MemoryTier>
Reads a tier name in any letter case; None for anything else.
Trait Implementations§
Source§impl Clone for MemoryTier
impl Clone for MemoryTier
Source§fn clone(&self) -> MemoryTier
fn clone(&self) -> MemoryTier
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 moreimpl Copy for MemoryTier
Source§impl Debug for MemoryTier
impl Debug for MemoryTier
Source§impl<'de> Deserialize<'de> for MemoryTier
impl<'de> Deserialize<'de> for MemoryTier
Source§fn deserialize<__D>(
__deserializer: __D,
) -> Result<MemoryTier, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(
__deserializer: __D,
) -> Result<MemoryTier, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
impl Eq for MemoryTier
Source§impl PartialEq for MemoryTier
impl PartialEq for MemoryTier
Source§impl Serialize for MemoryTier
impl Serialize for MemoryTier
Source§fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
Serialize this value into the given Serde serializer. Read more
impl StructuralPartialEq for MemoryTier
Auto Trait Implementations§
impl Forget for MemoryTier
impl Freeze for MemoryTier
impl Move for MemoryTier
impl RefUnwindSafe for MemoryTier
impl Send for MemoryTier
impl Sync for MemoryTier
impl Unpin for MemoryTier
impl UnsafeUnpin for MemoryTier
impl UnwindSafe for MemoryTier
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
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<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> ⓘ
Converts
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> ⓘ
Converts
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