Agent Activity

One adaptive activity stream for reasoning, searches, tool calls, structured execution traces, or a chronological mix.

Streaming Text

index.tsx

Streams freeform reasoning text into the capped viewport and keeps the completed log available behind a timed disclosure.

Thinking…

Reasoning Steps

index.tsx

Shows completed, active, and pending reasoning steps with optional trailing metadata.

Thinking…
Reading the product brief

Tool Calls

index.tsx

Summarizes read, edit, and run events with monospace targets and optional line-change counts.

Running tools…

Mixed Activity

index.tsx

Streams reasoning, search, and tool events in one chronological run while the viewport smoothly follows new work.

Thinking…
Reading the launch brief

Agent Trace

index.tsx

Streams messages and structured actions into a compact execution ledger, then summarizes the completed run by tool-call and message counts.

Running the agent trace…

API Reference

items
AgentActivityItem[]

Chronological activity entries. Append or update items as events stream.

contentType?
"step" | "text" | "search" | "tool" | "trace" | "mixed"

Expected activity kind before the first streamed item arrives.

status?
"working" | "complete"

Current run phase. Active runs always stay expanded.

working
duration?
number

Elapsed run time, in seconds. Used by the step-only summary.

0
open?
boolean

Controlled expanded state used after the run completes.

defaultOpen?
boolean

Initial expanded state used after the run completes.

false
onOpenChange?
((open: boolean) => void)

Called when the completed activity disclosure changes state.

collapseOnComplete?
boolean

Collapse the disclosure when status changes from working to complete.

true
activeLabel?
ReactNode

Optional label shown while the run is active.

summary?
ReactNode

Optional completed summary. Derived from the item types by default.

maxHeight?
number

Maximum visible activity height before the stream begins gliding.

208
className?
string
contentClassName?
string

Install

Add it with the shadcn CLI, or copy the source manually.

$ bunx --bun shadcn add @beui/agent-activity

Composition

Render progressive work as message content so it remains attached to the turn that produced it.

Message
└── MessageContent
    └── AgentActivity

Note: Agent Loading States covers the interval before the first structured event. Todo List separates durable planned work from transient events. Tool Result expands one completed execution into inspectable output.

How it works

Agent activity explains how work is progressing without exposing an unfiltered internal transcript. Events should arrive chronologically, remain easy to scan, and reduce to a useful summary when the run finishes.

Updated