Repository navigation
fix: show document content in the memory tool's list mode - #121
Open
ishaanxgupta wants to merge 2 commits into
Open
ishaanxgupta wants to merge 2 commits into
ishaanxgupta wants to merge 2 commits into
Conversation
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.
What
The
supermemorytool'slistmode returnedcontent: nullfor every memory. There were two causes:memory-tool.tsmappedmemory.summary, which is null for v5 documents.v5-client.ts, content hydration fetched each listed document and kept its content only ifdocument.metadata.sm_scopeequaled the requested scope. The v5 API leaves reservedsm_*keys out of document reads, so the check never passed and content was always dropped.Fixes:
listmapssummary || content || title, the same order compaction and the v2 runtime already use.sm_scopeon the server, which still works becausesm_scopeis one of the API's searchable reserved keys (SEARCHABLE_RESERVED_METADATA_KEYS). A missing key no longer drops the content.Release
2.1.1 in
package.jsonandsrc/version.ts.Tests
bun run test: 36 pass, 0 fail.bun run typecheckis clean.v5-client.test.ts:sm_*keys;sm_scope: personalduring a project list.memory-tool.test.tscase:listshows the content whensummaryis null.mainand pass here.Prod check (sandboxed
HOME, fresh OAuth sign-in, 2026-10-29)I saved one memory with the tool's
addmode under the throwaway tagrepo_audit_test_opencode_list__0123456789abcdef. That tag matches the scoped-tag pattern, so thesm_scopefilter path runs. Then I ranlistmode against prod on each version:Reading the same document directly from prod returns metadata keys
["type","project"]with nosm_scope, even though it was saved withsm_scope: project.The test blocked the client's startup
PATCH /v3/settingsso it wouldn't change org settings.