Files
Tabish Bidiwale a5c10ed5e7 feat: add /opsx:sync command for syncing delta specs to main specs (#450)
* feat: add /opsx:sync command for syncing delta specs to main specs

Add a new agent-driven skill that syncs delta specs from a change to main specs
without requiring archiving. This enables:

- Updating main specs during active development
- Intelligent merging (partial updates, adding scenarios)
- Idempotent operation (safe to run multiple times)

Implementation:
- Extract shared specs-apply logic from archive.ts to specs-apply.ts
- Add getSyncSpecsSkillTemplate and getOpsxSyncCommandTemplate
- Register /opsx:sync in artifact-experimental-setup
- Add specs-sync-skill main spec

* fix: rename specs apply to specs sync throughout change artifacts

Update all references:
- /opsx:specs → /opsx:sync
- specs-apply-skill → specs-sync-skill
- Remove cli-artifact-workflow delta spec (no CLI command)
- Update proposal, design, and tasks docs
2026-01-06 16:32:22 -08:00

1.5 KiB

Why

Spec application is currently bundled with archive - users must run openspec archive to apply delta specs to main specs. This couples two distinct concerns (applying specs vs. archiving the change) and forces users to wait until they're "done" to see main specs updated. Users want the flexibility to sync specs earlier in the workflow while iterating.

What Changes

  • Add /opsx:sync skill that syncs delta specs to main specs as a standalone action
  • The operation is idempotent - safe to run multiple times, agent reconciles main specs to match deltas
  • Archive continues to work as today (applies specs if not already reconciled, then moves to archive)
  • No new state tracking - the agent reads delta and main specs, reconciles on each run
  • Agent-driven approach allows intelligent merging (partial updates, adding scenarios)

Workflow becomes:

/opsx:new → /opsx:continue → /opsx:apply → archive
                                  │
                                  └── /opsx:sync (optional, anytime)

Capabilities

New Capabilities

  • specs-sync-skill: Skill template for /opsx:sync command that reconciles main specs with delta specs

Modified Capabilities

  • None (agent-driven, no CLI command needed)

Impact

  • Skills: New openspec-sync-specs skill in skill-templates.ts
  • Archive: No changes needed - already does reconciliation, will continue to work
  • Agent workflow: Users gain flexibility to sync specs before archive