pub struct LocalSessionStore { /* private fields */ }Expand description
Shared session store adapter backed by the CLI local SQLite store.
Implementations§
Trait Implementations§
Source§impl Clone for LocalSessionStore
impl Clone for LocalSessionStore
Source§fn clone(&self) -> LocalSessionStore
fn clone(&self) -> LocalSessionStore
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for LocalSessionStore
impl Debug for LocalSessionStore
Source§impl SessionStore for LocalSessionStore
impl SessionStore for LocalSessionStore
Source§fn save_session<'life0, 'async_trait>(
&'life0 self,
session: SessionRecord,
) -> Pin<Box<dyn Future<Output = SessionStoreResult<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn save_session<'life0, 'async_trait>(
&'life0 self,
session: SessionRecord,
) -> Pin<Box<dyn Future<Output = SessionStoreResult<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Save a session record.
Source§fn load_session<'life0, 'life1, 'async_trait>(
&'life0 self,
session_id: &'life1 SessionId,
) -> Pin<Box<dyn Future<Output = SessionStoreResult<SessionRecord>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn load_session<'life0, 'life1, 'async_trait>(
&'life0 self,
session_id: &'life1 SessionId,
) -> Pin<Box<dyn Future<Output = SessionStoreResult<SessionRecord>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Load a session record.
Source§fn list_sessions<'life0, 'async_trait>(
&'life0 self,
filter: SessionFilter,
) -> Pin<Box<dyn Future<Output = SessionStoreResult<Vec<SessionRecord>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn list_sessions<'life0, 'async_trait>(
&'life0 self,
filter: SessionFilter,
) -> Pin<Box<dyn Future<Output = SessionStoreResult<Vec<SessionRecord>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
List sessions by optional filter.
Source§fn update_session_status<'life0, 'life1, 'async_trait>(
&'life0 self,
session_id: &'life1 SessionId,
status: SessionStatus,
) -> Pin<Box<dyn Future<Output = SessionStoreResult<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn update_session_status<'life0, 'life1, 'async_trait>(
&'life0 self,
session_id: &'life1 SessionId,
status: SessionStatus,
) -> Pin<Box<dyn Future<Output = SessionStoreResult<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Update session status.
Source§fn save_context_state<'life0, 'life1, 'async_trait>(
&'life0 self,
session_id: &'life1 SessionId,
state: ResumableState,
) -> Pin<Box<dyn Future<Output = SessionStoreResult<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn save_context_state<'life0, 'life1, 'async_trait>(
&'life0 self,
session_id: &'life1 SessionId,
state: ResumableState,
) -> Pin<Box<dyn Future<Output = SessionStoreResult<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Save a context state snapshot for a session.
Source§fn save_environment_state<'life0, 'life1, 'async_trait>(
&'life0 self,
session_id: &'life1 SessionId,
environment_state: EnvironmentStateRef,
) -> Pin<Box<dyn Future<Output = SessionStoreResult<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn save_environment_state<'life0, 'life1, 'async_trait>(
&'life0 self,
session_id: &'life1 SessionId,
environment_state: EnvironmentStateRef,
) -> Pin<Box<dyn Future<Output = SessionStoreResult<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Save an environment state reference for a session.
Source§fn append_run<'life0, 'async_trait>(
&'life0 self,
run: RunRecord,
) -> Pin<Box<dyn Future<Output = SessionStoreResult<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn append_run<'life0, 'async_trait>(
&'life0 self,
run: RunRecord,
) -> Pin<Box<dyn Future<Output = SessionStoreResult<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Append or replace a run record.
Source§fn load_run<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
session_id: &'life1 SessionId,
run_id: &'life2 RunId,
) -> Pin<Box<dyn Future<Output = SessionStoreResult<RunRecord>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn load_run<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
session_id: &'life1 SessionId,
run_id: &'life2 RunId,
) -> Pin<Box<dyn Future<Output = SessionStoreResult<RunRecord>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Load a run record.
Source§fn list_runs<'life0, 'life1, 'async_trait>(
&'life0 self,
session_id: &'life1 SessionId,
) -> Pin<Box<dyn Future<Output = SessionStoreResult<Vec<RunRecord>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn list_runs<'life0, 'life1, 'async_trait>(
&'life0 self,
session_id: &'life1 SessionId,
) -> Pin<Box<dyn Future<Output = SessionStoreResult<Vec<RunRecord>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
List runs for a session.
Source§fn update_run_status<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
session_id: &'life1 SessionId,
run_id: &'life2 RunId,
status: RunStatus,
output_preview: Option<String>,
) -> Pin<Box<dyn Future<Output = SessionStoreResult<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn update_run_status<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
session_id: &'life1 SessionId,
run_id: &'life2 RunId,
status: RunStatus,
output_preview: Option<String>,
) -> Pin<Box<dyn Future<Output = SessionStoreResult<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Update run status and optional output preview.
Source§fn append_checkpoint<'life0, 'life1, 'async_trait>(
&'life0 self,
session_id: &'life1 SessionId,
checkpoint: AgentCheckpoint,
) -> Pin<Box<dyn Future<Output = SessionStoreResult<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn append_checkpoint<'life0, 'life1, 'async_trait>(
&'life0 self,
session_id: &'life1 SessionId,
checkpoint: AgentCheckpoint,
) -> Pin<Box<dyn Future<Output = SessionStoreResult<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Append a full runtime checkpoint.
Source§fn load_checkpoints<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
session_id: &'life1 SessionId,
run_id: &'life2 RunId,
) -> Pin<Box<dyn Future<Output = SessionStoreResult<Vec<AgentCheckpoint>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn load_checkpoints<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
session_id: &'life1 SessionId,
run_id: &'life2 RunId,
) -> Pin<Box<dyn Future<Output = SessionStoreResult<Vec<AgentCheckpoint>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Load checkpoints for a run in insertion order.
Source§fn append_stream_records<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
session_id: &'life1 SessionId,
run_id: &'life2 RunId,
records: Vec<AgentStreamRecord>,
) -> Pin<Box<dyn Future<Output = SessionStoreResult<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn append_stream_records<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
session_id: &'life1 SessionId,
run_id: &'life2 RunId,
records: Vec<AgentStreamRecord>,
) -> Pin<Box<dyn Future<Output = SessionStoreResult<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Append runtime stream records used as resume evidence.
Source§fn replay_stream_records<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
session_id: &'life1 SessionId,
run_id: &'life2 RunId,
) -> Pin<Box<dyn Future<Output = SessionStoreResult<Vec<AgentStreamRecord>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn replay_stream_records<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
session_id: &'life1 SessionId,
run_id: &'life2 RunId,
) -> Pin<Box<dyn Future<Output = SessionStoreResult<Vec<AgentStreamRecord>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Replay runtime stream records for a run.
Source§fn replay_stream_records_after<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
session_id: &'life1 SessionId,
run_id: &'life2 RunId,
after_sequence: Option<usize>,
) -> Pin<Box<dyn Future<Output = SessionStoreResult<Vec<AgentStreamRecord>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn replay_stream_records_after<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
session_id: &'life1 SessionId,
run_id: &'life2 RunId,
after_sequence: Option<usize>,
) -> Pin<Box<dyn Future<Output = SessionStoreResult<Vec<AgentStreamRecord>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Replay runtime stream records after a sequence cursor.
Source§fn save_stream_cursor<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
session_id: &'life1 SessionId,
run_id: &'life2 RunId,
cursor: StreamCursorRef,
) -> Pin<Box<dyn Future<Output = SessionStoreResult<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn save_stream_cursor<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
session_id: &'life1 SessionId,
run_id: &'life2 RunId,
cursor: StreamCursorRef,
) -> Pin<Box<dyn Future<Output = SessionStoreResult<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Store a stream cursor reference for a run and session.
Source§fn append_approval<'life0, 'async_trait>(
&'life0 self,
approval: ApprovalRecord,
) -> Pin<Box<dyn Future<Output = SessionStoreResult<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn append_approval<'life0, 'async_trait>(
&'life0 self,
approval: ApprovalRecord,
) -> Pin<Box<dyn Future<Output = SessionStoreResult<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Append an approval record.
Source§fn load_approvals<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
session_id: &'life1 SessionId,
run_id: &'life2 RunId,
) -> Pin<Box<dyn Future<Output = SessionStoreResult<Vec<ApprovalRecord>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn load_approvals<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
session_id: &'life1 SessionId,
run_id: &'life2 RunId,
) -> Pin<Box<dyn Future<Output = SessionStoreResult<Vec<ApprovalRecord>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Load approval records for a run.
Source§fn append_deferred_tool<'life0, 'async_trait>(
&'life0 self,
record: DeferredToolRecord,
) -> Pin<Box<dyn Future<Output = SessionStoreResult<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn append_deferred_tool<'life0, 'async_trait>(
&'life0 self,
record: DeferredToolRecord,
) -> Pin<Box<dyn Future<Output = SessionStoreResult<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Append a deferred tool record.
Source§fn load_deferred_tools<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
session_id: &'life1 SessionId,
run_id: &'life2 RunId,
) -> Pin<Box<dyn Future<Output = SessionStoreResult<Vec<DeferredToolRecord>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn load_deferred_tools<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
session_id: &'life1 SessionId,
run_id: &'life2 RunId,
) -> Pin<Box<dyn Future<Output = SessionStoreResult<Vec<DeferredToolRecord>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Load deferred tool records for a run.
Source§fn compact_run_trace<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
session_id: &'life1 SessionId,
run_id: &'life2 RunId,
) -> Pin<Box<dyn Future<Output = SessionStoreResult<CompactRunTrace>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn compact_run_trace<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
session_id: &'life1 SessionId,
run_id: &'life2 RunId,
) -> Pin<Box<dyn Future<Output = SessionStoreResult<CompactRunTrace>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Return compact run trace projection.
Source§fn compact_session_trace<'life0, 'life1, 'async_trait>(
&'life0 self,
session_id: &'life1 SessionId,
) -> Pin<Box<dyn Future<Output = SessionStoreResult<CompactSessionTrace>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn compact_session_trace<'life0, 'life1, 'async_trait>(
&'life0 self,
session_id: &'life1 SessionId,
) -> Pin<Box<dyn Future<Output = SessionStoreResult<CompactSessionTrace>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Return compact session trace projection.
Source§fn latest_checkpoint<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
session_id: &'life1 SessionId,
run_id: &'life2 RunId,
) -> Pin<Box<dyn Future<Output = Result<Option<AgentCheckpoint>, SessionStoreError>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Self: 'async_trait,
fn latest_checkpoint<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
session_id: &'life1 SessionId,
run_id: &'life2 RunId,
) -> Pin<Box<dyn Future<Output = Result<Option<AgentCheckpoint>, SessionStoreError>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Self: 'async_trait,
Load the latest checkpoint for a run.
Source§fn resume_snapshot<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
session_id: &'life1 SessionId,
run_id: &'life2 RunId,
) -> Pin<Box<dyn Future<Output = Result<SessionResumeSnapshot, SessionStoreError>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Self: 'async_trait,
fn resume_snapshot<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
session_id: &'life1 SessionId,
run_id: &'life2 RunId,
) -> Pin<Box<dyn Future<Output = Result<SessionResumeSnapshot, SessionStoreError>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Self: 'async_trait,
Load a resume snapshot from session, checkpoint, and stream evidence.
Auto Trait Implementations§
impl Freeze for LocalSessionStore
impl RefUnwindSafe for LocalSessionStore
impl Send for LocalSessionStore
impl Sync for LocalSessionStore
impl Unpin for LocalSessionStore
impl UnsafeUnpin for LocalSessionStore
impl UnwindSafe for LocalSessionStore
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