pub struct KuzuStore { /* private fields */ }Implementations§
Source§impl KuzuStore
impl KuzuStore
pub fn find_or_create_entity( &self, name: &str, entity_type: &str, ) -> Result<Entity>
pub fn memory_content_exists(&self, content_prefix: &str) -> Result<bool>
pub fn unconsolidated_memories(&self, limit: usize) -> Result<Vec<Memory>>
pub fn memories_created_between( &self, start: &DateTime<Utc>, end: &DateTime<Utc>, ) -> Result<Vec<Memory>>
pub fn mark_consolidated( &self, raw_id: Uuid, distilled_id: Uuid, model: &str, ) -> Result<()>
pub fn consolidation_count(&self) -> Result<usize>
pub fn delete_consolidated_raw(&self) -> Result<usize>
pub fn rebuild_vector_index(&self) -> Result<()>
pub fn clear_ingest_log(&self) -> Result<usize>
pub fn delete_memories_by_source(&self, source: &str) -> Result<usize>
pub fn is_file_ingested(&self, file_path: &str) -> Result<bool>
pub fn is_file_changed(&self, file_path: &str, file_hash: &str) -> Result<bool>
pub fn mark_ingested( &self, file_path: &str, file_hash: &str, memory_count: usize, source: &str, ) -> Result<()>
pub fn ingested_file_count(&self) -> Result<usize>
Source§impl KuzuStore
impl KuzuStore
pub fn get_conversation(&self, id: Uuid) -> Result<Option<Conversation>>
pub fn get_memory_with_embedding(&self, id: Uuid) -> Result<Option<Memory>>
pub fn import_memory(&self, memory: &Memory) -> Result<()>
pub fn import_conversation(&self, conversation: &Conversation) -> Result<()>
pub fn import_entity(&self, entity: &Entity) -> Result<()>
pub fn import_relation(&self, relation: &Relation) -> Result<()>
pub fn import_delete_memory(&self, id: Uuid) -> Result<()>
pub fn import_or_update_memory(&self, memory: &Memory) -> Result<()>
pub fn sync_log_since(&self, after_seq: u64) -> Result<Vec<SyncEntry>>
pub fn sync_log_page( &self, after_seq: u64, limit: Option<usize>, ) -> Result<Vec<SyncEntry>>
pub fn get_sync_state(&self, peer_id: &str) -> Result<Option<SyncState>>
pub fn set_sync_state(&self, state: &SyncState) -> Result<()>
pub fn get_all_sync_states(&self) -> Result<Vec<SyncState>>
pub fn all_entities(&self) -> Result<Vec<Entity>>
pub fn memories_for_entity(&self, entity_id: Uuid) -> Result<Vec<Memory>>
pub fn unassociated_memories(&self) -> Result<Vec<Memory>>
pub fn max_sync_seq(&self) -> Result<u64>
pub fn backfill_project_paths(&self) -> Result<u64>
pub fn memories_by_project_path( &self, project_path: &str, ) -> Result<Vec<Memory>>
pub fn backfill_sync_log(&self) -> Result<u64>
Source§impl KuzuStore
impl KuzuStore
pub fn upsert_machine(&self, id: &str, name: &str) -> Result<()>
pub fn get_machine_name(&self, id: &str) -> Result<Option<String>>
pub fn get_all_machines(&self) -> Result<HashMap<String, String>>
pub fn backfill_machine_id(&self, machine_id: &str) -> Result<u64>
pub fn register_machine(&self, identity: &MachineIdentity) -> Result<()>
Trait Implementations§
Source§impl Store for KuzuStore
impl Store for KuzuStore
fn store_memory(&self, memory: &Memory) -> Result<()>
fn get_memory(&self, id: Uuid) -> Result<Option<Memory>>
fn delete_memory(&self, id: Uuid) -> Result<()>
fn store_entity(&self, entity: &Entity) -> Result<()>
fn get_entity(&self, id: Uuid) -> Result<Option<Entity>>
fn find_entity_by_name(&self, name: &str) -> Result<Option<Entity>>
fn store_conversation(&self, conversation: &Conversation) -> Result<()>
fn store_relation(&self, relation: &Relation) -> Result<()>
fn get_relations( &self, node_id: Uuid, relation_type: Option<RelationType>, ) -> Result<Vec<Relation>>
fn vector_search( &self, embedding: &[f32], limit: usize, ) -> Result<Vec<(Memory, f32)>>
fn traverse( &self, start_id: Uuid, depth: u32, ) -> Result<Vec<(Memory, Vec<Relation>)>>
fn memories_by_source(&self, source: &str) -> Result<Vec<Memory>>
fn memories_by_type(&self, memory_type: MemoryType) -> Result<Vec<Memory>>
fn memories_needing_decay(&self, threshold_days: u32) -> Result<Vec<Memory>>
fn update_memory(&self, memory: &Memory) -> Result<()>
fn text_search(&self, query: &str, limit: usize) -> Result<Vec<Memory>>
fn memory_count(&self) -> Result<usize>
impl Send for KuzuStore
impl Sync for KuzuStore
Auto Trait Implementations§
impl !Freeze for KuzuStore
impl !RefUnwindSafe for KuzuStore
impl Unpin for KuzuStore
impl UnsafeUnpin for KuzuStore
impl UnwindSafe for KuzuStore
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 more