Skip to content

Commit 97272ca

Browse files
RbBtSn0wclaude
andauthored
Refocus Superb boundaries and align bridge workflows (#20)
* docs: unify superb path contract * feat: add specification and requirements checklists for refocusing superb boundaries * feat: enhance specification for Superb boundaries with detailed task validation and lifecycle adjustments * feat: implement comprehensive contracts and validation for refocused Superb boundaries * feat: add implementation tasks for refocusing Superb as a bounded Spec Kit extension * feat: update implementation plan and tasks for refocusing Superb boundaries with new tests and documentation adjustments * Refactor and enhance the Superb workflow and command contracts - Introduced a new WORKFLOW.md to define the Superb workflow contract, clarifying the responsibilities and routing of commands. - Added implementation-gate.md to establish a mandatory pre-implementation gate that reports test-first readiness. - Created multiple test scripts to validate command boundaries, lifecycle routing, capability contracts, and workflow contracts. - Updated test-review-regressions.sh to streamline Python interpreter detection and improve readability. - Removed deprecated commands and references from various scripts and documentation to ensure clarity and maintainability. - Enhanced the test-superb-path-contract.sh to dynamically determine expected feature directories based on the current branch. - Ensured that the memorylint extension adheres to independence contracts and does not reference removed lifecycle helpers. * feat: refine Superb boundaries with updated task classifications, enhanced documentation, and removal of legacy dependencies * feat: streamline superb path contract tests by removing deprecated checks and simplifying assertions * fix: replace rg with grep for improved path checks in superb path contract tests * fix(superpowers-bridge): use scoped npm package @rbbtsn0w/adg for install commands The unscoped npm package "adg" was unpublished in 2017; npx resolved to that dead package instead of the actual scoped package, failing CI's new test-e2e-installation.sh with ENOVERSIONS. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com> * fix(ci): provide uvx for spec-kit install test test-spec-kit-012-install.sh hard-requires uvx, which ubuntu-latest runners lack; install uv via astral-sh/setup-uv so the integration test runs in CI, and skip gracefully when uvx is absent locally. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com> * fix(tests): add python3 presence check to test-review-regressions Restore the canonical find_python3 helper (as used in test-catalog.sh) so a missing interpreter yields an actionable prerequisite error instead of a generic "python3: command not found". Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com> --------- Co-authored-by: Claude Sonnet 5 <noreply@anthropic.com>
1 parent 0e14185 commit 97272ca

64 files changed

Lines changed: 2299 additions & 5169 deletions

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.github/workflows/ci.yml

Lines changed: 13 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -17,14 +17,25 @@ jobs:
1717
- name: Checkout repository
1818
uses: actions/checkout@v4
1919

20+
- name: Install uv
21+
uses: astral-sh/setup-uv@v8.2.0
22+
2023
- name: Run shell regression tests
2124
shell: bash
2225
run: |
2326
bash tests/test-review-regressions.sh
2427
bash tests/test-release-workflow.sh
2528
bash tests/test-catalog.sh
26-
bash superpowers-bridge/tests/test-status-sync.sh
27-
bash superpowers-bridge/tests/test-archive-evidence.sh
29+
bash tests/test-superb-path-contract.sh
30+
bash superpowers-bridge/tests/test-capability-contract.sh
31+
bash superpowers-bridge/tests/test-lifecycle-routing.sh
32+
bash superpowers-bridge/tests/test-implementation-gate.sh
33+
bash superpowers-bridge/tests/test-command-boundaries.sh
34+
bash superpowers-bridge/tests/test-workflow-contract.sh
35+
bash superpowers-bridge/tests/test-install-guidance.sh
36+
bash superpowers-bridge/tests/test-resolve-skill.sh
37+
bash superpowers-bridge/tests/test-e2e-installation.sh
38+
bash superpowers-bridge/tests/test-spec-kit-012-install.sh
2839
bash universal-bridge/tests/test-pre-commit.sh
2940
bash tests/verify-feasibility.sh
3041
bash memorylint/tests/test-memorylint-regressions.sh
@@ -33,16 +44,3 @@ jobs:
3344
bash memorylint/tests/test-workspace-audit.sh
3445
bash memorylint/tests/test-apply-workflow.sh
3546
bash memorylint/tests/test-load-agents-proof.sh
36-
37-
powershell-bridge-tests:
38-
name: powershell-bridge-tests
39-
runs-on: windows-latest
40-
steps:
41-
- name: Checkout repository
42-
uses: actions/checkout@v4
43-
44-
- name: Run PowerShell bridge tests
45-
shell: pwsh
46-
run: |
47-
pwsh -File superpowers-bridge/tests/test-status-sync.ps1
48-
pwsh -File superpowers-bridge/tests/test-archive-evidence.ps1

AGENTS.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,9 @@
1717
- Command names must follow `speckit.{extension-id}.{command-name}`.
1818
- Every command markdown file under `commands/` must include the `$ARGUMENTS` context block.
1919
- If a command depends on scripts, declare them in Markdown frontmatter under `scripts:` instead of relying on undocumented side effects.
20+
- Use `scripts:` frontmatter with `../../scripts/...` only for Spec Kit core shared helpers that are expected to rewrite to `.specify/scripts/...` at registration time.
21+
- For extension-owned scripts, templates, configs, or other runtime assets, reference the installed extension path explicitly as `.specify/extensions/<extension-id>/...`; do not rely on repo-relative source paths after installation.
22+
- Do not use `{SCRIPT}` as a directory anchor to discover sibling helpers. `{SCRIPT}` is only the resolved frontmatter command placeholder, not an extension-root locator.
2023
- Hook `command:` values must match an entry declared under `provides.commands` exactly.
2124
- Prefer extension-local config templates such as `*-config.template.yml` and declare them under `provides.config` instead of hardcoding machine-local paths.
2225
- Extensions in this repo must be additive. Do not directly edit `.specify/scripts/` or `.specify/templates/` from an extension implementation.

README.md

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,9 @@
22

33
Evidence-first extensions for [Spec Kit](https://github.com/github/spec-kit) workflows.
44

5-
The current wedge is trustable AI-agent completion: when an agent says an implementation is complete, the workflow should have fresh tests, requirement coverage, and durable evidence to prove it. Broader AI governance and cross-tool portability are roadmap items, not the first product promise.
5+
The current wedge is focused lifecycle reinforcement: selected disciplines add
6+
specification quality, test-first readiness, debugging, review, and branch
7+
handoff without creating a second Spec Kit workflow.
68

79
## Extensions
810

@@ -61,7 +63,7 @@ specify extension add --dev ./superpowers-bridge
6163

6264
## Product Direction
6365

64-
- **Now:** evidence-based completion gates, status synchronization, and requirement drift review for Spec Kit users.
66+
- **Now:** focused specification refinement, test-first readiness, debugging, review, and branch handoff for Spec Kit users.
6567
- **Next:** MemoryLint semantic audits for long-lived agent instructions.
6668
- **Later:** Universal Bridge portability once the Spec Kit loop proves useful in real repositories.
6769

catalog.json

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -24,8 +24,8 @@
2424
]
2525
},
2626
"provides": {
27-
"commands": 10,
28-
"hooks": 6
27+
"commands": 7,
28+
"hooks": 2
2929
},
3030
"tags": [
3131
"methodology",
@@ -34,7 +34,7 @@
3434
"workflow",
3535
"superpowers",
3636
"brainstorming",
37-
"verification",
37+
"readiness",
3838
"debugging",
3939
"branch-management"
4040
],
Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
# Specification Quality Checklist: Refocus Superb Boundaries
2+
3+
**Purpose**: Validate specification completeness and quality before proceeding to planning
4+
**Created**: 2026-07-02
5+
**Feature**: [spec.md](../spec.md)
6+
7+
## Content Quality
8+
9+
- [x] No implementation details (languages, frameworks, APIs)
10+
- [x] Focused on user value and business needs
11+
- [x] Written for non-technical stakeholders
12+
- [x] All mandatory sections completed
13+
14+
## Requirement Completeness
15+
16+
- [x] No [NEEDS CLARIFICATION] markers remain
17+
- [x] Requirements are testable and unambiguous
18+
- [x] Success criteria are measurable
19+
- [x] Success criteria are technology-agnostic (no implementation details)
20+
- [x] All acceptance scenarios are defined
21+
- [x] Edge cases are identified
22+
- [x] Scope is clearly bounded
23+
- [x] Dependencies and assumptions identified
24+
25+
## Feature Readiness
26+
27+
- [x] All functional requirements have clear acceptance criteria
28+
- [x] User scenarios cover primary flows
29+
- [x] Feature meets measurable outcomes defined in Success Criteria
30+
- [x] No implementation details leak into specification
31+
32+
## Notes
33+
34+
- Validation passed on 2026-07-02 with no unresolved clarification markers.
35+
- MemoryLint is explicitly excluded from implementation scope and retained as an independent extension.
Lines changed: 64 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,64 @@
1+
# Superb Capability Contract
2+
3+
## Public Command Surface
4+
5+
The installed `superb` extension MUST expose exactly these commands:
6+
7+
1. `speckit.superb.check`
8+
2. `speckit.superb.brainstorm`
9+
3. `speckit.superb.implementation-gate`
10+
4. `speckit.superb.critique`
11+
5. `speckit.superb.debug`
12+
6. `speckit.superb.respond`
13+
7. `speckit.superb.finish`
14+
15+
No alias or compatibility command may preserve a removed lifecycle surface.
16+
17+
## Hook Surface
18+
19+
| Stage | Command | Optional | Responsibility |
20+
|---|---|---:|---|
21+
| `after_specify` | `speckit.superb.brainstorm` | true | Offer a bounded specification-quality enhancement without taking ownership of planning. |
22+
| `before_implement` | `speckit.superb.implementation-gate` | false | Check implementation readiness and TDD availability without executing or scheduling tasks. |
23+
24+
No Superb hook may run at `after_tasks`, `after_implement`, `before_converge`, or `after_converge`.
25+
26+
## Skill Surface
27+
28+
The bridge MUST discover or install exactly these logical Superpowers skills:
29+
30+
1. `brainstorming`
31+
2. `test-driven-development`
32+
3. `systematic-debugging`
33+
4. `receiving-code-review`
34+
5. `finishing-a-development-branch`
35+
36+
Missing skills MUST produce bounded native guidance or an explicit installation action. Missing skills MUST NOT activate an additional orchestration path.
37+
38+
## Forbidden Active Surface
39+
40+
The installed package MUST NOT expose or invoke:
41+
42+
- Commands: `controller`, `review`, `verify`, or `plan-gate`.
43+
- Hooks: `after_tasks`, `after_implement`, `before_converge`, or `after_converge`.
44+
- Skills: `verification-before-completion`, `writing-plans`, `executing-plans`, `subagent-driven-development`, `requesting-code-review`, or `dispatching-parallel-agents`.
45+
- Runtime helpers that synchronize spec status, archive evidence, own task completion, dispatch agents, or persist execution state.
46+
47+
Historical changelog entries may name removed surfaces, but active manifests, commands, scripts, config, tests, and installation artifacts may not depend on them.
48+
49+
## Package Invariants
50+
51+
- `extension.yml` remains valid for `schema_version: "1.0"`.
52+
- `extension.id` remains `superb`.
53+
- `extension.version` remains the latest published version until the release workflow publishes a new version.
54+
- All runtime assets use installed extension paths under `.specify/extensions/superb/`.
55+
- Superb owns no lifecycle status, task store, execution store, completion store, or convergence report.
56+
- MemoryLint manifests, commands, hooks, scripts, configuration, and behavior remain unchanged.
57+
58+
## Compatibility Evidence
59+
60+
Acceptance requires both source-tree and installed-package evidence:
61+
62+
- Source validation proves the exact command, hook, skill, and forbidden-surface sets.
63+
- Installation validation uses a pinned Spec Kit `0.12.4` environment and inspects the registered extension.
64+
- Compatibility assertions test durable Spec Kit contracts and observable installed behavior, not copied internal skill prose.
Lines changed: 57 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,57 @@
1+
# Superb Command Boundaries
2+
3+
## `speckit.superb.check`
4+
5+
- Reads: installed extension metadata, Superb config, and availability of the five contracted skills.
6+
- Writes: nothing unless the user explicitly accepts a skill installation action.
7+
- Reports: five-skill readiness, two-hook registration, and availability of the four standalone commands.
8+
- Must not: inspect or install unrelated plugins, mutate feature artifacts, or create lifecycle state.
9+
10+
## `speckit.superb.brainstorm`
11+
12+
- Trigger: optional `after_specify` hook or explicit invocation.
13+
- Reads: the current feature specification, relevant project context, and the `brainstorming` skill when available.
14+
- Writes: only user-approved improvements to the current specification.
15+
- Fallback: safely skip or provide bounded native questions when the skill is unavailable.
16+
- Must not: create plans or tasks, change branches, select an execution mode, update status, or invoke `writing-plans`.
17+
18+
## `speckit.superb.implementation-gate`
19+
20+
- Trigger: mandatory `before_implement` hook or explicit invocation.
21+
- Reads: the current specification, plan, tasks, and availability of `test-driven-development`.
22+
- Writes: no feature artifacts and no runtime state.
23+
- Reports: implementation readiness, missing prerequisites, TDD guidance availability, and behavior-changing tasks without explicit test-first readiness.
24+
- Must not: inspect or report parallel markers, ordering, shared-file constraints, or any other task-scheduling metadata.
25+
- Fallback: provide the minimum native TDD gate when the Superpowers skill is unavailable.
26+
- Must not: select single-agent or multi-agent modes, form batches, dispatch agents, execute tasks, edit task checkboxes, commit changes, or persist status.
27+
28+
## `speckit.superb.critique`
29+
30+
- Trigger: explicit invocation only.
31+
- Reads: the supplied diff or review scope and relevant requirements.
32+
- Writes: no code or feature artifacts.
33+
- Reports: evidence-backed findings ordered by severity, with artifact-routing guidance when requirements are wrong or incomplete.
34+
- Must not: fix findings, create tasks, declare completion, or replace Spec Kit analysis and convergence.
35+
36+
## `speckit.superb.debug`
37+
38+
- Trigger: explicit invocation for a current reproducible failure.
39+
- Reads: the failing task, evidence, focused tests, and `systematic-debugging` when available.
40+
- Writes: a focused failing test and minimal fix when the user requested implementation.
41+
- Must not: dispatch parallel agents, update lifecycle status, modify unrelated tasks, or advance the Spec Kit stage automatically.
42+
43+
## `speckit.superb.respond`
44+
45+
- Trigger: explicit invocation with supplied review findings.
46+
- Reads: the findings, affected requirements, code, and `receiving-code-review` when available.
47+
- Writes: only accepted, in-scope fixes.
48+
- Routing rule: findings that change specification, planning, or task meaning return to `speckit-clarify`, `speckit-plan`, or `speckit-tasks` before code mutation.
49+
- Must not: invent review findings, silently broaden scope, or mark the feature complete.
50+
51+
## `speckit.superb.finish`
52+
53+
- Trigger: explicit invocation after Spec Kit convergence and required checks.
54+
- Reads: fresh verification evidence, branch state, workspace ownership, and `finishing-a-development-branch` when available.
55+
- Writes: only the git or pull-request action explicitly selected by the user.
56+
- Must preserve: unrelated workspaces and uncommitted changes not owned by the current feature.
57+
- Must not: run a second convergence workflow, write Superb status, archive evidence, or choose a destructive git action implicitly.
Lines changed: 97 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,97 @@
1+
# Data Model: Refocus Superb Boundaries
2+
3+
**Feature**: `004-refocus-superb-boundaries` | **Date**: 2026-07-03
4+
5+
This feature has no application persistence model. Its entities are declarative
6+
extension contracts represented in YAML, Markdown, configuration, and tests.
7+
8+
## CapabilityContract
9+
10+
| Field | Type | Validation |
11+
|---|---|---|
12+
| `commands` | ordered set of `CommandContract` | Exactly seven unique command names |
13+
| `hooks` | ordered set of `HookBinding` | Exactly two unique lifecycle keys |
14+
| `skills` | ordered set of `SkillContract` | Exactly five unique skill names |
15+
| `statuses` | set | Must be empty |
16+
| `task_stores` | set | Must be empty |
17+
| `execution_stores` | set | Must be empty |
18+
| `completion_stores` | set | Must be empty |
19+
20+
Identity is the `superb` extension namespace plus the installed extension
21+
version. Counts must agree across manifest, configuration, installer,
22+
diagnostics, documentation, and tests.
23+
24+
## CommandContract
25+
26+
| Field | Type | Notes |
27+
|---|---|---|
28+
| `name` | command identifier | Must use `speckit.superb.*` |
29+
| `kind` | `hook` or `standalone` | Hook commands remain manually invocable |
30+
| `lifecycle_boundary` | hook key or `standalone` | Exactly one accountable boundary |
31+
| `user_outcome` | string | Lifecycle benefit, not internal terminology |
32+
| `reads` | set | Minimum necessary artifacts/context |
33+
| `writes` | set | Explicit allowlist |
34+
| `forbidden` | set | State, orchestration, or ownership violations |
35+
| `skill` | optional `SkillContract` | At most one primary upstream discipline |
36+
| `fallback` | enum | `native_minimum`, `unavailable`, or `not_applicable` |
37+
38+
### Command Identities
39+
40+
1. `speckit.superb.check`
41+
2. `speckit.superb.brainstorm`
42+
3. `speckit.superb.implementation-gate`
43+
4. `speckit.superb.critique`
44+
5. `speckit.superb.debug`
45+
6. `speckit.superb.respond`
46+
7. `speckit.superb.finish`
47+
48+
## HookBinding
49+
50+
| Hook | Command | Policy | Mutation |
51+
|---|---|---|---|
52+
| `after_specify` | `speckit.superb.brainstorm` | Optional | User-approved `spec.md` refinement only |
53+
| `before_implement` | `speckit.superb.implementation-gate` | Mandatory | Read-only |
54+
55+
No other Superb hook is valid. In particular, `after_tasks`, `after_implement`,
56+
`before_converge`, and `after_converge` must be absent.
57+
58+
## SkillContract
59+
60+
| Name | Consumer | Availability behavior | Stable dependency |
61+
|---|---|---|---|
62+
| `brainstorming` | `brainstorm` | Optional command/hook unavailable or skipped safely | Design alternatives, scope, approval |
63+
| `test-driven-development` | `implementation-gate` | Optional upstream enhancement; bridge-native minimum TDD readiness when absent | RED before production change |
64+
| `systematic-debugging` | `debug` | Standalone unavailable with install guidance | Evidence-led root-cause investigation |
65+
| `receiving-code-review` | `respond` | Standalone unavailable with install guidance | Technical verification of feedback |
66+
| `finishing-a-development-branch` | `finish` | Standalone unavailable with install guidance | Fresh tests and explicit branch choice |
67+
68+
Internal headings, prompt-template filenames, named agents, and exact workflow
69+
steps are not fields in this contract.
70+
71+
## ArtifactRoute
72+
73+
| Defect class | Owning command | Superb behavior |
74+
|---|---|---|
75+
| Requirement ambiguity | `speckit.clarify` | Report and route |
76+
| Plan/architecture mismatch | `speckit.plan` | Report and route |
77+
| Missing or malformed tasks | `speckit.tasks` | Report and route |
78+
| Cross-artifact inconsistency | `speckit.analyze`, then earliest owner | Report and route |
79+
| Implementation execution | `speckit.implement` | Gate readiness only |
80+
| Delivered-code gap | `speckit.converge` | Route only |
81+
| Feedback changes requirement/plan/task meaning | Earliest affected owner | Respond stops direct code mutation |
82+
83+
## MigrationRemoval
84+
85+
Each removed surface has one terminal transition: `active -> removed`.
86+
87+
| Surface | Replacement/route |
88+
|---|---|
89+
| `speckit.superb.controller` | `speckit.superb.implementation-gate` |
90+
| `speckit.superb.review` | `speckit.tasks` and `speckit.analyze` |
91+
| `speckit.superb.verify` | `speckit.implement` validation and `speckit.converge` |
92+
| `plan-gate.md` | Native `speckit.plan` |
93+
| Superb status synchronization | No replacement state machine |
94+
| Temporary evidence archive | Owning command's fresh in-session evidence |
95+
96+
Removed files, config keys, docs, and tests must not remain in the installed
97+
payload. Migration guidance may name them only as historical removed surfaces.

0 commit comments

Comments
 (0)