You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: packages/docs-site/guide/agenda.md
+4-2Lines changed: 4 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -16,7 +16,7 @@ An agenda **item** has a content, category, priority, optional due date, and a c
16
16
|`interval`| Milliseconds between fires |`86400000` (every 24h) |
17
17
|`cron`| 6-field cron (`sec min hour day month weekday`) |`0 0 9 * * 1-5` (9am weekdays) |
18
18
19
-
When a trigger fires it delivers its `message` to the bound session/channel using its `action` mode, and the fire is recorded in the `trigger_fire` log table (pure audit, not used for scheduling). One-shot `absolute`triggers retry briefly on delivery failure, then give up.
19
+
When a trigger fires it delivers its `message` to the bound session/channel using its `action` mode, and the fire is recorded in the `trigger_fire` log table (pure audit, not used for scheduling). A one-shot or finite schedule that reaches normal exhaustion becomes **Done**. A one-shot `absolute`trigger retries briefly on delivery failure; if it misses the grace window or gives up retrying, it is disabled and the item becomes **Expired** only when no other trigger on that item remains enabled. Expired items are retained as history rather than automatically deleted.
20
20
21
21
## Configuration
22
22
@@ -31,7 +31,9 @@ An **Agenda Profile** is the store + optional auto-sync. Sidebar → **Agenda Pr
31
31
32
32
Then, in an agent → **Agenda** section, toggle Agenda on and pick the profile. Enabling it registers the agenda tools; with a sync model, items are reconciled from the conversation automatically each turn.
33
33
34
-
From the Agenda Profiles page → **View** you can browse stored items, filter by pending/done, manually **Complete** / **Cancel**, add/edit/disable/reopen/delete triggers, fire a trigger manually for testing, and inspect each trigger's fire history.
34
+
AgendaSync normally uses one model call with the completed conversation and the full structure of every pending item. Only when that input exceeds the Sync Model budget does it reuse the same model to compress the conversation into explicit agenda-change intents, match compact cards in token-bounded batches (including item/trigger IDs, schedules, actions, and message previews), and give only the selected full records to the final sync pass. There is no separate Selector Model setting, and pending items are no longer cut off at a fixed count.
35
+
36
+
From the Agenda Profiles page → **View** you can browse stored items, filter by pending/done/cancelled/expired, manually **Complete** / **Cancel**, add/edit/disable/reopen/delete triggers, fire a trigger manually for testing, and inspect each trigger's fire history. Reopening an expired item restores only the item to Pending; retime or re-enable an appropriate trigger separately.
Copy file name to clipboardExpand all lines: packages/sbot/prompts/agenda/sync/default.txt
+2-2Lines changed: 2 additions & 2 deletions
Original file line number
Diff line number
Diff line change
@@ -38,8 +38,8 @@ Every existing item is rendered as:
38
38
39
39
Only ENABLED triggers are listed (disabled triggers are history; do not try to operate on them).
40
40
41
-
`status` may be pending / done / cancelled. ONLY operate on items with status="pending".
42
-
Items with status="done"or status="cancelled" are read-only history — never Edit them, never touch their triggers, never revive them by adding triggers. If the conversation seems to bring a done/cancelled item back to life, treat it as a NEW request and prefer Create (dedup still applies); do not resurrect the old one.
41
+
`status` may be pending / done / cancelled / expired. ONLY operate on items with status="pending".
42
+
Items with status="done", status="cancelled", or status="expired" are read-only history — never Edit them, never touch their triggers, never revive them by adding triggers. If the conversation seems to bring a terminal item back to life, treat it as a NEW request and prefer Create (dedup still applies); do not resurrect the old one.
43
43
44
44
`expr` semantics depend on `kind`:
45
45
- kind=absolute → ISO datetime string (the single fire moment)
Copy file name to clipboardExpand all lines: packages/sbot/prompts/agenda/tools/close.txt
+2Lines changed: 2 additions & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -5,6 +5,8 @@ Terminate an agenda item permanently — status set, ALL triggers disabled.
5
5
- dropped — "drop it / I don't want this / stop reminding me".
6
6
Same effect on the data; the difference is recorded intent.
7
7
8
+
`expired` is not an outcome accepted here. The scheduler records it automatically when a one-off reminder is missed or gives up delivery and no other trigger remains active.
9
+
8
10
DO NOT call this when the user reports finishing ONE occurrence of a recurring routine ("今天的水喝完了"). There is no per-occurrence check-in — closing would kill the whole routine. Acknowledge it and leave the item alone.
9
11
10
12
`at` (ISO, done only): the real completion moment when the user pinpoints a past one ("我昨天就交了"); omit for a plain "just did it".
How an item ends depends ONLY on its triggers — there is no completion-mode flag:
16
16
- no triggers (plain todo) → stays pending until agenda_close.
17
-
- one-off or finite trigger (single absolute fire, or count-bounded) → auto-closes once the schedule is exhausted; nobody needs to close it.
17
+
- one-off or finite trigger (single absolute fire, or count-bounded) → becomes done once the schedule reaches normal exhaustion; nobody needs to close it.
18
+
- a one-off trigger missed beyond its grace window, or still undeliverable after its retry window → becomes expired only when the item has no other enabled trigger. With another live trigger, the item stays pending.
18
19
- infinite recurring trigger → never auto-closes; ends only via agenda_close.
19
20
20
21
agenda_close ends the WHOLE item. On a recurring routine, "did it today" is NOT the end of the item — there is no per-occurrence check-in anywhere in this system. Acknowledge the report in conversation and leave the agenda untouched; the trigger keeps firing on its own.
@@ -49,6 +50,8 @@ To restate a full list ("from now on only 9 and 18"), send removes for the ones
49
50
50
51
agenda_close `outcome`: done = "I did it"; dropped = "drop it / stop reminding me". Both close the item and disable every trigger; only the recorded status differs. When the user merely reports progress on an ongoing routine, call NEITHER (see §2).
51
52
53
+
expired is a system-recorded terminal state for a missed one-off reminder, not an agenda_close outcome. It is retained as history rather than physically deleted.
54
+
52
55
# 7. CREATE — pitfalls
53
56
54
57
- Trust dedup: an "already exists" result IS success. Never pre-call agenda_list to check. That result also renders the existing item's triggers (ids, schedules, message previews) — if the user actually wanted a different cadence on it, go straight to agenda_edit with those ids.
0 commit comments