Promote dev to staging - #712
Merged
Merged
Conversation
Cold-start tools/list still advertised "call remember ONLY when asked", so clients that keep the first list ignored SessionStart/UserPromptSubmit. Align those descriptions with the sidecar. UserPromptSubmit treated "what do you remember about how I like to work" as a new preference because "I like" matched the remember heuristic. Questions about stored facts now inject memwal_recall only. Setup skill and Claude Code docs now require the plugin CLI and refuse to treat MCP-only as a complete Claude Code install.
Review caught that isQuestion plus a bare remember word inverted explicit save requests into recall-only. Drop remember from the extra question heuristic and keep the dedicated recall phrases. Cover the inversion plus whats-my and tell-me-what-you-remember in hook tests.
UserPromptSubmit no longer keyword-classifies the prompt. It injects a decision rubric so the agent picks the tool from meaning — Vietnamese, typos, and nested "I like" questions no longer steer the wrong call. Co-authored-by: Cursor <cursoragent@cursor.com>
Writes are expensive. The hook rubric, initialize instructions, and remember tool descriptions now tell the agent to skip one-off tasks, the current file or bug, small talk, and duplicates. Co-authored-by: Cursor <cursoragent@cursor.com>
Loosen the remember bar so preferences and decisions save without being asked, while still skipping one-off tasks. Setup now merges a user-level CLAUDE.md routing block so MEMORY.md does not win the system prompt. Co-authored-by: Cursor <cursoragent@cursor.com>
Harry review on #706: signed-out tools/list was advertising proactive remember, so a model without credentials would spam 401s. Keep that path conservative. Signed-in cold start (bridge) still uses the sidecar wording. Advertise memwal_recall as a read-only search so clients that gate on destructiveHint do not hold back proactive recall. Drop the em dash the docs style audit flagged.
Restore firstTime so the full decision rubric injects once per session and later turns get a one-line nudge. Lower the quiet gate to 8 chars so terse Vietnamese preferences are not skipped. Pin hook tests to byte-identical output across prompts instead of re-asserting the constant. Wrap the CLAUDE.md routing block in memwal start/end markers and require user go-ahead before writing a global file.
fix(mcp): make Claude Code auto-remember/recall actually fire
Collaborator
Style Guide AuditAll 5 file(s) pass the style guide audit. |
Collaborator
Author
|
@harrymove-ctrl ready for review. Promote after #706. npm Fresh Claude Code install +
All test-plan boxes are ticked. One caveat: a brand-new |
Rebased onto dev after #706 landed. Two of the four things this branch originally carried are now solved there, better than I had them: - #706 split SIGNED_OUT_* from SIGNED_IN_* tool descriptions via buildToolDefinitions(proactive). My version pushed proactive wording into the one shared list, which would have told signed-out clients to save proactively with tools that cannot work. Dropped mine. - #706 set memwal_recall to readOnlyHint: true, destructiveHint: false, going further than the readOnlyHint: false I had. Dropped mine. memwal_analyze keeps dev's destructiveHint: true; it writes memories, so that value is defensible. What remains is what #706 did not cover. 1. REMEMBER had no turn anchor. Measured on dev with the #706-equivalent fixes live, T1-T3 from WALM-368, scored from the MCP log rather than the tool cards: T2 recall PASS memwal_recall fired unprompted and answered from it T1 remember FAIL no tools/call at all T3 control PASS Recall firing is new; both earlier dogfood passes recorded zero tools/call for a whole session. RECALL and REMEMBER ship in the same instructions block, to the same client, in the same session, so this is a controlled comparison rather than a guess. The difference is in our own text: RECALL is anchored to a turn event ("before answering anything that touches..."), REMEMBER said "without waiting to be asked", which asks the model to classify a statement and then self-start with nothing tying the call to a moment. In T1 it replied "Got it - <fact>. What do you need done with it?", treating a durable fact as task setup. REMEMBER now anchors with "in that same turn, before you finish replying", adds configuration values (hostname, port, region, id) since the failing case was one, and closes the observed behaviour: do not ask whether to save, and acknowledging a fact in the reply does not store it. #706's scoping ("skip one-off tasks, the current file or bug, and small talk") is preserved verbatim. Applied to all three copies; the two that must be byte-identical were verified so. 2. Tool calls were not scorable. The host logs `method="tools/call" id=N` with no tool name, so "remember never fired" and "remember fired and failed" are indistinguishable - the exact ambiguity under investigation. Logs bridge.tool_call with the tool NAME and never `arguments`, since memory text is the user's private data. 3. No live check of what a client is actually handed. test/handshake-contract.mjs drives the real built server against a chosen env and asserts the delivered contract: instructions present with both halves anchored, recall advertised read-only, and cold start agreeing with upstream field by field. Not named *.test.mjs on purpose - it needs a live relayer and credentials, and the npm test glob must not collect it. tool-definitions.test.mjs from #706 covers the static list; this covers the deployed path, which is where the earlier runs went wrong: metadata lives in services/server/scripts, so a published package alone changes nothing for a signed-in user, and testing before the relayer redeploys measures the old server. packages/mcp 28 pass, services/server/scripts 221 pass. Refs WALM-324, WALM-368
…tools Running the new probe against dev caught drift #706 did not cover. It synced memwal_remember and memwal_recall, which were the contradictory ones, and left four others pointing at pre-rewrite copy: memwal_remember_bulk title "Remember Several Facts" -> "Remember Multiple Facts" memwal_health title "Check Relayer Health" -> "Check Walrus Memory Health" memwal_analyze description 150 chars -> 340 memwal_restore description 165 chars -> 427 Less severe than the remember/recall case, since these are thinner rather than contradictory: memwal_restore upstream explains when to reach for it ("recall returns nothing even though facts were saved before"), while the cold-start copy only described the mechanics. A client that caches its first tools/list keeps the thin version for the whole session. Values copied programmatically from a live upstream tools/list rather than retyped, so they cannot drift again through transcription. login-handoff pinned the two stale titles. Its own comment requires pre-login discovery to expose "the same safety metadata clients will receive after the bridge hands off", so the expectations were wrong, not the change. Also makes the probe's instruction assertions whitespace-tolerant. The payload is newline-wrapped, so a phrase match with literal spaces fails on correct output whenever the phrase straddles a wrap. That produced a false FAIL on "Do not ask whether / to save it" and would keep doing so on any future rewording. packages/mcp 28 pass, services/server/scripts 221 pass, handshake-contract --dev 13/13. Refs WALM-368
…aseline MEMWAL_MCP_SERVER overrides the server path, which defaults to this checkout's build. Without it the probe can only describe the branch it sits in, so it could not answer the question that actually matters before merging: what does dev ship today? Measured against the real shipping artifacts, published @mysten-incubation/memwal-mcp@dev 0.0.10-dev.4 talking to the dev relayer at e4bdcc9 (#706), signed in: 11/13 passed FAIL REMEMBER is anchored to a turn event FAIL cold-start and upstream lists agree (drift: remember_bulk, analyze, restore, health) Those are exactly the two defects this PR fixes, and they reproduce with no code of mine in the path: dev's own package, dev's own relayer. The same probe against this branch reports 13/13. Useful beyond this PR as the before/after harness for any change to the handshake contract, and as the pre-flight before a dogfood run: it distinguishes "the model chose not to call the tool" from "the client was never handed the contract", which is the ambiguity that made the earlier WALM-368 runs unreconcilable. packages/mcp 28 pass. Refs WALM-368
fix(mcp): anchor REMEMBER to the turn, log tool names, add a live handshake probe
harrymove-ctrl
approved these changes
Aug 20, 2026
This branch was successfully deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Promote
devtostagingafter merging #706 (Claude Code auto-remember/recall).Published npm:
@mysten-incubation/memwal-mcp@0.0.10-dev.4(devtag).Test plan
dev, Harry approveddevpublished0.0.10-dev.4MystenLabs/MemWal+ user MCP@0.0.10-dev.4 --dev+login --devsonnet-5: unpromptedmemwal_remember_bulk, saved 4/4 includingnpm-dev-lark-04sonnet-5session: calledmemwal_recall, returned npm-dev-lark-04 and dirty chaiNote: a brand-new
-psession can still start with MCPpendingifnpxis cold. Once the server is connected, remember and recall both work.Companion plugin sync: CommandOSSLabs/walrus-memory-mcp-plugin#5 merged.