# memory-mcp-lite [Health: Active]

**Category:** 🧠 Knowledge & Memory  
**Repository:** https://github.com/thuupx/memory-mcp-lite  
**GitHub Stars:** 4  
**npm Downloads (last month):** 262  
**Views:** 2  
**Installs:** 0  
**Upvotes:** 0  
**Directory Page:** https://allmcps.com/mcp/memory-mcp-lite

## Description
A lightweight, structured, token-efficient local-first MCP memory server

## Tools
Capabilities this server exposes over MCP:

- **get_global_summary** — Return the user's cross-project global memory summary (coding style, recurring preferences, stable workflow conventions).
USE WHEN: the request depends on durable user-level preferences that apply across projects.
DO NOT USE WHEN: the question is project-specific, purely syntactic, or self-contained.
RETURNS: { found, summary? } where summary has { id, title, summary, updated_at }.
- **get_project_summary** — Return the concise summary for the current project (architecture, key decisions, conventions).
USE WHEN: the request depends on project-level context — architecture, conventions, long-term decisions, or project overview.
DO NOT USE WHEN: the request is about the current task's state, global preferences, or is self-contained.
CALL ORDER: prefer this before search_memory_light. Pass workspace_path OR git_root OR remote_url OR project_id so the server can identify the project.
RETURNS: { project_id, found, summary? } where summary has { id, title, summary, updated_at }.
- **get_task_summary** — Return the current task summary (what was done, blockers, next steps).
USE WHEN: the user asks to continue, resume, or recall recent work on a task.
DO NOT USE WHEN: there is no prior task state referenced, or the request is about global / project-level context.
RETURNS: { project_id, found, summary? } where summary has { id, title, summary, updated_at }.
- **search_memory_light** — Lexical FTS5 search across atomic memories. Returns compact candidate records only — not full content.
USE WHEN: the summary tools above do not provide enough context AND the request includes a concrete search phrase (command name, symbol, past event).
DO NOT USE WHEN: summaries already answer the question, the query is empty/too vague, or you only need the global/project/task summary.
CALL ORDER: always call summary tools first. Then follow up this tool's top 1-3 results with get_memory_detail — never dump all candidates.
RETURNS: { count, results: [{ id, title, summary, memory_type, level, importance, updated_at }] }.
- **get_memory_detail** — Load the full body of a specific memory by id.
USE WHEN: a search_memory_light candidate looks relevant and you need its full content / metadata.
DO NOT USE WHEN: you have not identified a specific memory id, or you are tempted to call this many times in a row.
LIMIT: call at most 3 times per user turn.
RETURNS: { found, memory? } where memory has { id, title, summary, content, memory_type, level, importance, source, metadata, created_at, updated_at }.
- **remember_decision** — Persist a durable technical decision (architecture choice, trade-off, accepted pattern, rejected alternative).
USE WHEN: the user confirms a decision that should outlive the current session.
DO NOT USE WHEN: the info is a transient fact/command (use remember_fact) or raw chat log.
IMPORTANCE: defaults to 0.8 — override only if the user signals otherwise.
RETURNS: { project_id, memory_id }.
- **remember_fact** — Persist a concise atomic memory: fact, command, gotcha, link, or convention.
USE WHEN: the user gives concrete reusable info (a command, env detail, integration note, rule).
DO NOT USE WHEN: the info is a major decision (use remember_decision) or a summary (use upsert_*_summary).
FACT TYPES: fact | command | gotcha | link | convention | decision (prefer remember_decision for 'decision').
RETURNS: { project_id, memory_id }.
- **upsert_project_summary** — Idempotently create or replace the structured project summary node.
USE WHEN: architecture, conventions, or key decisions changed enough that a fresh summary is worth storing.
DO NOT USE WHEN: the change is a single fact / decision (use remember_fact or remember_decision).
RETURNS: { project_id, summary_id }.
- **upsert_task_summary** — Idempotently create or replace the current task summary (progress, blockers, next steps).
USE WHEN: meaningful progress was made, a blocker appeared, or the plan changed and the next session must resume.
DO NOT USE WHEN: the update fits better as a single fact or decision.
RETURNS: { project_id, summary_id }.

## Claude Desktop Quick Installation
Install path detected from listing signals. Uses `npx` (confidence: high):

```json
"mcpServers": {
  "memory-mcp-lite": {
    "command": "npx",
    "args": ["memory-mcp-lite"],
    "env": {
      "MEMORY_DB_PATH": "",
      "MEMORY_DATA_DIR": "",
      "DATABASE_URL": "",
      "MEMORY_DB_AUTH_TOKEN": ""
    }
  }
}
```

**Requires environment variables:** `MEMORY_DB_PATH`, `MEMORY_DATA_DIR`, `DATABASE_URL`, `MEMORY_DB_AUTH_TOKEN` — the values above are empty placeholders; fill in real credentials before running (see the repository for what each one is for).

## Documentation

## What memory-mcp-lite does

The memory-mcp-lite MCP server gives AI coding assistants a durable store for information that should survive a conversation. It records architecture decisions and rejected approaches, project conventions, commands, environment notes, links, gotchas, and task progress. It does not save raw chat transcripts, replace client rules, use embeddings or vector search, or require a cloud service.

Memory is arranged as a hierarchy: global knowledge sits above projects, projects contain project summaries and tasks, and tasks can contain atomic records such as decisions, facts, commands, links, conventions, and gotchas. Optional graph-like relationships connect nodes with labels including `related_to`, `depends_on`, `affects`, `caused_by`, `supersedes`, and `references`.

## How it works

The server encourages a staged retrieval process. First, an agent can request global, project, or task summaries. If those summaries do not answer the question, `search_memory_light` returns compact candidates using SQLite FTS5 lexical search. The agent can then call `get_memory_detail` for the most relevant one to three results instead of loading every stored record into context.

Project identity is resolved from a normalized Git remote URL first, then the Git root path, and finally the normalized workspace path. This lets stored project context remain associated with a repository when its local directory changes, provided the identifying information remains available.

The implementation uses TypeScript and Node.js 20 or newer, with the MCP TypeScript SDK, Drizzle ORM, and libSQL. A closure table supports subtree traversal, while FTS5 and its triggers support lexical lookup.

## Setup and configuration

The memory-mcp-lite MCP server can be started through `npx memory-mcp-lite` from an MCP client's stdio configuration. The README gives configurations for Windsurf and Claude Desktop and says the same command pattern applies to other MCP-compatible clients. It can also be built from source with `npm install` and `npm run build`, then launched with Node against `dist/index.js`. During development, `tsx` can run the TypeScript entry point directly.

By default, data is stored at `~/.memory-mcp/memory.db`. Configuration supports these environment variables:

- `MEMORY_DB_PATH`: a database file path or `libsql://` / `file:` URL.
- `MEMORY_DATA_DIR`: a directory containing `memory.db`.
- `DATABASE_URL`: a backwards-compatible database setting.
- `MEMORY_DB_AUTH_TOKEN`: a bearer token for remote libSQL or Turso access.

The database schema is created or re-asserted when the server starts, including the FTS5 table and triggers. No separate manual schema step is required.

## Tools and capabilities

The nine MCP tools cover retrieval and writing:

- `get_global_summary`, `get_project_summary`, and `get_task_summary` retrieve context at their respective scopes.
- `search_memory_light` finds compact matching candidates.
- `get_memory_detail` returns the full content for a selected memory.
- `remember_decision` stores an architectural choice, trade-off, or rejected path.
- `remember_fact` stores facts such as commands, environment notes, links, gotchas, or conventions.
- `upsert_project_summary` updates project-level architecture and convention context.
- `upsert_task_summary` updates task progress, blockers, or plans.

Responses include a readable JSON block and `structuredContent` for programmatic clients. Tool descriptions and annotations help agents select among the tools.

## Limitations and notes

The memory-mcp-lite MCP server uses lexical FTS5 search rather than embeddings or semantic retrieval. It is intentionally focused on durable structured memory, not conversation history. Remote operation is supported through libSQL or Turso with an authentication token, but the default setup is local and disk-backed.

_Full upstream README: https://allmcps.com/mcp/memory-mcp-lite/readme_

