Repomemory

io.github.DanielGuruPublished by GitHub account DanielGuruv1.3.0Updated Oct 24, 2026

Persistent memory for AI coding agents. Hybrid search, auto-session capture, context routing.

The publisher's own server: RepoMemory

VerifiedSTDIODesktop onlyKnowledge & MemoryDeveloper Tools

Overview

AI-generated overview

Persistent, searchable project memory for AI coding agents, exposing tools to search, read, write and delete a repo's .context knowledge base.

What you can do
  • Search and orient: hybrid keyword plus semantic search over repo and global context, and a one-call orientation returning index, preferences and recent sessions.
  • Read and browse: read full entries with repo-first, global-fallback lookup, and list entries tagged by provenance.
  • Write and maintain: record facts, decisions, regressions and preferences with scope routing, and delete stale knowledge.
  • Assess risk: report hotspots, hidden coupling and bus factor for the codebase or specific files.
  • Capture sessions and git history: session summaries are saved on shutdown and git history can be synced into a changelog.
When to use it
Useful when you work on the same codebase across many AI sessions and want agents to stop re-discovering architecture, re-debating settled decisions or re-introducing fixed bugs. It suits teams that want shared, searchable project knowledge instead of a static instruction file.
Requirements
Runs locally via npx (Node.js). Setup commands write MCP configuration and rules into tools such as Claude Code, Cursor, Copilot, Windsurf, Cline, Aider and Continue. AI analysis needs a provider API key such as ANTHROPIC_API_KEY, OPENAI_API_KEY, GEMINI_API_KEY or GROK_API_KEY; Cursor setup can skip external keys. Optional embeddings use Gemini or OpenAI keys.
Before you install
The tools can write and delete knowledge entries in the repository's .context directory, and setup modifies tool configuration files and installs a post-commit hook. AI analysis sends repository content to the chosen model provider, which is billed to your API key; embeddings may also be sent to Gemini or OpenAI. Review generated entries before relying on them.

Installation

In SourceWeft

  1. Open Repomemory in the dashboard and add it to a workspace.
  2. Enable the server for the chats that should use its tools.

Desktop only via STDIO. STDIO servers start a local process, so they need the SourceWeft desktop host.

Other MCP clients

Follow the launch instructions in the repository.

README

repomemory

Your codebase never forgets.

AI agents lose context every session. repomemory fixes that — one command creates a persistent, searchable knowledge base that any AI tool can read, search, and write to.

[npm version] [npm downloads] [license] [CI]

bash
npx repomemory go

The Problem

Every time you open a project with Claude Code, Cursor, Copilot, or any AI coding agent:

  • It re-discovers your architecture from scratch
  • It proposes changes that were already debated and rejected
  • It re-introduces bugs that were already fixed

Your CLAUDE.md / .cursorrules helps, but it's static and gets stale.

The Solution

.context/├── index.md              ← Quick orientation (loaded every session)├── facts/                ← Architecture, database, deployment├── decisions/            ← "We chose Drizzle over Prisma because..."├── regressions/          ← "This broke before. Here's what happened."├── preferences/          ← Your coding style — follows you across all repos├── sessions/             ← Auto-captured AI session summaries└── changelog/            ← Monthly git history syncs

Facts tell agents how things work. Decisions prevent re-debating. Regressions prevent re-breaking. Preferences teach agents how you code.

Quick Start

With an API key (Claude Code, terminal workflows)

bash
npx repomemory go

One command: sets up global profile, creates .context/, configures Claude Code + Cursor, runs AI analysis, prints CLAUDE.md instructions.

With Cursor (no API key needed)

bash
npx repomemory setup cursor

This installs everything Cursor needs:

  • MCP server in ~/.cursor/mcp.json (auto-starts repomemory in every project)
  • Rules in .cursor/rules/repomemory.mdc (teaches Cursor's AI to use context)
  • 6 commands in .cursor/commands/ (run with / in Cursor chat)

Then in Cursor chat, type:

/repomemory-analyze

Cursor's own AI scans your repo and populates .context/ via the MCP tools. No external API key required — your Cursor subscription handles it.

Available Cursor commands:

CommandWhat it does
/repomemory-analyzeFull repo analysis — populates facts, decisions, index
/repomemory-orientQuick orientation at start of session
/repomemory-searchSearch the knowledge base
/repomemory-recordRecord a fact, decision, or regression
/repomemory-sessionSave a session summary
/repomemory-statusShow context coverage

Guided wizard

bash
npx repomemory wizard

Walks through provider selection, tool integration, and first analysis. If no API keys are detected, offers a "None — I use Cursor" option that skips external analysis entirely.

Non-interactive (CI-safe)

bash
npx repomemory go --yes --provider anthropic --embedding-provider gemini --max-files 80

No prompts when --yes / --defaults / --no-prompt is used.

MCP Server — Agents With Real Memory

The real power is the MCP server. When configured via repomemory setup claude, it auto-starts with Claude Code and gives agents 7 tools:

ToolWhat It Does
context_searchHybrid keyword + semantic search across repo + global context
context_auto_orientOne-call orientation: index, preferences, recent sessions
context_writeWrite entries with smart scope routing (preferences → global)
context_readRead full content, repo-first with global fallback
context_listBrowse entries with [repo]/[global] provenance tags
context_riskAssess modification risk — hotspots, hidden coupling, bus factor
context_deleteRemove stale knowledge
Agent: "Let me orient myself in this project..."→ context_auto_orient()→ Returns: project overview, preferences, recent sessions, recent changes
Agent: "Let me search for context about the auth flow..."→ context_search("authentication flow")→ Auto-routes to facts/ category, returns compact results
Agent: "I found a race condition. Let me record this."→ context_write(category="regressions", filename="token-refresh-race", content="...")→ Persisted. Detects if it supersedes an existing entry.

Sessions are auto-captured on shutdown. Zero config — repomemory setup claude handles everything.

Supported Tools

ToolIntegrationAPI Key Required?
Claude CodeMCP server (auto-starts) + post-commit hookYes (for analysis)
CursorMCP server + rules + 6 slash commandsNo — uses Cursor's built-in AI
GitHub Copilotcopilot-instructions.mdYes (for analysis)
Windsurf.windsurfrulesYes (for analysis)
Cline.clinerulesYes (for analysis)
Aider.aider.conf.ymlYes (for analysis)
Continue.continue/rules/Yes (for analysis)

Cursor users: You don't need any API key. Run npx repomemory setup cursor, then use /repomemory-analyze in Cursor chat. Cursor's AI does the analysis using the MCP tools — whatever model Cursor is using (it can even switch models mid-task).

Supported Providers

ProviderModelsEnv Variable
anthropicclaude-sonnet-4-6, claude-opus-4-6ANTHROPIC_API_KEY
openaigpt-4o, o3-miniOPENAI_API_KEY
geminigemini-2.0-flash, gemini-2.5-proGEMINI_API_KEY / GOOGLE_API_KEY
grokgrok-3, grok-3-miniGROK_API_KEY / XAI_API_KEY

Embeddings (optional, for semantic search): Gemini text-embedding-004 (free, default) or OpenAI text-embedding-3-small. Auto-detected from available API keys.

All Commands

bash
repomemory go                            # One-command setup (add --yes for non-interactive)repomemory wizard                        # Interactive guided setuprepomemory analyze                       # AI-powered repo analysisrepomemory analyze --merge               # Update without overwriting editsrepomemory analyze --dry-run             # Preview without API callrepomemory search <query>                # Search knowledge base from terminalrepomemory status                        # Coverage and freshness reportrepomemory doctor                        # Diagnostics and health checkrepomemory dashboard                     # Local web UI (localhost:3333)repomemory risk                          # Hotspots, coupling, ownership analysisrepomemory risk -f src/auth.ts           # Targeted risk assessment for specific filesrepomemory sync                          # Sync git history to changelogrepomemory setup <tool>                  # Configure Claude/Cursor/Copilot/etcrepomemory hook install                  # Auto-sync changelog on commitsrepomemory global list                   # Manage global developer contextrepomemory global export                 # Export global context as JSON

Configuration

.repomemory.json in your repo root (all fields optional):

json
{  "provider": "anthropic",  "model": "claude-sonnet-4-6",  "embeddingProvider": "gemini",  "hybridAlpha": 0.5,  "maxFilesForAnalysis": 80,  "enableGlobalContext": true}

Custom ignorePatterns and keyFilePatterns are additive — they extend built-in defaults, not replace them.

Why Not Just CLAUDE.md?

CLAUDE.mdrepomemory
MaintenanceManualAI-generated + agent-maintained
SearchLoad everythingHybrid keyword + semantic
Cross-toolClaude Code only7 tools supported
Team knowledgeOne person writesEvery AI session contributes
DecisionsMixed in with instructionsStructured, searchable
RegressionsNot trackedPrevents repeat bugs
SessionsNot trackedAuto-captured on shutdown
FreshnessUnknownStaleness detection + auto-purge

repomemory doesn't replace CLAUDE.md — it complements it. CLAUDE.md is for instructions and rules. .context/ holds the knowledge that grows over time.

Contributing

See CONTRIBUTING.md for development setup, testing, and contribution guidelines.

License

MIT


Built for developers who are tired of AI agents forgetting everything between sessions.

Report Bug · Request Feature · npm

Source: README.md at commit b5b9d25

Tools

0
SourceWeft has not started this package in its sandbox yet, so its tools are not known.

Version history

1
  1. v1.3.0LatestSep 16, 2026

Score

50% of the applicable checks met

How complete this listing is, computed from the registry entry, the endpoint and public sources. Not a rating of the server and not a statement that it is safe or working today: reachability is a dated check, and no installs or reviews go into the score.

  • Reached in the last 30 days25 pts

    Keep the endpoint answering the MCP handshake; SourceWeft probes it every 30 days.

  • Auth declared10 pts

    Declare the credential headers in the registry entry, or keep the endpoint answering the probe so its auth can be classified.

  • Tools listed15 pts

    Answer tools/list without a credential, or ship a package that starts in a sandbox without one.

  • DescriptionRequired15 pts
  • Logo10 pts
  • Documentation15 pts
  • License10 pts

Other Repomemory integrations