Skip to content

AI uses for records

Agent evaluation side effect testing: measuring changes to unrelated records

By SourceX Editorial · Updated

10 sections

Short answer

To measure unintended changes an agent makes while completing a task, audit a stratified sample of records the task should not touch. Run each task with the agent and as a no-op baseline, diff the sample in both, attribute each difference to the agent, its triggered automation or background jobs, grade severity with the workflow owner, and report the side effect rate with an interval beside completion.

Evaluation split

Agent evaluation side effect

This page covers agent evaluation side effect testing: measuring changes to unrelated records.Illustrative

Key takeaways

  • Side effects are measured as a rate across runs, reported beside task completion and never merged into it.
  • Sample unrelated records in strata: look-alikes, siblings, dependents, shared-automation targets and random controls.
  • A no-op run of the same task subtracts the changes business systems make on their own, such as scheduled jobs and sync.
  • Every difference is labelled direct, triggered, background or unattributed, and only background changes are excused.
  • The workflow owner confirms severity grades, and zero observed side effects still needs an interval before anyone calls an agent safe.

How do you measure unintended changes an agent makes while finishing a task?

Measure them as an audit, not as a pass or fail flag. Before the runs, pick a sample of records the task has no reason to touch, grouped by how likely the agent is to reach them. Run the task with the agent and once without it, diff the sampled records in both runs, attribute each difference to the agent, its triggered automation or background activity, grade the ones the agent caused, and report that rate with an interval next to task completion.

That last point matters most. A completion score answers whether the requested change happened. The audit answers a different question: across many runs, how often does the agent alter something it was not asked to alter, how bad were those alterations, and how sure are you of the rate. Buyers comparing agents, prompts or tool permissions need both numbers, because an agent that completes more tasks while quietly editing more neighboring records is not an improvement.

This page covers the measurement side: which unrelated records to audit, how to separate the agent's edits from the noise a business system produces on its own, how to grade severity with the business owner and how to report a rate a reviewer can trust. Designing the per-task allowed change list and invariants is a separate design job that this page does not cover.

Which unrelated records belong in the audit sample?

Sample in strata, from the records most exposed to a stray write down to a random control group. A random sample of the whole database mostly finds records the agent could never reach, so it says little; a sample made only of obvious neighbors cannot tell you whether the audit missed a class of damage. Five strata are a practical default.

Size each stratum before the first run and keep the same sampling rule for every agent version you compare. If a later version is audited on a different sample, a change in the measured rate may come from the sample rather than the agent.

Which unrelated records belong in the audit sample?
StratumWhat it containsWhy the agent can reach itExample in a CRM or help desk
Look-alikesRecords that match the target on name, email domain, phone or a fuzzy searchSearch and lookup tools return them alongside the intended recordTwo contacts at different accounts sharing a company email domain
SiblingsOther children of the same parent recordBulk updates and loops over a parent's related listsOther open cases on the same account as the case being closed
DependentsRecords that point to the target and inherit its valuesEdits to the target cascade through lookups, roll-ups or workflow rulesOpen opportunities whose owner follows the account owner
Shared-automation targetsRecords touched by the same triggers, macros or flows the agent invokesOne macro or flow can update several objects at onceTickets in the same view that a macro is applied to
Random controlsA fixed random draw from the rest of the environmentShould be unreachable; any change here suggests an unknown pathAny account, ticket or invoice outside the task's neighborhood

What is the background change rate, and why run the task without the agent?

The background rate is how much the sampled records change when the agent does nothing, and you need it because business systems are never still. Scheduled jobs recalculate scores, timestamps update, SLA timers tick, sync jobs rewrite fields from another system. Count those as agent side effects and the audit blames the agent for the system's own behavior.

AI safety research has a name for this choice. Krakovna and colleagues split side-effect measures into a baseline and a deviation measure, and note that a starting-state baseline counts all natural dynamics as side effects, while an inaction baseline compares against what would have happened without the agent. An evaluation audit can use the same idea directly: for each task, restore the environment, run a no-op run of the same length with the same scheduled jobs, and diff its end state against the agent run rather than against the starting snapshot.

The inaction baseline has a known blind spot, and it applies here too. If doing nothing would itself cause harm, such as an order auto-cancelling because nobody released the hold, the baseline treats that harm as normal. Keep a short list of tasks where inaction is not neutral and grade them against the reference outcome instead.

Public agent benchmarks use a reference end state for the same reason. In the original tau-bench code, the grader replays the task's annotated actions on a freshly loaded database, hashes the result and sets the reward to zero if the agent's database hash differs. That catches any difference but cannot say which records differ or why; the audit adds the record-level diff and the attribution that a hash comparison leaves out.

How do you tell the agent's own edit from automation it set off?

Read the system's change history for every differing record and label who or what made the change. Help desks and CRMs record this differently, so check what each system actually keeps before relying on it.

At a glance

How do you tell the agent's own edit from automation it set off

Zendesk documents ticket audits as a read-only history of every update to a ticket, with each audit carrying the author and one or more change events that include the previous value. That is enough to separate an update made by the agent's API user from one made by a trigger. Salesforce field history tracking is narrower: its help pages say you can track a combination of up to 20 standard and custom fields per object by default, and that formula, roll-up summary and auto-number fields cannot be tracked. Fields outside that set will not show up in the history, so a snapshot diff of your own is still needed.

Run the agent under its own integration user so that its writes can be separated from people and automation in every log. Then give every difference one of four labels:

  • Direct: the agent's user wrote the change through a tool call.
  • Triggered: a rule, flow, macro or webhook wrote it in response to the agent's change. It counts against the agent, because the agent chose the action that fired it.
  • Background: the same change appears in the no-op run. It does not count.
  • Unattributed: no log explains it. Count it against the agent until someone explains it, and investigate it before the next run.

The side effect audit of unrelated records

Use the sheet below once per evaluation round. Each row is a step, the record it produces and the rule that decides the outcome. Fill it in before the first run where the column says so; deciding the rules after seeing the diffs invites tuning the audit to the result.

The side effect audit of unrelated records
StepWhat you recordDecision ruleOutput
1. Freeze the sampleRecord IDs per stratum, sampling seed, environment snapshot IDSame sampling rule for every agent version comparedAudit sample manifest
2. Choose fieldsFields compared per object, including status, owner, amounts, dates, links and deletion flagsExclude a field only with a written reason, such as last-viewed timestampsField list with exclusions
3. Run no-op baselineEnd state after a run of the same length with scheduled jobs on and the agent offOne baseline per task, restored from the same snapshotBackground diff
4. Run the agentEnd state, tool-call log, integration user ID, run seedRestore the snapshot before every runAgent diff
5. SubtractDifferences present in the agent diff but not the background diffMatch on record, field and new valueCandidate side effects
6. AttributeDirect, triggered, background or unattributed, with the log entry behind the labelUnattributed counts against the agentAttributed change list
7. Exclude intended changesChanges the task required, checked against the task's expected outcomeAnything the task did not require stays inSide effect list
8. Grade severitySeverity level from the rubric and the reasonBusiness owner confirms every grade above the lowestGraded side effects
9. ReportRuns with any side effect, runs with a serious one, interval method, per-stratum countsReport next to completion, never merged into itAudit summary

How severe is a given side effect, and who signs off the grade?

Grade by what it would take the business to notice and undo the change, and let the person who owns the workflow confirm the grade. An evaluation engineer can see that a field changed; only the owner knows whether that field feeds an invoice, a commission run or a customer email.

Keep the rubric short enough that two graders reach the same level; four levels are a workable start. Write the examples in the rubric in the business's own terms before the first run, and record disagreements rather than averaging them away.

How severe is a given side effect, and who signs off the grade?
LevelDefinitionTypical exampleReporting rule
S0 cosmeticChanges no business outcome and no downstream recordA tag added to a sibling ticketCounted, shown separately
S1 recoverableWrong value that a person would correct in normal reviewA contact's phone overwritten with the target's numberCounted in the side effect rate
S2 consequentialChanges a downstream outcome or misroutes work before anyone noticesAn opportunity moved to another account, changing who is paid commissionReported as its own rate
S3 irreversible or externalCannot be fully undone inside the system or reached a third partyA record hard-deleted or an email sent to another customerAny single case is reported by name

Worked example: an order-hold agent audited across 60 runs (illustrative)

All figures here are invented for illustration. An evaluation team tests an agent that releases credit holds on orders in a sandbox built from de-identified ERP and CRM records. The suite has 20 tasks, each run three times, for 60 runs. The audit sample per task is 40 records: 10 look-alikes, 10 siblings, 8 dependents, 6 shared-automation targets and 6 random controls.

The no-op baseline shows that a nightly job rewrites a risk score on about a third of sibling orders, so those changes are subtracted. After subtraction, 9 of the 60 runs contain at least one side effect. Seven of the nine involve siblings: the agent released holds on every held order for the customer instead of the one named in the task. Those releases were direct writes and the owner graded them S2, because a released order ships. Two runs changed a look-alike customer's credit limit through a flow the agent triggered, graded S1.

No random control changed in any run. The report states 9 of 60 runs with a side effect and 7 of 60 with an S2 or worse, each with a 95% interval, alongside the completion rate. It also notes that all seven S2 runs came from 3 of the 20 tasks, so the next round adds tasks where one customer has several held orders. The fix the team tests next is a tool change, not a prompt change: the release tool takes an order ID and refuses customer-level releases.

How should results be reported so two agents can be compared fairly?

Report completion and side effects as separate numbers, give the side effect rate an interval, and say how consistent the agent was across repeated runs of the same task. A single blended score lets a big gain on one hide a loss on the other.

SWE-bench is a useful model for the separation. Its grading code computes fail-to-pass tests as resolution and pass-to-pass tests as maintenance, and labels an instance fully resolved only when both equal 1. The maintenance score is a fraction, so the harness can show partial breakage that the resolved label hides. The same structure works for business tasks: completion is resolution, the audited sample staying unchanged is maintenance.

For the interval, treat each run as a success or failure for one question, such as whether it produced any S2 or worse side effect, and use a binomial interval. The NIST engineering statistics handbook describes the Wilson method for a proportion and notes that its limits stay inside 0 to 1, which matters when the observed count is zero or close to it. Zero side effects in 30 runs is not evidence of a zero rate; the interval shows how high the true rate could still be.

Repeats matter because a side effect that appears in one run out of three is still a production risk. The tau-bench paper defines pass^k as the chance that all k trials of a task succeed, averaged across tasks. The audit can report the analogous clean-run figure: the share of tasks where every repeated run left the sample untouched.

What does this audit miss, and when does it need specialist review?

It misses effects outside the sampled records and outside the sandbox. A record-level diff will not see an email the agent sent, a webhook to a partner system, a read of data the agent should not have seen, or damage that surfaces after the audit window closes, such as a renewal that fails next quarter because a date moved. Log outbound calls separately and treat any external action in an evaluation run as S3 until reviewed.

It can also miss whole task families. If the suite contains only one-record tasks, it will never see the bulk-update failures that can cause the worst damage. Before trusting a low rate, check the suite against the workflow owner's list of the tasks people actually do, with special attention to merges, bulk edits, reassignments and deletions.

Stop and bring in a specialist when the unattributed share stays high after a second round, because that means the logs cannot support the audit; when an S3 event appears, because it needs incident handling, not a rate; and when sampled records contain personal or regulated data that the sandbox copy was not cleared to hold. The underlying safety problem, which Amodei and colleagues describe as pursuing a goal without disturbing the environment and without listing everything that must stay untouched, has no complete general solution, so the audit is a measurement of exposure, not proof that the agent is safe.

Where realistic record neighborhoods come from

An audit is only as revealing as the neighborhoods around each target record. Synthetic sandboxes tend to have one contact per account and no shared automation, which makes look-alike and sibling strata nearly empty. Records from operating companies supply the dense neighborhoods, change histories and automation footprints that produce real side effects.

SourceX does not keep a catalog: each dataset is gathered from U.S. businesses after a buyer asks for it, and the request form is where that buyer sets out scope, volume, language, format, timing and licensing terms. For a side-effect audit, that request usually names the objects, the related lists that must stay linked and the change history the audit will read. Nothing reaches the buyer's sandbox until the business that holds the records has approved that scope and signed the agreement.

Frequently asked questions

What is agent evaluation side effect testing?

It is the part of an agent evaluation that checks what changed beyond the requested result. The agent is run in a sandbox, records it had no reason to touch are compared before and after, and any change the task did not require is counted and graded. It is reported next to task completion, not folded into it.

How many unrelated records should the audit sample per task?

Enough that every stratum has records the agent could plausibly reach, and the same rule for every agent version you compare. Tens of records per task across look-alikes, siblings, dependents, shared-automation targets and random controls is a practical starting point. Increase the strata where side effects actually appear rather than the random controls.

Why not just compare the final database to a reference end state?

A whole-state comparison is a strong pass or fail check and public benchmarks such as tau-bench use one. It does not tell you which records changed, whether the agent or a background job changed them, or how serious the change was. The audit adds those three answers, which are what an owner needs to decide whether an agent can be trusted.

Should side effects caused by automation count against the agent?

Yes, when the agent's action fired the automation. The agent chose an action whose consequences included the extra change, and the business pays the same cost either way. Changes that also appear in the no-op baseline are background activity and should not count.

Can an agent with zero observed side effects be treated as safe?

No. Zero events in a few dozen runs still leaves room for a meaningful true rate, which a binomial interval makes visible. It also says nothing about task types the suite did not include or effects outside the sampled records, so report the interval and the coverage together.

Sources

  • Side-effect measures split into a baseline and a deviation measure; a starting-state baseline counts natural dynamics as side effects, and an inaction baseline misses effects that doing nothing would also cause. Source
  • The original tau-bench grader replays the annotated actions on freshly loaded data and sets the reward to zero when the agent's database hash differs from the reference hash. Source
  • The tau-bench paper defines pass^k as the chance that all k independent trials of a task succeed, averaged across tasks. Source
  • SWE-bench grading treats fail-to-pass tests as resolution and pass-to-pass tests as maintenance and marks an instance fully resolved only when both are 1. Source
  • Zendesk ticket audits are a read-only history of every ticket update, each with an author and change events that include the previous value. Source
  • Salesforce field history tracking covers up to 20 standard and custom fields per object by default and cannot track formula, roll-up summary or auto-number fields. Source
  • The NIST engineering statistics handbook gives the Wilson interval for a proportion, whose limits stay within 0 and 1. Source
  • Avoiding negative side effects is framed as reaching a goal without disturbing the environment and without listing everything the system must not disturb. Source

Tell us what data you need

Share scope, volume, format, timing and licensing needs. Datasets are sourced on request.

See if your company qualifies