$npx -y skills add opendatahub-io/ai-helpers --skill doc-pipelineUse this skill to orchestrate the full documentation pipeline. Sequences doc-gather, doc-gap, doc-validate, doc-review, and doc-generate skills based on the requested pipeline mode.
| 1 | # doc-pipeline |
| 2 | |
| 3 | Orchestrate documentation skills in dependency order based on the requested pipeline mode. |
| 4 | |
| 5 | ## Parse arguments |
| 6 | |
| 7 | `$ARGUMENTS` contains: |
| 8 | 1. **Jira key or PR URL**: the feature identifier (required) |
| 9 | 2. **Mode**: one of `gather`, `gap`, `validate`, `review`, `generate` (required) |
| 10 | |
| 11 | ## Pipeline Modes |
| 12 | |
| 13 | | Mode | Skills executed | Use case | |
| 14 | |---|---|---| |
| 15 | | `gather` | doc-gather | Collect context only | |
| 16 | | `gap` | doc-gather → doc-gap | Identify documentation gaps | |
| 17 | | `validate` | doc-gather → doc-validate | Validate existing docs against context | |
| 18 | | `review` | doc-gather → doc-validate → doc-review | Full validation and review of existing docs | |
| 19 | | `generate` | doc-gather → doc-gap → doc-generate → doc-validate → doc-review | Generate docs end-to-end | |
| 20 | |
| 21 | ## Execution Protocol |
| 22 | |
| 23 | ### Step 1: Validate inputs |
| 24 | |
| 25 | - Confirm the Jira key or PR URL is provided |
| 26 | - Confirm the mode is one of the valid options |
| 27 | - Check that `${CLAUDE_SKILL_DIR}/../doc-gather/configs/rhoai.yaml` exists |
| 28 | |
| 29 | ### Step 2: Execute skills in order |
| 30 | |
| 31 | For each skill in the pipeline mode's sequence: |
| 32 | |
| 33 | 1. **Announce** the current phase to the caller |
| 34 | 2. **Invoke** the skill using `/doc-<skill> <arguments>` |
| 35 | 3. **Check** the skill output: |
| 36 | - If the skill produced an output file, verify it exists |
| 37 | - If the skill reported errors, decide whether to continue or halt |
| 38 | 4. **Route** outputs to the next skill (via workspace files) |
| 39 | |
| 40 | ### Skill invocations by mode |
| 41 | |
| 42 | #### mode: gather |
| 43 | ```text |
| 44 | /doc-gather <JIRA-KEY> |
| 45 | ``` |
| 46 | Report: context package summary. |
| 47 | |
| 48 | #### mode: gap |
| 49 | ```text |
| 50 | /doc-gather <JIRA-KEY> |
| 51 | /doc-gap |
| 52 | ``` |
| 53 | Check: if gap report recommendation is `stop`, halt and report gaps to caller. |
| 54 | Report: gap report summary. |
| 55 | |
| 56 | #### mode: validate |
| 57 | ```text |
| 58 | /doc-gather <JIRA-KEY> |
| 59 | /doc-validate <docs-directory> |
| 60 | ``` |
| 61 | The docs directory is determined from the context package (the docs repo checkout path). |
| 62 | Report: validation findings summary. |
| 63 | |
| 64 | #### mode: review |
| 65 | ```text |
| 66 | /doc-gather <JIRA-KEY> |
| 67 | /doc-validate <docs-directory> |
| 68 | /doc-review <docs-directory> |
| 69 | ``` |
| 70 | Report: validation + review findings summary. |
| 71 | |
| 72 | #### mode: generate |
| 73 | ``` |
| 74 | /doc-gather <JIRA-KEY> |
| 75 | /doc-gap |
| 76 | ``` |
| 77 | **Gate**: Check gap report recommendation. |
| 78 | - If `stop`: halt, report insufficient context. |
| 79 | - If `gather-more`: warn, ask caller whether to proceed. |
| 80 | - If `proceed`: continue. |
| 81 | |
| 82 | ```text |
| 83 | /doc-generate |
| 84 | /doc-validate workspace/generated-docs/ |
| 85 | /doc-review workspace/generated-docs/ |
| 86 | ``` |
| 87 | Report: generation report + validation + review summaries. |
| 88 | |
| 89 | ### Step 3: Final report |
| 90 | |
| 91 | After all skills complete, produce a summary: |
| 92 | |
| 93 | ```text |
| 94 | Pipeline: <mode> |
| 95 | Ticket: <JIRA-KEY> |
| 96 | Status: completed|halted |
| 97 | |
| 98 | Phases: |
| 99 | - doc-gather: completed (42 files, 85K tokens) |
| 100 | - doc-gap: completed (recommendation: proceed, confidence: 0.82) |
| 101 | - doc-generate: completed (3 modules, avg confidence: 0.85) |
| 102 | - doc-validate: completed (0 high, 3 medium, 5 low findings) |
| 103 | - doc-review: completed (confidence: 0.78) |
| 104 | |
| 105 | Output files: |
| 106 | - workspace/context-package.json |
| 107 | - workspace/gap-report.json |
| 108 | - workspace/generated-docs/ |
| 109 | - workspace/generation-report.json |
| 110 | - workspace/validation-findings.json |
| 111 | - workspace/review-findings.json |
| 112 | ``` |
| 113 | |
| 114 | ## Stop conditions |
| 115 | |
| 116 | - **Halt**: Invalid mode argument |
| 117 | - **Halt**: Jira key/PR URL not provided |
| 118 | - **Halt**: Gap report recommends `stop` (in gap and generate modes) |
| 119 | - **Ask caller**: Gap report recommends `gather-more` (in generate mode) |
| 120 | - **Continue**: Individual validation/review findings (non-blocking) |
| 121 | - **Continue**: Missing optional tools (vale, lychee — validation runs partial) |
| 122 | |
| 123 | ## Post-pipeline options |
| 124 | |
| 125 | After pipeline completes, offer the caller: |
| 126 | 1. Post findings to a PR: `/doc-post <PR-URL>` |
| 127 | 2. Re-run a specific phase with different parameters |
| 128 | 3. View detailed findings from any phase |