Noureddine RAMDI / Mind: a structured persistent memory layer with 3-tier context for AI agents

Created Mon, 04 May 2026 10:23:01 +0000 Modified Sat, 23 May 2026 20:41:27 +0000

GabrielMartinMoran/mind

Mind tackles a real pain point in AI agent workflows: preserving context and memory reliably across sessions and compaction boundaries. Its standout architectural feature is a 3-tier memory model—hot, warm, and cold memory—that organizes agent context with checkpoint-based recovery. This design addresses the persistent context decay problem in a queryable, structured way.

What Mind is and its architecture

Mind is a local persistent memory layer tailored for AI agent workflows. Built with TypeScript and Bun, it uses SQLite as its persistent store, leveraging the FTS5 extension for full-text search capabilities. The project exposes its memory layer through multiple interfaces: a command-line interface (CLI), an MCP server for integration with compatible AI agents, an HTTP API, and a web UI.

The core architectural innovation lies in its 3-tier memory model:

  • T1 Hot memory: This is the immediate and most accessible memory layer, holding recent context and interactions.
  • T2 Warm memory: A middle tier that stores less recent information but still relatively fresh and quickly retrievable.
  • T3 Cold memory: Long-term storage for older data, archived but still queryable.

These tiers allow Mind to manage context decay systematically, preventing loss of relevant history while keeping the working set manageable.

Checkpoint-based recovery complements this design by enabling the system to resume from known good states, ensuring robustness across agent restarts or crashes. Additionally, Mind optionally supports semantic search powered by OpenAI embeddings, enhancing information retrieval beyond keyword matching.

Integration-wise, Mind supports multiple AI coding agents via the Model Context Protocol (MCP), including Claude Code, Cursor, Codex, Windsurf, Gemini CLI, and others. This broad compatibility makes it versatile in diverse AI development environments.

The web UI includes a Neural Map graph visualization per “space,” which provides a graphical representation of memory nodes and their relationships, with URL-driven client routing for smooth navigation.

The technical strengths and tradeoffs in Mind

Mind’s technical strength is how it structures persistent memory into tiers, addressing a fundamental challenge in AI agents: context and memory decay. By explicitly modeling hot, warm, and cold memory, it allows agents to maintain relevant context efficiently while offloading older data.

The use of SQLite with FTS5 is a pragmatic choice, balancing the need for a lightweight, embeddable database with full-text search capabilities. SQLite’s reliability and ubiquity mean Mind can run on various platforms with minimal dependencies.

One tradeoff is the potential complexity in managing the checkpoint and memory tiers correctly, especially as data volume grows. The repo’s checkpoint system mitigates this by allowing recovery to consistent states, but it requires careful operational understanding.

Semantic search integration via OpenAI embeddings offers a powerful retrieval mechanism, but it introduces external API dependencies and costs, which may limit offline or cost-sensitive deployments. The design keeps this optional, which is a good tradeoff.

Code quality appears solid, with a TypeScript/Bun stack that benefits from modern JavaScript tooling and type safety. The MCP server integration is a standout for enabling multiple AI agents to communicate over a common protocol, something not all AI memory layers provide.

The CLI and HTTP API offer flexible access routes, while the web UI’s Neural Map visualization adds a useful perspective on memory relationships. This multi-modal access improves developer experience.

Overall, Mind balances solid engineering with practical features for AI memory persistence, though it demands some initial learning curve around its tiered memory and checkpoint concepts.

Quick start

You can install Mind quickly and start using it right away. If you want agent setup later, jump to Agent setup.

curl -fsSL https://raw.githubusercontent.com/GabrielMartinMoran/mind/main/scripts/install.sh | bash

This installs Mind to user-local paths (no sudo):

  • app: ~/.local/share/mind
  • launcher: ~/.local/bin/mind

Then run:

mind help

Requirements

  • Bun 1.2+ (auto installed by the one-line installer if not present)

Install from source

git clone https://github.com/GabrielMartinMoran/mind.git
cd mind
bun install

Quick start

This is the fastest way to see what Mind feels like in practice.

Agent setup

Mind supports multiple agent integrations, but they are not all equally mature. Run mind setup without an agent name to see the current capability matrix, then configure the specific agent you want.

mind setup              # show capability matrix first
mind setup claude-code
mind setup opencode
mind setup cursor
mind setup codex
mind setup windsurf
mind setup gemini-cli
mind setup vscode
mind setup antigravity

Post-install configuration

Most configuration is optional. You only need extra setup if you want to change paths, ports, or enable semantic search.

1. Create your .env file:

cp .env.example .env

Verdict

Mind is a well-engineered local memory layer for AI agents that addresses a real-world problem: preserving and structuring agent context over time with minimal friction. Its 3-tier memory model combined with checkpoint recovery offers a clear pattern for managing context decay, which many AI workflows struggle with.

The project is most relevant for developers building or experimenting with AI coding agents who need persistent, queryable memory that integrates with multiple agents via MCP. However, its reliance on SQLite and OpenAI API for semantic search means it may not fit all edge use cases, especially fully offline or extremely large-scale deployments.

Its multi-interface design (CLI, MCP server, HTTP API, UI) and thoughtful architecture make it a good candidate for production or research projects where persistent agent memory is a blocker.

If you’re building AI tools that require structured long-term memory and want to avoid ad hoc context handling, Mind is worth exploring with a realistic expectation of its operational tradeoffs.


→ GitHub Repo: GabrielMartinMoran/mind ⭐ 98 · TypeScript