feat(schemas): add sdd-plus-superpowers — integrate Superpowers skills via custom schema (ref #780)#970
feat(schemas): add sdd-plus-superpowers — integrate Superpowers skills via custom schema (ref #780)#970JiangWay wants to merge 3 commits intoFission-AI:mainfrom
Conversation
…d INTEGRATION doc 新增 verify artifact + templates/verify.md 新增 INTEGRATION.md(七節 onboarding 文件) schema.yaml:apply executor 拆 2a/2b、design 變可選、顯式化 TDD/code-review 傳遞 templates/brainstorm.md:加 Alternatives Considered templates/proposal.md:加 Why 字數限制 + From/To 格式 templates/spec.md:展開 MODIFIED/REMOVED/RENAMED delta + archive 套用順序
|
Task completed. I'll start by reviewing the PR diff and understanding the codebase context. Powered by 1Code |
📝 WalkthroughWalkthroughIntroduces a new Changes
Possibly related PRs
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~20 minutes Poem
🚥 Pre-merge checks | ✅ 3✅ Passed checks (3 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
Actionable comments posted: 5
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.
Inline comments:
In `@schemas/sdd-plus-superpowers/INTEGRATION.md`:
- Around line 40-81: The fenced ASCII DAG in INTEGRATION.md opens with an
unlabeled code fence which triggers markdownlint MD040; update the opening fence
for the DAG block (the triple backticks immediately before the ASCII diagram) to
include a language tag such as "text" (i.e. change ``` to ```text) so the block
is explicitly labeled and the linter warning is resolved; ensure the closing
fence remains ``` unchanged.
In `@schemas/sdd-plus-superpowers/README.md`:
- Around line 83-88: The README flow lists /opsx:continue entries and currently
implies that "design" is mandatory; update the sequence text to indicate that
the "design" step is optional (e.g., add "(optional)" or "— optional" after the
`design` entry) so operators know it need not always be performed; modify the
lines containing the `/opsx:continue` entries (specifically the entry
referencing `design`) to include the optional marker and keep formatting
consistent with the surrounding entries.
- Around line 30-34: The fenced diagram block currently has no language tag;
update the code fence around the ASCII workflow (the triple-backtick block
containing "brainstorm ──→ proposal ──→ specs ──→ tasks ──→ plan ...") to
include a language identifier (e.g., change ``` to ```text) so the README.md
passes MD040 linting and renders consistently.
In `@schemas/sdd-plus-superpowers/schema.yaml`:
- Line 1: Normalize the schema file's line endings to LF by converting the file
that contains "name: sdd-plus-superpowers" to use Unix line endings (LF) instead
of CRLF; update the file's line endings (or add a .gitattributes entry for YAML
files to enforce eol=lf) and re-save/commit the file so yamllint no longer
reports "new-lines" errors.
In `@schemas/sdd-plus-superpowers/templates/verify.md`:
- Around line 19-21: The fenced code block in verify.md that contains "<貼上
openspec validate --all 的輸出摘要>" is missing a language identifier (causing
MD040); update the opening fence from ``` to ```text so the block reads as a
text/code block and tools render/lint it consistently, leaving the contained
output unchanged.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Pro
Run ID: d8537d19-e0ee-4ea1-b062-787422688d55
📒 Files selected for processing (10)
schemas/sdd-plus-superpowers/INTEGRATION.mdschemas/sdd-plus-superpowers/README.mdschemas/sdd-plus-superpowers/schema.yamlschemas/sdd-plus-superpowers/templates/brainstorm.mdschemas/sdd-plus-superpowers/templates/design.mdschemas/sdd-plus-superpowers/templates/plan.mdschemas/sdd-plus-superpowers/templates/proposal.mdschemas/sdd-plus-superpowers/templates/spec.mdschemas/sdd-plus-superpowers/templates/tasks.mdschemas/sdd-plus-superpowers/templates/verify.md
| ``` | ||
| ┌──────────────┐ | ||
| │ brainstorm │ ◄── superpowers:brainstorming | ||
| │ (root) │ (2-3 方案 + Alternatives Considered) | ||
| └──────┬───────┘ | ||
| │ | ||
| ├──► ┌──────────┐ | ||
| │ │ proposal │ Why (50-1000 字元) / What Changes / Capabilities | ||
| │ └────┬─────┘ | ||
| │ │ | ||
| │ ▼ | ||
| │ ┌──────────────────┐ | ||
| │ │ specs/**/*.md │ ADDED / MODIFIED / REMOVED / RENAMED | ||
| │ │ (delta specs) │ 每 requirement 含 SHALL/MUST + scenario | ||
| │ └────┬─────────────┘ | ||
| │ │ | ||
| │ ▼ | ||
| │ ┌──────────┐ | ||
| │ │ tasks │ 粗粒度 checkbox(apply 的追蹤載體) | ||
| │ └────┬─────┘ | ||
| │ │ | ||
| │ ▼ | ||
| │ ┌──────────┐ | ||
| │ │ plan │ ◄── superpowers:writing-plans | ||
| │ └────┬─────┘ (2-5 分鐘 micro-step) | ||
| │ │ | ||
| │ │ ─────────┐ | ||
| │ │ │ | ||
| │ │ ┌────▼──────┐ | ||
| │ │ │ apply │ ◄── superpowers:using-git-worktrees | ||
| │ │ │ (phase) │ ◄── superpowers:subagent-driven-development | ||
| │ │ │ │ ├── superpowers:test-driven-development (transitive) | ||
| │ │ │ │ └── superpowers:requesting-code-review (transitive) | ||
| │ │ │ │ ◄── superpowers:finishing-a-development-branch | ||
| │ │ └────┬──────┘ | ||
| │ │ │ | ||
| ▼ ▼ ▼ | ||
| ┌──────────┐ ┌──────────┐ | ||
| │ design │ │ verify │ ◄── openspec-verify-change (5 checks) | ||
| │ (optional)│ └──────────┘ | ||
| └──────────┘ | ||
| ``` |
There was a problem hiding this comment.
Add a language tag to the DAG code fence.
Line 40 opens a fenced block without a language, which trips markdownlint MD040.
Suggested fix
-```
+```text
┌──────────────┐
│ brainstorm │ ◄── superpowers:brainstorming
...
-```
+```🧰 Tools
🪛 markdownlint-cli2 (0.22.0)
[warning] 40-40: Fenced code blocks should have a language specified
(MD040, fenced-code-language)
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.
In `@schemas/sdd-plus-superpowers/INTEGRATION.md` around lines 40 - 81, The fenced
ASCII DAG in INTEGRATION.md opens with an unlabeled code fence which triggers
markdownlint MD040; update the opening fence for the DAG block (the triple
backticks immediately before the ASCII diagram) to include a language tag such
as "text" (i.e. change ``` to ```text) so the block is explicitly labeled and
the linter warning is resolved; ensure the closing fence remains ``` unchanged.
| ``` | ||
| brainstorm ──→ proposal ──→ specs ──→ tasks ──→ plan | ||
| │ ↑ | ||
| └──→ design ──────────┘ | ||
| ``` |
There was a problem hiding this comment.
Specify a language for the workflow code fence.
Line 30 uses a fenced block without language (MD040). Please tag it for consistent linting/rendering.
Suggested patch
-```
+```text
brainstorm ──→ proposal ──→ specs ──→ tasks ──→ plan
│ ↑
└──→ design ──────────┘</details>
<!-- suggestion_start -->
<details>
<summary>📝 Committable suggestion</summary>
> ‼️ **IMPORTANT**
> Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.
```suggestion
🧰 Tools
🪛 markdownlint-cli2 (0.22.0)
[warning] 30-30: Fenced code blocks should have a language specified
(MD040, fenced-code-language)
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.
In `@schemas/sdd-plus-superpowers/README.md` around lines 30 - 34, The fenced
diagram block currently has no language tag; update the code fence around the
ASCII workflow (the triple-backtick block containing "brainstorm ──→ proposal
──→ specs ──→ tasks ──→ plan ...") to include a language identifier (e.g.,
change ``` to ```text) so the README.md passes MD040 linting and renders
consistently.
| /opsx:continue # → brainstorm(互動式對話) | ||
| /opsx:continue # → proposal | ||
| /opsx:continue # → design | ||
| /opsx:continue # → specs | ||
| /opsx:continue # → tasks | ||
| /opsx:continue # → plan |
There was a problem hiding this comment.
Clarify that design is optional in the step-by-step flow.
Lines 85-86 currently read like design is always required. If this schema keeps design optional, this sequence should explicitly mark that step as optional to avoid operator confusion.
Suggested patch
/opsx:continue # → proposal
-/opsx:continue # → design
+/opsx:continue # → design(optional)
/opsx:continue # → specs🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.
In `@schemas/sdd-plus-superpowers/README.md` around lines 83 - 88, The README flow
lists /opsx:continue entries and currently implies that "design" is mandatory;
update the sequence text to indicate that the "design" step is optional (e.g.,
add "(optional)" or "— optional" after the `design` entry) so operators know it
need not always be performed; modify the lines containing the `/opsx:continue`
entries (specifically the entry referencing `design`) to include the optional
marker and keep formatting consistent with the surrounding entries.
| @@ -0,0 +1,282 @@ | |||
| name: sdd-plus-superpowers | |||
There was a problem hiding this comment.
Normalize file line endings to LF (\n).
Line 1 indicates CRLF/newline mismatch (yamllint: new-lines), which can fail lint checks.
🧰 Tools
🪛 YAMLlint (1.38.0)
[error] 1-1: wrong new line character: expected \n
(new-lines)
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.
In `@schemas/sdd-plus-superpowers/schema.yaml` at line 1, Normalize the schema
file's line endings to LF by converting the file that contains "name:
sdd-plus-superpowers" to use Unix line endings (LF) instead of CRLF; update the
file's line endings (or add a .gitattributes entry for YAML files to enforce
eol=lf) and re-save/commit the file so yamllint no longer reports "new-lines"
errors.
| ``` | ||
| <貼上 openspec validate --all 的輸出摘要> | ||
| ``` |
There was a problem hiding this comment.
Add a language identifier to the fenced code block.
Line 19 opens a fenced block without language, which triggers MD040 and weakens markdown tooling/rendering consistency.
Suggested patch
-```
+```text
<貼上 openspec validate --all 的輸出摘要></details>
<details>
<summary>🤖 Prompt for AI Agents</summary>
Verify each finding against the current code and only fix it if needed.
In @schemas/sdd-plus-superpowers/templates/verify.md around lines 19 - 21, The
fenced code block in verify.md that contains "<貼上 openspec validate --all
的輸出摘要>" is missing a language identifier (causing MD040); update the opening
fence from totext so the block reads as a text/code block and tools
render/lint it consistently, leaving the contained output unchanged.
</details>
<!-- fingerprinting:phantom:triton:hawk:01f04040-7abb-42d5-acec-c15926dfdd97 -->
<!-- This is an auto-generated comment by CodeRabbit -->
Context
This PR addresses #780 — the request to distribute OpenSpec as a Superpowers skill pack so that both frameworks can coexist without manual coordination.
In my comment on that issue I suggested that the cleanest path forward is not packaging one inside the other, but using OpenSpec's own project-level schema mechanism to wire Superpowers skills into the artifact lifecycle. I shared an early fork-based draft at that time:
This PR contributes the refined, upstream-ready version of that schema, with several corrections and additions made after real-world use.
Why a custom schema (instead of a skill pack)
Distributing OpenSpec as a Superpowers skill pack would require maintaining
/opsx:*commands in two places, and would blur the line between OpenSpec's CLI (which enforces artifact structure) and Superpowers' skill system (which is prompt-only). A custom schema is strictly better because:schemas/,--schema <name>at change creation, native validation).instruction:prompt layer.openspec schemas, which is exactly the discovery mechanism [Feature Request] Distribute OpenSpec as a Superpowers (obra/superpowers) skill pack #780 asks for.What this schema does
sdd-plus-superpowersextendsspec-drivenwith:superpowers:brainstorming, with output redirected into the change directory so both systems share a single source of truth instead of writing todocs/superpowers/....tasks.md(coarse checkboxes), aplan.mdartifact invokessuperpowers:writing-plansto decompose work into 2-5 minute TDD steps.using-git-worktrees→subagent-driven-development(with transitive TDD + code-review) →openspec-verify-change→finishing-a-development-branch.Artifact DAG
Two things worth flagging:
designis an optional leaf. Brainstorming may pre-filldesign.md, buttasks.requires: [specs]only — matching OpenSpec conventions that design docs exist only for non-trivial technical decisions.verify.requires: [plan]is structural. The instruction explicitly states verify MUST run on a completed implementation. The DAG edge exists soopenspec statuscan surface verification progress; the timing is intentional.Apply-phase integration
The 2a/2b split follows Superpowers' own guidance —
executing-plans/SKILL.mdstates "If subagents are available, usesuperpowers:subagent-driven-developmentinstead of this skill." On Claude Code, 2a is always the right path; 2b is documented only for constrained runtimes, with an explicit note that transitive TDD and code-review do not carry over under 2b (the author must invoke them manually).Changes since the draft linked in #780 (commit 6449135)
Reviewers who saw the original fork version will notice the following refinements:
verifyartifact +templates/verify.md— the original draft relied on a separate slash command; this version formalizes verification as an artifact soopenspec statuscan track it andopenspec validatecan check its structure.designdemoted to optional — originallytasks.requires: [specs, design]. Experience showeddesign.mdwas frequently empty for small changes, causing false incomplete-state signals. Nowtasks.requires: [specs]only.subagent-driven-development. This version documents the fallback and explicitly lists transitive skill activation for readability.proposal.md— Why-section character limits (50-1000), From/To format for behavioral changes.spec.md— MODIFIED / REMOVED / RENAMED delta sections with archive-time apply order notes.brainstorm.md— Alternatives Considered section (the original had only "Agreed Approach").INTEGRATION.md— onboarding reference covering integration nature, skill touchpoints, artifact DAG, full change lifecycle, CLI cheat sheet, and the five design decisions behind the schema. Intended for teams adopting this schema in their own repos.Compatibility
--schema sdd-plus-superpowersat/opsx:newtime.Testing
openspec validate --all --jsonpasses for sample changes authored under this schema./opsx:new --schema sdd-plus-superpowers→/opsx:continuethrough all 6 planning artifacts →/opsx:apply→/opsx:verify→/opsx:archive, producing a clean archived change with synced delta specs.Notes for reviewers
core/, CLI commands, or thespec-drivenschema.INTEGRATION.md§7 is deliberately a snapshot template (placeholders), not project-specific content — each adopting repo fills in its own capability list, CLI versions, and plugin versions.INTEGRATION.mdcan be moved todocs/instead of sitting alongside the schema — happy to relocate based on reviewer preference.Related
JiangWay/OpenSpec@6449135/schemas/sdd-plus-superpowersSummary by CodeRabbit
New Features
sdd-plus-superpowersworkflow schema enabling integrated change lifecycle management across brainstorming, proposals, design, specifications, tasks, planning, and verification stages.Documentation