Book a demo
JSON Schema · 2020-12

The JSON Schema for one agent audit record

An audit trail is not a log file. It is one record per action — allowed or denied — that names who the agent was acting for, what it tried to do, which policy decided, what happened, and a signature over the whole thing. This is that record as a JSON Schema, plus a worked example.

The shape is informed by EU AI Act Article 12 (automatic event logs over the lifetime of a high-risk system) and Article 26(6) (deployers keep logs at least six months). Those are the floor, not the design: the fields are the ones a reviewer needs to reconstruct a run without asking the model what it did.

What is inside

SectionWhat it covers
Required fieldsrecord_id, trace_id, timestamp, principal, action, policy, result, signature.
Principal blockAgent identity, the human on whose behalf it acted, and the scope the call ran under.
Policy blockWhich policy version decided, the verdict, and the reason a reviewer can read.
SignatureA record missing its signature is rejected by the schema — unsigned evidence does not survive an examination.

How to use it

  1. Validate your current log output against the schema. Most teams find they are missing the on-behalf-of principal or the policy version.
  2. Decide which fields you already emit and which need a gateway or SDK change.
  3. Set retention to the longest period any rule you face requires, not the shortest one you can defend.
  4. Sign at write time. Re-signing a batch later proves the batch was intact, not that the individual action was.
  5. Test reconstruction: pick a run from last month and rebuild it from records alone.

What should an AI agent audit record contain?

What is an AI agent audit record?

One record per agent action that captures the principal, the requested action and its arguments, the policy decision and version, the approver if one was required, and the result. It is the unit a reviewer or examiner replays to establish what happened.

Is this the same as observability tracing?

No. A trace explains performance and flow; an audit record establishes permission and accountability. Traces are usually sampled and retained briefly, which is the opposite of what evidence retention requires. Most teams need both.

How long should records be kept?

At least as long as the longest rule that applies to you. The EU AI Act sets six months for deployers of high-risk systems; financial-services record-keeping often runs longer. Set retention from the rule, not from storage cost.

Where this fits