pub struct SurrealStore { /* private fields */ }Expand description
A SurrealDB-backed Store.
Implementations§
Source§impl SurrealStore
impl SurrealStore
Sourcepub async fn open_embedded() -> Result<Self>
pub async fn open_embedded() -> Result<Self>
Opens an in-memory embedded store (the Mem engine), with no
embedder. Use for tests; data does not survive restart.
§Errors
Returns IjimaError::Store if SurrealDB cannot initialize.
Sourcepub async fn open_embedded_with(embedder: Arc<dyn Embedder>) -> Result<Self>
pub async fn open_embedded_with(embedder: Arc<dyn Embedder>) -> Result<Self>
Opens an in-memory embedded store with an Embedder.
§Errors
Returns IjimaError::Store if SurrealDB cannot initialize.
Sourcepub async fn open_persistent(path: impl AsRef<Path>) -> Result<Self>
pub async fn open_persistent(path: impl AsRef<Path>) -> Result<Self>
Opens a persistent store (the SurrealKv engine) at path,
with no embedder. Data survives restart. Creates the directory if
absent.
§Locking (surrealdb 3)
The engine holds a directory LOCK file while open. Dropping the
store handle does not release it synchronously — the datastore’s
background tasks must wind down first (a task boundary + yield).
Cross-process restarts are unaffected (the OS releases the lock at
process exit); same-process sequential reopens of the same path
need the spawn-and-yield pattern (see the persistence test).
§Errors
Returns IjimaError::Store if SurrealDB cannot initialize or
the path is unwritable.
Sourcepub async fn open_persistent_with(
path: impl AsRef<Path>,
embedder: Arc<dyn Embedder>,
) -> Result<Self>
pub async fn open_persistent_with( path: impl AsRef<Path>, embedder: Arc<dyn Embedder>, ) -> Result<Self>
Opens a persistent store with an Embedder.
§Errors
Returns IjimaError::Store if SurrealDB cannot initialize or
the path is unwritable.
Trait Implementations§
Source§impl KnowledgeGraph for SurrealStore
impl KnowledgeGraph for SurrealStore
Source§fn add_triple<'life0, 'life1, 'life2, 'life3, 'life4, 'async_trait>(
&'life0 self,
ns: &'life1 NamespaceId,
subject: EntityId,
predicate: &'life2 str,
object: EntityId,
valid_from: Option<&'life3 str>,
confidence: f32,
source_memory_id: Option<&'life4 str>,
) -> Pin<Box<dyn Future<Output = Result<Triple>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
'life4: 'async_trait,
fn add_triple<'life0, 'life1, 'life2, 'life3, 'life4, 'async_trait>(
&'life0 self,
ns: &'life1 NamespaceId,
subject: EntityId,
predicate: &'life2 str,
object: EntityId,
valid_from: Option<&'life3 str>,
confidence: f32,
source_memory_id: Option<&'life4 str>,
) -> Pin<Box<dyn Future<Output = Result<Triple>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
'life4: 'async_trait,
Triple.Source§fn query_entity<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
ns: &'life1 NamespaceId,
entity: &'life2 EntityId,
) -> Pin<Box<dyn Future<Output = Result<EntityRecord>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn query_entity<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
ns: &'life1 NamespaceId,
entity: &'life2 EntityId,
) -> Pin<Box<dyn Future<Output = Result<EntityRecord>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
ns.Source§fn invalidate_triple<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
ns: &'life1 NamespaceId,
triple_id: &'life2 str,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn invalidate_triple<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
ns: &'life1 NamespaceId,
triple_id: &'life2 str,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
valid_to.
Idempotent.Source§fn find_triples<'life0, 'life1, 'life2, 'life3, 'life4, 'async_trait>(
&'life0 self,
ns: &'life1 NamespaceId,
subject: Option<&'life2 EntityId>,
predicate: Option<&'life3 str>,
object: Option<&'life4 EntityId>,
) -> Pin<Box<dyn Future<Output = Result<Vec<Triple>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
'life4: 'async_trait,
fn find_triples<'life0, 'life1, 'life2, 'life3, 'life4, 'async_trait>(
&'life0 self,
ns: &'life1 NamespaceId,
subject: Option<&'life2 EntityId>,
predicate: Option<&'life3 str>,
object: Option<&'life4 EntityId>,
) -> Pin<Box<dyn Future<Output = Result<Vec<Triple>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
'life4: 'async_trait,
None = wildcard).Source§fn kg_timeline<'life0, 'life1, 'async_trait>(
&'life0 self,
ns: &'life1 NamespaceId,
limit: usize,
) -> Pin<Box<dyn Future<Output = Result<Vec<Triple>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn kg_timeline<'life0, 'life1, 'async_trait>(
&'life0 self,
ns: &'life1 NamespaceId,
limit: usize,
) -> Pin<Box<dyn Future<Output = Result<Vec<Triple>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
valid_from), most
recent first.Source§fn knowledge_stats<'life0, 'life1, 'async_trait>(
&'life0 self,
ns: &'life1 NamespaceId,
) -> Pin<Box<dyn Future<Output = Result<KgStats>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn knowledge_stats<'life0, 'life1, 'async_trait>(
&'life0 self,
ns: &'life1 NamespaceId,
) -> Pin<Box<dyn Future<Output = Result<KgStats>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
ns.Source§impl Store for SurrealStore
impl Store for SurrealStore
Source§fn store_memory<'life0, 'life1, 'async_trait>(
&'life0 self,
ns: &'life1 NamespaceId,
memory: Memory,
) -> Pin<Box<dyn Future<Output = Result<MemoryId>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn store_memory<'life0, 'life1, 'async_trait>(
&'life0 self,
ns: &'life1 NamespaceId,
memory: Memory,
) -> Pin<Box<dyn Future<Output = Result<MemoryId>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
ns, performing content-hash +
semantic dedup. Returns the stored id.Source§fn check_duplicate<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
ns: &'life1 NamespaceId,
content: &'life2 str,
) -> Pin<Box<dyn Future<Output = Result<Option<MemoryId>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn check_duplicate<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
ns: &'life1 NamespaceId,
content: &'life2 str,
) -> Pin<Box<dyn Future<Output = Result<Option<MemoryId>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
ns (content-hash dedup). Returns the existing MemoryId if so.Source§fn recall_memory<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
ns: &'life1 NamespaceId,
id: &'life2 MemoryId,
) -> Pin<Box<dyn Future<Output = Result<Option<Memory>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn recall_memory<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
ns: &'life1 NamespaceId,
id: &'life2 MemoryId,
) -> Pin<Box<dyn Future<Output = Result<Option<Memory>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
ns. Returns None if the
id is absent or belongs to a different namespace (isolation).Source§fn delete_memory<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
ns: &'life1 NamespaceId,
id: &'life2 MemoryId,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn delete_memory<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
ns: &'life1 NamespaceId,
id: &'life2 MemoryId,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
ns.Source§fn list_memories<'life0, 'life1, 'async_trait>(
&'life0 self,
ns: &'life1 NamespaceId,
limit: usize,
) -> Pin<Box<dyn Future<Output = Result<Vec<Memory>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn list_memories<'life0, 'life1, 'async_trait>(
&'life0 self,
ns: &'life1 NamespaceId,
limit: usize,
) -> Pin<Box<dyn Future<Output = Result<Vec<Memory>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
limit memories in ns, ranked by importance DESC
then recency DESC. Powers wake-up composition (L1a personal
essentials, L1b doctrine baseline).Source§fn store_stats<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<StoreStats>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn store_stats<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<StoreStats>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
GET /status.Source§fn list_rooms<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
ns: &'life1 NamespaceId,
project: Option<&'life2 str>,
limit: usize,
) -> Pin<Box<dyn Future<Output = Result<Vec<Room>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn list_rooms<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
ns: &'life1 NamespaceId,
project: Option<&'life2 str>,
limit: usize,
) -> Pin<Box<dyn Future<Output = Result<Vec<Room>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
ns, optionally filtered to a single
project. Each room carries its memory count. Ordered by count desc.Source§fn taxonomy<'life0, 'life1, 'async_trait>(
&'life0 self,
ns: &'life1 NamespaceId,
) -> Pin<Box<dyn Future<Output = Result<Vec<ProjectTaxon>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn taxonomy<'life0, 'life1, 'async_trait>(
&'life0 self,
ns: &'life1 NamespaceId,
) -> Pin<Box<dyn Future<Output = Result<Vec<ProjectTaxon>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
ns. Powers
getTaxonomy navigation.Source§fn palace_graph<'life0, 'life1, 'async_trait>(
&'life0 self,
ns: &'life1 NamespaceId,
) -> Pin<Box<dyn Future<Output = Result<PalaceGraph>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn palace_graph<'life0, 'life1, 'async_trait>(
&'life0 self,
ns: &'life1 NamespaceId,
) -> Pin<Box<dyn Future<Output = Result<PalaceGraph>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
getPalaceGraph — “what connects these projects?”Source§fn traverse_tunnel<'life0, 'life1, 'life2, 'life3, 'life4, 'async_trait>(
&'life0 self,
ns: &'life1 NamespaceId,
topic: &'life2 str,
project_a: &'life3 str,
project_b: &'life4 str,
limit: usize,
) -> Pin<Box<dyn Future<Output = Result<TunnelTraversal>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
'life4: 'async_trait,
fn traverse_tunnel<'life0, 'life1, 'life2, 'life3, 'life4, 'async_trait>(
&'life0 self,
ns: &'life1 NamespaceId,
topic: &'life2 str,
project_a: &'life3 str,
project_b: &'life4 str,
limit: usize,
) -> Pin<Box<dyn Future<Output = Result<TunnelTraversal>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
'life4: 'async_trait,
topic, so the caller can see what connects them.Source§fn search_memories<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
ns: &'life1 NamespaceId,
embedding: &'life2 Embedding,
limit: usize,
) -> Pin<Box<dyn Future<Output = Result<Vec<SearchHit>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn search_memories<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
ns: &'life1 NamespaceId,
embedding: &'life2 Embedding,
limit: usize,
) -> Pin<Box<dyn Future<Output = Result<Vec<SearchHit>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
ns by nearest embedding. Read moreSource§fn ingest_turn<'life0, 'life1, 'async_trait>(
&'life0 self,
ns: &'life1 NamespaceId,
turn: SessionTurn,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn ingest_turn<'life0, 'life1, 'async_trait>(
&'life0 self,
ns: &'life1 NamespaceId,
turn: SessionTurn,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
ns.Source§fn session_turns<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
ns: &'life1 NamespaceId,
session: &'life2 SessionId,
limit: usize,
) -> Pin<Box<dyn Future<Output = Result<Vec<SessionTurn>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn session_turns<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
ns: &'life1 NamespaceId,
session: &'life2 SessionId,
limit: usize,
) -> Pin<Box<dyn Future<Output = Result<Vec<SessionTurn>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
limit turns of session under ns, in order.Source§fn create_session<'life0, 'life1, 'async_trait>(
&'life0 self,
ns: &'life1 NamespaceId,
session: Session,
) -> Pin<Box<dyn Future<Output = Result<SessionId>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn create_session<'life0, 'life1, 'async_trait>(
&'life0 self,
ns: &'life1 NamespaceId,
session: Session,
) -> Pin<Box<dyn Future<Output = Result<SessionId>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
ns (upsert by
id). Call when a session starts; turns reference the session id.
ended_at is set via Self::end_session.Source§fn list_sessions<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
ns: &'life1 NamespaceId,
harness: Option<&'life2 Harness>,
limit: usize,
) -> Pin<Box<dyn Future<Output = Result<Vec<Session>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn list_sessions<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
ns: &'life1 NamespaceId,
harness: Option<&'life2 Harness>,
limit: usize,
) -> Pin<Box<dyn Future<Output = Result<Vec<Session>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
limit sessions in ns, newest first, optionally
filtered by harness.Source§fn end_session<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
ns: &'life1 NamespaceId,
session: &'life2 SessionId,
ended_at: String,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn end_session<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
ns: &'life1 NamespaceId,
session: &'life2 SessionId,
ended_at: String,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
ended_at). Scoped by ns so a
principal can only end sessions in their own namespace.Source§fn enqueue_extraction<'life0, 'life1, 'async_trait>(
&'life0 self,
ns: &'life1 NamespaceId,
memory: Memory,
confidence: f32,
) -> Pin<Box<dyn Future<Output = Result<String>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn enqueue_extraction<'life0, 'life1, 'async_trait>(
&'life0 self,
ns: &'life1 NamespaceId,
memory: Memory,
confidence: f32,
) -> Pin<Box<dyn Future<Output = Result<String>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Source§fn list_pending<'life0, 'life1, 'async_trait>(
&'life0 self,
ns: &'life1 NamespaceId,
limit: usize,
) -> Pin<Box<dyn Future<Output = Result<Vec<QueuedExtraction>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn list_pending<'life0, 'life1, 'async_trait>(
&'life0 self,
ns: &'life1 NamespaceId,
limit: usize,
) -> Pin<Box<dyn Future<Output = Result<Vec<QueuedExtraction>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
ns, newest first.Source§fn accept_extraction<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
ns: &'life1 NamespaceId,
queue_id: &'life2 str,
) -> Pin<Box<dyn Future<Output = Result<AcceptedExtraction>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn accept_extraction<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
ns: &'life1 NamespaceId,
queue_id: &'life2 str,
) -> Pin<Box<dyn Future<Output = Result<AcceptedExtraction>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Source§fn reject_extraction<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
ns: &'life1 NamespaceId,
queue_id: &'life2 str,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn reject_extraction<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
ns: &'life1 NamespaceId,
queue_id: &'life2 str,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Source§fn write_diary<'life0, 'life1, 'async_trait>(
&'life0 self,
ns: &'life1 NamespaceId,
entry: DiaryEntry,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn write_diary<'life0, 'life1, 'async_trait>(
&'life0 self,
ns: &'life1 NamespaceId,
entry: DiaryEntry,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
ns.Source§fn read_diary<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
ns: &'life1 NamespaceId,
agent: &'life2 str,
limit: usize,
) -> Pin<Box<dyn Future<Output = Result<Vec<DiaryEntry>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn read_diary<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
ns: &'life1 NamespaceId,
agent: &'life2 str,
limit: usize,
) -> Pin<Box<dyn Future<Output = Result<Vec<DiaryEntry>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
limit entries of agent’s diary under ns, in
chronological order.Source§fn register_repo<'life0, 'async_trait>(
&'life0 self,
repo: RepoDirectory,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn register_repo<'life0, 'async_trait>(
&'life0 self,
repo: RepoDirectory,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
name). Powers POST /repos — the canonical Anima roster.Source§fn list_repos<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<Vec<RepoDirectory>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn list_repos<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<Vec<RepoDirectory>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Source§fn revoke_token<'life0, 'async_trait>(
&'life0 self,
revocation: TokenRevocation,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn revoke_token<'life0, 'async_trait>(
&'life0 self,
revocation: TokenRevocation,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
POST /tokens/revoke (admin).Source§fn list_revocations<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<Vec<TokenRevocation>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn list_revocations<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<Vec<TokenRevocation>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
GET /tokens/revocations (admin) and daemon-boot hydration of the
in-memory rejection set.Source§fn grant_namespace_membership<'life0, 'async_trait>(
&'life0 self,
membership: NamespaceMembership,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn grant_namespace_membership<'life0, 'async_trait>(
&'life0 self,
membership: NamespaceMembership,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
granted_at/
granted_by but never duplicates.Source§fn revoke_namespace_membership<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
ns: &'life1 NamespaceId,
principal: &'life2 str,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn revoke_namespace_membership<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
ns: &'life1 NamespaceId,
principal: &'life2 str,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Source§fn list_namespace_members<'life0, 'life1, 'async_trait>(
&'life0 self,
ns: &'life1 NamespaceId,
) -> Pin<Box<dyn Future<Output = Result<Vec<NamespaceMembership>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn list_namespace_members<'life0, 'life1, 'async_trait>(
&'life0 self,
ns: &'life1 NamespaceId,
) -> Pin<Box<dyn Future<Output = Result<Vec<NamespaceMembership>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
GET /namespaces/members (admin).Source§fn is_namespace_member<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
ns: &'life1 NamespaceId,
principal: &'life2 str,
) -> Pin<Box<dyn Future<Output = Result<bool>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn is_namespace_member<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
ns: &'life1 NamespaceId,
principal: &'life2 str,
) -> Pin<Box<dyn Future<Output = Result<bool>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
resolve_ns (shared-namespace
reads/writes).Source§fn list_memories_filtered<'life0, 'life1, 'life2, 'life3, 'async_trait>(
&'life0 self,
ns: &'life1 NamespaceId,
project: Option<&'life2 str>,
topic: Option<&'life3 str>,
limit: usize,
) -> Pin<Box<dyn Future<Output = Result<Vec<Memory>, IjimaError>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
Self: 'async_trait,
fn list_memories_filtered<'life0, 'life1, 'life2, 'life3, 'async_trait>(
&'life0 self,
ns: &'life1 NamespaceId,
project: Option<&'life2 str>,
topic: Option<&'life3 str>,
limit: usize,
) -> Pin<Box<dyn Future<Output = Result<Vec<Memory>, IjimaError>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
Self: 'async_trait,
ns, optionally filtered to project/topic.
Powers GET /memories (the memory_recall browse path — distinct
from Self::list_memories, which is the importance-ranked
wake-up feed). Default: fetch a cap, filter in Rust, truncate.
Backends MAY override with a native filtered query.Source§fn resolve_repo<'life0, 'life1, 'async_trait>(
&'life0 self,
cwd: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<Option<RepoDirectory>, IjimaError>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
Self: 'async_trait,
fn resolve_repo<'life0, 'life1, 'async_trait>(
&'life0 self,
cwd: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<Option<RepoDirectory>, IjimaError>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
Self: 'async_trait,
path is a prefix of cwd (after
normalizing). Powers GET /repos/resolve (CWD → project).Auto Trait Implementations§
impl !RefUnwindSafe for SurrealStore
impl !UnwindSafe for SurrealStore
impl Freeze for SurrealStore
impl Send for SurrealStore
impl Sync for SurrealStore
impl Unpin for SurrealStore
impl UnsafeUnpin for SurrealStore
Blanket Implementations§
impl<T> AsyncFriendly for T
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
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> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
Source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
T in a tonic::Request