Skip to content

Commit 3a7fca8

Browse files
phernandezclaude
andcommitted
feat: Add knowledge-organizer skill for maintaining knowledge graph
New skill to help users organize and maintain their knowledge base: Capabilities: - Find orphan notes (no relations to other notes) - Suggest relations based on content similarity - Identify duplicate or overlapping notes - Review and suggest folder organization - Normalize inconsistent tags - Create index/hub notes for topic navigation - Enrich sparse notes with observations and structure Includes workflows for: - Quick health check (overview of KB status) - Deep organization session (thorough review) - Topic-focused organization (organize around a subject) 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com> Signed-off-by: phernandez <paul@basicmachines.co>
1 parent 4f2b1b2 commit 3a7fca8

2 files changed

Lines changed: 307 additions & 1 deletion

File tree

PLUGIN.md

Lines changed: 24 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -168,6 +168,28 @@ Edit notes directly as local markdown files with automatic sync.
168168

169169
**Best for:** Local users who want full file access and git integration.
170170

171+
### knowledge-organizer
172+
173+
Help organize, link, and maintain the knowledge graph.
174+
175+
**Triggers when:**
176+
- User wants to organize their notes
177+
- User asks about orphan or unlinked notes
178+
- User wants to find connections between notes
179+
- User mentions duplicates or similar notes
180+
- User asks for help with folder organization
181+
182+
**Capabilities:**
183+
- **Find orphan notes** - Identify notes with no relations
184+
- **Suggest relations** - Propose meaningful links between notes
185+
- **Identify duplicates** - Find notes covering similar topics
186+
- **Folder organization** - Review and suggest folder structure
187+
- **Tag consistency** - Normalize and improve tagging
188+
- **Create index notes** - Generate hub notes linking related topics
189+
- **Enrich sparse notes** - Suggest observations and structure
190+
191+
**Best for:** Periodic knowledge base maintenance and improving discoverability.
192+
171193
---
172194

173195
## Hooks
@@ -216,7 +238,8 @@ basic-memory/
216238
│ ├── continue-conversation/
217239
│ ├── spec-driven-development/
218240
│ ├── edit-note/
219-
│ └── edit-note-local/
241+
│ ├── edit-note-local/
242+
│ └── knowledge-organizer/
220243
├── hooks/
221244
│ └── hooks.json # Hook definitions
222245
└── PLUGIN.md # This file
Lines changed: 283 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,283 @@
1+
---
2+
name: knowledge-organizer
3+
description: Help organize, link, and maintain the Basic Memory knowledge graph - find orphan notes, suggest relations, identify duplicates, and improve overall knowledge structure
4+
---
5+
6+
# Knowledge Organizer
7+
8+
This skill helps users maintain a healthy, well-connected knowledge graph. As notes accumulate, it becomes valuable to periodically organize, link, and curate the knowledge base.
9+
10+
## When to Use
11+
12+
Use this skill when:
13+
- User asks to organize their notes
14+
- User wants to find connections between notes
15+
- User mentions orphan or unlinked notes
16+
- User wants to clean up or improve their knowledge base
17+
- User asks about duplicate or similar notes
18+
- User wants help with folder organization
19+
- User asks to review or audit their notes
20+
- Phrases like "help me organize", "find related notes", "what's not linked", "clean up my notes"
21+
22+
## Organization Capabilities
23+
24+
### 1. Find Orphan Notes
25+
26+
Identify notes that have no relations to other notes - they're isolated in the knowledge graph.
27+
28+
```python
29+
# Get all notes
30+
mcp__basic-memory__search_notes(
31+
query="*",
32+
page_size=50,
33+
project="main"
34+
)
35+
36+
# For each note, check if it has relations
37+
# Orphans have empty Relations sections
38+
```
39+
40+
**What to do with orphans:**
41+
- Suggest potential relations based on content similarity
42+
- Ask if they should be linked to existing topics
43+
- Propose creating hub notes to connect related orphans
44+
45+
### 2. Suggest Relations
46+
47+
Analyze note content and suggest meaningful connections.
48+
49+
```python
50+
# Read a note
51+
mcp__basic-memory__read_note(
52+
identifier="note-to-analyze",
53+
project="main"
54+
)
55+
56+
# Search for potentially related notes
57+
mcp__basic-memory__search_notes(
58+
query="key terms from the note",
59+
project="main"
60+
)
61+
62+
# Suggest relations based on:
63+
# - Shared topics or concepts
64+
# - Complementary content (problem/solution, question/answer)
65+
# - Sequential relationship (part 1, part 2)
66+
# - Hierarchical (parent concept, child detail)
67+
```
68+
69+
**Relation types to suggest:**
70+
- `relates-to` - General topical connection
71+
- `extends` - Builds upon or expands
72+
- `implements` - Realizes a concept
73+
- `depends-on` - Requires understanding of
74+
- `contradicts` - Presents alternative view
75+
- `learned-from` - Source of insight
76+
- `enables` - Makes something possible
77+
78+
### 3. Identify Similar/Duplicate Notes
79+
80+
Find notes that may cover the same topic.
81+
82+
```python
83+
# Search for notes with similar titles or content
84+
mcp__basic-memory__search_notes(
85+
query="topic keywords",
86+
project="main"
87+
)
88+
89+
# Compare results for overlap
90+
# Look for:
91+
# - Similar titles
92+
# - Overlapping observations
93+
# - Same tags
94+
# - Related timestamps (created around same time)
95+
```
96+
97+
**Actions for duplicates:**
98+
- Merge into a single comprehensive note
99+
- Link them with `supersedes` or `updates` relations
100+
- Differentiate by adding context about their distinct focus
101+
102+
### 4. Folder Organization Review
103+
104+
Analyze folder structure and suggest improvements.
105+
106+
```python
107+
# List directory structure
108+
mcp__basic-memory__list_directory(
109+
dir_name="/",
110+
depth=3,
111+
project="main"
112+
)
113+
114+
# Identify:
115+
# - Overcrowded folders
116+
# - Single-note folders
117+
# - Inconsistent naming
118+
# - Notes that might belong elsewhere
119+
```
120+
121+
**Organization suggestions:**
122+
- Group related notes into topic folders
123+
- Create subfolders for large categories
124+
- Suggest consistent naming conventions
125+
- Move misplaced notes
126+
127+
### 5. Tag Consistency
128+
129+
Review and normalize tags across notes.
130+
131+
```python
132+
# Search notes to analyze tag patterns
133+
mcp__basic-memory__search_notes(
134+
query="*",
135+
page_size=100,
136+
project="main"
137+
)
138+
139+
# Look for:
140+
# - Similar tags (architecture vs arch)
141+
# - Unused tags
142+
# - Over-used generic tags
143+
# - Missing tags on relevant notes
144+
```
145+
146+
**Tag improvements:**
147+
- Suggest tag standardization (pick one variant)
148+
- Propose new tags for common themes
149+
- Identify notes missing obvious tags
150+
151+
### 6. Create Index/Hub Notes
152+
153+
Generate notes that serve as navigation hubs for related topics.
154+
155+
```python
156+
# After identifying a cluster of related notes
157+
mcp__basic-memory__write_note(
158+
title="Architecture Decisions Index",
159+
content="""---
160+
title: Architecture Decisions Index
161+
type: index
162+
tags:
163+
- architecture
164+
- index
165+
---
166+
167+
# Architecture Decisions Index
168+
169+
A hub linking all architecture-related decisions and patterns.
170+
171+
## Decisions
172+
173+
- [[Database Selection Decision]]
174+
- [[API Design Patterns]]
175+
- [[Authentication Architecture]]
176+
177+
## Patterns
178+
179+
- [[Repository Pattern]]
180+
- [[Async Client Pattern]]
181+
182+
## Observations
183+
184+
- [index] Central hub for architecture knowledge #navigation
185+
186+
## Relations
187+
188+
- indexes [[Architecture]]
189+
""",
190+
folder="indexes",
191+
project="main"
192+
)
193+
```
194+
195+
### 7. Enrich Sparse Notes
196+
197+
Find notes lacking observations or structure and suggest improvements.
198+
199+
```python
200+
# Read a sparse note
201+
mcp__basic-memory__read_note(
202+
identifier="sparse-note",
203+
project="main"
204+
)
205+
206+
# If missing:
207+
# - Observations section → suggest categories
208+
# - Relations section → suggest links
209+
# - Tags → suggest relevant tags
210+
# - Context → suggest adding background
211+
```
212+
213+
## Organization Workflows
214+
215+
### Quick Health Check
216+
217+
A fast overview of knowledge base status:
218+
219+
1. Count total notes
220+
2. Identify orphan count
221+
3. List recently modified
222+
4. Check for obvious duplicates
223+
5. Report folder distribution
224+
225+
### Deep Organization Session
226+
227+
Thorough review and improvement:
228+
229+
1. **Audit phase** - Catalog all notes, identify issues
230+
2. **Orphan phase** - Address unlinked notes
231+
3. **Relation phase** - Suggest new connections
232+
4. **Duplicate phase** - Merge or differentiate similar notes
233+
5. **Structure phase** - Reorganize folders if needed
234+
6. **Index phase** - Create hub notes for major topics
235+
236+
### Topic-Focused Organization
237+
238+
Organize around a specific subject:
239+
240+
1. Find all notes related to topic
241+
2. Map existing relations
242+
3. Identify gaps in the topic graph
243+
4. Suggest new notes to fill gaps
244+
5. Create topic index note
245+
246+
## Best Practices
247+
248+
1. **Work incrementally** - Don't reorganize everything at once
249+
2. **Confirm before changing** - Always ask before moving/editing notes
250+
3. **Preserve permalinks** - Moving is okay, changing permalinks breaks links
251+
4. **Show the graph** - Help user visualize connections
252+
5. **Explain suggestions** - Say why a relation makes sense
253+
6. **Respect user's system** - Enhance their organization, don't impose a new one
254+
255+
## Example Conversations
256+
257+
**User:** "Help me organize my notes"
258+
259+
**Claude:**
260+
1. Runs health check on the knowledge base
261+
2. Reports: "You have 47 notes. I found 12 orphan notes and 3 potential duplicates."
262+
3. Asks: "Would you like to start by connecting the orphan notes, or review the duplicates first?"
263+
264+
**User:** "Find notes that should be linked to my API design note"
265+
266+
**Claude:**
267+
1. Reads the API design note
268+
2. Searches for related content
269+
3. Suggests: "I found 5 notes that could relate:
270+
- 'REST Best Practices' → relates-to
271+
- 'Authentication Flow' → implements
272+
- 'Rate Limiting Decision' → extends
273+
Would you like me to add any of these relations?"
274+
275+
**User:** "Are there any notes about similar topics?"
276+
277+
**Claude:**
278+
1. Analyzes note titles and content
279+
2. Identifies clusters of similar notes
280+
3. Reports: "I found these potential overlaps:
281+
- 'Auth Flow' and 'Authentication Design' cover similar ground
282+
- 'DB Schema v1' and 'DB Schema v2' might need a 'supersedes' relation
283+
Would you like to review any of these?"

0 commit comments

Comments
 (0)