Compensating action

ProductionReliabilityPublished By Simon Budziak

A compensating action is a new operation that reduces or reverses the business effect of an earlier action when a literal technical rollback is impossible. An agent might issue a refund, cancel a booking, restore a prior document version, or create a correction while preserving the original audit record.

NIST AI Agent Standards Initiative provides the primary reference used for this definition and its production boundaries.

How does compensating action work in production?

The workflow records each completed step and its compensation. If a later step fails, agent recovery runs the relevant action in reverse order. An idempotent tool call prevents the compensation itself from duplicating. Compensation creates a new fact; it does not erase history.

When does compensating action matter?

Use compensation for external systems where agent rollback cannot restore the exact prior state. Keep both actions in the agent audit trail. Design compensation alongside the original operation.

Frequently asked questions

What is compensating action used for?

Use compensation for external systems where agent rollback cannot restore the exact prior state. Keep both actions in the agent audit trail.

Is a compensating action the same as rollback?

No. Rollback restores an earlier technical state; compensation creates a new action that offsets the business effect.

Summarize this page with

Train your team to build this