DET-199 · agent · confidence High

Keeping an Outside Record of Agent Actions

Write every agent step to a log the agent cannot read or edit, then check that real side effects match it.

An agent's own logs are only as honest as the agent and its runtime. This detection builds a separate, append-only record of each prompt, tool call, argument, result, approval and downstream change, all tied to one run ID. The record lives outside the agent's credentials and sandbox.

The value comes from reconciliation. If a database row changed and no tool call explains it, or a tool call has no arguments, or sequence numbers skip, something is wrong with the agent, the pipeline, or both. It also lets an investigator answer what instruction led to which action.

Data sources
Agent gateway logsTool broker logsApplication audit logsCloud control-plane logsAppend-only log store (WORM bucket)
Platforms
AI PlatformAWSSaaS

Logic

1. Stamp every agent run with a run_id and pass it to tools and downstream APIs.
2. Hunt: SELECT d.* FROM downstream_changes d LEFT JOIN agent_trace t ON d.run_id = t.run_id AND d.request_id = t.request_id WHERE d.actor = 'svc-agent' AND t.request_id IS NULL.
3. Alert on gaps in per-run sequence numbers, tool calls with empty args or results, and any agent identity touching the log bucket or log config.

False positives

Retries, batch jobs and tool timeouts can leave a few unmatched rows. Tune by comparing against a week of known-good runs.

Catches 12 techniques