@ancleto/spec 0.6.5 → 0.6.7

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 (40) hide show
  1. package/README.md +26 -1
  2. package/agents/context-resolver.md +1 -1
  3. package/agents/documenter.md +3 -1
  4. package/agents/memory-keeper.md +1 -1
  5. package/agents/spec-writer.md +2 -1
  6. package/agents/technical-discovery.md +1 -1
  7. package/agents/tester.md +1 -1
  8. package/commands/cleto-apply.md +2 -154
  9. package/commands/cleto-archive.md +2 -164
  10. package/commands/cleto-bulk-archive.md +2 -248
  11. package/commands/cleto-continue.md +2 -126
  12. package/commands/cleto-explore.md +2 -174
  13. package/commands/cleto-ff.md +2 -120
  14. package/commands/cleto-new.md +2 -108
  15. package/commands/cleto-onboard.md +2 -550
  16. package/commands/cleto-propose.md +2 -130
  17. package/commands/cleto-recall.md +4 -52
  18. package/commands/cleto-sync.md +2 -137
  19. package/commands/cleto-verify.md +2 -169
  20. package/package.json +1 -1
  21. package/skills/ancleto-apply/SKILL.md +15 -38
  22. package/skills/ancleto-archive/SKILL.md +22 -24
  23. package/skills/ancleto-bulk-archive/SKILL.md +45 -55
  24. package/skills/ancleto-commit/SKILL.md +10 -29
  25. package/skills/ancleto-continue/SKILL.md +18 -24
  26. package/skills/ancleto-explore/SKILL.md +40 -67
  27. package/skills/ancleto-ff/SKILL.md +20 -28
  28. package/skills/ancleto-new/SKILL.md +20 -39
  29. package/skills/ancleto-onboard/SKILL.md +35 -38
  30. package/skills/ancleto-pr/SKILL.md +12 -26
  31. package/skills/ancleto-propose/SKILL.md +22 -69
  32. package/skills/ancleto-recall/SKILL.md +21 -25
  33. package/skills/ancleto-sync-specs/SKILL.md +27 -62
  34. package/skills/ancleto-upgrade/SKILL.md +132 -223
  35. package/skills/ancleto-upgrade/references/templates.md +138 -171
  36. package/skills/ancleto-verify/SKILL.md +36 -66
  37. package/skills/ancleto-workflow/SKILL.md +17 -17
  38. package/src/cli/index.js +76 -49
  39. package/src/core/tier-models.js +48 -0
  40. package/templates/AGENTS.md +3 -0
@@ -2,126 +2,8 @@
2
2
  description: Create a change and generate all artifacts needed for implementation in one go
3
3
  ---
4
4
 
5
- Fast-forward through artifact creation - generate everything needed to start implementation.
5
+ Invoke the `ancleto-ff` skill with the Skill tool and follow it exactly; do not improvise steps.
6
6
 
7
7
  **Input**: The argument after `/cleto-ff` is the change name (kebab-case), OR a description of what the user wants to build.
8
8
 
9
- **Steps**
10
-
11
- 1. **Resolve Work Item context and derive change name**
12
-
13
- Resolve Work Item context in this order — stop at the first source that yields data:
14
-
15
- a. **In-session context** — If WI data was already fetched in this session, use it. Proceed to name derivation below.
16
- b. **`context.md`** — If a change name was provided as argument and `aspec/changes/<name>/context.md` exists, read it and use its content. Proceed to name derivation.
17
- c. **Ask the user** — Use the **AskUserQuestion tool** to ask for the Work Item reference. Two accepted formats:
18
-
19
- - **ID + Project** — e.g., ID `12345` and project `MyProject`
20
- - **Full URL** — e.g., `https://dev.azure.com/org/MyProject/_workitems/edit/12345`
21
-
22
- > "Do you have an Azure DevOps Work Item for this change? Provide the Work Item ID and Azure DevOps project name (e.g., ID: `12345`, Project: `MyProject`), or paste the full Work Item URL. Skip to describe the change manually."
23
-
24
- **If WI provided:**
25
-
26
- - If URL provided: extract numeric ID (pattern: `_workitems/edit/{id}`) AND project name (pattern: `/{org}/{project}/_workitems/`)
27
- - Use BOTH `id` AND `project` when calling the AzDO MCP (`wit_get_work_item`) — never call with ID alone
28
- - Extract from the response: `System.Id`, `System.Title`, `System.Description`, `Microsoft.VSTS.Common.AcceptanceCriteria`, `System.WorkItemType`
29
- - Suggest a kebab-case name derived from `System.Title` (e.g., "Add payment gateway" → `add-payment-gateway`)
30
- - Let the user accept or modify the suggested name before proceeding
31
-
32
- **If skipped:**
33
-
34
- - Display: "No work item linked — consider linking one for traceability."
35
- - If no change name was provided as argument, ask what they want to build:
36
- > "What change do you want to work on? Describe what you want to build or fix."
37
- - Derive a kebab-case name from the description.
38
-
39
- WI context is held **in-memory** for this flow — no `context.md` is written.
40
-
41
- **IMPORTANT**: Do NOT proceed without a change name.
42
-
43
- 2. **Create the change directory**
44
-
45
- Create the directory `aspec/changes/<name>/` in the repository.
46
-
47
- This scaffolds the change at `aspec/changes/<name>/`.
48
-
49
- 3. **Get the artifact build order**
50
-
51
- ```bash
52
- aspec status --change "<name>" --json
53
- ```
54
-
55
- Parse the JSON to get:
56
-
57
- - `applyRequires`: array of artifact IDs needed before implementation (e.g., `["tasks"]`)
58
- - `artifacts`: list of all artifacts with their status and dependencies
59
-
60
- 4. **Create artifacts in sequence until apply-ready**
61
-
62
- Use the **TodoWrite tool** to track progress through the artifacts.
63
-
64
- Loop through artifacts in dependency order (artifacts with no pending dependencies first):
65
-
66
- a. **For each artifact that is `ready` (dependencies satisfied)**:
67
-
68
- - Get instructions:
69
- ```bash
70
- aspec instructions <artifact-id> --change "<name>" --json
71
- ```
72
- - The instructions JSON includes:
73
- - `context`: Project background (constraints for you - do NOT include in output)
74
- - `rules`: Artifact-specific rules (constraints for you - do NOT include in output)
75
- - `template`: The structure to use for your output file
76
- - `instruction`: Schema-specific guidance for this artifact type
77
- - `outputPath`: Where to write the artifact
78
- - `dependencies`: Completed artifacts to read for context
79
- - Read any completed dependency files for context
80
- - If creating the first artifact (proposal):
81
- - If WI context is available (in-memory): use WI title/description as the problem statement, acceptance criteria as the requirements basis, and include a `## Related Work Item` section: `**#{id}** — {System.Title} ({WorkItemType}) · Project: {System.TeamProject}`
82
- - Create the artifact file using `template` as the structure
83
- - Apply `context` and `rules` as constraints - but do NOT copy them into the file
84
- - Show brief progress: "✓ Created <artifact-id>"
85
-
86
- b. **Continue until all `applyRequires` artifacts are complete**
87
-
88
- - After creating each artifact, re-run `aspec status --change "<name>" --json`
89
- - Check if every artifact ID in `applyRequires` has `status: "done"` in the artifacts array
90
- - Stop when all `applyRequires` artifacts are done
91
-
92
- c. **If an artifact requires user input** (unclear context):
93
-
94
- - Use **AskUserQuestion tool** to clarify
95
- - Then continue with creation
96
-
97
- 5. **Show final status**
98
- ```bash
99
- aspec status --change "<name>"
100
- ```
101
-
102
- **Output**
103
-
104
- After completing all artifacts, summarize:
105
-
106
- - Change name and location
107
- - List of artifacts created with brief descriptions
108
- - What's ready: "All artifacts created! Ready for implementation."
109
- - Prompt: "Run `/cleto-apply` to start implementing."
110
-
111
- **Artifact Creation Guidelines**
112
-
113
- - Follow the `instruction` field from `aspec instructions` for each artifact type
114
- - The schema defines what each artifact should contain - follow it
115
- - Read dependency artifacts for context before creating new ones
116
- - Use `template` as the structure for your output file - fill in its sections
117
- - **IMPORTANT**: `context` and `rules` are constraints for YOU, not content for the file
118
- - Do NOT copy `<context>`, `<rules>`, `<project_context>` blocks into the artifact
119
- - These guide what you write, but should never appear in the output
120
-
121
- **Guardrails**
122
-
123
- - Create ALL artifacts needed for implementation (as defined by schema's `apply.requires`)
124
- - Always read dependency artifacts before creating a new one
125
- - If context is critically unclear, ask the user - but prefer making reasonable decisions to keep momentum
126
- - If a change with that name already exists, ask if user wants to continue it or create a new one
127
- - Verify each artifact file exists after writing before proceeding to next
9
+ Work Item grounding (when the request references a Work Item) is owned by `@context-resolver`.
@@ -2,114 +2,8 @@
2
2
  description: Start a new change using the experimental artifact workflow
3
3
  ---
4
4
 
5
- Start a new change using the experimental artifact-driven approach.
5
+ Invoke the `ancleto-new` skill with the Skill tool and follow it exactly; do not improvise steps.
6
6
 
7
7
  **Input**: The argument after `/cleto-new` is the change name (kebab-case), OR a description of what the user wants to build.
8
8
 
9
- **Steps**
10
-
11
- 1. **Resolve Work Item context and derive change name**
12
-
13
- Resolve Work Item context in this order — stop at the first source that yields data:
14
-
15
- a. **In-session context** — If WI data was already fetched in this session, use it. Proceed to name derivation below.
16
- b. **`context.md`** — If a change name was provided as argument and `aspec/changes/<name>/context.md` exists, read it and use its content. Proceed to name derivation.
17
- c. **Ask the user** — Use the **AskUserQuestion tool** to ask for the Work Item reference. Two accepted formats:
18
-
19
- - **ID + Project** — e.g., ID `12345` and project `MyProject`
20
- - **Full URL** — e.g., `https://dev.azure.com/org/MyProject/_workitems/edit/12345`
21
-
22
- > "Do you have an Azure DevOps Work Item for this change? Provide the Work Item ID and Azure DevOps project name (e.g., ID: `12345`, Project: `MyProject`), or paste the full Work Item URL. Skip to describe the change manually."
23
-
24
- **If WI provided:**
25
-
26
- - If URL provided: extract numeric ID (pattern: `_workitems/edit/{id}`) AND project name (pattern: `/{org}/{project}/_workitems/`)
27
- - Use BOTH `id` AND `project` when calling the AzDO MCP (`wit_get_work_item`) — never call with ID alone
28
- - Extract from the response: `System.Id`, `System.Title`, `System.Description`, `Microsoft.VSTS.Common.AcceptanceCriteria`, `System.WorkItemType`
29
- - Suggest a kebab-case name derived from `System.Title` (e.g., "Add payment gateway" → `add-payment-gateway`)
30
- - Let the user accept or modify the suggested name before proceeding
31
-
32
- **If skipped:**
33
-
34
- - Display: "No work item linked — consider linking one for traceability."
35
- - If no change name was provided as argument, ask what they want to build:
36
- > "What change do you want to work on? Describe what you want to build or fix."
37
- - Derive a kebab-case name from the description.
38
-
39
- **IMPORTANT**: Do NOT proceed without a change name.
40
-
41
- 2. **Determine the workflow schema**
42
-
43
- Use the default schema (omit `--schema`) unless the user explicitly requests a different workflow.
44
-
45
- **Use a different schema only if the user mentions:**
46
-
47
- - A specific schema name → use `--schema <name>`
48
- - "show workflows" or "what workflows" → run `aspec schemas --json` and let them choose
49
-
50
- **Otherwise**: Omit `--schema` to use the default.
51
-
52
- 3. **Create the change directory**
53
-
54
- Create the directory `aspec/changes/<name>/` in the repository.
55
-
56
- Record the schema selection in the change metadata only if the user requested a specific workflow.
57
- This scaffolds the change at `aspec/changes/<name>/` with the selected schema.
58
-
59
- 4. **Persist Work Item context to `context.md`** (only if WI was resolved in step 1)
60
-
61
- Write WI context to `aspec/changes/<name>/context.md`:
62
-
63
- ```
64
- # Work Item Context
65
-
66
- **ID**: #{id}
67
- **Type**: {WorkItemType}
68
- **Title**: {System.Title}
69
- **Project**: {System.TeamProject}
70
-
71
- ## Description
72
- {System.Description (HTML stripped)}
73
-
74
- ## Acceptance Criteria
75
- {Microsoft.VSTS.Common.AcceptanceCriteria (HTML stripped)}
76
- ```
77
-
78
- Skip this step if the user skipped the Work Item step.
79
-
80
- 5. **Show the artifact status**
81
-
82
- ```bash
83
- aspec status --change "<name>"
84
- ```
85
-
86
- This shows which artifacts need to be created and which are ready (dependencies satisfied).
87
-
88
- 6. **Get instructions for the first artifact**
89
- The first artifact depends on the schema. Check the status output to find the first artifact with status "ready".
90
-
91
- ```bash
92
- aspec instructions <first-artifact-id> --change "<name>"
93
- ```
94
-
95
- This outputs the template and context for creating the first artifact.
96
-
97
- 7. **STOP and wait for user direction**
98
-
99
- **Output**
100
-
101
- After completing the steps, summarize:
102
-
103
- - Change name and location
104
- - Schema/workflow being used and its artifact sequence
105
- - Current status (0/N artifacts complete)
106
- - The template for the first artifact
107
- - Prompt: "Ready to create the first artifact? Run `/cleto-continue` or just describe what this change is about and I'll draft it."
108
-
109
- **Guardrails**
110
-
111
- - Do NOT create any artifacts yet - just show the instructions
112
- - Do NOT advance beyond showing the first artifact template
113
- - If the name is invalid (not kebab-case), ask for a valid name
114
- - If a change with that name already exists, suggest using `/cleto-continue` instead
115
- - Pass --schema if using a non-default workflow
9
+ Work Item grounding (when the request references a Work Item) is owned by `@context-resolver`.