feat(web): hide subagent threads from user-facing thread lists (5/5) - #4664
Draft
shivamhwp wants to merge 3 commits into
Draft
feat(web): hide subagent threads from user-facing thread lists (5/5)#4664shivamhwp wants to merge 3 commits into
shivamhwp wants to merge 3 commits into
Conversation
|
Important Review skippedAuto reviews are disabled on this repository. Please check the settings in the CodeRabbit UI or the ⚙️ Run configurationConfiguration used: Repository UI Review profile: CHILL Plan: Pro Plus Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
shivamhwp
force-pushed
the
subagent-obs/04-agents-panel
branch
from
July 27, 2026 20:20
940e8fb to
c3a50f8
Compare
shivamhwp
force-pushed
the
subagent-obs/05-thread-visibility
branch
from
July 27, 2026 20:20
d2ef6c7 to
adb1e9b
Compare
shivamhwp
force-pushed
the
subagent-obs/04-agents-panel
branch
from
July 27, 2026 20:52
c3a50f8 to
8c6a796
Compare
shivamhwp
force-pushed
the
subagent-obs/05-thread-visibility
branch
from
July 27, 2026 20:52
adb1e9b to
39912b0
Compare
shivamhwp
force-pushed
the
subagent-obs/04-agents-panel
branch
from
July 27, 2026 23:03
8c6a796 to
103b937
Compare
shivamhwp
force-pushed
the
subagent-obs/05-thread-visibility
branch
from
July 27, 2026 23:03
39912b0 to
6bc3a8d
Compare
shivamhwp
force-pushed
the
subagent-obs/04-agents-panel
branch
from
July 28, 2026 15:31
103b937 to
31adb36
Compare
shivamhwp
force-pushed
the
subagent-obs/05-thread-visibility
branch
from
July 28, 2026 15:31
6bc3a8d to
05fe44c
Compare
shivamhwp
force-pushed
the
subagent-obs/04-agents-panel
branch
from
July 28, 2026 19:27
31adb36 to
b270c47
Compare
shivamhwp
force-pushed
the
subagent-obs/05-thread-visibility
branch
from
July 28, 2026 19:27
05fe44c to
7458298
Compare
shivamhwp
force-pushed
the
subagent-obs/04-agents-panel
branch
from
July 28, 2026 19:46
b270c47 to
daf1a88
Compare
shivamhwp
force-pushed
the
subagent-obs/05-thread-visibility
branch
from
July 28, 2026 19:46
7458298 to
4daeac4
Compare
shivamhwp
force-pushed
the
subagent-obs/04-agents-panel
branch
from
July 28, 2026 20:26
daf1a88 to
1dce464
Compare
shivamhwp
force-pushed
the
subagent-obs/05-thread-visibility
branch
from
July 28, 2026 20:26
4daeac4 to
095cab7
Compare
shivamhwp
force-pushed
the
subagent-obs/04-agents-panel
branch
from
July 29, 2026 01:19
1dce464 to
4c169ed
Compare
shivamhwp
force-pushed
the
subagent-obs/05-thread-visibility
branch
from
July 29, 2026 01:19
095cab7 to
1d37a6f
Compare
shivamhwp
force-pushed
the
subagent-obs/04-agents-panel
branch
from
July 29, 2026 01:24
4c169ed to
70d5111
Compare
A subagent's child thread is an implementation detail of the agent that owns it, not a conversation the user started. Listing them alongside real threads makes the sidebar grow with every delegation. Filtered at the source — the shell snapshot the server serves — so every client sees the same set rather than each re-deriving it. The web client filters again for locally-held state, and the thread route redirects to the parent if a subagent thread is reached directly. Mobile is part of the sweep, not left behind. It still offered "Open subagent thread" and had no redirect to fall back on, so it would have navigated to a thread the client no longer receives. Its relationships banner also needed the same subagent-edge filter web has: those edges are derived from the projection rather than from thread shells, so they survive the shell filtering and would have rendered as "Unavailable" — and, sorting first, could have taken over the banner headline. Trade-off worth stating plainly: a subagent's transcript becomes unreachable. The Agents panel added in the previous PR shows what an agent did and what it returned, but not its full conversation. That is the intended shape here, and the "Open subagent thread" affordances are removed on both clients rather than left as dead ends.
Removing the "Open subagent thread" affordance left the mobile work log subscribing to item support it no longer reads, and the web sidebar importing a predicate it no longer calls. Both tripped the lint rule the CI Check job enforces. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude <noreply@anthropic.com>
shivamhwp
force-pushed
the
subagent-obs/05-thread-visibility
branch
from
July 29, 2026 01:25
1d37a6f to
6cf67a2
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Last of five stacked PRs replacing #4551. Stacked on #4663 — review that first.
A subagent's child thread is an implementation detail of the agent that owns it, not a conversation the user started. Listing them alongside real threads makes the sidebar grow with every delegation.
Filtered at the source — the shell snapshot the server serves — so every client sees the same set rather than each re-deriving it. The web client filters again for locally-held state, and the thread route redirects to the parent if a subagent thread is reached directly.
Mobile is part of the sweep
Found in review, and the reason this isn't a web-only change. Mobile still offered "Open subagent thread" with no redirect to fall back on, so it would have navigated to a thread the client no longer receives. Its relationships banner also needed the same subagent-edge filter web has — those edges derive from the projection rather than from thread shells, so they survive the shell filtering and would have rendered as "Unavailable", and by sorting first could have taken over the banner headline.
The trade-off, stated plainly
A subagent's transcript becomes unreachable. The Agents panel from #4663 shows what an agent did and what it returned, but not its full conversation. That is the intended shape here, and the "Open subagent thread" affordances are removed on both clients rather than left as dead ends — but it is a real capability loss and worth a deliberate decision rather than being smuggled in with a sidebar tidy-up.
Testing
Typecheck clean on server, web, client-runtime. Server 1,685 passing, web 1,500 passing, client-runtime 485 passing. (
apps/mobilehas 70 pre-existing typecheck errors on the base branch, unchanged by this PR.)Known, not fixed here
/rather than the parent. It matters under version skew, so it is kept.entities.tsswaps memoized ref atoms for per-call filter+map. The cost is negligible but the identity stability is not; filtering inside the client-runtime atoms instead would be the better shape.thread.removeddelta, absorbed harmlessly by the reducer.Note
Hide internal subagent threads from all user-facing thread lists and navigation
isInternalSubagentThreadandisUserFacingThreadhelpers that classify both lineage-subagent and node-owned subagent threads as internal.userFacingShellSnapshotutility in ThreadManagementService.ts./) in _chat.$environmentId.$threadId.tsx.findThreadRefnow returns nothing for internal subagent thread IDs, which could silently break any code that attempts to look up a subagent thread by ID.📊 Macroscope summarized 6bc3a8d. 12 files reviewed, 0 issues evaluated, 0 issues filtered, 0 comments posted
(Automatic summaries will resume when PR exits draft mode or review begins).🗂️ Filtered Issues
No issues evaluated.