openspec/changes/unify-template-generation-pipeline/proposal.md
The recent split of skill-templates.ts into workflow modules improved readability, but the generation pipeline is still fragmented across multiple layers:
getSkillTemplates, getCommandTemplates, getCommandContents)AI_TOOLS, CommandAdapterRegistry, and hardcoded lists like SKILL_NAMESinit, update, and adapter code)init, update, and legacy-upgrade flowThis fragmentation creates drift risk (missing exports, missing metadata parity, mismatched counts/support) and makes future workflow/tool additions slower and less predictable.
WorkflowManifest as the single source of truth for all workflow artifactsToolProfileRegistry to centralize tool capabilities (skills path, command adapter, transforms)preAdapter, postAdapter) and scopes (skill, command, both)ArtifactSyncEngine used by init, update, and legacy upgrade pathstemplate-artifact-pipeline: Unified workflow manifest, tool profile registry, transform pipeline, and sync engine for skill/command generationcommand-generation: Extended to support ordered transform phases around adapter renderingcli-init: Uses shared artifact sync orchestration instead of bespoke loopscli-update: Uses shared artifact sync orchestration instead of bespoke loopssrc/core/templates/*src/core/shared/skill-generation.tssrc/core/command-generation/*src/core/init.tssrc/core/update.tssrc/core/shared/tool-detection.ts