Skip to main content

ShellBrain logo

ShellBrain

Long-term Memory for AI.

ShellBrain uses case-based reasoning and a self-managing concept graph as long-term memory for software engineering.

Install

curl -L shellbrain.ai/install | bash

Works for Codex, Claude Code, and Cursor.

Requirements.

  • macOS or Linux, Python 3.11+, Docker.

Upgrade for Latest Capabilities

shellbrain upgrade

Recall in One Command

ShellBrain recall uses vector search and BM25 to search your memories. An inner recall agent summarizes the search results.


Architecture

ShellBrain stores evidence and two forms of reusable knowledge:

  • Episodic Memory. It stores prompts, responses, and tool calls.
  • Case-Based Memory. Problems, solutions, and failed attempts are structured and stored.
  • Concept Graph. It connects claims, relations, and implementations.

Memories and concepts link directly to supporting evidence. The code is the source of truth.


How Agents Use ShellBrain

Recall

Working agents run shellbrain recall for long-term memory related to their current task.

Recall combines BM25, vector similarity, and explicit graph associations.

shellbrain recall "What is ShellBrain, and how does it help a working coding agent?"

Response:

{
  "status": "ok",
  "data": {
    "brief": {
      "summary": "...",
      "constraints": ["..."],
      "known_traps": ["..."],
      "prior_cases": ["..."],
      "concept_orientation": ["..."],
      "anchors": ["`README.md`"],
      "conflicts": ["..."],
      "gaps": ["..."],
      "next_checks": ["..."]
    },
    "fallback_reason": null
  },
  "errors": []
}

If there are no relevant memories, nothing is returned.

Recall Provider

For blazing fast recall for cheap, get an Inception API key and run:

mkdir -p ~/.shellbrain
printf '\nINCEPTION_API_KEY=%s\n' 'PASTE_YOUR_KEY_HERE' >> ~/.shellbrain/.env
chmod 600 ~/.shellbrain/.env
shellbrain admin recall provider inception

Switch back with shellbrain admin recall provider codex, or choose claude.

Tune recall in ~/.shellbrain/recall.yaml (optional; these are the defaults):

recall:
  max_memories: 12
  max_concepts: 4
  max_neighbor_concepts: 2
  max_claims_per_concept: 3
  max_groundings_per_concept: 2
  max_input_tokens: 8000

The input budget uses a byte-based token estimate. Settings affect recall synthesis only.


Docs

Metadata

Release files for shellbrain 0.1.66

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for shellbrain 0.1.66
File Size Uploaded Provenance
shellbrain-0.1.66.tar.gz 364.7 kB With provenance Details

Built distribution (wheel)

Table of built distributions (wheels) for shellbrain 0.1.66
File Interpreter ABI Platform
shellbrain-0.1.66-py3-none-any.whl Python 3 none any Details

Total release size: 892.3 kB

Release files / shellbrain-0.1.66.tar.gz

Download URL shellbrain-0.1.66.tar.gz
Size 364.7 kB
Tags Source
SHA-256 checksum
How to use checksums
dd09f0f87611a69da92e0ad712f98ca89f43df1e13e78da0b6cf5bcde210e261
BLAKE2b-256 checksum
How to use checksums
b6b63ca82b09cfb9cda0b0546df9ad0a8c859daa355356979495dbec659b9617
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

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 Sep 23, 2026.

Transparency log

Release files / shellbrain-0.1.66-py3-none-any.whl

Download URL shellbrain-0.1.66-py3-none-any.whl
Size 527.6 kB
Tags Python 3
SHA-256 checksum
How to use checksums
1f1314063fb0e5b72d08d3fdb006076a91cd06996bb02307bcda949a31deba96
BLAKE2b-256 checksum
How to use checksums
760863ca1f78a3a5260b8116da2dff2524c07411d8346db3dedb6ff4a930cf16
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

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 Sep 23, 2026.

Transparency log

Security for shellbrain 0.1.66

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

All 2 files in this release have been uploaded with provenance metadata.

Select from 2 files

Attestation for shellbrain-0.1.66.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 Sep 23, 2026.

Transparency log

A 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.

Release history Release notifications | RSS feed

This release

0.1.66 This release

2 release files Full provenance

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page