@fission-ai/openspec 1.7.0 → 1.9.0

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 (113) hide show
  1. package/README.md +3 -1
  2. package/dist/cli/index.d.ts +15 -0
  3. package/dist/cli/index.js +39 -5
  4. package/dist/commands/change.js +16 -1
  5. package/dist/commands/config.d.ts +5 -0
  6. package/dist/commands/config.js +5 -1
  7. package/dist/commands/schema.js +281 -47
  8. package/dist/commands/spec.js +30 -6
  9. package/dist/commands/validate.d.ts +23 -0
  10. package/dist/commands/validate.js +148 -4
  11. package/dist/commands/workflow/instructions.js +32 -27
  12. package/dist/commands/workflow/schemas.d.ts +2 -0
  13. package/dist/commands/workflow/schemas.js +9 -2
  14. package/dist/commands/workflow/status.js +2 -2
  15. package/dist/commands/workflow/templates.js +15 -5
  16. package/dist/core/archive.d.ts +14 -0
  17. package/dist/core/archive.js +1272 -151
  18. package/dist/core/artifact-graph/index.d.ts +1 -1
  19. package/dist/core/artifact-graph/index.js +1 -1
  20. package/dist/core/artifact-graph/instruction-loader.d.ts +3 -1
  21. package/dist/core/artifact-graph/instruction-loader.js +15 -5
  22. package/dist/core/artifact-graph/outputs.d.ts +1 -0
  23. package/dist/core/artifact-graph/outputs.js +67 -5
  24. package/dist/core/artifact-graph/resolver.d.ts +0 -12
  25. package/dist/core/artifact-graph/resolver.js +49 -9
  26. package/dist/core/artifact-graph/types.js +21 -3
  27. package/dist/core/available-tools.d.ts +2 -2
  28. package/dist/core/available-tools.js +14 -3
  29. package/dist/core/change-metadata/schema.d.ts +1 -0
  30. package/dist/core/change-metadata/schema.js +7 -0
  31. package/dist/core/change-status-policy.js +2 -2
  32. package/dist/core/command-generation/adapters/command-code.d.ts +19 -0
  33. package/dist/core/command-generation/adapters/command-code.js +34 -0
  34. package/dist/core/command-generation/adapters/index.d.ts +1 -0
  35. package/dist/core/command-generation/adapters/index.js +1 -0
  36. package/dist/core/command-generation/registry.js +2 -0
  37. package/dist/core/completions/command-registry.js +13 -0
  38. package/dist/core/config-schema.d.ts +3 -0
  39. package/dist/core/config-schema.js +28 -1
  40. package/dist/core/config.d.ts +4 -0
  41. package/dist/core/config.js +40 -17
  42. package/dist/core/file-state.js +56 -24
  43. package/dist/core/github-copilot/cloud-agent.d.ts +95 -0
  44. package/dist/core/github-copilot/cloud-agent.js +497 -0
  45. package/dist/core/global-config.d.ts +11 -0
  46. package/dist/core/init.d.ts +23 -0
  47. package/dist/core/init.js +253 -46
  48. package/dist/core/legacy-cleanup.d.ts +10 -0
  49. package/dist/core/legacy-cleanup.js +52 -28
  50. package/dist/core/migration.d.ts +6 -4
  51. package/dist/core/migration.js +78 -22
  52. package/dist/core/parsers/requirement-blocks.d.ts +10 -0
  53. package/dist/core/parsers/requirement-blocks.js +93 -1
  54. package/dist/core/parsers/requirement-text.d.ts +8 -0
  55. package/dist/core/parsers/requirement-text.js +4 -3
  56. package/dist/core/parsers/spec-structure.d.ts +1 -1
  57. package/dist/core/parsers/spec-structure.js +17 -1
  58. package/dist/core/profile-sync-drift.js +40 -5
  59. package/dist/core/project-config.d.ts +3 -0
  60. package/dist/core/project-config.js +31 -1
  61. package/dist/core/root-selection.d.ts +1 -1
  62. package/dist/core/shared/index.d.ts +1 -0
  63. package/dist/core/shared/index.js +1 -0
  64. package/dist/core/shared/skill-content-equivalence.d.ts +7 -0
  65. package/dist/core/shared/skill-content-equivalence.js +41 -0
  66. package/dist/core/shared/skill-paths.d.ts +13 -0
  67. package/dist/core/shared/skill-paths.js +23 -0
  68. package/dist/core/shared/tool-detection.js +66 -35
  69. package/dist/core/shared-skill-target.d.ts +31 -0
  70. package/dist/core/shared-skill-target.js +186 -0
  71. package/dist/core/specs-apply.d.ts +72 -0
  72. package/dist/core/specs-apply.js +459 -59
  73. package/dist/core/templates/skill-templates.d.ts +1 -1
  74. package/dist/core/templates/skill-templates.js +1 -1
  75. package/dist/core/templates/workflows/apply-change.d.ts +10 -0
  76. package/dist/core/templates/workflows/apply-change.js +25 -182
  77. package/dist/core/templates/workflows/archive-change.js +8 -4
  78. package/dist/core/templates/workflows/bulk-archive-change.js +30 -26
  79. package/dist/core/templates/workflows/continue-change.js +6 -6
  80. package/dist/core/templates/workflows/explore.js +42 -18
  81. package/dist/core/templates/workflows/onboard.js +9 -3
  82. package/dist/core/templates/workflows/propose.js +72 -20
  83. package/dist/core/templates/workflows/store-selection.d.ts +1 -1
  84. package/dist/core/templates/workflows/store-selection.js +1 -1
  85. package/dist/core/templates/workflows/sync-specs.js +96 -18
  86. package/dist/core/templates/workflows/update-change.js +10 -8
  87. package/dist/core/update.d.ts +1 -0
  88. package/dist/core/update.js +136 -30
  89. package/dist/core/validation/task-numbering.d.ts +16 -0
  90. package/dist/core/validation/task-numbering.js +57 -0
  91. package/dist/core/validation/validator.d.ts +26 -3
  92. package/dist/core/validation/validator.js +189 -19
  93. package/dist/core/version-check.js +6 -11
  94. package/dist/telemetry/config.d.ts +3 -4
  95. package/dist/telemetry/index.d.ts +12 -5
  96. package/dist/telemetry/index.js +27 -9
  97. package/dist/utils/change-metadata.d.ts +17 -4
  98. package/dist/utils/change-metadata.js +26 -4
  99. package/dist/utils/ci.d.ts +12 -0
  100. package/dist/utils/ci.js +16 -0
  101. package/dist/utils/command-references.d.ts +14 -2
  102. package/dist/utils/command-references.js +45 -3
  103. package/dist/utils/file-system.d.ts +10 -0
  104. package/dist/utils/file-system.js +70 -0
  105. package/dist/utils/interactive.d.ts +52 -0
  106. package/dist/utils/interactive.js +135 -0
  107. package/dist/utils/spec-discovery.d.ts +4 -4
  108. package/dist/utils/spec-discovery.js +19 -6
  109. package/dist/utils/task-progress.d.ts +51 -1
  110. package/dist/utils/task-progress.js +93 -41
  111. package/package.json +1 -1
  112. package/schemas/spec-driven/schema.yaml +8 -6
  113. package/schemas/spec-driven/templates/proposal.md +6 -4
@@ -9,6 +9,8 @@ This is an **agent-driven** operation - you will read delta specs and directly e
9
9
 
10
10
  ${STORE_SELECTION_GUIDANCE}
11
11
 
12
+ \`<capability-path>\` is the spec directory relative to \`specs/\` (for example, \`user-auth\` or \`identity/user-auth\`). Preserve the full path from each delta spec when resolving its main spec.
13
+
12
14
  **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.
13
15
 
14
16
  **Steps**
@@ -42,8 +44,10 @@ ${STORE_SELECTION_GUIDANCE}
42
44
  instructions or writing a main spec.
43
45
 
44
46
  Sync every path in \`existingOutputPaths\` unless the caller narrowed the set.
45
- A caller narrows it by naming an explicit list of delta spec paths to sync —
46
- archive does this inline, and a user can too ("only sync the billing delta").
47
+ A caller narrows it by naming an explicit list of complete entries from
48
+ \`existingOutputPaths\` — copy those absolute values verbatim. Archive does
49
+ this inline, and a user can too (for example, by selecting the entry ending
50
+ in \`/specs/billing/invoices/spec.md\`).
47
51
  Then sync only the named paths and leave the remaining delta specs untouched:
48
52
  bulk archive excludes a delta whose implementation it could not find, and
49
53
  syncing it anyway would write a main spec the caller deliberately withheld.
@@ -83,7 +87,7 @@ ${STORE_SELECTION_GUIDANCE}
83
87
 
84
88
  a. **Read the delta spec** to understand the intended changes
85
89
 
86
- b. **Read the main spec** at \`<planningHome.root>/openspec/specs/<capability>/spec.md\` (may not exist yet)
90
+ b. **Read the main spec** at \`<planningHome.root>/openspec/specs/<capability-path>/spec.md\` (may not exist yet)
87
91
 
88
92
  c. **Apply changes intelligently**:
89
93
 
@@ -94,13 +98,35 @@ ${STORE_SELECTION_GUIDANCE}
94
98
  **MODIFIED Requirements:**
95
99
  - Find the requirement in main spec
96
100
  - Apply the changes - this can be:
97
- - Adding new scenarios (don't need to copy existing ones)
101
+ - Adding new scenarios the main spec does not have yet
98
102
  - Modifying existing scenarios
99
103
  - Changing the requirement description
100
104
  - Preserve scenarios/content not mentioned in the delta
101
105
 
102
106
  **REMOVED Requirements:**
103
107
  - Remove the entire requirement block from main spec
108
+ - Retiring the capability. Delete the whole \`spec.md\` - and the directory once
109
+ nothing else is left in it - only when ALL of these hold:
110
+ 1. removing the requirements *this run* left no requirement blocks;
111
+ 2. the rest of the spec is well-formed (it still has a \`## Purpose\`);
112
+ 3. the main spec was not already empty before this sync - if you removed
113
+ nothing, change nothing;
114
+ 4. every other nonblank line in the whole file is accounted for as the
115
+ title, Purpose, Requirements header, or a canonical requirement's
116
+ statement, scenarios, or fenced examples;
117
+ 5. the change's \`.openspec.yaml\` declares \`retire_capabilities: true\`;
118
+ 6. the \`spec.md\` resolves inside the real specs root (do not follow a
119
+ capability-directory symlink to delete an external file).
120
+ If removing the selected requirements would leave no requirement blocks and
121
+ any retirement condition is not satisfied, do not modify the main spec. Stop
122
+ the sync for that capability, report the blocking condition, and tell the user
123
+ how to resolve it. Never write or leave an empty \`## Requirements\` section.
124
+ When only the marker is missing, say that too - it is the one thing the user
125
+ can add to make the retirement go through.
126
+ - Deleting the file also deletes its \`## Purpose\`; any other section blocks
127
+ retirement. Name Purpose when you report the retirement. Include a pasteable
128
+ \`git checkout\` only when the spec lived in the caller's checkout;
129
+ otherwise give checkout-scoped recovery guidance.
104
130
 
105
131
  **RENAMED Requirements:**
106
132
  - Find the FROM requirement, rename to TO
@@ -110,19 +136,26 @@ ${STORE_SELECTION_GUIDANCE}
110
136
  (this is what \`openspec archive\` does; it warns and moves on)
111
137
 
112
138
  d. **Create new main spec** if capability doesn't exist yet:
113
- - Create \`<planningHome.root>/openspec/specs/<capability>/spec.md\`
139
+ - Create \`<planningHome.root>/openspec/specs/<capability-path>/spec.md\`
114
140
  - Add Purpose section: copy the delta's \`## Purpose\` body verbatim when it has one
115
141
  (this is what \`openspec archive\` does); only write a brief TBD placeholder when it does not
116
142
  - Add Requirements section with the ADDED requirements
117
143
  - Follow the **Main Spec Format Reference** below
118
144
 
119
- 5. **Show summary**
145
+ 5. **Validate updated main specs**
146
+
147
+ Run \`openspec validate --specs\` with the same selected-root flags used earlier.
148
+ If validation fails, report the problems and do not claim the sync succeeded.
149
+
150
+ 6. **Show summary**
120
151
 
121
152
  After applying all changes, summarize:
122
153
  - Which capabilities were updated
123
154
  - What changes were made (requirements added/modified/removed/renamed)
124
155
  - Any new main spec left with a TBD Purpose placeholder, so it gets written
125
156
  now rather than lingering
157
+ - Any capability retired, naming the deleted \`spec.md\`, its Purpose, and
158
+ either a pasteable \`git checkout\` or checkout-scoped recovery guidance
126
159
 
127
160
  **Delta Spec Format Reference**
128
161
 
@@ -143,6 +176,12 @@ The system SHALL do something new.
143
176
  ## MODIFIED Requirements
144
177
 
145
178
  ### Requirement: Existing Feature
179
+ The system SHALL keep doing the existing thing, now also handling A.
180
+
181
+ #### Scenario: Scenario the main spec already has
182
+ - **WHEN** user does X
183
+ - **THEN** system does Y
184
+
146
185
  #### Scenario: New scenario to add
147
186
  - **WHEN** user does A
148
187
  - **THEN** system does B
@@ -179,9 +218,9 @@ The system SHALL do something new.
179
218
 
180
219
  **Key Principle: Intelligent Merging**
181
220
 
182
- Unlike programmatic merging, you can apply **partial updates**:
183
- - To add a scenario, just include that scenario under MODIFIED - don't copy existing scenarios
184
- - The delta represents *intent*, not a wholesale replacement
221
+ Unlike programmatic merging, you merge rather than overwrite:
222
+ - A MODIFIED block carries the whole requirement - body plus every scenario that survives the change. \`openspec validate\` and \`openspec archive\` both reject one that drops a scenario the main spec still has.
223
+ - Keep anything the delta does not mention, in the main spec's existing order
185
224
  - Use your judgment to merge changes sensibly
186
225
 
187
226
  **Output On Success**
@@ -231,6 +270,8 @@ This is an **agent-driven** operation - you will read delta specs and directly e
231
270
 
232
271
  ${STORE_SELECTION_GUIDANCE}
233
272
 
273
+ \`<capability-path>\` is the spec directory relative to \`specs/\` (for example, \`user-auth\` or \`identity/user-auth\`). Preserve the full path from each delta spec when resolving its main spec.
274
+
234
275
  **Input**: Optionally specify a change name after \`/opsx:sync\` (e.g., \`/opsx:sync add-auth\`). If omitted, check if it can be inferred from conversation context. If vague or ambiguous you MUST prompt for available changes.
235
276
 
236
277
  **Steps**
@@ -264,8 +305,10 @@ ${STORE_SELECTION_GUIDANCE}
264
305
  instructions or writing a main spec.
265
306
 
266
307
  Sync every path in \`existingOutputPaths\` unless the caller narrowed the set.
267
- A caller narrows it by naming an explicit list of delta spec paths to sync —
268
- archive does this inline, and a user can too ("only sync the billing delta").
308
+ A caller narrows it by naming an explicit list of complete entries from
309
+ \`existingOutputPaths\` — copy those absolute values verbatim. Archive does
310
+ this inline, and a user can too (for example, by selecting the entry ending
311
+ in \`/specs/billing/invoices/spec.md\`).
269
312
  Then sync only the named paths and leave the remaining delta specs untouched:
270
313
  bulk archive excludes a delta whose implementation it could not find, and
271
314
  syncing it anyway would write a main spec the caller deliberately withheld.
@@ -305,7 +348,7 @@ ${STORE_SELECTION_GUIDANCE}
305
348
 
306
349
  a. **Read the delta spec** to understand the intended changes
307
350
 
308
- b. **Read the main spec** at \`<planningHome.root>/openspec/specs/<capability>/spec.md\` (may not exist yet)
351
+ b. **Read the main spec** at \`<planningHome.root>/openspec/specs/<capability-path>/spec.md\` (may not exist yet)
309
352
 
310
353
  c. **Apply changes intelligently**:
311
354
 
@@ -316,13 +359,35 @@ ${STORE_SELECTION_GUIDANCE}
316
359
  **MODIFIED Requirements:**
317
360
  - Find the requirement in main spec
318
361
  - Apply the changes - this can be:
319
- - Adding new scenarios (don't need to copy existing ones)
362
+ - Adding new scenarios the main spec does not have yet
320
363
  - Modifying existing scenarios
321
364
  - Changing the requirement description
322
365
  - Preserve scenarios/content not mentioned in the delta
323
366
 
324
367
  **REMOVED Requirements:**
325
368
  - Remove the entire requirement block from main spec
369
+ - Retiring the capability. Delete the whole \`spec.md\` - and the directory once
370
+ nothing else is left in it - only when ALL of these hold:
371
+ 1. removing the requirements *this run* left no requirement blocks;
372
+ 2. the rest of the spec is well-formed (it still has a \`## Purpose\`);
373
+ 3. the main spec was not already empty before this sync - if you removed
374
+ nothing, change nothing;
375
+ 4. every other nonblank line in the whole file is accounted for as the
376
+ title, Purpose, Requirements header, or a canonical requirement's
377
+ statement, scenarios, or fenced examples;
378
+ 5. the change's \`.openspec.yaml\` declares \`retire_capabilities: true\`;
379
+ 6. the \`spec.md\` resolves inside the real specs root (do not follow a
380
+ capability-directory symlink to delete an external file).
381
+ If removing the selected requirements would leave no requirement blocks and
382
+ any retirement condition is not satisfied, do not modify the main spec. Stop
383
+ the sync for that capability, report the blocking condition, and tell the user
384
+ how to resolve it. Never write or leave an empty \`## Requirements\` section.
385
+ When only the marker is missing, say that too - it is the one thing the user
386
+ can add to make the retirement go through.
387
+ - Deleting the file also deletes its \`## Purpose\`; any other section blocks
388
+ retirement. Name Purpose when you report the retirement. Include a pasteable
389
+ \`git checkout\` only when the spec lived in the caller's checkout;
390
+ otherwise give checkout-scoped recovery guidance.
326
391
 
327
392
  **RENAMED Requirements:**
328
393
  - Find the FROM requirement, rename to TO
@@ -332,19 +397,26 @@ ${STORE_SELECTION_GUIDANCE}
332
397
  (this is what \`openspec archive\` does; it warns and moves on)
333
398
 
334
399
  d. **Create new main spec** if capability doesn't exist yet:
335
- - Create \`<planningHome.root>/openspec/specs/<capability>/spec.md\`
400
+ - Create \`<planningHome.root>/openspec/specs/<capability-path>/spec.md\`
336
401
  - Add Purpose section: copy the delta's \`## Purpose\` body verbatim when it has one
337
402
  (this is what \`openspec archive\` does); only write a brief TBD placeholder when it does not
338
403
  - Add Requirements section with the ADDED requirements
339
404
  - Follow the **Main Spec Format Reference** below
340
405
 
341
- 5. **Show summary**
406
+ 5. **Validate updated main specs**
407
+
408
+ Run \`openspec validate --specs\` with the same selected-root flags used earlier.
409
+ If validation fails, report the problems and do not claim the sync succeeded.
410
+
411
+ 6. **Show summary**
342
412
 
343
413
  After applying all changes, summarize:
344
414
  - Which capabilities were updated
345
415
  - What changes were made (requirements added/modified/removed/renamed)
346
416
  - Any new main spec left with a TBD Purpose placeholder, so it gets written
347
417
  now rather than lingering
418
+ - Any capability retired, naming the deleted \`spec.md\`, its Purpose, and
419
+ either a pasteable \`git checkout\` or checkout-scoped recovery guidance
348
420
 
349
421
  **Delta Spec Format Reference**
350
422
 
@@ -365,6 +437,12 @@ The system SHALL do something new.
365
437
  ## MODIFIED Requirements
366
438
 
367
439
  ### Requirement: Existing Feature
440
+ The system SHALL keep doing the existing thing, now also handling A.
441
+
442
+ #### Scenario: Scenario the main spec already has
443
+ - **WHEN** user does X
444
+ - **THEN** system does Y
445
+
368
446
  #### Scenario: New scenario to add
369
447
  - **WHEN** user does A
370
448
  - **THEN** system does B
@@ -401,9 +479,9 @@ The system SHALL do something new.
401
479
 
402
480
  **Key Principle: Intelligent Merging**
403
481
 
404
- Unlike programmatic merging, you can apply **partial updates**:
405
- - To add a scenario, just include that scenario under MODIFIED - don't copy existing scenarios
406
- - The delta represents *intent*, not a wholesale replacement
482
+ Unlike programmatic merging, you merge rather than overwrite:
483
+ - A MODIFIED block carries the whole requirement - body plus every scenario that survives the change. \`openspec validate\` and \`openspec archive\` both reject one that drops a scenario the main spec still has.
484
+ - Keep anything the delta does not mention, in the main spec's existing order
407
485
  - Use your judgment to merge changes sensibly
408
486
 
409
487
  **Output On Success**
@@ -9,6 +9,8 @@ ${STORE_SELECTION_GUIDANCE}
9
9
 
10
10
  **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.
11
11
 
12
+ \`/opsx:continue\` is an optional workflow and may not be installed. Before suggesting it anywhere below, verify that it is available. If it is unavailable, \`openspec status --change "<name>" --json\` shows the next artifact and \`openspec instructions "<artifact-id>" --change "<name>" --json\` explains how to create it.
13
+
12
14
  **Steps**
13
15
 
14
16
  1. **Select the change**
@@ -35,7 +37,7 @@ ${STORE_SELECTION_GUIDANCE}
35
37
  Parse the JSON to understand current state. The response includes:
36
38
  - \`schemaName\`: The workflow schema being used (e.g., "spec-driven")
37
39
  - \`artifacts\`: Array of artifacts with their status ("done", "skipped", "ready", "blocked")
38
- - \`isComplete\`: Boolean indicating if all artifacts are complete
40
+ - \`isPlanningComplete\`: Boolean indicating if all planning artifacts are complete. Older CLI versions expose the same value as \`isComplete\`.
39
41
  - \`planningHome\`, \`changeRoot\`, \`artifactPaths\`, and \`actionContext\`: path and scope context. Use these instead of assuming repo-local paths.
40
42
 
41
43
  The artifact ids and paths come from the active schema - do NOT assume them, and do NOT branch on hardcoded artifact names. Custom schemas must work unchanged.
@@ -58,7 +60,7 @@ ${STORE_SELECTION_GUIDANCE}
58
60
  - If the user rejects a revision, do not write it - leave that artifact unchanged.
59
61
  - When a substantial rewrite is needed, get that artifact's rules and template first:
60
62
  \`\`\`bash
61
- openspec instructions <artifact-id> --change "<name>" --json
63
+ openspec instructions "<artifact-id>" --change "<name>" --json
62
64
  \`\`\`
63
65
 
64
66
  6. **Point to the next step (guidance only - NEVER act on it)**
@@ -79,8 +81,7 @@ After each invocation, show:
79
81
  - Edit only the concrete files in \`existingOutputPaths\`; never write to a glob \`resolvedOutputPath\`.
80
82
  - Do not advance the build frontier: no new artifacts, no new files under glob artifacts - that is \`/opsx:continue\`'s job.
81
83
  - Confirm every edit with the user before writing.
82
- - If the request changes the change's *intent* rather than refining it, recommend starting fresh with \`/opsx:new\` (the "Update vs. Start Fresh" heuristic).
83
- - \`/opsx:continue\` and \`/opsx:new\` may not be installed (core profile). When suggesting one that is unavailable, point to the CLI instead: \`openspec status --change "<name>" --json\` shows the next artifact and \`openspec instructions <artifact-id> --change "<name>" --json\` explains how to create it.`,
84
+ - If the request changes the change's *intent* rather than refining it, first verify whether the optional \`/opsx:new\` workflow is available. If it is, recommend starting fresh with \`/opsx:new\` (the "Update vs. Start Fresh" heuristic). If it is unavailable, ask for a distinct unused change name and recommend \`openspec new change "<new-change-name>"\` instead.`,
84
85
  license: 'MIT',
85
86
  compatibility: 'Requires openspec CLI.',
86
87
  metadata: { author: 'openspec', version: '1.0' },
@@ -98,6 +99,8 @@ ${STORE_SELECTION_GUIDANCE}
98
99
 
99
100
  **Input**: Optionally specify a change name after \`/opsx:update\` (e.g., \`/opsx:update add-auth\`). If omitted, check if it can be inferred from conversation context. If vague or ambiguous you MUST prompt for available changes.
100
101
 
102
+ \`/opsx:continue\` is an optional workflow and may not be installed. Before suggesting it anywhere below, verify that it is available. If it is unavailable, \`openspec status --change "<name>" --json\` shows the next artifact and \`openspec instructions "<artifact-id>" --change "<name>" --json\` explains how to create it.
103
+
101
104
  **Steps**
102
105
 
103
106
  1. **Select the change**
@@ -124,7 +127,7 @@ ${STORE_SELECTION_GUIDANCE}
124
127
  Parse the JSON to understand current state. The response includes:
125
128
  - \`schemaName\`: The workflow schema being used (e.g., "spec-driven")
126
129
  - \`artifacts\`: Array of artifacts with their status ("done", "skipped", "ready", "blocked")
127
- - \`isComplete\`: Boolean indicating if all artifacts are complete
130
+ - \`isPlanningComplete\`: Boolean indicating if all planning artifacts are complete. Older CLI versions expose the same value as \`isComplete\`.
128
131
  - \`planningHome\`, \`changeRoot\`, \`artifactPaths\`, and \`actionContext\`: path and scope context. Use these instead of assuming repo-local paths.
129
132
 
130
133
  The artifact ids and paths come from the active schema - do NOT assume them, and do NOT branch on hardcoded artifact names. Custom schemas must work unchanged.
@@ -147,7 +150,7 @@ ${STORE_SELECTION_GUIDANCE}
147
150
  - If the user rejects a revision, do not write it - leave that artifact unchanged.
148
151
  - When a substantial rewrite is needed, get that artifact's rules and template first:
149
152
  \`\`\`bash
150
- openspec instructions <artifact-id> --change "<name>" --json
153
+ openspec instructions "<artifact-id>" --change "<name>" --json
151
154
  \`\`\`
152
155
 
153
156
  6. **Point to the next step (guidance only - NEVER act on it)**
@@ -168,8 +171,7 @@ After each invocation, show:
168
171
  - Edit only the concrete files in \`existingOutputPaths\`; never write to a glob \`resolvedOutputPath\`.
169
172
  - Do not advance the build frontier: no new artifacts, no new files under glob artifacts - that is \`/opsx:continue\`'s job.
170
173
  - Confirm every edit with the user before writing.
171
- - If the request changes the change's *intent* rather than refining it, recommend starting fresh with \`/opsx:new\` (the "Update vs. Start Fresh" heuristic).
172
- - \`/opsx:continue\` and \`/opsx:new\` may not be installed (core profile). When suggesting one that is unavailable, point to the CLI instead: \`openspec status --change "<name>" --json\` shows the next artifact and \`openspec instructions <artifact-id> --change "<name>" --json\` explains how to create it.`
174
+ - If the request changes the change's *intent* rather than refining it, first verify whether the optional \`/opsx:new\` workflow is available. If it is, recommend starting fresh with \`/opsx:new\` (the "Update vs. Start Fresh" heuristic). If it is unavailable, ask for a distinct unused change name and recommend \`openspec new change "<new-change-name>"\` instead.`
173
175
  };
174
176
  }
175
177
  //# sourceMappingURL=update-change.js.map
@@ -28,6 +28,7 @@ export declare class UpdateCommand {
28
28
  * @param projectPath - Path to the project root containing the openspec directory
29
29
  */
30
30
  execute(projectPath: string): Promise<void>;
31
+ private syncCopilotCloudFiles;
31
32
  /**
32
33
  * Display message when all tools are up to date.
33
34
  */