Memory evolution system for Claude Code
npx claudepluginhub chadhietala/engramMemory evolution system that learns from your Claude Code usage and generates reusable skills through Hegelian dialectic
A memory system for Claude Code that learns how you work and generates new skills from your patterns.
Local Development:
# Clone the repo
git clone https://github.com/chietala/engram.git
cd engram
bun install
# Run Claude Code with the plugin
claude --plugin-dir /path/to/engram
From GitHub:
# Add the marketplace
/plugin marketplace add chietala/engram
# Install the plugin
/plugin install engram@engram-marketplace
Team Auto-Install:
Add to your project's .claude/settings.json:
{
"extraKnownMarketplaces": {
"engram-marketplace": {
"source": {
"source": "github",
"repo": "chietala/engram"
}
}
},
"enabledPlugins": {
"engram@engram-marketplace": true
}
}
Every time you use Claude Code, you're teaching it something. Engram captures those lessons automatically:
Once installed, these commands are available:
| Command | Description |
|---|---|
/engram-status | Show memory counts and system status |
/engram-query <search> | Search memories semantically |
/engram-generate <name> | Generate a skill from recent patterns |
/engram-publish | Publish mature patterns as Claude rules |
Engram notices when you do similar things repeatedly. Read a config file then run a command? Do it a few times and Engram recognizes the pattern.
Patterns evolve through dialectic:
git status before committing"git status for multi-file changes, skip for single-line fixes"This creates nuanced, context-aware knowledge.
Claude analyzes your patterns and generates insights like:
"The user is building a self-improving system that observes its own tool usage patterns and automatically generates new reusable skills"
When patterns reach synthesis, Engram automatically publishes them as Claude rules—meaning Claude remembers your patterns without the plugin running:
.claude/rules/engram/
├── testing-workflow.md # "Run tests before committing"
├── error-handling.md # "Check logs after deployments"
└── code-review.md # "Read tests before reviewing PRs"
Rules include:
Example generated rule:
---
paths:
- "**/*.ts"
- "src/**"
---
# Test Before Commit
Before committing any code changes, always run the test suite with `bun test`.
## Related Skill
This pattern has an associated skill: **test-before-commit**
> Runs tests and commits changes with conventional commit messages
**To invoke this skill**, say:
- "commit my changes"
- "run tests and commit"
- "safe commit"
When a pattern matures enough (used consistently, survived contradictions), Engram generates a Claude Skill you can use in future sessions.
Generated skills aren't just static instructions—they're executable scripts that combine:
// Deterministic: gather data
const files = await glob.scan({ pattern: "**/*.ts" });
const diff = await $`git diff --cached`.text();
// Intelligence point: generate insights
const summary = await intelligence(
"Summarize the key patterns in this codebase",
{ files: fileList, diff }
);
// Deterministic: output results
console.log(summary);
This creates scripts that are both reliable and intelligent.
Like human memory:
Old, unused memories fade. Important ones strengthen.
Query your memories naturally:
/engram-query "how do I handle errors"
Finds relevant patterns even if wording differs.
| Event | What's Learned |
|---|---|
| File reads | What you look at to understand code |
| Bash commands | Your debugging and build workflows |
| File edits | How you modify code |
| Prompts | What you're trying to accomplish |