Skip to main content

fetch_recent_events

Function fetch_recent_events 

Source
pub async fn fetch_recent_events(
    store: &SqliteStore,
    session_id: &str,
    limit: usize,
) -> Result<Vec<EpisodicEvent>, MemoryError>
Expand description

Retrieve recent events for a session (context for causal linking).

Returns the most recent limit events ordered by creation time descending.

ยงErrors

Returns an error if the database query fails.