@ancleto/spec 0.6.4 → 0.6.6

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 (42) hide show
  1. package/README.md +1 -1
  2. package/agents/coder.md +11 -11
  3. package/agents/documenter.md +29 -27
  4. package/agents/orchestrator.md +8 -8
  5. package/agents/reviewer.md +13 -13
  6. package/agents/spec-writer.md +11 -10
  7. package/agents/technical-discovery.md +5 -5
  8. package/agents/technical-seed-writer.md +1 -1
  9. package/agents/tester.md +9 -9
  10. package/commands/cleto-apply.md +3 -155
  11. package/commands/cleto-archive.md +2 -164
  12. package/commands/cleto-bulk-archive.md +2 -248
  13. package/commands/cleto-continue.md +2 -126
  14. package/commands/cleto-explore.md +2 -174
  15. package/commands/cleto-ff.md +2 -122
  16. package/commands/cleto-new.md +2 -110
  17. package/commands/cleto-onboard.md +3 -563
  18. package/commands/cleto-propose.md +2 -132
  19. package/commands/cleto-recall.md +4 -52
  20. package/commands/cleto-sync.md +2 -137
  21. package/commands/cleto-verify.md +2 -169
  22. package/package.json +2 -2
  23. package/skills/ancleto-apply/SKILL.md +16 -39
  24. package/skills/ancleto-archive/SKILL.md +24 -26
  25. package/skills/ancleto-bulk-archive/SKILL.md +46 -56
  26. package/skills/ancleto-commit/SKILL.md +10 -29
  27. package/skills/ancleto-continue/SKILL.md +19 -25
  28. package/skills/ancleto-explore/SKILL.md +42 -69
  29. package/skills/ancleto-ff/SKILL.md +22 -30
  30. package/skills/ancleto-new/SKILL.md +23 -42
  31. package/skills/ancleto-onboard/SKILL.md +37 -40
  32. package/skills/ancleto-pr/SKILL.md +12 -26
  33. package/skills/ancleto-propose/SKILL.md +23 -70
  34. package/skills/ancleto-recall/SKILL.md +21 -25
  35. package/skills/ancleto-sync-specs/SKILL.md +29 -64
  36. package/skills/ancleto-upgrade/SKILL.md +134 -227
  37. package/skills/ancleto-upgrade/references/templates.md +138 -171
  38. package/skills/ancleto-verify/SKILL.md +37 -67
  39. package/skills/ancleto-workflow/SKILL.md +19 -19
  40. package/src/cli/index.js +53 -38
  41. package/templates/AGENTS.md +7 -4
  42. package/templates/PRODUCT.md +1 -1
@@ -2,85 +2,64 @@
2
2
  name: ancleto-sync-specs
3
3
  description: Sync delta specs from a change to main specs. Use when the user wants to update main specs with changes from a delta spec, without archiving the change.
4
4
  license: MIT
5
- compatibility: Requires openspec CLI.
5
+ compatibility: No external CLI required.
6
6
  metadata:
7
7
  author: ancleto
8
8
  version: '1.0'
9
9
  ---
10
10
 
11
+ # aspec Sync
12
+
13
+ **Artifacts language**: write every artifact in English. Keywords (`Requirement`, `Scenario`, `SHALL`, `WHEN`/`THEN`, `ADDED/MODIFIED/REMOVED/RENAMED Requirements`) are literal and MUST NOT be translated. File and directory names stay English kebab-case.
14
+
11
15
  Sync delta specs from a change to main specs.
12
16
 
13
- This is an **agent-driven** operation - you will read delta specs and directly edit main specs to apply the changes. This allows intelligent merging (e.g., adding a scenario without copying the entire requirement).
17
+ **Agent-driven**: read delta specs and directly edit main specs, enabling intelligent merging (add one scenario without copying the whole requirement). The delta is _intent_, not a wholesale replacement — apply partial updates. Must be idempotent (running twice gives the same result).
14
18
 
15
- **Input**: Optionally specify a change name. If omitted, check if it can be inferred from conversation context. If vague or ambiguous you MUST prompt for available changes.
19
+ **Input**: Optionally a change name; if omitted, infer from context. If ambiguous you MUST prompt for available changes.
16
20
 
17
21
  **Steps**
18
22
 
19
23
  1. **If no change name provided, prompt for selection**
20
24
 
21
- Run `openspec list --json` to get available changes. Use the **AskUserQuestion tool** to let the user select.
22
-
23
- Show changes that have delta specs (under `specs/` directory).
25
+ List `aspec/changes/` dirs (excluding `archive/`); ask the user to select (runtime question tool when available). Show changes that have delta specs (under `specs/`).
24
26
 
25
27
  **IMPORTANT**: Do NOT guess or auto-select a change. Always let the user choose.
26
28
 
27
29
  2. **Find delta specs**
28
30
 
29
- Look for delta spec files in `openspec/changes/<name>/specs/*/spec.md`.
30
-
31
- Each delta spec file contains sections like:
31
+ Look for `aspec/changes/<name>/specs/*/spec.md`, whose sections are:
32
32
 
33
33
  - `## ADDED Requirements` - New requirements to add
34
34
  - `## MODIFIED Requirements` - Changes to existing requirements
35
35
  - `## REMOVED Requirements` - Requirements to remove
36
36
  - `## RENAMED Requirements` - Requirements to rename (FROM:/TO: format)
37
37
 
38
- If no delta specs found, inform user and stop.
39
-
40
- 3. **For each delta spec, apply changes to main specs**
41
-
42
- For each capability with a delta spec at `openspec/changes/<name>/specs/<capability>/spec.md`:
43
-
44
- a. **Read the delta spec** to understand the intended changes
45
-
46
- b. **Read the main spec** at `openspec/specs/<capability>/spec.md` (may not exist yet)
38
+ If none found, inform the user and stop.
47
39
 
48
- c. **Apply changes intelligently**:
40
+ 3. **Apply each delta spec to main specs**
49
41
 
50
- **ADDED Requirements:**
42
+ Per capability with a delta at `aspec/changes/<name>/specs/<capability>/spec.md`:
51
43
 
52
- - If requirement doesn't exist in main spec → add it
53
- - If requirement already exists → update it to match (treat as implicit MODIFIED)
44
+ a. **Read the delta spec** for the intended changes
54
45
 
55
- **MODIFIED Requirements:**
46
+ b. **Read the main spec** at `aspec/specs/<capability>/spec.md` (may not exist yet)
56
47
 
57
- - Find the requirement in main spec
58
- - Apply the changes - this can be:
59
- - Adding new scenarios (don't need to copy existing ones)
60
- - Modifying existing scenarios
61
- - Changing the requirement description
62
- - Preserve scenarios/content not mentioned in the delta
48
+ c. **Apply changes**:
63
49
 
64
- **REMOVED Requirements:**
50
+ **ADDED Requirements:** absent → add; present → update to match (implicit MODIFIED).
65
51
 
66
- - Remove the entire requirement block from main spec
52
+ **MODIFIED Requirements:** find the requirement and apply — add new scenarios (don't copy existing ones), modify scenarios, or change the description. Preserve content not mentioned in the delta.
67
53
 
68
- **RENAMED Requirements:**
54
+ **REMOVED Requirements:** remove the entire requirement block.
69
55
 
70
- - Find the FROM requirement, rename to TO
56
+ **RENAMED Requirements:** rename the FROM requirement to TO.
71
57
 
72
- d. **Create new main spec** if capability doesn't exist yet:
73
-
74
- - Create `openspec/specs/<capability>/spec.md`
75
- - Add Purpose section (can be brief, mark as TBD)
76
- - Add Requirements section with the ADDED requirements
58
+ d. **Create the main spec** if the capability doesn't exist: `aspec/specs/<capability>/spec.md` with a brief Purpose (mark TBD if unknown) and the ADDED requirements.
77
59
 
78
60
  4. **Show summary**
79
61
 
80
- After applying all changes, summarize:
81
-
82
- - Which capabilities were updated
83
- - What changes were made (requirements added/modified/removed/renamed)
62
+ Summarize capabilities updated and changes made (added/modified/removed/renamed).
84
63
 
85
64
  **Delta Spec Format Reference**
86
65
 
@@ -115,36 +94,22 @@ The system SHALL do something new.
115
94
  - TO: `### Requirement: New Name`
116
95
  ```
117
96
 
118
- **Key Principle: Intelligent Merging**
119
-
120
- Unlike programmatic merging, you can apply **partial updates**:
121
-
122
- - To add a scenario, just include that scenario under MODIFIED - don't copy existing scenarios
123
- - The delta represents _intent_, not a wholesale replacement
124
- - Use your judgment to merge changes sensibly
125
-
126
97
  **Output On Success**
127
98
 
128
99
  ```
129
100
  ## Specs Synced: <change-name>
130
101
 
131
102
  Updated main specs:
103
+ - **<capability-1>**: added "New Feature"; modified "Existing Feature" (1 scenario)
104
+ - **<capability-2>**: created new spec file; added "Another Feature"
132
105
 
133
- **<capability-1>**:
134
- - Added requirement: "New Feature"
135
- - Modified requirement: "Existing Feature" (added 1 scenario)
136
-
137
- **<capability-2>**:
138
- - Created new spec file
139
- - Added requirement: "Another Feature"
140
-
141
- Main specs are now updated. The change remains active - archive when implementation is complete.
106
+ The change remains active - archive when implementation is complete.
142
107
  ```
143
108
 
144
109
  **Guardrails**
145
110
 
146
- - Read both delta and main specs before making changes
147
- - Preserve existing content not mentioned in delta
148
- - If something is unclear, ask for clarification
149
- - Show what you're changing as you go
150
- - The operation should be idempotent - running twice should give same result
111
+ - Read both delta and main specs before editing
112
+ - Preserve content not mentioned in the delta
113
+ - If unclear, ask for clarification
114
+ - Show changes as you go
115
+ - Idempotent - running twice gives the same result