light-agent-memory-mcp-server

light-agent-memory-mcp-server

Provides persistent, searchable memory for AI agents across any MCP-compatible client, storing project context, user preferences, and session learnings locally in SQLite with tools to save, retrieve, search, and manage them.

Category
Visit Server

README

light-agent-memory-mcp-server

MCP server for persistent agent memory — projects, preferences, and session learnings stored in a local SQLite database.

Harness-agnostic. Works with any MCP-compatible client: opencode, Claude Desktop, Cursor, Windsurf, etc.

Install

npm install -g light-agent-memory-mcp-server

Or use directly with npx (no install needed):

npx light-agent-memory-mcp-server

Configure

Add to your MCP client's config:

opencode (~/.config/opencode/opencode.json):

{
  "mcp": {
    "memory": {
      "type": "local",
      "command": ["npx", "-y", "light-agent-memory-mcp-server"],
      "enabled": true
    }
  }
}

Claude Desktop (claude_desktop_config.json):

{
  "mcpServers": {
    "memory": {
      "command": "npx",
      "args": ["-y", "light-agent-memory-mcp-server"]
    }
  }
}

Cursor (.cursor/mcp.json):

{
  "mcpServers": {
    "memory": {
      "command": "npx",
      "args": ["-y", "light-agent-memory-mcp-server"]
    }
  }
}

Custom database path

npx light-agent-memory-mcp-server --db /path/to/custom.db

Tools

Project Memory

Tool Description
memory_project_save Save/update project context (tech stack, architecture, conventions)
memory_project_get Get project details by name
memory_project_list List all saved projects

Preference Memory

Tool Description
memory_pref_save Save/update a personal coding preference
memory_pref_get Get a preference by key
memory_pref_list List preferences (optionally filtered by category)

Learning Memory

Tool Description
memory_learning_save Record a session learning (solution, insight, bug note)
memory_learning_search Search learnings by keyword

Generic

Tool Description
memory_save Unified save (auto-routes by type)
memory_search Cross-type search by keyword
memory_delete Delete a memory by type and ID
memory_list List all memories with pagination and stats

Examples

Save a project:

memory_project_save({
  name: "my-app",
  path: "/home/user/projects/my-app",
  tech_stack: ["TypeScript", "React", "SQLite"],
  architecture: "Monorepo with pnpm workspaces, plugin-based architecture",
  conventions: "ESM-only, strict TypeScript, no comments in code"
})

Save a preference:

memory_pref_save({
  key: "language.typescript.style",
  value: "Always use ESM imports, strict mode, and prefer readonly types",
  category: "language"
})

Record a learning:

memory_learning_save({
  title: "Fix SQLite WAL mode deadlock",
  content: "When using WAL mode in SQLite, set busy_timeout to 5000ms to avoid SQLITE_BUSY errors under concurrent reads.",
  project_name: "my-app",
  tags: ["sqlite", "debugging", "concurrency"]
})

Search all memories:

memory_search({ query: "SQLite" })

Database

Data is stored in ~/.agent-memory/memory.db by default (SQLite via Node.js built-in node:sqlite). The database is created automatically on first run.

Schema

  • projectsid, name (unique), path, tech_stack (JSON), architecture, conventions, notes, timestamps
  • preferencesid, key (unique), value, category, timestamps
  • learningsid, title, content, project_name, tags (JSON), timestamps

Development

git clone https://github.com/AliYar-Khan/light-agent-memory-mcp-server.git
cd light-agent-memory-mcp-server
npm install
npm run build
npm run dev  # runs with tsx, no build step

License

MIT

Recommended Servers

playwright-mcp

playwright-mcp

A Model Context Protocol server that enables LLMs to interact with web pages through structured accessibility snapshots without requiring vision models or screenshots.

Official
Featured
TypeScript
Audiense Insights MCP Server

Audiense Insights MCP Server

Enables interaction with Audiense Insights accounts via the Model Context Protocol, facilitating the extraction and analysis of marketing insights and audience data including demographics, behavior, and influencer engagement.

Official
Featured
Local
TypeScript
Magic Component Platform (MCP)

Magic Component Platform (MCP)

An AI-powered tool that generates modern UI components from natural language descriptions, integrating with popular IDEs to streamline UI development workflow.

Official
Featured
Local
TypeScript
VeyraX MCP

VeyraX MCP

Single MCP tool to connect all your favorite tools: Gmail, Calendar and 40 more.

Official
Featured
Local
graphlit-mcp-server

graphlit-mcp-server

The Model Context Protocol (MCP) Server enables integration between MCP clients and the Graphlit service. Ingest anything from Slack to Gmail to podcast feeds, in addition to web crawling, into a Graphlit project - and then retrieve relevant contents from the MCP client.

Official
Featured
TypeScript
Kagi MCP Server

Kagi MCP Server

An MCP server that integrates Kagi search capabilities with Claude AI, enabling Claude to perform real-time web searches when answering questions that require up-to-date information.

Official
Featured
Python
Neon Database

Neon Database

MCP server for interacting with Neon Management API and databases

Official
Featured
Exa Search

Exa Search

A Model Context Protocol (MCP) server lets AI assistants like Claude use the Exa AI Search API for web searches. This setup allows AI models to get real-time web information in a safe and controlled way.

Official
Featured
Qdrant Server

Qdrant Server

This repository is an example of how to create a MCP server for Qdrant, a vector search engine.

Official
Featured
E2B

E2B

Using MCP to run code via e2b.

Official
Featured