feat(web): regenerate thread titles from sidebar - #4810
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:
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 |
63add75 to
3a36a86
Compare
ApprovabilityVerdict: Needs human review This PR introduces a new user-facing feature (thread title regeneration) with database schema changes, new orchestration logic, and UI components. New features introducing new workflows warrant human review regardless of implementation quality. You can customize Macroscope's approvability policy. Learn more. |
3a36a86 to
f5de384
Compare
f5de384 to
a3ba2e0
Compare
a3ba2e0 to
8316ef2
Compare
8316ef2 to
ea1c1d9
Compare
ea1c1d9 to
55673e2
Compare
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes using high effort and found 1 potential issue.
❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.
Reviewed by Cursor Bugbot for commit 6a59660. Configure here.

Thread titles can stop reflecting the conversation as work evolves, while Sidebar v2 only supports replacing them manually.
This adds a Regenerate title action that sends recent thread context and the previous title through the configured text-generation model. The server keeps the work off the provider command queue, preserves manual renames made while generation is running, and capability-gates the action for version-skewed environments.
Testing
Generated by gpt-5.6-sol with the Codex harness in T3 Code.
Note
Medium Risk
Touches orchestration commands/events, projection persistence, and async reactor behavior with race handling; changes are well-tested but span server and web with a new migration.
Overview
Adds Regenerate title for threads whose titles no longer match the conversation, exposed from Sidebar v2 (single and bulk selection) and gated by a new
threadTitleRegenerationserver capability.Clients send
thread.meta.updatewithregenerateTitle: true. The decider records pendingtitleRegenerationstate and emits completion viathread.title.regeneration.complete. ProviderCommandReactor handles regeneration on a dedicated async worker (not the provider turn queue): it builds bounded thread context (8k chars, up to four attachments), calls text generation withpreviousTitle, skips fallback/unchanged titles, and avoids overwriting manual renames made while a run is in flight or queued.SQLite migration 035 adds projection columns; snapshots and the client reducer surface
titleRegenerationso rows can dim, setaria-busy, and time out after 30s if the server never clears pending state.Reviewed by Cursor Bugbot for commit 88b3bd1. Bugbot is set up for automated code reviews on this repo. Configure here.
Note
Add thread title regeneration from the sidebar context menu
updateThreadMetadatawithregenerateTitle: trueand showing a disabled 'Regenerating…' label while pending.thread.meta-updatedevent withregenerateTitle=truetriggers async LLM title generation, then emits athread.title.regeneration.completecommand to update the thread.previousTitlesupport tobuildThreadTitlePromptacross all text generation providers so regeneration prompts reflect prior title context and use tail-preserving truncation on long thread histories.titleRegenerationRequestId,titleRegenerationStartedAt) via a new DB migration (035_ProjectionThreadTitleRegeneration.ts) and propagates it through the read model to the client.threadTitleRegenerationcapability flag in the server environment descriptor so clients can gate the UI feature on server support.Macroscope summarized 88b3bd1.