Depute Logo

Rollback Timeline

Undo-tree for agentic tool sequences.

Install

npx ax-depute@latest add rollback-timeline
pnpm dlx ax-depute@latest add rollback-timeline
yarn dlx ax-depute@latest add rollback-timeline
bunx ax-depute@latest add rollback-timeline

Overview

Rollback Timeline is an undo-tree designed specifically for agentic action sequences. When agents execute long chains of tool calls, humans need a safe way to regress state if an error or hallucination is caught late. This component visualizes execution history and makes irreversibility explicit.

Deployment Steps

3 actions
Provisioned database12:00:00
Step 1: Provisioned database. Status: Available. Reversible.
Ran schema migrations12:01:15
Step 2: Ran schema migrations. Status: Available. Reversible.
Inserted seed data12:02:30
Step 3: Inserted seed data. Status: Current. Reversible.
Interactive StorybookView all states, toggle props, and test edge cases.

Basic Usage

<RollbackTimeline
  title="Action Timeline"
  points={[
    { id: 'p1', label: 'Updated email', status: 'rolled-back', timestamp: '2026-03-19T10:00:00Z', reversible: true },
    { id: 'p2', label: 'Dropped legacy table', status: 'current', timestamp: '2026-03-19T10:05:00Z', reversible: false },
  ]}
  onRollback={(id) => handleRevert(id)}
/>

Solution Patterns

Typically paired with ToolTrace for deep orchestration. When an agent executes a sequence of 10 tools and fails on the 11th, the timeline provides a structured path to rewind system state safely without guessing.

Props

PropTypeDefaultDescription
titlestringTitle of the timeline
pointsRollbackPoint[]Ordered list of rollback points
onRollback(pointId: string) => voidRollback callback handler
requireConfirmationbooleantrueAsk for confirmation before reverting

Design rationale

Prerequisites: This component assumes your product has reversible operations. If your agent's tool calls are all-or-nothing (e.g., sending emails, executing payments), RollbackTimeline will show the history but rollback actions won't be available past irreversible nodes. Evaluate your system's undo capabilities before adopting this component — it is most effective in environments where tool calls can be programmatically reversed (e.g., database migrations, file system changes, API calls with corresponding undo endpoints).

Why explicit irreversibility? Agent sequences frequently cross immutable boundaries (e.g., dropping a database table). Marking specific nodes reversible: false prevents the user from attempting a regression past a terminal action, saving engineering headaches.

On this page