Skip to content

A subtask opens in a view of its own, read as a conversation - #3036

Draft
ataibarkai wants to merge 24 commits into
mainfrom
claude/subtask-own-view-58826d
Draft

ataibarkai wants to merge 24 commits into
mainfrom
claude/subtask-own-view-58826d

Conversation

@ataibarkai

@ataibarkai ataibarkai commented Dec 5, 2026 •

Copy link
Copy Markdown
Contributor

Before and after

Before: a subtask's row opened in place, to its task, its answer and a list of steps. What the subagent said between steps was not shown.

before-inline-light.mp4

After: clicking the row opens the subtask on a page of its own. It reads like a conversation: what the Bot asked it, then its thinking and steps on the same grouped line the conversation uses, live while it works, then its answer. Back (or Escape) returns to the conversation exactly as it was left: same scroll, turn still running.

after-follow-light.mp4

Dark:

after-follow-dark.mp4

Opened from "See all" while the Bot works:

after-see-all-light.mp4
Before: opened in place After: its own page
Working Answered, dark Phone Phone, dark
The rows link to it "See all" links to it too

The films are replays of a recorded five-subtask run, with each subagent's thread served step by step as the store serves it while the subagent works. I also opened real subtasks from a real run on OpenBot Cloud through this branch's dev server (light, dark, phone width). Those pictures aren't here because they show internal Slack and repository details.

Builds on #2973, which is now merged into main and merged in here.

Options tried, and why the page won

I built two candidates on the same view and filmed both on the replay:

  1. The conversation's side pane, where an artifact, the Computer and the Bot's settings already open (DetailPanel, ?subtask=, 560 px).

    • At 1280 px it doesn't fit beside the conversation: the pane needs 560 px plus 400 px for the conversation. So it becomes a sheet that blurs and covers the conversation, and the reason to have a pane (both in view) is gone on an ordinary laptop.
    • At 1680 px it sits beside the conversation, but the subtask reads in a 560 px column on the gray frame surface: at a different width, and on a different surface, from the conversation it mirrors.
    Side pane at 1280 px: a sheet over the conversation Side pane at 1680 px
    candidate-side-pane-1680.mp4
  2. A route of its own, in place of the conversation (/channel/$channelId/subtask/$toolCallId). Chosen.

    • It reads like a conversation: the same column, surface and type, at every width, phone included.
    • The address can be linked, opened in a new tab and reloaded.
    • Back, the browser's Back and Escape all return to the conversation.

The leading tools do the same. Each opens a subagent as its own conversation, with a way back:

How it works

  • The view is the conversation's own transcript, given the subagent's thread (SubtaskView).
    • A subagent is the same Bot run again on one part of the work, so its work is drawn by the same code as the conversation's, and changes with it.
    • The thread's first message is the server's framing of the task for the model ("You are a subagent: …"). It is replaced by the task the Bot wrote, drawn as "Sent from ", as a task's brief is (SentFromBot).
    • The thread is read through the same query and the same five-second poll the row uses, so the two never disagree and the store is asked once for both.
  • Running state and the result come from the conversation's call. The thread says what the subagent did, never whether it is still doing it.
    • The conversation's transcript publishes its run_subagent calls to a small store (lib/subagents/thread-subtasks.ts), as it already publishes a task's work to its Details pane (thread-work.ts).
    • It publishes only once it draws the live conversation, not a copy of it.
  • The conversation stays drawn under the page, inert.
    • The page is a child route of the conversation's, so Back finds the conversation where it was and gives focus back to the row.
    • Back uses history.back() when the page was opened from the conversation, and otherwise goes to the conversation. This is how an artifact's full page works.
    • The page's header is the artifact page's: sidebar toggle, then Back with a tooltip, then "General Assistant › Subtask". Back takes the focus.
  • The row is a link wherever a subtask's view can open, and so is each row in "See all", which closes as the subtask opens. Where no view can open (a preview, the view itself), the row still opens in place, as before.
  • Opened at its own address, the page shows the conversation's loading placeholder until the conversation has drawn the call. It says "This subtask isn't in this conversation." only after five seconds without it.

Found against OpenBot Cloud, and fixed. The app keys a page by its leaf route (PageArrival). The subtask route had a key of its own, so opening it took the whole conversation down and put it up again. The conversation read its history again and lost its scroll. While that read was out, the subtask it hands over was gone, and the page went blank. The route now shares the conversation's arrival key. subtask-page-browser.test.tsx fails without that line.

No API or database change.

Tests

  • New, subtask-view.test.tsx (functional, on the real transcript, with a call, a result and a subagent thread recorded off a real run):
    • The view reads a subtask as a conversation: the task sent from the Bot (and never the server's framing of it), the turn's running line while it works, its answer and folded line once done.
    • A subtask that stopped before an approval says so in the view and asks nothing.
    • A thread that can't be read still shows the task and the answer, from the call.
    • A row is a link to the subtask's address, a new-tab click is left to the browser, and each row in "See all" opens the subtask and closes the dialog.
  • New, subtask-page-browser.test.tsx (real browser, the app's real conversation and subtask routes inside the app's page wrapper, Chromium and WebKit, light and dark, 1280 px and 390 px):
    • Opens the subtask from its row; the page shows the task, the steps' line and the answer; Back has the focus; the conversation underneath is the same element, inert.
    • Escape goes back to it, scrolled where it was, with the row focused again.
    • A fresh load of the subtask's address shows it, and its Back leads to the conversation.
  • Existing tests: I ran every test file that imports what this changes: 144 unit files (1,206 pass, 75 skipped in this mode) and the real-browser files whose fixtures draw a conversation, in Chromium and WebKit.
    • The look guard caught a rounded-sm on the row's focus ring. It is now rounded-md, the look's corner for controls.
    • Real browser: the 77 files whose fixtures draw a conversation, in Chromium and WebKit: 1,176 pass, 60 skipped. The only failures were the new subtask-page test in WebKit. Safari doesn't focus a link it clicks, so Back had no row to give the focus back to. Back now finds the row by the subtask's address, which also covers a row opened from "See all". The test now passes in both engines (8 of 8).

Not in this PR

  • A row given to another Bot ("OpenBot Roadmap Helper · Claude Opus 5.5 · 31 steps") truncates its task to nothing at desktop widths. That comes from A Bot's steps on an app read one way, running or done #2973's row layout, not from this change.
  • OpenBot Mobile is unchanged.
  • A group conversation's subtasks, if any, keep opening in place: the route is under /channel only.

🤖 Generated with Claude Code

ataibarkai and others added 24 commits December 4, 2026 15:41
A Google Calendar turn showed three steps three ways: finished steps read
"List events  Googlecalendar" (the app's key), while the step still running
sat in a box of its own, app first: "Google Calendar · List events" with a
spinner. The box (LiveConnectorStep) said nothing the row does not, so it
goes: every step is one row, the action then the app, and a running row
differs only by its shimmer and "In progress".

Every step now names its app as it was added here (useAppName, from the
apps the transcript already reads for logos), not from its key. A running
line also tells a screen reader "In progress", as the box did.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Three Google Calendar steps in a row drew three Google Calendar logos down
one list. The first step of a run of steps with the same icon (the same
app, or the same kind of step) draws it; the steps under it keep its room,
empty, so their words stay lined up. Also in a subtask's list of steps.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
A running ToolLine now also says "In progress" to a screen reader, so the
line's text reads "Asked you…In progress" in the real-browser test.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…nder it

A run of steps on one app read "List events  Google Calendar" on every row, the app's logo and
name repeated down the list while the action was what set the rows apart. Now the app is the
lead: its logo and name once, and each step under it says only what was done ("List events",
"Read the next part of an answer  List events, part 2 of 3").

- A folded line that already names the app ("Used Google Calendar") opens to its steps with no
  second lead.
- In a "Worked through" fold, a run the Bot's words had split goes on under the app named just
  above it, so two "List events" sit under one "Google Calendar".
- An app's call on a line of its own has the app over it, the same way.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…not its name

Replaces the nested "app leads its run" rows with what Atai settled on:

- While a step runs, a run of one app's steps is one line, "Using Google Calendar…", shimmering
  and folded, as it already was once done ("Used Google Calendar"). Opened, it lists one row per
  step. The open live list (`showLiveSteps`) and the `conversation` prop it needed are gone.
- A row says what was done, not the app's name after it. Under a line that already shows its one
  app (`LineShowsApp`), rows draw no logo. Where the steps are on several apps, each row draws its
  app's logo (`AppMark`), which shows the app's name on hover and is what a screen reader hears.
- In a "Worked through" line, a lone app call is drawn as a step row like the others, and app rows
  the Bot's words had split sit 8px apart as one list's steps do.
- Rows line up: a step that doesn't open keeps the chevron's room where others open, a step row is
  spaced as a line of its own is, and an opened list of steps is drawn at one size everywhere.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
… on hover

"Worked through 2 steps" beside Google Calendar's logo now reads "Worked through 2 steps  Google
Calendar", the name in gray as a step's detail is. A line whose logos are several apps' names none.

The logos on folded lines (a turn's "Worked through", a run's "Used 2 apps") now name their app on
hover and to a screen reader, as a step's logo already did (`AppMark`).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…p draw no logo

"Worked through 2 steps  Google Calendar" now reads "Google Calendar  Worked through 2 steps": the
app beside its logo, then what was done (`ToolLine`'s new `lead`).

The line names its app and its rows leave out that app's logo by one rule (`onlyApp`): the one app
among the steps that are on an app. A turn that looked for a tool, then listed events, named Google
Calendar on its line and still drew the Google Calendar logo beside "List events", since the rows
asked whether every step was on the app.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…the rows that open draw none

Under "Google Calendar  Worked through 2 steps", "List events" is its chevron and its words, no
logo. "Looked for a tool", which opens to nothing, kept the chevron's room and drew its wrench
after it, so its words started 21px further in. Where the rows in a list that open draw no mark,
a row that doesn't open now draws its mark where their chevron is, as wide, and its words start
where theirs do (`markInChevron`). Where they draw marks, it keeps the chevron's room as before.

step-rows-layout measures it in Chromium and WebKit: the wrench's centre on the chevron's, and
both labels at one x.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…orked" follows an app's name in lower case

Opened, "Worked through 4 steps" listed "Looked for a tool" as a muted line of its own, its wrench
in a gray circle and a gap under it, above rows of app steps drawn bare. A lone call the server ran
is now a step row in the same list (ToolActivity), with its own mark, the chevron's room kept, and
the same spacing; a tool search opens to the tools it found, as its line of its own does. Calls the
app draws itself (a command and its terminal) keep their own cards. Every row draws its own mark,
the app's logo included where the line names the app, and a single mark is drawn bare everywhere.

Where the line names its one app, what was done carries on from the name in lower case:
"Google Calendar  worked through 2 steps".

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…r case

A line on one app names it first, and "worked" carries on from the name in lower case:
"Google Calendar  worked through 1 step". The test's locator read only "Worked through", so it
waited for a line that now reads otherwise.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…ude/consistent-tool-rows-25bc36

# Conflicts:
#	app/src/components/channels/chat-transcript.tsx
…ond call renames nothing

"Fetch emails", alone, was a line of its own; when the Bot fetched again, the two became a run, and
a run is its app's line, so the same row read "Fetch emails", then "Using Gmail…", and its logo moved
right when the chevron came. Now one call on an app is drawn as a run of one: "Using Gmail…" while
it runs, "Used Gmail" once answered, opening to "Fetch emails", with the chevron from the start. A
second call joins it and only the list under it grows. A call that asks the person stays its card.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…repeats its step under it

"Thinking" was a line of its own under "Used Gmail" or "Looked for a tool" while the Bot worked out
its next move: a second thing under the turn that came and went between steps. The last line, its
steps all answered, now says "Thinking" (or "Reconnecting…") itself, shimmering, its icons kept,
and goes back to "Using Gmail…" when the next step starts or "Used Gmail" when the Bot speaks
(`thinkingInLine`). A step on no app does the same on its own line (`LineWaiting`). A screen reader
hears it as before (`role="status"`). A card the app draws, and a task's "Worked for" line, keep
"Thinking" under them.

A folded line naming the step under way ("Reading the next part of an answer…") also drew that step
beneath it; a step the line already names is left out of what is drawn under it.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
… line, its subtasks as rows

What the Bot says on the way and the steps it takes are one group from its first step: the turn's
line reads its latest thought, shimmering, over up to three lines beside the logos of the apps it
used (or what its steps are doing, or "Thinking"), and a screen reader hears it as it changes. Once
it has answered, the line says what it did, the answer stands under it, and its thoughts are inside
with its steps, in order, quieter than the answer. Nothing is drawn under the folded line.

Subtasks run as rows of their own beside the line, one list for the whole turn, each with its own
chevron, opened to its steps, and saying the step it is on and how many it has taken. Past three,
"See all (N)" opens a view of every one. They fold into the line with the rest once it has answered.

A line no longer draws its step twice (under the line as well as on it), a running line keeps one
tree as what is under way comes and goes (so an app's logo names it on hover while it runs), and a
label of several lines keeps its chevron and icons on its first line.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
… as inside it

While a conversation's turn runs, the Bot's latest words are its line's text and a row among its
steps inside the closed line, so a strict lookup found two. The three tests that wait for those
words while the turn runs take the first, the line's.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…ubtask beside a search is tested as drawn

"See all (N)" was a button of its own making, centred under the rows; it is the design system's
ghost Button, under the rows where their words start, in light and dark.

Tests are functional and regression only (Dave's rule): the grouping assertions this branch had
added to a unit test of `groupToolSteps` are gone, and a functional test draws a turn that looks for
a tool and starts a subtask, and finds the subtask a row of its own and the search in the turn's line.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…e Bot asked it, its steps as it works, its answer

Clicking a subtask's row, or one in "See all", opens /channel/$id/subtask/$toolCallId in place of
the conversation. The view is the conversation's own transcript given the subagent's thread, so
its thinking and steps sit on the same grouped line and rows, live while it runs. The task is drawn
as sent from the Bot. The conversation stays drawn underneath, so Back finds it as it was.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…t its own address waits for it

The subtask route shares the conversation's arrival key, so opening it no longer remounted the
conversation: its scroll, its run and its message box stay, and Back finds them as they were (found
against OpenBot Cloud, where the remount emptied the page). Opened at its own address, the page
shows the loading placeholder until the live conversation has drawn the call, and says the subtask
is missing only after a few seconds without it. A conversation that can't be opened gives way to
its own notice, and Escape on the page goes back rather than dismissing a notice under it.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…ew-58826d

# Conflicts:
#	app/src/components/channels/subtask-step.tsx
#	app/src/components/channels/tool-activity.tsx
…ts row keeps the look's corner

subtask-view.test.tsx: the view reads a subtask as a conversation (sent from the Bot, the turn's
running line, its answer), says what it handed back, still shows its answer when its thread can't
be read, and a row and each row in See all are links that open it. subtask-page-browser.test.tsx
opens it from its row in Chromium and WebKit, light and dark, wide and on a phone, and goes back to
the very same conversation, scrolled where it was; it fails without the conversation's arrival key.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…it from See all

Found by the browser test in WebKit: Safari doesn't focus a link it clicks, so the row that opened
the subtask was never remembered. The row is now found by the subtask's address when the person
comes back, which also covers a row in See all, gone with its dialog, and focused without scrolling.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant