[codex] add automatic thread labels - #5461
Conversation
Persist and generate durable thread labels, expose them across web and mobile clients, and add filtering, manual actions, migration coverage, and review screenshots. Co-authored-by: Cursor <cursoragent@cursor.com>
|
You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard. |
|
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 |
ApprovabilityVerdict: Needs human review This PR introduces a new thread labels feature with AI-generated classification, manual label management, and filtering across mobile and web apps. The scope includes database migration, modified text generation prompts, and cross-platform UI changes - substantial new functionality that warrants human review. You can customize Macroscope's approvability policy. Learn more. |
Preserve inferred labels when title regeneration leaves the title unchanged, protect first-turn labels with compare-and-set semantics, and hide unlabeled pending tasks while a mobile label filter is active. Co-authored-by: Cursor <cursoragent@cursor.com>
Reset the settled thread page when the active label filter changes so filtered history starts from the first page on web and mobile. Co-authored-by: Cursor <cursoragent@cursor.com>
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 e6ee5c6. Configure here.
Keep navigation sidebar pending tasks consistent with filtered thread lists in both legacy groups and the v2 list. Co-authored-by: Cursor <cursoragent@cursor.com>

Summary
Thread labels are now durable, automatically generated metadata for the existing thread lifecycle.
bug,feature,review, andnew-buildlabels to contracts, event decisions, projections, SQLite persistence, and migration coverage.Why
Threads previously had no durable category, making it difficult to scan, filter, and recover the intent of a large thread list. This keeps classification close to the existing title-generation flow, persists it through the event-sourced server, and exposes the same behavior across clients.
Screenshots
Validation
vp test run --exclude '**/.t3/**' apps/server/src/orchestration/decider.labels.test.ts apps/server/src/orchestration/projector.labels.test.ts apps/server/src/persistence/Migrations/037_ProjectionThreadsLabels.test.ts apps/server/src/orchestration/Layers/ProjectionSnapshotQuery.test.ts apps/server/src/persistence/Layers/ProjectionRepositories.test.ts— 5 files, 17 tests passed.vp test run --exclude '**/.t3/**' apps/server/src/orchestration/Layers/ProviderCommandReactor.test.ts apps/server/src/textGeneration/TextGenerationPrompts.test.ts packages/shared/src/threadLabels.test.ts packages/client-runtime/src/state/threadReducer.test.ts apps/mobile/src/features/home/home-list-filter-menu.test.ts— 5 files, 101 tests passed.git diff --check FETCH_HEAD...HEAD— clean.Model/harness: GPT-5.6 Luna via Cursor CLI.
Made with Cursor
Note
Add automatic thread label assignment and label filtering across web and mobile
ThreadLabeltype (bug,feature,review,new-build) inpackages/contracts/src/thread.tsand shared display utilities inpackages/shared/src/threadLabels.ts.label; the first-turn and regeneration flows inProviderCommandReactorapply the label to unlabeled threads viathread.meta.updatewith compare-and-set semantics.037_ProjectionThreadsLabels) adds a nullablelabelcolumn toprojection_threads; the projection pipeline, snapshot queries, and repositories all read/write this column.threadLabels: truecapability.label: nulluntil the migration runs and the server re-generates or a user manually assigns a label.Macroscope summarized 66e44fe.