Compliance Guide
LLM Audit Log Format for Regulators
A regulator-ready LLM log is a structured, machine-readable record in which every prompt, response, tool call, and policy decision shares a correlation identifier, names the human, service, and agent involved, carries a synchronized timestamp, and is protected against alteration.
Treat logs as evidence, not debugging output
A record prepared for regulator production has four properties. The table summarizes the reference record used in the rest of this guide.
| Property | What it means |
|---|---|
| Attributed | User, service account, and agent identity on every event. |
| Correlated | One trace identifier across prompt, tool call, and policy decision. |
| Structured | Versioned schema in a machine-readable export format. |
| Tamper-evident | Synchronized timestamps and verifiable integrity protection. |
A reference log record structure
Each event should be one self-contained record with a versioned schema. Line-delimited JSON is a common choice because it is machine-readable, append-friendly, and easy to filter and export. The record should carry six groups of fields.
| Field group | What to record |
|---|---|
| 1. Identity | Human user, service account, agent identifier, and tenant or business unit, recorded separately so that delegated actions can be traced to a person. |
| 2. Correlation | Trace or request identifier, session identifier, parent event reference, and sequence number to reconstruct order across providers, gateways, and agent runtimes. |
| 3. Interaction | Model identifier and version, relevant parameters, and the prompt and response, stored in full, as references, or as hashes depending on minimization decisions. |
| 4. Tool calls | Tool name, arguments, target system, approval status, result, and errors for every action an agent attempts, including denied ones. |
| 5. Policy decisions | Policy identifier and version, the decision (allow, deny, modify, escalate), the reason, and any redaction applied. |
| 6. Integrity and time | UTC timestamp from a synchronized source, schema version, record hash, and a link to the previous record or a signature. |
Integrity properties that make records defensible
The sixth field group carries the integrity properties: a UTC timestamp from a synchronized source, a schema version, a record hash, and a link to the previous record or a signature. Together they let you show that records were not altered and explain how timestamps were synchronized.
Balancing completeness with minimization and retention
Prompts and responses can be stored in full, as references, or as hashes, depending on minimization decisions. Where redaction is applied, the policy decision record should capture it. Content, retention, and format requirements vary by regime, so confirm them with counsel.
Why the enforcement layer produces more uniform evidence
Runtime governance and audit logging can support consistent, defensible records of AI agent activity. Capturing the policy identifier, version, decision, and reason with each event is one way to keep evidence uniform across the systems involved.
Test your current logging against a regulator request
Use these questions to find gaps in your current logging.
- Can one trace identifier link the prompt, response, tool calls, and policy decisions across every system involved?
- Does each event name the human user, service account, and agent, rather than only an API key?
- Are denied and escalated tool calls recorded, not just successful ones?
- Is the policy version in force at that moment captured with each decision?
- Can you show that records were not altered, and explain how timestamps were synchronized?
- Can you export a filtered set in a structured format, with redactions logged and a hashed manifest?