memory-bank
Manage Memory Bank development logs in .ai_memory/. Use when starting a new feature, updating progress on current work, adding implementation log entries, or checking log status. Triggers on: (1) Starting new features/tasks, (2) "update memory bank" or "log progress", (3) Adding dated entries to implementation logs, (4) Checking Memory Bank status. Always prepends entries with YYYY-MM-DD dates, newest first.
When & Why to Use This Skill
The Memory Bank skill is a specialized context management tool designed to maintain persistent development logs for AI agents and developers. It automates the organization of project-specific knowledge within a `.ai_memory/` directory, utilizing chronological versioning and branch-based tracking. By ensuring that the most recent implementation details and research findings are always prioritized, it solves the challenge of context loss during long-term software development projects and facilitates seamless handoffs between AI sessions.
Use Cases
- Feature Branch Documentation: Automatically initialize a structured log file when starting a new feature, ensuring the problem statement and architectural goals are documented from the outset.
- Chronological Progress Tracking: Maintain a detailed implementation log where entries are prepended by date, allowing agents to quickly resume work by reading the most recent context first.
- Development State Auditing: Generate comprehensive status reports that summarize completed tasks, pending research, and the overall health of the project's memory bank.
- Context Preservation for AI Agents: Enable AI coding assistants to 'remember' technical decisions and research outcomes across different sessions by reading and updating standardized markdown logs.
| name | memory-bank |
|---|---|
| description | Manage Memory Bank development logs in .ai_memory/. Use when starting a new feature, updating progress on current work, adding implementation log entries, or checking log status. Triggers on: (1) Starting new features/tasks, (2) "update memory bank" or "log progress", (3) Adding dated entries to implementation logs, (4) Checking Memory Bank status. Always prepends entries with YYYY-MM-DD dates, newest first. |
Memory Bank
Manage development logs in .ai_memory/ with chronological date ordering.
Date Ordering Rule
All entries use YYYY-MM-DD format. Newer entries appear FIRST (top of section).
This ensures recent context takes precedence when reading logs.
Operations
1. Create New Log
When starting a new feature/task:
# Get current branch
BRANCH=$(git rev-parse --abbrev-ref HEAD 2>/dev/null || echo "unknown")
DATE=$(date +%Y-%m-%d)
- Check if log exists:
ls .ai_memory/ - Copy template:
.ai_memory/TEMPLATE.md→.ai_memory/<branch-name>.md - Fill Context section with current date and branch
- Complete Problem Statement
2. Update Existing Log
When adding progress to an existing log:
- Read current log
- Identify section to update (Research, Proposed Solution, Status)
- Add content while preserving structure
3. Add Implementation Entry
Add dated entries to the Implementation Log section. Always prepend (newest first):
## Implementation Log
### 2025-12-29 ← NEW (add here)
- [x] Completed task A
- [ ] Started task B
### 2025-12-28 ← OLDER (stays below)
- [x] Initial setup
Process:
- Get today's date:
date +%Y-%m-%d - Check if today's entry exists
- If exists: Add items to existing date section
- If not: Create new date header at TOP of Implementation Log
4. Show Status
Report current Memory Bank state:
Memory Bank Status
==================
File: .ai_memory/<name>.md
Last Updated: YYYY-MM-DD
Sections:
- [x] Context (complete)
- [x] Problem Statement (complete)
- [ ] Research (incomplete)
- [ ] Proposed Solution (incomplete)
Implementation Progress:
- 3 entries logged
- Latest: YYYY-MM-DD
Quick Reference
| Action | Command Pattern |
|---|---|
| Create | Copy TEMPLATE.md, fill Context |
| Update | Read → Modify section → Write |
| Add Entry | Prepend dated entry to Implementation Log |
| Status | List sections, check completion |
File Structure
.ai_memory/
├── README.md # Documentation
├── TEMPLATE.md # Copy for new logs
└── <branch>.md # Active development logs
Completion Report
After any operation, report:
Memory Bank: <operation>
========================
File: .ai_memory/<name>.md
Date: YYYY-MM-DD
Changes:
- <what was added/modified>
Next Steps:
- <suggested actions>