@hanzlaa/rcode 2.1.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.
- package/AGENTS.md +120 -0
- package/CLAUDE.md +120 -0
- package/CONTRIBUTING.md +298 -0
- package/README.md +436 -0
- package/cli/config.js +142 -0
- package/cli/context.js +213 -0
- package/cli/dashboard.js +38 -0
- package/cli/digest.js +66 -0
- package/cli/doctor.js +283 -0
- package/cli/github-sync.js +1016 -0
- package/cli/index.js +113 -0
- package/cli/install.js +946 -0
- package/cli/lib/config.cjs +334 -0
- package/cli/lib/fsutil.cjs +76 -0
- package/cli/lib/github.cjs +365 -0
- package/cli/lib/manifest.cjs +240 -0
- package/cli/lib/memory-bank.cjs +348 -0
- package/cli/lib/model-profiles.cjs +169 -0
- package/cli/lib/prompts.cjs +355 -0
- package/cli/postinstall.js +32 -0
- package/cli/set-mode.js +94 -0
- package/cli/set-profile.js +80 -0
- package/cli/show-model.js +82 -0
- package/cli/team.js +35 -0
- package/cli/tiers.js +49 -0
- package/cli/uninstall.js +600 -0
- package/cli/update.js +373 -0
- package/package.json +60 -0
- package/rihal/agents/rihal-advisor-researcher.md +116 -0
- package/rihal/agents/rihal-ahmed.md +66 -0
- package/rihal/agents/rihal-architect.md +79 -0
- package/rihal/agents/rihal-assumptions-analyzer.md +117 -0
- package/rihal/agents/rihal-code-fixer.md +74 -0
- package/rihal/agents/rihal-code-reviewer.md +75 -0
- package/rihal/agents/rihal-codebase-mapper.md +170 -0
- package/rihal/agents/rihal-debugger.md +140 -0
- package/rihal/agents/rihal-deviation-analyzer.md +74 -0
- package/rihal/agents/rihal-docs-auditor.md +77 -0
- package/rihal/agents/rihal-edge-case-hunter.md +75 -0
- package/rihal/agents/rihal-executor.md +113 -0
- package/rihal/agents/rihal-fatima.md +68 -0
- package/rihal/agents/rihal-haitham.md +75 -0
- package/rihal/agents/rihal-hanzla.md +59 -0
- package/rihal/agents/rihal-hussain-pm.md +82 -0
- package/rihal/agents/rihal-integration-checker.md +455 -0
- package/rihal/agents/rihal-khalid.md +59 -0
- package/rihal/agents/rihal-layla.md +57 -0
- package/rihal/agents/rihal-mariam.md +58 -0
- package/rihal/agents/rihal-nasser.md +57 -0
- package/rihal/agents/rihal-noor.md +60 -0
- package/rihal/agents/rihal-nyquist-auditor.md +182 -0
- package/rihal/agents/rihal-omar.md +57 -0
- package/rihal/agents/rihal-phase-researcher.md +84 -0
- package/rihal/agents/rihal-planner.md +176 -0
- package/rihal/agents/rihal-profiler.md +74 -0
- package/rihal/agents/rihal-project-researcher.md +80 -0
- package/rihal/agents/rihal-remediation-planner.md +78 -0
- package/rihal/agents/rihal-research-synthesizer.md +253 -0
- package/rihal/agents/rihal-roadmapper.md +73 -0
- package/rihal/agents/rihal-sadiq.md +72 -0
- package/rihal/agents/rihal-security-adversary.md +82 -0
- package/rihal/agents/rihal-security-auditor.md +78 -0
- package/rihal/agents/rihal-sprint-checker.md +124 -0
- package/rihal/agents/rihal-tech-writer.md +80 -0
- package/rihal/agents/rihal-ui-auditor.md +81 -0
- package/rihal/agents/rihal-ui-designer.md +6 -0
- package/rihal/agents/rihal-ux-designer.md +83 -0
- package/rihal/agents/rihal-verifier.md +124 -0
- package/rihal/agents/rihal-waleed.md +60 -0
- package/rihal/agents/rihal-yousef.md +78 -0
- package/rihal/agents/rihal-zahra.md +62 -0
- package/rihal/agents/rihal-zayd.md +78 -0
- package/rihal/agents/rules/codebase-mapper/detailed-guide.md +615 -0
- package/rihal/agents/rules/debugger/checkpoint-recovery.md +272 -0
- package/rihal/agents/rules/debugger/debug-session-state.md +261 -0
- package/rihal/agents/rules/debugger/hypothesis-templates.md +330 -0
- package/rihal/agents/rules/debugger/investigation-protocol.md +298 -0
- package/rihal/agents/rules/debugger/scientific-method.md +317 -0
- package/rihal/agents/rules/executor/authentication-gates.md +202 -0
- package/rihal/agents/rules/executor/deviation-rules.md +191 -0
- package/rihal/agents/rules/executor/execution-flow.md +116 -0
- package/rihal/agents/rules/executor/self-check.md +241 -0
- package/rihal/agents/rules/executor/stub-detection.md +267 -0
- package/rihal/agents/rules/executor/summary-creation.md +76 -0
- package/rihal/agents/rules/executor/task-commit-protocol.md +283 -0
- package/rihal/agents/rules/executor/tdd-flow.md +294 -0
- package/rihal/agents/rules/phase-researcher/detailed-guide.md +628 -0
- package/rihal/agents/rules/planner/common-patterns.md +373 -0
- package/rihal/agents/rules/planner/dependency-analysis.md +195 -0
- package/rihal/agents/rules/planner/goal-backward-thinking.md +220 -0
- package/rihal/agents/rules/planner/sprint-verification.md +202 -0
- package/rihal/agents/rules/planner/task-templates.md +296 -0
- package/rihal/agents/rules/project-researcher/detailed-guide.md +589 -0
- package/rihal/agents/rules/roadmapper/detailed-guide.md +620 -0
- package/rihal/agents/rules/sprint-checker/dimensions.md +414 -0
- package/rihal/agents/rules/sprint-checker/process.md +377 -0
- package/rihal/agents/rules/verifier/anti-patterns.md +94 -0
- package/rihal/agents/rules/verifier/artifact-verification.md +69 -0
- package/rihal/agents/rules/verifier/behavioral-spot-checks.md +49 -0
- package/rihal/agents/rules/verifier/context-loading.md +84 -0
- package/rihal/agents/rules/verifier/data-flow-trace.md +65 -0
- package/rihal/agents/rules/verifier/gap-output.md +51 -0
- package/rihal/agents/rules/verifier/key-links.md +56 -0
- package/rihal/agents/rules/verifier/requirements-coverage.md +28 -0
- package/rihal/agents/rules/verifier/verification-report.md +131 -0
- package/rihal/bin/lib/code-references.cjs +196 -0
- package/rihal/bin/lib/config.cjs +146 -0
- package/rihal/bin/lib/council-panel.cjs +501 -0
- package/rihal/bin/lib/roadmap.cjs +256 -0
- package/rihal/bin/lib/verify.cjs +118 -0
- package/rihal/bin/rihal-hooks.cjs +204 -0
- package/rihal/bin/rihal-tools.cjs +3554 -0
- package/rihal/brain/README.md +38 -0
- package/rihal/brain/best-practices/no-autonomous-bypass.md +37 -0
- package/rihal/brain/best-practices/research-citation-rule.md +39 -0
- package/rihal/brain/best-practices/state-sync-rule.md +43 -0
- package/rihal/brain/sources.yaml +59 -0
- package/rihal/commands/add-phase.md +18 -0
- package/rihal/commands/add-tests.md +18 -0
- package/rihal/commands/add-todo.md +8 -0
- package/rihal/commands/analyze-dependencies.md +11 -0
- package/rihal/commands/audit-fix.md +14 -0
- package/rihal/commands/audit-milestone.md +12 -0
- package/rihal/commands/audit-uat.md +18 -0
- package/rihal/commands/autonomous.md +19 -0
- package/rihal/commands/brainstorm.md +11 -0
- package/rihal/commands/chain.md +8 -0
- package/rihal/commands/check-implementation-readiness.md +8 -0
- package/rihal/commands/check-todos.md +18 -0
- package/rihal/commands/cleanup.md +18 -0
- package/rihal/commands/code-review-fix.md +14 -0
- package/rihal/commands/code-review.md +14 -0
- package/rihal/commands/complete-milestone.md +12 -0
- package/rihal/commands/config.md +8 -0
- package/rihal/commands/correct-course.md +8 -0
- package/rihal/commands/council.md +25 -0
- package/rihal/commands/create-epics-and-stories.md +8 -0
- package/rihal/commands/create-story.md +8 -0
- package/rihal/commands/dashboard.md +10 -0
- package/rihal/commands/debug.md +8 -0
- package/rihal/commands/decisions.md +10 -0
- package/rihal/commands/dev-story.md +8 -0
- package/rihal/commands/diff.md +10 -0
- package/rihal/commands/discuss-phase-power.md +11 -0
- package/rihal/commands/discuss-phase.md +19 -0
- package/rihal/commands/discuss.md +23 -0
- package/rihal/commands/do.md +22 -0
- package/rihal/commands/docs-update.md +14 -0
- package/rihal/commands/document-project.md +8 -0
- package/rihal/commands/enable-hooks.md +11 -0
- package/rihal/commands/execute-sprint.md +13 -0
- package/rihal/commands/execute.md +19 -0
- package/rihal/commands/explore.md +14 -0
- package/rihal/commands/export-to-github.md +11 -0
- package/rihal/commands/forensics.md +11 -0
- package/rihal/commands/from-template.md +11 -0
- package/rihal/commands/health.md +10 -0
- package/rihal/commands/help.md +8 -0
- package/rihal/commands/import.md +12 -0
- package/rihal/commands/inbox.md +12 -0
- package/rihal/commands/init.md +14 -0
- package/rihal/commands/insert-phase.md +11 -0
- package/rihal/commands/install.md +10 -0
- package/rihal/commands/karpathy-audit.md +12 -0
- package/rihal/commands/list-plans.md +11 -0
- package/rihal/commands/list-workspaces.md +10 -0
- package/rihal/commands/map-codebase.md +14 -0
- package/rihal/commands/milestone-summary.md +11 -0
- package/rihal/commands/new-milestone.md +12 -0
- package/rihal/commands/new-project-research.md +11 -0
- package/rihal/commands/new-project-roadmap.md +11 -0
- package/rihal/commands/new-project.md +13 -0
- package/rihal/commands/new-workspace.md +12 -0
- package/rihal/commands/next.md +19 -0
- package/rihal/commands/note.md +12 -0
- package/rihal/commands/notify-test.md +10 -0
- package/rihal/commands/pause-work.md +8 -0
- package/rihal/commands/plan-milestone-gaps.md +18 -0
- package/rihal/commands/plan.md +19 -0
- package/rihal/commands/plant-seed.md +18 -0
- package/rihal/commands/pr-branch.md +18 -0
- package/rihal/commands/profile-user.md +8 -0
- package/rihal/commands/progress.md +19 -0
- package/rihal/commands/quick.md +14 -0
- package/rihal/commands/remove-phase.md +18 -0
- package/rihal/commands/remove-workspace.md +11 -0
- package/rihal/commands/replay.md +11 -0
- package/rihal/commands/report.md +10 -0
- package/rihal/commands/rerun.md +11 -0
- package/rihal/commands/research-phase.md +18 -0
- package/rihal/commands/resume-work.md +8 -0
- package/rihal/commands/review-adversarial.md +8 -0
- package/rihal/commands/review-edge-case-hunter.md +8 -0
- package/rihal/commands/review.md +18 -0
- package/rihal/commands/scan.md +14 -0
- package/rihal/commands/secure-phase.md +14 -0
- package/rihal/commands/session-report.md +10 -0
- package/rihal/commands/settings.md +8 -0
- package/rihal/commands/ship.md +18 -0
- package/rihal/commands/show.md +10 -0
- package/rihal/commands/sprint-planning.md +20 -0
- package/rihal/commands/sprint-status.md +21 -0
- package/rihal/commands/stats.md +10 -0
- package/rihal/commands/status.md +21 -0
- package/rihal/commands/ui-phase.md +8 -0
- package/rihal/commands/ui-review.md +8 -0
- package/rihal/commands/undo.md +14 -0
- package/rihal/commands/update.md +11 -0
- package/rihal/commands/validate-phase.md +18 -0
- package/rihal/commands/verify-phase.md +18 -0
- package/rihal/commands/verify-work.md +19 -0
- package/rihal/commands/why.md +10 -0
- package/rihal/commands/workstream.md +11 -0
- package/rihal/config/model-profiles.json +226 -0
- package/rihal/config/model-profiles.schema.json +36 -0
- package/rihal/config.yaml +39 -0
- package/rihal/digests/README.md +50 -0
- package/rihal/digests/fatima.md +24 -0
- package/rihal/digests/hussain-pm.md +24 -0
- package/rihal/digests/mariam.md +24 -0
- package/rihal/digests/sadiq.md +24 -0
- package/rihal/digests/waleed.md +24 -0
- package/rihal/modules/core.yaml +101 -0
- package/rihal/modules/discovery.yaml +50 -0
- package/rihal/modules/execution.yaml +66 -0
- package/rihal/references/brain-methods.csv +9 -0
- package/rihal/references/checklist-architect.md +146 -0
- package/rihal/references/checklist-change.md +136 -0
- package/rihal/references/checklist-pm.md +154 -0
- package/rihal/references/checklist-po-master.md +100 -0
- package/rihal/references/checklist-story-dod.md +75 -0
- package/rihal/references/checklist-story-draft.md +53 -0
- package/rihal/references/checkpoints-index.md +53 -0
- package/rihal/references/checkpoints.md +778 -0
- package/rihal/references/codebase-grounding.md +76 -0
- package/rihal/references/command-redirect-format.md +62 -0
- package/rihal/references/commit-conventions.md +125 -0
- package/rihal/references/common-bug-patterns-index.md +44 -0
- package/rihal/references/common-bug-patterns.md +621 -0
- package/rihal/references/context-budget.md +104 -0
- package/rihal/references/continuation-format.md +249 -0
- package/rihal/references/council-protocol.md +91 -0
- package/rihal/references/domain-probes.md +213 -0
- package/rihal/references/elicitation-methods.csv +16 -0
- package/rihal/references/execution-protocol.md +155 -0
- package/rihal/references/gate-prompts.md +212 -0
- package/rihal/references/gates.md +127 -0
- package/rihal/references/git-integration.md +159 -0
- package/rihal/references/git-planning-commit.md +185 -0
- package/rihal/references/karpathy-guidelines.md +79 -0
- package/rihal/references/model-profiles.md +90 -0
- package/rihal/references/no-unauthorized-git-ops.md +73 -0
- package/rihal/references/output-format.md +319 -0
- package/rihal/references/output-realism.md +52 -0
- package/rihal/references/project-types.yaml +270 -0
- package/rihal/references/questioning.md +163 -0
- package/rihal/references/response-style.md +81 -0
- package/rihal/references/state-schema.md +366 -0
- package/rihal/references/tdd.md +263 -0
- package/rihal/references/thinking-models-debug.md +126 -0
- package/rihal/references/thinking-models-planning.md +127 -0
- package/rihal/references/ui-brand.md +254 -0
- package/rihal/references/verification-patterns-index.md +76 -0
- package/rihal/references/verification-patterns.md +612 -0
- package/rihal/references/workstream-flag.md +166 -0
- package/rihal/skills/SKILLS_INDEX.md +114 -0
- package/rihal/skills/_shared/no-autonomous-bypass.md +37 -0
- package/rihal/skills/_shared/research-citation-rule.md +39 -0
- package/rihal/skills/_shared/state-sync-rule.md +43 -0
- package/rihal/skills/actions/1-analysis/research/rihal-domain-research/SKILL.md +31 -0
- package/rihal/skills/actions/1-analysis/research/rihal-domain-research/domain-steps/step-01-init.md +137 -0
- package/rihal/skills/actions/1-analysis/research/rihal-domain-research/domain-steps/step-02-domain-analysis.md +229 -0
- package/rihal/skills/actions/1-analysis/research/rihal-domain-research/domain-steps/step-03-competitive-landscape.md +238 -0
- package/rihal/skills/actions/1-analysis/research/rihal-domain-research/domain-steps/step-04-regulatory-focus.md +206 -0
- package/rihal/skills/actions/1-analysis/research/rihal-domain-research/domain-steps/step-05-technical-trends.md +234 -0
- package/rihal/skills/actions/1-analysis/research/rihal-domain-research/domain-steps/step-06-research-synthesis.md +444 -0
- package/rihal/skills/actions/1-analysis/research/rihal-domain-research/research.template.md +29 -0
- package/rihal/skills/actions/1-analysis/research/rihal-domain-research/workflow.md +49 -0
- package/rihal/skills/actions/1-analysis/research/rihal-market-research/SKILL.md +30 -0
- package/rihal/skills/actions/1-analysis/research/rihal-market-research/research.template.md +29 -0
- package/rihal/skills/actions/1-analysis/research/rihal-market-research/steps/step-01-init.md +184 -0
- package/rihal/skills/actions/1-analysis/research/rihal-market-research/steps/step-02-customer-behavior.md +239 -0
- package/rihal/skills/actions/1-analysis/research/rihal-market-research/steps/step-03-customer-pain-points.md +251 -0
- package/rihal/skills/actions/1-analysis/research/rihal-market-research/steps/step-04-customer-decisions.md +261 -0
- package/rihal/skills/actions/1-analysis/research/rihal-market-research/steps/step-05-competitive-analysis.md +173 -0
- package/rihal/skills/actions/1-analysis/research/rihal-market-research/steps/step-06-research-completion.md +478 -0
- package/rihal/skills/actions/1-analysis/research/rihal-market-research/workflow.md +49 -0
- package/rihal/skills/actions/1-analysis/research/rihal-technical-research/SKILL.md +31 -0
- package/rihal/skills/actions/1-analysis/research/rihal-technical-research/research.template.md +29 -0
- package/rihal/skills/actions/1-analysis/research/rihal-technical-research/technical-steps/step-01-init.md +137 -0
- package/rihal/skills/actions/1-analysis/research/rihal-technical-research/technical-steps/step-02-technical-overview.md +239 -0
- package/rihal/skills/actions/1-analysis/research/rihal-technical-research/technical-steps/step-03-integration-patterns.md +248 -0
- package/rihal/skills/actions/1-analysis/research/rihal-technical-research/technical-steps/step-04-architectural-patterns.md +202 -0
- package/rihal/skills/actions/1-analysis/research/rihal-technical-research/technical-steps/step-05-implementation-research.md +233 -0
- package/rihal/skills/actions/1-analysis/research/rihal-technical-research/technical-steps/step-06-research-synthesis.md +487 -0
- package/rihal/skills/actions/1-analysis/research/rihal-technical-research/workflow.md +50 -0
- package/rihal/skills/actions/1-analysis/rihal-document-project/SKILL.md +30 -0
- package/rihal/skills/actions/1-analysis/rihal-document-project/checklist.md +245 -0
- package/rihal/skills/actions/1-analysis/rihal-document-project/documentation-requirements.csv +12 -0
- package/rihal/skills/actions/1-analysis/rihal-document-project/instructions.md +128 -0
- package/rihal/skills/actions/1-analysis/rihal-document-project/templates/deep-dive-template.md +345 -0
- package/rihal/skills/actions/1-analysis/rihal-document-project/templates/index-template.md +169 -0
- package/rihal/skills/actions/1-analysis/rihal-document-project/templates/project-overview-template.md +103 -0
- package/rihal/skills/actions/1-analysis/rihal-document-project/templates/project-scan-report-schema.json +160 -0
- package/rihal/skills/actions/1-analysis/rihal-document-project/templates/source-tree-template.md +135 -0
- package/rihal/skills/actions/1-analysis/rihal-document-project/workflow.md +27 -0
- package/rihal/skills/actions/1-analysis/rihal-document-project/workflows/deep-dive-instructions.md +299 -0
- package/rihal/skills/actions/1-analysis/rihal-document-project/workflows/deep-dive-workflow.md +34 -0
- package/rihal/skills/actions/1-analysis/rihal-document-project/workflows/full-scan-instructions.md +1107 -0
- package/rihal/skills/actions/1-analysis/rihal-document-project/workflows/full-scan-workflow.md +34 -0
- package/rihal/skills/actions/1-analysis/rihal-prfaq/SKILL.md +120 -0
- package/rihal/skills/actions/1-analysis/rihal-prfaq/agents/artifact-analyzer.md +60 -0
- package/rihal/skills/actions/1-analysis/rihal-prfaq/agents/web-researcher.md +49 -0
- package/rihal/skills/actions/1-analysis/rihal-prfaq/assets/prfaq-template.md +62 -0
- package/rihal/skills/actions/1-analysis/rihal-prfaq/references/customer-faq.md +55 -0
- package/rihal/skills/actions/1-analysis/rihal-prfaq/references/internal-faq.md +51 -0
- package/rihal/skills/actions/1-analysis/rihal-prfaq/references/press-release.md +60 -0
- package/rihal/skills/actions/1-analysis/rihal-prfaq/references/verdict.md +79 -0
- package/rihal/skills/actions/1-analysis/rihal-prfaq/rihal-manifest.json +16 -0
- package/rihal/skills/actions/1-analysis/rihal-product-brief/SKILL.md +112 -0
- package/rihal/skills/actions/1-analysis/rihal-product-brief/agents/artifact-analyzer.md +60 -0
- package/rihal/skills/actions/1-analysis/rihal-product-brief/agents/opportunity-reviewer.md +44 -0
- package/rihal/skills/actions/1-analysis/rihal-product-brief/agents/skeptic-reviewer.md +44 -0
- package/rihal/skills/actions/1-analysis/rihal-product-brief/agents/web-researcher.md +49 -0
- package/rihal/skills/actions/1-analysis/rihal-product-brief/prompts/contextual-discovery.md +57 -0
- package/rihal/skills/actions/1-analysis/rihal-product-brief/prompts/draft-and-review.md +86 -0
- package/rihal/skills/actions/1-analysis/rihal-product-brief/prompts/finalize.md +75 -0
- package/rihal/skills/actions/1-analysis/rihal-product-brief/prompts/guided-elicitation.md +70 -0
- package/rihal/skills/actions/1-analysis/rihal-product-brief/resources/brief-template.md +60 -0
- package/rihal/skills/actions/1-analysis/rihal-product-brief/rihal-manifest.json +17 -0
- package/rihal/skills/actions/2-plan/rihal-create-epics-and-stories/SKILL.md +30 -0
- package/rihal/skills/actions/2-plan/rihal-create-epics-and-stories/steps/step-01-validate-prerequisites.md +255 -0
- package/rihal/skills/actions/2-plan/rihal-create-epics-and-stories/steps/step-02-design-epics.md +212 -0
- package/rihal/skills/actions/2-plan/rihal-create-epics-and-stories/steps/step-03-create-stories.md +255 -0
- package/rihal/skills/actions/2-plan/rihal-create-epics-and-stories/steps/step-04-final-validation.md +131 -0
- package/rihal/skills/actions/2-plan/rihal-create-epics-and-stories/templates/epics-template.md +61 -0
- package/rihal/skills/actions/2-plan/rihal-create-epics-and-stories/workflow.md +54 -0
- package/rihal/skills/actions/2-plan/rihal-create-milestone/SKILL.md +39 -0
- package/rihal/skills/actions/2-plan/rihal-create-milestone/steps/README.md +30 -0
- package/rihal/skills/actions/2-plan/rihal-create-milestone/steps/step-01-init.md +62 -0
- package/rihal/skills/actions/2-plan/rihal-create-milestone/steps/step-02-outcomes.md +64 -0
- package/rihal/skills/actions/2-plan/rihal-create-milestone/steps/step-03-sequencing.md +65 -0
- package/rihal/skills/actions/2-plan/rihal-create-milestone/steps/step-04-windows.md +60 -0
- package/rihal/skills/actions/2-plan/rihal-create-milestone/steps/step-05-kill-criteria.md +59 -0
- package/rihal/skills/actions/2-plan/rihal-create-milestone/steps/step-06-phase-stubs.md +56 -0
- package/rihal/skills/actions/2-plan/rihal-create-milestone/steps/step-07-backlog.md +44 -0
- package/rihal/skills/actions/2-plan/rihal-create-milestone/steps/step-08-write-roadmap.md +58 -0
- package/rihal/skills/actions/2-plan/rihal-create-milestone/steps/step-09-state-sync.md +62 -0
- package/rihal/skills/actions/2-plan/rihal-create-milestone/steps/step-10-complete.md +56 -0
- package/rihal/skills/actions/2-plan/rihal-create-milestone/workflow.md +93 -0
- package/rihal/skills/actions/2-plan/rihal-create-prd/SKILL.md +40 -0
- package/rihal/skills/actions/2-plan/rihal-create-prd/data/domain-complexity.csv +15 -0
- package/rihal/skills/actions/2-plan/rihal-create-prd/data/prd-purpose.md +197 -0
- package/rihal/skills/actions/2-plan/rihal-create-prd/data/project-types.csv +11 -0
- package/rihal/skills/actions/2-plan/rihal-create-prd/steps-c/step-01-init.md +178 -0
- package/rihal/skills/actions/2-plan/rihal-create-prd/steps-c/step-01b-continue.md +161 -0
- package/rihal/skills/actions/2-plan/rihal-create-prd/steps-c/step-02-discovery.md +208 -0
- package/rihal/skills/actions/2-plan/rihal-create-prd/steps-c/step-02b-vision.md +142 -0
- package/rihal/skills/actions/2-plan/rihal-create-prd/steps-c/step-02c-executive-summary.md +158 -0
- package/rihal/skills/actions/2-plan/rihal-create-prd/steps-c/step-03-success.md +214 -0
- package/rihal/skills/actions/2-plan/rihal-create-prd/steps-c/step-04-journeys.md +201 -0
- package/rihal/skills/actions/2-plan/rihal-create-prd/steps-c/step-05-domain.md +194 -0
- package/rihal/skills/actions/2-plan/rihal-create-prd/steps-c/step-06-innovation.md +211 -0
- package/rihal/skills/actions/2-plan/rihal-create-prd/steps-c/step-07-project-type.md +222 -0
- package/rihal/skills/actions/2-plan/rihal-create-prd/steps-c/step-08-scoping.md +216 -0
- package/rihal/skills/actions/2-plan/rihal-create-prd/steps-c/step-09-functional.md +219 -0
- package/rihal/skills/actions/2-plan/rihal-create-prd/steps-c/step-10-nonfunctional.md +230 -0
- package/rihal/skills/actions/2-plan/rihal-create-prd/steps-c/step-11-polish.md +221 -0
- package/rihal/skills/actions/2-plan/rihal-create-prd/steps-c/step-12-complete.md +115 -0
- package/rihal/skills/actions/2-plan/rihal-create-prd/templates/prd-template.md +10 -0
- package/rihal/skills/actions/2-plan/rihal-create-prd/workflow.md +64 -0
- package/rihal/skills/actions/2-plan/rihal-create-story/SKILL.md +31 -0
- package/rihal/skills/actions/2-plan/rihal-create-story/checklist.md +357 -0
- package/rihal/skills/actions/2-plan/rihal-create-story/discover-inputs.md +88 -0
- package/rihal/skills/actions/2-plan/rihal-create-story/template.md +49 -0
- package/rihal/skills/actions/2-plan/rihal-create-story/workflow.md +380 -0
- package/rihal/skills/actions/2-plan/rihal-create-ux-design/SKILL.md +31 -0
- package/rihal/skills/actions/2-plan/rihal-create-ux-design/steps/step-01-init.md +135 -0
- package/rihal/skills/actions/2-plan/rihal-create-ux-design/steps/step-01b-continue.md +127 -0
- package/rihal/skills/actions/2-plan/rihal-create-ux-design/steps/step-02-discovery.md +190 -0
- package/rihal/skills/actions/2-plan/rihal-create-ux-design/steps/step-03-core-experience.md +217 -0
- package/rihal/skills/actions/2-plan/rihal-create-ux-design/steps/step-04-emotional-response.md +220 -0
- package/rihal/skills/actions/2-plan/rihal-create-ux-design/steps/step-05-inspiration.md +235 -0
- package/rihal/skills/actions/2-plan/rihal-create-ux-design/steps/step-06-design-system.md +253 -0
- package/rihal/skills/actions/2-plan/rihal-create-ux-design/steps/step-07-defining-experience.md +255 -0
- package/rihal/skills/actions/2-plan/rihal-create-ux-design/steps/step-08-visual-foundation.md +225 -0
- package/rihal/skills/actions/2-plan/rihal-create-ux-design/steps/step-09-design-directions.md +225 -0
- package/rihal/skills/actions/2-plan/rihal-create-ux-design/steps/step-10-user-journeys.md +242 -0
- package/rihal/skills/actions/2-plan/rihal-create-ux-design/steps/step-11-component-strategy.md +249 -0
- package/rihal/skills/actions/2-plan/rihal-create-ux-design/steps/step-12-ux-patterns.md +238 -0
- package/rihal/skills/actions/2-plan/rihal-create-ux-design/steps/step-13-responsive-accessibility.md +265 -0
- package/rihal/skills/actions/2-plan/rihal-create-ux-design/steps/step-14-complete.md +171 -0
- package/rihal/skills/actions/2-plan/rihal-create-ux-design/ux-design-template.md +13 -0
- package/rihal/skills/actions/2-plan/rihal-create-ux-design/workflow.md +36 -0
- package/rihal/skills/actions/2-plan/rihal-edit-prd/SKILL.md +30 -0
- package/rihal/skills/actions/2-plan/rihal-edit-prd/steps-e/step-e-01-discovery.md +242 -0
- package/rihal/skills/actions/2-plan/rihal-edit-prd/steps-e/step-e-01b-legacy-conversion.md +204 -0
- package/rihal/skills/actions/2-plan/rihal-edit-prd/steps-e/step-e-02-review.md +245 -0
- package/rihal/skills/actions/2-plan/rihal-edit-prd/steps-e/step-e-03-edit.md +250 -0
- package/rihal/skills/actions/2-plan/rihal-edit-prd/steps-e/step-e-04-complete.md +165 -0
- package/rihal/skills/actions/2-plan/rihal-edit-prd/workflow.md +63 -0
- package/rihal/skills/actions/2-plan/rihal-frontend-design/SKILL.md +169 -0
- package/rihal/skills/actions/2-plan/rihal-validate-prd/SKILL.md +29 -0
- package/rihal/skills/actions/2-plan/rihal-validate-prd/data/domain-complexity.csv +15 -0
- package/rihal/skills/actions/2-plan/rihal-validate-prd/data/prd-purpose.md +197 -0
- package/rihal/skills/actions/2-plan/rihal-validate-prd/data/project-types.csv +11 -0
- package/rihal/skills/actions/2-plan/rihal-validate-prd/steps-v/step-v-01-discovery.md +221 -0
- package/rihal/skills/actions/2-plan/rihal-validate-prd/steps-v/step-v-02-format-detection.md +188 -0
- package/rihal/skills/actions/2-plan/rihal-validate-prd/steps-v/step-v-02b-parity-check.md +206 -0
- package/rihal/skills/actions/2-plan/rihal-validate-prd/steps-v/step-v-03-density-validation.md +171 -0
- package/rihal/skills/actions/2-plan/rihal-validate-prd/steps-v/step-v-04-brief-coverage-validation.md +211 -0
- package/rihal/skills/actions/2-plan/rihal-validate-prd/steps-v/step-v-05-measurability-validation.md +225 -0
- package/rihal/skills/actions/2-plan/rihal-validate-prd/steps-v/step-v-06-traceability-validation.md +214 -0
- package/rihal/skills/actions/2-plan/rihal-validate-prd/steps-v/step-v-07-implementation-leakage-validation.md +202 -0
- package/rihal/skills/actions/2-plan/rihal-validate-prd/steps-v/step-v-08-domain-compliance-validation.md +240 -0
- package/rihal/skills/actions/2-plan/rihal-validate-prd/steps-v/step-v-09-project-type-validation.md +260 -0
- package/rihal/skills/actions/2-plan/rihal-validate-prd/steps-v/step-v-10-smart-validation.md +206 -0
- package/rihal/skills/actions/2-plan/rihal-validate-prd/steps-v/step-v-11-holistic-quality-validation.md +261 -0
- package/rihal/skills/actions/2-plan/rihal-validate-prd/steps-v/step-v-12-completeness-validation.md +239 -0
- package/rihal/skills/actions/2-plan/rihal-validate-prd/steps-v/step-v-13-report-complete.md +229 -0
- package/rihal/skills/actions/2-plan/rihal-validate-prd/workflow.md +62 -0
- package/rihal/skills/actions/3-solutioning/rihal-check-implementation-readiness/SKILL.md +30 -0
- package/rihal/skills/actions/3-solutioning/rihal-check-implementation-readiness/steps/step-01-document-discovery.md +179 -0
- package/rihal/skills/actions/3-solutioning/rihal-check-implementation-readiness/steps/step-02-prd-analysis.md +168 -0
- package/rihal/skills/actions/3-solutioning/rihal-check-implementation-readiness/steps/step-03-epic-coverage-validation.md +169 -0
- package/rihal/skills/actions/3-solutioning/rihal-check-implementation-readiness/steps/step-04-ux-alignment.md +129 -0
- package/rihal/skills/actions/3-solutioning/rihal-check-implementation-readiness/steps/step-05-epic-quality-review.md +241 -0
- package/rihal/skills/actions/3-solutioning/rihal-check-implementation-readiness/steps/step-06-final-assessment.md +126 -0
- package/rihal/skills/actions/3-solutioning/rihal-check-implementation-readiness/templates/readiness-report-template.md +4 -0
- package/rihal/skills/actions/3-solutioning/rihal-check-implementation-readiness/workflow.md +49 -0
- package/rihal/skills/actions/3-solutioning/rihal-create-architecture/SKILL.md +32 -0
- package/rihal/skills/actions/3-solutioning/rihal-create-architecture/architecture-decision-template.md +12 -0
- package/rihal/skills/actions/3-solutioning/rihal-create-architecture/data/domain-complexity.csv +13 -0
- package/rihal/skills/actions/3-solutioning/rihal-create-architecture/data/project-types.csv +7 -0
- package/rihal/skills/actions/3-solutioning/rihal-create-architecture/steps/step-01-init.md +153 -0
- package/rihal/skills/actions/3-solutioning/rihal-create-architecture/steps/step-01b-continue.md +173 -0
- package/rihal/skills/actions/3-solutioning/rihal-create-architecture/steps/step-02-context.md +224 -0
- package/rihal/skills/actions/3-solutioning/rihal-create-architecture/steps/step-03-starter.md +329 -0
- package/rihal/skills/actions/3-solutioning/rihal-create-architecture/steps/step-04-decisions.md +318 -0
- package/rihal/skills/actions/3-solutioning/rihal-create-architecture/steps/step-05-patterns.md +359 -0
- package/rihal/skills/actions/3-solutioning/rihal-create-architecture/steps/step-06-structure.md +379 -0
- package/rihal/skills/actions/3-solutioning/rihal-create-architecture/steps/step-07-validation.md +359 -0
- package/rihal/skills/actions/3-solutioning/rihal-create-architecture/steps/step-08-complete.md +76 -0
- package/rihal/skills/actions/3-solutioning/rihal-create-architecture/workflow.md +38 -0
- package/rihal/skills/actions/3-solutioning/rihal-generate-project-context/SKILL.md +31 -0
- package/rihal/skills/actions/3-solutioning/rihal-generate-project-context/project-context-template.md +21 -0
- package/rihal/skills/actions/3-solutioning/rihal-generate-project-context/steps/step-01-discover.md +186 -0
- package/rihal/skills/actions/3-solutioning/rihal-generate-project-context/steps/step-02-generate.md +321 -0
- package/rihal/skills/actions/3-solutioning/rihal-generate-project-context/steps/step-03-complete.md +278 -0
- package/rihal/skills/actions/3-solutioning/rihal-generate-project-context/workflow.md +43 -0
- package/rihal/skills/actions/4-implementation/rihal-checkpoint-preview/SKILL.md +48 -0
- package/rihal/skills/actions/4-implementation/rihal-checkpoint-preview/generate-trail.md +38 -0
- package/rihal/skills/actions/4-implementation/rihal-checkpoint-preview/step-01-orientation.md +105 -0
- package/rihal/skills/actions/4-implementation/rihal-checkpoint-preview/step-02-walkthrough.md +89 -0
- package/rihal/skills/actions/4-implementation/rihal-checkpoint-preview/step-03-detail-pass.md +106 -0
- package/rihal/skills/actions/4-implementation/rihal-checkpoint-preview/step-04-testing.md +74 -0
- package/rihal/skills/actions/4-implementation/rihal-checkpoint-preview/step-05-wrapup.md +24 -0
- package/rihal/skills/actions/4-implementation/rihal-code-review/SKILL.md +31 -0
- package/rihal/skills/actions/4-implementation/rihal-code-review/steps/step-01-gather-context.md +62 -0
- package/rihal/skills/actions/4-implementation/rihal-code-review/steps/step-02-review.md +34 -0
- package/rihal/skills/actions/4-implementation/rihal-code-review/steps/step-03-triage.md +49 -0
- package/rihal/skills/actions/4-implementation/rihal-code-review/steps/step-04-present.md +129 -0
- package/rihal/skills/actions/4-implementation/rihal-code-review/workflow.md +55 -0
- package/rihal/skills/actions/4-implementation/rihal-correct-course/SKILL.md +29 -0
- package/rihal/skills/actions/4-implementation/rihal-correct-course/checklist.md +288 -0
- package/rihal/skills/actions/4-implementation/rihal-correct-course/workflow.md +267 -0
- package/rihal/skills/actions/4-implementation/rihal-dev-story/SKILL.md +36 -0
- package/rihal/skills/actions/4-implementation/rihal-dev-story/checklist.md +80 -0
- package/rihal/skills/actions/4-implementation/rihal-dev-story/workflow.md +450 -0
- package/rihal/skills/actions/4-implementation/rihal-qa-generate-e2e-tests/SKILL.md +31 -0
- package/rihal/skills/actions/4-implementation/rihal-qa-generate-e2e-tests/checklist.md +33 -0
- package/rihal/skills/actions/4-implementation/rihal-qa-generate-e2e-tests/workflow.md +136 -0
- package/rihal/skills/actions/4-implementation/rihal-retrospective/SKILL.md +30 -0
- package/rihal/skills/actions/4-implementation/rihal-retrospective/workflow.md +1479 -0
- package/rihal/skills/actions/4-implementation/rihal-scaffold-project/SKILL.md +77 -0
- package/rihal/skills/actions/4-implementation/rihal-scaffold-project/steps/step-01-target.md +17 -0
- package/rihal/skills/actions/4-implementation/rihal-scaffold-project/steps/step-02-safety.md +35 -0
- package/rihal/skills/actions/4-implementation/rihal-scaffold-project/steps/step-03-clone.md +50 -0
- package/rihal/skills/actions/4-implementation/rihal-scaffold-project/steps/step-04-post-setup.md +44 -0
- package/rihal/skills/actions/4-implementation/rihal-sprint-planning/SKILL.md +35 -0
- package/rihal/skills/actions/4-implementation/rihal-sprint-planning/checklist.md +43 -0
- package/rihal/skills/actions/4-implementation/rihal-sprint-planning/sprint-status-template.yaml +56 -0
- package/rihal/skills/actions/4-implementation/rihal-sprint-planning/workflow.md +284 -0
- package/rihal/skills/actions/4-implementation/rihal-sprint-status/SKILL.md +30 -0
- package/rihal/skills/actions/4-implementation/rihal-sprint-status/workflow.md +261 -0
- package/rihal/skills/agents/ahmed-hassani-director/SKILL.md +121 -0
- package/rihal/skills/agents/fatima-qa/SKILL.md +106 -0
- package/rihal/skills/agents/fatima-qa/skill-manifest.yaml +11 -0
- package/rihal/skills/agents/haitham-frontend/SKILL.md +120 -0
- package/rihal/skills/agents/hanzla-engineer/SKILL.md +109 -0
- package/rihal/skills/agents/hanzla-engineer/skill-manifest.yaml +11 -0
- package/rihal/skills/agents/hussain-pm/SKILL.md +107 -0
- package/rihal/skills/agents/hussain-pm/skill-manifest.yaml +11 -0
- package/rihal/skills/agents/hussain-sm/SKILL.md +104 -0
- package/rihal/skills/agents/hussain-sm/skill-manifest.yaml +11 -0
- package/rihal/skills/agents/layla-designer/SKILL.md +96 -0
- package/rihal/skills/agents/layla-designer/skill-manifest.yaml +11 -0
- package/rihal/skills/agents/majlis-council/SKILL.md +179 -0
- package/rihal/skills/agents/mariam-marketing/SKILL.md +133 -0
- package/rihal/skills/agents/nasser-eng-manager/SKILL.md +125 -0
- package/rihal/skills/agents/noor-writer/SKILL.md +104 -0
- package/rihal/skills/agents/noor-writer/explain-concept.md +20 -0
- package/rihal/skills/agents/noor-writer/mermaid-gen.md +20 -0
- package/rihal/skills/agents/noor-writer/skill-manifest.yaml +11 -0
- package/rihal/skills/agents/noor-writer/validate-doc.md +19 -0
- package/rihal/skills/agents/noor-writer/write-document.md +20 -0
- package/rihal/skills/agents/raees-orchestrator/SKILL.md +154 -0
- package/rihal/skills/agents/sadiq-analyst/SKILL.md +106 -0
- package/rihal/skills/agents/sadiq-analyst/skill-manifest.yaml +11 -0
- package/rihal/skills/agents/waleed-architect/SKILL.md +106 -0
- package/rihal/skills/agents/waleed-architect/skill-manifest.yaml +11 -0
- package/rihal/skills/agents/yousef-backend/SKILL.md +136 -0
- package/rihal/skills/agents/zahra-branding/SKILL.md +141 -0
- package/rihal/skills/agents/zayd-ml/SKILL.md +124 -0
- package/rihal/skills/core/module-help.csv +11 -0
- package/rihal/skills/core/module.yaml +25 -0
- package/rihal/skills/core/rihal-advanced-elicitation/SKILL.md +155 -0
- package/rihal/skills/core/rihal-advanced-elicitation/methods.csv +51 -0
- package/rihal/skills/core/rihal-advanced-elicitation/rihal-advanced-elicitation/SKILL.md +148 -0
- package/rihal/skills/core/rihal-advanced-elicitation/rihal-advanced-elicitation/methods.csv +51 -0
- package/rihal/skills/core/rihal-brainstorming/SKILL.md +82 -0
- package/rihal/skills/core/rihal-brainstorming/brain-methods.csv +62 -0
- package/rihal/skills/core/rihal-brainstorming/steps/step-01-session-setup.md +214 -0
- package/rihal/skills/core/rihal-brainstorming/steps/step-01b-continue.md +124 -0
- package/rihal/skills/core/rihal-brainstorming/steps/step-02a-user-selected.md +229 -0
- package/rihal/skills/core/rihal-brainstorming/steps/step-02b-ai-recommended.md +239 -0
- package/rihal/skills/core/rihal-brainstorming/steps/step-02c-random-selection.md +211 -0
- package/rihal/skills/core/rihal-brainstorming/steps/step-02d-progressive-flow.md +266 -0
- package/rihal/skills/core/rihal-brainstorming/steps/step-03-technique-execution.md +401 -0
- package/rihal/skills/core/rihal-brainstorming/steps/step-04-idea-organization.md +305 -0
- package/rihal/skills/core/rihal-brainstorming/template.md +15 -0
- package/rihal/skills/core/rihal-brainstorming/workflow.md +53 -0
- package/rihal/skills/core/rihal-clone-website/SKILL.md +395 -0
- package/rihal/skills/core/rihal-distillator/SKILL.md +205 -0
- package/rihal/skills/core/rihal-distillator/agents/distillate-compressor.md +116 -0
- package/rihal/skills/core/rihal-distillator/agents/round-trip-reconstructor.md +68 -0
- package/rihal/skills/core/rihal-distillator/resources/compression-rules.md +51 -0
- package/rihal/skills/core/rihal-distillator/resources/distillate-format-reference.md +227 -0
- package/rihal/skills/core/rihal-distillator/resources/splitting-strategy.md +78 -0
- package/rihal/skills/core/rihal-distillator/scripts/analyze_sources.py +300 -0
- package/rihal/skills/core/rihal-distillator/scripts/tests/test_analyze_sources.py +204 -0
- package/rihal/skills/core/rihal-editorial-review-prose/SKILL.md +108 -0
- package/rihal/skills/core/rihal-editorial-review-structure/SKILL.md +193 -0
- package/rihal/skills/core/rihal-help/SKILL.md +91 -0
- package/rihal/skills/core/rihal-index-docs/SKILL.md +80 -0
- package/rihal/skills/core/rihal-init/SKILL.md +119 -0
- package/rihal/skills/core/rihal-init/resources/core-module.yaml +25 -0
- package/rihal/skills/core/rihal-init/scripts/rihal_init.py +593 -0
- package/rihal/skills/core/rihal-init/scripts/tests/test_rihal_init.py +329 -0
- package/rihal/skills/core/rihal-party-mode/SKILL.md +77 -0
- package/rihal/skills/core/rihal-party-mode/steps/step-01-agent-loading.md +138 -0
- package/rihal/skills/core/rihal-party-mode/steps/step-02-discussion-orchestration.md +187 -0
- package/rihal/skills/core/rihal-party-mode/steps/step-03-graceful-exit.md +167 -0
- package/rihal/skills/core/rihal-party-mode/workflow.md +190 -0
- package/rihal/skills/core/rihal-review-adversarial-general/SKILL.md +55 -0
- package/rihal/skills/core/rihal-review-edge-case-hunter/SKILL.md +81 -0
- package/rihal/skills/core/rihal-shard-doc/SKILL.md +119 -0
- package/rihal/skills/core/rihal-shard-doc/rihal-shard-doc/SKILL.md +122 -0
- package/rihal/team.yaml +343 -0
- package/rihal/templates/UI-SPEC.md +127 -0
- package/rihal/templates/documentation-requirements.csv +11 -0
- package/rihal/templates/github/bug-template.md +53 -0
- package/rihal/templates/github/epic-template.md +57 -0
- package/rihal/templates/github/feature-template.md +55 -0
- package/rihal/templates/github/task-template.md +52 -0
- package/rihal/templates/milestone.md +147 -0
- package/rihal/templates/projects/api-backend/PROJECT.md +37 -0
- package/rihal/templates/projects/api-backend/REQUIREMENTS.md +38 -0
- package/rihal/templates/projects/api-backend/ROADMAP.md +92 -0
- package/rihal/templates/projects/api-backend/template.yaml +17 -0
- package/rihal/templates/projects/mobile-app/PROJECT.md +37 -0
- package/rihal/templates/projects/mobile-app/REQUIREMENTS.md +32 -0
- package/rihal/templates/projects/mobile-app/ROADMAP.md +93 -0
- package/rihal/templates/projects/mobile-app/template.yaml +17 -0
- package/rihal/templates/projects/saas-b2b/PROJECT.md +40 -0
- package/rihal/templates/projects/saas-b2b/REQUIREMENTS.md +38 -0
- package/rihal/templates/projects/saas-b2b/ROADMAP.md +95 -0
- package/rihal/templates/projects/saas-b2b/template.yaml +18 -0
- package/rihal/templates/settings-hooks.json +36 -0
- package/rihal/templates/sprint.md +70 -0
- package/rihal/workflows/add-phase.md +112 -0
- package/rihal/workflows/add-tests.md +351 -0
- package/rihal/workflows/add-todo.md +181 -0
- package/rihal/workflows/analyze-dependencies.md +138 -0
- package/rihal/workflows/audit-fix.md +190 -0
- package/rihal/workflows/audit-milestone.md +155 -0
- package/rihal/workflows/audit-uat.md +109 -0
- package/rihal/workflows/autonomous.md +992 -0
- package/rihal/workflows/brainstorm.md +203 -0
- package/rihal/workflows/chain.md +188 -0
- package/rihal/workflows/check-implementation-readiness.md +193 -0
- package/rihal/workflows/check-todos.md +177 -0
- package/rihal/workflows/cleanup.md +152 -0
- package/rihal/workflows/code-review-fix.md +529 -0
- package/rihal/workflows/code-review.md +566 -0
- package/rihal/workflows/complete-milestone.md +836 -0
- package/rihal/workflows/config.md +105 -0
- package/rihal/workflows/correct-course.md +190 -0
- package/rihal/workflows/council.md +565 -0
- package/rihal/workflows/create-epics-and-stories.md +373 -0
- package/rihal/workflows/create-story.md +297 -0
- package/rihal/workflows/dashboard.md +102 -0
- package/rihal/workflows/debug.md +256 -0
- package/rihal/workflows/decisions.md +107 -0
- package/rihal/workflows/dev-story.md +432 -0
- package/rihal/workflows/diff.md +74 -0
- package/rihal/workflows/discuss-phase-power.md +325 -0
- package/rihal/workflows/discuss-phase.md +1201 -0
- package/rihal/workflows/discuss.md +227 -0
- package/rihal/workflows/do.md +175 -0
- package/rihal/workflows/docs-update.md +261 -0
- package/rihal/workflows/document-project.md +180 -0
- package/rihal/workflows/enable-hooks.md +102 -0
- package/rihal/workflows/execute-sprint.md +514 -0
- package/rihal/workflows/execute.md +1478 -0
- package/rihal/workflows/explore.md +171 -0
- package/rihal/workflows/export-to-github.md +174 -0
- package/rihal/workflows/forensics.md +201 -0
- package/rihal/workflows/from-template.md +173 -0
- package/rihal/workflows/health.md +194 -0
- package/rihal/workflows/help.md +318 -0
- package/rihal/workflows/import.md +306 -0
- package/rihal/workflows/inbox.md +418 -0
- package/rihal/workflows/init.md +245 -0
- package/rihal/workflows/insert-phase.md +116 -0
- package/rihal/workflows/install.md +85 -0
- package/rihal/workflows/karpathy-audit.md +409 -0
- package/rihal/workflows/list-plans.md +146 -0
- package/rihal/workflows/list-workspaces.md +115 -0
- package/rihal/workflows/map-codebase.md +449 -0
- package/rihal/workflows/milestone-summary.md +206 -0
- package/rihal/workflows/new-milestone.md +616 -0
- package/rihal/workflows/new-project-research.md +262 -0
- package/rihal/workflows/new-project-roadmap.md +446 -0
- package/rihal/workflows/new-project.md +1503 -0
- package/rihal/workflows/new-workspace.md +167 -0
- package/rihal/workflows/next.md +162 -0
- package/rihal/workflows/note.md +156 -0
- package/rihal/workflows/notify-test.md +113 -0
- package/rihal/workflows/pause-work.md +243 -0
- package/rihal/workflows/plan-milestone-gaps.md +273 -0
- package/rihal/workflows/plan.md +1262 -0
- package/rihal/workflows/plant-seed.md +169 -0
- package/rihal/workflows/pr-branch.md +129 -0
- package/rihal/workflows/profile-user.md +162 -0
- package/rihal/workflows/progress.md +184 -0
- package/rihal/workflows/quick.md +105 -0
- package/rihal/workflows/remove-phase.md +155 -0
- package/rihal/workflows/remove-workspace.md +158 -0
- package/rihal/workflows/replay.md +160 -0
- package/rihal/workflows/rerun.md +77 -0
- package/rihal/workflows/research-phase.md +82 -0
- package/rihal/workflows/resume-work.md +326 -0
- package/rihal/workflows/review-adversarial.md +180 -0
- package/rihal/workflows/review-edge-case-hunter.md +214 -0
- package/rihal/workflows/review.md +281 -0
- package/rihal/workflows/scan.md +135 -0
- package/rihal/workflows/secure-phase.md +196 -0
- package/rihal/workflows/session-report.md +187 -0
- package/rihal/workflows/settings.md +185 -0
- package/rihal/workflows/ship.md +237 -0
- package/rihal/workflows/show.md +63 -0
- package/rihal/workflows/sprint-planning.md +166 -0
- package/rihal/workflows/sprint-status.md +124 -0
- package/rihal/workflows/stats.md +141 -0
- package/rihal/workflows/status.md +116 -0
- package/rihal/workflows/ui-phase.md +148 -0
- package/rihal/workflows/ui-review.md +130 -0
- package/rihal/workflows/undo.md +426 -0
- package/rihal/workflows/update.md +185 -0
- package/rihal/workflows/validate-phase.md +174 -0
- package/rihal/workflows/verify-phase.md +375 -0
- package/rihal/workflows/verify-work.md +717 -0
- package/rihal/workflows/why.md +130 -0
- package/rihal/workflows/workstream.md +197 -0
- package/server/dashboard.js +632 -0
|
@@ -0,0 +1,1503 @@
|
|
|
1
|
+
<purpose>
|
|
2
|
+
Initialize a new project through unified flow: questioning, research (optional), requirements, roadmap. This is the most leveraged moment in any project — deep questioning here means better plans, better execution, better outcomes. One workflow takes you from idea to ready-for-planning.
|
|
3
|
+
|
|
4
|
+
</purpose>
|
|
5
|
+
|
|
6
|
+
<required_reading>
|
|
7
|
+
@.rihal/references/output-format.md
|
|
8
|
+
|
|
9
|
+
Read all files referenced by the invoking prompt's execution_context before starting.
|
|
10
|
+
</required_reading>
|
|
11
|
+
|
|
12
|
+
<output_format>
|
|
13
|
+
Open with banner:
|
|
14
|
+
|
|
15
|
+
```
|
|
16
|
+
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
17
|
+
RIHAL ► NEW PROJECT
|
|
18
|
+
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
19
|
+
```
|
|
20
|
+
|
|
21
|
+
Use TaskCreate at workflow start to show the full journey:
|
|
22
|
+
- TaskCreate: "Detect project type (greenfield / brownfield)"
|
|
23
|
+
- TaskCreate: "Collect workflow config (mode, granularity, parallelization, models, agents)"
|
|
24
|
+
- TaskCreate: "Write and commit PROJECT.md"
|
|
25
|
+
- TaskCreate: "Run domain research (4 parallel agents + synthesizer)" — if research enabled
|
|
26
|
+
- TaskCreate: "Define REQUIREMENTS.md"
|
|
27
|
+
- TaskCreate: "Spawn rihal-roadmapper to build ROADMAP.md"
|
|
28
|
+
- TaskCreate: "Finalize: STATE.md, CLAUDE.md refresh, commit"
|
|
29
|
+
|
|
30
|
+
Mark one in_progress at a time. Mark completed immediately after each step.
|
|
31
|
+
|
|
32
|
+
Per-stage banners:
|
|
33
|
+
- `RIHAL ► QUESTIONING`
|
|
34
|
+
- `RIHAL ► RESEARCHING`
|
|
35
|
+
- `RIHAL ► RESEARCH COMPLETE ✓`
|
|
36
|
+
- `RIHAL ► DEFINING REQUIREMENTS`
|
|
37
|
+
- `RIHAL ► CREATING ROADMAP`
|
|
38
|
+
- `RIHAL ► PROJECT INITIALIZED ✓`
|
|
39
|
+
|
|
40
|
+
**Brownfield detection banner** (if existing code found):
|
|
41
|
+
```
|
|
42
|
+
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
43
|
+
RIHAL ► BROWNFIELD DETECTED
|
|
44
|
+
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
45
|
+
|
|
46
|
+
Existing {stack} code found in {path}. Mapping it first will save
|
|
47
|
+
duplication during planning.
|
|
48
|
+
```
|
|
49
|
+
|
|
50
|
+
Then AskUserQuestion to route to /rihal:map-codebase before proceeding.
|
|
51
|
+
|
|
52
|
+
**Exiting to map-codebase handoff:**
|
|
53
|
+
```
|
|
54
|
+
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
55
|
+
RIHAL ► EXITING TO CODEBASE MAP
|
|
56
|
+
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
57
|
+
|
|
58
|
+
Per the workflow, mapping runs first. After it finishes I'll re-enter
|
|
59
|
+
/rihal:new-project automatically with the map in hand.
|
|
60
|
+
|
|
61
|
+
Handing off to /rihal:map-codebase now.
|
|
62
|
+
```
|
|
63
|
+
</output_format>
|
|
64
|
+
|
|
65
|
+
|
|
66
|
+
## Step 0 — Usage check
|
|
67
|
+
|
|
68
|
+
If `$ARGUMENTS` is empty or contains only `--help` or `-h`:
|
|
69
|
+
|
|
70
|
+
```
|
|
71
|
+
/rihal:new-project <argument-here>
|
|
72
|
+
```
|
|
73
|
+
|
|
74
|
+
**Examples:**
|
|
75
|
+
```
|
|
76
|
+
/rihal:new-project employee leave request tracker for an Omani government ministry
|
|
77
|
+
/rihal:new-project car rental marketplace SEO site for Dubai
|
|
78
|
+
/rihal:new-project tasbeeh app with Arabic RTL support for Android
|
|
79
|
+
```
|
|
80
|
+
|
|
81
|
+
STOP — do not proceed.
|
|
82
|
+
|
|
83
|
+
<available_agent_types>
|
|
84
|
+
Valid Rihal subagent types (use exact names — do not fall back to 'general-purpose'):
|
|
85
|
+
- rihal-project-researcher — Researches project-level technical decisions
|
|
86
|
+
- rihal-research-synthesizer — Synthesizes findings from parallel research agents
|
|
87
|
+
- rihal-roadmapper — Creates phased execution roadmaps
|
|
88
|
+
</available_agent_types>
|
|
89
|
+
|
|
90
|
+
## Step 0.5 — Detect existing project (redirect)
|
|
91
|
+
|
|
92
|
+
Before any processing, check if a project already exists in this directory:
|
|
93
|
+
|
|
94
|
+
```bash
|
|
95
|
+
EXISTING=$(node .rihal/bin/rihal-tools.cjs state read 2>/dev/null | grep '"project"' | head -1)
|
|
96
|
+
```
|
|
97
|
+
|
|
98
|
+
If `$EXISTING` is non-empty (project already initialized):
|
|
99
|
+
|
|
100
|
+
```
|
|
101
|
+
⚠ A rihal project already exists here.
|
|
102
|
+
|
|
103
|
+
To check current state: /rihal:status
|
|
104
|
+
To find next action: /rihal:next
|
|
105
|
+
To start a fresh phase instead: /rihal:add-phase
|
|
106
|
+
```
|
|
107
|
+
|
|
108
|
+
Only proceed past this step if no project exists (`$EXISTING` is empty).
|
|
109
|
+
|
|
110
|
+
<auto_mode>
|
|
111
|
+
|
|
112
|
+
## Auto Mode Detection
|
|
113
|
+
|
|
114
|
+
Check if `--auto` flag is present in $ARGUMENTS.
|
|
115
|
+
|
|
116
|
+
**If auto mode:**
|
|
117
|
+
|
|
118
|
+
- Skip brownfield mapping offer (assume greenfield)
|
|
119
|
+
- Skip deep questioning (extract context from provided document)
|
|
120
|
+
- Config: YOLO mode is implicit (skip that question), but ask granularity/git/agents FIRST (Step 2a)
|
|
121
|
+
- After config: run Steps 6-9 automatically with smart defaults:
|
|
122
|
+
- Research: Always yes
|
|
123
|
+
- Requirements: Include all table stakes + features from provided document
|
|
124
|
+
- Requirements approval: Auto-approve
|
|
125
|
+
- Roadmap approval: Auto-approve
|
|
126
|
+
|
|
127
|
+
**Document requirement:**
|
|
128
|
+
Auto mode requires an idea document — either:
|
|
129
|
+
|
|
130
|
+
- File reference: `/rihal:new-project --auto @prd.md`
|
|
131
|
+
- Pasted/written text in the prompt
|
|
132
|
+
|
|
133
|
+
If no document content provided, error:
|
|
134
|
+
|
|
135
|
+
```
|
|
136
|
+
Error: --auto requires an idea document.
|
|
137
|
+
|
|
138
|
+
Usage:
|
|
139
|
+
/rihal:new-project --auto @your-idea.md
|
|
140
|
+
/rihal:new-project --auto [paste or write your idea here]
|
|
141
|
+
|
|
142
|
+
The document should describe what you want to build.
|
|
143
|
+
```
|
|
144
|
+
|
|
145
|
+
</auto_mode>
|
|
146
|
+
|
|
147
|
+
<process>
|
|
148
|
+
|
|
149
|
+
## 1. Setup
|
|
150
|
+
|
|
151
|
+
**MANDATORY FIRST STEP — Execute these checks before ANY user interaction:**
|
|
152
|
+
|
|
153
|
+
```bash
|
|
154
|
+
INIT=$(node .rihal/bin/rihal-tools.cjs init new-project 2>/dev/null || node .rihal/bin/rihal-tools.cjs init)
|
|
155
|
+
if [[ "$INIT" == @file:* ]]; then INIT=$(cat "${INIT#@file:}"); fi
|
|
156
|
+
AGENT_RESEARCHER=$(node .rihal/bin/rihal-tools.cjs agent-info rihal-project-researcher 2>/dev/null)
|
|
157
|
+
AGENT_SYNTHESIZER=$(node .rihal/bin/rihal-tools.cjs agent-info rihal-research-synthesizer 2>/dev/null)
|
|
158
|
+
AGENT_ROADMAPPER=$(node .rihal/bin/rihal-tools.cjs agent-info rihal-roadmapper 2>/dev/null)
|
|
159
|
+
RESEARCHER_MODEL=$(node .rihal/bin/rihal-tools.cjs resolve-model rihal-project-researcher 2>/dev/null || echo "sonnet")
|
|
160
|
+
SYNTHESIZER_MODEL=$(node .rihal/bin/rihal-tools.cjs resolve-model rihal-research-synthesizer 2>/dev/null || echo "sonnet")
|
|
161
|
+
ROADMAPPER_MODEL=$(node .rihal/bin/rihal-tools.cjs resolve-model rihal-roadmapper 2>/dev/null || echo "sonnet")
|
|
162
|
+
```
|
|
163
|
+
|
|
164
|
+
Parse JSON for: `commit_docs`, `project_exists`, `has_codebase_map`, `planning_exists`, `has_existing_code`, `has_package_file`, `is_brownfield`, `needs_codebase_map`, `has_git`, `project_path`.
|
|
165
|
+
|
|
166
|
+
**Detect runtime and set instruction file name:**
|
|
167
|
+
|
|
168
|
+
Derive `RUNTIME` from the invoking prompt's `execution_context` path:
|
|
169
|
+
- Path contains `/.codex/` → `RUNTIME=codex`
|
|
170
|
+
- Path contains `/.gemini/` → `RUNTIME=gemini`
|
|
171
|
+
- Path contains `/.config/opencode/` or `/.opencode/` → `RUNTIME=opencode`
|
|
172
|
+
- Otherwise → `RUNTIME=claude`
|
|
173
|
+
|
|
174
|
+
Fallback via env vars:
|
|
175
|
+
```bash
|
|
176
|
+
if [ -n "$CODEX_HOME" ]; then RUNTIME="codex"
|
|
177
|
+
elif [ -n "$GEMINI_CONFIG_DIR" ]; then RUNTIME="gemini"
|
|
178
|
+
elif [ -n "$OPENCODE_CONFIG_DIR" ] || [ -n "$OPENCODE_CONFIG" ]; then RUNTIME="opencode"
|
|
179
|
+
else RUNTIME="claude"; fi
|
|
180
|
+
```
|
|
181
|
+
|
|
182
|
+
Set instruction file variable:
|
|
183
|
+
```bash
|
|
184
|
+
if [ "$RUNTIME" = "codex" ]; then INSTRUCTION_FILE="AGENTS.md"; else INSTRUCTION_FILE="CLAUDE.md"; fi
|
|
185
|
+
```
|
|
186
|
+
|
|
187
|
+
All subsequent references to the project instruction file use `$INSTRUCTION_FILE`.
|
|
188
|
+
|
|
189
|
+
**If `project_exists` is true:** Error — project already initialized. Use `/rihal:progress`.
|
|
190
|
+
|
|
191
|
+
**If `has_git` is false:** Initialize git:
|
|
192
|
+
|
|
193
|
+
```bash
|
|
194
|
+
git init
|
|
195
|
+
```
|
|
196
|
+
|
|
197
|
+
## 2. Project Type Classification
|
|
198
|
+
|
|
199
|
+
**If auto mode:** Detect project type from provided document context. Skip to Step 4.
|
|
200
|
+
|
|
201
|
+
**Otherwise:** Ask user to classify the project via AskUserQuestion:
|
|
202
|
+
|
|
203
|
+
- header: "Project Type"
|
|
204
|
+
- question: "Is this a greenfield project or brownfield (existing codebase)?"
|
|
205
|
+
- multiSelect: false
|
|
206
|
+
- options:
|
|
207
|
+
- "Greenfield" — New project from scratch (default flow)
|
|
208
|
+
- "Brownfield" — Enhancing/modifying existing codebase (narrow discovery to delta questions)
|
|
209
|
+
|
|
210
|
+
## 2.1. Brownfield Path (if brownfield selected)
|
|
211
|
+
|
|
212
|
+
**If `needs_codebase_map` is true** (existing code detected but no codebase map):
|
|
213
|
+
|
|
214
|
+
Use AskUserQuestion:
|
|
215
|
+
|
|
216
|
+
- header: "Codebase"
|
|
217
|
+
- question: "I detected existing code in this directory. Would you like to map the codebase first?"
|
|
218
|
+
- options:
|
|
219
|
+
- "Map codebase first" — Run /rihal:map-codebase to understand existing architecture (Recommended)
|
|
220
|
+
- "Skip mapping" — Proceed with targeted discovery
|
|
221
|
+
|
|
222
|
+
**If "Map codebase first":**
|
|
223
|
+
|
|
224
|
+
```
|
|
225
|
+
Run `/rihal:map-codebase` first, then return to `/rihal:new-project`
|
|
226
|
+
```
|
|
227
|
+
|
|
228
|
+
Exit command.
|
|
229
|
+
|
|
230
|
+
**Otherwise:** Continue with narrowed discovery (Step 3b).
|
|
231
|
+
|
|
232
|
+
## 2.2. Greenfield Path (if greenfield selected)
|
|
233
|
+
|
|
234
|
+
Continue to Step 3 (standard deep discovery flow).
|
|
235
|
+
|
|
236
|
+
### Step 3b. Brownfield Discovery (instead of deep questioning)
|
|
237
|
+
|
|
238
|
+
For brownfield projects, narrow discovery to delta questions:
|
|
239
|
+
|
|
240
|
+
```
|
|
241
|
+
AskUserQuestion([
|
|
242
|
+
{
|
|
243
|
+
header: "Change Scope",
|
|
244
|
+
question: "What's changing in this project?",
|
|
245
|
+
multiSelect: false,
|
|
246
|
+
options: [
|
|
247
|
+
"New feature on existing architecture",
|
|
248
|
+
"Refactoring existing feature",
|
|
249
|
+
"Migration to new tech stack",
|
|
250
|
+
"Bug fixes and tech debt",
|
|
251
|
+
"Performance optimization"
|
|
252
|
+
]
|
|
253
|
+
},
|
|
254
|
+
{
|
|
255
|
+
header: "Change Impact",
|
|
256
|
+
question: "Scope of impact?",
|
|
257
|
+
multiSelect: false,
|
|
258
|
+
options: [
|
|
259
|
+
"Single component/module",
|
|
260
|
+
"Multiple components",
|
|
261
|
+
"Entire system (breaking changes)"
|
|
262
|
+
]
|
|
263
|
+
},
|
|
264
|
+
{
|
|
265
|
+
header: "Rollback Risk",
|
|
266
|
+
question: "Can this be rolled back easily?",
|
|
267
|
+
multiSelect: false,
|
|
268
|
+
options: [
|
|
269
|
+
"Yes — change is isolated",
|
|
270
|
+
"Partially — some migration needed",
|
|
271
|
+
"No — breaking change"
|
|
272
|
+
]
|
|
273
|
+
}
|
|
274
|
+
])
|
|
275
|
+
```
|
|
276
|
+
|
|
277
|
+
Adapt PRD template — focus on delta: what's NEW or CHANGED, reference existing architecture/patterns, highlight breaking changes, identify rollback/migration strategy.
|
|
278
|
+
|
|
279
|
+
**Brownfield PRD Template:**
|
|
280
|
+
|
|
281
|
+
```markdown
|
|
282
|
+
# PRD — {project_name}
|
|
283
|
+
|
|
284
|
+
## Existing Context
|
|
285
|
+
|
|
286
|
+
- Current architecture: {from codebase map}
|
|
287
|
+
- Tech stack: {from codebase analysis}
|
|
288
|
+
- What exists today: {brief}
|
|
289
|
+
|
|
290
|
+
## What's Changing
|
|
291
|
+
|
|
292
|
+
- New features: {list}
|
|
293
|
+
- Refactored components: {list}
|
|
294
|
+
- Removed features: {list}
|
|
295
|
+
- Tech debt addressed: {list}
|
|
296
|
+
|
|
297
|
+
## Change Impact
|
|
298
|
+
|
|
299
|
+
- Breaking changes: {yes/no, list if yes}
|
|
300
|
+
- Rollback strategy: {how to back out}
|
|
301
|
+
- Migration path: {if moving data/state}
|
|
302
|
+
|
|
303
|
+
## Success Criteria
|
|
304
|
+
|
|
305
|
+
- {delta-focused acceptance criteria}
|
|
306
|
+
|
|
307
|
+
## Non-functional Requirements
|
|
308
|
+
|
|
309
|
+
- Backward compatibility: {required version range}
|
|
310
|
+
- Data migration: {strategy}
|
|
311
|
+
- Performance impact: {acceptable degradation}
|
|
312
|
+
```
|
|
313
|
+
|
|
314
|
+
After delta discovery, continue with Step 5 (research, requirements approval, roadmap).
|
|
315
|
+
|
|
316
|
+
## 2a. Auto Mode Config (auto mode only)
|
|
317
|
+
|
|
318
|
+
**If auto mode:** Collect config settings upfront.
|
|
319
|
+
|
|
320
|
+
YOLO mode is implicit (auto = YOLO). Ask remaining config questions:
|
|
321
|
+
|
|
322
|
+
**Round 1 — Core settings (3 questions, no Mode question):**
|
|
323
|
+
|
|
324
|
+
```
|
|
325
|
+
AskUserQuestion([
|
|
326
|
+
{
|
|
327
|
+
header: "Granularity",
|
|
328
|
+
question: "How finely should scope be sliced into phases?",
|
|
329
|
+
multiSelect: false,
|
|
330
|
+
options: [
|
|
331
|
+
{ label: "Coarse (Recommended)", description: "Fewer, broader phases (3-5 phases, 1-3 plans each)" },
|
|
332
|
+
{ label: "Standard", description: "Balanced phase size (5-8 phases, 3-5 plans each)" },
|
|
333
|
+
{ label: "Fine", description: "Many focused phases (8-12 phases, 5-10 plans each)" }
|
|
334
|
+
]
|
|
335
|
+
},
|
|
336
|
+
{
|
|
337
|
+
header: "Execution",
|
|
338
|
+
question: "Run plans in parallel?",
|
|
339
|
+
multiSelect: false,
|
|
340
|
+
options: [
|
|
341
|
+
{ label: "Parallel (Recommended)", description: "Independent plans run simultaneously" },
|
|
342
|
+
{ label: "Sequential", description: "One plan at a time" }
|
|
343
|
+
]
|
|
344
|
+
},
|
|
345
|
+
{
|
|
346
|
+
header: "Git Tracking",
|
|
347
|
+
question: "Commit planning docs to git?",
|
|
348
|
+
multiSelect: false,
|
|
349
|
+
options: [
|
|
350
|
+
{ label: "Yes (Recommended)", description: "Planning docs tracked in version control" },
|
|
351
|
+
{ label: "No", description: "Keep .planning/ local-only (add to .gitignore)" }
|
|
352
|
+
]
|
|
353
|
+
}
|
|
354
|
+
])
|
|
355
|
+
```
|
|
356
|
+
|
|
357
|
+
**Round 2 — Workflow agents (same as Step 5):**
|
|
358
|
+
|
|
359
|
+
```
|
|
360
|
+
AskUserQuestion([
|
|
361
|
+
{
|
|
362
|
+
header: "Research",
|
|
363
|
+
question: "Research before planning each phase? (adds tokens/time)",
|
|
364
|
+
multiSelect: false,
|
|
365
|
+
options: [
|
|
366
|
+
{ label: "Yes (Recommended)", description: "Investigate domain, find patterns, surface gotchas" },
|
|
367
|
+
{ label: "No", description: "Plan directly from requirements" }
|
|
368
|
+
]
|
|
369
|
+
},
|
|
370
|
+
{
|
|
371
|
+
header: "Plan Check",
|
|
372
|
+
question: "Verify plans will achieve their goals? (adds tokens/time)",
|
|
373
|
+
multiSelect: false,
|
|
374
|
+
options: [
|
|
375
|
+
{ label: "Yes (Recommended)", description: "Catch gaps before execution starts" },
|
|
376
|
+
{ label: "No", description: "Execute plans without verification" }
|
|
377
|
+
]
|
|
378
|
+
},
|
|
379
|
+
{
|
|
380
|
+
header: "Verifier",
|
|
381
|
+
question: "Verify work satisfies requirements after each phase? (adds tokens/time)",
|
|
382
|
+
multiSelect: false,
|
|
383
|
+
options: [
|
|
384
|
+
{ label: "Yes (Recommended)", description: "Confirm deliverables match phase goals" },
|
|
385
|
+
{ label: "No", description: "Trust execution, skip verification" }
|
|
386
|
+
]
|
|
387
|
+
},
|
|
388
|
+
{
|
|
389
|
+
header: "AI Models",
|
|
390
|
+
question: "Which AI models for planning agents?",
|
|
391
|
+
multiSelect: false,
|
|
392
|
+
options: [
|
|
393
|
+
{ label: "Balanced (Recommended)", description: "Sonnet for most agents — good quality/cost ratio" },
|
|
394
|
+
{ label: "Quality", description: "Opus for research/roadmap — higher cost, deeper analysis" },
|
|
395
|
+
{ label: "Budget", description: "Haiku where possible — fastest, lowest cost" },
|
|
396
|
+
{ label: "Inherit", description: "Use the current session model for all agents" }
|
|
397
|
+
]
|
|
398
|
+
}
|
|
399
|
+
])
|
|
400
|
+
```
|
|
401
|
+
|
|
402
|
+
Create `.planning/config.json`:
|
|
403
|
+
|
|
404
|
+
```bash
|
|
405
|
+
mkdir -p .planning
|
|
406
|
+
cat > .planning/config.json <<EOF
|
|
407
|
+
{
|
|
408
|
+
"mode": "yolo",
|
|
409
|
+
"granularity": "[selected]",
|
|
410
|
+
"parallelization": true,
|
|
411
|
+
"commit_docs": true,
|
|
412
|
+
"model_profile": "balanced",
|
|
413
|
+
"workflow": {
|
|
414
|
+
"research": true,
|
|
415
|
+
"plan_check": true,
|
|
416
|
+
"verifier": true,
|
|
417
|
+
"nyquist_validation": true,
|
|
418
|
+
"auto_advance": true,
|
|
419
|
+
"_auto_chain_active": true
|
|
420
|
+
}
|
|
421
|
+
}
|
|
422
|
+
EOF
|
|
423
|
+
```
|
|
424
|
+
|
|
425
|
+
**If commit_docs = No:** Add `.planning/` to `.gitignore`.
|
|
426
|
+
|
|
427
|
+
**Commit config.json (guarded):**
|
|
428
|
+
|
|
429
|
+
```bash
|
|
430
|
+
git add .planning/config.json 2>/dev/null \
|
|
431
|
+
&& git commit -m "chore: add project config" 2>/dev/null \
|
|
432
|
+
|| echo "ℹ .planning/ gitignored — config written, not committed"
|
|
433
|
+
```
|
|
434
|
+
|
|
435
|
+
Proceed to Step 4 (skip Steps 3 and 5).
|
|
436
|
+
|
|
437
|
+
## 3. Deep Questioning
|
|
438
|
+
|
|
439
|
+
**If auto mode:** Skip (already handled in Step 2a). Extract project context from provided document instead and proceed to Step 4.
|
|
440
|
+
|
|
441
|
+
**Display stage banner:**
|
|
442
|
+
|
|
443
|
+
```
|
|
444
|
+
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
445
|
+
RIHAL ► QUESTIONING
|
|
446
|
+
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
447
|
+
```
|
|
448
|
+
|
|
449
|
+
**Open the conversation:**
|
|
450
|
+
|
|
451
|
+
Ask inline (freeform, NOT AskUserQuestion):
|
|
452
|
+
|
|
453
|
+
"What do you want to build?"
|
|
454
|
+
|
|
455
|
+
Wait for their response. This gives you the context needed to ask intelligent follow-up questions.
|
|
456
|
+
|
|
457
|
+
**Research-before-questions mode:** Check if `workflow.research_before_questions` is enabled in `.planning/config.json`. When enabled, before asking follow-up questions about a topic:
|
|
458
|
+
|
|
459
|
+
1. Do a brief web search for best practices related to what the user described
|
|
460
|
+
2. Mention key findings naturally as you ask questions
|
|
461
|
+
3. This makes questions more informed without changing the conversational flow
|
|
462
|
+
|
|
463
|
+
When disabled (default), ask questions directly.
|
|
464
|
+
|
|
465
|
+
**Follow the thread:**
|
|
466
|
+
|
|
467
|
+
Based on what they said, ask follow-up questions via AskUserQuestion with options that probe what they mentioned — interpretations, clarifications, concrete examples.
|
|
468
|
+
|
|
469
|
+
Keep following threads. Ask about:
|
|
470
|
+
|
|
471
|
+
- What excited them
|
|
472
|
+
- What problem sparked this
|
|
473
|
+
- What they mean by vague terms
|
|
474
|
+
- What it would actually look like
|
|
475
|
+
- What's already decided
|
|
476
|
+
|
|
477
|
+
Techniques:
|
|
478
|
+
|
|
479
|
+
- Challenge vagueness
|
|
480
|
+
- Make abstract concrete
|
|
481
|
+
- Surface assumptions
|
|
482
|
+
- Find edges
|
|
483
|
+
- Reveal motivation
|
|
484
|
+
|
|
485
|
+
**Check context (background, not out loud):**
|
|
486
|
+
|
|
487
|
+
Mentally check the context checklist. If gaps remain, weave questions naturally. Don't suddenly switch to checklist mode.
|
|
488
|
+
|
|
489
|
+
**Decision gate:**
|
|
490
|
+
|
|
491
|
+
When you could write a clear PROJECT.md, use AskUserQuestion:
|
|
492
|
+
|
|
493
|
+
- header: "Ready?"
|
|
494
|
+
- question: "I think I understand what you're after. Ready to create PROJECT.md?"
|
|
495
|
+
- options:
|
|
496
|
+
- "Create PROJECT.md" — Let's move forward
|
|
497
|
+
- "Keep exploring" — I want to share more / ask me more
|
|
498
|
+
|
|
499
|
+
If "Keep exploring" — ask what they want to add, or identify gaps and probe naturally.
|
|
500
|
+
|
|
501
|
+
Loop until "Create PROJECT.md" selected.
|
|
502
|
+
|
|
503
|
+
## 3.5. Detect Project Type
|
|
504
|
+
|
|
505
|
+
**If auto mode:** Skip — project type will be inferred from document in Step 4.
|
|
506
|
+
|
|
507
|
+
**Goal:** Classify the project into one of 9 types (api-backend, mobile-app, saas-b2b, cli-tool, web-app, desktop-app, iot, dev-tool, other). This shapes discovery questions and discovery section requirements.
|
|
508
|
+
|
|
509
|
+
**Load project type signals:**
|
|
510
|
+
|
|
511
|
+
```bash
|
|
512
|
+
PROJECT_TYPES=$(cat .rihal/references/project-types.yaml 2>/dev/null || true)
|
|
513
|
+
```
|
|
514
|
+
|
|
515
|
+
**Classify by signals:**
|
|
516
|
+
|
|
517
|
+
Scan the user's responses from Step 3 for keywords from the `signals` list. Build a score per type:
|
|
518
|
+
|
|
519
|
+
- Each signal match adds 1 point
|
|
520
|
+
- Pick the type with the highest score
|
|
521
|
+
- If tie or score < 2, ask the user to clarify
|
|
522
|
+
|
|
523
|
+
**If score is clear (>2 points for one type):**
|
|
524
|
+
|
|
525
|
+
```
|
|
526
|
+
📋 Detected project type: {display_name} (based on your description mentioning {signal1}, {signal2}, {signal3})
|
|
527
|
+
|
|
528
|
+
Proceed with this type? [Y/n]
|
|
529
|
+
```
|
|
530
|
+
|
|
531
|
+
If "n": Ask the user to pick from the list.
|
|
532
|
+
|
|
533
|
+
**Store the detected type** in a shell variable for Step 5 discovery adaptation. Add required-sections and discovery questions from project-types.yaml to the upcoming questionnaire.
|
|
534
|
+
|
|
535
|
+
## 4. Write PROJECT.md
|
|
536
|
+
|
|
537
|
+
**If auto mode:** Synthesize from provided document. No "Ready?" gate was shown — proceed directly to commit.
|
|
538
|
+
|
|
539
|
+
Synthesize all context into `.planning/PROJECT.md`. If `.rihal/templates/project.md` exists, use it. Otherwise use this inline template:
|
|
540
|
+
|
|
541
|
+
```markdown
|
|
542
|
+
# Project: {name}
|
|
543
|
+
|
|
544
|
+
## What This Is
|
|
545
|
+
|
|
546
|
+
{1-2 sentence description}
|
|
547
|
+
|
|
548
|
+
## Core Value
|
|
549
|
+
|
|
550
|
+
{The ONE thing that must work}
|
|
551
|
+
|
|
552
|
+
## Requirements
|
|
553
|
+
|
|
554
|
+
### Validated
|
|
555
|
+
|
|
556
|
+
{For greenfield: "(None yet — ship to validate)"}
|
|
557
|
+
{For brownfield: list existing capabilities}
|
|
558
|
+
|
|
559
|
+
### Active
|
|
560
|
+
|
|
561
|
+
- [ ] {Requirement 1}
|
|
562
|
+
- [ ] {Requirement 2}
|
|
563
|
+
- [ ] {Requirement 3}
|
|
564
|
+
|
|
565
|
+
### Out of Scope
|
|
566
|
+
|
|
567
|
+
- {Exclusion 1} — {why}
|
|
568
|
+
- {Exclusion 2} — {why}
|
|
569
|
+
|
|
570
|
+
## Key Decisions
|
|
571
|
+
|
|
572
|
+
| Decision | Rationale | Outcome |
|
|
573
|
+
|----------|-----------|---------|
|
|
574
|
+
| {Choice} | {Why} | — Pending |
|
|
575
|
+
|
|
576
|
+
## Constraints
|
|
577
|
+
|
|
578
|
+
- {Budget / timeline / tech}
|
|
579
|
+
|
|
580
|
+
## Context
|
|
581
|
+
|
|
582
|
+
{Current state, tech stack, user feedback themes}
|
|
583
|
+
|
|
584
|
+
## Evolution
|
|
585
|
+
|
|
586
|
+
This document evolves at phase transitions and milestone boundaries.
|
|
587
|
+
|
|
588
|
+
**After each phase transition** (via `/rihal:discuss-phase` + `/rihal:plan`):
|
|
589
|
+
1. Requirements invalidated? → Move to Out of Scope with reason
|
|
590
|
+
2. Requirements validated? → Move to Validated with phase reference
|
|
591
|
+
3. New requirements emerged? → Add to Active
|
|
592
|
+
4. Decisions to log? → Add to Key Decisions
|
|
593
|
+
5. "What This Is" still accurate? → Update if drifted
|
|
594
|
+
|
|
595
|
+
**After each milestone** (via `/rihal:complete-milestone`):
|
|
596
|
+
1. Full review of all sections
|
|
597
|
+
2. Core Value check — still the right priority?
|
|
598
|
+
3. Audit Out of Scope — reasons still valid?
|
|
599
|
+
4. Update Context with current state
|
|
600
|
+
|
|
601
|
+
---
|
|
602
|
+
*Last updated: {date} after initialization*
|
|
603
|
+
```
|
|
604
|
+
|
|
605
|
+
**For greenfield projects:** Initialize requirements as hypotheses (all Active).
|
|
606
|
+
|
|
607
|
+
**For brownfield projects (codebase map exists):** Read `.planning/codebase/ARCHITECTURE.md` and `STACK.md`. Identify what the codebase already does — these become the initial Validated set.
|
|
608
|
+
|
|
609
|
+
**Key Decisions:** Initialize with any decisions made during questioning.
|
|
610
|
+
|
|
611
|
+
Do not compress. Capture everything gathered.
|
|
612
|
+
|
|
613
|
+
**Commit PROJECT.md (guarded):**
|
|
614
|
+
|
|
615
|
+
```bash
|
|
616
|
+
mkdir -p .planning
|
|
617
|
+
git add .planning/PROJECT.md 2>/dev/null \
|
|
618
|
+
&& git commit -m "docs: initialize project" 2>/dev/null \
|
|
619
|
+
|| echo "ℹ .planning/ gitignored — PROJECT.md written, not committed"
|
|
620
|
+
```
|
|
621
|
+
|
|
622
|
+
## 5. Workflow Preferences
|
|
623
|
+
|
|
624
|
+
**If auto mode:** Skip — config was collected in Step 2a. Proceed to Step 5.5.
|
|
625
|
+
|
|
626
|
+
**Check for global defaults** at `~/.rihal/defaults.json`. If the file exists, offer to use saved defaults:
|
|
627
|
+
|
|
628
|
+
```
|
|
629
|
+
AskUserQuestion([
|
|
630
|
+
{
|
|
631
|
+
question: "Use your saved default settings? (from ~/.rihal/defaults.json)",
|
|
632
|
+
header: "Defaults",
|
|
633
|
+
multiSelect: false,
|
|
634
|
+
options: [
|
|
635
|
+
{ label: "Yes (Recommended)", description: "Use saved defaults, skip settings questions" },
|
|
636
|
+
{ label: "No", description: "Configure settings manually" }
|
|
637
|
+
]
|
|
638
|
+
}
|
|
639
|
+
])
|
|
640
|
+
```
|
|
641
|
+
|
|
642
|
+
If "Yes": read `~/.rihal/defaults.json`, use those values for config.json, skip to **Commit config.json** below.
|
|
643
|
+
|
|
644
|
+
If "No" or file doesn't exist: proceed with the questions below.
|
|
645
|
+
|
|
646
|
+
**Round 1 — Core workflow settings (4 questions):**
|
|
647
|
+
|
|
648
|
+
```
|
|
649
|
+
questions: [
|
|
650
|
+
{
|
|
651
|
+
header: "Mode",
|
|
652
|
+
question: "How do you want to work?",
|
|
653
|
+
multiSelect: false,
|
|
654
|
+
options: [
|
|
655
|
+
{ label: "YOLO (Recommended)", description: "Auto-approve, just execute" },
|
|
656
|
+
{ label: "Interactive", description: "Confirm at each step" }
|
|
657
|
+
]
|
|
658
|
+
},
|
|
659
|
+
{
|
|
660
|
+
header: "Granularity",
|
|
661
|
+
question: "How finely should scope be sliced into phases?",
|
|
662
|
+
multiSelect: false,
|
|
663
|
+
options: [
|
|
664
|
+
{ label: "Coarse", description: "Fewer, broader phases (3-5 phases, 1-3 plans each)" },
|
|
665
|
+
{ label: "Standard", description: "Balanced phase size (5-8 phases, 3-5 plans each)" },
|
|
666
|
+
{ label: "Fine", description: "Many focused phases (8-12 phases, 5-10 plans each)" }
|
|
667
|
+
]
|
|
668
|
+
},
|
|
669
|
+
{
|
|
670
|
+
header: "Execution",
|
|
671
|
+
question: "Run plans in parallel?",
|
|
672
|
+
multiSelect: false,
|
|
673
|
+
options: [
|
|
674
|
+
{ label: "Parallel (Recommended)", description: "Independent plans run simultaneously" },
|
|
675
|
+
{ label: "Sequential", description: "One plan at a time" }
|
|
676
|
+
]
|
|
677
|
+
},
|
|
678
|
+
{
|
|
679
|
+
header: "Git Tracking",
|
|
680
|
+
question: "Commit planning docs to git?",
|
|
681
|
+
multiSelect: false,
|
|
682
|
+
options: [
|
|
683
|
+
{ label: "Yes (Recommended)", description: "Planning docs tracked in version control" },
|
|
684
|
+
{ label: "No", description: "Keep .planning/ local-only (add to .gitignore)" }
|
|
685
|
+
]
|
|
686
|
+
}
|
|
687
|
+
]
|
|
688
|
+
```
|
|
689
|
+
|
|
690
|
+
**Round 2 — Workflow agents:**
|
|
691
|
+
|
|
692
|
+
These spawn additional agents during planning/execution. They add tokens and time but improve quality.
|
|
693
|
+
|
|
694
|
+
| Agent | When it runs | What it does |
|
|
695
|
+
|-------|--------------|--------------|
|
|
696
|
+
| **Researcher** | Before planning each phase | Investigates domain, finds patterns, surfaces gotchas |
|
|
697
|
+
| **Plan Checker** | After plan is created | Verifies plan actually achieves the phase goal |
|
|
698
|
+
| **Verifier** | After phase execution | Confirms must-haves were delivered |
|
|
699
|
+
|
|
700
|
+
```
|
|
701
|
+
questions: [
|
|
702
|
+
{
|
|
703
|
+
header: "Research",
|
|
704
|
+
question: "Research before planning each phase? (adds tokens/time)",
|
|
705
|
+
multiSelect: false,
|
|
706
|
+
options: [
|
|
707
|
+
{ label: "Yes (Recommended)", description: "Investigate domain, find patterns, surface gotchas" },
|
|
708
|
+
{ label: "No", description: "Plan directly from requirements" }
|
|
709
|
+
]
|
|
710
|
+
},
|
|
711
|
+
{
|
|
712
|
+
header: "Plan Check",
|
|
713
|
+
question: "Verify plans will achieve their goals? (adds tokens/time)",
|
|
714
|
+
multiSelect: false,
|
|
715
|
+
options: [
|
|
716
|
+
{ label: "Yes (Recommended)", description: "Catch gaps before execution starts" },
|
|
717
|
+
{ label: "No", description: "Execute plans without verification" }
|
|
718
|
+
]
|
|
719
|
+
},
|
|
720
|
+
{
|
|
721
|
+
header: "Verifier",
|
|
722
|
+
question: "Verify work satisfies requirements after each phase? (adds tokens/time)",
|
|
723
|
+
multiSelect: false,
|
|
724
|
+
options: [
|
|
725
|
+
{ label: "Yes (Recommended)", description: "Confirm deliverables match phase goals" },
|
|
726
|
+
{ label: "No", description: "Trust execution, skip verification" }
|
|
727
|
+
]
|
|
728
|
+
},
|
|
729
|
+
{
|
|
730
|
+
header: "AI Models",
|
|
731
|
+
question: "Which AI models for planning agents?",
|
|
732
|
+
multiSelect: false,
|
|
733
|
+
options: [
|
|
734
|
+
{ label: "Balanced (Recommended)", description: "Sonnet for most agents — good quality/cost ratio" },
|
|
735
|
+
{ label: "Quality", description: "Opus for research/roadmap — higher cost, deeper analysis" },
|
|
736
|
+
{ label: "Budget", description: "Haiku where possible — fastest, lowest cost" },
|
|
737
|
+
{ label: "Inherit", description: "Use the current session model for all agents" }
|
|
738
|
+
]
|
|
739
|
+
}
|
|
740
|
+
]
|
|
741
|
+
```
|
|
742
|
+
|
|
743
|
+
Create `.planning/config.json` with all settings:
|
|
744
|
+
|
|
745
|
+
```bash
|
|
746
|
+
mkdir -p .planning
|
|
747
|
+
cat > .planning/config.json <<EOF
|
|
748
|
+
{
|
|
749
|
+
"mode": "[yolo|interactive]",
|
|
750
|
+
"granularity": "[selected]",
|
|
751
|
+
"parallelization": true,
|
|
752
|
+
"commit_docs": true,
|
|
753
|
+
"model_profile": "[quality|balanced|budget|inherit]",
|
|
754
|
+
"workflow": {
|
|
755
|
+
"research": true,
|
|
756
|
+
"plan_check": true,
|
|
757
|
+
"verifier": true,
|
|
758
|
+
"nyquist_validation": true
|
|
759
|
+
}
|
|
760
|
+
}
|
|
761
|
+
EOF
|
|
762
|
+
```
|
|
763
|
+
|
|
764
|
+
**Note:** Run `/rihal:settings` anytime to update model profile, workflow agents, branching strategy, and other preferences.
|
|
765
|
+
|
|
766
|
+
**If commit_docs = No:**
|
|
767
|
+
|
|
768
|
+
- Set `commit_docs: false` in config.json
|
|
769
|
+
- Add `.planning/` to `.gitignore` (create if needed)
|
|
770
|
+
|
|
771
|
+
**Commit config.json (guarded):**
|
|
772
|
+
|
|
773
|
+
```bash
|
|
774
|
+
git add .planning/config.json 2>/dev/null \
|
|
775
|
+
&& git commit -m "chore: add project config" 2>/dev/null \
|
|
776
|
+
|| echo "ℹ .planning/ gitignored — config written, not committed"
|
|
777
|
+
```
|
|
778
|
+
|
|
779
|
+
## 5.1. Sub-Repo Detection
|
|
780
|
+
|
|
781
|
+
**Detect multi-repo workspace:**
|
|
782
|
+
|
|
783
|
+
```bash
|
|
784
|
+
find . -maxdepth 1 -type d -not -name ".*" -not -name "node_modules" -exec test -d "{}/.git" \; -print
|
|
785
|
+
```
|
|
786
|
+
|
|
787
|
+
**If sub-repos found:**
|
|
788
|
+
|
|
789
|
+
Strip the `./` prefix (e.g., `./backend` → `backend`).
|
|
790
|
+
|
|
791
|
+
Use AskUserQuestion:
|
|
792
|
+
|
|
793
|
+
- header: "Multi-Repo Workspace"
|
|
794
|
+
- question: "I detected separate git repos in this workspace. Which directories contain code that Rihal should commit to?"
|
|
795
|
+
- multiSelect: true
|
|
796
|
+
- options: one option per detected directory
|
|
797
|
+
|
|
798
|
+
**If user selects one or more directories:**
|
|
799
|
+
|
|
800
|
+
- Set `planning.sub_repos` in config.json to the selected directory names array
|
|
801
|
+
- Auto-set `planning.commit_docs` to `false` (planning docs stay local in multi-repo workspaces)
|
|
802
|
+
- Add `.planning/` to `.gitignore` if not already present
|
|
803
|
+
|
|
804
|
+
**If no sub-repos found or user selects none:** Continue with no changes to config.
|
|
805
|
+
|
|
806
|
+
## 5.5. Resolve Model Profile
|
|
807
|
+
|
|
808
|
+
Use models resolved in Step 1: `RESEARCHER_MODEL`, `SYNTHESIZER_MODEL`, `ROADMAPPER_MODEL`.
|
|
809
|
+
|
|
810
|
+
## 6. Research Decision
|
|
811
|
+
|
|
812
|
+
**If auto mode:** Default to "Research first" without asking.
|
|
813
|
+
|
|
814
|
+
Use AskUserQuestion:
|
|
815
|
+
|
|
816
|
+
- header: "Research"
|
|
817
|
+
- question: "Research the domain ecosystem before defining requirements?"
|
|
818
|
+
- options:
|
|
819
|
+
- "Research first (Recommended)" — Discover standard stacks, expected features, architecture patterns
|
|
820
|
+
- "Skip research" — I know this domain well, go straight to requirements
|
|
821
|
+
|
|
822
|
+
**If "Research first":**
|
|
823
|
+
|
|
824
|
+
Display stage banner:
|
|
825
|
+
|
|
826
|
+
```
|
|
827
|
+
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
828
|
+
RIHAL ► RESEARCHING
|
|
829
|
+
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
830
|
+
|
|
831
|
+
Researching [domain] ecosystem...
|
|
832
|
+
```
|
|
833
|
+
|
|
834
|
+
Create research directory:
|
|
835
|
+
|
|
836
|
+
```bash
|
|
837
|
+
mkdir -p .planning/research
|
|
838
|
+
```
|
|
839
|
+
|
|
840
|
+
**Determine milestone context:**
|
|
841
|
+
|
|
842
|
+
- If no "Validated" requirements in PROJECT.md → Greenfield (building from scratch)
|
|
843
|
+
- If "Validated" requirements exist → Subsequent milestone (adding to existing app)
|
|
844
|
+
|
|
845
|
+
Display spawning indicator:
|
|
846
|
+
|
|
847
|
+
```
|
|
848
|
+
◆ Spawning 4 researchers in parallel...
|
|
849
|
+
→ Stack research
|
|
850
|
+
→ Features research
|
|
851
|
+
→ Architecture research
|
|
852
|
+
→ Pitfalls research
|
|
853
|
+
```
|
|
854
|
+
|
|
855
|
+
Spawn 4 parallel rihal-project-researcher agents:
|
|
856
|
+
|
|
857
|
+
```
|
|
858
|
+
Task(prompt="<research_type>
|
|
859
|
+
Project Research — Stack dimension for [domain].
|
|
860
|
+
</research_type>
|
|
861
|
+
|
|
862
|
+
<milestone_context>
|
|
863
|
+
[greenfield OR subsequent]
|
|
864
|
+
|
|
865
|
+
Greenfield: Research the standard stack for building [domain] from scratch.
|
|
866
|
+
Subsequent: Research what's needed to add [target features] to an existing [domain] app.
|
|
867
|
+
</milestone_context>
|
|
868
|
+
|
|
869
|
+
<question>
|
|
870
|
+
What's the standard 2026 stack for [domain]?
|
|
871
|
+
</question>
|
|
872
|
+
|
|
873
|
+
<files_to_read>
|
|
874
|
+
- .planning/PROJECT.md (Project context and goals)
|
|
875
|
+
</files_to_read>
|
|
876
|
+
|
|
877
|
+
${AGENT_RESEARCHER}
|
|
878
|
+
|
|
879
|
+
<downstream_consumer>
|
|
880
|
+
Your STACK.md feeds into roadmap creation. Be prescriptive:
|
|
881
|
+
- Specific libraries with versions
|
|
882
|
+
- Clear rationale for each choice
|
|
883
|
+
- What NOT to use and why
|
|
884
|
+
</downstream_consumer>
|
|
885
|
+
|
|
886
|
+
<quality_gate>
|
|
887
|
+
- [ ] Versions are current (verify with Context7/official docs, not training data)
|
|
888
|
+
- [ ] Rationale explains WHY, not just WHAT
|
|
889
|
+
- [ ] Confidence levels assigned to each recommendation
|
|
890
|
+
</quality_gate>
|
|
891
|
+
|
|
892
|
+
<output>
|
|
893
|
+
Write to: .planning/research/STACK.md
|
|
894
|
+
</output>
|
|
895
|
+
", subagent_type="rihal-project-researcher", model="${RESEARCHER_MODEL}", description="Stack research")
|
|
896
|
+
|
|
897
|
+
Task(prompt="<research_type>
|
|
898
|
+
Project Research — Features dimension for [domain].
|
|
899
|
+
</research_type>
|
|
900
|
+
|
|
901
|
+
<milestone_context>
|
|
902
|
+
[greenfield OR subsequent]
|
|
903
|
+
|
|
904
|
+
Greenfield: What features do [domain] products have? What's table stakes vs differentiating?
|
|
905
|
+
Subsequent: How do [target features] typically work? What's expected behavior?
|
|
906
|
+
</milestone_context>
|
|
907
|
+
|
|
908
|
+
<files_to_read>
|
|
909
|
+
- .planning/PROJECT.md
|
|
910
|
+
</files_to_read>
|
|
911
|
+
|
|
912
|
+
${AGENT_RESEARCHER}
|
|
913
|
+
|
|
914
|
+
<downstream_consumer>
|
|
915
|
+
Your FEATURES.md feeds into requirements definition. Categorize clearly:
|
|
916
|
+
- Table stakes (must have or users leave)
|
|
917
|
+
- Differentiators (competitive advantage)
|
|
918
|
+
- Anti-features (things to deliberately NOT build)
|
|
919
|
+
</downstream_consumer>
|
|
920
|
+
|
|
921
|
+
<quality_gate>
|
|
922
|
+
- [ ] Categories are clear (table stakes vs differentiators vs anti-features)
|
|
923
|
+
- [ ] Complexity noted for each feature
|
|
924
|
+
- [ ] Dependencies between features identified
|
|
925
|
+
</quality_gate>
|
|
926
|
+
|
|
927
|
+
<output>
|
|
928
|
+
Write to: .planning/research/FEATURES.md
|
|
929
|
+
</output>
|
|
930
|
+
", subagent_type="rihal-project-researcher", model="${RESEARCHER_MODEL}", description="Features research")
|
|
931
|
+
|
|
932
|
+
Task(prompt="<research_type>
|
|
933
|
+
Project Research — Architecture dimension for [domain].
|
|
934
|
+
</research_type>
|
|
935
|
+
|
|
936
|
+
<milestone_context>
|
|
937
|
+
[greenfield OR subsequent]
|
|
938
|
+
|
|
939
|
+
Greenfield: How are [domain] systems typically structured? What are major components?
|
|
940
|
+
Subsequent: How do [target features] integrate with existing [domain] architecture?
|
|
941
|
+
</milestone_context>
|
|
942
|
+
|
|
943
|
+
<files_to_read>
|
|
944
|
+
- .planning/PROJECT.md
|
|
945
|
+
</files_to_read>
|
|
946
|
+
|
|
947
|
+
${AGENT_RESEARCHER}
|
|
948
|
+
|
|
949
|
+
<downstream_consumer>
|
|
950
|
+
Your ARCHITECTURE.md informs phase structure in roadmap. Include:
|
|
951
|
+
- Component boundaries (what talks to what)
|
|
952
|
+
- Data flow (how information moves)
|
|
953
|
+
- Suggested build order (dependencies between components)
|
|
954
|
+
</downstream_consumer>
|
|
955
|
+
|
|
956
|
+
<quality_gate>
|
|
957
|
+
- [ ] Components clearly defined with boundaries
|
|
958
|
+
- [ ] Data flow direction explicit
|
|
959
|
+
- [ ] Build order implications noted
|
|
960
|
+
</quality_gate>
|
|
961
|
+
|
|
962
|
+
<output>
|
|
963
|
+
Write to: .planning/research/ARCHITECTURE.md
|
|
964
|
+
</output>
|
|
965
|
+
", subagent_type="rihal-project-researcher", model="${RESEARCHER_MODEL}", description="Architecture research")
|
|
966
|
+
|
|
967
|
+
Task(prompt="<research_type>
|
|
968
|
+
Project Research — Pitfalls dimension for [domain].
|
|
969
|
+
</research_type>
|
|
970
|
+
|
|
971
|
+
<milestone_context>
|
|
972
|
+
[greenfield OR subsequent]
|
|
973
|
+
|
|
974
|
+
Greenfield: What do [domain] projects commonly get wrong? Critical mistakes?
|
|
975
|
+
Subsequent: What are common mistakes when adding [target features] to [domain]?
|
|
976
|
+
</milestone_context>
|
|
977
|
+
|
|
978
|
+
<files_to_read>
|
|
979
|
+
- .planning/PROJECT.md
|
|
980
|
+
</files_to_read>
|
|
981
|
+
|
|
982
|
+
${AGENT_RESEARCHER}
|
|
983
|
+
|
|
984
|
+
<downstream_consumer>
|
|
985
|
+
Your PITFALLS.md prevents mistakes in roadmap/planning. For each pitfall:
|
|
986
|
+
- Warning signs (how to detect early)
|
|
987
|
+
- Prevention strategy (how to avoid)
|
|
988
|
+
- Which phase should address it
|
|
989
|
+
</downstream_consumer>
|
|
990
|
+
|
|
991
|
+
<quality_gate>
|
|
992
|
+
- [ ] Pitfalls are specific to this domain (not generic advice)
|
|
993
|
+
- [ ] Prevention strategies are actionable
|
|
994
|
+
- [ ] Phase mapping included where relevant
|
|
995
|
+
</quality_gate>
|
|
996
|
+
|
|
997
|
+
<output>
|
|
998
|
+
Write to: .planning/research/PITFALLS.md
|
|
999
|
+
</output>
|
|
1000
|
+
", subagent_type="rihal-project-researcher", model="${RESEARCHER_MODEL}", description="Pitfalls research")
|
|
1001
|
+
```
|
|
1002
|
+
|
|
1003
|
+
After all 4 agents complete, spawn synthesizer to create SUMMARY.md:
|
|
1004
|
+
|
|
1005
|
+
```
|
|
1006
|
+
Task(prompt="
|
|
1007
|
+
<task>
|
|
1008
|
+
Synthesize research outputs into SUMMARY.md.
|
|
1009
|
+
</task>
|
|
1010
|
+
|
|
1011
|
+
<files_to_read>
|
|
1012
|
+
- .planning/research/STACK.md
|
|
1013
|
+
- .planning/research/FEATURES.md
|
|
1014
|
+
- .planning/research/ARCHITECTURE.md
|
|
1015
|
+
- .planning/research/PITFALLS.md
|
|
1016
|
+
</files_to_read>
|
|
1017
|
+
|
|
1018
|
+
${AGENT_SYNTHESIZER}
|
|
1019
|
+
|
|
1020
|
+
<output>
|
|
1021
|
+
Write to: .planning/research/SUMMARY.md
|
|
1022
|
+
Synthesize into: recommended stack, table stakes vs differentiators, architecture outline, top pitfalls to avoid.
|
|
1023
|
+
</output>
|
|
1024
|
+
", subagent_type="rihal-research-synthesizer", model="${SYNTHESIZER_MODEL}", description="Synthesize research")
|
|
1025
|
+
```
|
|
1026
|
+
|
|
1027
|
+
**Commit research (guarded):**
|
|
1028
|
+
|
|
1029
|
+
```bash
|
|
1030
|
+
git add .planning/research/ 2>/dev/null \
|
|
1031
|
+
&& git commit -m "docs: add project research" 2>/dev/null \
|
|
1032
|
+
|| echo "ℹ .planning/ gitignored — research written, not committed"
|
|
1033
|
+
```
|
|
1034
|
+
|
|
1035
|
+
Display research complete banner and key findings:
|
|
1036
|
+
|
|
1037
|
+
```
|
|
1038
|
+
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
1039
|
+
RIHAL ► RESEARCH COMPLETE ✓
|
|
1040
|
+
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
1041
|
+
|
|
1042
|
+
## Key Findings
|
|
1043
|
+
|
|
1044
|
+
**Stack:** [from SUMMARY.md]
|
|
1045
|
+
**Table Stakes:** [from SUMMARY.md]
|
|
1046
|
+
**Watch Out For:** [from SUMMARY.md]
|
|
1047
|
+
|
|
1048
|
+
Files: `.planning/research/`
|
|
1049
|
+
```
|
|
1050
|
+
|
|
1051
|
+
**If "Skip research":** Continue to Step 7.
|
|
1052
|
+
|
|
1053
|
+
## 7. Define Requirements
|
|
1054
|
+
|
|
1055
|
+
Display stage banner:
|
|
1056
|
+
|
|
1057
|
+
```
|
|
1058
|
+
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
1059
|
+
RIHAL ► DEFINING REQUIREMENTS
|
|
1060
|
+
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
1061
|
+
```
|
|
1062
|
+
|
|
1063
|
+
**Load context:**
|
|
1064
|
+
|
|
1065
|
+
Read PROJECT.md and extract:
|
|
1066
|
+
|
|
1067
|
+
- Core value (the ONE thing that must work)
|
|
1068
|
+
- Stated constraints (budget, timeline, tech limitations)
|
|
1069
|
+
- Any explicit scope boundaries
|
|
1070
|
+
|
|
1071
|
+
**If research exists:** Read research/FEATURES.md and extract feature categories.
|
|
1072
|
+
|
|
1073
|
+
**If auto mode:**
|
|
1074
|
+
|
|
1075
|
+
- Auto-include all table stakes features
|
|
1076
|
+
- Include features explicitly mentioned in provided document
|
|
1077
|
+
- Auto-defer differentiators not mentioned in document
|
|
1078
|
+
- Skip per-category AskUserQuestion loops
|
|
1079
|
+
- Skip "Any additions?" question
|
|
1080
|
+
- Skip requirements approval gate
|
|
1081
|
+
- Generate REQUIREMENTS.md and commit directly
|
|
1082
|
+
|
|
1083
|
+
**Present features by category (interactive mode only):**
|
|
1084
|
+
|
|
1085
|
+
```
|
|
1086
|
+
Here are the features for [domain]:
|
|
1087
|
+
|
|
1088
|
+
## Authentication
|
|
1089
|
+
**Table stakes:**
|
|
1090
|
+
- Sign up with email/password
|
|
1091
|
+
- Email verification
|
|
1092
|
+
- Password reset
|
|
1093
|
+
- Session management
|
|
1094
|
+
|
|
1095
|
+
**Differentiators:**
|
|
1096
|
+
- Magic link login
|
|
1097
|
+
- OAuth (Google, GitHub)
|
|
1098
|
+
- 2FA
|
|
1099
|
+
|
|
1100
|
+
**Research notes:** [any relevant notes]
|
|
1101
|
+
|
|
1102
|
+
---
|
|
1103
|
+
|
|
1104
|
+
## [Next Category]
|
|
1105
|
+
...
|
|
1106
|
+
```
|
|
1107
|
+
|
|
1108
|
+
**If no research:** Gather requirements through conversation.
|
|
1109
|
+
|
|
1110
|
+
Ask: "What are the main things users need to be able to do?"
|
|
1111
|
+
|
|
1112
|
+
For each capability mentioned:
|
|
1113
|
+
|
|
1114
|
+
- Ask clarifying questions to make it specific
|
|
1115
|
+
- Probe for related capabilities
|
|
1116
|
+
- Group into categories
|
|
1117
|
+
|
|
1118
|
+
**Scope each category:**
|
|
1119
|
+
|
|
1120
|
+
For each category, use AskUserQuestion:
|
|
1121
|
+
|
|
1122
|
+
- header: "[Category]" (max 12 chars)
|
|
1123
|
+
- question: "Which [category] features are in v1?"
|
|
1124
|
+
- multiSelect: true
|
|
1125
|
+
- options:
|
|
1126
|
+
- "[Feature 1]" — [brief description]
|
|
1127
|
+
- "[Feature 2]" — [brief description]
|
|
1128
|
+
- "[Feature 3]" — [brief description]
|
|
1129
|
+
- "None for v1" — Defer entire category
|
|
1130
|
+
|
|
1131
|
+
Track responses:
|
|
1132
|
+
|
|
1133
|
+
- Selected features → v1 requirements
|
|
1134
|
+
- Unselected table stakes → v2
|
|
1135
|
+
- Unselected differentiators → out of scope
|
|
1136
|
+
|
|
1137
|
+
**Identify gaps:**
|
|
1138
|
+
|
|
1139
|
+
Use AskUserQuestion:
|
|
1140
|
+
|
|
1141
|
+
- header: "Additions"
|
|
1142
|
+
- question: "Any requirements research missed?"
|
|
1143
|
+
- options:
|
|
1144
|
+
- "No, research covered it" — Proceed
|
|
1145
|
+
- "Yes, let me add some" — Capture additions
|
|
1146
|
+
|
|
1147
|
+
**Validate core value:**
|
|
1148
|
+
|
|
1149
|
+
Cross-check requirements against Core Value from PROJECT.md. If gaps detected, surface them.
|
|
1150
|
+
|
|
1151
|
+
**Generate REQUIREMENTS.md:**
|
|
1152
|
+
|
|
1153
|
+
Create `.planning/REQUIREMENTS.md` with:
|
|
1154
|
+
|
|
1155
|
+
- v1 Requirements grouped by category (checkboxes, REQ-IDs)
|
|
1156
|
+
- v2 Requirements (deferred)
|
|
1157
|
+
- Out of Scope (explicit exclusions with reasoning)
|
|
1158
|
+
- Traceability section (empty, filled by roadmap)
|
|
1159
|
+
|
|
1160
|
+
**REQ-ID format:** `[CATEGORY]-[NUMBER]` (AUTH-01, CONTENT-02)
|
|
1161
|
+
|
|
1162
|
+
**Requirement quality criteria:**
|
|
1163
|
+
|
|
1164
|
+
Good requirements are:
|
|
1165
|
+
|
|
1166
|
+
- **Specific and testable:** "User can reset password via email link"
|
|
1167
|
+
- **User-centric:** "User can X"
|
|
1168
|
+
- **Atomic:** One capability per requirement
|
|
1169
|
+
- **Independent:** Minimal dependencies on other requirements
|
|
1170
|
+
|
|
1171
|
+
Reject vague requirements. Push for specificity:
|
|
1172
|
+
|
|
1173
|
+
- "Handle authentication" → "User can log in with email/password and stay logged in across sessions"
|
|
1174
|
+
- "Support sharing" → "User can share post via link that opens in recipient's browser"
|
|
1175
|
+
|
|
1176
|
+
**Present full requirements list (interactive mode only):**
|
|
1177
|
+
|
|
1178
|
+
Show every requirement for user confirmation:
|
|
1179
|
+
|
|
1180
|
+
```
|
|
1181
|
+
## v1 Requirements
|
|
1182
|
+
|
|
1183
|
+
### Authentication
|
|
1184
|
+
- [ ] **AUTH-01**: User can create account with email/password
|
|
1185
|
+
- [ ] **AUTH-02**: User can log in and stay logged in across sessions
|
|
1186
|
+
- [ ] **AUTH-03**: User can log out from any page
|
|
1187
|
+
|
|
1188
|
+
### Content
|
|
1189
|
+
- [ ] **CONT-01**: User can create posts with text
|
|
1190
|
+
- [ ] **CONT-02**: User can edit their own posts
|
|
1191
|
+
|
|
1192
|
+
[... full list ...]
|
|
1193
|
+
|
|
1194
|
+
---
|
|
1195
|
+
|
|
1196
|
+
Does this capture what you're building? (yes / adjust)
|
|
1197
|
+
```
|
|
1198
|
+
|
|
1199
|
+
If "adjust": Return to scoping.
|
|
1200
|
+
|
|
1201
|
+
**Commit requirements (guarded):**
|
|
1202
|
+
|
|
1203
|
+
```bash
|
|
1204
|
+
git add .planning/REQUIREMENTS.md 2>/dev/null \
|
|
1205
|
+
&& git commit -m "docs: define v1 requirements" 2>/dev/null \
|
|
1206
|
+
|| echo "ℹ .planning/ gitignored — requirements written, not committed"
|
|
1207
|
+
```
|
|
1208
|
+
|
|
1209
|
+
## 8. Create Roadmap
|
|
1210
|
+
|
|
1211
|
+
Display stage banner:
|
|
1212
|
+
|
|
1213
|
+
```
|
|
1214
|
+
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
1215
|
+
RIHAL ► CREATING ROADMAP
|
|
1216
|
+
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
1217
|
+
|
|
1218
|
+
◆ Spawning roadmapper...
|
|
1219
|
+
```
|
|
1220
|
+
|
|
1221
|
+
Spawn rihal-roadmapper agent:
|
|
1222
|
+
|
|
1223
|
+
```
|
|
1224
|
+
Task(prompt="
|
|
1225
|
+
<planning_context>
|
|
1226
|
+
|
|
1227
|
+
<files_to_read>
|
|
1228
|
+
- .planning/PROJECT.md (Project context)
|
|
1229
|
+
- .planning/REQUIREMENTS.md (v1 Requirements)
|
|
1230
|
+
- .planning/research/SUMMARY.md (Research findings - if exists)
|
|
1231
|
+
- .planning/config.json (Granularity and mode settings)
|
|
1232
|
+
</files_to_read>
|
|
1233
|
+
|
|
1234
|
+
${AGENT_ROADMAPPER}
|
|
1235
|
+
|
|
1236
|
+
</planning_context>
|
|
1237
|
+
|
|
1238
|
+
<instructions>
|
|
1239
|
+
Create roadmap:
|
|
1240
|
+
1. Derive phases from requirements (don't impose structure)
|
|
1241
|
+
2. Map every v1 requirement to exactly one phase
|
|
1242
|
+
3. Derive 2-5 success criteria per phase (observable user behaviors)
|
|
1243
|
+
4. Validate 100% coverage
|
|
1244
|
+
5. Write files immediately (ROADMAP.md, STATE.md, update REQUIREMENTS.md traceability)
|
|
1245
|
+
6. Return ROADMAP CREATED with summary
|
|
1246
|
+
|
|
1247
|
+
Write files first, then return. This ensures artifacts persist even if context is lost.
|
|
1248
|
+
</instructions>
|
|
1249
|
+
", subagent_type="rihal-roadmapper", model="${ROADMAPPER_MODEL}", description="Create roadmap")
|
|
1250
|
+
```
|
|
1251
|
+
|
|
1252
|
+
**Handle roadmapper return:**
|
|
1253
|
+
|
|
1254
|
+
**If `## ROADMAP BLOCKED`:**
|
|
1255
|
+
|
|
1256
|
+
- Present blocker information
|
|
1257
|
+
- Work with user to resolve
|
|
1258
|
+
- Re-spawn when resolved
|
|
1259
|
+
|
|
1260
|
+
**If `## ROADMAP CREATED`:**
|
|
1261
|
+
|
|
1262
|
+
Read the created ROADMAP.md and present it nicely inline:
|
|
1263
|
+
|
|
1264
|
+
```
|
|
1265
|
+
---
|
|
1266
|
+
|
|
1267
|
+
## Proposed Roadmap
|
|
1268
|
+
|
|
1269
|
+
**[N] phases** | **[X] requirements mapped** | All v1 requirements covered ✓
|
|
1270
|
+
|
|
1271
|
+
| # | Phase | Goal | Requirements | Success Criteria |
|
|
1272
|
+
|---|-------|------|--------------|------------------|
|
|
1273
|
+
| 1 | [Name] | [Goal] | [REQ-IDs] | [count] |
|
|
1274
|
+
| 2 | [Name] | [Goal] | [REQ-IDs] | [count] |
|
|
1275
|
+
| 3 | [Name] | [Goal] | [REQ-IDs] | [count] |
|
|
1276
|
+
|
|
1277
|
+
### Phase Details
|
|
1278
|
+
|
|
1279
|
+
**Phase 1: [Name]**
|
|
1280
|
+
Goal: [goal]
|
|
1281
|
+
Requirements: [REQ-IDs]
|
|
1282
|
+
Success criteria:
|
|
1283
|
+
1. [criterion]
|
|
1284
|
+
2. [criterion]
|
|
1285
|
+
3. [criterion]
|
|
1286
|
+
|
|
1287
|
+
[... continue for all phases ...]
|
|
1288
|
+
|
|
1289
|
+
---
|
|
1290
|
+
```
|
|
1291
|
+
|
|
1292
|
+
**If auto mode:** Skip approval gate — auto-approve and commit directly.
|
|
1293
|
+
|
|
1294
|
+
**CRITICAL: Ask for approval before committing (interactive mode only):**
|
|
1295
|
+
|
|
1296
|
+
Use AskUserQuestion:
|
|
1297
|
+
|
|
1298
|
+
- header: "Roadmap"
|
|
1299
|
+
- question: "Does this roadmap structure work for you?"
|
|
1300
|
+
- options:
|
|
1301
|
+
- "Approve" — Commit and continue
|
|
1302
|
+
- "Adjust phases" — Tell me what to change
|
|
1303
|
+
- "Review full file" — Show raw ROADMAP.md
|
|
1304
|
+
|
|
1305
|
+
**If "Approve":** Continue to commit.
|
|
1306
|
+
|
|
1307
|
+
**If "Adjust phases":**
|
|
1308
|
+
|
|
1309
|
+
- Get user's adjustment notes
|
|
1310
|
+
- Re-spawn roadmapper with revision context:
|
|
1311
|
+
|
|
1312
|
+
```
|
|
1313
|
+
Task(prompt="
|
|
1314
|
+
<revision>
|
|
1315
|
+
User feedback on roadmap:
|
|
1316
|
+
[user's notes]
|
|
1317
|
+
|
|
1318
|
+
<files_to_read>
|
|
1319
|
+
- .planning/ROADMAP.md (Current roadmap to revise)
|
|
1320
|
+
</files_to_read>
|
|
1321
|
+
|
|
1322
|
+
${AGENT_ROADMAPPER}
|
|
1323
|
+
|
|
1324
|
+
Update the roadmap based on feedback. Edit files in place.
|
|
1325
|
+
Return ROADMAP REVISED with changes made.
|
|
1326
|
+
</revision>
|
|
1327
|
+
", subagent_type="rihal-roadmapper", model="${ROADMAPPER_MODEL}", description="Revise roadmap")
|
|
1328
|
+
```
|
|
1329
|
+
|
|
1330
|
+
- Present revised roadmap
|
|
1331
|
+
- Loop until user approves
|
|
1332
|
+
|
|
1333
|
+
**If "Review full file":** Display raw `cat .planning/ROADMAP.md`, then re-ask.
|
|
1334
|
+
|
|
1335
|
+
**Generate or refresh project instruction file before final commit:**
|
|
1336
|
+
|
|
1337
|
+
The rihal-tools CLI does not expose a `generate-claude-md` subcommand. Instead, if `$INSTRUCTION_FILE` does not already exist, write a minimal instruction file pointing at the rihal workflow docs:
|
|
1338
|
+
|
|
1339
|
+
```markdown
|
|
1340
|
+
# {INSTRUCTION_FILE} — project instructions
|
|
1341
|
+
|
|
1342
|
+
This project uses Rihal for planning and execution. See `.planning/PROJECT.md` for context and `.planning/ROADMAP.md` for phases.
|
|
1343
|
+
|
|
1344
|
+
Common commands:
|
|
1345
|
+
- /rihal:progress — check status and next action
|
|
1346
|
+
- /rihal:discuss-phase N — gather context before planning phase N
|
|
1347
|
+
- /rihal:plan N — create a SPRINT.md for phase N
|
|
1348
|
+
- /rihal:execute N — execute a SPRINT.md
|
|
1349
|
+
- /rihal:verify-work — conversational UAT
|
|
1350
|
+
- /rihal:complete-milestone — archive milestone and reset
|
|
1351
|
+
|
|
1352
|
+
Rules:
|
|
1353
|
+
- Never run `git push` without explicit user authorization.
|
|
1354
|
+
- No Claude/AI attribution in commits.
|
|
1355
|
+
- Prefer editing existing files over creating new ones.
|
|
1356
|
+
```
|
|
1357
|
+
|
|
1358
|
+
If it already exists, leave it alone (respect user-customized content).
|
|
1359
|
+
|
|
1360
|
+
**Commit roadmap (guarded):**
|
|
1361
|
+
|
|
1362
|
+
```bash
|
|
1363
|
+
git add \
|
|
1364
|
+
.planning/ROADMAP.md \
|
|
1365
|
+
.planning/STATE.md \
|
|
1366
|
+
.planning/REQUIREMENTS.md \
|
|
1367
|
+
"$INSTRUCTION_FILE" 2>/dev/null \
|
|
1368
|
+
&& git commit -m "docs: create roadmap ([N] phases)" 2>/dev/null \
|
|
1369
|
+
|| echo "ℹ .planning/ gitignored — roadmap written, not committed (instruction file committed separately)"
|
|
1370
|
+
|
|
1371
|
+
# Fallback: also try committing just the instruction file if .planning was ignored
|
|
1372
|
+
git add "$INSTRUCTION_FILE" 2>/dev/null && git commit -m "docs: add project instruction file" 2>/dev/null || true
|
|
1373
|
+
```
|
|
1374
|
+
|
|
1375
|
+
## 9. Done
|
|
1376
|
+
|
|
1377
|
+
Present completion summary:
|
|
1378
|
+
|
|
1379
|
+
```
|
|
1380
|
+
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
1381
|
+
RIHAL ► PROJECT INITIALIZED ✓
|
|
1382
|
+
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
1383
|
+
|
|
1384
|
+
**[Project Name]**
|
|
1385
|
+
|
|
1386
|
+
| Artifact | Location |
|
|
1387
|
+
|----------------|-----------------------------|
|
|
1388
|
+
| Project | `.planning/PROJECT.md` |
|
|
1389
|
+
| Config | `.planning/config.json` |
|
|
1390
|
+
| Research | `.planning/research/` |
|
|
1391
|
+
| Requirements | `.planning/REQUIREMENTS.md` |
|
|
1392
|
+
| Roadmap | `.planning/ROADMAP.md` |
|
|
1393
|
+
| Project guide | `$INSTRUCTION_FILE` |
|
|
1394
|
+
|
|
1395
|
+
**[N] phases** | **[X] requirements** | Ready to build ✓
|
|
1396
|
+
```
|
|
1397
|
+
|
|
1398
|
+
**If auto mode:**
|
|
1399
|
+
|
|
1400
|
+
```
|
|
1401
|
+
╔══════════════════════════════════════════╗
|
|
1402
|
+
║ AUTO-ADVANCING → DISCUSS PHASE 1 ║
|
|
1403
|
+
╚══════════════════════════════════════════╝
|
|
1404
|
+
```
|
|
1405
|
+
|
|
1406
|
+
Exit skill and invoke `/rihal:discuss-phase 1 --auto`.
|
|
1407
|
+
|
|
1408
|
+
**If interactive mode:**
|
|
1409
|
+
|
|
1410
|
+
Check if Phase 1 has UI indicators in ROADMAP.md:
|
|
1411
|
+
|
|
1412
|
+
```bash
|
|
1413
|
+
PHASE1_SECTION=$(sed -n '/^## Phase 1/,/^## Phase /p' .planning/ROADMAP.md)
|
|
1414
|
+
PHASE1_HAS_UI=$(echo "$PHASE1_SECTION" | grep -qiE "UI|interface|frontend|component|layout|page|screen|view|form|dashboard|widget" && echo "true" || echo "false")
|
|
1415
|
+
```
|
|
1416
|
+
|
|
1417
|
+
**If Phase 1 has UI:**
|
|
1418
|
+
|
|
1419
|
+
```
|
|
1420
|
+
───────────────────────────────────────────────────────────────
|
|
1421
|
+
|
|
1422
|
+
## ▶ Next Up
|
|
1423
|
+
|
|
1424
|
+
**Phase 1: [Phase Name]** — [Goal from ROADMAP.md]
|
|
1425
|
+
|
|
1426
|
+
/clear then:
|
|
1427
|
+
|
|
1428
|
+
/rihal:discuss-phase 1 — gather context and clarify approach
|
|
1429
|
+
|
|
1430
|
+
---
|
|
1431
|
+
|
|
1432
|
+
**Also available:**
|
|
1433
|
+
- /rihal:ui-phase 1 — generate UI design contract (recommended for frontend phases)
|
|
1434
|
+
- /rihal:plan 1 — skip discussion, plan directly
|
|
1435
|
+
|
|
1436
|
+
───────────────────────────────────────────────────────────────
|
|
1437
|
+
```
|
|
1438
|
+
|
|
1439
|
+
**If Phase 1 has no UI:**
|
|
1440
|
+
|
|
1441
|
+
```
|
|
1442
|
+
───────────────────────────────────────────────────────────────
|
|
1443
|
+
|
|
1444
|
+
## ▶ Next Up
|
|
1445
|
+
|
|
1446
|
+
**Phase 1: [Phase Name]** — [Goal from ROADMAP.md]
|
|
1447
|
+
|
|
1448
|
+
/clear then:
|
|
1449
|
+
|
|
1450
|
+
/rihal:discuss-phase 1 — gather context and clarify approach
|
|
1451
|
+
|
|
1452
|
+
---
|
|
1453
|
+
|
|
1454
|
+
**Also available:**
|
|
1455
|
+
- /rihal:plan 1 — skip discussion, plan directly
|
|
1456
|
+
|
|
1457
|
+
───────────────────────────────────────────────────────────────
|
|
1458
|
+
```
|
|
1459
|
+
|
|
1460
|
+
</process>
|
|
1461
|
+
|
|
1462
|
+
<output>
|
|
1463
|
+
|
|
1464
|
+
- `.planning/PROJECT.md`
|
|
1465
|
+
- `.planning/config.json`
|
|
1466
|
+
- `.planning/research/` (if research selected)
|
|
1467
|
+
- `STACK.md`
|
|
1468
|
+
- `FEATURES.md`
|
|
1469
|
+
- `ARCHITECTURE.md`
|
|
1470
|
+
- `PITFALLS.md`
|
|
1471
|
+
- `SUMMARY.md`
|
|
1472
|
+
- `.planning/REQUIREMENTS.md`
|
|
1473
|
+
- `.planning/ROADMAP.md`
|
|
1474
|
+
- `.planning/STATE.md`
|
|
1475
|
+
- `$INSTRUCTION_FILE` (`AGENTS.md` for Codex, `CLAUDE.md` for all other runtimes)
|
|
1476
|
+
|
|
1477
|
+
</output>
|
|
1478
|
+
|
|
1479
|
+
<success_criteria>
|
|
1480
|
+
|
|
1481
|
+
- [ ] .planning/ directory created
|
|
1482
|
+
- [ ] Git repo initialized
|
|
1483
|
+
- [ ] Brownfield detection completed
|
|
1484
|
+
- [ ] Deep questioning completed (threads followed, not rushed)
|
|
1485
|
+
- [ ] PROJECT.md captures full context → **committed (or noted as gitignored)**
|
|
1486
|
+
- [ ] config.json has workflow mode, granularity, parallelization → **committed**
|
|
1487
|
+
- [ ] Research completed (if selected) — 4 parallel agents spawned → **committed**
|
|
1488
|
+
- [ ] Requirements gathered (from research or conversation)
|
|
1489
|
+
- [ ] User scoped each category (v1/v2/out of scope)
|
|
1490
|
+
- [ ] REQUIREMENTS.md created with REQ-IDs → **committed**
|
|
1491
|
+
- [ ] rihal-roadmapper spawned with context
|
|
1492
|
+
- [ ] Roadmap files written immediately (not draft)
|
|
1493
|
+
- [ ] User feedback incorporated (if any)
|
|
1494
|
+
- [ ] ROADMAP.md created with phases, requirement mappings, success criteria
|
|
1495
|
+
- [ ] STATE.md initialized
|
|
1496
|
+
- [ ] REQUIREMENTS.md traceability updated
|
|
1497
|
+
- [ ] `$INSTRUCTION_FILE` generated (if missing) with rihal workflow guidance
|
|
1498
|
+
- [ ] User knows next step is `/rihal:discuss-phase 1`
|
|
1499
|
+
- [ ] No `git push` issued by the workflow (per AGENTS.md)
|
|
1500
|
+
|
|
1501
|
+
**Atomic commits:** Each phase commits its artifacts immediately. If context is lost, artifacts persist. When `.planning/` is gitignored, files are written but commit is skipped gracefully.
|
|
1502
|
+
|
|
1503
|
+
</success_criteria>
|