sublation-os 1.0.1 โ†’ 1.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (31) hide show
  1. package/.claude/agents/sublation-os/implementation-verifier.md +16 -0
  2. package/.claude/agents/sublation-os/implementer.md +16 -0
  3. package/.claude/commands/sublation-os/address-comments.md +13 -0
  4. package/.claude/commands/sublation-os/consolidate-learnings.md +553 -0
  5. package/.claude/commands/sublation-os/implement-tasks.md +10 -0
  6. package/.claude/commands/sublation-os/investigate.md +14 -4
  7. package/.claude/commands/sublation-os/optimise.md +14 -0
  8. package/.claude/commands/sublation-os/review.md +18 -1
  9. package/.claude/commands/sublation-os/test-plan.md +19 -2
  10. package/.claude/skills/README.md +274 -0
  11. package/.claude/skills/auto-learn/SKILL.md +233 -0
  12. package/.cursor/commands/sublation-os/address-comments.md +74 -0
  13. package/.cursor/commands/sublation-os/commit-message.md +84 -0
  14. package/.cursor/commands/sublation-os/consolidate-learnings.md +553 -0
  15. package/.cursor/commands/sublation-os/create-tasks.md +254 -0
  16. package/.cursor/commands/sublation-os/implement-tasks.md +207 -0
  17. package/.cursor/commands/sublation-os/investigate.md +164 -0
  18. package/.cursor/commands/sublation-os/learn.md +131 -0
  19. package/.cursor/commands/sublation-os/optimise.md +108 -0
  20. package/.cursor/commands/sublation-os/plan-product.md +241 -0
  21. package/.cursor/commands/sublation-os/pr-description.md +15 -0
  22. package/.cursor/commands/sublation-os/recall.md +114 -0
  23. package/.cursor/commands/sublation-os/review.md +12 -0
  24. package/.cursor/commands/sublation-os/shape-spec.md +395 -0
  25. package/.cursor/commands/sublation-os/test-plan.md +12 -0
  26. package/.cursor/commands/sublation-os/write-spec.md +134 -0
  27. package/README.md +50 -13
  28. package/bin/install.js +103 -24
  29. package/package.json +4 -10
  30. package/.claude/agents/sublation-os/implementer-v2.md +0 -542
  31. /package/{.claude โ†’ .cursor}/commands/sublation-os/review-v2.md +0 -0
@@ -2,11 +2,28 @@
2
2
  description: Generate a structured test plan from a spec or code sample
3
3
  ---
4
4
 
5
+ You are creating a structured test plan for a feature or code sample.
6
+
7
+ ## Test Plan Output Format
8
+
5
9
  ## ๐ŸŽฏ Objective
6
10
  {Feature or behavior to test}
7
11
 
8
12
  ## ๐Ÿงช Test Scenarios
9
- - {Given/When/Then}
13
+ - {Given/When/Then format}
10
14
 
11
15
  ## ๐Ÿงฐ Edge Cases
12
- - {Corner cases or stress conditions}
16
+ - {Corner cases or stress conditions}
17
+
18
+ ## Automatic Learning Capture
19
+
20
+ After creating the test plan, **automatically invoke `auto-learn` skill** if you discovered:
21
+ - Codebase-specific testing patterns that should be followed
22
+ - Edge cases unique to this project's domain
23
+ - Testing anti-patterns found in existing tests
24
+ - Test setup patterns that work well in this codebase
25
+
26
+ **When to invoke auto-learn:**
27
+ - Found testing convention specific to this codebase โ†’ Document it
28
+ - Discovered common edge cases for this domain โ†’ Capture them
29
+ - Identified effective test pattern for this stack โ†’ Learn it
@@ -0,0 +1,274 @@
1
+ # Sublation-OS Skills
2
+
3
+ This directory contains **skills** that are automatically invoked by Claude during development workflows.
4
+
5
+ ## โœ… Correct Skill Structure
6
+
7
+ Skills in Claude Code must follow this structure:
8
+
9
+ ```
10
+ .claude/skills/
11
+ โ””โ”€โ”€ skill-name/ # Directory for each skill
12
+ โ””โ”€โ”€ SKILL.md # Main skill file (MUST be uppercase!)
13
+ ```
14
+
15
+ ### Required SKILL.md Format
16
+
17
+ Each `SKILL.md` file MUST start with YAML frontmatter:
18
+
19
+ ```yaml
20
+ ---
21
+ name: skill-name # lowercase, hyphens only, max 64 chars
22
+ description: What the skill does and when Claude should use it (max 1024 chars)
23
+ ---
24
+ ```
25
+
26
+ **The `description` field is critical** - Claude uses this to decide when to invoke the skill.
27
+
28
+ ---
29
+
30
+ ## Skills vs. Commands
31
+
32
+ | Type | Invocation | Purpose | Example |
33
+ |------|------------|---------|---------|
34
+ | **Skill** | Claude decides (model-invoked) | Automatic behavior | `auto-learn` skill |
35
+ | **Command** | User types `/command` | Explicit request | `/sublation-os:learn` |
36
+
37
+ **Key difference:** Skills activate based on context; commands require explicit invocation.
38
+
39
+ ---
40
+
41
+ ## Available Skills
42
+
43
+ ### ๐Ÿง  auto-learn
44
+
45
+ **Location**: `.claude/skills/auto-learn/SKILL.md`
46
+
47
+ **Purpose**: Automatically capture codebase-specific learnings
48
+
49
+ **When invoked by Claude**:
50
+ - After completing complex implementations
51
+ - After fixing bugs that reveal patterns
52
+ - After discovering codebase conventions
53
+ - After code reviews that find recurring issues
54
+
55
+ **Integration points**:
56
+ - `implementer-v2` agent - Invokes after implementation reflection
57
+ - `/sublation-os:review-v2` - Invokes when finding recurring patterns
58
+ - `/sublation-os:investigate` - Invokes after root cause analysis
59
+ - And 7 other commands/agents
60
+
61
+ **Output**: Creates entries in `.sublation-os/memory/{category}-lessons.md`
62
+
63
+ **How to invoke**: Don't! Claude invokes it automatically when appropriate.
64
+
65
+ **Manual alternative**: Use `/sublation-os:learn` for explicit control
66
+
67
+ ---
68
+
69
+ ## How Skills Work
70
+
71
+ ### Discovery
72
+
73
+ Skills are automatically discovered from:
74
+ 1. **Project skills**: `.claude/skills/` (shared with team via git)
75
+ 2. **Personal skills**: `~/.claude/skills/` (available across all your projects)
76
+ 3. **Plugin skills**: Installed via plugin marketplace
77
+
78
+ ### Invocation
79
+
80
+ When you make a request, Claude:
81
+ 1. Reads skill descriptions
82
+ 2. Determines which skill (if any) is relevant
83
+ 3. Invokes the skill automatically
84
+ 4. Executes the skill's instructions
85
+
86
+ You'll see: `<command-message>The "skill-name" skill is loading</command-message>`
87
+
88
+ ### Progressive Disclosure
89
+
90
+ Claude only reads SKILL.md when the skill is invoked, managing context efficiently.
91
+
92
+ ---
93
+
94
+ ## Creating New Skills
95
+
96
+ ### Step 1: Create Directory Structure
97
+
98
+ ```bash
99
+ mkdir -p .claude/skills/my-skill
100
+ ```
101
+
102
+ ### Step 2: Create SKILL.md
103
+
104
+ ```bash
105
+ cat > .claude/skills/my-skill/SKILL.md << 'EOF'
106
+ ---
107
+ name: my-skill
108
+ description: Clear explanation of what this skill does and when to use it
109
+ ---
110
+
111
+ You are [role description].
112
+
113
+ ## Instructions
114
+
115
+ [Detailed instructions for the skill]
116
+
117
+ ## Steps
118
+
119
+ [Step-by-step workflow]
120
+ EOF
121
+ ```
122
+
123
+ ### Step 3: Write a Good Description
124
+
125
+ The description field determines **when Claude invokes the skill**. Make it:
126
+ - **Specific**: What exact scenarios trigger this?
127
+ - **Clear**: What capability does this provide?
128
+ - **Actionable**: When should Claude use this vs. other skills?
129
+ - **Concise**: Max 1024 characters
130
+
131
+ **Good description:**
132
+ ```yaml
133
+ description: Automatically capture codebase-specific learnings after implementations, bug fixes, or code reviews. Invoked when discovering non-obvious patterns, fixing mistakes, or finding recurring issues (3+ occurrences). Saves structured entries to .sublation-os/memory/.
134
+ ```
135
+
136
+ **Bad description:**
137
+ ```yaml
138
+ description: Helps with learning stuff
139
+ ```
140
+
141
+ ### Step 4: Test the Skill
142
+
143
+ Work normally and see if Claude invokes your skill appropriately. Check that:
144
+ - It triggers in the right scenarios
145
+ - It doesn't trigger too often (be selective)
146
+ - The output is useful
147
+
148
+ ---
149
+
150
+ ## Skill Design Principles
151
+
152
+ ### โœ… DO:
153
+
154
+ - Design for automatic, silent invocation
155
+ - Keep output minimal (users didn't explicitly ask)
156
+ - Be selective about when to invoke
157
+ - Follow consistent formats with related commands
158
+ - Document integration points clearly
159
+ - Use clear, specific descriptions
160
+
161
+ ### โŒ DON'T:
162
+
163
+ - Require user interaction or confirmation
164
+ - Produce verbose output
165
+ - Invoke for trivial or routine work
166
+ - Duplicate work that commands already do
167
+ - Create side effects users wouldn't expect
168
+ - Use vague descriptions
169
+
170
+ ---
171
+
172
+ ## Comparison: Skills vs. Slash Commands
173
+
174
+ ### When to Create a Skill
175
+
176
+ Use a skill when:
177
+ - Claude should decide when to use it (automatic)
178
+ - It enhances ongoing work without explicit invocation
179
+ - The trigger conditions are clear and detectable
180
+ - It provides capabilities Claude needs autonomously
181
+
182
+ **Examples**: auto-learn, auto-test, auto-format
183
+
184
+ ### When to Create a Slash Command
185
+
186
+ Use a slash command when:
187
+ - Users should explicitly control when it runs
188
+ - It's a distinct workflow users initiate
189
+ - The user needs to provide specific inputs
190
+ - It's not always relevant to ongoing work
191
+
192
+ **Examples**: /learn (manual control), /review (explicit request), /investigate (user-triggered)
193
+
194
+ ---
195
+
196
+ ## Future Skill Ideas
197
+
198
+ Potential skills to implement:
199
+
200
+ - **auto-test** - Automatically run relevant tests after code changes
201
+ - **auto-document** - Generate inline documentation for complex functions
202
+ - **auto-refactor-suggest** - Suggest refactoring when complexity is high
203
+ - **auto-security-check** - Scan for common security issues
204
+ - **auto-performance-profile** - Identify performance bottlenecks
205
+
206
+ ---
207
+
208
+ ## File Structure Reference
209
+
210
+ ```
211
+ .claude/skills/
212
+ โ”œโ”€โ”€ README.md # This file
213
+ โ””โ”€โ”€ auto-learn/ # Skill directory
214
+ โ””โ”€โ”€ SKILL.md # Main skill file (uppercase!)
215
+ ```
216
+
217
+ **Additional optional files per skill:**
218
+ ```
219
+ skill-name/
220
+ โ”œโ”€โ”€ SKILL.md # Required
221
+ โ”œโ”€โ”€ reference.md # Optional reference docs
222
+ โ”œโ”€โ”€ scripts/ # Optional scripts
223
+ โ””โ”€โ”€ templates/ # Optional templates
224
+ ```
225
+
226
+ ---
227
+
228
+ ## Related Documentation
229
+
230
+ - **Commands**: `.claude/commands/sublation-os/` - User-invoked slash commands
231
+ - **Agents**: `.claude/agents/sublation-os/` - Specialized implementation agents
232
+ - **Memory**: `.sublation-os/memory/` - Where auto-learn saves learnings
233
+ - **Skills Guide**: `docs/skills-guide.md` - Comprehensive user guide
234
+ - **Integration Map**: `docs/auto-learn-integration.md` - All integration points
235
+
236
+ ---
237
+
238
+ ## Troubleshooting
239
+
240
+ ### Skill Not Appearing
241
+
242
+ **Problem**: Skill not being invoked by Claude
243
+
244
+ **Check**:
245
+ 1. Is SKILL.md uppercase? (`SKILL.md` not `skill.md`)
246
+ 2. Is it in the right location? (`.claude/skills/skill-name/SKILL.md`)
247
+ 3. Does it have valid YAML frontmatter with `name` and `description`?
248
+ 4. Is the description clear about when to invoke?
249
+
250
+ ### Skill Invoked Too Often
251
+
252
+ **Problem**: Skill triggers too frequently
253
+
254
+ **Solution**: Make the description more specific about trigger conditions
255
+
256
+ ### Skill Never Invoked
257
+
258
+ **Problem**: Claude never uses the skill
259
+
260
+ **Solution**: Broaden the description to include more scenarios, or make trigger conditions clearer
261
+
262
+ ---
263
+
264
+ ## Official Documentation
265
+
266
+ For more information, see:
267
+ - [Claude Code Skills Documentation](https://code.claude.com/docs/en/skills)
268
+ - [GitHub: Anthropic Skills Repository](https://github.com/anthropics/skills)
269
+
270
+ ---
271
+
272
+ **Current Skills**: 1 (auto-learn)
273
+
274
+ **Status**: โœ… Properly configured and operational
@@ -0,0 +1,233 @@
1
+ ---
2
+ name: auto-learn
3
+ description: Automatically capture codebase-specific learnings after implementations, bug fixes, code reviews, or investigations. Invoked when discovering non-obvious patterns, fixing mistakes, finding recurring issues (3+ occurrences), or uncovering architectural insights. Saves structured entries to .sublation-os/memory/ for future sessions.
4
+ ---
5
+
6
+ You are automatically capturing a learning moment from recent work to help future Claude sessions work more effectively on this codebase.
7
+
8
+ ## When This Skill is Invoked
9
+
10
+ This skill should be proactively invoked by Claude (not the user) after:
11
+ - โœ… Completing a complex implementation with non-obvious solutions
12
+ - โœ… Fixing a bug that revealed a pattern or gotcha
13
+ - โœ… Discovering codebase-specific conventions or patterns
14
+ - โœ… Making a mistake and correcting it
15
+ - โœ… Finding performance optimizations specific to this codebase
16
+ - โœ… Completing code review that identified recurring issues
17
+ - โœ… Investigating errors that revealed architectural insights
18
+ - โœ… Using a tool or approach that worked particularly well (or poorly)
19
+
20
+ **Do NOT invoke for:**
21
+ - Trivial changes or routine work
22
+ - General programming knowledge (not codebase-specific)
23
+ - Changes already documented in standards
24
+ - Learning that doesn't provide future value
25
+
26
+ ---
27
+
28
+ ## Your Task
29
+
30
+ Analyze the recent work in this session and automatically generate a structured learning entry.
31
+
32
+ ### Step 0: Should This Be Captured?
33
+
34
+ Before proceeding, verify this learning is worth capturing:
35
+
36
+ **Ask yourself:**
37
+ 1. Is this specific to THIS codebase (not general programming advice)?
38
+ 2. Would future Claude sessions benefit from knowing this?
39
+ 3. Is this a mistake/pattern that could be repeated?
40
+ 4. Does this reveal something non-obvious about the architecture?
41
+
42
+ If you answer "no" to all questions, **STOP** - don't create a learning entry.
43
+
44
+ If YES to any question, proceed to capture the learning.
45
+
46
+ ---
47
+
48
+ ## Step 1: Analyze Recent Context
49
+
50
+ Examine the recent conversation to identify:
51
+
52
+ **What happened?**
53
+ - What task was being performed?
54
+ - What approach was initially tried?
55
+ - What correction or insight occurred?
56
+ - What was learned that wasn't obvious?
57
+
58
+ **Why does this matter?**
59
+ - How does this affect future work?
60
+ - What mistake does this prevent?
61
+ - What pattern should be followed?
62
+
63
+ **Evidence:**
64
+ - What files or code demonstrate this?
65
+ - Where can future sessions see the pattern?
66
+
67
+ ---
68
+
69
+ ## Step 2: Determine Category
70
+
71
+ Automatically classify this learning into one category:
72
+
73
+ - **backend** - APIs, databases, services, server-side logic, data access
74
+ - **frontend** - UI components, state management, user interactions, styling
75
+ - **testing** - Testing strategies, frameworks, mocking, test organization
76
+ - **architecture** - System design, patterns, project structure, cross-cutting concerns
77
+ - **general** - Workflow, tooling, debugging, anything that doesn't fit above
78
+
79
+ Target file: `.sublation-os/memory/{category}-lessons.md`
80
+
81
+ ---
82
+
83
+ ## Step 3: Read Existing File
84
+
85
+ Read the target category file to:
86
+ 1. Determine the next entry number (check for "## Entry {N}")
87
+ 2. Ensure consistent formatting
88
+ 3. Verify this isn't a duplicate learning
89
+
90
+ If file doesn't exist, start with Entry 1 and create the file with the header template (see Step 5).
91
+
92
+ ---
93
+
94
+ ## Step 4: Generate Learning Entry
95
+
96
+ Create the entry using this **EXACT** format:
97
+
98
+ ```markdown
99
+ ## Entry {N} - {YYYY-MM-DD HH:mm}
100
+
101
+ ### ๐Ÿง  Context
102
+ {1-2 sentences: What happened? What was the task or correction?}
103
+
104
+ ### ๐Ÿ“˜ Lesson
105
+ {Core principle or insight as a durable rule. Be specific to this codebase when possible.}
106
+
107
+ ### โš™๏ธ Application
108
+ {How should this affect future reasoning? Be actionable and specific. Include:
109
+ - Which files/services/patterns this applies to
110
+ - What to check before making similar changes
111
+ - What tools or approaches work best}
112
+
113
+ ### ๐Ÿงฉ Example
114
+ {OPTIONAL: Concrete before/after or do/don't example. Include code if relevant.}
115
+
116
+ ### ๐Ÿท๏ธ Tags
117
+ {Comma-separated tags for searchability: e.g., "Work service, bulk operations, async patterns, testing"}
118
+
119
+ ---
120
+
121
+ ```
122
+
123
+ **Quality Standards:**
124
+ - โœ… **Be specific**: Reference actual files, classes, methods
125
+ - โœ… **Be actionable**: Provide concrete guidance
126
+ - โœ… **Be contextual**: Tie to this codebase, not general advice
127
+ - โœ… **Be valuable**: Focus on non-obvious insights
128
+
129
+ **Examples of GOOD learnings:**
130
+ - "When adding bulk operations to Work service, use BulkUpdate domain entity pattern (WorkRepository.cs:245-280) rather than individual update loops"
131
+ - "AR service uses .NET Framework 4.8 - cannot use C# 9+ features like records"
132
+ - "Multi-tenant queries MUST include TenantPermaKey filter - caused cross-tenant leak in WorkRepository.GetWorkItems"
133
+
134
+ **Examples of BAD learnings:**
135
+ - "Use async/await for better performance" (too generic)
136
+ - "Follow SOLID principles" (not actionable)
137
+ - "Write tests" (not specific to this codebase)
138
+
139
+ ---
140
+
141
+ ## Step 5: Append to Memory File
142
+
143
+ ### If file exists:
144
+ Append the new entry to the end of `.sublation-os/memory/{category}-lessons.md`
145
+
146
+ ### If file doesn't exist (new category):
147
+ Create the file with this header first:
148
+
149
+ ```markdown
150
+ # {Category} Lessons
151
+
152
+ This file contains durable learnings from Claude Code sessions to help future sessions work more effectively on this codebase.
153
+
154
+ **Category**: {Category}
155
+
156
+ **Search tips:**
157
+ - Use Ctrl+F to find specific services or patterns
158
+ - Look for ๐Ÿท๏ธ Tags sections to find related lessons
159
+ - Entries are chronological - recent ones are at the bottom
160
+
161
+ ---
162
+
163
+ ```
164
+
165
+ Then append the new entry.
166
+
167
+ ---
168
+
169
+ ## Step 6: Silently Update Index (Optional)
170
+
171
+ If this is a significant learning or introduces new tags:
172
+
173
+ 1. Read `.sublation-os/memory/index.md`
174
+ 2. Check if the new tags exist in the tag index
175
+ 3. If not, add them to the appropriate section
176
+ 4. Update entry count statistics
177
+
178
+ **Note:** Only update index for significant learnings. Don't update for every entry.
179
+
180
+ ---
181
+
182
+ ## Step 7: Silent Confirmation
183
+
184
+ After capturing the learning, OUTPUT a brief confirmation to the conversation:
185
+
186
+ ```
187
+ ๐Ÿ’ก Captured learning: {brief one-line description}
188
+ โ†’ Saved as Entry {N} in {category}-lessons.md
189
+ โ†’ Tags: {key tags}
190
+ ```
191
+
192
+ **Keep it minimal** - this is automatic, not a user-requested action.
193
+
194
+ ---
195
+
196
+ ## Integration Points
197
+
198
+ This skill works alongside:
199
+
200
+ - **`/sublation-os:learn`** - User-invoked version for explicit learning capture
201
+ - **`implementer-v2`** - Should invoke this after implementation reflection
202
+ - **`/sublation-os:investigate`** - Should invoke this after root cause analysis
203
+ - **`/sublation-os:review-v2`** - Should invoke this after finding recurring patterns
204
+ - **Any agent** - Can invoke when discovering codebase-specific insights
205
+
206
+ ---
207
+
208
+ ## Decision Tree: Should I Invoke Auto-Learn?
209
+
210
+ ```
211
+ Did I just...
212
+ โ”œโ”€ Fix a bug that revealed a codebase gotcha? โ†’ YES, invoke
213
+ โ”œโ”€ Implement something using a non-obvious pattern? โ†’ YES, invoke
214
+ โ”œโ”€ Correct an initial mistake with a better approach? โ†’ YES, invoke
215
+ โ”œโ”€ Discover a codebase-specific convention? โ†’ YES, invoke
216
+ โ”œโ”€ Find an architecture insight while exploring? โ†’ YES, invoke
217
+ โ”œโ”€ Use a tool/approach that worked particularly well? โ†’ YES, invoke
218
+ โ”œโ”€ Complete a routine task following known patterns? โ†’ NO, skip
219
+ โ”œโ”€ Apply general programming knowledge? โ†’ NO, skip
220
+ โ””โ”€ Make a trivial change? โ†’ NO, skip
221
+ ```
222
+
223
+ ---
224
+
225
+ ## Notes
226
+
227
+ - **Be selective**: Don't capture every small thing, only valuable insights
228
+ - **Be specific**: Always reference concrete files and line numbers when possible
229
+ - **Be quiet**: Keep confirmation minimal since this is automatic
230
+ - **Be consistent**: Use the exact format from /learn command
231
+ - **Be valuable**: Focus on things that will help future sessions
232
+
233
+ This skill builds institutional knowledge automatically, making Claude more effective over time.
@@ -0,0 +1,74 @@
1
+ ---
2
+ description: Fetch PR comments and address them systematically
3
+ model: sonnet
4
+ ---
5
+
6
+ # Address PR Comments
7
+
8
+ You are tasked with fetching all comments from the current pull request and addressing them systematically.
9
+
10
+ ## Instructions
11
+
12
+ 1. **Fetch PR Information**
13
+ - Use `gh pr view --json number` to get the current PR number
14
+ - If no PR exists for the current branch, inform the user and stop
15
+
16
+ 2. **Fetch PR Comments**
17
+ - Use `gh api repos/:owner/:repo/pulls/{PR_NUMBER}/comments` to get review comments
18
+ - Use `gh pr view --json comments` to get general PR comments
19
+ - Parse and organize comments by file and line number where applicable
20
+
21
+ 3. **Analyze Comments**
22
+ - Read each comment carefully
23
+ - Categorize comments by type:
24
+ - Code changes required
25
+ - Questions to clarify
26
+ - Suggestions for improvement
27
+ - Informational/acknowledgments
28
+ - Prioritize actionable comments
29
+
30
+ 4. **Create Action Plan**
31
+ - Use the TodoWrite tool to create a structured task list with:
32
+ - Each actionable comment as a separate task
33
+ - File path and line number references where applicable
34
+ - Brief description of what needs to be addressed
35
+ - Group related comments together
36
+
37
+ 5. **Address Each Comment**
38
+ - Work through the todo list systematically
39
+ - For each comment:
40
+ - Read the relevant code using serena tools (find_symbol, get_symbols_overview)
41
+ - Make the requested changes or improvements
42
+ - If clarification is needed, note it for the user
43
+ - Mark the todo as completed once addressed
44
+
45
+ 6. **Verify Changes**
46
+ - After addressing all comments, run relevant tests
47
+ - Ensure code builds successfully
48
+ - Review the changes to confirm all comments have been addressed
49
+
50
+ 7. **Summary Report**
51
+ - Provide a summary of:
52
+ - Total comments found
53
+ - Comments addressed
54
+ - Comments requiring user input/clarification
55
+ - Any comments skipped and why
56
+ - Suggest next steps (e.g., respond to reviewers, push changes)
57
+
58
+ ## Guidelines
59
+
60
+ - Be thorough but efficient - use serena's symbolic tools to read only necessary code
61
+ - If a comment is unclear, ask the user for clarification before making changes
62
+ - Respect the reviewer's intent - if unsure, err on the side of asking
63
+ - Follow the project's coding standards and patterns (check CLAUDE.md context)
64
+ - Test your changes after addressing comments when possible
65
+ - For .NET code, ensure you follow Clean Architecture and DDD principles
66
+
67
+ ## Output Format
68
+
69
+ Provide clear feedback after each step:
70
+ - "Found X comments on PR #Y"
71
+ - "Created todo list with Z actionable items"
72
+ - "Addressing comment: {comment summary}"
73
+ - "Completed: {what was changed}"
74
+ - Final summary with all changes made
@@ -0,0 +1,84 @@
1
+ ---
2
+ description: Generate a commit message based on code changes
3
+ model: haiku
4
+ ---
5
+
6
+ # Generate Commit Message
7
+
8
+ You are tasked with analyzing the current code changes and generating an appropriate commit message following the project's conventions.
9
+
10
+ ## Instructions
11
+
12
+ 1. **Analyze Changes**
13
+ - Run `git status` to see modified/added/deleted files
14
+ - Run `git diff --staged` to see staged changes (if any)
15
+ - Run `git diff` to see unstaged changes
16
+ - Identify the scope and nature of changes
17
+
18
+ 2. **Review Recent Commits**
19
+ - Run `git log --oneline -10` to see recent commit message patterns
20
+ - Note the project's commit message format (appears to use conventional commits)
21
+
22
+ 3. **Categorize Changes**
23
+ - Determine the change type:
24
+ - `feat` - New feature
25
+ - `fix` - Bug fix
26
+ - `refactor` - Code refactoring
27
+ - `test` - Adding or updating tests
28
+ - `docs` - Documentation changes
29
+ - `chore` - Build, dependencies, or tooling
30
+ - `perf` - Performance improvements
31
+ - `style` - Code style/formatting
32
+ - Identify the affected service/pillar (e.g., work, contacts, accounting)
33
+
34
+ 4. **Generate Commit Message**
35
+ Format: `{type}({scope}): {description}`
36
+
37
+ Examples from this repo:
38
+ - `feat(work): Add bulk reset status endpoint`
39
+ - `fix(contacts): Resolve email validation issue`
40
+ - `refactor(accounting): Simplify invoice calculation logic`
41
+
42
+ Guidelines:
43
+ - Keep description concise (50-72 chars for first line)
44
+ - Use imperative mood ("Add" not "Added" or "Adds")
45
+ - Focus on WHAT and WHY, not HOW
46
+ - Be specific but brief
47
+ - No period at the end of the subject line
48
+ - If changes span multiple files/areas, focus on the primary purpose
49
+
50
+ 5. **Add Body (Optional)**
51
+ - If the change is complex, add a blank line and detailed body
52
+ - Explain WHY the change was made
53
+ - Reference any tickets/issues: `Refs: OTT-852`
54
+ - Break lines at 72 characters
55
+
56
+ 6. **Output Format**
57
+ Provide the commit message in a code block that can be easily copied:
58
+
59
+ ```
60
+ {type}({scope}): {description}
61
+
62
+ {optional body}
63
+
64
+ {optional footer with refs/breaking changes}
65
+ ```
66
+
67
+ ## Example Output
68
+
69
+ ```
70
+ feat(work): Add GetBulkResetStatus endpoint with workTemplatePermaKey support
71
+
72
+ Enable querying bulk reset status by either bulkUpdatePermaKey or
73
+ workTemplatePermaKey. Updated validation to ensure exactly one key
74
+ is provided. Added comprehensive test coverage.
75
+
76
+ Refs: OTT-852
77
+ ```
78
+
79
+ ## Notes
80
+
81
+ - If no changes are staged, analyze unstaged changes
82
+ - If changes are trivial (whitespace, comments), suggest a simpler message
83
+ - If changes span multiple concerns, recommend splitting into separate commits
84
+ - Follow the existing patterns in the codebase (check recent git log)