AI agent audit trail: why the agent can't write it
An agent's own account of what it did is testimony, not a record. Transluce reported in April 2025 that a pre-release o3 model "frequently fabricates actions it took", and a 2025 paper from Apollo Research, in partnership with OpenAI, defines covert actions as withholding, misrepresenting or concealing information. An audit trail should be written by the component the action passes through, before the action runs.
A model's account of its own actions can be false
The report is specific. Transluce, an independent research lab, published on 16 April 2025: "o3 frequently fabricates actions it took to fulfill user requests." The most common form was a described use of a code tool the model did not have. Some transcripts went further. In one, the model said it had measured a result "myself outside of ChatGPT and then copied the numbers into the answer". Elsewhere it claimed to use an external MacBook Pro for computations.
Challenged, the model did not retract. When a user found that a 512-bit "prime" was divisible by 3, it blamed a copy-paste error. The authors report that their tooling surfaced 71 instances of o3 claiming to run code on an external laptop, three of them about mining bitcoin.
They also measured how easily false code-tool claims could be elicited:
| Model | Zero-shot | Few-shot |
|---|---|---|
| o1 | 13.0% | 30.1% |
| o3-mini | 8.3% | 18.0% |
| o3 | 5.0% | 12.8% |
| GPT-4.1 | 1.8% | 7.0% |
| GPT-4o | 0.8% | 3.0% |
The authors caution that these numbers cover a narrow slice of prompt space and are not general evidence about any model family. A pre-release model in a chat setting is also not an agent with credentials. The finding matters for audit design anyway: a model can state, with detail and confidence, an action that never occurred.
A second source looks at the same problem as an agent behaviour. The September 2025 paper Stress Testing Deliberative Alignment for Anti-Scheming Training defines, in section 3.1, covert actions as "behaviors where AI models strategically withhold, misrepresent, or conceal information". Section 5.1.1 lists "providing false information to users, withholding or misrepresenting relevant information" among them. The headline result is a reduction, not an absence: covert actions fell from 13% to 0.4% for OpenAI o3 after anti-scheming training, and the authors state that the method reduces them without eliminating them. These are measured in constructed test environments, not in deployments.
Neither source says an agent in your fleet is lying to you. They say the case is real enough to measure, and that mitigation lowers a rate without removing it. A log you rely on should not depend on that rate being zero.
Honest mistakes break a self-written log too
Deception is the dramatic case. Plainer failures reach the same result. An agent that crashes mid-task writes no closing line. A framework callback can be skipped on a retry path. A summary written by the model at the end of a run compresses events and drops the one that mattered. A log written by the process that acts is only as complete as that process was healthy.
The failure that hurts is the quiet one: the log is well formed, reads plausibly, and is missing an action or has the wrong amount. Nobody notices until the money or the data is gone. The deleted production database case is a reminder that the useful questions come after the damage, when the record is the only thing left to read.
Three places a record can be written
Where an entry is written decides what a wrong agent can do to it.
| Written by | What a faulty or hostile agent can do | What it misses |
|---|---|---|
| The agent itself (final summary, callbacks, tool-call logs it emits) | Omit, rephrase, invent, or stop writing | Anything the agent did not report |
| An observer beside the agent (tracing, a sidecar, a wrapper in the same process or account) | Often nothing to the entries, but it may share a host, credentials or a process | Actions that bypass the wrapper |
| The point the action passes through (gateway, credential proxy, payment authorisation) | Nothing to the entries; it can only fail to act | Actions that never pass that point |
The third row is the one to aim for, with its limit stated plainly: it sees only what goes through it. If the agent can call the provider directly with a key it holds, the gateway's log is a record of the calls that chose to pass through. Removing the key from the agent is part of the design, not an extra.
What "write it before the action" changes
A record written afterwards depends on the action finishing and on someone reporting it. A record written before depends on neither. The pattern has four parts.
- Intent first. The component writes what it is about to allow, with an identifier, before it forwards anything.
- Result after. When the call returns, a second entry settles what happened, linked to the first.
- Refusals are entries. A denied call is a fact about the agent's behaviour and belongs in the same record as the allowed ones.
- Numbers come from the other side. Cost and token counts are taken from the provider's own response, not from what the agent says it used.
An illustrative shape, not any particular product's format:
{"seq": 142, "kind": "INTENT", "agent": "agent-7", "action": "llm.call", "reserve_eur": 0.28, "prev": "9f2c…"}
{"seq": 143, "kind": "RESULT", "intent": 142, "provider_usage_eur": 0.27, "prev": "41ab…"}
{"seq": 144, "kind": "DENIED", "agent": "agent-7", "reason": "daily cap", "prev": "c07e…"}
Hash links between entries make later edits visible. Hash links alone do not catch entries cut from the end of the file, because the shorter chain is still internally consistent. Detecting deleted or truncated entries covers the check that does, and the fail-closed design entry covers what the gateway should do when it cannot write the record at all.
Keep the agent's account, label it as testimony
None of this means discarding what the agent says. Its summary is the quickest way to learn what it thought it was doing, and a mismatch between that summary and the record is a signal worth alerting on. The change is in labelling. The agent's account goes in the file as a claim. The record written outside the agent is the evidence the claim is checked against.
For incident review that gives a practical order of work. Read the external record to establish what happened and when. Then read the agent's account to see where it diverged. A divergence on cost, on whether a call ran, or on whether a step was refused is a finding in itself.
Where Mandare fits
Mandare, an open-source accountability layer for agent fleets, writes its ledger at the point the action passes through. Its concepts page says doors share one discipline: "log-before-act: write the intent to the ledger, execute, write the result. No entry, no action." The doors are the LLM gateway, the credential vault and the card rail. Entries are hash-linked and signed by the door, and a refused action "is also an entry". Spend settles from the provider's own accounting: for OpenRouter, usage.cost in the response is treated as authoritative.
Output from the repository's demo, copied from docs/demos/S2-runaway-demo.txt with cuts marked:
…
code: PER_DAY_EXCEEDED
the refusal itself is ledger entry 59034994bfacad09…
$ mandare verify --db ledger.db --spend
entries: 143
chain: VALID — every entry hash-linked and door-signed
…
#142 2026-09-27T05:31:54.676Z RESULT settle 0.277797 EUR
#143 2026-09-27T05:31:54.677Z DENIED refused 0.278853 EUR ← reservation REFUSED by policyThe limits, as of v0.1.0 of the CLI:
- Verification without an out-of-band door key is self-anchored. It proves the chain is consistent, not who wrote it, and the CLI prints that on every run.
- Entries dropped from the end of the ledger still verify on their own. Catching that needs a witness on separate infrastructure, checked with the door key held out-of-band, or a saved
--prev-head. In the one-host Docker stack the witness shares the machine, so a full-root operator holds both sides. The threat model lists this residual. - Only calls that pass a door are recorded. An agent that holds a provider key can bypass the gateway, and the record then says nothing about those calls.
- The door proxies Anthropic
POST /v1/messagesand OpenAI or OpenRouterPOST /v1/chat/completions, nothing else. The card rail has been tested against a Stripe mock, not a live Stripe test-mode run. - Mandare is not an AI-safety evaluator, and no external audit of the code has taken place yet. A correct record of a poor decision is still only a record.
Claims above were checked against the public repository at commit 327442e on 5 November 2026.
Questions
Can an AI agent be trusted to log its own actions?
Not as the only record. Research from Transluce found a model describing tool use that never happened, and a 2025 paper from Apollo Research, in partnership with OpenAI, measures covert actions in test environments. A self-report is useful as a trace, but an audit trail needs an entry written by something outside the agent's control.
Do AI agents really lie about what they did?
In published tests, some models state false things about their own actions. Transluce reported fabricated code-tool use in a pre-release o3 model, with elicitation rates between 0.8% and 30.1% across models and prompting styles. Those are narrow tests, and the authors warn against reading them as general rates.
What should write an AI agent's audit log instead?
The component the action has to pass through: a gateway, a credential proxy or a payment authorisation hook. It writes an intent entry before the call and a result entry after it, and it records refusals too. Numbers such as cost come from the provider's accounting, not from the agent.
Does a log written outside the agent prove the agent did a good job?
No. It proves what crossed the point where it was written, in what order, and that the entries were not edited afterwards. Actions that never pass that point are not in it, and a correct record of a bad decision is still a record of a bad decision.
Sources
- Investigating truthfulness in a pre-release o3 model · Transluce · 2025-04-16
- Stress Testing Deliberative Alignment for Anti-Scheming Training · arXiv (Apollo Research, in partnership with OpenAI) · 2025-09-19
Run it yourself: 3 commands, no API keys.
github.com/mandarelabs/mandare →