{"id":981,"date":"2026-09-08T00:18:34","date_gmt":"2026-09-08T03:18:34","guid":{"rendered":"https:\/\/www.linuxpro.com.br\/2026\/09\/alternativas-claude-mem-go-rust-c\/"},"modified":"2026-10-15T08:44:21","modified_gmt":"2026-10-15T11:44:21","slug":"alternativas-claude-mem-go-rust-c","status":"publish","type":"post","link":"https:\/\/www.linuxpro.com.br\/en\/2026\/09\/alternativas-claude-mem-go-rust-c\/","title":{"rendered":"Claude-Mem alternatives in Go, Rust, and C"},"content":{"rendered":"<p><img loading=\"lazy\" decoding=\"async\" alt=\"Mascote do LinuxPro encaixando um cartucho de mem\u00f3ria no SQLite, com o gopher do Go, o Ferris e o cubo do C\" src=\"\/wp-content\/uploads\/2026\/09\/alternativas-claude-mem-go-rust-c-v3.webp\" width=\"1486\" height=\"856\" \/><\/p>\n<p class=\"translation-block\">The terminal agent is great until the session ends. In the next one, it rediscovers the same bug, rereads the same README, and asks again if the API uses JWT. <a href=\"https:\/\/github.com\/thedotmack\/claude-mem\">claude-mem<\/a> solves this \u2014 it captures what the agent did, compresses it, and returns the right chunk at SessionStart. Only it's TypeScript, Node, Bun, and a separate worker. If your machine already runs on a single binary in <a href=\"\/en\/2026\/09\/a-historia-da-linguagem-go\/\">Go<\/a>, <a href=\"\/en\/2026\/09\/a-historia-da-linguagem-rust\/\">Rust<\/a> or C, you can have the same idea without the JS stack.<\/p>\n<p><!-- more --><\/p>\n<div style=\"background:#eff6ff;border-left:4px solid #2563eb;padding:.8em 1em;margin:1em 0\"><strong>Update \u2014 15\/10\/2026:<\/strong> we included Deja Vu, which searches existing histories from different agents. The section on Deja Vu considers the stable release 0.22.1. The URL, original date, and cover of this article have been preserved.<\/div>\n<p>This post maps the native alternatives that actually exist today: session memory (decisions, bugs, conventions), retroactive search across agent histories, and code memory (who calls whom). They are not clones. Some speak MCP over stdio, others use HTTP, install hooks, or become SQLite extensions. The map of agents in the terminal continues in <a href=\"\/en\/2026\/09\/assistentes-de-ia-no-terminal-linux\/\">AI assistants on the Linux terminal<\/a>; the fit of claude-mem into the vibe coding flow is at <a href=\"\/en\/2026\/09\/vibe-coding-linux-skills-ia-cli\/\">Vibe coding on Linux<\/a>.<\/p>\n<h2>What Claude-Mem does \u2014 and what the alternatives try to copy<\/h2>\n<p>The reference repository is <a href=\"https:\/\/github.com\/thedotmack\/claude-mem\">thedotmack\/claude-mem<\/a>, presented by the project as Claude-Mem, under the Apache 2.0 license. The point of comparison is the memory flow, not just the implementation language:<\/p>\n<ul>\n<li>lifecycle hooks (<code data-no-translation=\"\">SessionStart<\/code>, <code data-no-translation=\"\">PostToolUse<\/code>, <code data-no-translation=\"\">PreCompact<\/code>, <code data-no-translation=\"\">Stop<\/code>);<\/li>\n<li>SQLite + search (FTS5 and vector);<\/li>\n<li>MCP for the agent to query memory on demand;<\/li>\n<li>context injection at the start of the session, without you asking \u201cremember what we agreed on\u201d.<\/li>\n<\/ul>\n<p>Whoever switches the stack ultimately wants these capabilities with fewer pieces to operate. Storage can be SQLite, a wiki, or a custom index. Embeddings can use <a href=\"\/en\/2026\/09\/rodando-ia-local-no-linux-com-ollama\/\">Ollama<\/a> or another endpoint; checking the destination is essential. Even with local search, snippets retrieved by a cloud agent may end up in the context sent to the provider.<\/p>\n<h2>Quick table<\/h2>\n<table>\n<thead>\n<tr>\n<th>Project<\/th>\n<th>Language<\/th>\n<th>Storage<\/th>\n<th>MCP<\/th>\n<th>Profile<\/th>\n<\/tr>\n<\/thead>\n<tbody>\n<tr>\n<td><a href=\"https:\/\/github.com\/vshulcz\/deja-vu\">Deja Vu<\/a><\/td>\n<td>Go<\/td>\n<td>Own binary index; optional embeddings<\/td>\n<td>stdio<\/td>\n<td>Retroactive search across multiple agent histories, CLI\/TUI and handoff<\/td>\n<\/tr>\n<tr>\n<td><a href=\"https:\/\/github.com\/kyungw00k\/mnemo\">mnemo<\/a><\/td>\n<td>Go<\/td>\n<td>SQLite (pgvector optional)<\/td>\n<td>stdio \/ SSE<\/td>\n<td>The closest equivalent to Claude-Mem in Go<\/td>\n<\/tr>\n<tr>\n<td><a href=\"https:\/\/github.com\/Gentleman-Programming\/engram\">Engram<\/a><\/td>\n<td>Go<\/td>\n<td>SQLite + FTS5<\/td>\n<td>yes<\/td>\n<td>Multi-agent memory, CLI, TUI, HTTP<\/td>\n<\/tr>\n<tr>\n<td><a href=\"https:\/\/github.com\/srfrog\/goldie-mcp\">Goldie<\/a><\/td>\n<td>Go<\/td>\n<td>SQLite + vector<\/td>\n<td>yes<\/td>\n<td>Shared pool between agents<\/td>\n<\/tr>\n<tr>\n<td><a href=\"https:\/\/github.com\/akitaonrails\/ai-memory\">ai-memory<\/a><\/td>\n<td>Rust<\/td>\n<td>Wiki Markdown + SQLite<\/td>\n<td>yes (HTTP)<\/td>\n<td>Local server, hooks and handoff between agents<\/td>\n<\/tr>\n<tr>\n<td><a href=\"https:\/\/github.com\/asanabrial\/leteo\">Leteo<\/a><\/td>\n<td>Rust<\/td>\n<td>SQLite<\/td>\n<td>22 tools<\/td>\n<td>Single binary + hooks, derived from Engram<\/td>\n<\/tr>\n<tr>\n<td><a href=\"https:\/\/github.com\/zircote\/subcog\">Subcog<\/a><\/td>\n<td>Rust<\/td>\n<td>SQLite + FTS5 + HNSW<\/td>\n<td>yes<\/td>\n<td>Hybrid search + knowledge graph<\/td>\n<\/tr>\n<tr>\n<td><a href=\"https:\/\/github.com\/corporatepiyush\/mcp-memory\">mcp-memory<\/a><\/td>\n<td>Rust<\/td>\n<td>SQLite<\/td>\n<td>yes<\/td>\n<td>Graph + vector + code indexing<\/td>\n<\/tr>\n<tr>\n<td><a href=\"https:\/\/github.com\/DioNanos\/mcp-memory-rs\">mcp-memory-rs<\/a><\/td>\n<td>Rust<\/td>\n<td>JSON + SQLite FTS5<\/td>\n<td>yes<\/td>\n<td>Local-first, versioned, no embedding<\/td>\n<\/tr>\n<tr>\n<td><a href=\"https:\/\/github.com\/tokarix\/memory-server\">memory-server<\/a><\/td>\n<td>Rust<\/td>\n<td>PostgreSQL + pgvector<\/td>\n<td>yes<\/td>\n<td>Centralized service + Ollama<\/td>\n<\/tr>\n<tr>\n<td><a href=\"https:\/\/github.com\/sqliteai\/sqlite-memory\">sqlite-memory<\/a><\/td>\n<td>C<\/td>\n<td>SQLite<\/td>\n<td>via sqlmem \/ sqlite-mcp<\/td>\n<td>Extension, Markdown + hybrid search<\/td>\n<\/tr>\n<tr>\n<td><a href=\"https:\/\/github.com\/DeusData\/codebase-memory-mcp\">codebase-memory-mcp<\/a><\/td>\n<td>C<\/td>\n<td>SQLite<\/td>\n<td>yes<\/td>\n<td>Code graph, not conversation graph<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<h2>Go: four binaries, different ways to remember<\/h2>\n<h3>Deja Vu \u2014 the histories you already have become memory<\/h3>\n<p><a href=\"https:\/\/github.com\/vshulcz\/deja-vu\">Deja Vu<\/a> (MIT, Go) part of an important difference: Claude Code, Codex, Cursor, and other agents already leave histories on disk. The command <code data-no-translation=\"\">deja<\/code> reads these sources and enables retroactive search, even for sessions prior to installation. You don't have to wait for new hooks to accumulate weeks of work before getting started.<\/p>\n<p>The default index, <code data-no-translation=\"\">~\/.cache\/deja\/index.db<\/code>, is a <strong>directory of proprietary binary files, not a SQLite database<\/strong>. There is lexical search, filters, CLI, TUI, MCP server over stdio, and optional automatic integration. Sources that store sessions in SQLite are read using the local executable <code data-no-translation=\"\">sqlite3<\/code>; the fact that the main program is a Go binary doesn't eliminate this dependency for all agents.<\/p>\n<figure><img decoding=\"async\" src=\"\/wp-content\/uploads\/2026\/10\/deja-vu-local-memory-flow.webp\" alt=\"Arquitetura do Deja Vu: hist\u00f3ricos locais dos agentes, sanitiza\u00e7\u00e3o, \u00edndice bin\u00e1rio e recupera\u00e7\u00e3o por CLI, TUI, MCP e hooks opcionais.\" width=\"1200\" height=\"770\" loading=\"lazy\" \/><figcaption>Deja Vu retrieves the past that's already saved; automatic integration is a separate step.<\/figcaption><\/figure>\n<pre data-no-translation=\"\"><code class=\"language-bash\" data-no-translation=\"\"># Instalador oficial: baixe e inspecione antes de executar.\n# Esta URL fixa o script; ele baixa a release est\u00e1vel mais recente.\nmkdir -p \"$HOME\/.cache\/deja-installer\"\ncurl -fsSL \\\n  https:\/\/raw.githubusercontent.com\/vshulcz\/deja-vu\/v0.22.1\/install.sh \\\n  -o \"$HOME\/.cache\/deja-installer\/install.sh\"\nless \"$HOME\/.cache\/deja-installer\/install.sh\"\nsh \"$HOME\/.cache\/deja-installer\/install.sh\"\nexport PATH=\"$HOME\/.local\/bin:$PATH\"\n\ndeja index\ndeja search \"connection pool exhausted\"\ndeja doctor\n\n# Opcional: ap\u00f3s backup das configura\u00e7\u00f5es, integre somente estes clientes.\ndeja install claude-code codex<\/code><\/pre>\n<p>For those who already have a compatible Go, <code data-no-translation=\"\">go install github.com\/vshulcz\/deja-vu\/cmd\/deja@v0.22.1<\/code> pins the build tag; the module declares Go 1.25. <code data-no-translation=\"\">deja install --auto<\/code> it is the broad path to configure detected agents with their automatic hooks\/plugins. It is not mandatory: starting only with the CLI allows you to evaluate the search without changing existing integrations.<\/p>\n<p>Useful features: <code data-no-translation=\"\">deja ctx<\/code> prepares context, <code data-no-translation=\"\">deja blame<\/code> finds sessions related to files, <code data-no-translation=\"\">deja how<\/code> shows previous invocations, <code data-no-translation=\"\">deja fix<\/code> queries attempts after errors and <code data-no-translation=\"\">deja handoff --to codex<\/code> prepares the continuation in another agent. The history is evidence to review, not an order to execute old commands.<\/p>\n<p><strong>Maturity:<\/strong> the release <a href=\"https:\/\/github.com\/vshulcz\/deja-vu\/releases\/tag\/v0.22.1\">0.22.1, from 12\/10\/2026<\/a>, brings an extensive base of tests, CI, and security documentation. In our lab, build, static analysis, search between two synthetic histories, and MCP worked. We also reproduced a test failure related to the S\u00e3o Paulo time zone, with no evidence of note loss. It is promising for a serious desktop pilot, but it is still a young project on the 0.x line, not a guarantee of stability for all customers.<\/p>\n<p><strong>Privacy:<\/strong> the default search does not require a model; embeddings are optional and send material to the configured endpoint. Sanitization reduces credential exposure, but it does not guarantee removing every secret and does not encrypt the index. In addition, deleting the conversation in the agent does not necessarily delete its copy already retained in Deja Vu. Read the <a href=\"https:\/\/github.com\/vshulcz\/deja-vu\/blob\/v0.22.1\/docs\/SECURITY-MODEL.md\">security model<\/a> before enabling broad capture.<\/p>\n<p>Detailed installation, tests, limits, and maturity assessment are in <a href=\"\/en\/2026\/10\/deja-vu-memoria-dos-agentes-no-linux\/\">Deja Vu: agents' memory on Linux<\/a>.<\/p>\n<h3>mnemo \u2014 the most direct clone<\/h3>\n<p><a href=\"https:\/\/github.com\/kyungw00k\/mnemo\">mnemo<\/a> (MIT, Go 1.23+) is a memory MCP server with a single binary. Default database in <code data-no-translation=\"\">~\/.mnemo\/memory.db<\/code>. Detects Claude Code, OpenCode and Codex on first run and self-registers. Has dashboard at <code data-no-translation=\"\">http:\/\/localhost:8765<\/code>.<\/p>\n<pre data-no-translation=\"\"><code class=\"language-bash\" data-no-translation=\"\">go install github.com\/kyungw00k\/mnemo\/cmd\/mnemo@latest\n\n# hooks do Claude Code (ou deixe o auto-install)\nmnemo hook install --dry-run\nmnemo hook install\n\nmnemo dashboard<\/code><\/pre>\n<p>The hooks cover the cycle that Claude-Mem popularized: <code data-no-translation=\"\">SessionStart<\/code> injects recent decisions, <code data-no-translation=\"\">PreCompact<\/code> saves a snapshot, <code data-no-translation=\"\">PostToolUse<\/code> annotates result of <code data-no-translation=\"\">Bash<\/code>, <code data-no-translation=\"\">Stop<\/code> closes the session. Embeddings talk to any OpenAI-compatible endpoint \u2014 Ollama by default (<code data-no-translation=\"\">nomic-embed-text<\/code>, 768 dimensions). PostgreSQL + pgvector come in if you swap the <code data-no-translation=\"\">DB_URL<\/code>.<\/p>\n<p>It's the option closest to the original in Go. The project is still new; treat it as a useful tool, not a mature product of years.<\/p>\n<h3>Engram \u2014 one brain for multiple agents<\/h3>\n<p><a href=\"https:\/\/github.com\/Gentleman-Programming\/engram\">Engram<\/a> (MIT) was born inspired by claude-mem, but is agent-agnostic: a Go binary, a SQLite with FTS5 in <code data-no-translation=\"\">~\/.engram\/engram.db<\/code>, MCP, HTTP, CLI, and TUI. No Node, no Python, no Docker to run.<\/p>\n<pre data-no-translation=\"\"><code class=\"language-bash\" data-no-translation=\"\"># Claude Code\nclaude plugin marketplace add Gentleman-Programming\/engram\nclaude plugin install engram\n\n# Codex, OpenCode, Antigravity, Cursor\u2026\nengram setup codex\nengram setup opencode\nengram setup antigravity-cli\n\nengram tui<\/code><\/pre>\n<p>The contract with the agent is explicit: orient yourself with <code data-no-translation=\"\">mem_context<\/code> \/ <code data-no-translation=\"\">mem_search<\/code> before repeating work; record only what lasts (<code data-no-translation=\"\">mem_save<\/code>); close the session with <code data-no-translation=\"\">mem_session_summary<\/code>. It's not a transcript dump. The production README asks for the binary from the <a href=\"https:\/\/github.com\/Gentleman-Programming\/engram\/releases\">GitHub Releases<\/a>; Homebrew covers the stable line.<\/p>\n<p>If Claude Code, Codex, and Google's CLI need to remember the <em>same<\/em> decision, start here. The step-by-step covering installation, MCP, project name, and systemd is in <a href=\"\/en\/2026\/09\/engram-memoria-persistente-para-agentes-no-linux\/\">Engram: persistent memory for agents on Linux<\/a>.<\/p>\n<h3>Goldie \u2014 one pool, multiple agents<\/h3>\n<p class=\"translation-block\"><a href=\"https:\/\/github.com\/srfrog\/goldie-mcp\">Goldie<\/a> (MIT) replaces <code>MEMORY.md<\/code> with a shared SQLite file. Tools with the right vocabulary: <code>remember<\/code>, <code>recall<\/code>, <code>update_memory<\/code>, <code>forget<\/code>. Typed memories (<code>user<\/code>, <code>feedback<\/code>, <code>project<\/code>, <code>reference<\/code>\u2026), a concept graph, local embeddings via MiniLM (ONNX Runtime) or Ollama.<\/p>\n<pre data-no-translation=\"\"><code class=\"language-bash\" data-no-translation=\"\"># Linux amd64 \u2014 pegue o bin\u00e1rio da release\ncurl -LO https:\/\/github.com\/srfrog\/goldie-mcp\/releases\/latest\/download\/goldie-mcp-linux-amd64\nchmod +x goldie-mcp-linux-amd64\nmv goldie-mcp-linux-amd64 ~\/.local\/bin\/goldie-mcp\n\n# MiniLM precisa do ONNX Runtime\nsudo apt install libonnxruntime-dev   # Debian\/Ubuntu\n\n# ou pule o ONNX e use Ollama\nollama pull nomic-embed-text\nclaude mcp add -s user -e GOLDIE_DB_PATH=~\/.local\/share\/goldie\/index.db goldie goldie-mcp -- -b ollama<\/code><\/pre>\n<p>The \u201cscope\u201d is the file. Two agents using the same <code data-no-translation=\"\">GOLDIE_DB_PATH<\/code> share memory. Do not write from two machines at the same time if the <code data-no-translation=\"\">.db<\/code> is on Syncthing \u2014 the README is honest about this.<\/p>\n<h2>Rust: from single binary to memory server<\/h2>\n<h3>ai-memory \u2014 versioned wiki and handoff<\/h3>\n<p><a href=\"https:\/\/github.com\/akitaonrails\/ai-memory\">ai-memory<\/a> (MIT, Rust) is the most structured option in this part of the list. Instead of each agent writing directly to the database, a server is the sole writer: it receives observations sanitized by hooks, maintains a Git-versioned Markdown wiki as the source of truth, and uses SQLite as a derived index (FTS5, entities, and optional vectors).<\/p>\n<p>The workflow is <em>capture \u2192 consolidate \u2192 retrieve \u2192 hand off<\/em>. At the end of a session, observations can become readable wiki pages; in the next one, the agent receives a bounded handoff and can search the history. Capture, search, and handoff work without a key or LLM call; configuring a provider only adds consolidation and semantic search. This is an important difference from Engram and Leteo: ai-memory is a local HTTP\/MCP service, not just a process that opens SQLite.<\/p>\n<p>The documented path for Linux is Docker or Podman. Anyone already using <code data-no-translation=\"\">mise<\/code> can download the release binary with a checksum, without installing Rust:<\/p>\n<pre data-no-translation=\"\"><code class=\"language-bash\" data-no-translation=\"\">mise use -g github:akitaonrails\/ai-memory\n\n# uma vez: cria o estado local; depois sobe MCP + API + hooks HTTP\nai-memory init\nai-memory serve --transport http --bind 127.0.0.1:49374\n\n# em outro terminal, registre MCP e hooks para o cliente escolhido\nai-memory install-mcp --client claude-code --apply\nai-memory install-hooks --agent claude-code --apply\n\n# para o Codex, troque claude-code por codex nos dois comandos<\/code><\/pre>\n<p>Claude Code, Codex, OpenCode, Gemini CLI, Grok Build, and several other clients have first-party integration. On a single machine, the server listens on loopback; for a team or homelab, it can run on a shared host with authentication and HTTPS. Choose ai-memory when the priority is explicit transitions between Claude, Codex, and other agents \u2014 or when you want to inspect and version memory as Markdown. For direct SQLite access and a smaller setup, Engram and Leteo remain simpler.<\/p>\n<h3>Leteo \u2014 the Engram in Rust<\/h3>\n<p><a href=\"https:\/\/github.com\/asanabrial\/leteo\">Leteo<\/a> (MIT) is an independent Rust product derived from Engram's workflow and MIT implementation. One binary, SQLite in <code data-no-translation=\"\">~\/.leteo\/leteo.db<\/code>, no API key, no server. Imports the Engram database with <code data-no-translation=\"\">leteo import --from-engram<\/code>.<\/p>\n<pre data-no-translation=\"\"><code class=\"language-bash\" data-no-translation=\"\">curl -fsSL https:\/\/raw.githubusercontent.com\/asanabrial\/leteo\/main\/scripts\/install.sh | sh\nleteo tui\nleteo setup claude-code --hooks\nleteo setup codex<\/code><\/pre>\n<p>The Linux release files require glibc 2.34 \u2014 Debian 12, Ubuntu 22.04, RHEL 9 or newer. Claude Code plugin: <code data-no-translation=\"\">\/plugin marketplace add asanabrial\/leteo<\/code> and <code data-no-translation=\"\">\/plugin install leteo@leteo<\/code>. Do not register the plugin <em>and<\/em> <code data-no-translation=\"\">leteo setup --hooks<\/code> at the same time: each event fires twice.<\/p>\n<h3>Subcog \u2014 true hybrid search<\/h3>\n<p><a href=\"https:\/\/github.com\/zircote\/subcog\">Subcog<\/a> (MIT, Rust 1.88+) stacks three layers: SQLite as the source of truth, FTS5 (BM25), and HNSW vectors via usearch. Embeddings with <code data-no-translation=\"\">all-MiniLM-L6-v2<\/code> through fastembed, 384 dimensions, without calling an API. RRF fusion. Knowledge graph with entities and relationships.<\/p>\n<pre data-no-translation=\"\"><code class=\"language-bash\" data-no-translation=\"\">cargo install subcog\n# ou: brew install zircote\/tap\/subcog\n\nsubcog capture --namespace decisions \"Use PostgreSQL por causa do ACID\"\nsubcog recall \"decis\u00e3o de banco\"\nsubcog serve<\/code><\/pre>\n<p>Claude Code hooks: <code data-no-translation=\"\">SessionStart<\/code>, <code data-no-translation=\"\">UserPromptSubmit<\/code>, <code data-no-translation=\"\">PostToolUse<\/code>, <code data-no-translation=\"\">PreCompact<\/code>, <code data-no-translation=\"\">Stop<\/code>. This is the option if \u201cremembering\u201d needs to mean semantic search, not just grep in SQLite.<\/p>\n<h3>mcp-memory \u2014 graph + code in the same binary<\/h3>\n<p><a href=\"https:\/\/github.com\/corporatepiyush\/mcp-memory\">mcp-memory<\/a> (Apache-2.0) combines a knowledge graph, FTS5, vectors (usearch HNSW), and tree-sitter indexing for Rust, Python, JS\/TS, Go, Java, C, C++, Ruby, and PHP. Tools are enabled by category: nothing is exposed until you pass <code data-no-translation=\"\">--enable-graph-read<\/code> \/ <code data-no-translation=\"\">--enable-code<\/code> \/ <code data-no-translation=\"\">--enable-all<\/code>.<\/p>\n<pre data-no-translation=\"\"><code class=\"language-bash\" data-no-translation=\"\">cargo install mcp-memory\nmcp-memory --transport stdio --enable-all<\/code><\/pre>\n<p>Useful when you want <em>a<\/em> process remembering project entities <em>and<\/em> the symbol map. It does not replace codebase-memory-mcp at kernel scale, but fits on a laptop without an extra daemon.<\/p>\n<h3>mcp-memory-rs \u2014 local notebook, no ML<\/h3>\n<p><a href=\"https:\/\/github.com\/DioNanos\/mcp-memory-rs\">mcp-memory-rs<\/a> (Apache-2.0) stores agent state in JSON by category, with a SQLite FTS5 index. Every write is versioned. No model download, no embeddings. Synchronization between machines is an explicit step (Merkle manifest + HTTP), never a hidden dependency.<\/p>\n<p>The offline default is the point: Claude Code and Codex point to the same binary, and state survives model changes. For corpora (chunked documents), the author points to the companion <code data-no-translation=\"\">mcp-vl-msa-rs<\/code> \u2014 this one is the notebook, not the library.<\/p>\n<h3>memory-server \u2014 when memory is a service<\/h3>\n<p><a href=\"https:\/\/github.com\/tokarix\/memory-server\">memory-server<\/a> separates the pieces: the agent speaks MCP to <code data-no-translation=\"\">memory-mcp<\/code>, which calls <code data-no-translation=\"\">memoryd<\/code> over HTTP, which writes to PostgreSQL + pgvector and requests embeddings from Ollama (<code data-no-translation=\"\">bge-m3<\/code> by default).<\/p>\n<pre data-no-translation=\"\"><code class=\"language-text\" data-no-translation=\"\">agent  --stdio--&gt;  memory-mcp  --HTTP--&gt;  memoryd\n                                           |-- PostgreSQL + pgvector\n                                           +-- Ollama<\/code><\/pre>\n<p>Fixed categories: <code data-no-translation=\"\">context<\/code>, <code data-no-translation=\"\">decision<\/code>, <code data-no-translation=\"\">error_fix<\/code>, <code data-no-translation=\"\">plan<\/code>, <code data-no-translation=\"\">rule<\/code>. It makes sense when a laptop and server need the same store \u2014 and you accept running Postgres 17 with pgvector. For a single laptop user, it is overkill.<\/p>\n<h2>C: SQLite extension and repository graph<\/h2>\n<h3>sqlite-memory \u2014 memory as SQL<\/h3>\n<p><a href=\"https:\/\/github.com\/sqliteai\/sqlite-memory\">sqlite-memory<\/a> (MIT) is a C extension: Markdown as the source of truth, heading-aware chunking, hybrid search (vectors + FTS5), local embeddings with <a href=\"\/en\/2026\/09\/llama-cpp-primeiros-passos\/\">llama.cpp<\/a>. It is part of the SQLite AI family (<code data-no-translation=\"\">sqlite-vector<\/code>, <code data-no-translation=\"\">sqlite-sync<\/code>, <code data-no-translation=\"\">sqlite-mcp<\/code>\u2026).<\/p>\n<pre data-no-translation=\"\"><code class=\"language-sql\" data-no-translation=\"\">.load .\/vector\n.load .\/memory\nSELECT memory_set_model('local', '\/path\/to\/nomic-embed-text-v1.5.Q8_0.gguf');\nSELECT memory_add_directory('\/path\/to\/docs', 'project-docs');\nSELECT path, snippet, ranking FROM memory_search\n WHERE query = 'como o agente persiste contexto';<\/code><\/pre>\n<p>The Go CLI, <code data-no-translation=\"\">sqlmem<\/code>, wraps this in a project (<code data-no-translation=\"\">sqlmem init<\/code>, <code data-no-translation=\"\">add<\/code>, <code data-no-translation=\"\">search<\/code>) and exposes the tools via MCP. This is the path if you want to build your own layer, not install a ready-made product. Synchronization between agents uses CRDT from <code data-no-translation=\"\">sqlite-sync<\/code> \u2014 each works offline and merges later.<\/p>\n<h3>codebase-memory-mcp \u2014 the other memory<\/h3>\n<p class=\"translation-block\"><a href=\"https:\/\/github.com\/DeusData\/codebase-memory-mcp\">codebase-memory-mcp<\/a> (MIT, pure C) is <strong>not<\/strong> an alternative to Claude-Mem. It indexes the repository into a knowledge graph: functions, classes, HTTP routes, who calls whom. Tree-sitter, 15 MCP tools, native binary. The preprint is on arXiv <a href=\"https:\/\/arxiv.org\/abs\/2603.27277\">2603.27277<\/a>.<\/p>\n<pre data-no-translation=\"\"><code class=\"language-bash\" data-no-translation=\"\">curl -fsSL https:\/\/raw.githubusercontent.com\/DeusData\/codebase-memory-mcp\/main\/install.sh | bash\n# reinicie o agente e pe\u00e7a: index this project<\/code><\/pre>\n<p>Questions it answers that grep cannot: \u201cwho calls this function?\u201d, \u201cwhat is the blast radius of this diff?\u201d, \u201cwhere is this interface implemented?\u201d. Usage details in the post on <a href=\"\/en\/2026\/09\/vibe-coding-linux-skills-ia-cli\/\">AI skills in the CLI<\/a>. The happy path is <em>both<\/em> in the same agent: one remembers the conversation, the other remembers the code.<\/p>\n<h2>C++: the clone isn't ready yet<\/h2>\n<p>Among the projects on this list, there is no mature Claude-Mem equivalent whose primary implementation is C++. What exists in C++ serves as a component \u2014 <code data-no-translation=\"\">llama.cpp<\/code> for embeddings, SQLite, vector indexes \u2014 not as a session-memory product. codebase-memory-mcp analyzes C\/C++ very well; its binary, however, is C.<\/p>\n<h2>Where to test on Linux<\/h2>\n<p>A practical order for Claude Code + Codex + whatever else is in your <code data-no-translation=\"\">PATH<\/code>:<\/p>\n<ol>\n<li><strong>Deja Vu (Go)<\/strong> \u2014 if the problem is finding solutions and decisions in the histories that Claude Code, Codex, and other agents have already saved. Start with on-demand search; enable automation only after evaluating scope and privacy.<\/li>\n<li><strong>ai-memory (Rust)<\/strong> \u2014 when the main point is automatic handoff between Claude, Codex, and other agents, with a versioned Markdown wiki and a local server.<\/li>\n<li><strong>Engram (Go)<\/strong> \u2014 one database, multiple agents, a TUI to inspect what was saved.<\/li>\n<li><strong>mnemo (Go)<\/strong> \u2014 if what you want is Claude-Mem's hook cycle, without changing philosophy.<\/li>\n<li><strong>Leteo (Rust)<\/strong> \u2014 the same workflow as Engram, a Rust binary, imports its <code data-no-translation=\"\">.db<\/code> database.<\/li>\n<li><strong>Subcog (Rust)<\/strong> \u2014 when search really needs vectors + BM25.<\/li>\n<li><strong>mcp-memory (Rust)<\/strong> \u2014 if you want a graph + code index in the same process.<\/li>\n<li><strong>Goldie (Go)<\/strong> \u2014 shared pool, vocabulary <code data-no-translation=\"\">remember<\/code>\/<code data-no-translation=\"\">recall<\/code>.<\/li>\n<li><strong>sqlite-memory (C)<\/strong> \u2014 if the idea is to build your own layer on top of SQLite.<\/li>\n<\/ol>\n<p>And, alongside it, not instead: <strong>codebase-memory-mcp<\/strong>.<\/p>\n<pre data-no-translation=\"\"><code class=\"language-text\" data-no-translation=\"\">          Claude Code \/ Codex \/ OpenCode\n                       |\n              +--------+--------+\n              |                 |\n              v                 v\n     mem\u00f3ria de sess\u00e3o    mem\u00f3ria do c\u00f3digo\n     Engram \/ mnemo \/     codebase-memory-mcp\n     Leteo \/ Subcog              |\n              |                  v\n              v            knowledge graph\n         SQLite + FTS5         (tree-sitter)\n              |\n              +--------+--------+\n                       v\n              contexto persistente<\/code><\/pre>\n<p>This way, the next morning's agent already knows that authentication is JWT with refresh, <em>and<\/em> can point to the <code data-no-translation=\"\">handler.go<\/code> without rereading the repo.<\/p>\n<h2>What not to outsource<\/h2>\n<p>Persistent memory is not a backup of the truth. Git remains the record; the history is in <a href=\"\/en\/2026\/09\/a-historia-do-git\/\">The history of Git<\/a>. What goes into SQLite is decisions, conventions, costly bugs \u2014 not passwords, not tokens, not a dump of <code data-no-translation=\"\">journalctl<\/code>. Serious projects have a <code data-no-translation=\"\">&lt;private&gt;<\/code> tag or secret filter; if the one you chose does not, do not store anything that cannot be leaked.<\/p>\n<p>Avoid installing several auto-recall mechanisms on the same agent \u201cto be safe\u201d: they can duplicate context and decisions. A more manageable combination is a primary source of durable memory, the code graph, and, when it makes sense, Deja Vu as on-demand retrospective query. Enable more automation only if the gain justifies the context cost.<\/p>\n<h2>Closing<\/h2>\n<p>Claude-Mem showed the format: hook in the lifecycle, local state, and MCP on the query. Go and Rust already deliver different parts of this flow as native binaries. Deja Vu adds retrospective search in existing transcripts, with its own index; Rust also has the server + versioned wiki path from ai-memory. C delivers the extension and the code graph. C++ is still a piece, not a product. Choose by the question that hurts today \u2014 \u201cthe agent forgot the decision\u201d, \u201cI need to pass the work to another agent\u201d, or \u201cthe agent can't find the function\u201d \u2014 and put only the tool that answers that question.<\/p>\n<p>Repositories: <a href=\"https:\/\/github.com\/thedotmack\/claude-mem\">claude-mem<\/a> \u00b7 <a href=\"https:\/\/github.com\/vshulcz\/deja-vu\">Deja Vu<\/a> \u00b7 <a href=\"https:\/\/github.com\/kyungw00k\/mnemo\">mnemo<\/a> \u00b7 <a href=\"https:\/\/github.com\/Gentleman-Programming\/engram\">Engram<\/a> \u00b7 <a href=\"https:\/\/github.com\/akitaonrails\/ai-memory\">ai-memory<\/a> \u00b7 <a href=\"https:\/\/github.com\/srfrog\/goldie-mcp\">Goldie<\/a> \u00b7 <a href=\"https:\/\/github.com\/asanabrial\/leteo\">Leteo<\/a> \u00b7 <a href=\"https:\/\/github.com\/zircote\/subcog\">Subcog<\/a> \u00b7 <a href=\"https:\/\/github.com\/corporatepiyush\/mcp-memory\">mcp-memory<\/a> \u00b7 <a href=\"https:\/\/github.com\/DioNanos\/mcp-memory-rs\">mcp-memory-rs<\/a> \u00b7 <a href=\"https:\/\/github.com\/tokarix\/memory-server\">memory-server<\/a> \u00b7 <a href=\"https:\/\/github.com\/sqliteai\/sqlite-memory\">sqlite-memory<\/a> \u00b7 <a href=\"https:\/\/github.com\/DeusData\/codebase-memory-mcp\">codebase-memory-mcp<\/a>. Docs: <a href=\"https:\/\/docs.claude-mem.ai\/\">docs.claude-mem.ai<\/a> \u00b7 <a href=\"https:\/\/engram.gentlemanprogramming.com\/\">engram.gentlemanprogramming.com<\/a>.<\/p>\n<p style=\"font-size:.9em;opacity:.75\">Go Gopher designed by Ren\u00e9e French (CC BY 3.0). Ferris, Rust's unofficial mascot, by Karen Rustad T\u00f6lva.<\/p>","protected":false},"excerpt":{"rendered":"<p>Compare alternatives to Claude-Mem in Go, Rust, and C: Deja Vu for searching previously saved histories, Engram, ai-memory, mnemo, Leteo, Subcog, and other options.<\/p>","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[45,115,2],"tags":[394,408,544,31,116,311,427,158,407],"class_list":["post-981","post","type-post","status-publish","format-standard","hentry","category-desenv","category-ia","category-linux","tag-agentes","tag-claude-mem","tag-deja-vu","tag-golang","tag-ia","tag-mcp","tag-memoria-persistente","tag-rust","tag-sqlite"],"_links":{"self":[{"href":"https:\/\/www.linuxpro.com.br\/en\/wp-json\/wp\/v2\/posts\/981","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.linuxpro.com.br\/en\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.linuxpro.com.br\/en\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.linuxpro.com.br\/en\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.linuxpro.com.br\/en\/wp-json\/wp\/v2\/comments?post=981"}],"version-history":[{"count":5,"href":"https:\/\/www.linuxpro.com.br\/en\/wp-json\/wp\/v2\/posts\/981\/revisions"}],"predecessor-version":[{"id":1865,"href":"https:\/\/www.linuxpro.com.br\/en\/wp-json\/wp\/v2\/posts\/981\/revisions\/1865"}],"wp:attachment":[{"href":"https:\/\/www.linuxpro.com.br\/en\/wp-json\/wp\/v2\/media?parent=981"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.linuxpro.com.br\/en\/wp-json\/wp\/v2\/categories?post=981"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.linuxpro.com.br\/en\/wp-json\/wp\/v2\/tags?post=981"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}