Repository navigation
feat(notes): unify workspace vault and Mem synchronization - #575
Merged
Merged
Conversation
PeterGuy326
added a commit
to bytefolk/mem
that referenced
this pull request
Oct 9, 2026
## Summary Add workspace-scoped Vault discovery, snapshots and atomic delta commits. Logical note IDs keep identical and empty notes distinct; whole-Vault CAS rejects competing stale edits with 409. Immutable revisions, mutable heads and tombstones preserve note identity and history. Closes #234. Client integration: bytefolk/roleweave#575. ## Behavior and boundaries - Existing workspace membership, read/write scopes and literal token paths authorize every operation; properties remain untrusted data. - Additive migration 0027 preserves existing file/auth/memory tables. Downgrade drops Vault state and requires a backup. - The snapshot is a separate current-state portability contract. Existing workspace bundles and CLI/MCP/Web adapters do not transport Vault history. - No local login helpers, credentials, machine paths or production deployment changes are included. ## CI baseline repair The first run failed on unchanged vulnerable Web dependencies and an unavailable public MinIO image, before exercising Vault code. Remove the unpatched braces chain with official Tailwind/PostCSS 4 and typescript-eslint 8; retain the existing theme and utility behavior with browser compatibility tests. Build test-only MinIO/mc images from checksum-pinned official sources and preserve isolation and every lifecycle assertion. Audit thresholds, checks and timeouts remain unchanged. ## Validation Local PASS: complete Go build/vet/unit/race; full disposable PostgreSQL integration and integration-race; clean Web install, zero-finding Linux/Windows audits, 109 unit tests, lint/typecheck/build, all browser acceptance; complete HTTP/CLI/MCP lifecycle with CI-exact Go 1.25.0. Test resources were removed. Remote verification on `18db8a26791b3827b86e8d3c9e11fec5ac171999`: all 21 checks and all 12 required checks pass, including [CI and Windows audit](https://github.com/bytefolk/mem/actions/runs/37809406457) and [full PostgreSQL/HTTP/CLI/MCP/browser validation](https://github.com/bytefolk/mem/actions/runs/37809406428). Non-author CODEOWNERS approval remains required. Public advisory sources, compatibility checks and exact evidence: [validation ledger](https://github.com/bytefolk/mem/blob/18db8a26791b3827b86e8d3c9e11fec5ac171999/docs/acceptance/VAULT_SYNC_VALIDATION.md).
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.
Change
RoleWeave separates position documents, shared knowledge and conversation memory, making a portable notebook and cross-device sharing difficult. This change provides one workspace Markdown notebook under
notes/, with Notes and Drive as the default resource workflow. Positions associate with note identities, completed answers can be saved with provenance, and turns expose the note references actually used.The notebook supports bounded local history and recovery, original attachments and image previews, and manual bidirectional Mem synchronization. Revision/hash checks and durable pre-image journals preserve notes across stale writes, interrupted syncs and failed index persistence. Concurrent edits retain conflict copies; equivalent image aliases resolve to one original while different originals are rejected. Existing knowledge is referenced in place until explicitly migrated, and legacy Doc APIs remain compatible.
CI follow-ups fix the explicit runtime package inventory, preserve conversation rendering without a preload bridge, and validate Mem as the default connection. Files are read through bounded verified descriptors with no-follow protection where available and path/identity checks on all platforms. Synchronization uses configured origins, known routes and reconstructed UUIDs.
Validation
See
docs/acceptance/workspace-vault-validation.mdfor reproducible evidence anddocs/workspace-vault.mdfor limits and deployment prerequisites. Implementation and source review used automated assistance. No personal maintenance tools, credentials, deployed data or runtime artifacts are included, and newer UI changes already on main are preserved.Rollback: revert the client change while retaining user
notes/and.roleweave/vault/files. Legacy knowledge and Doc APIs remain compatible; the dependent Mem migration is additive.Closes #574. Uses the canonical Mem Vault API in bytefolk/mem#235. Relates to #511.