Skip to content

feat: restage the harness card on model switch without clobbering peers - #20

Merged
SoryAK merged 2 commits into
mainfrom
feat/cursor-envelope-model-name
Sep 10, 2026
Merged

feat: restage the harness card on model switch without clobbering peers#20
SoryAK merged 2 commits into
mainfrom
feat/cursor-envelope-model-name

Conversation

@SoryAK

@SoryAK SoryAK commented Sep 10, 2026

Copy link
Copy Markdown
Owner

Summary

  • Pairing can hold several models on one client; the harness envelope stays one playbook per project. Last connect that wrote a card owns the slot. A model with no card only pairs and does not unstage a sibling.
  • POST /models/ensure / mba_ensure_model restages this model's card in every project it is already paired to (MBA_MODEL_SWITCH=on). Revoke restages from the newest remaining owner, or unstages if nobody left has a card.
  • Status and clients label the owner card vs others pair, and drop a redundant default IDE from the display name. Built-in envelope filenames stay the harness slot (mba.mdc, CLAUDE.local.md, …); the model id lives inside the card.

Test plan

  • Connect two models to the same Cursor project: one with instructions.md, one without. Empty card must not wipe the sibling playbook.
  • Connect a second model that has a card; envelope should switch and print that it replaced the previous owner.
  • With MBA_MODEL_SWITCH=on, ensure/switch the first model and confirm paired projects restage its card.
  • Revoke the current owner; remaining peer with a card should restage, else the slot unstages.
  • mba status / mba clients show card vs pair and do not print cursor+cursor.

Made with Cursor

Pairing can hold several models on one client, but the envelope is still
one playbook. Empty cards no longer wipe a sibling; ensure updates the
staged instructions; status shows who owns the card.
Comment thread packages/core/src/mba/envelope.ts Fixed
Comment thread packages/core/src/mba/envelope.ts Fixed
Comment thread packages/core/src/mba/envelope.ts Fixed
@SoryAK
SoryAK force-pushed the feat/cursor-envelope-model-name branch from a433b0c to b8db71c Compare September 10, 2026 01:07
@SoryAK
SoryAK merged commit 06fd90b into main Sep 10, 2026
3 checks passed
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.

2 participants