@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,155 @@
|
|
|
1
|
+
# Rihal Execution Protocol
|
|
2
|
+
|
|
3
|
+
Shared reference `@`-included by `execute.md` workflow and `rihal-executor` subagent.
|
|
4
|
+
|
|
5
|
+
**Also see:** @.rihal/references/karpathy-guidelines.md for behavioral principles that apply during execution.
|
|
6
|
+
|
|
7
|
+
## SPRINT.md schema
|
|
8
|
+
|
|
9
|
+
Every plan file must have this frontmatter and structure:
|
|
10
|
+
|
|
11
|
+
```markdown
|
|
12
|
+
---
|
|
13
|
+
id: "01.02" # full hierarchical ID
|
|
14
|
+
phase: "01" # phase ID (2-digit, zero-padded)
|
|
15
|
+
plan: "02" # plan ID within phase (2-digit, zero-padded)
|
|
16
|
+
milestone: "M1" # optional, if assigned to milestone
|
|
17
|
+
type: auto | tdd
|
|
18
|
+
depends_on: [] # list of other plan IDs like ["01.01"]
|
|
19
|
+
wave: 1 # auto-derived from depends_on
|
|
20
|
+
---
|
|
21
|
+
|
|
22
|
+
## Objective
|
|
23
|
+
One sentence describing what this plan achieves.
|
|
24
|
+
|
|
25
|
+
## Success criteria
|
|
26
|
+
- [ ] Specific, verifiable outcome
|
|
27
|
+
|
|
28
|
+
## Tasks
|
|
29
|
+
|
|
30
|
+
### Task 01.02.01 — name
|
|
31
|
+
type: auto
|
|
32
|
+
**Steps:**
|
|
33
|
+
1. ...
|
|
34
|
+
**Done when:** specific, observable condition
|
|
35
|
+
**Commit:** feat(scope): description
|
|
36
|
+
|
|
37
|
+
### Task 01.02.02 — name
|
|
38
|
+
type: checkpoint:human-verify
|
|
39
|
+
**Verify:** what the human must confirm before continuing
|
|
40
|
+
```
|
|
41
|
+
|
|
42
|
+
**Hierarchical ID format:**
|
|
43
|
+
- Milestone: `M{N}` (e.g., M1, M2)
|
|
44
|
+
- Phase: `{NN}` 2-digit, zero-padded (e.g., 01, 02, 72)
|
|
45
|
+
- Decimal phase (inserted): `{NN.M}` (e.g., 02.1, 72.3)
|
|
46
|
+
- Plan within phase: `{NN.MM}` (e.g., 01.02)
|
|
47
|
+
- Task within plan: `{NN.MM.TT}` (e.g., 01.02.03)
|
|
48
|
+
|
|
49
|
+
**Task types:**
|
|
50
|
+
- `auto` — executor runs without pausing
|
|
51
|
+
- `checkpoint:human-verify` — executor stops, prints return format, waits for human
|
|
52
|
+
- `checkpoint:decision` — executor stopped itself due to a deviation requiring architectural choice
|
|
53
|
+
|
|
54
|
+
## Deviation rules
|
|
55
|
+
|
|
56
|
+
When the executor encounters something unexpected:
|
|
57
|
+
|
|
58
|
+
1. **Bug in the task itself** → fix it, continue, note in SUMMARY
|
|
59
|
+
2. **Missing critical dependency** (file, package, env var) → add it, continue, note in SUMMARY
|
|
60
|
+
3. **Blocking issue not in the plan** → fix the blocker, continue, note in SUMMARY
|
|
61
|
+
4. **Architectural change required** (the plan's approach is fundamentally wrong) → STOP, return `checkpoint:decision` with the options
|
|
62
|
+
|
|
63
|
+
Rules 1-3 are auto. Rule 4 always pauses for human decision.
|
|
64
|
+
|
|
65
|
+
## Analysis paralysis guard
|
|
66
|
+
|
|
67
|
+
If the executor has made 5+ Read/Grep/Glob calls without a Write, Edit, or Bash that changes state — STOP. Write what you have so far, commit, and continue from the next task. Do not read more before acting.
|
|
68
|
+
|
|
69
|
+
## Checkpoint return format
|
|
70
|
+
|
|
71
|
+
When an executor hits a checkpoint, it returns exactly this block and stops:
|
|
72
|
+
|
|
73
|
+
```
|
|
74
|
+
---CHECKPOINT REACHED---
|
|
75
|
+
Plan: {plan file path}
|
|
76
|
+
Task: {task name}
|
|
77
|
+
Type: {human-verify | decision}
|
|
78
|
+
|
|
79
|
+
{For human-verify:}
|
|
80
|
+
Please verify: {what to check}
|
|
81
|
+
URL/path: {where to look}
|
|
82
|
+
Resume with: /rihal:execute {plan} --continue
|
|
83
|
+
|
|
84
|
+
{For decision:}
|
|
85
|
+
Problem: {what the plan assumed that isn't true}
|
|
86
|
+
Option A: {approach} — {trade-off}
|
|
87
|
+
Option B: {approach} — {trade-off}
|
|
88
|
+
Recommendation: {which one and why}
|
|
89
|
+
Resume with: /rihal:execute {plan} --continue --option=A
|
|
90
|
+
---
|
|
91
|
+
```
|
|
92
|
+
|
|
93
|
+
## Commit protocol
|
|
94
|
+
|
|
95
|
+
After every completed `auto` task:
|
|
96
|
+
|
|
97
|
+
1. `git status --short` — confirm only expected files changed
|
|
98
|
+
2. Stage specific files: `git add path/to/file` — never `git add -A`
|
|
99
|
+
3. Commit: `type(scope): description` (Conventional Commits)
|
|
100
|
+
4. Record the SHA in the SUMMARY
|
|
101
|
+
|
|
102
|
+
**Never add:** `Co-Authored-By: Claude`, `Generated with Claude Code`, or any AI attribution.
|
|
103
|
+
**Never use:** `--no-verify`.
|
|
104
|
+
**Never run:** `git push` — pushing requires explicit human authorization outside the executor's scope. Commits only.
|
|
105
|
+
|
|
106
|
+
## SUMMARY format
|
|
107
|
+
|
|
108
|
+
Written to `{plan-dir}/{plan-name}-SUMMARY.md` after completion:
|
|
109
|
+
|
|
110
|
+
```markdown
|
|
111
|
+
# Plan Summary — {plan name}
|
|
112
|
+
|
|
113
|
+
**Status:** complete | partial
|
|
114
|
+
**Duration:** {start} → {end}
|
|
115
|
+
**Commits:** {count}
|
|
116
|
+
|
|
117
|
+
## Tasks
|
|
118
|
+
- [x] Task 1 — {commit SHA}
|
|
119
|
+
- [x] Task 2 — {commit SHA}
|
|
120
|
+
- [ ] Task 3 — SKIPPED: {reason}
|
|
121
|
+
|
|
122
|
+
## Deviations
|
|
123
|
+
- {deviation description} → {rule applied} → {resolution}
|
|
124
|
+
|
|
125
|
+
## Known Stubs
|
|
126
|
+
(Optional section if stubs exist)
|
|
127
|
+
- [file:line] stub pattern → reason → resolved in [plan name]
|
|
128
|
+
|
|
129
|
+
## Self-Check
|
|
130
|
+
**Status:** PASSED | FAILED
|
|
131
|
+
- Task count: {count} completed vs {plan count} in plan
|
|
132
|
+
- Commits: {count} recorded
|
|
133
|
+
- Criteria: {verified count}/{total} verified
|
|
134
|
+
```
|
|
135
|
+
|
|
136
|
+
### Stub Detection
|
|
137
|
+
|
|
138
|
+
Before writing SUMMARY.md, executor scans all modified files for stub patterns:
|
|
139
|
+
- `TODO` / `FIXME` / `XXX` comments
|
|
140
|
+
- `throw new Error('not implemented')` or `throw new Error('TODO')`
|
|
141
|
+
- Placeholder values: `'YOUR_API_KEY'`, `'REPLACE_ME'`
|
|
142
|
+
- `console.log` in non-test files
|
|
143
|
+
- Empty function bodies: `return null` / `return undefined`
|
|
144
|
+
|
|
145
|
+
If stubs exist, add `## Known Stubs` section listing each with file:line and resolution plan. Do NOT mark complete if stubs block success criteria.
|
|
146
|
+
|
|
147
|
+
### Self-Check Loop
|
|
148
|
+
|
|
149
|
+
After writing SUMMARY.md:
|
|
150
|
+
1. **Count tasks:** SUMMARY task count must match plan task count
|
|
151
|
+
2. **Count commits:** Commits listed must exist in git log
|
|
152
|
+
3. **Verify criteria:** Each success criterion has evidence (diff line, test, or SUMMARY entry)
|
|
153
|
+
4. **Report result:** Append `## Self-Check: PASSED/FAILED` with deltas if failed
|
|
154
|
+
|
|
155
|
+
Stop before state updates if self-check fails.
|
|
@@ -0,0 +1,212 @@
|
|
|
1
|
+
# Gate Prompts
|
|
2
|
+
|
|
3
|
+
Gate prompts enforce safety, reversibility, and clarity at critical decision points. They follow three canonical patterns: **Safety gates** (before risky actions), **Decision gates** (before irreversible commitments), and **Escalation gates** (when uncertainty exceeds tolerance).
|
|
4
|
+
|
|
5
|
+
All gate prompts reference `.rihal/references/no-unauthorized-git-ops.md` — never allow unauthorized commits, pushes, or force operations.
|
|
6
|
+
|
|
7
|
+
---
|
|
8
|
+
|
|
9
|
+
## Template: Safety Gate
|
|
10
|
+
|
|
11
|
+
Use before executing **irreversible or high-impact actions** (deletes, force-pushes, breaking changes).
|
|
12
|
+
|
|
13
|
+
**Structure:**
|
|
14
|
+
|
|
15
|
+
```markdown
|
|
16
|
+
## Safety Gate: [Action Name]
|
|
17
|
+
|
|
18
|
+
**You are about to:** [Specific action in plain English]
|
|
19
|
+
|
|
20
|
+
**Impact:** [What user will see/lose if they proceed]
|
|
21
|
+
|
|
22
|
+
**Approval Required**
|
|
23
|
+
|
|
24
|
+
Confirm you want to:
|
|
25
|
+
- [ ] [Specific irreversible consequence 1]
|
|
26
|
+
- [ ] [Specific irreversible consequence 2]
|
|
27
|
+
|
|
28
|
+
Type `yes, proceed` to confirm or `abort` to stop.
|
|
29
|
+
```
|
|
30
|
+
|
|
31
|
+
**Example: Delete Branch**
|
|
32
|
+
|
|
33
|
+
```markdown
|
|
34
|
+
## Safety Gate: Delete Feature Branch
|
|
35
|
+
|
|
36
|
+
You are about to **permanently delete** the branch `feature/payment-redesign` and all uncommitted changes on that branch will be lost.
|
|
37
|
+
|
|
38
|
+
**Consequences:**
|
|
39
|
+
- 3 unpushed commits (1234abc–4567def) will be discarded
|
|
40
|
+
- If you pushed this branch to origin, the remote copy will remain (must delete separately)
|
|
41
|
+
- This cannot be undone
|
|
42
|
+
|
|
43
|
+
Confirm:
|
|
44
|
+
- [ ] I have reviewed all unpushed commits (above)
|
|
45
|
+
- [ ] I understand this is permanent
|
|
46
|
+
- [ ] I accept responsibility for any lost work
|
|
47
|
+
|
|
48
|
+
Type `yes, proceed` to delete or `abort` to stop.
|
|
49
|
+
```
|
|
50
|
+
|
|
51
|
+
---
|
|
52
|
+
|
|
53
|
+
## Template: Decision Gate
|
|
54
|
+
|
|
55
|
+
Use before **high-stakes architectural or functional commitments** (framework choice, auth model, data migration strategy).
|
|
56
|
+
|
|
57
|
+
**Structure:**
|
|
58
|
+
|
|
59
|
+
```markdown
|
|
60
|
+
## Decision Gate: [Decision Name]
|
|
61
|
+
|
|
62
|
+
**You have chosen:** [Option selected]
|
|
63
|
+
|
|
64
|
+
**Rationale you provided:** [Summary of reasoning]
|
|
65
|
+
|
|
66
|
+
**We will commit to:**
|
|
67
|
+
- [ ] [Consequence 1 — what must now be true]
|
|
68
|
+
- [ ] [Consequence 2 — what becomes harder/impossible]
|
|
69
|
+
- [ ] [Consequence 3 — reversibility or cost of changing later]
|
|
70
|
+
|
|
71
|
+
**Alternative considered:**
|
|
72
|
+
- [Alt 1]: Why not chosen? [Your reasoning]
|
|
73
|
+
- [Alt 2]: Why not chosen? [Your reasoning]
|
|
74
|
+
|
|
75
|
+
Confirm this is the right choice, or select a different option.
|
|
76
|
+
```
|
|
77
|
+
|
|
78
|
+
**Example: Framework Choice**
|
|
79
|
+
|
|
80
|
+
```markdown
|
|
81
|
+
## Decision Gate: Choose Backend Framework
|
|
82
|
+
|
|
83
|
+
**You have chosen:** Express.js
|
|
84
|
+
|
|
85
|
+
**Rationale:** "Lightweight, large ecosystem, familiar to team, handles routing + middleware out of the box"
|
|
86
|
+
|
|
87
|
+
**We will commit to:**
|
|
88
|
+
- [ ] Express patterns (routes, middleware, error handling) will structure all backend code
|
|
89
|
+
- [ ] Team becomes responsible for architectural decisions Express doesn't provide (logging, caching, auth flow)
|
|
90
|
+
- [ ] Switching later requires rewriting routing and middleware (medium cost, ~2-3 days)
|
|
91
|
+
|
|
92
|
+
**Alternatives considered:**
|
|
93
|
+
- Fastify: "Too low-level for our timeline, less middleware ecosystem"
|
|
94
|
+
- NestJS: "Good, but opinionated — less flexibility for experiments"
|
|
95
|
+
|
|
96
|
+
Confirm this is right, or choose differently.
|
|
97
|
+
```
|
|
98
|
+
|
|
99
|
+
---
|
|
100
|
+
|
|
101
|
+
## Template: Irreversible-Action Gate
|
|
102
|
+
|
|
103
|
+
Use before **operations with no undo button** (force-push, delete production data, merge to main without PR).
|
|
104
|
+
|
|
105
|
+
**Structure:**
|
|
106
|
+
|
|
107
|
+
```markdown
|
|
108
|
+
## Gate: Irreversible Action
|
|
109
|
+
|
|
110
|
+
**Action:** [What you're about to do]
|
|
111
|
+
|
|
112
|
+
**Undo Difficulty:** [IMPOSSIBLE | HARD | MEDIUM | EASY]
|
|
113
|
+
|
|
114
|
+
**Recovery Plan** (if action fails):
|
|
115
|
+
[Specific steps to recover, or "Cannot be undone — be certain"]
|
|
116
|
+
|
|
117
|
+
---
|
|
118
|
+
|
|
119
|
+
**Type your confirmation:**
|
|
120
|
+
- For IMPOSSIBLE/HARD: Type the exact phrase `I understand [consequence], proceed`
|
|
121
|
+
- For MEDIUM: Type `yes, proceed`
|
|
122
|
+
- For EASY: Proceed normally (standard confirmation)
|
|
123
|
+
```
|
|
124
|
+
|
|
125
|
+
**Example: Force-Push to Main**
|
|
126
|
+
|
|
127
|
+
```markdown
|
|
128
|
+
## Gate: Force-Push to Main
|
|
129
|
+
|
|
130
|
+
**Action:** `git push --force-with-lease origin main`
|
|
131
|
+
|
|
132
|
+
**Undo Difficulty:** IMPOSSIBLE (force-push rewrites history; commits are lost unless recovered via reflog within 30 days)
|
|
133
|
+
|
|
134
|
+
**Recovery Plan:**
|
|
135
|
+
If commits are lost, recovery requires:
|
|
136
|
+
1. Accessing git reflog (only possible on local machine where push originated)
|
|
137
|
+
2. Resetting to the lost commit
|
|
138
|
+
3. Re-pushing to main (requires another force-push authorization)
|
|
139
|
+
|
|
140
|
+
This is high-risk and should not be attempted in production workflows.
|
|
141
|
+
|
|
142
|
+
---
|
|
143
|
+
|
|
144
|
+
**Type your confirmation:**
|
|
145
|
+
`I understand this cannot be easily undone and may cause data loss, proceed`
|
|
146
|
+
```
|
|
147
|
+
|
|
148
|
+
---
|
|
149
|
+
|
|
150
|
+
## Approval / Revise / Abort Pattern
|
|
151
|
+
|
|
152
|
+
For gates that offer a **choice** (not just yes/no):
|
|
153
|
+
|
|
154
|
+
```markdown
|
|
155
|
+
## Confirmation Gate: [Decision]
|
|
156
|
+
|
|
157
|
+
[Summarize the planned action and its consequences]
|
|
158
|
+
|
|
159
|
+
### Options
|
|
160
|
+
|
|
161
|
+
1. **Approve** — Proceed with the plan as described
|
|
162
|
+
2. **Revise** — Go back and modify [aspect 1], [aspect 2]
|
|
163
|
+
3. **Abort** — Stop here; don't proceed
|
|
164
|
+
|
|
165
|
+
Enter: `approve` | `revise <aspect>` | `abort`
|
|
166
|
+
```
|
|
167
|
+
|
|
168
|
+
**Example: Code Review Findings**
|
|
169
|
+
|
|
170
|
+
```markdown
|
|
171
|
+
## Confirmation Gate: Fix Code Review Issues
|
|
172
|
+
|
|
173
|
+
Found 3 issues:
|
|
174
|
+
1. Missing error handling in `/api/users.js`
|
|
175
|
+
2. Hardcoded API key in `.env.local` (security risk)
|
|
176
|
+
3. Type annotation missing on `fetchUser()` return type
|
|
177
|
+
|
|
178
|
+
All are medium severity. Should we fix before merging?
|
|
179
|
+
|
|
180
|
+
### Options
|
|
181
|
+
|
|
182
|
+
1. **Approve** — Merge as-is (I accept these risks)
|
|
183
|
+
2. **Revise** — Fix issues 1 and 2, skip 3
|
|
184
|
+
3. **Abort** — Stop; I want to rethink this
|
|
185
|
+
|
|
186
|
+
Enter: `approve` | `revise 1,2` | `abort`
|
|
187
|
+
```
|
|
188
|
+
|
|
189
|
+
---
|
|
190
|
+
|
|
191
|
+
## Gate Placement Rules
|
|
192
|
+
|
|
193
|
+
| Gate Type | Placement | User Decision? |
|
|
194
|
+
|---|---|---|
|
|
195
|
+
| Safety | Before destructive operation | Required (explicit yes) |
|
|
196
|
+
| Decision | After exploring options, before implementation | Required (choose path) |
|
|
197
|
+
| Escalation | After investigation, before proceeding with uncertainty | Required (accept or retry) |
|
|
198
|
+
|
|
199
|
+
---
|
|
200
|
+
|
|
201
|
+
## No Unauthorized Git Operations
|
|
202
|
+
|
|
203
|
+
Reference `.rihal/references/no-unauthorized-git-ops.md` before any gate that involves:
|
|
204
|
+
- `git push` (any flag)
|
|
205
|
+
- `git reset --hard`
|
|
206
|
+
- `git rebase`
|
|
207
|
+
- `git checkout` to discard changes
|
|
208
|
+
- `git clean -f`
|
|
209
|
+
|
|
210
|
+
**Rule:** User types the command themselves, or explicitly authorizes it in chat (outside of gate prompts).
|
|
211
|
+
|
|
212
|
+
Gates may **describe** an intended git operation, but the user must actively choose to proceed with full understanding of consequences.
|
|
@@ -0,0 +1,127 @@
|
|
|
1
|
+
# Gates Reference
|
|
2
|
+
|
|
3
|
+
Defines 4 gate types used in rihal workflows to control execution flow, validate decisions, and escalate blockers.
|
|
4
|
+
|
|
5
|
+
## Gate Types
|
|
6
|
+
|
|
7
|
+
### 1. Pre-Flight (Validation Before Action)
|
|
8
|
+
|
|
9
|
+
**Purpose:** Block invalid operations before they start.
|
|
10
|
+
|
|
11
|
+
**Behavior:**
|
|
12
|
+
- Check preconditions (file exists, user authorized, config valid)
|
|
13
|
+
- Either block execution or warn with recovery suggestion
|
|
14
|
+
- Non-blocking warnings permit continuation; blocking gates halt
|
|
15
|
+
|
|
16
|
+
**Recovery:** Suggest specific fix and retry path
|
|
17
|
+
|
|
18
|
+
**Example:** Phase execution gate
|
|
19
|
+
```
|
|
20
|
+
Gate: Check phase.md exists and has required sections
|
|
21
|
+
Block: "Phase {N} has no SPRINT.md. Create with /rihal:help"
|
|
22
|
+
Warn: "Phase overdue by {days}. Review roadmap?"
|
|
23
|
+
```
|
|
24
|
+
|
|
25
|
+
---
|
|
26
|
+
|
|
27
|
+
### 2. Revision (Iteration Loop)
|
|
28
|
+
|
|
29
|
+
**Purpose:** Catch defects within a task, permit retries.
|
|
30
|
+
|
|
31
|
+
**Behavior:**
|
|
32
|
+
- Max retries: 3 (configurable per workflow)
|
|
33
|
+
- Detect stalls: if N consecutive attempts fail identically, escalate
|
|
34
|
+
- Log each retry attempt with timestamp and error
|
|
35
|
+
|
|
36
|
+
**Recovery:** After 3 failures, escalate to Escalation gate
|
|
37
|
+
|
|
38
|
+
**Example:** Code compilation gate
|
|
39
|
+
```
|
|
40
|
+
Revision Loop: Test build
|
|
41
|
+
Retry 1: "Build failed: missing import. Added import, retrying..."
|
|
42
|
+
Retry 2: "Build failed: type error. Fixed type, retrying..."
|
|
43
|
+
Retry 3: "Build succeeded."
|
|
44
|
+
On 4th failure: escalate to user
|
|
45
|
+
```
|
|
46
|
+
|
|
47
|
+
---
|
|
48
|
+
|
|
49
|
+
### 3. Escalation (Decision Needed)
|
|
50
|
+
|
|
51
|
+
**Purpose:** Pause execution and ask user for direction.
|
|
52
|
+
|
|
53
|
+
**Behavior:**
|
|
54
|
+
- Preserve current state (save SPRINT.md, commit progress)
|
|
55
|
+
- Pause execution with AskUserQuestion
|
|
56
|
+
- Wait for user decision (proceed, abort, or retry with modified approach)
|
|
57
|
+
- Log decision timestamp and rationale
|
|
58
|
+
|
|
59
|
+
**Recovery:** User confirms direction; resume or return to Revision
|
|
60
|
+
|
|
61
|
+
**Example:** Architecture decision gate
|
|
62
|
+
```
|
|
63
|
+
Gate: Design choice between Pattern A and Pattern B
|
|
64
|
+
State: Saved current work, phase paused
|
|
65
|
+
Ask: "Pattern A is faster but less flexible. Pattern B is extensible but slower.
|
|
66
|
+
Which should we implement? (A/B/defer)"
|
|
67
|
+
```
|
|
68
|
+
|
|
69
|
+
---
|
|
70
|
+
|
|
71
|
+
### 4. Abort (Unrecoverable)
|
|
72
|
+
|
|
73
|
+
**Purpose:** Exit gracefully when task cannot proceed.
|
|
74
|
+
|
|
75
|
+
**Behavior:**
|
|
76
|
+
- Preserve all state (don't delete files, commit progress, log cause)
|
|
77
|
+
- Exit cleanly without recovery attempt
|
|
78
|
+
- Suggest manual recovery path
|
|
79
|
+
|
|
80
|
+
**Recovery:** Manual repair via `/rihal:health` or `/rihal:forensics`
|
|
81
|
+
|
|
82
|
+
**Example:** Corrupted state gate
|
|
83
|
+
```
|
|
84
|
+
Gate: Validate state.json integrity
|
|
85
|
+
Fail: "state.json corrupted (invalid JSON at line 42).
|
|
86
|
+
Aborting to prevent further damage.
|
|
87
|
+
Recovery: /rihal:health --repair"
|
|
88
|
+
```
|
|
89
|
+
|
|
90
|
+
---
|
|
91
|
+
|
|
92
|
+
## State Preservation Rules
|
|
93
|
+
|
|
94
|
+
**Revision gates:** Commit work-in-progress at each retry
|
|
95
|
+
```bash
|
|
96
|
+
git add -A
|
|
97
|
+
git commit -m "wip: revision loop attempt {N} of {max}"
|
|
98
|
+
```
|
|
99
|
+
|
|
100
|
+
**Escalation gates:** Tag the commit with the question
|
|
101
|
+
```bash
|
|
102
|
+
git add -A
|
|
103
|
+
git commit -m "session: escalation gate at {phase} — awaiting user input"
|
|
104
|
+
```
|
|
105
|
+
|
|
106
|
+
**Abort gates:** Preserve full state, no cleanup
|
|
107
|
+
```bash
|
|
108
|
+
git add -A
|
|
109
|
+
git commit -m "session: abort gate — state preserved for manual repair"
|
|
110
|
+
# Do NOT delete files, do NOT reset --hard
|
|
111
|
+
```
|
|
112
|
+
|
|
113
|
+
---
|
|
114
|
+
|
|
115
|
+
## Iteration Cap Rule
|
|
116
|
+
|
|
117
|
+
Revision gates must fail fast:
|
|
118
|
+
- **Cap:** 3 retries maximum per gate
|
|
119
|
+
- **Stall detection:** If retries 2 and 3 fail identically, escalate immediately
|
|
120
|
+
- **Rationale:** Prevent infinite loops; protect token budget
|
|
121
|
+
|
|
122
|
+
Example stall detection:
|
|
123
|
+
```
|
|
124
|
+
Retry 2 error: "Compilation failed: missing MockDB"
|
|
125
|
+
Retry 3 error: "Compilation failed: missing MockDB"
|
|
126
|
+
→ Detect stall (identical error) → Escalate to user
|
|
127
|
+
```
|
|
@@ -0,0 +1,159 @@
|
|
|
1
|
+
# Git Integration Reference
|
|
2
|
+
|
|
3
|
+
Defines 3 branching strategies for rihal workflows and when to use each.
|
|
4
|
+
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
## Configuration
|
|
8
|
+
|
|
9
|
+
Add to `config.yaml`:
|
|
10
|
+
|
|
11
|
+
```yaml
|
|
12
|
+
git:
|
|
13
|
+
branching_strategy: "feature-branch" # options: none, feature-branch, worktree-isolation
|
|
14
|
+
```
|
|
15
|
+
|
|
16
|
+
---
|
|
17
|
+
|
|
18
|
+
## 3 Branching Strategies
|
|
19
|
+
|
|
20
|
+
### 1. None (Commit to Current Branch)
|
|
21
|
+
|
|
22
|
+
**Complexity:** ⭐ (minimal)
|
|
23
|
+
**Cleanliness:** ⭐ (messy history)
|
|
24
|
+
**Parallel Safety:** ⭐ (unsafe)
|
|
25
|
+
|
|
26
|
+
**How it works:**
|
|
27
|
+
- All commits go to current branch (typically main or v2-prototype)
|
|
28
|
+
- No branch creation; no cleanup
|
|
29
|
+
- Linear history but mixed concerns (planning, code, docs)
|
|
30
|
+
|
|
31
|
+
**When to use:**
|
|
32
|
+
- Solo development, local experimentation
|
|
33
|
+
- Fast prototyping where history doesn't matter
|
|
34
|
+
- Quick fixes, immediate merge to main
|
|
35
|
+
|
|
36
|
+
**Trade-offs:**
|
|
37
|
+
- ✅ Zero overhead
|
|
38
|
+
- ❌ Pollutes main with wip/planning commits
|
|
39
|
+
- ❌ Can't revert feature without reverting unrelated work
|
|
40
|
+
- ❌ CI might fail on intermediate commits
|
|
41
|
+
|
|
42
|
+
---
|
|
43
|
+
|
|
44
|
+
### 2. Feature-Branch (Auto-Create Per Phase)
|
|
45
|
+
|
|
46
|
+
**Complexity:** ⭐⭐⭐ (moderate)
|
|
47
|
+
**Cleanliness:** ⭐⭐⭐⭐ (clean history)
|
|
48
|
+
**Parallel Safety:** ⭐⭐ (limited)
|
|
49
|
+
|
|
50
|
+
**How it works:**
|
|
51
|
+
- Workflow auto-creates branch per phase: `phase/1-setup`, `phase/2-auth`, etc.
|
|
52
|
+
- All commits in phase go to phase branch
|
|
53
|
+
- PR to main when phase complete
|
|
54
|
+
- Delete branch after merge
|
|
55
|
+
|
|
56
|
+
**When to use:**
|
|
57
|
+
- Standard team workflow, code review required
|
|
58
|
+
- Multi-phase projects with clean phase boundaries
|
|
59
|
+
- Need clear history of which commits belong to which phase
|
|
60
|
+
- CI/CD integration with branch-based triggers
|
|
61
|
+
|
|
62
|
+
**Trade-offs:**
|
|
63
|
+
- ✅ Clean history, easy PR review
|
|
64
|
+
- ✅ Can revert entire phase with one revert commit
|
|
65
|
+
- ⚠️ Branch management overhead (create, delete, rebase)
|
|
66
|
+
- ❌ Can't work on multiple phases in parallel
|
|
67
|
+
|
|
68
|
+
---
|
|
69
|
+
|
|
70
|
+
### 3. Worktree-Isolation (Each Phase in Worktree)
|
|
71
|
+
|
|
72
|
+
**Complexity:** ⭐⭐⭐⭐⭐ (high)
|
|
73
|
+
**Cleanliness:** ⭐⭐⭐⭐⭐ (pristine)
|
|
74
|
+
**Parallel Safety:** ⭐⭐⭐⭐⭐ (safe)
|
|
75
|
+
|
|
76
|
+
**How it works:**
|
|
77
|
+
- Each phase runs in isolated `git worktree`
|
|
78
|
+
- Phase branch created, checked out in worktree
|
|
79
|
+
- Work in isolation; no interference with main or other phases
|
|
80
|
+
- Each worktree has independent working directory and index
|
|
81
|
+
- Switch between phases by exiting/entering worktrees
|
|
82
|
+
|
|
83
|
+
**When to use:**
|
|
84
|
+
- Parallel multi-phase execution
|
|
85
|
+
- Complex features needing isolated testing
|
|
86
|
+
- Multiple team members working different phases simultaneously
|
|
87
|
+
- High-risk changes requiring clean rollback
|
|
88
|
+
|
|
89
|
+
**Trade-offs:**
|
|
90
|
+
- ✅ True isolation, zero branch interference
|
|
91
|
+
- ✅ Parallel work on multiple phases
|
|
92
|
+
- ✅ Easy rollback (delete worktree, delete branch)
|
|
93
|
+
- ❌ Disk overhead (separate directory per phase)
|
|
94
|
+
- ❌ More cognitive load (track multiple worktrees)
|
|
95
|
+
- ⚠️ Requires git worktree knowledge
|
|
96
|
+
|
|
97
|
+
---
|
|
98
|
+
|
|
99
|
+
## Strategy Decision Tree
|
|
100
|
+
|
|
101
|
+
```
|
|
102
|
+
1. Solo development, quick fix?
|
|
103
|
+
→ Strategy: none
|
|
104
|
+
|
|
105
|
+
2. Team, need clean history, sequential phases?
|
|
106
|
+
→ Strategy: feature-branch
|
|
107
|
+
|
|
108
|
+
3. Parallel phases, isolated testing, or high risk?
|
|
109
|
+
→ Strategy: worktree-isolation
|
|
110
|
+
```
|
|
111
|
+
|
|
112
|
+
---
|
|
113
|
+
|
|
114
|
+
## Implementation Details
|
|
115
|
+
|
|
116
|
+
### None Strategy
|
|
117
|
+
```bash
|
|
118
|
+
# Just commit to current branch
|
|
119
|
+
git add <files>
|
|
120
|
+
git commit -m "feat(...): description"
|
|
121
|
+
```
|
|
122
|
+
|
|
123
|
+
### Feature-Branch Strategy
|
|
124
|
+
```bash
|
|
125
|
+
# Auto-created by workflow
|
|
126
|
+
git checkout -b phase/1-setup
|
|
127
|
+
git add <files>
|
|
128
|
+
git commit -m "feat(...): description"
|
|
129
|
+
# On completion: create PR, merge, delete branch
|
|
130
|
+
```
|
|
131
|
+
|
|
132
|
+
### Worktree-Isolation Strategy
|
|
133
|
+
```bash
|
|
134
|
+
# Workflow commands
|
|
135
|
+
/rihal:do --worktree phase/2-auth
|
|
136
|
+
# Internally:
|
|
137
|
+
git worktree add .claude/worktrees/phase-2-auth phase/2-auth
|
|
138
|
+
cd .claude/worktrees/phase-2-auth
|
|
139
|
+
# Work here, commit, test
|
|
140
|
+
# Exit: cd ../.. ; git worktree remove .claude/worktrees/phase-2-auth
|
|
141
|
+
```
|
|
142
|
+
|
|
143
|
+
---
|
|
144
|
+
|
|
145
|
+
## Config Example
|
|
146
|
+
|
|
147
|
+
```yaml
|
|
148
|
+
# Single-phase project: no branching needed
|
|
149
|
+
git:
|
|
150
|
+
branching_strategy: "none"
|
|
151
|
+
|
|
152
|
+
# Multi-phase, team project: feature branches
|
|
153
|
+
git:
|
|
154
|
+
branching_strategy: "feature-branch"
|
|
155
|
+
|
|
156
|
+
# High-risk, parallel work: worktrees
|
|
157
|
+
git:
|
|
158
|
+
branching_strategy: "worktree-isolation"
|
|
159
|
+
```
|