[FEATURE] Desktop sidebar: show sessions as a parent/child tree

Status Open
Maintainer reply None cached
Activity 0 comments · opened Sep 17, 2026

Preflight Checklist

  • [x] I have searched existing requests and this feature hasn't been requested yet
  • [x] This is a single feature request (not multiple features)

Problem Statement

In the desktop app's Code tab, sessions can start other sessions (spawn_task chips, plan continuations, sessions started from the session tools), and those can start more. The app already records the link: get_session returns parentSessionId and detached. The sidebar shows none of it. Every session is a flat row sorted by recency, date, project or state, so a planning session and the work it fanned out end up scattered across the list.

This bites with orchestration workflows. A planning session starts one child per step, and a child may start its own helper session. Measured on one real project: a family of 34 sessions across six levels: one planning session, 14 sessions at level 2, 13 at level 3, then 3, 2 and 1. Six are live and 28 are archived. Nothing in the UI shows that structure.

It is also easy to get wrong from the tools. My first pass had an agent call get_session once per session (list_sessions does not include parentSessionId) and walk up from the sessions list_sessions returned. That reported 9 sessions across four levels, because list_sessions omits archived sessions by default, so whole archived branches never appeared. The real count came from reading the app's session files directly.

Custom sidebar groups are the only workaround, and they are flat. They can hold a whole family, but they can't show who started whom, and archived sessions can't go in a group, so the chain between a root and a deeper descendant disappears.

Proposed Solution

Add a tree view of sessions to the sidebar, built from parentSessionId:

  1. A "Group by: parent" option in the sidebar filter menu, next to date / project / state / custom. Each root session is a collapsible node, with its descendants indented under it at any depth.
  2. Archived sessions in between stay visible in the tree as dimmed placeholders when they have live descendants, so a deep live session isn't shown as a direct child of a much shallower one.
  3. Per-row status (running, PR open/merged, archived) so you can see at a glance which branches of the tree are done.
  4. Respect detached: a session the user moved to top level shows as its own root.

Smaller pieces that would help even without the full view:

  • Include parentSessionId in list_sessions output, so tools can build the tree in one call instead of one call per session.
  • Show a "started from: <parent title>" link in the session header.

Alternative Solutions

  • Custom sidebar groups, one per root session (what I'm doing now, with a CLAUDE.md rule telling child sessions to file themselves into their root's group). This keeps a family together, but it's flat, depends on every child following the rule, and can't include archived sessions.
  • #82788 (auto-assign spawned sessions to their parent's sidebar group) would make that workaround automatic. It's related but doesn't show the hierarchy itself.
  • #86488 asked for chain linkage between continuation transcripts in --resume and was closed as not planned. This request is about the desktop sidebar and the parentSessionId link the app already stores.

Priority

Medium - Would be very helpful

Feature Category

Other

Use Case Example

  1. A planning session breaks an issue into steps and starts one session per step.
  2. One step session hits a question it can't settle and starts a helper session. That helper starts another session to make the fix.
  3. Steps finish and get archived as their PRs merge.
  4. Today the user sees 6 unrelated live rows mixed in with other work (34 if archived sessions are shown), and can't tell which open PR belongs to which plan, or whether a plan still has live work under it.
  5. With a parent tree, the planning session is one collapsible node. Expanding it shows its 14 steps, their helpers down to six levels, and which branches still have live work, with archived sessions dimmed or hidden.

Additional Context

Desktop app (Code tab) on macOS. The data model already supports this: get_session exposes parentSessionId and detached, and parent links survive archiving, so this is a presentation feature rather than a new data model.

View original on GitHub ↗