From 9c3d2eb3359d21920d78e65078fd435c6980bc6c Mon Sep 17 00:00:00 2001 From: phernandez Date: Fri, 28 Nov 2025 14:08:29 -0600 Subject: [PATCH] refactor: Move plugin into claude-code-plugin subdirectory MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Reorganize plugin files into a dedicated subdirectory to keep them separate from the main Basic Memory Python package: - Move all plugin files to claude-code-plugin/ - Add README.md with quick start guide - Update installation paths to use subdirectory New structure: ``` claude-code-plugin/ ├── .claude-plugin/ │ ├── plugin.json │ └── marketplace.json ├── commands/ ├── skills/ ├── hooks/ ├── README.md └── PLUGIN.md ``` Installation: /plugin marketplace add basicmachines-co/basic-memory/claude-code-plugin /plugin install basic-memory@basicmachines 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Signed-off-by: phernandez --- .../.claude-plugin}/marketplace.json | 0 .../.claude-plugin}/plugin.json | 0 PLUGIN.md => claude-code-plugin/PLUGIN.md | 10 +- claude-code-plugin/README.md | 95 +++++++++++++++++++ .../commands}/context.md | 0 .../commands}/continue.md | 0 .../commands}/organize.md | 0 .../commands}/recent.md | 0 .../commands}/remember.md | 0 .../hooks}/hooks.json | 0 .../skills}/continue-conversation/SKILL.md | 0 .../skills}/edit-note-local/SKILL.md | 0 .../skills}/edit-note/SKILL.md | 0 .../skills}/knowledge-capture/SKILL.md | 0 .../skills}/knowledge-organize/SKILL.md | 0 .../skills}/spec-driven-development/SKILL.md | 0 16 files changed, 101 insertions(+), 4 deletions(-) rename {.claude-plugin => claude-code-plugin/.claude-plugin}/marketplace.json (100%) rename {.claude-plugin => claude-code-plugin/.claude-plugin}/plugin.json (100%) rename PLUGIN.md => claude-code-plugin/PLUGIN.md (95%) create mode 100644 claude-code-plugin/README.md rename {commands => claude-code-plugin/commands}/context.md (100%) rename {commands => claude-code-plugin/commands}/continue.md (100%) rename {commands => claude-code-plugin/commands}/organize.md (100%) rename {commands => claude-code-plugin/commands}/recent.md (100%) rename {commands => claude-code-plugin/commands}/remember.md (100%) rename {hooks => claude-code-plugin/hooks}/hooks.json (100%) rename {skills => claude-code-plugin/skills}/continue-conversation/SKILL.md (100%) rename {skills => claude-code-plugin/skills}/edit-note-local/SKILL.md (100%) rename {skills => claude-code-plugin/skills}/edit-note/SKILL.md (100%) rename {skills => claude-code-plugin/skills}/knowledge-capture/SKILL.md (100%) rename {skills => claude-code-plugin/skills}/knowledge-organize/SKILL.md (100%) rename {skills => claude-code-plugin/skills}/spec-driven-development/SKILL.md (100%) diff --git a/.claude-plugin/marketplace.json b/claude-code-plugin/.claude-plugin/marketplace.json similarity index 100% rename from .claude-plugin/marketplace.json rename to claude-code-plugin/.claude-plugin/marketplace.json diff --git a/.claude-plugin/plugin.json b/claude-code-plugin/.claude-plugin/plugin.json similarity index 100% rename from .claude-plugin/plugin.json rename to claude-code-plugin/.claude-plugin/plugin.json diff --git a/PLUGIN.md b/claude-code-plugin/PLUGIN.md similarity index 95% rename from PLUGIN.md rename to claude-code-plugin/PLUGIN.md index 75f199c0..e59ad2dc 100644 --- a/PLUGIN.md +++ b/claude-code-plugin/PLUGIN.md @@ -21,7 +21,7 @@ Then add it to your Claude Code MCP configuration. ### Add the Marketplace ``` -/plugin marketplace add basicmachines-co/basic-memory +/plugin marketplace add basicmachines-co/basic-memory/claude-code-plugin ``` ### Install the Plugin @@ -41,7 +41,8 @@ Add to your `.claude/settings.json`: "basicmachines": { "source": { "source": "github", - "repo": "basicmachines-co/basic-memory" + "repo": "basicmachines-co/basic-memory", + "path": "claude-code-plugin" } } }, @@ -243,7 +244,7 @@ This plugin leverages Basic Memory's MCP tools: ## Plugin Structure ``` -basic-memory/ +claude-code-plugin/ ├── .claude-plugin/ │ ├── plugin.json # Plugin manifest │ └── marketplace.json # Self-hosted marketplace @@ -262,7 +263,8 @@ basic-memory/ │ └── knowledge-organize/ ├── hooks/ │ └── hooks.json # Hook definitions -└── PLUGIN.md # This file +├── README.md # Quick start guide +└── PLUGIN.md # Full documentation ``` --- diff --git a/claude-code-plugin/README.md b/claude-code-plugin/README.md new file mode 100644 index 00000000..b5249634 --- /dev/null +++ b/claude-code-plugin/README.md @@ -0,0 +1,95 @@ +# Basic Memory Plugin for Claude Code + +A Claude Code plugin that integrates [Basic Memory](https://basicmemory.io) - a local-first knowledge management system built on the Model Context Protocol (MCP). + +## What This Plugin Does + +This plugin helps Claude Code work seamlessly with your Basic Memory knowledge base: + +- **Capture knowledge** from conversations automatically +- **Resume previous work** by building context from your knowledge graph +- **Edit notes** interactively through conversation +- **Organize your knowledge** by finding orphans, suggesting links, and maintaining structure + +## Installation + +### 1. Install Basic Memory + +```bash +pip install basic-memory +# or +pipx install basic-memory +``` + +### 2. Add the Marketplace + +``` +/plugin marketplace add basicmachines-co/basic-memory/claude-code-plugin +``` + +### 3. Install the Plugin + +``` +/plugin install basic-memory@basicmachines +``` + +## Commands + +| Command | Description | +|---------|-------------| +| `/remember [title]` | Capture insights from the current conversation | +| `/continue [topic]` | Resume previous work with context | +| `/context ` | Build context from a specific note | +| `/recent [timeframe]` | Show recent activity | +| `/organize [action]` | Maintain your knowledge graph | + +### Examples + +```bash +# Capture what we just discussed +/remember "Database Design Decision" + +# Pick up where we left off +/continue postgres migration + +# Check recent changes +/recent 1week + +# Find orphan notes and suggest links +/organize orphans +``` + +## Skills + +Skills are model-invoked - Claude uses them automatically when the context fits. + +| Skill | What It Does | +|-------|--------------| +| `knowledge-capture` | Auto-captures decisions and insights into structured notes | +| `continue-conversation` | Builds context when resuming previous work | +| `spec-driven-development` | Guides implementation based on specs in Basic Memory | +| `edit-note` | Edits notes via MCP tools (cloud-compatible) | +| `edit-note-local` | Edits notes as files (local installations) | +| `knowledge-organize` | Helps organize and link notes | + +## Hooks + +| Event | Behavior | +|-------|----------| +| `PostToolUse: write_note` | Confirms when notes are saved | +| `Stop` | Suggests capturing valuable insights after conversations | + +## Requirements + +- [Claude Code](https://claude.com/claude-code) +- [Basic Memory](https://basicmemory.io) with MCP server configured + +## Documentation + +- [Full Plugin Documentation](./PLUGIN.md) +- [Basic Memory Docs](https://docs.basicmemory.io) +- [Claude Code Plugins](https://code.claude.com/docs/en/plugins) + +## License + +MIT - See the [Basic Memory repository](https://github.com/basicmachines-co/basic-memory) for details. diff --git a/commands/context.md b/claude-code-plugin/commands/context.md similarity index 100% rename from commands/context.md rename to claude-code-plugin/commands/context.md diff --git a/commands/continue.md b/claude-code-plugin/commands/continue.md similarity index 100% rename from commands/continue.md rename to claude-code-plugin/commands/continue.md diff --git a/commands/organize.md b/claude-code-plugin/commands/organize.md similarity index 100% rename from commands/organize.md rename to claude-code-plugin/commands/organize.md diff --git a/commands/recent.md b/claude-code-plugin/commands/recent.md similarity index 100% rename from commands/recent.md rename to claude-code-plugin/commands/recent.md diff --git a/commands/remember.md b/claude-code-plugin/commands/remember.md similarity index 100% rename from commands/remember.md rename to claude-code-plugin/commands/remember.md diff --git a/hooks/hooks.json b/claude-code-plugin/hooks/hooks.json similarity index 100% rename from hooks/hooks.json rename to claude-code-plugin/hooks/hooks.json diff --git a/skills/continue-conversation/SKILL.md b/claude-code-plugin/skills/continue-conversation/SKILL.md similarity index 100% rename from skills/continue-conversation/SKILL.md rename to claude-code-plugin/skills/continue-conversation/SKILL.md diff --git a/skills/edit-note-local/SKILL.md b/claude-code-plugin/skills/edit-note-local/SKILL.md similarity index 100% rename from skills/edit-note-local/SKILL.md rename to claude-code-plugin/skills/edit-note-local/SKILL.md diff --git a/skills/edit-note/SKILL.md b/claude-code-plugin/skills/edit-note/SKILL.md similarity index 100% rename from skills/edit-note/SKILL.md rename to claude-code-plugin/skills/edit-note/SKILL.md diff --git a/skills/knowledge-capture/SKILL.md b/claude-code-plugin/skills/knowledge-capture/SKILL.md similarity index 100% rename from skills/knowledge-capture/SKILL.md rename to claude-code-plugin/skills/knowledge-capture/SKILL.md diff --git a/skills/knowledge-organize/SKILL.md b/claude-code-plugin/skills/knowledge-organize/SKILL.md similarity index 100% rename from skills/knowledge-organize/SKILL.md rename to claude-code-plugin/skills/knowledge-organize/SKILL.md diff --git a/skills/spec-driven-development/SKILL.md b/claude-code-plugin/skills/spec-driven-development/SKILL.md similarity index 100% rename from skills/spec-driven-development/SKILL.md rename to claude-code-plugin/skills/spec-driven-development/SKILL.md