mirror of
https://github.com/harivansh-afk/claude-continual-learning.git
synced 2026-04-15 06:04:40 +00:00
continual learning setup
This commit is contained in:
commit
443592d6c7
8 changed files with 578 additions and 0 deletions
73
commands/retrospective.md
Normal file
73
commands/retrospective.md
Normal file
|
|
@ -0,0 +1,73 @@
|
|||
---
|
||||
description: Analyze the current session and extract learnings to memory
|
||||
allowed-tools: Read, Edit
|
||||
---
|
||||
|
||||
# Session Retrospective
|
||||
|
||||
Analyze this coding session and extract valuable learnings to improve future sessions.
|
||||
|
||||
## Your Task
|
||||
|
||||
### 1. Review What Happened This Session
|
||||
|
||||
Reflect on the session:
|
||||
- What code was written or modified?
|
||||
- What problems were solved?
|
||||
- What approaches were tried (both successful and unsuccessful)?
|
||||
- Were there any surprises or unexpected behaviors?
|
||||
|
||||
### 2. Identify Learnings
|
||||
|
||||
Extract insights in these categories:
|
||||
|
||||
**Patterns (what worked well)**:
|
||||
- Successful approaches that should be reused
|
||||
- Code patterns that solved problems effectively
|
||||
- Workflows that were efficient
|
||||
|
||||
**Failures (what to avoid)**:
|
||||
- Approaches that didn't work
|
||||
- Bugs that were encountered and their root causes
|
||||
- Time wasted on wrong paths
|
||||
- Assumptions that turned out to be wrong
|
||||
|
||||
**Edge Cases**:
|
||||
- Tricky scenarios discovered
|
||||
- Non-obvious behavior found
|
||||
- Boundary conditions that matter
|
||||
|
||||
**Technology Insights**:
|
||||
- Framework/library-specific knowledge gained
|
||||
- API quirks discovered
|
||||
- Performance considerations learned
|
||||
|
||||
### 3. Update learnings.md
|
||||
|
||||
Edit `.claude/skills/codebase-agent/learnings.md` and add new entries under the appropriate sections.
|
||||
|
||||
Use this format for each entry:
|
||||
|
||||
```markdown
|
||||
### [Short Descriptive Title]
|
||||
- **Context**: When does this apply?
|
||||
- **Learning**: What is the insight?
|
||||
- **Example**: (optional) Code snippet or concrete example
|
||||
- **Session**: [Date or brief session description]
|
||||
```
|
||||
|
||||
### 4. Quality Guidelines
|
||||
|
||||
Be selective about what to add:
|
||||
- **Add** genuinely useful, project-specific insights
|
||||
- **Skip** general programming knowledge (things any developer would know)
|
||||
- **Skip** one-time fixes that won't recur
|
||||
- **Avoid** duplicating existing entries
|
||||
- **Merge** with existing entries if they're related
|
||||
|
||||
## Output
|
||||
|
||||
Summarize:
|
||||
1. How many learnings were added (and to which categories)
|
||||
2. Brief description of the most important insights
|
||||
3. Any patterns emerging across sessions
|
||||
73
commands/setup-agent.md
Normal file
73
commands/setup-agent.md
Normal file
|
|
@ -0,0 +1,73 @@
|
|||
---
|
||||
description: Analyze codebase and set up the learning agent (run once after install)
|
||||
allowed-tools: Read, Grep, Glob, Edit
|
||||
---
|
||||
|
||||
# Initial Codebase Assessment
|
||||
|
||||
You are setting up the continual learning agent for this codebase. This is a one-time setup that analyzes the project and configures the agent.
|
||||
|
||||
## Your Task
|
||||
|
||||
### 1. Analyze the Codebase Structure
|
||||
|
||||
Explore the project to understand:
|
||||
- **Directory structure**: What are the key directories and their purposes?
|
||||
- **Tech stack**: What languages, frameworks, and libraries are used?
|
||||
- **Configuration files**: Find package.json, tsconfig.json, pyproject.toml, Cargo.toml, etc.
|
||||
- **Build tools**: How is the project built and tested?
|
||||
- **Entry points**: Where does the application start?
|
||||
|
||||
### 2. Discover Conventions
|
||||
|
||||
Look for patterns in the existing code:
|
||||
- **Code style**: Indentation, naming conventions, file organization
|
||||
- **Architectural patterns**: MVC, component-based, microservices, etc.
|
||||
- **Testing patterns**: How are tests structured? What testing frameworks?
|
||||
- **Documentation patterns**: How is code documented?
|
||||
|
||||
### 3. Update the Skill File
|
||||
|
||||
Edit `.claude/skills/codebase-agent/SKILL.md` and replace the `## Codebase Context` section with your findings:
|
||||
|
||||
```markdown
|
||||
## Codebase Context
|
||||
|
||||
### Architecture
|
||||
[Brief overview of the architecture]
|
||||
|
||||
### Tech Stack
|
||||
- **Language(s)**: [e.g., TypeScript, Python]
|
||||
- **Framework(s)**: [e.g., React, FastAPI]
|
||||
- **Key Libraries**: [important dependencies]
|
||||
|
||||
### Key Directories
|
||||
- `src/` - [purpose]
|
||||
- `tests/` - [purpose]
|
||||
- [etc.]
|
||||
|
||||
### Build & Test Commands
|
||||
- Build: `[command]`
|
||||
- Test: `[command]`
|
||||
- Lint: `[command]`
|
||||
|
||||
### Conventions
|
||||
- [Convention 1]
|
||||
- [Convention 2]
|
||||
```
|
||||
|
||||
### 4. Initialize Learnings
|
||||
|
||||
Edit `.claude/skills/codebase-agent/learnings.md` and add any initial observations:
|
||||
- Obvious patterns you notice in the code
|
||||
- Potential edge cases visible in the structure
|
||||
- Tech stack insights that would be helpful to remember
|
||||
|
||||
## Output
|
||||
|
||||
After completing the assessment:
|
||||
1. Summarize what you learned about the codebase
|
||||
2. Confirm the skill file has been updated
|
||||
3. Note any initial learnings added
|
||||
|
||||
The agent is now ready for coding. Future sessions will automatically accumulate more learnings!
|
||||
Loading…
Add table
Add a link
Reference in a new issue