Engram logo

Engram

OrganizationPopular
Gentleman-Programming

Persistent memory system for AI coding agents. Agent-agnostic Go binary with SQLite + FTS5, MCP server, HTTP API, CLI, and TUI.

PublisherGentleman-Programming
Repositoryengram
LanguageGo
Forks
718
Stars
7K
Available tools
0
Transport typestdio
Categories
LicenseMIT
Links
  • Connect tools to AI workflows

    Engram exposes MCP capabilities that can be used by compatible AI clients and agents.

  • 0 available tools

    Browse the callable actions below, including names and descriptions when provided by the server.

  • Ready-to-copy setup

    Use the installation snippets to configure this server in your preferred MCP client.

  • Open source signals

    7K stars and 718 forks from the linked repository.


engram /ˈen.ɡræm/ — neuroscience: the physical trace of a memory in the brain.

Your AI coding agent forgets everything when the session ends. Engram gives it a brain.

A Go binary with SQLite + FTS5 full-text search, exposed through CLI, HTTP API, MCP, and an interactive TUI. It works with any MCP-compatible agent, including Claude Code, OpenCode, Gemini CLI, Codex, VS Code (Copilot), Antigravity, Cursor, and Windsurf.

No Node.js, Python, or Docker is required: one binary, one SQLite file.

Agent (Claude Code / OpenCode / Gemini CLI / Codex / VS Code / Antigravity / ...)
    ↓ MCP stdio
Engram (single Go binary)
    ↓
SQLite + FTS5 (~/.engram/engram.db)

For agents

Treat Engram as a curated project memory, not a transcript sink. Use this operating contract throughout the session.

  1. Orient before writing. Start with mem_current_project to confirm the resolved project and its source. At the start of related work, use mem_context and mem_search to recover the relevant history.
  2. Search before repeating. Before revisiting a decision, bug, convention, or request that may already be known, search with focused terms. Search results are previews, not the complete record.
  3. Retrieve progressively. Use mem_search for candidates, mem_timeline when surrounding session context matters, and mem_get_observation before relying on a full observation.
  4. Save significant knowledge deliberately. Save completed bug fixes, decisions, discoveries, configuration changes, patterns, and durable user constraints with mem_save. Do not capture raw tool output or every conversational turn.
  5. Keep evolving knowledge stable. Give an evolving topic a stable topic_key such as architecture/auth-model; reuse it to update that topic rather than creating competing memories. Use mem_suggest_topic_key when the key is unclear.
  6. Leave a handoff. Before ending a session, save a mem_session_summary with the goal, instructions, discoveries, accomplished work, next steps, and relevant files.
  7. Recover after compaction. Persist the compacted handoff with mem_session_summary first. Then call mem_context to recover recent session history before continuing.

A useful memory is structured

markdown
**What**: Added retry-safe upload handling.
**Why**: Retries could create duplicate records.
**Where**: internal/upload/handler.go
**Learned**: Reuse the request id as the idempotency key.

Use a short, searchable title and a fitting type with that content. The full Memory Protocol defines the durable-save rules and session-summary shape.

Choose MCP tools by intent

Tool availability can vary by MCP profile. Start with the intent, then use your client's tool discovery mechanism (such as ToolSearch) only when a deferred tool is needed.

IntentStart with
Confirm the project and recover recent workmem_current_project, mem_context
Find prior knowledge without repeating workmem_search
Inspect a result in enough detailmem_timeline, mem_get_observation
Save or refine durable knowledgemem_save, mem_update, mem_suggest_topic_key
Preserve the user's requestmem_save_prompt
Hand off or close a sessionmem_session_summary, mem_session_start, mem_session_end
Review stale knowledge or memory relationshipsmem_review, mem_judge, mem_compare
Diagnose project or store statemem_doctor

For parameters and the complete, current tool reference, see the full documentation.

Quick start

Install

For production use and security support, install the latest stable release from GitHub Releases. Release candidates are prerelease validation and feedback builds; choose one only when you accept prerelease risk. See the Release Policy before upgrading.

Homebrew remains on the stable v1.20.0 line:

bash
brew install gentleman-programming/tap/engram

For Windows, Linux, source builds, and all installation methods, see Installation.

Set up your agent

Run the setup command for the agent you use, then restart that agent. engram setup writes the applicable MCP and integration configuration; it does not require you to start a server for the usual stdio-only setup.

AgentSetup
Claude Codeclaude plugin marketplace add Gentleman-Programming/engram && claude plugin install engram
Piengram setup pi
OpenCodeengram setup opencode
Gemini CLIengram setup gemini-cli
Codexengram setup codex
Antigravity CLIengram setup antigravity-cli
Windsurfengram setup windsurf
Qwen Codeengram setup qwen
Kiroengram setup kiro
Cursorengram setup cursor
VS Code (Copilot)engram setup vscode-copilot
Kilo Codeengram setup kilocode
Kimi Codeengram setup kimi
CommandCodeengram setup commandcode
Another MCP-compatible agentManual MCP setup

See Agent Setup for per-agent configuration, plugin behavior, manual MCP setup, compaction resilience, and troubleshooting. Pi users can also find the package at gentle-engram.

Local first, portable when needed

Engram keeps memory local by default. The local SQLite database is authoritative; Git Sync exports portable compressed chunks for sharing across machines, and Engram Cloud is optional, project-scoped replication/shared access with browser visibility.

NeedStart here
Local memory and the runtime modelArchitecture
Share memory with GitGit Sync reference
Use optional Cloud replicationEngram Cloud
Diagnose or recover Cloud operationsCloud troubleshooting

For an existing local database, use the guided upgrade sequence. If the dry run reports changes, apply them before bootstrap; otherwise continue directly to bootstrap.

bash
engram cloud upgrade doctor --project <project>
engram cloud upgrade repair --project <project> --dry-run
engram cloud upgrade repair --project <project> --apply # only when the dry run reports changes
engram cloud upgrade bootstrap --project <project>
engram cloud upgrade status --project <project>

See the Cloud upgrade reference for apply, rollback, and recovery details.

Project-aware reads

Project-aware reads use the canonical current project when no selector is supplied: an explicit project, then ENGRAM_PROJECT, then cwd detection. Use --all in the CLI or all_projects=true in HTTP for an intentional global read; do not combine either with an explicit project. engram context retains its positional project as an alias for --project. GET /sync/status supports one resolved project and rejects all_projects=true because its provider cannot aggregate status.

Terminal UI

bash
engram tui

Navigate with j/k, use Enter to drill in, c to copy content to the clipboard, / to search, and Esc to go back. The TUI uses the Catppuccin Mocha theme.

Documentation

DocDescription
InstallationPlatform support and all installation methods
Release PolicyStable, RC, security-support, upgrade, and rollback guidance
Agent SetupPer-agent configuration and compaction resilience
Intended UsageThe human mental model for using Engram
ArchitectureMemory model, tool behavior, and project structure
Codebase GuideRepository structure, flows, and implementation landmarks
PluginsOpenCode and Claude Code plugin details
Team UsageShared-memory conventions
Engram CloudCloud quickstart, deployment, and technical links
DoctorOperational diagnosis and repair workflows
Binary self-testingIsolated reliability and performance checks for released binaries
Beta TestingIsolated beta testing flows and cleanup guidance
ComparisonEngram compared with claude-mem
Obsidian BrainExport memories as an Obsidian knowledge graph (beta)
Full DocsComplete CLI, environment, API, and operational reference

Dashboard contributors: if you modify .templ files in internal/cloud/dashboard/, run make templ to regenerate before committing. See Dashboard templ regeneration.

Contributing

Every change starts with an approved issue. See Contributing for the issue-first workflow, labels, review requirements, and contributor standards.

Trademark notice: The Engram names and logos are trademarks of Alan Buscaglia. The MIT License applies to the code; it does not permit implying endorsement or official affiliation. See TRADEMARKS.md.

License

MIT


Inspired by claude-mem — but agent-agnostic, simpler, and built different.

Contributors

Installation

TypingMind
{
  "mcpServers": {
    "gentleman-programming-engram": {
      "command": "engram",
      "args": [
        "mcp"
      ]
    }
  }
}

Use Engram MCP with multiple AI models

TypingMind connects MCP tools at the workspace level, so once Engram is connected, you can use it with different AI models in TypingMind instead of setting it up separately for each model. This MCP runs locally through the TypingMind MCP connector on your device.

Setup guide to use the local connector

Use this when the MCP server needs access to local files, apps, or private resources on your computer.

1

Open the MCP settings

In TypingMind, go to Settings, Advanced Settings, then Model Context Protocol and choose Setup Connector.

  1. Open TypingMind in your browser.
  2. Click the Settings icon.
  3. Go to Advanced Settings.
  4. Open the Model Context Protocol section.
  5. Click Setup Connector and choose This Device.
TypingMind MCP connector setup screen with This Device selected
2

Run the connector command

Choose This Device, copy the command from TypingMind, and run it in Terminal. Keep the process running while you use MCP.

  1. Copy the setup command shown by TypingMind.
  2. Open Terminal on macOS or Windows Terminal on Windows.
  3. Paste and run the command.
  4. Approve the package install if Terminal asks you to proceed.
  5. Keep the Terminal window running while using MCP tools.
3

Add Engram as a server

When the connector status is Ready, click Edit Servers and paste the MCP server configuration.

  1. Wait until the connector status shows Ready.
  2. Click Edit Servers.
  3. Paste the Engram MCP server configuration.
  4. Save the server list.
  5. Refresh if you want to confirm the connector is still ready.
TypingMind MCP settings showing active server and Edit Servers button
{
  "mcpServers": {
    "gentleman-programming-engram": {
      "command": "npx",
      "args": [
        "-y",
        "<mcp-server-package>"
      ]
    }
  }
}
4

Use it across models

Save the server list, open Plugins, enable the Engram MCP tools, then select any supported AI model in TypingMind and use the tools in chat or assign them to an AI agent.

  1. Open the Plugins page in TypingMind.
  2. Enable the Engram MCP tools.
  3. Start a chat and choose the AI model you want to use.
  4. Use the MCP tools in chat or assign them to an AI agent.
  5. Switch to another AI model whenever needed without reconnecting MCP.
TypingMind chat using enabled MCP tools with a selected AI model
Can you use Engram to help me with this task?
Engram
Sure. I read it.
Here is what I found using Engram.

Frequently asked questions

What is the Engram MCP server used for?

Engram is an MCP server that lets compatible AI clients connect to external tools and context. In TypingMind, you can add this MCP server once and make its tools available in your AI workspace.

Can I use Engram MCP with multiple AI models in TypingMind?

Yes. TypingMind connects MCP tools at the workspace level, so you can use Engram with different AI models such as Claude, ChatGPT, Gemini, or other models you have configured in TypingMind without setting up the MCP server separately for each model.

Why use Engram MCP with TypingMind?

TypingMind is one of the best frontends for LLM chat because it brings multiple AI models, prompts, plugins, AI agents, API keys, and MCP tools into one workspace. With Engram connected, you can use its MCP tools across your preferred models while keeping your chat workflow organized in TypingMind.

How do I connect Engram MCP to TypingMind?

Engram runs through the TypingMind local MCP connector. This is best when the MCP server needs access to local files, desktop apps, command-line tools, or private resources on your computer.

What tools does Engram MCP provide in TypingMind?

Engram exposes MCP capabilities that can be enabled from the TypingMind Plugins page and used in chat or assigned to AI agents.

Do I need to share my API keys with TypingMind to use Engram MCP?

No. TypingMind is local-first and lets you keep your model providers, API keys, prompts, and MCP configuration under your control. If Engram requires authentication, add the required headers, OAuth settings, or local configuration for that MCP server when you create the connection.

Related MCP Servers

View all

Set up your own AI workspace now

Get notified about new features and future giveaways by subscribing to our newsletter 👇