learn
Process inbox summaries and update system knowledge. Curates role "Right Now" sections, appends "Recent Context", updates central docs. Intelligent curation, not just appending.
When & Why to Use This Skill
The Learn skill is a sophisticated system learning tool designed to bridge the gap between short-term session interactions and long-term agent memory. It intelligently processes session summaries to update system knowledge, curating 'Right Now' priorities and maintaining a rolling 30-day 'Recent Context' log. By automating the curation of role-specific documentation and managing Git-based knowledge updates, it ensures that AI agents remain perfectly aligned with the latest project decisions, workflows, and operational changes without manual intervention.
Use Cases
- Dynamic Role Evolution: Automatically update agent role descriptions and 'Right Now' focus areas based on the outcomes of recent brainstorming or development sessions.
- Automated Knowledge Base Maintenance: Transform informal session summaries into structured markdown documentation, ensuring the system's central docs reflect the current state of the project.
- Context Window Optimization: Prevent context drift and clutter by intelligently pruning stale information and highlighting only the most relevant current priorities for the agent.
- Decision Audit Trails: Maintain a timestamped, auto-pruned history of key decisions and workflow changes, providing a reliable 'Recent Context' for future task execution.
- Git-Integrated Learning: Streamline system updates by automatically creating branches and Pull Requests for knowledge changes, allowing for human-in-the-loop review of AI learning.
| name | learn |
|---|---|
| description | Process inbox summaries and update system knowledge. Curates role "Right Now" sections, appends "Recent Context", updates central docs. Intelligent curation, not just appending. |
| allowed-tools | Read, Edit, Bash, Write |
Learn (System Learning)
Intelligently update roles and docs based on session summaries.
When to Activate
- User says: "learn", "update roles"
- After compressing sessions
- When inbox has session summaries
Approach
OLD: Append bullets to logs NEW: Intelligent curation
Role structure:
- What This Role Does (rarely changes)
- Right Now ← CURATE (what's currently relevant)
- Recent Context ← APPEND (timestamped, last 30 days)
- How This Role Operates (rarely changes)
Process
1. Read Inbox
ls inbox/session-summaries/
cat inbox/session-summaries/*.md
2. Analyze Changes
Extract from summaries:
- Decisions made
- Tools/workflows built
- Role activity
- Context changes
Categorize:
- Right Now: What's newly relevant for ongoing work
- Recent Context: Timestamped decisions (auto-prune > 30 days)
3. Create Branch
git checkout -b learning-$(date +%Y-%m-%d)
4. Update Roles
For each affected role:
A. Read Current Role
cat roles/[role-file].md
B. Curate "Right Now"
This is CURATION, not appending:
- Read existing "Right Now"
- Add newly relevant context
- Remove stale/no-longer-relevant items
- Keep tight (5-10 bullets max)
C. Append "Recent Context"
Add timestamped entry at top:
## Recent Context (Last 30 Days)
**YYYY-MM-DD:** [Summary]
- Key point 1
- Key point 2
[...existing entries...]
Auto-prune if > 10 entries.
D. Update "Last Updated"
5. Commit and PR
git add roles/*.md
git commit -m "System learning: [summary]"
git push -u origin learning-$(date +%Y-%m-%d)
gh pr create --title "System Learning $(date +%Y-%m-%d)" --body "..."
git checkout main
6. Report
System learning complete.
Processed: [N] session summaries
Roles updated: [list]
Branch: learning-YYYY-MM-DD
PR: #[number]
Next: Review and merge PR.
Curation Guidelines
"Right Now" = what's relevant:
- Shapes how role operates TODAY
- Would need to know this to do role's job
- NOT just recent - could be weeks old but still relevant
"Recent Context" = what happened:
- Timestamped decisions
- Links to details if needed
- Auto-prune oldest when > 10 entries