Source repository: rohitg00/agentmemory
Source pull request number: 7
Source URL: intentionally omitted to avoid GitHub cross-references
Title: feat: agentmemory v0.4.0 — MCP resources, prompts, enrichment, confidence
Author: rohitg00
State: closed
Draft: no
Merged: yes
Head: rohitg00/agentmemory:feat/v0.4.0-mcp-resources-enrichment @ 0492682
Base: main @ 1333118
Labels: (none)
Changed files: 0
Commits: 0
Created: 2026-02-28T09:51:45Z
Updated: 2026-02-28T10:28:35Z
Closed: 2026-02-28T10:28:32Z
Merged at: 2026-02-28T10:28:32Z
Original PR body:
Summary
Closes 4 feature gaps identified from GitNexus competitive analysis:
- MCP Resources (4):
agentmemory://status, agentmemory://project/{name}/profile, agentmemory://project/{name}/recent, agentmemory://memories/latest
- MCP Prompts (3):
recall_context(task_description), session_handoff(session_id), detect_patterns(project?)
- Confidence-scored relations: Auto-computed from co-occurrence (+0.1/shared session, max +0.3), recency (+/-0.1), and relation type (+0.1 supersedes, -0.05 contradicts). Explicit override supported.
minConfidence filter + confidence-desc sorting on mem::get-related
- Unified enrichment:
mem::enrich aggregates file context + relevant observations + bug memories into <agentmemory-relevant-context> / <agentmemory-past-errors> XML blocks. PreToolUse hook now calls /agentmemory/enrich with search term extraction from Grep/Glob patterns
Files changed (13)
src/types.ts — confidence?: number on MemoryRelation
src/functions/relations.ts — confidence scoring + minConfidence filter
src/functions/enrich.ts — new enrichment function
src/mcp/server.ts — 4 resources + 3 prompts endpoints
src/triggers/api.ts — POST /agentmemory/enrich + version bump
src/hooks/pre-tool-use.ts — switch to enrich endpoint
src/index.ts — wire up enrich, version bump
package.json — 0.3.0 → 0.4.0
- 4 new test files (27 tests)
Test plan
Summary by CodeRabbit
-
New Features
- Enrichment capability to aggregate file context, observations, and relevant past errors for improved processing.
- Confidence scoring for memory relations, exposed for filtering and ordering results.
- New resources and prompts endpoints for discovery and helper prompts.
- Public API endpoint to request enrichment.
-
Tests
- Added comprehensive tests for enrichment, confidence scoring, MCP prompts, and MCP resources.
-
Chores
- Bumped package version to 0.4.0.
Local branch:
Fork PR:
Fork decision:
Verification:
Notes:
Source repository: rohitg00/agentmemory
Source pull request number: 7
Source URL: intentionally omitted to avoid GitHub cross-references
Title: feat: agentmemory v0.4.0 — MCP resources, prompts, enrichment, confidence
Author: rohitg00
State: closed
Draft: no
Merged: yes
Head: rohitg00/agentmemory:feat/v0.4.0-mcp-resources-enrichment @ 0492682
Base: main @ 1333118
Labels: (none)
Changed files: 0
Commits: 0
Created: 2026-02-28T09:51:45Z
Updated: 2026-02-28T10:28:35Z
Closed: 2026-02-28T10:28:32Z
Merged at: 2026-02-28T10:28:32Z
Original PR body:
Summary
Closes 4 feature gaps identified from GitNexus competitive analysis:
agentmemory://status,agentmemory://project/{name}/profile,agentmemory://project/{name}/recent,agentmemory://memories/latestrecall_context(task_description),session_handoff(session_id),detect_patterns(project?)minConfidencefilter + confidence-desc sorting onmem::get-relatedmem::enrichaggregates file context + relevant observations + bug memories into<agentmemory-relevant-context>/<agentmemory-past-errors>XML blocks. PreToolUse hook now calls/agentmemory/enrichwith search term extraction from Grep/Glob patternsFiles changed (13)
src/types.ts—confidence?: numberon MemoryRelationsrc/functions/relations.ts— confidence scoring + minConfidence filtersrc/functions/enrich.ts— new enrichment functionsrc/mcp/server.ts— 4 resources + 3 prompts endpointssrc/triggers/api.ts—POST /agentmemory/enrich+ version bumpsrc/hooks/pre-tool-use.ts— switch to enrich endpointsrc/index.ts— wire up enrich, version bumppackage.json— 0.3.0 → 0.4.0Test plan
npm test— 171 tests passing (144 existing + 27 new)npm run build— clean build, no TS errorscurl GET /agentmemory/mcp/resources→ 4 resources listedcurl POST /agentmemory/mcp/resources/readwithagentmemory://status→ JSON countscurl POST /agentmemory/mcp/prompts/getwith recall_context → messages arraycurl POST /agentmemory/enrich→ enriched context stringSummary by CodeRabbit
New Features
Tests
Chores
Local branch:
Fork PR:
Fork decision:
Verification:
Notes: