
MemoryGuard
io.github.MerakOsiris由 GitHub 帳號 MerakOsiris 發布v0.7.15更新於 Oct 24, 2026
Local-first governed MCP memory backend for coding agents.
發布方自己的服務:Memory.fit
概覽
MemoryGuard 是面向編碼代理的本地優先 MCP 記憶後端,透過作用域規則、證據與回滾來治理共享記憶。
- 可以做什麼
- 在會話開始時載入有界的強制規則與相關記憶脈絡,並檢視共享記憶狀態與支援分頁和選用結構描述的能力目錄。搜尋、讀取、寫入、更新與軟刪除受治理的記憶,寫入會被分類整理。執行唯讀的本機治理稽核,並解釋稽核發現及其證據。探索並呼叫已註冊的 MCP 操作或經審核的無頭 GUI 操作,變更類目標需要確認與冪等鍵。規則生命週期、原始碼掃描、CodeGraph、知識與歷史審閱等高階治理仍在桌面主控台與命令列中完成。
- 適用情境
- 當多個編碼代理寫入同一專案脈絡,而你希望持久記憶經過去重、限定作用域、保留證據且可回滾,而不是一堆未經審閱的筆記時使用。適合希望資料僅存本機、由人工複核例外情況的使用者。
- 執行需求
- 以本機 stdio MCP 伺服器執行,需用 Python 從 PyPI 安裝(pip install agent-memguard);選用桌面主控台需安裝 gui 附加元件。每個專案需用命令列授權,並連接或修復編碼代理主機(Claude Code、Codex、Cursor、TRAE)後重新啟動。無需帳號、遠端伺服器、API 金鑰或標頭;除非明確授權遠端嵌入或模型索引,資料保留在本機。
安裝
在 SourceWeft 中
- 開啟 儀表板中的 MemoryGuard,將其新增到工作區。
- 為需要使用其工具的對話啟用該服務。
Desktop only,透過 STDIO。 STDIO 服務會啟動本機處理程序,因此需要 SourceWeft 桌面主機。
其他 MCP 客戶端
參照 儲存庫 中的啟動說明。
README
MemoryGuard
Governed shared memory for coding agents.
Local-first MCP memory with automatic organization, scoped rules, evidence, and rollback.
[PyPI version] [CI status] [Python 3.10 or newer] [MIT license] 中文文档
Let agents write without turning shared memory into an unreviewed pile. MemoryGuard organizes each write, preserves the evidence behind changes, and keeps governance decisions reversible.
No account. No remote server. No remote telemetry. Local-only usage telemetry is optional and stores bounded, privacy-preserving aggregates locally.
Quick start · Upgrade · Knowledge Library · Architecture · Supported hosts · Privacy and safety
A synthetic governed projection: signals move through memory categories while raw conversation text remains outside the graph.
What's New in v0.7.15
- Automatic CodeGraph builds: Trusted bootstrap starts a project's first build in a background process. Default and per-project switches persist; disabling automation preserves the graph. Supported file-write events trigger incremental refresh.
- Clear graph navigation: Switch between a file overview and symbols, filter by file, inspect neighboring relations, and use zoom controls.
- Bounded temporary storage: Ordinary graph queries read SQLite directly instead of retaining full-database copies. Validation and installation temporary files use the owning project/deployment cache and are cleaned up when the operation ends.
See the v0.7.15 release note and CodeGraph automation details. Reconnect or restart hosts after upgrading and repairing their provider integration.
Earlier governance improvements
v0.7.13 strengthens mandatory-rule replacement and recovery, improves audience-aware identity handling, and improves conflict resolution:
- Safe mandatory-rule replacement: Replacements validate the final mandatory package against audience matching, canonical rules, deduplication, sensitivity checks, and publication budgets. Equivalent unlocked predecessors retire in the same transaction; failed validation rolls back the complete update. See the replacement and recovery details.
- Native Agent/group audience matching: Matching and deduplication no longer split the same native audience solely by provider or runtime role. Distinct Agent identities remain separate, and project-scoped audiences retain their project boundaries. Provider repair uses the verified identity for its target provider.
- Readable, atomic conflict resolution: Conflict views preserve readable peer information, and resolution keeps peer groups intact while applying the selected changes atomically. Ambiguous conflicts remain unresolved.
- Cursor Hook protection: Cursor MemoryGuard Hooks now use a 30-second
timeout, up from 15 seconds, with
failClosed: true.
v0.7.14 only corrects release metadata for the GitHub repository rename; it does not change runtime behavior. See the v0.7.14 release note.
See the v0.7.13 release note and release history.
Earlier release details are kept in the Changelog and GitHub release records.
Token evidence and demo
Usage events distinguish measured_cached_input from
measured_cache_write_input. measured_cache_coverage.cache_read and
cache_write report complete, partial, or unavailable; measured zero
remains 0, while missing provider data remains None/unavailable.
Character-based estimates remain explicitly labelled
estimated mg_deterministic_unit, never provider tokens.
Run the benchmark only against an authorized local workspace:
Read the benchmark guide for measured, estimated, derived, and unsupported semantics. Use the demo recording checklist for a sanitized walkthrough. The repository's synthetic graph artwork is not a live product capture; it is not evidence of usage or savings.
Major V2 refactor in v0.6.0
v0.6.0 was a production data-plane refactor, not a storage-only upgrade:
- Authoritative V2 domains: Memory, Rules, Evidence, Content, Runtime, Projection, Assets, CodeGraph, Skills, and System state are separated into explicit SQLite domains with governed boundaries.
- Explicit cutover:
V1_ACTIVE → V2_BUILDING → V2_READY → V2_ACTIVEis fail-closed; V2 never silently falls back to legacy stores or dual-writes after READY/ACTIVE. - Lossless migration: frozen-source preparation uses coherent SQLite online backups, validates source/target evidence, rechecks live-source drift, and preserves V1 data plus migration backups for rollback.
- Native routing: MCP, CLI, GUI, and Hook surfaces are classified explicitly; the release closed the 233-surface cutover with 138 implemented routes, 95 retired routes, and zero neutral/blocker routes.
- Governed intelligence: Rule lifecycle and RuleMerge, extraction/enrichment, External MCP import, provider control-plane, conversation history, Knowledge Library, and GUI governance all use the V2 evidence and decision paths.
- Operational evidence: Reference Audit, per-domain SQLite health, guarded maintenance, rollback evidence, and safe unbound diagnostics are part of readiness and operations.
Why MemoryGuard
Persistent memory solves storage. It does not solve governance.
When several coding agents write into the same context, records become duplicated, stale, contradictory, over-broad, or unsafe to reuse. MemoryGuard sits between coding agents and their shared memory to keep that context usable.
System architecture
Quick start
MCP Registry metadata
This package exposes a local stdio MCP server as io.github.MerakOsiris/memoryguard.
Registry metadata is kept in server.json, and the marker above
ships with the PyPI package README. Releases are published through GitHub OIDC
to PyPI and the official MCP Registry. Verify the current package version and
the Registry entry's active/latest state through their live public records.
1. Install
For the desktop governance console:
2. Authorize the current project
3. Connect or repair your coding agent
Global provider configuration is rebuilt from the real binding in the canonical user data home. The command is idempotent and removes superseded MemoryGuard project-level overrides after a successful global takeover.
Restart the host after installation, then verify the integration:
Launch the desktop console:
memoryguard-gui . remains available for desktop shortcuts. A bare
memoryguard gui always opens the canonical user-level control directory
(default %LOCALAPPDATA%\MemoryGuard on Windows), so running it from a project
or from C:\Windows\System32 cannot silently switch databases.
MEMORYGUARD_WORKSPACE is an explicit operator override; an explicit
memoryguard gui <project-path> or memoryguard gui --workspace <project-path>
selects a specific workspace.
It does not remember a previously selected project or open a folder picker.
On Windows, memoryguard gui detaches the native window from the terminal, so
closing PowerShell does not close the GUI.
Provider-specific setup and behavior:
Stable Codex / Router binding
Codex/Router binds MemoryGuard to the stable local Codex program and control installation. An account profile is an endpoint/alias, not a new memory owner: switching profiles automatically discovers or repairs the profile and reuses the verified Agent binding and active group. Request identity remains fail-closed; this does not share records across machines or with arbitrary accounts.
Upgrade
MemoryGuard currently upgrades through Python's package manager:
If you installed the GUI extra, keep it during the upgrade:
There is no package self-update command. The package manager is the
authoritative package-upgrade path; memoryguard upgrade below is the explicit
workspace migration flow, not a package updater.
Upgrade an existing V1 data home
Upgrade the package, then run the verified migration. No workspace, data-home, apply, or confirmation arguments are required for the normal user-level data home:
The command prepares V2, validates the frozen and live source evidence,
migrates Agent/Group control, activates only after all gates pass, and removes
only the backup batch belonging to that successful migration. Re-running it on
V2_ACTIVE is idempotent. For a zero-write report, use:
Advanced explicit workspace/data-home options remain available for operators managing an isolated installation. A failed gate stays non-active and preserves its evidence; successful activation does not keep a redundant migration backup.
Existing pre-V2 workspaces: explicit V2 cutover
v0.6.0 never auto-activates an existing workspace. Upgrade the package first, then use the packaged operator CLI:
The prepare step uses coherent SQLite online backups, preserves V1 and
migration-backups, and rechecks live-source drift before READY. Activation
performs another fresh drift check before changing the manifest. Do not delete
legacy V1 data or migration backups as part of the upgrade.
Knowledge Library
The desktop console can turn a selected folder or file set into one governed local knowledge library. Source files remain where they are; MemoryGuard stores the searchable index in its user data home instead of copying a runtime database into every source project. Knowledge metadata never becomes a second source-body store.
Open the desktop console and choose Knowledge Library. Remote embedding or model-backed indexing is opt-in and requires explicit authorization; local full-text retrieval remains available without sending source text to a remote provider. Background imports, re-ingests, and smart rebuilds have durable task receipts: retrying the same request reuses its task, while reusing that key for a different request is rejected. A live task for a different request reports busy rather than claiming that work was accepted.
CodeGraph refresh
The first CodeGraph build is an explicit, confirmed full build. After a scope
has been built, each successful trusted file write can trigger an incremental
refresh for that scope, subject to strict source-path and active-binding
validation. Unchanged content hashes are a no-op; deleted files are retired;
the next context receives one bounded affected receipt. MemoryGuard does not
run a daemon or watcher for this path and does not infer paths from shell or
free-form text. A projectless MCP caller first builds an already-bound directory
source, then passes its codegraph_source_id to select that exact scope for
query, status, update, and graph reads.
Desktop console surfaces
The GUI has eight visible navigation entries: seven governance pages plus a separate Token usage-and-savings view:
- Governance Overview
- Data Sources & Agents
- Memory Core
- CodeGraph
- Rules & Habits
- Conversation History
- Risk Signals & Governance Console
- Token Usage & Savings (separate from the seven governance pages)
Agent lists use readable program/provider names; the underlying ID remains available in the detail view. Empty data is shown as an explicit empty state.
Write and governance lifecycle
The console is not an approval queue. Agents keep moving. MemoryGuard records the outcome and exposes the evidence needed to correct it later.
What you can govern
Rules and history stay separate
MemoryGuard deliberately keeps governed long-term memory and raw conversation history on different paths.
History retrieval is progressive: search results, then a bounded timeline, then an explicitly selected turn or session. Extracting from history creates a preview first; it does not silently write a long-term memory.
Supported hosts
Provider status is reported honestly as redirected, observed, operational, or unsupported. MemoryGuard does not claim it can disable every host's native memory when the host exposes no reliable integration point.
Architecture
V2 uses separate authoritative SQLite domains rather than one shared-memory
database. The runtime reads and writes V2 only after the manifest reaches
V2_ACTIVE; V2_BUILDING and V2_READY never silently fall back or dual-write.
Evidence remains traceable without being treated as automatically trusted memory.
Privacy and safety
- MemoryGuard runs as a local MCP stdio server.
- All governed data stays local unless you explicitly authorize a remote model
or embedding operation. Optional usage telemetry is local-only: its measured
host token events and deterministic conversion events are stored under
.memoryguard/usage_telemetry.sqlite; it does not upload data. Token savings are estimates based on MemoryGuard deterministic units, not a provider billing statement. Hosts without token reporting remain unsupported in the measured columns. - The Knowledge Library database uses
MEMORYGUARD_HOMEor the platform user data directory, so a selected source folder does not receive its own knowledge database. - V2 authoritative workspace state is separated under
.memoryguard/into explicit Memory, Rules, Evidence, Content, Runtime, Projection, Assets, CodeGraph, Skills, and System domains; History, Source, Binding, and Group control are V2-native surfaces. Legacy V1 artifacts are preserved as local rollback/audit evidence after cutover and are no longer the active V2 runtime write path; onlymemoryguard.migrationmay read them. - Source scanning is read-only by default.
- Mutating governance paths use validation, explicit scope, provenance, and reversible state.
- Quarantined records stay outside active shared memory.
- Raw conversation history is never injected into bootstrap automatically.
- Shared-group history access follows current active membership and does not grant deletion rights over another Agent's source.
CLI
The installed memoryguard command exposes these top-level operations:
The old V1 plan, apply, verify, undo, import, and gc workflows may
remain parseable as explicit retired compatibility surfaces, but are not a V1
runtime path. Under V2_ACTIVE they return a stable retired result instead of
writing through a legacy store. Legacy data input is accepted only by the
explicit memoryguard.migration upgrade flow.
Run memoryguard --help or memoryguard <command> --help for the live command
reference.
MCP API
The default MCP discovery surface is intentionally compact. New MCP clients
receive these eleven day-to-day tools through tools/list:
Advanced governance remains available through the GUI and CLI: rule lifecycle,
bindings and shared groups, source scanning, CodeGraph, knowledge and history
review, provider controls, external MCP import, and maintenance operations.
Existing advanced MCP names remain callable for compatibility when an installed
client invokes an exact name, but they are not returned by the default
tools/list. This reduces discovery/schema overhead without removing those
governance capabilities.
memoryguard_capabilities is the discovery path for the broader compatibility
catalog. It supports exact operation lookup, English or Chinese query text,
domain filtering, and offset pagination; schemas are returned only when
include_schema=true is requested for the selected page. The catalog exposes
162 reviewed headless GUI business operations through memoryguard_invoke.
Eight GUI operations remain explicitly restricted by their existing authority:
desktop-only path/folder actions, desktop-admin CodeGraph selection/build, and
SafeBridge protocol actions.
Bounded read responses
MemoryGuard minifies JSON text by default. A replayable read response is capped
at 24,000 UTF-8 bytes across the complete MCP envelope, including every
content block and existing structuredContent. Small responses keep their
existing shape. An oversized read returns a compact receipt with response_ref
and required identifiers; it does not silently truncate the original result.
Fetch a page through the existing broker, after discovering
memoryguard_response_read with memoryguard_capabilities:
Pages are UTF-8 JSON fragments with next_offset; concatenate them in order.
limit is 4–4096 bytes and offsets must be UTF-8 character boundaries. On a
single JSON text payload, fields selects business fields: use a top-level
name or an object-only JSON Pointer such as /data/memory_id. Multi-content
and non-JSON results reject field selection and remain available only as
whole-envelope pages.
Private references live only in the MCP process for at most five minutes: at
most 16 snapshots, each at most 512,000 bytes. They are bound to the exact
trusted session, principal, scope, and active binding revision. Each page
reruns the original read under current authorization and compares its
digest. A denial, changed output, binding/session change, or expired reference
returns a stable refusal such as response_ref_access_denied,
response_ref_expired, or response_ref_result_changed; cached old content
is never used to bypass the current read. Public capability metadata uses its
existing offset pagination. Writes and context bootstrap keep their existing
complete receipt/mandatory-rule contracts and cannot request response
pagination, so a page read never reruns a mutation. If an oversized read cannot
safely create a reference, its bounded receipt reports
delivery.status="unavailable" and action="narrow_query" rather than
promising the whole result can be retrieved.
Example discovery and invocation using the published schemas:
For a mutating target, the invoke envelope must also carry
"confirmed":true and a non-empty "idempotency_key"; the broker forwards
those proofs to the target's existing permission and scope checks.
The underlying compatibility catalog also covers:
- governed memory read, search, write, update, delete, and status;
- bounded context bootstrap with mandatory-rule isolation;
- rule creation, feedback, merge governance, undo, and scope statistics;
- Agent binding and shared-group inspection;
- source scanning, graph projection, import previews, and build planning;
- external MCP discovery and import;
- document extraction previews and candidate acceptance;
- conversation-history search, timeline, explicit read, export, deletion, and extraction preview;
- provider installation and host-agent enrichment.
Use MCP tools/list for the compact default discovery set. Use
memoryguard_capabilities for the registered compatibility catalog and its
reviewed operation metadata.
Project links
- PyPI package
- GitHub releases
- Changelog
- v0.7.13 release note
- v0.7.12 release note
- v0.7.11 release note
- v0.7.9 release record
- v0.7.8 release record
- v0.7.7 release record
- v0.7.6 release record
- v0.7.5 release record
- v0.7.4 release record
- v0.7.3 release record
- v0.7.2 release record
- v0.7.1 release record
- v0.7.0 release gate
- Memory continuity and lossless storage spec
- Privacy policy
- Terms of use
- Contributing guide
- Contributor License Agreement
- Issue tracker
Roadmap
- Release history: v0.7.9 consolidates canonical governance, local-only token evidence, readable multi-agent governance, and public distribution through GitHub, PyPI, and the official MCP Registry. v0.7.8 records the preceding governance, telemetry, and Codex runtime work; v0.7.7 makes bare provider repair safe in a verified, uniquely bound control home and aligns installed Codex MCP/Hook repairs to the current interpreter while preserving Agent and shared-group identity. v0.7.6 makes Codex Hook/MCP runtime selection consistent through one immutable snapshot, shortens Hook state lock windows, and keeps bootstrap success/failure state honest with explicit mandatory-overflow fail-closed handling. Earlier release records retain the detailed v0.7.5 conflict-review, v0.7.4 canonical-governance, v0.7.3 shared-history, and v0.7.2 write/read and Codex lifecycle changes. The v0.7.1 V2-only migration and desktop lifecycle work remains documented as historical release context.
- Acceptance boundary: the Graphify evidence is the focused
3 / 3result plus the real full-repository export/projection described above. It does not claim that upstream Graphify's full-repository test suite passed. - Next after release: broader CodeGraph/Skills ingestion, more operator-friendly maintenance reports, and additional migration observability. Long-term records are not retired merely because they are old.
- Later: team and enterprise capabilities only after validated demand.
Contributing
Issues and pull requests are welcome. Read CONTRIBUTING.md before submitting a change. Pull requests require agreement to the CLA.
License
來源:README.md,提交 a1de280
工具
0版本歷史
2- v0.7.15最新Sep 30, 2026
- v0.7.14Sep 28, 2026
評分
已滿足適用檢查項的 50%
該評分衡量此收錄條目的完整程度,依據註冊中心條目、端點與公開來源計算得出。它不是對伺服器本身的評價,也不表示伺服器安全或目前可用:可連通性是帶日期的檢查結果,評分也不包含安裝量或使用者評價。
- 近 30 天內可連通25 分
請保持端點能夠回應 MCP 握手;SourceWeft 每 30 天探測一次。
- 已宣告認證方式10 分
請在註冊中心條目中宣告憑證請求標頭,或保持端點能夠回應探測,以便判定其認證方式。
- 已列出工具15 分
請讓伺服器在無憑證時回應 tools/list,或發布可在沙箱中無憑證啟動的軟體包。
- 描述必需15 分
- 圖示10 分
- 文件15 分
- 授權條款10 分
其他 Memory 整合

Memory.fit
fit.memory官方發布者
託管式 Memory.fit 伺服器,讓 AI 讀取你的訓練、睡眠、恢復與飲食資料,並寫回每週計畫、每日目標和飲食計畫。
pg.ddx.io: the PostgreSQL community's memory
io.ddx.pg官方發布者
pg.ddx.io: the PostgreSQL community's memory 的託管 MCP 服務,由 pg.ddx.io 發布;無需登入;Streamable HTTP;29 個工具。
var.gg Naming Memory
gg.var官方發布者
遠端 MCP 伺服器,可依領域概念推薦並檢索韓、日、中、越、英多語言的程式識別字名稱,並提供 ERD 結構查詢。

Memoria — Deterministic AI Memory & Code Intelligence MCP
由 GitHub 帳號 kolivritech 發布
遠端 MCP 伺服器,為 AI 程式開發助理提供確定性的長期記憶與程式碼智慧工具,召回過程不消耗 LLM token。

thron-memory
由 GitHub 帳號 jacobbarglof 發布
為所有支援 MCP 的 AI 應用提供一份共用的私有記憶,以純文字筆記頁形式供助理搜尋、讀取和更新。