Repository navigation
refactor(fork): remove legacy chat-replies and subThreads - #445
Merged
Merged
Conversation
…to_user
Remove the legacy chat-replies fork implementation (subThreads, displayModeWrap, SendToUser/replace_send_to_user/replyStage, shownHistory/shownOnlyThread, userView/t3_thread_user_view, web displayMode, and shared displayModes/textMatch) so the codebase returns to clean Classic T3 before native single-ledger Chat mode is added.
- Delete 69 legacy fork files (including disconnected web displayMode helpers ChatWorkingIndicator, AgentMessageDivider, and EditedMark so knip:check stays clean) and keep claudeTerminalTool wired for Classic send_to_user.
- Restore upstream MessageToolkit (send_to_user({ message })) and McpToolExposure PROXY_DIRECT_TOOLS, and lower agentContextBudget.json mcpToolListJsonBytes from 67817 to 63805.
- Remove threadDisplayModes/newThreadDisplayMode settings schemas, shownOnly snapshot/history plumbing (restoring IndexedDB snapshot caching), sub-thread RPCs and right-panel replies surface, and t3 thread user-view CLI/docs/feedback entries.
- Drop the ephemeral fork_display_mode_told table on SQLite startup if present without touching user data, and verify legacy settings.json decoding.
Thread transfer impact✅ Thread transfer remains within every enforced ceiling.
Other scenariosAll 64 scenario measurements match All 64 scenario measurements
Baseline: Scenario and decoded snapshot size10 historical turns, 5 command tools per turn, 878.9 KiB retained MCP result per historical turn, and a 1.05 MiB retained result in the measured turn.
Updated in place by a trusted workflow. PR artifacts are strictly validated and never executed. |
This was referenced Dec 3, 2026
Closed
This was referenced Dec 3, 2026
Closed
Closed
Closed
Closed
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.
Why
Remove the legacy
chat-repliesandsubThreadssubsystem before building the native single-ledger Chat mode, so every surviving thread runs cleanly on upstream Classic T3 without parallel display-mode plumbing. Closes #443, Closes #444.What changed
subThreads,displayModeWrap,SendToUser*/replyStage*,shownHistory/shownOnlyThread,userView,web/src/fork/displayMode, andshared/src/fork/{displayModes,textMatch}(net -19,573 lines across 176 files).send_to_user({ message })handlers,McpHttpServerregistration,PROXY_DIRECT_TOOLS, IndexedDB thread snapshot caching,ChatViewchat.findguard, andciteAssistantTexti18n entries; loweredmcpToolListJsonBytesinagentContextBudget.jsonfrom67817to63805.claudeTerminalTool.ts(trimmed to Classicsend_to_user) and addeddropRetiredForkTablesinSqlite.tsto drop only the ephemeralfork_display_mode_toldtable on startup if present.Scope
Legacy
chat-repliesandsubThreadsremoval only. Does not add the new native Chat mode or delete any persisted user threads or messages.Tradeoffs
Deleted unused
apps/web/src/fork/displayMode/*helpers now rather than carrying dead props until the native Chat UI PR, keepingknip:checkand reader load clean.Blast Radius
Existing settings entries for
threadDisplayModes/newThreadDisplayModeare silently ignored by lenient JSON decoding (fromLenientJson), so formerchat-repliesthreads open in Classic mode with all history intact. The"replies"right-panel kind is dropped from persisted panel state.Verification
vp check(0 errors),vp run i18n:check,effect-tsgo tsrs --noEmit(0 errors).reactCompilerCoverage).legacyChatRepliesCleanup.test.ts) and browser tests (22 files, 291 passed).