pub trait LoopMemoryStore: Send + Sync {
// Required methods
fn read_notes(&self) -> Result<String>;
fn write_note(&self, note: &str) -> Result<()>;
fn read_decisions(&self) -> Result<String>;
fn write_decision(&self, decision: &str) -> Result<()>;
}Expand description
A trait for persisting loop-level memory across runs. Implementations may store notes and decisions in markdown, a database, or any other durable form.
Required Methods§
Sourcefn read_notes(&self) -> Result<String>
fn read_notes(&self) -> Result<String>
Read all accumulated notes.
Sourcefn write_note(&self, note: &str) -> Result<()>
fn write_note(&self, note: &str) -> Result<()>
Append a note. Notes are agent-written, human-readable, append-only.
Sourcefn read_decisions(&self) -> Result<String>
fn read_decisions(&self) -> Result<String>
Read all accumulated decisions.
Sourcefn write_decision(&self, decision: &str) -> Result<()>
fn write_decision(&self, decision: &str) -> Result<()>
Append a decision entry. Decisions are the agent’s choices that should survive across loop iterations.
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".
Implementors§
impl LoopMemoryStore for MarkdownLoopMemory
impl LoopMemoryStore for SqliteLoopMemory
Available on crate feature
sqlite only.