Skip to content

Commit ba9b686

Browse files
author
Test User
committed
Add impact scope summary to change impact report
Compute per-branch lowest common ancestors of all impacted requirements through the derivedFrom hierarchy, giving reviewers a high-level view of affected model areas. Section appears between Changed Elements and Invalidated Verifications in both text and JSON output. Bump version to 0.11.0.
1 parent f012fe2 commit ba9b686

File tree

21 files changed

+703
-33
lines changed

21 files changed

+703
-33
lines changed

Cargo.lock

Lines changed: 8 additions & 8 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ members = [
66
resolver = "2"
77

88
[workspace.package]
9-
version = "0.10.0"
9+
version = "0.11.0"
1010
edition = "2021"
1111
rust-version = "1.86"
1212
license = "Apache-2.0"

claude-plugins/commands/analyze-impact.md

Lines changed: 14 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -46,9 +46,12 @@ ${1:-Comparing against: HEAD~1 (previous commit)}
4646
3. **Analyze the results:**
4747

4848
Extract from JSON:
49-
- `added_elements[]` - New requirements/verifications
50-
- `modified_elements[]` - Changed requirements/verifications
51-
- `affected_elements[]` - Elements impacted by changes
49+
- `added[]` - New requirements/verifications
50+
- `changed[]` - Changed requirements/verifications
51+
- `removed[]` - Removed elements
52+
- `relocated[]` - Relocated elements (same name, different path)
53+
- `impact_scope[]` - Per-branch scope roots (common parent requirements covering all impacted elements)
54+
- `invalidated_verifications[]` - Verifications that need re-review
5255

5356
4. **For each modified requirement:**
5457

@@ -65,19 +68,22 @@ ${1:-Comparing against: HEAD~1 (previous commit)}
6568

6669
5. **Present impact findings:**
6770

71+
**Impact Scope** (high-level affected areas):
72+
- [Parent Requirement A](file.md#parent-a) - covers changed children
73+
- [Standalone Req](file.md#standalone) - directly changed
74+
6875
**Added Elements:**
6976
- [New Requirement](file.md#new-req) - type: requirement
7077

7178
**Modified Elements:**
7279
- [Changed Requirement](file.md#changed) - review needed
7380

74-
**Affected Elements (propagation):**
75-
- Verifications needing review: X
76-
- Implementations needing update: Y
77-
- Child requirements affected: Z
81+
**Invalidated Verifications:**
82+
- Verifications needing re-review: X
7883

7984
6. **Provide recommendations:**
80-
- Review and update affected verifications
85+
- Start with impact scope to understand affected model areas
86+
- Review and update invalidated verifications
8187
- Update test criteria if requirements changed
8288
- Review implementations marked with satisfiedBy
8389
- Run tests for affected verifications

claude-plugins/commands/generate-tasks.md

Lines changed: 11 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,11 @@ Generate implementation task plan from requirement changes on a feature branch.
3737
reqvire change-impact --git-commit=$BASE_COMMIT --json > /tmp/impact.json
3838
```
3939

40-
3. **For each changed requirement:**
40+
3. **Review impact scope** (from JSON `impact_scope[]`):
41+
42+
The `impact_scope` array shows the per-branch common parent requirements covering all impacted elements. Use this to understand the high-level affected model areas before diving into details.
43+
44+
4. **For each changed requirement:**
4145

4246
Get full context using collect:
4347
```bash
@@ -62,7 +66,7 @@ Generate implementation task plan from requirement changes on a feature branch.
6266
- satisfiedBy relations (code to update)
6367
- derivedFrom relations (context)
6468

65-
4. **For each verification:**
69+
5. **For each verification:**
6670

6771
Get test paths:
6872
```bash
@@ -71,7 +75,7 @@ Generate implementation task plan from requirement changes on a feature branch.
7175

7276
Extract satisfiedBy relations (test files).
7377

74-
5. **Generate TodoWrite task plan:**
78+
6. **Generate TodoWrite task plan:**
7579

7680
**Use collected context** from `/tmp/req_<requirement-id>.json` to create concise summaries:
7781
- Extract parent requirement purpose (why this exists)
@@ -108,13 +112,13 @@ Generate implementation task plan from requirement changes on a feature branch.
108112
☐ Validate: reqvire validate
109113
```
110114

111-
6. **Generate git blob links:**
115+
7. **Generate git blob links:**
112116
```bash
113117
REPO_URL=$(git remote get-url origin | sed 's/\.git$//' | sed 's/git@github.com:/https:\/\/github.com\//')
114118
BLOB_URL="${REPO_URL}/blob/${BASE_COMMIT}/${file_path}#${element-anchor}"
115119
```
116120

117-
7. **Save collected context for reference:**
121+
8. **Save collected context for reference:**
118122

119123
For each requirement, save a formatted summary:
120124
```bash
@@ -124,7 +128,7 @@ Generate implementation task plan from requirement changes on a feature branch.
124128

125129
This provides developers with full context documents they can reference during implementation.
126130

127-
8. **Present task plan:**
131+
9. **Present task plan:**
128132
- Phase 1: New requirements to implement (with context summaries)
129133
- Phase 2: Modified requirements to update (with impact analysis)
130134
- Phase 3: Affected verifications to review
@@ -139,6 +143,7 @@ Generate implementation task plan from requirement changes on a feature branch.
139143
**Feature**: {current_branch}
140144

141145
## Summary
146+
- Impact scope: {scope root names from impact_scope[]}
142147
- New requirements: X
143148
- Modified requirements: Y
144149
- Tests to run: Z

claude-plugins/skills/syseng/SKILL.md

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -348,9 +348,10 @@ reqvire change-impact --git-commit=HEAD~1
348348
```
349349

350350
The change-impact command shows:
351-
- Which requirements were modified
351+
- Which requirements were added, changed, removed, or relocated
352352
- Which downstream elements are affected (via derivedFrom, verifiedBy)
353-
- Impact scope and traceability
353+
- **Impact scope**: Per-branch common parent requirements covering all impacted elements (high-level summary of affected areas)
354+
- Invalidated verifications that need re-review
354355

355356
For detailed analysis workflows, see [Explore](reference/explore.md).
356357

claude-plugins/skills/syseng/reference/CreatingTasks.md

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -36,9 +36,12 @@ reqvire change-impact --git-commit=HEAD~1
3636
```
3737

3838
The change-impact command identifies:
39-
- `added_elements[]` - New requirements/verifications
40-
- `modified_elements[]` - Changed requirements/verifications
41-
- `affected_elements[]` - Elements impacted by changes (via derivedFrom, verifiedBy)
39+
- `added[]` - New requirements/verifications
40+
- `changed[]` - Changed requirements/verifications
41+
- `removed[]` - Removed elements
42+
- `relocated[]` - Relocated elements (same name, different path)
43+
- `impact_scope[]` - Per-branch scope roots: common parent requirements covering all impacted elements. Use this for a high-level summary of affected model areas
44+
- `invalidated_verifications[]` - Verifications that need re-review
4245

4346
**Change Propagation Rules:**
4447
- **Parent → Child**: Parent changes propagate to all derived children

0 commit comments

Comments
 (0)