Skip to content

Observe sessions and recorded usage in the Janitor dashboard - #26

Merged
IMax153 merged 1 commit into
mainfrom
t3code/implement-session-observation
Sep 13, 2026
Merged

IMax153 merged 1 commit into
mainfrom
t3code/implement-session-observation

Conversation

@IMax153

@IMax153 IMax153 commented Sep 13, 2026

Copy link
Copy Markdown
Member

Summary

  • Add paginated session list and detail views with execution state, activity, usage, associations, delivery warnings, and freshness.
  • Add Access- and membership-gated session APIs and live updates with reconnect and stale-data handling.
  • Project session execution and cumulative usage atomically, including rejection and historical-failure handling.
  • Add session observation migrations, dashboard routes, and comprehensive backend and web tests.

Testing

  • vp check passed with warnings and no errors.
  • Full backend and web test suite passed.
  • Runner-backed suites remain skipped because isolated runner dependencies are not installed.
  • No live Slack, GitHub, runner, or deployment validation was performed.

Ticket 04: teammates browse ongoing agent sessions and open a session's
facts with execution state and reason, meaningful activity, recorded token
usage, delivery warnings and projection freshness.

- Migration 0028 adds the team-wide `sessions` live channel with invalidation
  triggers on the session projection, session identity, thread associations,
  delivery health, catch-up freshness and membership. Intent commits with the
  change; catch-up and delivery cron wakes forward it.
- `SessionObservation` composes one read model over Janitor's session
  identity, the runner-projected facts and the delivery records: keyset-paged
  list ordered working first, then activity, then session id; compact detail
  with pending inputs, latest error and pending delivery. Usage is shown as
  input plus cache read/write and output plus reasoning, unavailable until
  the first snapshot.
- Accepted input is meaningful activity and moves an idle or failed session
  to working; a terminal admission rejection marks it failed; runner holds are
  blocked with their reason.
- Routes under /api/v1/sessions sit behind Access and active membership. The
  live channel rechecks membership at the boundary and removal closes open
  subscriptions.
- The web dashboard at /sessions reuses the live socket, reconnect and
  fallback pattern, coalesces invalidations during a read, preserves loaded
  pages on refresh and keeps last known data with a stale indication.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
@IMax153
IMax153 merged commit de14e0a into main Sep 13, 2026
1 check passed
@IMax153
IMax153 deleted the t3code/implement-session-observation branch September 13, 2026 12:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant