specweave 0.3.7 → 0.3.9
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.
- package/CLAUDE.md +91 -28
- package/README.md +22 -6
- package/dist/cli/commands/init.d.ts.map +1 -1
- package/dist/cli/commands/init.js +16 -0
- package/dist/cli/commands/init.js.map +1 -1
- package/dist/utils/generate-skills-index.d.ts +24 -0
- package/dist/utils/generate-skills-index.d.ts.map +1 -0
- package/dist/utils/generate-skills-index.js +410 -0
- package/dist/utils/generate-skills-index.js.map +1 -0
- package/dist/utils/model-selection.d.ts +75 -0
- package/dist/utils/model-selection.d.ts.map +1 -0
- package/dist/utils/model-selection.js +204 -0
- package/dist/utils/model-selection.js.map +1 -0
- package/package.json +2 -1
- package/src/adapters/copilot/README.md +41 -1
- package/src/adapters/cursor/README.md +43 -1
- package/src/agents/pm/AGENT.md +3 -1
- package/src/commands/specweave.do.md +31 -8
- package/src/hooks/post-task-completion.sh +29 -2
- package/src/skills/SKILLS-INDEX.md +436 -0
- package/src/skills/brownfield-onboarder/SKILL.md +63 -60
- package/src/skills/increment-planner/SKILL.md +41 -11
- package/src/templates/AGENTS.md.template +274 -2
|
@@ -92,15 +92,18 @@ When installing SpecWeave into an existing project:
|
|
|
92
92
|
```
|
|
93
93
|
Project-specific content → SpecWeave folders:
|
|
94
94
|
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
95
|
+
# Internal Documentation (strategic, team-only)
|
|
96
|
+
Architecture details → .specweave/docs/internal/architecture/existing-system.md
|
|
97
|
+
Technology stack → .specweave/docs/internal/architecture/tech-stack.md
|
|
98
|
+
Business rules → .specweave/docs/internal/strategy/business-rules.md
|
|
99
|
+
Team workflows → .specweave/docs/internal/processes/team-workflows.md
|
|
100
|
+
Deployment process → .specweave/docs/internal/processes/deployment.md
|
|
101
|
+
Domain knowledge → .specweave/increments/{####-name}/domain/{domain}.md
|
|
102
|
+
|
|
103
|
+
# Public Documentation (user-facing, can be published)
|
|
104
|
+
Project conventions → .specweave/docs/public/guides/project-conventions.md
|
|
105
|
+
API conventions → .specweave/docs/public/guides/api-conventions.md
|
|
106
|
+
Code style → .specweave/docs/public/guides/code-style.md
|
|
104
107
|
```
|
|
105
108
|
|
|
106
109
|
**Only add to CLAUDE.md**: High-level project summary (1-2 paragraphs max)
|
|
@@ -252,13 +255,13 @@ We use a microservices architecture:
|
|
|
252
255
|
- Database (PostgreSQL) - shared across services
|
|
253
256
|
```
|
|
254
257
|
|
|
255
|
-
**Destination**:
|
|
258
|
+
**Destination**: `.specweave/docs/internal/architecture/existing-system.md`
|
|
256
259
|
|
|
257
260
|
**CLAUDE.md addition**:
|
|
258
261
|
```markdown
|
|
259
262
|
## Project-Specific Architecture
|
|
260
263
|
|
|
261
|
-
See [Existing System Architecture](.specweave/docs/architecture/existing-system.md) for complete microservices architecture.
|
|
264
|
+
See [Existing System Architecture](.specweave/docs/internal/architecture/existing-system.md) for complete microservices architecture.
|
|
262
265
|
```
|
|
263
266
|
|
|
264
267
|
---
|
|
@@ -278,7 +281,7 @@ See [Existing System Architecture](.specweave/docs/architecture/existing-system.
|
|
|
278
281
|
- React components: `{Name}Component.tsx` suffix
|
|
279
282
|
```
|
|
280
283
|
|
|
281
|
-
**Destination**: `.specweave/docs/guides/project-conventions.md`
|
|
284
|
+
**Destination**: `.specweave/docs/public/guides/project-conventions.md`
|
|
282
285
|
|
|
283
286
|
**CLAUDE.md addition**: None (standard conventions, no need to clutter CLAUDE.md)
|
|
284
287
|
|
|
@@ -301,13 +304,13 @@ See [Existing System Architecture](.specweave/docs/architecture/existing-system.
|
|
|
301
304
|
6. Rollback via GitHub Actions if needed
|
|
302
305
|
```
|
|
303
306
|
|
|
304
|
-
**Destination**: `.specweave/docs/
|
|
307
|
+
**Destination**: `.specweave/docs/internal/processes/deployment.md`
|
|
305
308
|
|
|
306
309
|
**CLAUDE.md addition**:
|
|
307
310
|
```markdown
|
|
308
311
|
## Deployment
|
|
309
312
|
|
|
310
|
-
See [Deployment Guide](.specweave/docs/
|
|
313
|
+
See [Deployment Guide](.specweave/docs/internal/processes/deployment.md).
|
|
311
314
|
```
|
|
312
315
|
|
|
313
316
|
---
|
|
@@ -328,7 +331,7 @@ See [Deployment Guide](.specweave/docs/guides/deployment.md).
|
|
|
328
331
|
- Insurance verification required before booking
|
|
329
332
|
```
|
|
330
333
|
|
|
331
|
-
**Destination**:
|
|
334
|
+
**Destination**: `.specweave/docs/internal/strategy/appointments/business-rules.md`
|
|
332
335
|
|
|
333
336
|
**CLAUDE.md addition**: None (specifications are source of truth)
|
|
334
337
|
|
|
@@ -352,7 +355,7 @@ See [Deployment Guide](.specweave/docs/guides/deployment.md).
|
|
|
352
355
|
- Monitoring: Grafana, Prometheus
|
|
353
356
|
```
|
|
354
357
|
|
|
355
|
-
**Destination**: `.specweave/docs/architecture/tech-stack.md`
|
|
358
|
+
**Destination**: `.specweave/docs/internal/architecture/tech-stack.md`
|
|
356
359
|
|
|
357
360
|
**CLAUDE.md addition**:
|
|
358
361
|
```markdown
|
|
@@ -360,7 +363,7 @@ See [Deployment Guide](.specweave/docs/guides/deployment.md).
|
|
|
360
363
|
|
|
361
364
|
Next.js 14 + Node.js 20 + PostgreSQL 16 + Hetzner Cloud
|
|
362
365
|
|
|
363
|
-
See [Tech Stack Details](.specweave/docs/architecture/tech-stack.md).
|
|
366
|
+
See [Tech Stack Details](.specweave/docs/internal/architecture/tech-stack.md).
|
|
364
367
|
```
|
|
365
368
|
|
|
366
369
|
---
|
|
@@ -382,7 +385,7 @@ All APIs follow REST conventions:
|
|
|
382
385
|
- Versioning: /api/v1, /api/v2
|
|
383
386
|
```
|
|
384
387
|
|
|
385
|
-
**Destination**: `.specweave/docs/guides/api-conventions.md`
|
|
388
|
+
**Destination**: `.specweave/docs/public/guides/api-conventions.md`
|
|
386
389
|
|
|
387
390
|
**CLAUDE.md addition**: None (guide covers it)
|
|
388
391
|
|
|
@@ -418,7 +421,7 @@ function useCustomAuth() {
|
|
|
418
421
|
}
|
|
419
422
|
```
|
|
420
423
|
|
|
421
|
-
**Action**: Extract to `.specweave/docs/guides/authentication.md` (project-specific pattern)
|
|
424
|
+
**Action**: Extract to `.specweave/docs/public/guides/authentication.md` (project-specific pattern)
|
|
422
425
|
|
|
423
426
|
---
|
|
424
427
|
|
|
@@ -435,12 +438,12 @@ function useCustomAuth() {
|
|
|
435
438
|
**Domain**: Healthcare, Patient Management, Provider Scheduling
|
|
436
439
|
|
|
437
440
|
### Quick Links
|
|
438
|
-
- [Domain Model](
|
|
439
|
-
- [Existing System Architecture](.specweave/docs/architecture/existing-system.md)
|
|
440
|
-
- [Tech Stack](.specweave/docs/architecture/tech-stack.md)
|
|
441
|
-
- [Business Rules](
|
|
442
|
-
- [Deployment Guide](.specweave/docs/
|
|
443
|
-
- [Project Conventions](.specweave/docs/guides/project-conventions.md)
|
|
441
|
+
- [Domain Model](.specweave/increments/####-name/domain/appointments/domain-model.md)
|
|
442
|
+
- [Existing System Architecture](.specweave/docs/internal/architecture/existing-system.md)
|
|
443
|
+
- [Tech Stack](.specweave/docs/internal/architecture/tech-stack.md)
|
|
444
|
+
- [Business Rules](.specweave/docs/internal/strategy/appointments/business-rules.md)
|
|
445
|
+
- [Deployment Guide](.specweave/docs/internal/processes/deployment.md)
|
|
446
|
+
- [Project Conventions](.specweave/docs/public/guides/project-conventions.md)
|
|
444
447
|
|
|
445
448
|
**Note**: All project-specific details are in linked documents. This keeps CLAUDE.md concise.
|
|
446
449
|
|
|
@@ -505,22 +508,22 @@ if (exists("specifications/modules/appointments/domain-model.md")) {
|
|
|
505
508
|
I found the following project-specific content in your backup CLAUDE.md:
|
|
506
509
|
|
|
507
510
|
📦 Domain Model (Healthcare Appointments)
|
|
508
|
-
→
|
|
511
|
+
→ .specweave/increments/####-name/domain/appointments/domain-model.md
|
|
509
512
|
|
|
510
513
|
🏗️ Microservices Architecture
|
|
511
|
-
→ .specweave/docs/architecture/existing-system.md
|
|
514
|
+
→ .specweave/docs/internal/architecture/existing-system.md
|
|
512
515
|
|
|
513
516
|
🛠️ Tech Stack (Next.js + Node.js + PostgreSQL)
|
|
514
|
-
→ .specweave/docs/architecture/tech-stack.md
|
|
517
|
+
→ .specweave/docs/internal/architecture/tech-stack.md
|
|
515
518
|
|
|
516
519
|
📋 Business Rules (Booking policies)
|
|
517
|
-
→
|
|
520
|
+
→ .specweave/docs/internal/strategy/appointments/business-rules.md
|
|
518
521
|
|
|
519
522
|
🔧 Project Conventions (Naming, code style)
|
|
520
|
-
→ .specweave/docs/guides/project-conventions.md
|
|
523
|
+
→ .specweave/docs/public/guides/project-conventions.md
|
|
521
524
|
|
|
522
525
|
🚀 Deployment Process (CI/CD workflow)
|
|
523
|
-
→ .specweave/docs/
|
|
526
|
+
→ .specweave/docs/internal/processes/deployment.md
|
|
524
527
|
|
|
525
528
|
📝 CLAUDE.md Update
|
|
526
529
|
→ Add 12-line project summary with links
|
|
@@ -551,11 +554,11 @@ Proceed with merge? (y/n)
|
|
|
551
554
|
|
|
552
555
|
## Files Created (Essential Only)
|
|
553
556
|
|
|
554
|
-
1. ✅ `.specweave/docs/architecture/core-architecture.md` (120 lines)
|
|
555
|
-
2. ✅ `.specweave/docs/architecture/tech-stack.md` (80 lines)
|
|
556
|
-
3. ✅ `.specweave/docs/architecture/critical-patterns.md` (100 lines)
|
|
557
|
-
4. ✅ `.specweave/docs/guides/project-conventions.md` (90 lines)
|
|
558
|
-
5. ✅ `.specweave/docs/
|
|
557
|
+
1. ✅ `.specweave/docs/internal/architecture/core-architecture.md` (120 lines)
|
|
558
|
+
2. ✅ `.specweave/docs/internal/architecture/tech-stack.md` (80 lines)
|
|
559
|
+
3. ✅ `.specweave/docs/internal/architecture/critical-patterns.md` (100 lines)
|
|
560
|
+
4. ✅ `.specweave/docs/public/guides/project-conventions.md` (90 lines)
|
|
561
|
+
5. ✅ `.specweave/docs/internal/processes/deployment.md` (70 lines)
|
|
559
562
|
|
|
560
563
|
**Total**: 5 files, 460 lines (essential content)
|
|
561
564
|
|
|
@@ -573,11 +576,11 @@ Proceed with merge? (y/n)
|
|
|
573
576
|
|
|
574
577
|
| Content Type | Lines | Status | Destination |
|
|
575
578
|
|--------------|-------|--------|-------------|
|
|
576
|
-
| Core Architecture | 120 | ✅ Merged | .specweave/docs/architecture/ |
|
|
577
|
-
| Tech Stack | 80 | ✅ Merged | .specweave/docs/architecture/ |
|
|
578
|
-
| Critical Patterns | 100 | ✅ Merged | .specweave/docs/architecture/ |
|
|
579
|
-
| Conventions | 90 | ✅ Merged | .specweave/docs/guides/ |
|
|
580
|
-
| Deployment | 70 | ✅ Merged | .specweave/docs/
|
|
579
|
+
| Core Architecture | 120 | ✅ Merged | .specweave/docs/internal/architecture/ |
|
|
580
|
+
| Tech Stack | 80 | ✅ Merged | .specweave/docs/internal/architecture/ |
|
|
581
|
+
| Critical Patterns | 100 | ✅ Merged | .specweave/docs/internal/architecture/ |
|
|
582
|
+
| Conventions | 90 | ✅ Merged | .specweave/docs/public/guides/ |
|
|
583
|
+
| Deployment | 70 | ✅ Merged | .specweave/docs/internal/processes/ |
|
|
581
584
|
| **CLAUDE.md** | **10** | ✅ **Updated** | **Root** |
|
|
582
585
|
| **Subtotal Merged** | **470** | | |
|
|
583
586
|
| | | | |
|
|
@@ -662,12 +665,12 @@ The following content remains in the backup and will be extracted when you work
|
|
|
662
665
|
|
|
663
666
|
## Files Created
|
|
664
667
|
|
|
665
|
-
1. ✅
|
|
666
|
-
2. ✅ `.specweave/docs/architecture/existing-system.md` (320 lines)
|
|
667
|
-
3. ✅ `.specweave/docs/architecture/tech-stack.md` (180 lines)
|
|
668
|
-
4. ✅
|
|
669
|
-
5. ✅ `.specweave/docs/guides/project-conventions.md` (200 lines)
|
|
670
|
-
6. ✅ `.specweave/docs/
|
|
668
|
+
1. ✅ `.specweave/increments/####-name/domain/appointments/domain-model.md` (450 lines)
|
|
669
|
+
2. ✅ `.specweave/docs/internal/architecture/existing-system.md` (320 lines)
|
|
670
|
+
3. ✅ `.specweave/docs/internal/architecture/tech-stack.md` (180 lines)
|
|
671
|
+
4. ✅ `.specweave/docs/internal/strategy/appointments/business-rules.md` (280 lines)
|
|
672
|
+
5. ✅ `.specweave/docs/public/guides/project-conventions.md` (200 lines)
|
|
673
|
+
6. ✅ `.specweave/docs/internal/processes/deployment.md` (150 lines)
|
|
671
674
|
|
|
672
675
|
**Total**: 6 files, 1,580 lines
|
|
673
676
|
|
|
@@ -685,12 +688,12 @@ The following content remains in the backup and will be extracted when you work
|
|
|
685
688
|
|
|
686
689
|
| Content Type | Lines | Destination |
|
|
687
690
|
|--------------|-------|-------------|
|
|
688
|
-
| Domain Model | 450 |
|
|
689
|
-
| Architecture | 320 | .specweave/docs/architecture/ |
|
|
690
|
-
| Tech Stack | 180 | .specweave/docs/architecture/ |
|
|
691
|
-
| Business Rules | 280 |
|
|
692
|
-
| Conventions | 200 | .specweave/docs/guides/ |
|
|
693
|
-
| Deployment | 150 | .specweave/docs/
|
|
691
|
+
| Domain Model | 450 | .specweave/increments/####-name/domain/ |
|
|
692
|
+
| Architecture | 320 | .specweave/docs/internal/architecture/ |
|
|
693
|
+
| Tech Stack | 180 | .specweave/docs/internal/architecture/ |
|
|
694
|
+
| Business Rules | 280 | .specweave/docs/internal/strategy/ |
|
|
695
|
+
| Conventions | 200 | .specweave/docs/public/guides/ |
|
|
696
|
+
| Deployment | 150 | .specweave/docs/internal/processes/ |
|
|
694
697
|
| **CLAUDE.md** | **12** | **Root** |
|
|
695
698
|
|
|
696
699
|
**Result**: 99.2% of content distributed to appropriate folders, not bloating CLAUDE.md
|
|
@@ -709,7 +712,7 @@ The following content remains in the backup and will be extracted when you work
|
|
|
709
712
|
|
|
710
713
|
## Next Steps
|
|
711
714
|
|
|
712
|
-
1. ✅ Review generated files in `.specweave/docs/` and
|
|
715
|
+
1. ✅ Review generated files in `.specweave/docs/internal/` and `.specweave/docs/public/`
|
|
713
716
|
2. ✅ SpecWeave uses auto-detection
|
|
714
717
|
3. ✅ Run `npm run docs:dev` to preview documentation
|
|
715
718
|
4. ✅ Create features from specifications: `specweave plan-feature {name}`
|
|
@@ -779,12 +782,12 @@ Proceed with merge? (y/n)
|
|
|
779
782
|
✅ Merge complete!
|
|
780
783
|
|
|
781
784
|
Created:
|
|
782
|
-
1.
|
|
783
|
-
2. .specweave/docs/architecture/existing-system.md
|
|
784
|
-
3. .specweave/docs/architecture/tech-stack.md
|
|
785
|
-
4.
|
|
786
|
-
5. .specweave/docs/guides/project-conventions.md
|
|
787
|
-
6. .specweave/docs/
|
|
785
|
+
1. .specweave/increments/####-name/domain/appointments/domain-model.md
|
|
786
|
+
2. .specweave/docs/internal/architecture/existing-system.md
|
|
787
|
+
3. .specweave/docs/internal/architecture/tech-stack.md
|
|
788
|
+
4. .specweave/docs/internal/strategy/appointments/business-rules.md
|
|
789
|
+
5. .specweave/docs/public/guides/project-conventions.md
|
|
790
|
+
6. .specweave/docs/internal/processes/deployment.md
|
|
788
791
|
|
|
789
792
|
Updated:
|
|
790
793
|
- CLAUDE.md (added 12-line project summary)
|
|
@@ -426,7 +426,12 @@ created: YYYY-MM-DD
|
|
|
426
426
|
|
|
427
427
|
### Step 7: Generate tasks.md
|
|
428
428
|
|
|
429
|
-
**Purpose**: Break down implementation into executable steps.
|
|
429
|
+
**Purpose**: Break down implementation into executable steps with intelligent model selection.
|
|
430
|
+
|
|
431
|
+
**CRITICAL**: Use the model detection utility to assign optimal models to tasks:
|
|
432
|
+
```typescript
|
|
433
|
+
import { detectModelForTask, formatModelHint } from '../utils/model-selection';
|
|
434
|
+
```
|
|
430
435
|
|
|
431
436
|
**Structure**:
|
|
432
437
|
```markdown
|
|
@@ -439,27 +444,28 @@ created: YYYY-MM-DD
|
|
|
439
444
|
- `[US#]`: User story reference
|
|
440
445
|
- `[ ]`: Not started
|
|
441
446
|
- `[x]`: Completed
|
|
447
|
+
- Model hints: ⚡ haiku (fast), 🧠 sonnet (thinking), 💎 opus (critical)
|
|
442
448
|
|
|
443
449
|
## Phase 1: Setup and Foundation
|
|
444
450
|
|
|
445
|
-
- [ ] [T001] [P] Initialize project structure
|
|
446
|
-
- [ ] [T002] [P] Setup testing framework
|
|
447
|
-
- [ ] [T003] Install dependencies
|
|
451
|
+
- [ ] [T001] [P] ⚡ haiku - Initialize project structure
|
|
452
|
+
- [ ] [T002] [P] ⚡ haiku - Setup testing framework
|
|
453
|
+
- [ ] [T003] ⚡ haiku - Install dependencies
|
|
448
454
|
|
|
449
455
|
## Phase 2: Core Implementation
|
|
450
456
|
|
|
451
457
|
### US1: [User Story Title] (P1)
|
|
452
458
|
|
|
453
|
-
- [ ] [T004] Write test for [component]
|
|
454
|
-
- [ ] [T005] Implement [component] in src/path/file.ts
|
|
455
|
-
- [ ] [T006] [P] Create [another component]
|
|
456
|
-
- [ ] [T007] Integrate components
|
|
457
|
-
- [ ] [T008] Verify US1 acceptance criteria
|
|
459
|
+
- [ ] [T004] ⚡ haiku - Write test for [component]
|
|
460
|
+
- [ ] [T005] ⚡ haiku - Implement [component] in src/path/file.ts
|
|
461
|
+
- [ ] [T006] [P] ⚡ haiku - Create [another component]
|
|
462
|
+
- [ ] [T007] 🧠 sonnet - Integrate components (requires decision-making)
|
|
463
|
+
- [ ] [T008] ⚡ haiku - Verify US1 acceptance criteria
|
|
458
464
|
|
|
459
465
|
### US2: [User Story Title] (P2)
|
|
460
466
|
|
|
461
|
-
- [ ] [T009] Write test for [feature]
|
|
462
|
-
- [ ] [T010] Implement [feature]
|
|
467
|
+
- [ ] [T009] ⚡ haiku - Write test for [feature]
|
|
468
|
+
- [ ] [T010] 🧠 sonnet - Implement [feature] (complex logic)
|
|
463
469
|
...
|
|
464
470
|
|
|
465
471
|
## Phase 3: Testing and Validation
|
|
@@ -488,6 +494,30 @@ T051 depends on T050 (integration must pass first)
|
|
|
488
494
|
- Exact file paths specified
|
|
489
495
|
- Parallelizable tasks marked `[P]`
|
|
490
496
|
- Dependencies explicitly stated
|
|
497
|
+
- **Model hints for cost optimization**: Each task labeled with optimal model
|
|
498
|
+
- ⚡ haiku: Clear instructions, mechanical work (3x faster, 20x cheaper)
|
|
499
|
+
- 🧠 sonnet: Complex decisions, creative problem-solving
|
|
500
|
+
- 💎 opus: Critical architecture (rare, use sparingly)
|
|
501
|
+
|
|
502
|
+
**Model Selection Guidelines**:
|
|
503
|
+
1. **Use Haiku (⚡) when**:
|
|
504
|
+
- Task has specific file path (e.g., `src/components/LoginForm.tsx`)
|
|
505
|
+
- Acceptance criteria are detailed (3+ specific points)
|
|
506
|
+
- Implementation approach is defined in plan.md
|
|
507
|
+
- Simple CRUD operations, configuration, setup tasks
|
|
508
|
+
|
|
509
|
+
2. **Use Sonnet (🧠) when**:
|
|
510
|
+
- Task requires architecture decisions
|
|
511
|
+
- Multiple valid approaches exist
|
|
512
|
+
- Integration between components
|
|
513
|
+
- Complex business logic
|
|
514
|
+
- Error handling strategies
|
|
515
|
+
|
|
516
|
+
3. **Use Opus (💎) when**:
|
|
517
|
+
- Critical system architecture
|
|
518
|
+
- Security-critical decisions
|
|
519
|
+
- Performance-critical algorithms
|
|
520
|
+
- Novel problem-solving required
|
|
491
521
|
|
|
492
522
|
### Step 8: Generate tests.md
|
|
493
523
|
|
|
@@ -70,6 +70,127 @@ SpecWeave uses role-based development. When working on tasks, adopt the appropri
|
|
|
70
70
|
|
|
71
71
|
---
|
|
72
72
|
|
|
73
|
+
## 🎯 CRITICAL: Skills Are Your Expert Manuals (Read First!)
|
|
74
|
+
|
|
75
|
+
**MANDATORY**: Before starting ANY implementation task, check for relevant skills.
|
|
76
|
+
|
|
77
|
+
### What Are Skills?
|
|
78
|
+
|
|
79
|
+
Skills are **specialized expert manuals** that contain:
|
|
80
|
+
- Proven workflows for specific tasks
|
|
81
|
+
- SpecWeave conventions and best practices
|
|
82
|
+
- Required files to read and tools to use
|
|
83
|
+
- Step-by-step instructions
|
|
84
|
+
- Examples and test cases
|
|
85
|
+
|
|
86
|
+
**There are 34+ skills available** organized into categories:
|
|
87
|
+
- **Framework Core**: increment-planner, context-loader, context-optimizer
|
|
88
|
+
- **External Integrations**: jira-sync, ado-sync, github-sync
|
|
89
|
+
- **Architecture & Design**: diagrams-architect, design-system-architect
|
|
90
|
+
- **Development**: frontend, nodejs-backend, python-backend, nextjs, dotnet-backend
|
|
91
|
+
- **Quality & Testing**: increment-quality-judge, e2e-playwright
|
|
92
|
+
- **Infrastructure**: hetzner-provisioner, cost-optimizer
|
|
93
|
+
- **Documentation**: docusaurus, figma-to-code, figma-designer
|
|
94
|
+
- **Orchestration**: role-orchestrator, skill-router, spec-driven-brainstorming
|
|
95
|
+
|
|
96
|
+
### Progressive Disclosure Pattern (How to Use Skills)
|
|
97
|
+
|
|
98
|
+
**STEP 1: Discovery (Always Start Here)**
|
|
99
|
+
|
|
100
|
+
Before starting ANY task, read the skills index:
|
|
101
|
+
|
|
102
|
+
```bash
|
|
103
|
+
cat .claude/skills/SKILLS-INDEX.md
|
|
104
|
+
```
|
|
105
|
+
|
|
106
|
+
This single file contains ALL available skills with their activation keywords. **This is your first stop for every task.**
|
|
107
|
+
|
|
108
|
+
**STEP 2: Matching**
|
|
109
|
+
|
|
110
|
+
Look for skills whose "Activates for" keywords match your current task:
|
|
111
|
+
|
|
112
|
+
| Your Task | Relevant Skill | Keywords |
|
|
113
|
+
|-----------|---------------|----------|
|
|
114
|
+
| "Plan a new feature for user auth" | `increment-planner` | "feature planning", "create increment" |
|
|
115
|
+
| "Sync this to JIRA" | `jira-sync` | "JIRA sync", "create JIRA issue" |
|
|
116
|
+
| "Create architecture diagram" | `diagrams-architect` | "architecture diagram", "C4 diagram" |
|
|
117
|
+
| "Implement React component" | `frontend` | "React", "components", "UI" |
|
|
118
|
+
| "Deploy to cloud" | `hetzner-provisioner` or `cost-optimizer` | "deploy", "hosting", "infrastructure" |
|
|
119
|
+
| "Quality check" | `increment-quality-judge` | "validate quality", "quality check" |
|
|
120
|
+
| "E2E test" | `e2e-playwright` | "E2E test", "browser automation" |
|
|
121
|
+
| "Generate docs site" | `docusaurus` | "documentation site", "docs" |
|
|
122
|
+
|
|
123
|
+
**STEP 3: Load Full Skill**
|
|
124
|
+
|
|
125
|
+
Once you've identified 1-3 relevant skills, load their full documentation:
|
|
126
|
+
|
|
127
|
+
```bash
|
|
128
|
+
cat .claude/skills/{skill-name}/SKILL.md
|
|
129
|
+
```
|
|
130
|
+
|
|
131
|
+
**STEP 4: Execute Workflow**
|
|
132
|
+
|
|
133
|
+
Follow the skill's instructions precisely:
|
|
134
|
+
- Read required files listed in skill
|
|
135
|
+
- Use recommended tools
|
|
136
|
+
- Follow step-by-step workflow
|
|
137
|
+
- Apply SpecWeave best practices
|
|
138
|
+
|
|
139
|
+
### Why This Matters (Token Savings + Quality)
|
|
140
|
+
|
|
141
|
+
**Scenario**: User asks to plan a new feature
|
|
142
|
+
|
|
143
|
+
**Without skills** (bad):
|
|
144
|
+
```
|
|
145
|
+
❌ Read entire .specweave/docs/ folder (50k tokens)
|
|
146
|
+
❌ Guess at SpecWeave conventions
|
|
147
|
+
❌ Create inconsistent increment structure
|
|
148
|
+
❌ Miss context-manifest.yaml (no token savings)
|
|
149
|
+
❌ Reinvent workflow from scratch
|
|
150
|
+
Result: High token cost, inconsistent output
|
|
151
|
+
```
|
|
152
|
+
|
|
153
|
+
**With skills** (good):
|
|
154
|
+
```
|
|
155
|
+
✅ Read SKILLS-INDEX.md (2k tokens)
|
|
156
|
+
✅ Match "plan feature" → increment-planner skill
|
|
157
|
+
✅ Load increment-planner SKILL.md (3k tokens)
|
|
158
|
+
✅ Follow proven workflow with templates
|
|
159
|
+
✅ Create proper context-manifest.yaml (70% token savings)
|
|
160
|
+
Result: 5k tokens vs 50k = 90% savings + higher quality
|
|
161
|
+
```
|
|
162
|
+
|
|
163
|
+
### Skills vs Agents (What's the Difference?)
|
|
164
|
+
|
|
165
|
+
**Skills = Capabilities (WHAT you can do)**
|
|
166
|
+
- increment-planner: Creates feature plans
|
|
167
|
+
- jira-sync: Syncs with external tools
|
|
168
|
+
- diagrams-architect: Creates diagrams
|
|
169
|
+
- **Use skills for workflows and procedures**
|
|
170
|
+
|
|
171
|
+
**Agents = Roles (WHO you become)**
|
|
172
|
+
- PM: Product manager perspective
|
|
173
|
+
- Architect: Technical design perspective
|
|
174
|
+
- DevOps: Infrastructure perspective
|
|
175
|
+
- **Use agents when you need to adopt a specific role/perspective**
|
|
176
|
+
|
|
177
|
+
### For Non-Claude Code Users
|
|
178
|
+
|
|
179
|
+
**GitHub Copilot, Cursor, Windsurf, etc.:**
|
|
180
|
+
|
|
181
|
+
Since these tools don't have native skill support, you MUST:
|
|
182
|
+
|
|
183
|
+
1. **At session start**: Always read `SKILLS-INDEX.md` first
|
|
184
|
+
2. **Before each task**: Check if relevant skills exist
|
|
185
|
+
3. **During execution**: Follow skill workflows precisely
|
|
186
|
+
4. **When stuck**: Re-read the relevant SKILL.md
|
|
187
|
+
|
|
188
|
+
**Treat this as mandatory**, not optional. Skills are the difference between:
|
|
189
|
+
- Inconsistent ad-hoc work ❌
|
|
190
|
+
- Professional SpecWeave-compliant output ✅
|
|
191
|
+
|
|
192
|
+
---
|
|
193
|
+
|
|
73
194
|
## Available Skills (Specialized Capabilities)
|
|
74
195
|
|
|
75
196
|
SpecWeave has specialized capabilities for different tasks:
|
|
@@ -81,10 +202,14 @@ SpecWeave has specialized capabilities for different tasks:
|
|
|
81
202
|
**In Claude Code** (automatic):
|
|
82
203
|
- Skills activate based on keywords in your request
|
|
83
204
|
- No manual invocation needed
|
|
205
|
+
- Claude reads SKILLS-INDEX.md at startup
|
|
206
|
+
- Full SKILL.md loaded when relevant
|
|
84
207
|
|
|
85
208
|
**In other tools** (manual):
|
|
86
|
-
- Read
|
|
87
|
-
-
|
|
209
|
+
- Read `.claude/skills/SKILLS-INDEX.md` first (mandatory)
|
|
210
|
+
- Match task to activation keywords
|
|
211
|
+
- Load full skill: `.claude/skills/{skill-name}/SKILL.md`
|
|
212
|
+
- Follow the workflow precisely
|
|
88
213
|
- Example: "Following increment-planner skill workflow..."
|
|
89
214
|
|
|
90
215
|
---
|
|
@@ -276,6 +401,152 @@ npm run lint
|
|
|
276
401
|
|
|
277
402
|
---
|
|
278
403
|
|
|
404
|
+
## 📝 Documentation Updates (CRITICAL FOR NON-CLAUDE TOOLS)
|
|
405
|
+
|
|
406
|
+
**IMPORTANT**: Claude Code has automatic hooks that remind you to update documentation. **GitHub Copilot, Cursor, and other tools DO NOT have these hooks!**
|
|
407
|
+
|
|
408
|
+
### You MUST Manually Update Documentation After Every Task
|
|
409
|
+
|
|
410
|
+
When you complete ANY task (implementation, bug fix, refactoring), you MUST update:
|
|
411
|
+
|
|
412
|
+
#### 1. Living Docs (.specweave/docs/)
|
|
413
|
+
|
|
414
|
+
After implementing features, update strategic documentation:
|
|
415
|
+
|
|
416
|
+
**Strategy Docs** (`.specweave/docs/internal/strategy/`):
|
|
417
|
+
- Update PRDs when requirements change
|
|
418
|
+
- Add new user stories if scope expanded
|
|
419
|
+
- Document discovered requirements
|
|
420
|
+
|
|
421
|
+
**Architecture Docs** (`.specweave/docs/internal/architecture/`):
|
|
422
|
+
- Update HLD (high-level design) when architecture changes
|
|
423
|
+
- Update LLD (low-level design) when components change
|
|
424
|
+
- Update ADRs from "Proposed" → "Accepted" after implementation
|
|
425
|
+
- Add new ADRs for significant decisions made during implementation
|
|
426
|
+
|
|
427
|
+
**Delivery Docs** (`.specweave/docs/internal/delivery/`):
|
|
428
|
+
- Update deployment guides after infrastructure changes
|
|
429
|
+
- Update CI/CD docs after pipeline modifications
|
|
430
|
+
|
|
431
|
+
**Operations Docs** (`.specweave/docs/internal/operations/`):
|
|
432
|
+
- Update runbooks after operational changes
|
|
433
|
+
- Update monitoring/alerting docs
|
|
434
|
+
|
|
435
|
+
#### 2. Increment Documentation
|
|
436
|
+
|
|
437
|
+
**Always update these files in `.specweave/increments/{increment-id}/`**:
|
|
438
|
+
|
|
439
|
+
```bash
|
|
440
|
+
# Update implementation status
|
|
441
|
+
vim .specweave/increments/0001-feature/plan.md
|
|
442
|
+
# Add: "## Implementation Notes" section with learnings
|
|
443
|
+
|
|
444
|
+
# Update task checklist
|
|
445
|
+
vim .specweave/increments/0001-feature/tasks.md
|
|
446
|
+
# Mark completed: - [x] T001: Task description
|
|
447
|
+
|
|
448
|
+
# Document completion
|
|
449
|
+
vim .specweave/increments/0001-feature/reports/completion-report.md
|
|
450
|
+
# Add: Summary of what was implemented, challenges, solutions
|
|
451
|
+
```
|
|
452
|
+
|
|
453
|
+
#### 3. Project Documentation
|
|
454
|
+
|
|
455
|
+
**CLAUDE.md or AGENTS.md** (this file):
|
|
456
|
+
- Update when project structure changes
|
|
457
|
+
- Add new workflows or commands
|
|
458
|
+
- Update "Current Work" section
|
|
459
|
+
|
|
460
|
+
**README.md** (user-facing):
|
|
461
|
+
- Update when features are added
|
|
462
|
+
- Update installation instructions if changed
|
|
463
|
+
- Update usage examples
|
|
464
|
+
|
|
465
|
+
**CHANGELOG.md** (version history):
|
|
466
|
+
- Add entries for all user-facing changes
|
|
467
|
+
- Format: `## [version] - date` with bullet points
|
|
468
|
+
|
|
469
|
+
#### 4. Code Documentation
|
|
470
|
+
|
|
471
|
+
**Inline comments**:
|
|
472
|
+
- Add JSDoc/TSDoc for new functions
|
|
473
|
+
- Update existing comments if behavior changes
|
|
474
|
+
- Explain "why" not just "what"
|
|
475
|
+
|
|
476
|
+
### When to Update (Checklist)
|
|
477
|
+
|
|
478
|
+
After you:
|
|
479
|
+
- ✅ Complete a task → Update increment tasks.md
|
|
480
|
+
- ✅ Implement a feature → Update living docs (architecture, strategy)
|
|
481
|
+
- ✅ Make architecture decision → Create or update ADR
|
|
482
|
+
- ✅ Change project structure → Update CLAUDE.md/AGENTS.md
|
|
483
|
+
- ✅ Add user-facing feature → Update README.md
|
|
484
|
+
- ✅ Fix a bug → Update CHANGELOG.md
|
|
485
|
+
- ✅ Change API → Update API documentation
|
|
486
|
+
- ✅ Modify deployment → Update deployment guide
|
|
487
|
+
|
|
488
|
+
### Example Workflow (GitHub Copilot/Cursor Users)
|
|
489
|
+
|
|
490
|
+
```markdown
|
|
491
|
+
# After completing "Implement user authentication" task:
|
|
492
|
+
|
|
493
|
+
1. Update living docs:
|
|
494
|
+
echo "## Implementation Notes
|
|
495
|
+
- Used JWT for stateless authentication
|
|
496
|
+
- Password hashing with bcrypt
|
|
497
|
+
- Session timeout: 24 hours
|
|
498
|
+
" >> .specweave/increments/0001-auth/plan.md
|
|
499
|
+
|
|
500
|
+
2. Update architecture:
|
|
501
|
+
vim .specweave/docs/internal/architecture/hld-system.md
|
|
502
|
+
# Add authentication component diagram
|
|
503
|
+
|
|
504
|
+
3. Create ADR:
|
|
505
|
+
vim .specweave/docs/internal/architecture/adr-003-jwt-authentication.md
|
|
506
|
+
|
|
507
|
+
4. Update README:
|
|
508
|
+
vim README.md
|
|
509
|
+
# Add authentication usage example
|
|
510
|
+
|
|
511
|
+
5. Update CHANGELOG:
|
|
512
|
+
echo "### Added
|
|
513
|
+
- User authentication with JWT
|
|
514
|
+
- Password reset flow
|
|
515
|
+
" >> CHANGELOG.md
|
|
516
|
+
|
|
517
|
+
6. Mark task complete:
|
|
518
|
+
vim .specweave/increments/0001-auth/tasks.md
|
|
519
|
+
# Change [ ] to [x] for completed tasks
|
|
520
|
+
```
|
|
521
|
+
|
|
522
|
+
### Why This Matters
|
|
523
|
+
|
|
524
|
+
**Without documentation updates**:
|
|
525
|
+
- ❌ Specs diverge from implementation (specs become useless)
|
|
526
|
+
- ❌ Team members don't know what changed
|
|
527
|
+
- ❌ Future AI sessions have outdated context
|
|
528
|
+
- ❌ SpecWeave's core principle (living documentation) breaks down
|
|
529
|
+
|
|
530
|
+
**With documentation updates**:
|
|
531
|
+
- ✅ Specs stay synchronized with code
|
|
532
|
+
- ✅ Clear audit trail of changes
|
|
533
|
+
- ✅ AI agents have accurate context
|
|
534
|
+
- ✅ Team members stay informed
|
|
535
|
+
- ✅ SpecWeave philosophy is maintained
|
|
536
|
+
|
|
537
|
+
### Tools That Need Manual Updates
|
|
538
|
+
|
|
539
|
+
These tools **DO NOT** have automatic documentation hooks:
|
|
540
|
+
- GitHub Copilot (all versions)
|
|
541
|
+
- Cursor
|
|
542
|
+
- Windsurf
|
|
543
|
+
- Gemini CLI
|
|
544
|
+
- Generic AI tools (ChatGPT, Claude web, etc.)
|
|
545
|
+
|
|
546
|
+
Only **Claude Code** has automatic hooks that remind you to update docs.
|
|
547
|
+
|
|
548
|
+
---
|
|
549
|
+
|
|
279
550
|
## Security Considerations
|
|
280
551
|
|
|
281
552
|
- Never commit secrets (use `.env` files, gitignored)
|
|
@@ -317,6 +588,7 @@ When you encounter a new task:
|
|
|
317
588
|
5. ✅ **Technology-specific in plan.md** (HOW with details)
|
|
318
589
|
6. ✅ **Use checkboxes in tasks.md** for tracking
|
|
319
590
|
7. ✅ **All supporting files in increment folders** (never in root)
|
|
591
|
+
8. 🔴 **UPDATE DOCUMENTATION AFTER EVERY TASK** (see "Documentation Updates" section above - CRITICAL for non-Claude tools!)
|
|
320
592
|
|
|
321
593
|
---
|
|
322
594
|
|