Skip to content

[upstream PR 9] feat: agentmemory v0.4.0 — the memory layer for all AI coding agents #906

@wbugitlab1

Description

@wbugitlab1

Source repository: rohitg00/agentmemory
Source pull request number: 9
Source URL: intentionally omitted to avoid GitHub cross-references
Title: feat: agentmemory v0.4.0 — the memory layer for all AI coding agents
Author: rohitg00
State: closed
Draft: no
Merged: yes
Head: rohitg00/agentmemory:feat/v0.4.0-memory-layer @ 7a5f1ef
Base: main @ 5c4ef04
Labels: (none)
Changed files: 0
Commits: 0
Created: 2026-03-01T17:42:15Z
Updated: 2026-03-01T18:03:39Z
Closed: 2026-03-01T18:03:36Z
Merged at: 2026-03-01T18:03:36Z

Original PR body:

Summary

agentmemory v0.4.0 adds 7 major features to become the definitive memory layer for all AI coding agents — not just Claude Code.

New Features (all opt-in via env vars)

Feature What it does
Claude Code Memory Bridge Bi-directional sync with ~/.claude/projects/*/memory/MEMORY.md
Standalone Cross-Agent MCP npx agentmemory-mcp — works with Cursor, Codex, Gemini CLI, Windsurf
Knowledge Graph Entity extraction + BFS traversal across files, functions, concepts
4-Tier Consolidation Working → episodic → semantic → procedural with strength decay
Team Memory Namespaced shared + private memory across team members
Memory Governance Delete, bulk-delete, and audit trail for all operations
Git Snapshots Version, rollback, and diff memory state via git commits

Stats

Metric v0.3.0 v0.4.0
Functions 22 33
MCP tools 10 18
MCP resources 4 6
REST endpoints 34 49
KV scopes 12 21
Tests 144 216
LOC ~8,700 ~11,000
Bundle 142KB 208KB (192KB + 16KB standalone)

New Files (21 source + 8 tests)

  • src/functions/{audit,claude-bridge,graph,consolidation-pipeline,team,governance,snapshot}.ts
  • src/mcp/{tools-registry,in-memory-kv,transport,standalone}.ts
  • src/prompts/{graph-extraction,consolidation}.ts
  • test/{audit,claude-bridge,graph,consolidation-pipeline,team,governance,snapshot,mcp-standalone}.test.ts

Modified Files (17)

  • Types, schema, config, index, api, mcp/server, export-import, hooks, telemetry, package.json, tsdown, tests, README

Test plan

  • npx tsc --noEmit — compiles cleanly
  • npx vitest run — 216 tests pass (29 test files)
  • Bundle under 250KB target (208KB actual)
  • Manual: CLAUDE_MEMORY_BRIDGE=true logs sync to MEMORY.md
  • Manual: GRAPH_EXTRACTION_ENABLED=true logs extraction enabled
  • Manual: npx agentmemory-mcp responds to MCP initialize
  • Manual: New REST endpoints return expected responses

Summary by CodeRabbit

Release Notes

  • New Features

    • Added Claude Code bridge for seamless memory file synchronization
    • Introduced knowledge graph extraction, querying, and analytics
    • Added memory consolidation with semantic and procedural processing
    • Enabled team memory sharing, feeds, and collaborative profiles
    • Introduced audit trail and governance features for memory management
    • Added Git-based snapshots for memory backup and recovery
    • Launched standalone MCP server mode with persistence support
  • Documentation

    • Updated guides reflecting new capabilities and integrations
  • Tests

    • Added comprehensive test coverage for new features

Local branch:
Fork PR:
Fork decision:
Verification:
Notes:

Metadata

Metadata

Assignees

No one assigned

    Labels

    decision-candidateFork decision has not been madeupstream-mergedUpstream pull request is merged upstreamupstream-prTracks an upstream pull request

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions