Skip to content

feat: allow accepting memory proposals across all projects - #145

Open
mfituri wants to merge 1 commit into
mainfrom
t3/memory-proposal-personal-all-projects
Open

mfituri wants to merge 1 commit into
mainfrom
t3/memory-proposal-personal-all-projects

Conversation

@mfituri

@mfituri mfituri commented Nov 22, 2026

Copy link
Copy Markdown

Personal all-projects memory (memory/people/<user>.md) and team all-projects memory (memory/team.md) already load into threads and can be edited in the Memory panel, but in-chat memory_propose cards (and the shared unanswered proposal rows in the Memory panel and Questions page) only offered project-scoped accept buttons (me and team).

What changed

  • Contracts (packages/contracts/src/memory.ts): Added "me-all" and "team-all" to MemoryChoice and MemoryDecisionChoice, keeping "me" and "team" unchanged so existing proposals.json history decodes cleanly.
  • Server (apps/server/src/memory/Memory.ts):
    • Mapped "me-all" to "personal" (memory/people/<live-login>.md) and "team-all" to "team" (memory/team.md) in appendedLine, with matching PR titles and branch stems (memory/personal-<login>, memory/team).
    • Tightened supersededVoiceAgentMemory to allow only "me" (rejecting "team", "team-all", and "me-all").
    • Existing proposeEdit (change / remove) and undo already operate on proposal.file / decision.file, so edits and undos for all four scopes work directly.
  • Web UI (apps/web/src/components/memory/MemoryProposalCard.tsx, memoryProposal.logic.ts):
    • Turned Accept for me and Accept for team into split buttons (Group + GroupSeparator + Menu): clicking the primary button still accepts for the current project in one click, while each dropdown offers both this-project and all-projects targets.
    • Because MemoryDecisionButtons is shared by MemoryProposalCard and MemoryProposalRow, the split buttons appear across chat cards, the Memory panel's Proposals tab, and the Questions page.
    • Added memoryAcceptedLabel so accepted cards show Accepted for you across all projects and Accepted for the team across all projects (with working Undo).
  • Docs & tests: Extended Memory.test.ts and memoryProposal.logic.test.ts (including live login switching, voice-agent guards, and undo for me-all / team-all), and updated docs/user/team-projects.md and fork/README.md.

Verification

  • vp run check:changed passed (format, lint, knip, graphql, typecheck across 43 packages, test across 4 files / 28 tests, react compiler).
  • Verified visually in the isolated dev web app (vp run dev) across both the in-chat proposal cards (pending split buttons + open dropdown + me-all / team-all accepted cards) and the /questions page.

Built with Gemini 4 Neon (High) via Antigravity.

@cursor

cursor Bot commented Nov 22, 2026 •

Copy link
Copy Markdown

PR Summary

Medium Risk
Changes memory decision handling and catalog PR targets; mistakes could write to the wrong shared memory files, though existing me/team defaults and tests limit regression risk.

Overview
Adds me-all and team-all decision choices so new agent memory lines can be saved to global files (memory/people/<login>.md and memory/team.md) instead of only project-scoped paths. Contracts extend MemoryChoice / MemoryDecisionChoice; the server’s appendedLine maps each choice to scope, PR title, and branch stem, while voice-agent proposals still accept only me.

In the web UI, Accept for me and Accept for team become split buttons: the primary click keeps the existing project-scoped behavior; the menu picks this project vs all projects. Accepted cards use memoryAcceptedLabel for clearer outcomes (including undo). Tests and user docs cover the new flows.

Reviewed by Cursor Bugbot for commit 39a2aa1. Bugbot is set up for automated code reviews on this repo. Configure here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant