From akashicrecords
Safely deletes files from knowledge base after checking RULE.md permissions, scanning dependencies via grep/find, and obtaining user confirmation. Use for delete, remove, or trash requests.
How this skill is triggered — by the user, by Claude, or both
Slash command
/akashicrecords:delete-contentThe summary Claude sees in its skill listing — used to decide when to auto-load this skill
Generic file deletion Skill that checks RULE.md permissions and handles dependencies safely.
Generic file deletion Skill that checks RULE.md permissions and handles dependencies safely.
If user provides file path:
ls or ReadIf user provides topic/title only:
**/*keyword*.mdSearch strategies:
find . -name "*keyword*"grep -r "keyword" .Locate and read RULE.md:
Check for:
Example RULE.md deletion rules:
## Deletion Rules
- Deletions allowed with confirmation
- Check for cross-references before deleting
- Move to Archive/ subdirectory instead of permanent deletion
Search for cross-references:
grep -r "filename" .Categorize dependencies:
Severity assessment:
Present deletion summary:
⚠️ Delete confirmation required
File: [path to file]
Size: [file size]
Last modified: [timestamp]
Dependencies found:
- [file1.md] links to this file
- [file2.md] links to this file
(Total: X files reference this content)
RULE.md policy: [deletion policy summary]
Are you sure you want to delete this file?
- Yes, delete permanently
- Yes, move to archive (if RULE.md allows)
- No, cancel
- Show me the dependencies first
If user requests dependency review:
Based on RULE.md policy:
Permanent deletion:
rm [file path]
Archive instead:
# Create archive directory if not exists
mkdir -p Archive/
# Move file to archive
mv [file path] Archive/[filename]
Backup then delete:
# Create backup
cp [file path] [backup path]
# Then delete original
rm [file path]
Update README.md:
- YYYY-MM-DD: Removed filename.md
Update parent README.md if needed:
Handle cross-references:
Verify cleanup:
Confirm deletion complete:
✅ File deleted successfully
Deleted: [path to file]
Method: [permanent deletion / moved to archive / backed up then deleted]
README.md updated:
- [directory]/README.md
Dependencies handled:
- [X] files need attention (broken links)
- [List of affected files]
Recommendation: Review affected files to update/remove broken links
If archived instead:
✅ File archived successfully
Original: [original path]
Archived to: [archive path]
Archive method: [per RULE.md policy]
README.md updated:
- [directory]/README.md
- Archive/README.md
Note: File preserved in archive, not permanently deleted
If RULE.md specifies immutable:
## RULE.md says: "This directory is immutable - no deletions allowed"
Process:
If RULE.md requires archival instead:
## RULE.md says: "Move to Archive/ instead of deleting"
Process:
If user requests deleting multiple files:
User: "Delete all old notes from last year"
Process:
If user wants to delete entire directory:
User: "Delete the old-project directory"
Process:
If RULE.md specifies soft delete:
## RULE.md says: "Mark files as deleted in frontmatter instead of removing"
Process:
status: deleted[DELETED] filename.mdUser: "Delete the transformer note"
→ Search for file
→ No matches found
→ Report: "I couldn't find a file about transformers. Nothing to delete."
User: "Delete the transformer note"
→ Find 3 files with "transformer"
→ Present list: "I found 3 files. Which one to delete?"
→ User selects → Proceed
RULE.md says: "Immutable directory"
→ Warn: "RULE.md forbids deletions in this directory"
→ Explain reasoning
→ Ask for override confirmation
→ If confirmed: proceed with warning note
File has 50+ incoming references
→ Warn: "⚠️ HIGH IMPACT: 50+ files reference this content"
→ Show most critical dependencies
→ Recommend: "Consider archiving instead of deleting"
→ Require explicit "yes, delete anyway" confirmation
Bash rm command fails (permissions, file locked, etc.)
→ Report error clearly
→ Show exact error message
→ Suggest: "Check file permissions or if file is open in another program"
→ Offer alternatives: archive, rename, mark as deleted
Deletion successful but broken links remain
→ Report: "Deletion complete, but broken references detected in:"
→ List affected files
→ Offer: "Would you like me to update these files to remove broken links?"
→ If yes: update files to remove/fix references
This Skill automatically invokes the governance protocol:
Before deletion:
During deletion:
After deletion:
User: "Delete the old transformer draft"
Skill workflow:
Research/AI/2025-10-15-transformer-draft.mdrm Research/AI/2025-10-15-transformer-draft.mdUser: "Delete the 2024 work logs"
Skill workflow:
Work/WorkLog/Archive/2024/ if not existsmv Work/WorkLog/2024/* Work/WorkLog/Archive/2024/User: "Delete the core-concepts document"
Skill workflow:
Research/core-concepts.mdnpx claudepluginhub legacybridge-tech/claude-plugins --plugin akashicrecordsRemoves Knowledge Base files from CLAUDE.md tables and optionally deletes them from disk. Supports direct path or interactive selection, with cross-reference cleanup and index updates.
Performs extended vault cleanup: full audits, stale content scans, outdated references, content quality reviews, redundant tag removal, broken external link fixes, and template compliance checks.
Audits and selectively forgets stored Claude Code memories. Use when memory is large/uncurated, project state has shifted, or retrieval quality degraded.