agentstategraph_reminders/lib.rs
1//! Agent reminder substrate for AgentStateGraph.
2//!
3//! Reminders are future-oriented, pull-based scheduling primitives for
4//! agents. An agent (or user) creates a reminder with a due time,
5//! instructions, and optional soft references to branches, memories,
6//! plans, or tasks. At any checkpoint the agent calls `remind_me()` to
7//! retrieve due reminders ordered by priority, then acts on them.
8//!
9//! ## Key concepts
10//!
11//! - **Pull-based**: nothing is pushed to agents; they poll `remind_me()`
12//! at natural checkpoints (session start, task completion, etc.).
13//! - **Autonomous flag**: `autonomous: true` means the agent may execute
14//! without asking; `false` requires explicit user approval first.
15//! - **Soft refs**: reminders may reference branches, memories, plans,
16//! or tasks by ID. Refs are advisory — the reminder is not invalidated
17//! if the referenced object is deleted; the ref is marked stale instead.
18//! - **Repeating schedules**: `Schedule::Interval`, `::Daily`, `::Weekly`
19//! cause `record_execution` to automatically compute the next `due_at`
20//! and reset status to `Pending`.
21
22pub mod error;
23pub mod manager;
24pub mod memory;
25pub mod store;
26pub mod types;
27
28pub use error::ReminderError;
29pub use manager::ReminderManager;
30pub use memory::MemoryReminderStore;
31pub use store::{ReminderStore, same_reminder};
32pub use types::{
33 CreateReminder, ExecutionRecord, ExecutionResult, Priority, RefKind, Reminder, ReminderFilter,
34 ReminderRef, ReminderStatus, Schedule,
35};