Integration
Long-term memory for AstrBot
AstrBot is the multi-platform chatbot framework that runs on QQ, WeChat, Discord, and Telegram all at once. Its built-in memory is per-conversation. The Engram plugin adds two slash commands (`/remember`, `/recall`) plus optional silent auto-archive, so every message a user sends becomes a memory in their personal bucket.
Install
Three steps: sign up for an Engram API key, paste a BYOK LLM-provider key on /models, then drop the snippet below into AstrBot.
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.
astrbot_plugin_engram: multi-platform chatbot framework
Adds /remember and /recall slash commands plus optional auto-archive of every non-command message. Per-user, per-chat, or fixed bucket strategy. Source: github.com/lumetra-io/engram-astrbot.
- Install from the AstrBot WebUI: Plugins → Install from URL → paste
https://github.com/lumetra-io/engram-astrbot→ Install → Enable. - Open Plugins → Engram Memory → Config and paste your API key, or set
ENGRAM_API_KEYin the AstrBot env and leave the form blank. - Pick a bucket strategy:
per_user(default; per-sender memory),per_chat(per-session), orfixed(one shared bucket). Setauto_archive: trueif you want every non-command message persisted in the background.
What you can do once memory's wired in
- Give every user across Discord, QQ, and WeChat the same persistent personality and preferences
- Auto-archive every non-command message so the bot can answer 'what did we talk about last week?'
- Run per-chat buckets in group rooms and per-user buckets in DMs, controlled by the bucket strategy config
- Build a memory-first companion bot where every fact the user shares is queryable across platforms
FAQ
What's the difference between `per_user` and `per_chat` bucket strategies?
`per_user` keys by sender ID (memories follow the human across rooms); `per_chat` keys by session ID (memories scope to the conversation, useful for group rooms). `fixed` puts everything in one shared bucket.
Does `auto_archive` store slash commands too?
No, slash commands are skipped to avoid double-storing. Only normal messages over `auto_archive_min_length` chars get persisted. Default min length is 8.
Where does the plugin store the API key?
In AstrBot's plugin config (UI form or `data/config/astrbot_plugin_engram_config.json`). Falls back to the `ENGRAM_API_KEY` env var if the form is blank.
Related integrations
Ship durable memory in AstrBot 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.