{"slug": "how-i-gave-my-ai-coding-agent-persistent-memory-in-2-minutes", "title": "How I Gave My AI Coding Agent Persistent Memory in 2 Minutes", "summary": "A developer built Engram, a tool that gives AI coding assistants like ChatGPT, Claude Code, Cursor, and Windsurf persistent memory across sessions. Engram stores conversations verbatim and enables semantic search, allowing AI agents to recall past context without manual re-explanation. The tool uses the Model Context Protocol and runs on Cloudflare's global network.", "body_md": "Every AI coding session starts the same way: you explain your project, your conventions, your preferences, and the context from last week's debugging session. Then you do it all again tomorrow.\n\nI built [Engram](https://getengram.app) to fix this. It gives ChatGPT, Claude Code, Cursor, and Windsurf a persistent memory that survives across sessions — so your AI actually remembers what you discussed yesterday.\n\nAI assistants are stateless. Each session starts from zero. There are workarounds:\n\nNone of these capture the *full arc* of a conversation — the trade-offs you evaluated, the bugs you investigated, the reasoning behind decisions.\n\nEngram stores your conversations verbatim and makes them searchable by meaning. When your AI starts a new session, it can search your history and pull in relevant context from days or weeks ago.\n\nIt works through [MCP](https://modelcontextprotocol.io) (Model Context Protocol), so any compatible client can use it. Your AI gets three core tools:\n\n`search`\n\n— \"what did we decide about the auth flow?\" finds the relevant conversation even if you never used those exact words`create_conversation`\n\n/ `append_messages`\n\n— stores new conversations automatically`vault_set`\n\n/ `vault_get`\n\n— key-value store for structured factsUnder the hood, conversations are chunked and embedded using vector embeddings. Search is semantic — it matches by meaning, not keywords.\n\n`https://mcp.getengram.app/mcp`\n\nThat's it. No CLI, no API keys, no install. ChatGPT can now search your history and store new conversations.\n\nTry asking: *\"What did we discuss about [topic] last week?\"*\n\nAdd to your MCP config (`~/.claude/settings.json`\n\n):\n\n```\n{\n  \"mcpServers\": {\n    \"engram\": {\n      \"type\": \"http\",\n      \"url\": \"https://mcp.getengram.app/mcp\",\n      \"headers\": {\n        \"Authorization\": \"Bearer YOUR_API_KEY\"\n      }\n    }\n  }\n}\n```\n\nThen add a few lines to your `CLAUDE.md`\n\ntelling Claude to search on session start:\n\n```\n## Memory\n\nOn session start, search Engram for context relevant to the current task:\n- search query: \"<summary of what the user is asking about>\"\n\nWhen important decisions or context are established, store them in Engram.\n```\n\nFor zero-friction capture, install the CLI:\n\n```\nnpm i -g @getengram/cli\nengram daemon start\n```\n\nThe daemon runs in the background and auto-captures every Claude Code session. You don't have to prompt Claude to remember things — it just happens.\n\nSame as Claude — add the MCP server URL + API key to your MCP config. Both support MCP natively.\n\nAfter a few weeks of use, here's the kind of context Engram surfaces for me:\n\nThe key difference from CLAUDE.md: I don't maintain any of this manually. Conversations are stored as they happen, and the right context surfaces when it's relevant.\n\nThe backend runs entirely on Cloudflare:\n\nWhen you store a conversation, Engram:\n\nWhen you search, it:\n\nThe whole thing is globally distributed with sub-100ms cold starts.\n\nThe source is on GitHub under BSL-1.1 (converts to Apache 2.0 after the change date). You can self-host the whole thing on Cloudflare's free tier with `wrangler deploy`\n\n.\n\n**GitHub:** [github.com/get-engram/engram](https://github.com/get-engram/engram)\n\nI'm working on:\n\nIf you're tired of re-explaining yourself to your AI every session:\n\n`https://mcp.getengram.app/mcp`\n\n`@getengram/cli`\n\nfor auto-captureThe free tier is enough to see if it's useful for your workflow. I'd love to hear what context you find yourself repeating the most.\n\n[Engram](https://getengram.app) is built by [Get Engram Inc](https://github.com/get-engram). Questions? [hello@getengram.app](mailto:hello@getengram.app)", "url": "https://wpnews.pro/news/how-i-gave-my-ai-coding-agent-persistent-memory-in-2-minutes", "canonical_source": "https://dev.to/debragail/how-i-gave-my-ai-coding-agent-persistent-memory-in-2-minutes-581l", "published_at": "2026-07-07 22:38:10+00:00", "updated_at": "2026-07-07 22:58:15.158297+00:00", "lang": "en", "topics": ["developer-tools", "large-language-models", "ai-agents", "ai-infrastructure"], "entities": ["Engram", "Get Engram Inc", "ChatGPT", "Claude Code", "Cursor", "Windsurf", "Cloudflare", "Model Context Protocol"], "alternates": {"html": "https://wpnews.pro/news/how-i-gave-my-ai-coding-agent-persistent-memory-in-2-minutes", "markdown": "https://wpnews.pro/news/how-i-gave-my-ai-coding-agent-persistent-memory-in-2-minutes.md", "text": "https://wpnews.pro/news/how-i-gave-my-ai-coding-agent-persistent-memory-in-2-minutes.txt", "jsonld": "https://wpnews.pro/news/how-i-gave-my-ai-coding-agent-persistent-memory-in-2-minutes.jsonld"}}