Skip to main content
Glama
MindGate MCP
by aaserag1

๐Ÿง  MindGate MCP (v1.1.0) โ€” ุจูˆุงุจุฉ ุงู„ุนู‚ู„

CI License: MIT Security: Node2Shell Hardened Version: 1.1.0

Security-Hardened Persistent Cognitive Memory & Context Gateway for AI Agents (Model Context Protocol).

๐Ÿ‡ช๐Ÿ‡ฌ ุงู‚ุฑุฃ ุงู„ุชูˆุซูŠู‚ ุจุงู„ู„ุบุฉ ุงู„ุนุฑุจูŠุฉ


๐Ÿ’ก Why MindGate MCP?

AI coding and workflow agents (Antigravity, Cursor, Claude Desktop, Windsurf, Cline) suffer from two critical limitations:

  1. Cross-Session Context Amnesia: Every new chat starts from zeroโ€”forgetting architectural decisions, debugging root causes, coding conventions, and session handoffs.

  2. Prompt-to-Shell (Node2Shell) & Secret Leakage Risks: Unsanitized MCP memory servers can store leaked API keys in plaintext or ingest poisoned instructions that trick agents into executing destructive shell commands.

MindGate MCP solves both problems in a single, zero-cloud local server:

  • ๐Ÿ—„๏ธ Blazing-Fast Local SQLite + FTS5 BM25 Search: Instant full-text retrieval of architectural decisions, bugfixes, conventions, preferences, and session handoffs.

  • ๐Ÿ”„ Auto-Compiled Workspace Rules (AGENTS.md / .cursorrules / CLAUDE.md) โ€” New in v1.1.0: Automatically compiles your stored decisions, conventions, and bugfixes into a structured rules file so any AI agent immediately inherits project context.

  • โœ๏ธ In-Place Memory Updates & Portable JSON Snapshots โ€” New in v1.1.0: Update evolving architectural decisions in place (update_memory) while keeping FTS5 indexes in sync, and export full JSON backups (export_memory_snapshot).

  • ๐Ÿ›ก๏ธ Built-in Node2Shell Security Guard: Bi-directional inspection that blocks command-injection payloads (curl | bash, reverse shells, child_process.exec), detects prompt injection attempts, and automatically redacts secrets (OpenAI, GitHub, AWS, JWT, Private Keys) before they touch disk.


Related MCP server: Sugar Memory

๐Ÿ› ๏ธ MCP Tools Included (10 Tools)

Tool Name

Description

store_memory

Store a persistent memory item with automatic secret redaction and Node2Shell screening

update_memory

[New in v1.1] Update an existing memory in-place by ID while syncing FTS5 search indexes

recall_memory

Search and rank stored memories using SQLite FTS5 BM25 full-text search + project/category filters

delete_memory

Remove an obsolete memory entry by its ID

save_session_handoff

Save a structured session handoff summary (completed tasks, blockers, next steps)

get_project_context

One-call retrieval of top project memories, recent session handoffs, and user preferences

sync_workspace_rules

[New in v1.1] Auto-generate AGENTS.md, .cursorrules, or CLAUDE.md from stored project memories

export_memory_snapshot

[New in v1.1] Export a portable JSON snapshot of memories, session handoffs, and preferences

set_preference

Save or update a persistent global developer preference (key/value)

security_audit_text

Audit any text or command snippet against Node2Shell and secret-leak rules


๐Ÿ“ฆ MCP Resources & Prompts

Resources

  • mindgate://stats โ€” Live JSON telemetry of total memories, sessions, preferences, and category breakdown.

  • mindgate://security/policy โ€” Active Node2Shell security policy & protection status.

  • mindgate://rules/agents-md โ€” [New in v1.1] Live auto-compiled AGENTS.md rules preview from your stored memories.

Prompts

  • bootstrap_session โ€” Ready-to-use prompt that instructs the AI agent to load full project context at session start.

  • handoff_session โ€” Ready-to-use prompt that summarizes work and stores a clean handoff before closing.


๐Ÿš€ Quick Start

Option 1: Zero-Install via npx (once published to npm)

npx -y mindgate-mcp --init

Option 2: Build from Source (Windows / macOS / Linux)

git clone https://github.com/aaserag1/mindgate-mcp.git
cd mindgate-mcp
npm install
npm run build

# Print ready-to-paste MCP client configuration
npm run init-config

Configure in Antigravity / Cursor / Claude Desktop (Windows Example)

{
  "mcpServers": {
    "mindgate": {
      "command": "node",
      "args": ["C:\\path\\to\\mindgate-mcp\\dist\\index.js"],
      "env": {
        "MINDGATE_DB_DIR": "C:\\Users\\YOUR_USER\\.mindgate-mcp"
      }
    }
  }
}

Configure via npx (Cross-Platform 1-Liner)

{
  "mcpServers": {
    "mindgate": {
      "command": "npx",
      "args": ["-y", "mindgate-mcp"]
    }
  }
}

๐Ÿงช Testing & Verification

npm run typecheck
npm test

๐Ÿ“„ License

Released under the MIT License.

Related MCP Connectors

Related MCP Servers

  • F
    license
    Not graded
    quality
    A
    maintenance
    Gives AI coding agents persistent, local-first memory so they can store, semantically search, and recall decisions, preferences, error patterns, and cross-project guidelines directly during a session. It also optionally queues tasks for autonomous execution against that same memory.
    -
  • F
    license
    Not graded
    quality
    A
    maintenance
    Provides AI coding agents with a local-first persistent memory layer they can read and write during sessions, storing decisions, preferences, error patterns, and research per project or globally. Enables semantic and keyword search, formatted context recall, and cross-project guideline surfacing without API keys or cloud storage.
    -
  • F
    license
    Not graded
    quality
    A
    maintenance
    Gives AI coding agents a local-first persistent memory they can read and write directly during sessions, storing decisions, preferences, error patterns, and guidelines in per-project and global SQLite stores. Enables semantic and keyword retrieval of relevant context across sessions so agents start work already knowing a codebase's conventions and history.
    -
  • F
    license
    Not graded
    quality
    A
    maintenance
    Enables AI coding agents to store and retrieve persistent project and cross-project memories via semantic search, so decisions, preferences, error patterns, and guidelines survive across sessions. Optionally supports autonomous task execution built on the same local-first knowledge store.
    -