Skip to main content
Glama

MCP Memory Server

Memoria persistente de agente para Blockbrain (o cualquier cliente MCP) mediante archivos Markdown + búsqueda de texto completo SQLite FTS5.

¿Por qué?

Los agentes de Blockbrain no conservan la memoria entre sesiones. Cada conversación empieza desde cero. Este servidor MCP lo soluciona: el agente puede guardar lo que ha aprendido y recuperarlo la próxima vez.

Cómo funciona:

  • El agente resuelve un problema → llama a memory_save con la solución

  • El agente inicia una nueva tarea → llama a memory_recall para comprobar si hay problemas similares en el pasado

  • Todos los recuerdos se almacenan como archivos Markdown legibles + se indexan en SQLite para una búsqueda rápida

Related MCP server: universal-memory-mcp

Herramientas

Herramienta

Descripción

memory_save

Almacena una entrada de memoria (tema, título, contenido)

memory_recall

Busca recuerdos por palabra clave/tema (FTS5)

memory_list_topics

Lista todos los temas almacenados con recuento de entradas

memory_delete

Elimina una entrada de memoria por ID

Inicio rápido (Docker)

# 1. Clone
git clone https://github.com/lanlibbi/mcp-memory-server.git
cd mcp-memory-server

# 2. Configure
cp .env.example .env
# Edit .env — set MEMORY_API_KEY!
# Generate a key: openssl rand -hex 32

# 3. Run
docker compose up -d

# 4. Verify
curl http://localhost:8080/health

Integración con Blockbrain

  1. Exponer el servidor públicamente — Blockbrain necesita una URL HTTPS:

    • Opción A: Cloudflare Tunnel (cloudflared tunnel --url http://localhost:8080)

    • Opción B: Cualquier proxy inverso (nginx, Caddy, Traefik) con TLS

    • Opción C: ngrok para pruebas (ngrok http 8080)

  2. Registrarlo en Blockbrain:

    • Ve a Admin → Agents → MCP Servers

    • Haz clic en "+ Add MCP Server"

    • Rellena los campos:

      • Nombre: Memory Server

      • URL del servidor: https://<your-public-url>/sse

      • Transporte: SSE

      • Autenticación: API Key

      • API Key: (el valor de tu .env)

    • Guarda y activa

  3. Asignarlo a un agente y añade instrucciones al prompt del sistema del agente:

    Before starting a new task, call memory_recall with keywords related to the task.
    After completing a task or learning something new, call memory_save with:
    - topic: a category for the task (e.g. "contract-review", "supplier-issue")
    - title: a short descriptive title
    - content: what was the problem, what was the solution, what was learned

Configuración

Toda la configuración mediante variables de entorno:

Variable

Valor por defecto

Descripción

MEMORY_API_KEY

(vacío = sin autenticación)

Clave API para la cabecera X-API-Key

MEMORY_DATA_DIR

/data/memories

Dónde se almacenan los archivos Markdown

MEMORY_PORT

8080

Puerto HTTP

MEMORY_MAX_RESULTS

10

Máximo de resultados por búsqueda

LOG_LEVEL

info

debug, info, warning, error

Almacenamiento

Los recuerdos se almacenan como archivos Markdown con frontmatter YAML:

/data/memories/
├── contract-review/
│   ├── nda-standard-clauses.md
│   └── liability-clause-fix.md
├── supplier-issue/
│   └── delayed-delivery-workaround.md
└── memory.db          ← SQLite FTS5 index

Cada archivo tiene este aspecto:

---
id: a1b2c3d4e5f67890
topic: contract-review
title: NDA Standard Clauses
created_at: 2026-08-20T15:00:00Z
updated_at: 2026-08-20T15:00:00Z
---

# NDA Standard Clauses

The standard NDA should always include...

Puedes navegar, editar o eliminar recuerdos directamente: son solo archivos Markdown. El índice SQLite se mantiene sincronizado automáticamente.

Desarrollo local (sin Docker)

python -m venv .venv
source .venv/bin/activate
pip install -e ".[dev]"
export MEMORY_API_KEY=test-key
export MEMORY_DATA_DIR=./data/memories
python -m uvicorn src.server:app --host 0.0.0.0 --port 8080

Endpoints de la API

Endpoint

Método

Descripción

/health

GET

Comprobación de salud (sin autenticación requerida)

/sse

GET

Endpoint SSE para la conexión del cliente MCP

/messages/

POST

Endpoint de mensajes MCP (usado por el transporte SSE)

Stack tecnológico

  • Python 3.12 + MCP SDK

  • Starlette + Uvicorn para HTTP/SSE

  • SQLite FTS5 para búsqueda de texto completo (cero dependencias externas)

  • Markdown para almacenamiento legible por humanos

Licencia

MIT

A
license - permissive license
Not graded
quality - not tested
C
maintenance

Maintenance

Maintainers
Response time
Release cycle
Releases (12mo)
Commit activity

Resources

Unclaimed servers have limited discoverability.

Looking for Admin?

If you are the server author, to access and configure the admin panel.

Related MCP Servers

  • A
    license
    Not graded
    quality
    D
    maintenance
    MCP server providing persistent memory management for AI agents using SQLite and FTS5, enabling storage, full-text search, and recall of memories with namespace isolation.
    1
    MIT
  • A
    license
    Not graded
    quality
    B
    maintenance
    Persistent memory MCP server that stores and retrieves memories in Markdown files, enabling shared context across multiple AI agents with hybrid search and deduplication.
    MIT
  • A
    license
    A
    quality
    B
    maintenance
    MCP server for persistent, cross-session, local-first memory for AI agents, storing memories as Markdown files with SQLite indexing for hybrid search.
    24
    Apache 2.0

View all related MCP servers

Related MCP Connectors

View all MCP Connectors

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/lanlibbi/mcp-memory-server'

If you have feedback or need assistance with the MCP directory API, please join our Discord server