Integration
Long-term memory for Gemini CLI
Google's Gemini CLI is fast, capable, and stateless. Every `gemini -p "..."` call starts fresh, with no memory of yesterday's question, last week's project context, or your standing preferences. Add Engram to `~/.gemini/settings.json` and Gemini gets six durable memory tools without changing your CLI muscle memory.
Install
Three steps: sign up for an Engram API key, paste a BYOK LLM-provider key on /models, then drop the snippet below into Gemini CLI.
Three steps to memory in your agent
- Sign up. Free, no card. You'll land on a Getting Started page that walks the next two steps.
- Add your LLM key. Engram is BYOK. Paste an OpenAI / Anthropic / Groq / Together / Fireworks key and we'll route every extraction and query call through your provider. You pay your provider directly. We never see your inference.
- Paste the snippet below into your agent and restart it. Use
Authorization: Bearer <api-key>with the API key from your portal.
engram-gemini-cli: Google's official Gemini CLI
Adds six Engram MCP tools to gemini via ~/.gemini/settings.json. The url field is the signal; Gemini auto-detects SSE. Source: github.com/lumetra-io/engram-gemini-cli.
- Create or merge into
~/.gemini/settings.json(or.gemini/settings.jsonfor project scope): - Verify:
{
"mcpServers": {
"engram": {
"url": "https://mcp.lumetra.io/mcp/sse",
"headers": {
"Authorization": "Bearer <api-key>"
},
"timeout": 30000
}
}
}npm install -g @google/gemini-cli
gemini -p "Use the engram store_memory tool to remember 'gemini cli verification'. Then call engram list_memories on bucket default with limit 3."What you can do once memory's wired in
- Recall the answers Gemini gave you on the same topic last week without retyping the context
- Remember which information sources you trust for which topic (finance, medical, code, travel)
- Pull up the spec for that side project you haven't touched in a month
- Avoid re-explaining your team, org, and role every time you ask Gemini a work-context question
FAQ
Does Gemini CLI auto-detect SSE vs stdio?
Yes. Provide a `url` field and Gemini connects over SSE. Provide `command` and `args` for stdio servers. The presence of `url` is the signal.
Can I scope the config per project?
Yes. A `.gemini/settings.json` in the project root overrides `~/.gemini/settings.json` for that project. Useful for project-specific buckets.
Does this require a paid Gemini API tier?
Engram works on any Gemini CLI install; your LLM credentials are unrelated. Engram is BYOK for the *extraction + synthesis* layer (configured at lumetra.io/models), not for Gemini's own model calls.
Related integrations
Ship durable memory in Gemini CLI today
Free tier: 10K memories and 50K retrievals per month. No credit card. Same Engram backend powers all 41 integrations, so memories you write from one client are immediately queryable from the rest.