# Observability and incident management Version 1.2.0 | 11 November 2026 | Deliverable D13 | Part of the RJ AI Agent Guardrails and Evaluation Framework ## Contents - [1. Telemetry schema](#1-telemetry-schema) - [2. Detection mechanisms](#2-detection-mechanisms) - [3. Incident management](#3-incident-management) - [4. Log governance](#4-log-governance) ## 1. Telemetry schema Minimum per-run record set (all fields correlation-linked by run ID): | Field | Content | | --- | --- | | Agent identity and version | Which agent, which build, which configuration | | Model version | Exact model identifier and provider; record provider-side version notices | | Policy version | Guardrail register, behaviour policy and permission manifest versions in force | | Context provenance | Sources of context used (retrieval set IDs, memory scopes, tool inputs) - references, not raw payloads by default | | Tool invocations | Tool, validated arguments (redacted as needed), decision path, outcome, latency | | Tool authorisation | Permission tier evaluated, checks applied, approval grant ID if any | | Guardrail decisions | Which guardrails fired, with rule/version references | | Approval events | Grant metadata: approver, binding, expiry, consumption - logged as references and hashes. Never log the bearer grant token, nonce or any secret itself: a logged token is a replayable credential | | Agent handoffs | Delegation tree: per-hop scopes, contracts, outcomes | | Execution traces | Step-level trajectory of observable actions, states and decision metadata (never hidden chain-of-thought) sufficient to audit decisions. Model outputs are not bit-identical across versions, so traces support audit and re-evaluation, not guaranteed deterministic replay | | Error events | Failures, retries, circuit-breaker trips, fallbacks | | Resource consumption | Tokens, cost, time, per run and per tenant | | Final task outcome | Verifiable end state and the agent's own report (kept distinct - AT-30) | The OpenTelemetry GenAI semantic conventions (emerging industry specification, still stabilising as of late 2026) are the natural wire format where adopted; treat their agent-span work as the direction, pin what you implement. ## 2. Detection mechanisms - Real-time anomaly detection: baseline per-run cost, step count, tool mix, data volumes; alert on deviation. Baselines come from the deployment's own history (D10), not imported numbers. - Guardrail violation alerts: every critical guardrail event pages within minutes; non-critical events aggregate into daily review. - Suspicious tool activity: watch for novel tool use, argument distribution shifts, sequences matching known exfiltration shapes, and tool output volumes inconsistent with the task. - Runaway execution detection: bound-consumption rate alerts before limits hit; loop signatures (repeated identical calls, cyclic delegation) trigger automatic circuit breakers. - Drift monitors: scheduled canary evaluations against pinned golden tasks detect silent provider-side model changes. - All detection produces incidents or recorded dismissals; an alert stream nobody reviews is not a control (L4 rule). ## 3. Incident management Severity classes (orientation, calibrate per organisation): - SEV1: unauthorised external action, confirmed data disclosure, active compromise, uncontrolled spend. Immediate containment. - SEV2: guardrail bypass in testing reaching production path, privilege anomalies, repeated injection success. - SEV3: single control failures contained by design; near-misses. Response mechanics: - Emergency termination: kill switch halting all agent execution; capability freeze disabling specific tools/integrations while the rest runs (the common case - full shutdown is the exception). - Containment: revoke credentials, isolate integrations, quarantine memory/corpus partitions, freeze approvals. - Recovery and rollback: restore to known-good configuration; verify state integrity before restart; risk-approver sign-off for restart after SEV1/2. - Post-incident: timeline from traces (not from agent self-report), root cause, new D9 dataset cases, control changes, D17 updates. Blameless for reporters; nobody is sanctioned for surfacing failure or invoking the kill switch in good faith. ## 4. Log governance Agent traces concentrate sensitive data; the observability pipeline is itself an attack surface (D2 section 4.16). - Minimisation: log references and redacted forms by default; full payloads only under controlled, time-limited debug capture. - Access control: trace access is role-based, itself logged, and reviewed; red-team artefacts and adversarial content are access-restricted. - Retention: defined schedules balancing investigation needs against data-minimisation obligations; deletion is executed and evidenced, including from backups on their cycle. - Integrity: tamper-evident central storage; local agent-side logs are never the only copy. - Safety: log content is untrusted in downstream tooling (dashboards, query tools); parse defensively against log injection. - Privacy: telemetry design is reviewed by the data protection owner; regulated jurisdictions may constrain what may be logged at all - resolve with counsel where applicable.