Session Diagnostics
manage_diagnosticsManage session diagnostics and maintenance: summarize or compact audit logs, verify/replay state, run visibility checks, report health, subscribe, reassign categories, and append/read events.
Instructions
Manage session diagnostics and maintenance surfaces separate from play-facing session controls. compress summarizes the audit log while compact prunes it irreversibly; verify compares live state with recorded hashes and replay reads the retained log, and both are read-only; visibility_check records its decision in the audit log while visibility_audit reads recent decisions; health, subscribe, and category reassignment do not change Novel content. compact is GM-only. Use when: reporting health, summarizing or compacting the audit log, subscribing, reassigning a category, appending/reading the event log, verifying or replaying state, or scanning a draft for GM-only disclosure. Do NOT use when: recapping play, setting verbosity, or reordering the briefing — use manage_session.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| mode | No | normal or terse (verbosity). | |
| text | No | Observation text (event). | |
| tier | No | Compression tier to assemble (recap; REQ-592). | |
| query | No | Optional search term matched against tool name, description, and title (discover). | |
| action | Yes | health, context_report, compress, compact, subscribe, category, event, history, verify, replay, visibility_check, or visibility_audit. | |
| detail | No | discover response detail: summary (default) or schema (live input schemas for the matches; requires query; REQ-609). | |
| source | No | Event source classification (event). | |
| topics | No | Notification topics to subscribe to (subscribe). | |
| audience | No | Audience badge for a visibility check (visibility_check; default the active badge). | |
| category | No | New category label, or null/empty to restore the default (category). | |
| gm_notes | No | GM-only free-text notes returned only to the Game Master badge (recap). | |
| ordinals | No | Exact event ordinals to return in order (history; REQ-591). | |
| sections | No | Ordered list of briefing sections (briefing_order). | |
| sessions | No | Number of recent sessions to retain live; triggers irreversible compaction (compact; default TTRPG_AUDIT_RETENTION_SESSIONS). | |
| to_event | No | Target event ordinal for replay inspection (replay; default the newest retained entry). | |
| supersede | No | Ordinal of an event this observation replaces (event). | |
| tool_name | No | Registered tool name to reassign (category). | |
| session_id | No | Archived session id to include in recap (recap). | |
| max_entries | No | Positive integer; returns a non-mutating summarize prompt over the most recent entries (compress). | |
| budget_tokens | No | Positive token budget for tier assembly (recap; REQ-592) or for ledger packing (context_report; REQ-610). | |
| through_ordinal | No | Return events up to and including this ordinal (history). | |
| include_superseded | No | Include superseded events (history; default true). |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| text | No | Human-readable text envelope mirroring the structured result (REQ-001, REQ-548a). | |
| status | Yes | Machine-readable result status: OK, NEED_INPUT, WARNING, PARTIAL, or an error category (REQ-002, REQ-548c). |