Skip to content

Commit ba76286

Browse files
committed
chore(skill): add replan skill for iterative design and critique process
1 parent 1496cb9 commit ba76286

1 file changed

Lines changed: 97 additions & 0 deletions

File tree

.claude/skills/replan/SKILL.md

Lines changed: 97 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,97 @@
1+
---
2+
name: replan
3+
description: Iterative deep planning with critiques and alternatives. Use when facing complex design decisions requiring thorough analysis.
4+
allowed-tools: Read, Glob, Grep, WebSearch, WebFetch
5+
---
6+
7+
# Replan
8+
9+
You are going to **replan** - an iterative process of designing, critiquing, and refining a plan.
10+
11+
## Required Reading First
12+
13+
Before any work, you MUST read:
14+
15+
- [CLAUDE.md](CLAUDE.md)
16+
- [docs/SIMPLE-DESIGN.md](docs/SIMPLE-DESIGN.md)
17+
- [docs/TDD.md](docs/TDD.md)
18+
19+
## Process
20+
21+
### 1. Understand & Clarify
22+
23+
- Read relevant code, documentation, and constraints
24+
- State any assumptions you're making
25+
- Ask clarifying questions before proceeding
26+
27+
### 2. Initial Plan
28+
29+
Design your first approach, considering requirements and existing solutions.
30+
31+
### 3. Critique
32+
33+
Generate thorough critiques of your plan:
34+
35+
**General design:**
36+
37+
- Does it balance simplicity with good engineering?
38+
- Is it maintainable, testable, DRY, scalable?
39+
- Scrutinize for "hand-wavy" aspects - don't assume how things work, study the code
40+
- For novel libraries/APIs, validate with web searches
41+
- Note uncertainties as risks
42+
43+
**Project-specific:**
44+
45+
- Does this preserve backwards compatibility for 500+ downstream consumers?
46+
- Does this affect ExifTool process pool performance or startup latency?
47+
- Does this handle timezone edge cases correctly (DST transitions, GPS inference, UTC deltas)?
48+
- Does this introduce new dependencies? Are they justified for a library this widely used?
49+
- Will this work cross-platform (Linux, macOS, Windows)?
50+
- Does this respect the auto-generated nature of Tags.ts (changes belong in mktags, not manual edits)?
51+
- Does the approach fail fast on errors rather than silently falling back to defaults?
52+
- Does this interact correctly with batch-cluster's process management?
53+
54+
### 4. Alternatives
55+
56+
Brainstorm alternatives based on critiques. Goals:
57+
58+
- Simplify the plan
59+
- Reduce complexity and risk
60+
- Improve code quality and maintainability
61+
62+
### 5. Develop Best Alternative
63+
64+
Select the most promising alternative and develop it fully.
65+
66+
### 6. Iterate
67+
68+
Repeat steps 3-5 at least **three times**, asking for user feedback at each iteration.
69+
70+
### 7. Final Plan
71+
72+
Assemble the best features from all iterations into a robust final plan.
73+
74+
## Output Format
75+
76+
For each iteration, present options with pros/cons:
77+
78+
### Option A: [Name]
79+
80+
[Description]
81+
82+
**Pros:** ...
83+
**Cons:** ...
84+
**Risks:** ...
85+
86+
### Recommendation
87+
88+
[Which option and why, per SIMPLE-DESIGN.md principles]
89+
90+
## Guidelines
91+
92+
- Follow Kent Beck's Four Rules of Simple Design as defined in docs/SIMPLE-DESIGN.md (in priority order: passes tests, reveals intention, no duplication, fewest elements, no bogus guardrails)
93+
- Consider coupling, cohesion, testability
94+
- Be honest about tradeoffs
95+
- Ask questions - don't guess
96+
- No mocks - plan for integration tests with real ExifTool and actual image files
97+
- Use `??` not `||`, `!= null` not `!`, standard `node:` imports

0 commit comments

Comments
 (0)