pub struct RecallEcho { /* private fields */ }Expand description
The recall-echo memory system.
All paths are derived from entity_root:
{entity_root}/memory/
├── MEMORY.md
├── EPHEMERAL.md
├── ARCHIVE.md
├── conversations/
└── graph/ (when graph feature is enabled)Implementations§
Source§impl RecallEcho
impl RecallEcho
Sourcepub fn new(entity_root: PathBuf) -> Self
pub fn new(entity_root: PathBuf) -> Self
Create a new RecallEcho instance with a specific entity root directory.
Sourcepub fn from_default() -> Result<Self, String>
pub fn from_default() -> Result<Self, String>
Create a RecallEcho using the default path resolution (RECALL_ECHO_HOME env var or current working directory).
Sourcepub fn entity_root(&self) -> &Path
pub fn entity_root(&self) -> &Path
Entity root directory.
Sourcepub fn memory_dir(&self) -> PathBuf
pub fn memory_dir(&self) -> PathBuf
Memory directory: {entity_root}/memory/
Sourcepub fn memory_file(&self) -> PathBuf
pub fn memory_file(&self) -> PathBuf
Path to MEMORY.md.
Sourcepub fn ephemeral_file(&self) -> PathBuf
pub fn ephemeral_file(&self) -> PathBuf
Path to EPHEMERAL.md.
Sourcepub fn conversations_dir(&self) -> PathBuf
pub fn conversations_dir(&self) -> PathBuf
Path to conversations directory.
Sourcepub fn archive_index(&self) -> PathBuf
pub fn archive_index(&self) -> PathBuf
Path to ARCHIVE.md index.
Sourcepub fn consume_content(&self) -> Result<Option<String>, String>
pub fn consume_content(&self) -> Result<Option<String>, String>
Read EPHEMERAL.md content without clearing it. Returns None if the file doesn’t exist or is empty.
Sourcepub fn is_initialized(&self) -> bool
pub fn is_initialized(&self) -> bool
Check if the memory system has been initialized.
Sourcepub fn memory_line_count(&self) -> usize
pub fn memory_line_count(&self) -> usize
Number of lines in MEMORY.md.
Auto Trait Implementations§
impl Freeze for RecallEcho
impl RefUnwindSafe for RecallEcho
impl Send for RecallEcho
impl Sync for RecallEcho
impl Unpin for RecallEcho
impl UnsafeUnpin for RecallEcho
impl UnwindSafe for RecallEcho
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> 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>
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 moreSource§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
Source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
Wrap the input message
T in a tonic::Request