Brain
Brain gives coding agents durable, local context: long-term project memory, agent-to-agent messages, and a localhost dashboard through an MCP server. It works with Claude Code and Codex, while keeping the Python import name and existing devmem command available for compatibility.
Windows, macOS, and Linux are supported. Windows is supported natively starting with this release.
Install
Install Brain as a tool:
uv tool install agent-memory-brain
Or use pipx:
pipx install agent-memory-brain
If brain is not yet on your PATH, run uv tool update-shell, follow its shell instructions, and open a new terminal. Until then, use the absolute executable path from uv tool dir --bin.
Connect an agent
Register the MCP server for Claude Code:
claude mcp add brain -s user -- brain mcp
If brain is not on PATH, replace it in that command with the absolute executable path from uv tool dir --bin.
For Codex, add this to ~/.codex/config.toml (use the absolute path if needed). The MCP server's internal name remains devmem for compatibility:
[mcp_servers.devmem]
command = "brain"
args = ["mcp"]
To include a compact project briefing at the start of a Claude Code session, optionally configure a SessionStart hook that runs:
brain context --hook
Dashboard
Start the local panel:
brain panel
Then open http://127.0.0.1:8765. The dashboard shows activity, projects, sessions, memories, messages, and optional integrations.
Memory that stays useful
Use the MCP tools to save decisions, preferences, snippets, notes, and follow-ups. Search combines keywords with local semantic embeddings when enabled; brain embed backfills embeddings and DEVMEM_EMBED=0 keeps operation keyword-only. The CLI also offers brain search, brain context, and brain audit.
Changes and deletions retain revision history (memory_history and memory_restore). Pin only the facts needed in every session, and use typed memory links rather than repeating related context. brain maintain --dry-run previews optional maintenance work before it changes anything.
Privacy and network
All memory data stays in ~/.devmem/devmem.db, and the panel binds only to localhost. Brain reads, but never modifies, logs in ~/.claude/projects and ~/.codex/sessions.
On first embedding use, FastEmbed may download its model into ~/.devmem/models; set DEVMEM_EMBED=0 to disable embeddings. The following features are off unless configured: the Azure DevOps panel (requires ~/.devmem/ado.json and a user-created token file), git sync (a user-configured git remote), automatic maintenance (runs local codex exec or claude -p), and panel chat dispatch (runs local Claude or Codex CLIs).
Guard limits
Command guard rules match literal command text, so dynamic forms such as x=git; $x commit or eval can bypass them. Put hard limits in OS permissions; path rules still inspect command tokens.
Configuration
Configuration names deliberately remain compatible: environment variables continue to use the DEVMEM_* prefix and data/configuration paths remain under ~/.devmem/. Common settings include DEVMEM_DB, DEVMEM_EMBED, DEVMEM_MAX_CONTENT, DEVMEM_PANEL_PORT, DEVMEM_MAINTAIN, and DEVMEM_ADO_CONFIG.
License
Brain is free for individuals and small businesses under the PolyForm Small Business License 1.0.0. Larger companies can contact the author for a commercial license via the PyPI project page.
The paid Agensi skill pack teaches agents to use Brain well.
Metadata
Release files for agent-memory-brain 0.3.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| agent_memory_brain-0.3.1.tar.gz | 668.8 kB | With provenance | Details for agent_memory_brain-0.3.1.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| agent_memory_brain-0.3.1-py3-none-any.whl | Python 3 | none | any | Details for agent_memory_brain-0.3.1-py3-none-any.whl |
Total release size: 1.4 MB
Release files / agent_memory_brain-0.3.1.tar.gz
| Download URL | agent_memory_brain-0.3.1.tar.gz |
|---|---|
| Size | 668.8 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
ac22af11dee0638d7be0fb49437bacfacc5eb0e56c57e5e9044f61b4889eaccc
|
|
BLAKE2b-256 checksum How to use checksums |
13eb2f8a0604e1921e3f12375e6cc70a2f955e2cc8d3385dc2f143e056d4a9aa
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.16
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Nov 12, 2026.
Transparency logRelease files / agent_memory_brain-0.3.1-py3-none-any.whl
| Download URL | agent_memory_brain-0.3.1-py3-none-any.whl |
|---|---|
| Size | 698.3 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
61350093cbeb9255dd9ef13b05eb3c47c7d3b8144e8df6f5464a3f319aa55511
|
|
BLAKE2b-256 checksum How to use checksums |
2667603bdc573d15499d44ab8c6e51625302bb32021341cc0aac0b15da6a7820
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.16
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Nov 12, 2026.
Transparency logSecurity for agent-memory-brain 0.3.1
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
Full provenance
Both files in this release have been uploaded with provenance metadata.
Attestation for agent_memory_brain-0.3.1.tar.gz
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Nov 12, 2026.
Transparency logA note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.