fix(provider-cursor): advertise manual compaction#31203
Summary
Cursor supports native manual compaction, but its provider snapshots omit /compact, hiding the slash-menu entry and disabling the context-meter action. Advertise the existing shared command in enabled initial and probed snapshots, following other providers.
| 1 | Cursor provider snapshots |
| 2 | - slashCommands: [] |
| 3 | + slashCommands: [COMPACT_SLASH_COMMAND] |
This is a small fix for an existing capability. The native agent.summarize() path from #29398, automatic compaction, MCP configuration, and defaults are unchanged.
Evidence
- Before:
vp test run packages/provider-cursor/src/server/status.test.tsfailed three assertions because enabled initial, successful, and empty-model snapshots returned no commands. Disabled startup passed. - After: All 16 status tests pass. Coverage includes enabled and disabled startup, successful discovery, and empty-model discovery.
vp run check:changedpasses formatting, lint, knip, affected-package typechecks (10 packages), and 18 tests across two files.- Live UI was not tested; this change only updates provider capability advertisement.
Merge Danger
Door: Two-way. Reverting restores the previous advertisement.
Blast Radius: Cursor. Only snapshot commands change; compaction execution is untouched.
Implemented with GPT-6.1 Sol via T3 Code.
Checks
Added 1 commit
- fix(provider-cursor): advertise manual compaction3c837e3
Approvability
Verdict: Approved at 3c837e3
Macroscope's review found this PR approvable — Cursor now advertises its existing manual compaction capability in provider snapshots, making it discoverable in command controls. Compaction remains user-invoked; automatic behavior and product defaults are unchanged.
You can add or adjust custom eligibility rules. Learn more.
No actionable comments were generated in the recent review.
Walkthrough
-
Cursor provider snapshots now include
COMPACT_SLASH_COMMANDwhen enabled. Tests verify initial snapshots for enabled and disabled states, and update expectations for probe-result and API-key snapshots.Changes: Cursor compact command
Layer / File(s) Summary Add compact command to Cursor snapshots
packages/provider-cursor/src/server/status.ts,packages/provider-cursor/src/server/status.test.tsEnabled initial and probe-result snapshots include COMPACT_SLASH_COMMAND. Tests check enabled and disabled initial snapshots and update expectations for snapshots with no discovered models and API-key status.Estimated code review effort: 2 (Simple) | ~8 minutes
Change: Bug fix
Suggested reviewers:
stienswout
Merge Risk: External image Minimal · up to 7a608
-
Cursor providers will now show the /compact command when enabled. The change is small and reversible, and no concrete merge risk was found.
Pre-merge checks: Passed 4
-
Check name Status Explanation Title check Passed The title names the main change: Cursor provider snapshots now advertise the manual compaction command (/compact). It uses the conventional commit form and matches the status.ts and status.test.ts cha… Description check Passed The description follows the template. It gives a problem summary, the change with a diff, scope (a small fix for an existing capability, no issue link), and verification with before and after test res… Linked Issues check Passed Check skipped because no linked issues were found for this pull request. Out of Scope Changes check Passed Check skipped because no linked issues were found for this pull request. Full details: Title check
-
Explanation
The title names the main change: Cursor provider snapshots now advertise the manual compaction command (/compact). It uses the conventional commit form and matches the status.ts and status.test.ts changes, which add COMPACT_SLASH_COMMAND to enabled initial and probed snapshots.
Full details: Description check
-
Explanation
The description follows the template. It gives a problem summary, the change with a diff, scope (a small fix for an existing capability, no issue link), and verification with before and after test results. It also states what was not tested (live UI). The Scope section does not link an issue or explain why none is needed beyond calling it a small fix of an obvious gap, and it has no explicit Problem heading. Those gaps are minor. Model attribution is present.
-
Finishing Touches
-
Generate unit tests (beta)
-
- Create a new PR
-
- Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts
External image Recent review info
-
External image Run configuration
-
- Source mode: Auto
- Repository: pingdotgg/t3code
- Branch: main
- File: .coderabbit.config.ts
- Commit: a6d7695
- Layers: Repository TS config
- Review profile: CHILL
- Plan: Advanced
- Run ID:
6c207219-79f1-48de-a6b4-d0582b11df53
External image Commits
-
Reviewing files that changed from the base of the PR and between 3c837e3e477d8d8ff94dfd51b1ede87b7b3b15e3 and 7a60833c834f0edaf9f6bfe561afd5b9ef49eadc.
External image Files selected for processing: 2
-
packages/provider-cursor/src/server/status.test.tspackages/provider-cursor/src/server/status.ts
Included review availability: This review used your included allowance. Your plan provides up to 10 included reviews per hour; 9 remain after this review.
External image Recent review info
-
External image Run configuration
-
- Source mode: Auto
- Repository: pingdotgg/t3code
- Branch: main
- File: .coderabbit.config.ts
- Commit: a6d7695
- Layers: Repository TS config
- Review profile: CHILL
- Plan: Advanced
- Run ID:
6c207219-79f1-48de-a6b4-d0582b11df53
External image Commits
-
Reviewing files that changed from the base of the PR and between 3c837e3e477d8d8ff94dfd51b1ede87b7b3b15e3 and 7a60833c834f0edaf9f6bfe561afd5b9ef49eadc.
External image Files selected for processing: 2
-
packages/provider-cursor/src/server/status.test.tspackages/provider-cursor/src/server/status.ts
Included review availability: This review used your included allowance. Your plan provides up to 10 included reviews per hour; 9 remain after this review.
-
Added 1 commit
- Merge remote-tracking branch 'origin/main' into fix/cursor-compact-capability7a60833
Evidence
Real Chromium web client, 1280×800, light theme, separate fresh databases, authenticated real Cursor provider. On both commits, start Composer 2.5 with “Reply with just the word hello. Do not use any tools.”, wait for its completed hello reply, open the thread and type /comp.
The scenario failed on base because the compact entry was absent and passed on head because it was visible.
| Before | After |
|---|---|
| Before: Cursor omits compact | After: Cursor lists compact |
| a6d7695064 | 7a60833c83 |
| Before recording | After recording |
Not shown:
- The context-meter compaction action was not exercised; the captured flow proves slash-menu discovery.
- Native compaction execution was not invoked; the scenario checks availability after a completed real Cursor turn.
- Provider addition through Settings and the Codex comparison were not repeated; the scenario enabled Cursor through settings and created its real completed thread through the application CLI.