Files
fission-ai__openspec/openspec/changes/archive/2026-01-06-add-specs-apply-command/tasks.md
Tabish Bidiwale eb15cdb983 chore: archive completed changes and clean up stale ones (#455)
Archive 5 completed changes:
- opsx-archive-command (synced specs)
- add-specs-apply-command
- add-per-change-schema-metadata
- make-apply-instructions-schema-aware (synced specs)
- add-agent-schema-selection

Delete 5 stale/abandoned changes:
- add-fingerprinting (no tasks, 7 weeks old)
- add-scaffold-command (0/7 tasks, 7 weeks old)
- add-proposal-frontmatter (no tasks, 8 weeks old)
- add-interactive-proposal-command (no tasks, 8 weeks old)
- make-validation-scope-aware (0/8 tasks, 4 months old)

Sync delta specs to main:
- Add opsx-archive-skill spec (new capability)
- Update cli-artifact-workflow spec with Schema Apply Block and
  Apply Instructions Command requirements
2026-01-06 23:52:11 -08:00

1.5 KiB

Tasks

Core Implementation

  • Extract spec application logic from ArchiveCommand into src/core/specs-apply.ts
    • Move buildUpdatedSpec(), findSpecUpdates(), writeUpdatedSpec() to shared module
    • Keep ArchiveCommand importing from the new module
    • Ensure all validation logic is preserved

Skill Template

  • Add getSyncSpecsSkillTemplate() function in src/core/templates/skill-templates.ts

    • Skill name: openspec-sync-specs
    • Description: Sync delta specs to main specs
    • Agent-driven: Instructions for agent to read deltas and edit main specs directly
  • Add /opsx:sync slash command template in skill-templates.ts

    • Mirror the skill template for slash command format
    • Agent-driven: No CLI command, agent does the merge

Registration

  • Register skill in managed skills (via artifact-experimental-setup)
    • Add to skill list with appropriate metadata
    • Ensure it appears in setup output

Design Decision

Why agent-driven instead of CLI-driven?

The programmatic merge operates at requirement-level granularity:

  • MODIFIED requires copying ALL scenarios, not just the changed ones
  • If agent forgets a scenario, it gets deleted
  • Delta specs become bloated with copied content

Agent-driven approach:

  • Agent can apply partial updates (add a scenario without copying others)
  • Delta represents intent, not wholesale replacement
  • More flexible and natural editing workflow
  • Archive still uses programmatic merge (for finalized changes)