moonshot-decide-sequence
Determines phase and execution chain based on analysisContext (task type, complexity, signals). Use after uncertainty detection.
Installation
Follow the repository instructions for this skill and your agent. Review the files and dependencies before adding it to your workflow.
View source ↗GuidesSkill instructions
PM Sequence Decision
Shared schema (analysisContext.v1)
schemaVersion: "1.0"
request:
userMessage: "..."
taskType: feature|modification|bugfix|refactor|unknown
keywords: []
repo:
gitBranch: "..."
gitStatus: clean|dirty
openFiles: []
changedFiles: []
signals:
hasContextMd: false
hasPendingQuestions: false
requirementsClear: false
implementationReady: false
implementationComplete: false
hasMockImplementation: false
apiSpecConfirmed: false
reactProject: false
estimates:
estimatedFiles: 0
estimatedLines: 0
estimatedTime: unknown
phase: planning|implementation|integration|verification|unknown
complexity: simple|medium|complex|unknown
missingInfo: []
decisions:
recommendedAgents: []
skillChain: []
parallelGroups: []
artifacts:
contextDocPath: {tasksRoot}/{feature-name}/context.md
verificationScript: .claude/agents/verification/verify-changes.sh
notes: []
Phase rules
- hasPendingQuestions == true -> planning
- implementationComplete == true && (complexity == complex or (apiSpecConfirmed && hasMockImplementation)) -> integration
- implementationComplete == true -> verification
- requirementsClear && hasContextMd && implementationReady -> implementation
- otherwise -> planning
Chain rules
Include only stages to run after moonshot-decide-sequence (do not include moonshot-* skills).
- simple: implementation-runner -> verify-changes.sh
- medium: requirements-analyzer -> implementation-runner -> completion-verifier -> codex-review-code -> efficiency-tracker
- complex: pre-flight-check -> requirements-analyzer -> context-builder -> codex-validate-plan -> implementation-runner -> completion-verifier -> codex-review-code -> efficiency-tracker -> session-logger
Complex always includes test-based completion verification.
Testing Integration (ref: .claude/rules/testing.md):
- medium/complex chains include
completion-verifierafter implementation - Request additional tests if coverage < 80%
- API changes require integration tests
Security & Build Error Integration:
-
security-reviewer: Triggered when security concern detected (auth changes, env file modified, new dependencies) -
build-error-resolver: Triggered whentsc/buildfails, inserted before next implementation step
Parallel execution guide
Only run dependency-free steps in parallel. If results affect the next stage, do not parallelize.
Possible parallel examples:
- After
/moonshot-classify-task:/moonshot-evaluate-complexity+/moonshot-detect-uncertainty - After implementation:
codex-review-code+verify-changes.sh(re-run verify if review changes) - Logging:
efficiency-tracker+session-logger
Not allowed in parallel:
-
requirements-analyzer<->context-builder(requirements must precede) -
codex-validate-plan<->implementation-runner(plan validation before implementation)
Output (patch)
phase: planning
decisions.skillChain:
- pre-flight-check
- requirements-analyzer
- context-builder
decisions.parallelGroups:
- - moonshot-evaluate-complexity
- moonshot-detect-uncertainty
decisions.recommendedAgents:
- requirements-analyzer
- context-builder
notes:
- "phase=planning, chain=complex"
Examples
Read the usage examples in the source repository.
View source ↗Source history
- Indexed on
- 2026-01-20
- Index updated
- 2026-01-26
- Branch
- main
Index and sync dates describe this directory. View the source repository for code history.
GitHub ↗chat Comments (0)
Sign in to join the discussion and leave a comment.
No comments yet. Be the first to share your thoughts!