pub trait PersistenceLayer:
Send
+ Sync
+ Debug {
Show 64 methods
// Required methods
fn create_presentation<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
owner_id: &'life1 str,
draft: &'life2 PresentationDraft,
) -> Pin<Box<dyn Future<Output = Result<Presentation>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait;
fn get_presentation<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
owner_id: &'life1 str,
id: &'life2 str,
) -> Pin<Box<dyn Future<Output = Result<Option<Presentation>>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait;
fn list_presentations<'life0, 'life1, 'async_trait>(
&'life0 self,
owner_id: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<Vec<Presentation>>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn update_presentation<'life0, 'life1, 'life2, 'life3, 'async_trait>(
&'life0 self,
owner_id: &'life1 str,
id: &'life2 str,
expected_revision: u64,
draft: &'life3 PresentationDraft,
) -> Pin<Box<dyn Future<Output = Result<Presentation>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait;
fn delete_presentation<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
owner_id: &'life1 str,
id: &'life2 str,
expected_revision: u64,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait;
fn save_session<'life0, 'life1, 'async_trait>(
&'life0 self,
session: &'life1 Session,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn load_session<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
owner_id: &'life1 str,
id: &'life2 str,
) -> Pin<Box<dyn Future<Output = Result<Option<Session>>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait;
fn save_conversation_policy<'life0, 'life1, 'async_trait>(
&'life0 self,
record: &'life1 ConversationPolicyRecord,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn load_conversation_policy<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
owner_id: &'life1 str,
conversation_id: &'life2 str,
) -> Pin<Box<dyn Future<Output = Result<Option<ConversationPolicyRecord>>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait;
fn save_principal_conversation_policy<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
record: &'life1 ConversationPolicyRecord,
expected: Option<&'life2 RunPolicy>,
) -> Pin<Box<dyn Future<Output = Result<bool>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait;
fn load_principal_conversation_policy<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
owner_id: &'life1 str,
conversation_id: &'life2 str,
) -> Pin<Box<dyn Future<Output = Result<Option<ConversationPolicyRecord>>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait;
fn delete_conversation_policy<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
owner_id: &'life1 str,
conversation_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 save_user_prompt_caching_settings<'life0, 'life1, 'async_trait>(
&'life0 self,
settings: &'life1 UserPromptCachingSettings,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn load_user_prompt_caching_settings<'life0, 'life1, 'async_trait>(
&'life0 self,
principal_id: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<Option<UserPromptCachingSettings>>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn save_skill<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
skill: &'life1 Skill,
embedding: &'life2 [f32],
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait;
fn search_skills<'life0, 'life1, 'async_trait>(
&'life0 self,
query_vec: &'life1 [f32],
limit: usize,
) -> Pin<Box<dyn Future<Output = Result<Vec<SkillMatch>>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn save_knowledge_base<'life0, 'life1, 'async_trait>(
&'life0 self,
kb: &'life1 KnowledgeBase,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn get_knowledge_base<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
owner_id: &'life1 str,
id: &'life2 str,
) -> Pin<Box<dyn Future<Output = Result<Option<KnowledgeBase>>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait;
fn get_knowledge_base_by_name<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
owner_id: &'life1 str,
name: &'life2 str,
) -> Pin<Box<dyn Future<Output = Result<Option<KnowledgeBase>>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait;
fn list_knowledge_bases<'life0, 'life1, 'async_trait>(
&'life0 self,
owner_id: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<Vec<KnowledgeBase>>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn delete_knowledge_base<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
owner_id: &'life1 str,
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 save_chunk<'life0, 'life1, 'async_trait>(
&'life0 self,
chunk: &'life1 KnowledgeChunk,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn search_knowledge<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
owner_id: &'life1 str,
query_vec: &'life2 [f32],
limit: usize,
min_score: f32,
) -> Pin<Box<dyn Future<Output = Result<Vec<KnowledgeMatch>>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait;
fn search_knowledge_scoped<'life0, 'life1, 'life2, 'life3, 'life4, 'async_trait>(
&'life0 self,
owner_id: &'life1 str,
kb_ids: &'life2 [&'life3 str],
query_vec: &'life4 [f32],
limit: usize,
min_score: f32,
) -> Pin<Box<dyn Future<Output = Result<Vec<KnowledgeMatch>>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
'life4: 'async_trait;
fn save_document<'life0, 'life1, 'async_trait>(
&'life0 self,
doc: &'life1 KnowledgeDocument,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn get_document<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
owner_id: &'life1 str,
id: &'life2 str,
) -> Pin<Box<dyn Future<Output = Result<Option<KnowledgeDocument>>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait;
fn list_documents<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
owner_id: &'life1 str,
kb_id: &'life2 str,
) -> Pin<Box<dyn Future<Output = Result<Vec<KnowledgeDocument>>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait;
fn update_document_status<'life0, 'life1, 'life2, 'life3, 'async_trait>(
&'life0 self,
owner_id: &'life1 str,
doc_id: &'life2 str,
status: &'life3 DocumentStatus,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait;
fn delete_document<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
owner_id: &'life1 str,
doc_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 create_agent_root<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
owner_id: &'life1 str,
thread: &'life2 AgentThread,
) -> Pin<Box<dyn Future<Output = Result<PersistedAgentThread>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait;
fn create_agent_child<'life0, 'life1, 'life2, 'life3, 'async_trait>(
&'life0 self,
owner_id: &'life1 str,
thread: &'life2 AgentThread,
edge: &'life3 AgentEdge,
) -> Pin<Box<dyn Future<Output = Result<PersistedAgentThread>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait;
fn load_agent_thread<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
owner_id: &'life1 str,
thread_id: &'life2 str,
) -> Pin<Box<dyn Future<Output = Result<Option<PersistedAgentThread>>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait;
fn update_agent_thread<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
owner_id: &'life1 str,
expected_revision: u64,
thread: &'life2 AgentThread,
) -> Pin<Box<dyn Future<Output = Result<PersistedAgentThread>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait;
fn list_agent_threads<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
owner_id: &'life1 str,
root_run_id: &'life2 str,
) -> Pin<Box<dyn Future<Output = Result<Vec<PersistedAgentThread>>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait;
fn list_agent_edges<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
owner_id: &'life1 str,
root_run_id: &'life2 str,
) -> Pin<Box<dyn Future<Output = Result<Vec<AgentEdge>>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait;
fn save_canonical_tool_receipt<'life0, 'life1, 'async_trait>(
&'life0 self,
receipt: &'life1 CanonicalToolReceipt,
) -> Pin<Box<dyn Future<Output = Result<CanonicalToolReceipt>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn list_canonical_tool_receipts<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
owner_id: &'life1 str,
run_id: &'life2 str,
) -> Pin<Box<dyn Future<Output = Result<Vec<CanonicalToolReceipt>>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait;
fn save_agent<'life0, 'life1, 'async_trait>(
&'life0 self,
agent: &'life1 AgentArtifact,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn save_agent_if_unchanged<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
expected: &'life1 AgentArtifact,
updated: &'life2 AgentArtifact,
) -> Pin<Box<dyn Future<Output = Result<bool>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait;
fn load_agent<'life0, 'life1, 'async_trait>(
&'life0 self,
id: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<Option<AgentArtifact>>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn load_agent_by_name<'life0, 'life1, 'async_trait>(
&'life0 self,
name: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<Option<AgentArtifact>>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn list_agents<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<Vec<AgentArtifact>>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
fn save_memory<'life0, 'life1, 'async_trait>(
&'life0 self,
memory: &'life1 Memory,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn search_memory<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
agent_id: Option<&'life1 str>,
query_vec: &'life2 [f32],
limit: usize,
min_score: f32,
) -> Pin<Box<dyn Future<Output = Result<Vec<MemoryMatch>>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait;
fn compare_and_swap_global_presentation_policy<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
expected: &'life1 Value,
selection: &'life2 ResourceSelection,
) -> Pin<Box<dyn Future<Output = Result<bool>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait;
// Provided methods
fn list_skills<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<Vec<Skill>>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait { ... }
fn delete_skill<'life0, 'life1, 'async_trait>(
&'life0 self,
_id: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait { ... }
fn count_documents<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
owner_id: &'life1 str,
kb_id: &'life2 str,
) -> Pin<Box<dyn Future<Output = Result<usize>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait { ... }
fn delete_agent<'life0, 'life1, 'async_trait>(
&'life0 self,
_id: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait { ... }
fn upsert_settings_type<'life0, 'life1, 'async_trait>(
&'life0 self,
_st: &'life1 SettingsType,
) -> Pin<Box<dyn Future<Output = Result<Uuid>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait { ... }
fn list_settings_types<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<Vec<SettingsType>>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait { ... }
fn get_settings_type<'life0, 'life1, 'async_trait>(
&'life0 self,
_key: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<Option<SettingsType>>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait { ... }
fn upsert_setting<'life0, 'life1, 'async_trait>(
&'life0 self,
_setting: &'life1 Settings,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait { ... }
fn get_setting<'life0, 'life1, 'async_trait>(
&'life0 self,
_key: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<Option<Settings>>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait { ... }
fn list_settings<'life0, 'life1, 'async_trait>(
&'life0 self,
_type_key: Option<&'life1 str>,
_parent_id: Option<Uuid>,
) -> Pin<Box<dyn Future<Output = Result<Vec<Settings>>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait { ... }
fn delete_setting<'life0, 'life1, 'async_trait>(
&'life0 self,
_key: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait { ... }
fn insert_attachment<'life0, 'life1, 'async_trait>(
&'life0 self,
_meta: &'life1 AttachmentMeta,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait { ... }
fn get_attachment<'life0, 'life1, 'async_trait>(
&'life0 self,
_id: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<Option<AttachmentMeta>>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait { ... }
fn list_attachments_for_session<'life0, 'life1, 'async_trait>(
&'life0 self,
_session_id: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<Vec<AttachmentMeta>>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait { ... }
fn save_checkpoint<'life0, 'life1, 'async_trait>(
&'life0 self,
_checkpoint: &'life1 Checkpoint,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait { ... }
fn load_checkpoint<'life0, 'life1, 'async_trait>(
&'life0 self,
_id: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<Option<Checkpoint>>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait { ... }
fn list_checkpoints<'life0, 'life1, 'async_trait>(
&'life0 self,
_run_id: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<Vec<Checkpoint>>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait { ... }
fn record_cost_entry<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
_scope: &'life1 str,
_scope_id: &'life2 str,
_cost_usd: f64,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait { ... }
fn list_cost_history<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
_scope: &'life1 str,
_scope_id: &'life2 str,
) -> Pin<Box<dyn Future<Output = Result<Vec<CostEntry>>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait { ... }
}Required Methods§
Sourcefn create_presentation<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
owner_id: &'life1 str,
draft: &'life2 PresentationDraft,
) -> Pin<Box<dyn Future<Output = Result<Presentation>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn create_presentation<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
owner_id: &'life1 str,
draft: &'life2 PresentationDraft,
) -> Pin<Box<dyn Future<Output = Result<Presentation>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Create a validated template in the verified owner’s partition.
Sourcefn get_presentation<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
owner_id: &'life1 str,
id: &'life2 str,
) -> Pin<Box<dyn Future<Output = Result<Option<Presentation>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn get_presentation<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
owner_id: &'life1 str,
id: &'life2 str,
) -> Pin<Box<dyn Future<Output = Result<Option<Presentation>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Read one template without exposing records belonging to another owner.
Sourcefn list_presentations<'life0, 'life1, 'async_trait>(
&'life0 self,
owner_id: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<Vec<Presentation>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn list_presentations<'life0, 'life1, 'async_trait>(
&'life0 self,
owner_id: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<Vec<Presentation>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
List the owner’s templates, including disabled records for management.
Sourcefn update_presentation<'life0, 'life1, 'life2, 'life3, 'async_trait>(
&'life0 self,
owner_id: &'life1 str,
id: &'life2 str,
expected_revision: u64,
draft: &'life3 PresentationDraft,
) -> Pin<Box<dyn Future<Output = Result<Presentation>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
fn update_presentation<'life0, 'life1, 'life2, 'life3, 'async_trait>(
&'life0 self,
owner_id: &'life1 str,
id: &'life2 str,
expected_revision: u64,
draft: &'life3 PresentationDraft,
) -> Pin<Box<dyn Future<Output = Result<Presentation>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
Atomically replace editable content only at the expected revision.
Sourcefn delete_presentation<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
owner_id: &'life1 str,
id: &'life2 str,
expected_revision: u64,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn delete_presentation<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
owner_id: &'life1 str,
id: &'life2 str,
expected_revision: u64,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Atomically delete only the requested owner’s expected record revision.
fn save_session<'life0, 'life1, 'async_trait>(
&'life0 self,
session: &'life1 Session,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn load_session<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
owner_id: &'life1 str,
id: &'life2 str,
) -> Pin<Box<dyn Future<Output = Result<Option<Session>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Sourcefn save_conversation_policy<'life0, 'life1, 'async_trait>(
&'life0 self,
record: &'life1 ConversationPolicyRecord,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn save_conversation_policy<'life0, 'life1, 'async_trait>(
&'life0 self,
record: &'life1 ConversationPolicyRecord,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Save or replace a conversation-scoped chat policy.
Sourcefn load_conversation_policy<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
owner_id: &'life1 str,
conversation_id: &'life2 str,
) -> Pin<Box<dyn Future<Output = Result<Option<ConversationPolicyRecord>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn load_conversation_policy<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
owner_id: &'life1 str,
conversation_id: &'life2 str,
) -> Pin<Box<dyn Future<Output = Result<Option<ConversationPolicyRecord>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Load a conversation-scoped chat policy.
Sourcefn save_principal_conversation_policy<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
record: &'life1 ConversationPolicyRecord,
expected: Option<&'life2 RunPolicy>,
) -> Pin<Box<dyn Future<Output = Result<bool>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn save_principal_conversation_policy<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
record: &'life1 ConversationPolicyRecord,
expected: Option<&'life2 RunPolicy>,
) -> Pin<Box<dyn Future<Output = Result<bool>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Conditionally write in the principal namespace. None expects no record; an existing policy must still equal the complete supplied baseline.
Sourcefn load_principal_conversation_policy<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
owner_id: &'life1 str,
conversation_id: &'life2 str,
) -> Pin<Box<dyn Future<Output = Result<Option<ConversationPolicyRecord>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn load_principal_conversation_policy<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
owner_id: &'life1 str,
conversation_id: &'life2 str,
) -> Pin<Box<dyn Future<Output = Result<Option<ConversationPolicyRecord>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Read only the verified principal namespace, without legacy fallback.
Sourcefn delete_conversation_policy<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
owner_id: &'life1 str,
conversation_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 delete_conversation_policy<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
owner_id: &'life1 str,
conversation_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,
Delete a conversation-scoped chat policy.
Sourcefn save_user_prompt_caching_settings<'life0, 'life1, 'async_trait>(
&'life0 self,
settings: &'life1 UserPromptCachingSettings,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn save_user_prompt_caching_settings<'life0, 'life1, 'async_trait>(
&'life0 self,
settings: &'life1 UserPromptCachingSettings,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Save or replace one verified user’s prompt-caching preferences.
Sourcefn load_user_prompt_caching_settings<'life0, 'life1, 'async_trait>(
&'life0 self,
principal_id: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<Option<UserPromptCachingSettings>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn load_user_prompt_caching_settings<'life0, 'life1, 'async_trait>(
&'life0 self,
principal_id: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<Option<UserPromptCachingSettings>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Load prompt-caching preferences by the collision-safe verified principal key.
fn save_skill<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
skill: &'life1 Skill,
embedding: &'life2 [f32],
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn search_skills<'life0, 'life1, 'async_trait>(
&'life0 self,
query_vec: &'life1 [f32],
limit: usize,
) -> Pin<Box<dyn Future<Output = Result<Vec<SkillMatch>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Sourcefn save_knowledge_base<'life0, 'life1, 'async_trait>(
&'life0 self,
kb: &'life1 KnowledgeBase,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn save_knowledge_base<'life0, 'life1, 'async_trait>(
&'life0 self,
kb: &'life1 KnowledgeBase,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Save or update a knowledge base definition.
Sourcefn get_knowledge_base<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
owner_id: &'life1 str,
id: &'life2 str,
) -> Pin<Box<dyn Future<Output = Result<Option<KnowledgeBase>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn get_knowledge_base<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
owner_id: &'life1 str,
id: &'life2 str,
) -> Pin<Box<dyn Future<Output = Result<Option<KnowledgeBase>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Get a knowledge base by ID.
Sourcefn get_knowledge_base_by_name<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
owner_id: &'life1 str,
name: &'life2 str,
) -> Pin<Box<dyn Future<Output = Result<Option<KnowledgeBase>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn get_knowledge_base_by_name<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
owner_id: &'life1 str,
name: &'life2 str,
) -> Pin<Box<dyn Future<Output = Result<Option<KnowledgeBase>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Get a knowledge base by name.
Sourcefn list_knowledge_bases<'life0, 'life1, 'async_trait>(
&'life0 self,
owner_id: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<Vec<KnowledgeBase>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn list_knowledge_bases<'life0, 'life1, 'async_trait>(
&'life0 self,
owner_id: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<Vec<KnowledgeBase>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
List all knowledge bases.
Sourcefn delete_knowledge_base<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
owner_id: &'life1 str,
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 delete_knowledge_base<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
owner_id: &'life1 str,
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,
Delete a knowledge base and all its chunks/documents.
Sourcefn save_chunk<'life0, 'life1, 'async_trait>(
&'life0 self,
chunk: &'life1 KnowledgeChunk,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn save_chunk<'life0, 'life1, 'async_trait>(
&'life0 self,
chunk: &'life1 KnowledgeChunk,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Save a knowledge chunk.
Sourcefn search_knowledge<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
owner_id: &'life1 str,
query_vec: &'life2 [f32],
limit: usize,
min_score: f32,
) -> Pin<Box<dyn Future<Output = Result<Vec<KnowledgeMatch>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn search_knowledge<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
owner_id: &'life1 str,
query_vec: &'life2 [f32],
limit: usize,
min_score: f32,
) -> Pin<Box<dyn Future<Output = Result<Vec<KnowledgeMatch>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Search knowledge across ALL knowledge bases (original behavior).
Sourcefn search_knowledge_scoped<'life0, 'life1, 'life2, 'life3, 'life4, 'async_trait>(
&'life0 self,
owner_id: &'life1 str,
kb_ids: &'life2 [&'life3 str],
query_vec: &'life4 [f32],
limit: usize,
min_score: f32,
) -> Pin<Box<dyn Future<Output = Result<Vec<KnowledgeMatch>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
'life4: 'async_trait,
fn search_knowledge_scoped<'life0, 'life1, 'life2, 'life3, 'life4, 'async_trait>(
&'life0 self,
owner_id: &'life1 str,
kb_ids: &'life2 [&'life3 str],
query_vec: &'life4 [f32],
limit: usize,
min_score: f32,
) -> Pin<Box<dyn Future<Output = Result<Vec<KnowledgeMatch>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
'life4: 'async_trait,
Search knowledge scoped to specific knowledge base IDs.
Sourcefn save_document<'life0, 'life1, 'async_trait>(
&'life0 self,
doc: &'life1 KnowledgeDocument,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn save_document<'life0, 'life1, 'async_trait>(
&'life0 self,
doc: &'life1 KnowledgeDocument,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Save a document record.
Sourcefn get_document<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
owner_id: &'life1 str,
id: &'life2 str,
) -> Pin<Box<dyn Future<Output = Result<Option<KnowledgeDocument>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn get_document<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
owner_id: &'life1 str,
id: &'life2 str,
) -> Pin<Box<dyn Future<Output = Result<Option<KnowledgeDocument>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Get a document by ID.
Sourcefn list_documents<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
owner_id: &'life1 str,
kb_id: &'life2 str,
) -> Pin<Box<dyn Future<Output = Result<Vec<KnowledgeDocument>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn list_documents<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
owner_id: &'life1 str,
kb_id: &'life2 str,
) -> Pin<Box<dyn Future<Output = Result<Vec<KnowledgeDocument>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
List documents in a knowledge base.
Sourcefn update_document_status<'life0, 'life1, 'life2, 'life3, 'async_trait>(
&'life0 self,
owner_id: &'life1 str,
doc_id: &'life2 str,
status: &'life3 DocumentStatus,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
fn update_document_status<'life0, 'life1, 'life2, 'life3, 'async_trait>(
&'life0 self,
owner_id: &'life1 str,
doc_id: &'life2 str,
status: &'life3 DocumentStatus,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
Update document processing status.
Sourcefn delete_document<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
owner_id: &'life1 str,
doc_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 delete_document<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
owner_id: &'life1 str,
doc_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,
Delete a document and all its associated chunks.
Sourcefn create_agent_root<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
owner_id: &'life1 str,
thread: &'life2 AgentThread,
) -> Pin<Box<dyn Future<Output = Result<PersistedAgentThread>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn create_agent_root<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
owner_id: &'life1 str,
thread: &'life2 AgentThread,
) -> Pin<Box<dyn Future<Output = Result<PersistedAgentThread>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Insert a fresh root. Existing IDs/paths are errors, never upserts. The owner argument must come from the verified host context.
Sourcefn create_agent_child<'life0, 'life1, 'life2, 'life3, 'async_trait>(
&'life0 self,
owner_id: &'life1 str,
thread: &'life2 AgentThread,
edge: &'life3 AgentEdge,
) -> Pin<Box<dyn Future<Output = Result<PersistedAgentThread>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
fn create_agent_child<'life0, 'life1, 'life2, 'life3, 'async_trait>(
&'life0 self,
owner_id: &'life1 str,
thread: &'life2 AgentThread,
edge: &'life3 AgentEdge,
) -> Pin<Box<dyn Future<Output = Result<PersistedAgentThread>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
Atomically insert a pending child and its immutable edge. Both persisted parent and root must belong to the owner/tree and still have a live turn. An interrupted/error response is not proof that nothing committed: the caller must reconcile the exact child ID before releasing its reservation.
Sourcefn load_agent_thread<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
owner_id: &'life1 str,
thread_id: &'life2 str,
) -> Pin<Box<dyn Future<Output = Result<Option<PersistedAgentThread>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn load_agent_thread<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
owner_id: &'life1 str,
thread_id: &'life2 str,
) -> Pin<Box<dyn Future<Output = Result<Option<PersistedAgentThread>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Load only from this owner’s namespace. Missing records return None; corrupt records or backend failures return errors, never empty success.
Sourcefn update_agent_thread<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
owner_id: &'life1 str,
expected_revision: u64,
thread: &'life2 AgentThread,
) -> Pin<Box<dyn Future<Output = Result<PersistedAgentThread>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn update_agent_thread<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
owner_id: &'life1 str,
expected_revision: u64,
thread: &'life2 AgentThread,
) -> Pin<Box<dyn Future<Output = Result<PersistedAgentThread>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Update mutable turn state with compare-and-swap on the storage revision. Lineage, artifact, creation time, and terminal outcomes cannot be rewritten. A new authorized turn may replace a terminal outcome with a new run ID.
Sourcefn list_agent_threads<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
owner_id: &'life1 str,
root_run_id: &'life2 str,
) -> Pin<Box<dyn Future<Output = Result<Vec<PersistedAgentThread>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn list_agent_threads<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
owner_id: &'life1 str,
root_run_id: &'life2 str,
) -> Pin<Box<dyn Future<Output = Result<Vec<PersistedAgentThread>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
List one owner’s root-run tree, ordered by canonical path then thread ID using Rust string ordering (independent of database locale/collation).
Sourcefn list_agent_edges<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
owner_id: &'life1 str,
root_run_id: &'life2 str,
) -> Pin<Box<dyn Future<Output = Result<Vec<AgentEdge>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn list_agent_edges<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
owner_id: &'life1 str,
root_run_id: &'life2 str,
) -> Pin<Box<dyn Future<Output = Result<Vec<AgentEdge>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
List immutable edges in canonical path/child-ID order. No deletion API is exposed: lineage remains available for recovery and lifetime accounting.
Sourcefn save_canonical_tool_receipt<'life0, 'life1, 'async_trait>(
&'life0 self,
receipt: &'life1 CanonicalToolReceipt,
) -> Pin<Box<dyn Future<Output = Result<CanonicalToolReceipt>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn save_canonical_tool_receipt<'life0, 'life1, 'async_trait>(
&'life0 self,
receipt: &'life1 CanonicalToolReceipt,
) -> Pin<Box<dyn Future<Output = Result<CanonicalToolReceipt>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Append one immutable pre-format tool result. A repeated call ID is idempotent only when its canonical payload identity is unchanged.
Sourcefn list_canonical_tool_receipts<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
owner_id: &'life1 str,
run_id: &'life2 str,
) -> Pin<Box<dyn Future<Output = Result<Vec<CanonicalToolReceipt>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn list_canonical_tool_receipts<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
owner_id: &'life1 str,
run_id: &'life2 str,
) -> Pin<Box<dyn Future<Output = Result<Vec<CanonicalToolReceipt>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
List one owner’s canonical receipts for a run in stable execution order.
fn save_agent<'life0, 'life1, 'async_trait>(
&'life0 self,
agent: &'life1 AgentArtifact,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Sourcefn save_agent_if_unchanged<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
expected: &'life1 AgentArtifact,
updated: &'life2 AgentArtifact,
) -> Pin<Box<dyn Future<Output = Result<bool>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn save_agent_if_unchanged<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
expected: &'life1 AgentArtifact,
updated: &'life2 AgentArtifact,
) -> Pin<Box<dyn Future<Output = Result<bool>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Persist a merged agent only while the stored artifact matches the read baseline. A conflict returns false without overwriting another editor.
fn load_agent<'life0, 'life1, 'async_trait>(
&'life0 self,
id: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<Option<AgentArtifact>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn load_agent_by_name<'life0, 'life1, 'async_trait>(
&'life0 self,
name: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<Option<AgentArtifact>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn list_agents<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<Vec<AgentArtifact>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn save_memory<'life0, 'life1, 'async_trait>(
&'life0 self,
memory: &'life1 Memory,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn search_memory<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
agent_id: Option<&'life1 str>,
query_vec: &'life2 [f32],
limit: usize,
min_score: f32,
) -> Pin<Box<dyn Future<Output = Result<Vec<MemoryMatch>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Sourcefn compare_and_swap_global_presentation_policy<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
expected: &'life1 Value,
selection: &'life2 ResourceSelection,
) -> Pin<Box<dyn Future<Output = Result<bool>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn compare_and_swap_global_presentation_policy<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
expected: &'life1 Value,
selection: &'life2 ResourceSelection,
) -> Pin<Box<dyn Future<Output = Result<bool>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Change only global Presentation intent if the full saved policy still matches the supplied baseline. Missing or changed records return false.
Provided Methods§
Sourcefn list_skills<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<Vec<Skill>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn list_skills<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<Vec<Skill>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
List all persisted skills.
Sourcefn delete_skill<'life0, 'life1, 'async_trait>(
&'life0 self,
_id: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn delete_skill<'life0, 'life1, 'async_trait>(
&'life0 self,
_id: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Delete a skill by ID.
Sourcefn count_documents<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
owner_id: &'life1 str,
kb_id: &'life2 str,
) -> Pin<Box<dyn Future<Output = Result<usize>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn count_documents<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
owner_id: &'life1 str,
kb_id: &'life2 str,
) -> Pin<Box<dyn Future<Output = Result<usize>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Count documents in a knowledge base. Default impl uses list_documents;
providers should override with a backend-native COUNT query for efficiency.
Sourcefn delete_agent<'life0, 'life1, 'async_trait>(
&'life0 self,
_id: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn delete_agent<'life0, 'life1, 'async_trait>(
&'life0 self,
_id: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Delete an agent by ID.
Sourcefn upsert_settings_type<'life0, 'life1, 'async_trait>(
&'life0 self,
_st: &'life1 SettingsType,
) -> Pin<Box<dyn Future<Output = Result<Uuid>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn upsert_settings_type<'life0, 'life1, 'async_trait>(
&'life0 self,
_st: &'life1 SettingsType,
) -> Pin<Box<dyn Future<Output = Result<Uuid>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Upsert a settings type definition (core UAR namespace or plugin-provided).
Callers pass in the full struct including JSON Schema — idempotent on key.
Returns the actual id stored in the database: on a first insert this
matches st.id, but on a conflict-update the original row’s id is kept,
so callers must use the returned value when constructing FK references.
Sourcefn list_settings_types<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<Vec<SettingsType>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn list_settings_types<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<Vec<SettingsType>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
List all registered settings types.
Sourcefn get_settings_type<'life0, 'life1, 'async_trait>(
&'life0 self,
_key: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<Option<SettingsType>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn get_settings_type<'life0, 'life1, 'async_trait>(
&'life0 self,
_key: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<Option<SettingsType>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Get a settings type by key slug (e.g. “server”).
Sourcefn upsert_setting<'life0, 'life1, 'async_trait>(
&'life0 self,
_setting: &'life1 Settings,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn upsert_setting<'life0, 'life1, 'async_trait>(
&'life0 self,
_setting: &'life1 Settings,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Upsert a single setting value.
Implementations MUST validate setting.data against the parent type’s
JSON Schema (fetched via get_settings_type) and return Err if invalid.
Sourcefn get_setting<'life0, 'life1, 'async_trait>(
&'life0 self,
_key: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<Option<Settings>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn get_setting<'life0, 'life1, 'async_trait>(
&'life0 self,
_key: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<Option<Settings>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Get one setting by its unique dotted key (e.g. “server.port”).
Sourcefn list_settings<'life0, 'life1, 'async_trait>(
&'life0 self,
_type_key: Option<&'life1 str>,
_parent_id: Option<Uuid>,
) -> Pin<Box<dyn Future<Output = Result<Vec<Settings>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn list_settings<'life0, 'life1, 'async_trait>(
&'life0 self,
_type_key: Option<&'life1 str>,
_parent_id: Option<Uuid>,
) -> Pin<Box<dyn Future<Output = Result<Vec<Settings>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
List settings, optionally scoped to a type key and/or parent_id.
Sourcefn delete_setting<'life0, 'life1, 'async_trait>(
&'life0 self,
_key: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn delete_setting<'life0, 'life1, 'async_trait>(
&'life0 self,
_key: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Delete a setting by key (reset-to-default workflow).
Sourcefn insert_attachment<'life0, 'life1, 'async_trait>(
&'life0 self,
_meta: &'life1 AttachmentMeta,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn insert_attachment<'life0, 'life1, 'async_trait>(
&'life0 self,
_meta: &'life1 AttachmentMeta,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Persist attachment metadata after a file has been written to disk.
Sourcefn get_attachment<'life0, 'life1, 'async_trait>(
&'life0 self,
_id: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<Option<AttachmentMeta>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn get_attachment<'life0, 'life1, 'async_trait>(
&'life0 self,
_id: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<Option<AttachmentMeta>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Retrieve attachment metadata by ID.
Sourcefn list_attachments_for_session<'life0, 'life1, 'async_trait>(
&'life0 self,
_session_id: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<Vec<AttachmentMeta>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn list_attachments_for_session<'life0, 'life1, 'async_trait>(
&'life0 self,
_session_id: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<Vec<AttachmentMeta>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
List all attachments uploaded during a given chat session.
Sourcefn save_checkpoint<'life0, 'life1, 'async_trait>(
&'life0 self,
_checkpoint: &'life1 Checkpoint,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn save_checkpoint<'life0, 'life1, 'async_trait>(
&'life0 self,
_checkpoint: &'life1 Checkpoint,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Persist a graph execution checkpoint.
Sourcefn load_checkpoint<'life0, 'life1, 'async_trait>(
&'life0 self,
_id: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<Option<Checkpoint>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn load_checkpoint<'life0, 'life1, 'async_trait>(
&'life0 self,
_id: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<Option<Checkpoint>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Load a single checkpoint by its unique ID.
Sourcefn list_checkpoints<'life0, 'life1, 'async_trait>(
&'life0 self,
_run_id: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<Vec<Checkpoint>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn list_checkpoints<'life0, 'life1, 'async_trait>(
&'life0 self,
_run_id: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<Vec<Checkpoint>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
List all checkpoints recorded for a given run, ordered by creation time.
Sourcefn record_cost_entry<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
_scope: &'life1 str,
_scope_id: &'life2 str,
_cost_usd: f64,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn record_cost_entry<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
_scope: &'life1 str,
_scope_id: &'life2 str,
_cost_usd: f64,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Durably record one cost-budget spend event. CostBudgetTracker
(src/uar/runtime/cost_budget.rs) is intentionally in-memory-only for
the hot path; this is the durable roll-up layer its own doc comment
anticipated subscribing to. Default no-op so this remains additive for
any future PersistenceLayer implementer that doesn’t need history.
Sourcefn list_cost_history<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
_scope: &'life1 str,
_scope_id: &'life2 str,
) -> Pin<Box<dyn Future<Output = Result<Vec<CostEntry>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn list_cost_history<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
_scope: &'life1 str,
_scope_id: &'life2 str,
) -> Pin<Box<dyn Future<Output = Result<Vec<CostEntry>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
List durable cost-history entries for a (scope, scope_id), ordered by
recorded_at ascending.
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".