Agent timeline
The trace of an AI agent's run, in order: the messages, the reasoning, each tool call, handoffs between agents, errors. Built on the timeline, with markers by kind, a dashed rail toward what has not happened yet, a pulse on the running step, and earlier steps folded away.

Works with no script. With Alpine and the package's script the fold and collapsed rows keep the reader's open or closed over a re-render. See getting started.
Use it
<x-ds::agent-timeline label="Refund question" :fold="5">
@foreach ($run->steps as $step)
<x-ds::agent-timeline-item wire:key="step-{{ $step->id }}"
:type="$step->type" :status="$step->status" :title="$step->title"
:time="$step->created_at" :duration="$step->seconds" :collapsed="$step->type === 'reasoning'">
@if ($step->type === 'tool')
<x-ds::tool-call :name="$step->tool" :status="$step->status" :arguments="$step->input" :result="$step->output" />
@else
{{ $step->text }}
@endif
</x-ds::agent-timeline-item>
@endforeach
</x-ds::agent-timeline>
In a box that keeps the newest step in view:
<x-ds::agent-timeline label="Run 42" :follow="true" maxHeight="480">…</x-ds::agent-timeline>
Props
agent-timeline
| Prop | Type | Default | What it does |
|---|---|---|---|
label | string | required | Names the list, and the box with follow. |
density | comfortable compact | comfortable | Compact is the timeline's dense. |
fold | int | — | Keep only the last this many steps in view; the earlier ones fold behind "Show N earlier steps". |
follow | bool | false | Scroll in a box that opens on the newest step and keeps a new one in view, unless the reader has scrolled up. |
maxHeight | int, string | 24rem | With follow: pixels, or a CSS length. |
foldLabel | string | Show :count earlier step|Show :count earlier steps | The fold's words. |
unfoldLabel | string | Hide earlier steps | Its words when open. |
agent-timeline-item
| Prop | Type | Default | What it does |
|---|---|---|---|
type | message reasoning tool handoff error note | note | The kind of step: its marker once finished. |
status | string | done | From the status set. |
title | string | the type in words | What happened, in one line. |
time | DateTime, string | — | When, as the timeline item takes it. |
datetime | DateTime, string | — | The moment, for a time in words. |
timeFormat | string | — | relative, or a PHP date format. |
duration | number | — | Seconds it took, after the title: "· 1.2s". |
actor | string or array | — | Who did it, for a run with several agents: a name, or avatar props. |
collapsed | bool | false | Only the title line; the body opens under it. |
statusText | array | — | [status => words]. |
| Slot | What it does |
|---|---|
| default | The step's body: text, a tool call, a reasoning block. |
A finished step's marker is its kind's icon, grey. Anything else shows its
status: a pulse while running, amber while waiting, red when failed. An
error is red whatever its status.
The fold, and Livewire
Folded steps stay in the page, where your loop rendered them, and are hidden
by CSS: moving them into a container of their own would break Livewire's
morph of the loop. So a re-render that adds a step just works, and the count
moves with it. Give every row a wire:key.
Accessibility
- An ordered list named by
label; each step's status is written before its title for screen readers; times aretimeelements. - The fold and each collapsed step are native disclosures.
- With
follow, the box is a named region and a Tab stop, so it scrolls from the keyboard. - New rows and the pulse are motion-safe.
Don't
- Don't key rows by their position (
$loop->index). Key by the step's id. - Don't put a link in a collapsed step's title. The title is the control that opens it.
- Don't show a long run unfolded. Fold all but the last few.
From the package repo: edit this page on GitHub.