sdtk-spec-kit 0.3.12 → 0.3.13
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/assets/manifest/toolkit-bundle.manifest.json +77 -37
- package/assets/manifest/toolkit-bundle.sha256.txt +26 -18
- package/assets/toolkit/toolkit/AGENTS.md +1 -1
- package/assets/toolkit/toolkit/README.md +1 -1
- package/assets/toolkit/toolkit/SDTK_TOOLKIT.md +1 -1
- package/assets/toolkit/toolkit/scripts/agents/run-claude-task.ps1 +52 -0
- package/assets/toolkit/toolkit/scripts/agents/run-codex-task.ps1 +44 -0
- package/assets/toolkit/toolkit/scripts/generate-code-handoff.ps1 +308 -246
- package/assets/toolkit/toolkit/scripts/install-claude-skills.ps1 +1 -1
- package/assets/toolkit/toolkit/skills/sdtk-api-design-spec/scripts/generate_api_design_detail.py +1 -1
- package/assets/toolkit/toolkit/skills/sdtk-ba/SKILL.md +10 -0
- package/assets/toolkit/toolkit/skills/sdtk-dev/SKILL.md +28 -4
- package/assets/toolkit/toolkit/skills/sdtk-mailbox-dispatch/SKILL.md +70 -0
- package/assets/toolkit/toolkit/skills/sdtk-orchestrator/SKILL.md +8 -0
- package/assets/toolkit/toolkit/skills/sdtk-pm/SKILL.md +28 -0
- package/assets/toolkit/toolkit/skills/skills.catalog.yaml +25 -0
- package/assets/toolkit/toolkit/skills-claude/ba/SKILL.md +9 -0
- package/assets/toolkit/toolkit/skills-claude/dev/SKILL.md +58 -57
- package/assets/toolkit/toolkit/skills-claude/mailbox-dispatch/SKILL.md +70 -0
- package/assets/toolkit/toolkit/skills-claude/orchestrator/SKILL.md +7 -0
- package/assets/toolkit/toolkit/skills-claude/pm/SKILL.md +29 -2
- package/assets/toolkit/toolkit/templates/docs/dev/FEATURE_IMPL_PLAN_TEMPLATE.md +13 -2
- package/assets/toolkit/toolkit/templates/docs/dev/OPS_HANDOFF_CREATION_RULES.md +369 -0
- package/assets/toolkit/toolkit/templates/docs/product/CONDENSED_UPSTREAM_INPUT_TEMPLATE.md +136 -0
- package/assets/toolkit/toolkit/templates/handoffs/DEV_TO_SDTK_CODE.md +34 -29
- package/assets/toolkit/toolkit/templates/handoffs/PM_TO_BA.md +4 -0
- package/assets/toolkit/toolkit/templates/mailbox/AGENT_REPORT_TEMPLATE.md +46 -0
- package/assets/toolkit/toolkit/templates/mailbox/AGENT_TASK_TEMPLATE.md +59 -0
- package/package.json +48 -48
|
@@ -12,6 +12,7 @@ description: Developer planning workflow for SDTK-SPEC. Use when you need to con
|
|
|
12
12
|
## Outputs
|
|
13
13
|
- `docs/dev/FEATURE_IMPL_PLAN_[FEATURE_KEY].md`
|
|
14
14
|
- `docs/dev/CODE_HANDOFF_[FEATURE_KEY].json`
|
|
15
|
+
- `docs/dev/OPS_HANDOFF_[FEATURE_KEY].json` after CODE phase completion and human-approved readiness review
|
|
15
16
|
|
|
16
17
|
## Legacy Prompt Templates
|
|
17
18
|
- `./prompts/implementer.md`
|
|
@@ -28,10 +29,10 @@ Use them only when the user explicitly requests a manual legacy review or delega
|
|
|
28
29
|
3. Write or refine `FEATURE_IMPL_PLAN_*`:
|
|
29
30
|
- issue summary and scope
|
|
30
31
|
- explicit non-goals
|
|
31
|
-
- implementation slices
|
|
32
|
+
- implementation slices in the recommended downstream build order
|
|
32
33
|
- required refs
|
|
33
34
|
- optional refs
|
|
34
|
-
- issue-specific test obligations using real executable commands
|
|
35
|
+
- issue-specific test obligations using implementation-ready acceptance mapping statements and real executable commands
|
|
35
36
|
- blockers and open questions
|
|
36
37
|
4. If anything is unclear: record OQ-xx in `FEATURE_IMPL_PLAN` and escalate to `@pm` for a decision.
|
|
37
38
|
5. Decide readiness:
|
|
@@ -41,10 +42,33 @@ Use them only when the user explicitly requests a manual legacy review or delega
|
|
|
41
42
|
- Canonical writer rule: the machine-readable JSON is generator-owned; do not hand-author or patch the JSON shape manually.
|
|
42
43
|
- If an existing `CODE_HANDOFF_*` file is non-canonical, regenerate it with the script and `-Force` instead of editing keys by hand.
|
|
43
44
|
- Use the script-owned snake_case contract only. Do not emit legacy camelCase keys such as `featureKey`, `requiredRefs`, `optionalRefs`, `openBlockers`, `implementationSlices`, `testObligations`, or `suggestedNextCommand`.
|
|
45
|
+
- Current canonical emission is schema `0.2`; the generator auto-derives `impact_map` from the current handoff refs and may include optional `recovery_notes`.
|
|
44
46
|
7. Mirror the same readiness decision in the final `SDTK-CODE Handoff` section of `FEATURE_IMPL_PLAN`.
|
|
45
47
|
- Do not copy placeholder `UPDATE_ME` commands from `sdtk-spec.config.json` into the handoff plan as if they were executable proof.
|
|
46
|
-
8.
|
|
47
|
-
|
|
48
|
+
8. After CODE_HANDOFF is generated and the feature has been implemented and verified by SDTK-CODE,
|
|
49
|
+
author `docs/dev/OPS_HANDOFF_[FEATURE_KEY].json` for operational readiness handoff.
|
|
50
|
+
- Creation rules: `toolkit/templates/docs/dev/OPS_HANDOFF_CREATION_RULES.md`
|
|
51
|
+
- Schema version must be `"0.1"`. Required top-level fields: `schema_version`, `feature_key`,
|
|
52
|
+
`ops_handoff_status`, `source_handoff_ref`, `non_claims`, `deploy_starter`,
|
|
53
|
+
`env_expectations`, `health_check_baseline`, `monitoring_baseline`, `rollback_starter`,
|
|
54
|
+
`human_gates`. Optional: `open_questions`.
|
|
55
|
+
- The `non_claims` array must include the six minimum entries defined in the creation rules.
|
|
56
|
+
The handoff does not automate deployment, does not configure CI/CD pipelines, does not
|
|
57
|
+
configure a production monitoring platform, and does not provide automated rollback.
|
|
58
|
+
- Gate H5 must be present in `human_gates`. A human controller must review and approve the
|
|
59
|
+
OPS_HANDOFF artifact before any deployment action proceeds. This gate is not optional and
|
|
60
|
+
cannot be satisfied by automated review alone.
|
|
61
|
+
- Set `ops_handoff_status` to `"READY_FOR_OPS_REVIEW"` only after all required fields are
|
|
62
|
+
complete, the authoring checklist in the creation rules passes, and all blocking
|
|
63
|
+
open_questions are resolved. Use `"BLOCKED_FOR_OPS_REVIEW"` when any blocking question
|
|
64
|
+
remains unresolved.
|
|
65
|
+
- Do not hand-author fields derived from CODE_HANDOFF without verifying the source artifact.
|
|
66
|
+
Read `source_handoff_ref` before completing `deploy_starter` and `env_expectations`.
|
|
67
|
+
- This is starter-level guidance for a bounded small-app internal deployment only.
|
|
68
|
+
Do not claim production automation, cloud-platform management, or CI/CD pipeline
|
|
69
|
+
configuration in any field of the OPS_HANDOFF artifact.
|
|
70
|
+
9. Update `SHARED_PLANNING.md` + `QUALITY_CHECKLIST.md` Phase 4 to show planning/handoff completion status.
|
|
71
|
+
10. Handoff:
|
|
48
72
|
- if ready: suggest the exact `sdtk-code start --feature-key <KEY> --lane <feature|bugfix> --project-path .` command
|
|
49
73
|
- if blocked: list blockers and keep the work in `/dev`
|
|
50
74
|
|
|
@@ -0,0 +1,70 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: sdtk-mailbox-dispatch
|
|
3
|
+
description: Controller-owned mailbox delegation for SDTK-SPEC. Use when PM or Orchestrator needs to assign a bounded phase to Claude or Codex, preserve exact include/exclude boundaries, review raw reports against formal artifacts, and run a mandatory post-issue mailbox retrospective.
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
# SDTK Mailbox Dispatch
|
|
7
|
+
|
|
8
|
+
Use this skill only for controller-owned delegation. It is the shipped SDTK-SPEC mailbox flow for bounded PM or Orchestrator dispatch, not a generic autonomous worker platform.
|
|
9
|
+
|
|
10
|
+
## Critical Constraints
|
|
11
|
+
- I do not use mailbox dispatch for broad exploratory planning when the controller already has enough local context to plan safely.
|
|
12
|
+
- I do not mix transient runtime files under `governance/ai/agent-mailbox/runtime/` into feature commit boundaries.
|
|
13
|
+
- I do not widen include/exclude boundaries, fallback rules, or verification commands without an explicit controller decision.
|
|
14
|
+
- I do not leak internal backlog IDs into runtime-facing docs, templates, samples, or public guidance.
|
|
15
|
+
|
|
16
|
+
## Use When
|
|
17
|
+
- one bounded issue phase should be delegated through the mailbox runtime
|
|
18
|
+
- runtime choice between Claude and Codex matters
|
|
19
|
+
- the task needs exact include/exclude boundaries and a stable review packet
|
|
20
|
+
- the phase is implementation, review, QA, or controller acceptance
|
|
21
|
+
- you want the closeout loop to absorb new mailbox lessons automatically
|
|
22
|
+
|
|
23
|
+
## Do Not Use
|
|
24
|
+
- broad exploratory planning when the controller already has enough local context
|
|
25
|
+
- unbounded multi-issue orchestration or a generic worker platform
|
|
26
|
+
- tasks that require a direct external-CLI-to-chat-session bridge
|
|
27
|
+
|
|
28
|
+
## Required Inputs
|
|
29
|
+
Read these shipped toolkit surfaces before dispatching or reviewing a run:
|
|
30
|
+
- `toolkit/templates/mailbox/AGENT_TASK_TEMPLATE.md`
|
|
31
|
+
- `toolkit/templates/mailbox/AGENT_REPORT_TEMPLATE.md`
|
|
32
|
+
- `toolkit/scripts/agents/run-claude-task.ps1`
|
|
33
|
+
- `toolkit/scripts/agents/run-codex-task.ps1`
|
|
34
|
+
- current issue spec/plan/review artifacts for the bounded phase
|
|
35
|
+
- current git truth for the included surfaces
|
|
36
|
+
|
|
37
|
+
## Workflow
|
|
38
|
+
1. Decide whether the controller should plan locally first. Default to local planning when the codebase context is already strong.
|
|
39
|
+
2. Choose runtime:
|
|
40
|
+
- Claude for controller spec drafting, wording-heavy review, and SDTK-SPEC shaping
|
|
41
|
+
- Codex for code changes, tests, workflow/harness changes, and verification-heavy implementation
|
|
42
|
+
3. Write the task packet with exact boundary truth, boundary mode, carryover findings, formal artifact write expectation, an explicit runtime-stall budget plus fallback trigger, and a clear closeout mode (`full-issue` or `phase-only`).
|
|
43
|
+
4. Dispatch through the mailbox launcher into `governance/ai/agent-mailbox/runtime/...`.
|
|
44
|
+
5. Review the raw report against git truth and the formal artifact on disk. Prefer the formal artifact when console output is lossy.
|
|
45
|
+
6. Promote only approved code/docs/tests/artifacts into tracked paths.
|
|
46
|
+
7. Run a default post-issue retrospective before the next mailbox-driven issue:
|
|
47
|
+
- update the mailbox contract/spec if a real new lesson appeared
|
|
48
|
+
- otherwise record `no new mailbox lessons` in the closeout summary
|
|
49
|
+
|
|
50
|
+
## Boundary Rules
|
|
51
|
+
- Treat runtime files under `governance/ai/agent-mailbox/runtime/` as transient.
|
|
52
|
+
- Do not mix mailbox runtime dirt into feature commit boundaries.
|
|
53
|
+
- State explicitly whether a batch is `canonical-only` or includes packaged distribution parity.
|
|
54
|
+
- Keep internal backlog IDs out of runtime-facing docs, templates, and public guidance.
|
|
55
|
+
|
|
56
|
+
## Fallback Rules
|
|
57
|
+
- If an external runtime stalls, use a bounded fallback path instead of blocking the issue.
|
|
58
|
+
- For long implementation passes, one bounded external attempt is enough before controller-local or native fallback if the trigger defined in the task packet is reached.
|
|
59
|
+
- If quota or permission prevents the agent from writing the formal artifact, the controller may author it directly, but the artifact must state the fallback reason.
|
|
60
|
+
- QA and controller acceptance may inherit fresh controller verification only when the implementation scope is unchanged and the inheritance is declared explicitly.
|
|
61
|
+
- If the controller fixes a bounded hygiene defect between phases, later mailbox tasks must review current repo truth and treat the resolved defect as fixed instead of repeating stale findings from earlier raw reports.
|
|
62
|
+
|
|
63
|
+
## Default Phase Order
|
|
64
|
+
1. `controller-spec` or `plan`
|
|
65
|
+
2. `implementation`
|
|
66
|
+
3. `controller-dev-review`
|
|
67
|
+
4. `qa-review`
|
|
68
|
+
5. `controller-acceptance`
|
|
69
|
+
6. `commit/push`
|
|
70
|
+
7. `post-issue-retrospective`
|
|
@@ -52,6 +52,13 @@ description: Orchestrate a full 6-phase SDLC multi-agent workflow (PM/BA/ARCH/DE
|
|
|
52
52
|
- `on`: always run `sdtk-test-case-spec` for QA phase (fail fast if required inputs are missing).
|
|
53
53
|
- `off`: skip test-case spec generation unless user explicitly requests it.
|
|
54
54
|
|
|
55
|
+
## Optional: Mailbox Dispatch
|
|
56
|
+
- Use `sdtk-mailbox-dispatch` when one bounded controller-owned phase should be delegated to Claude or Codex.
|
|
57
|
+
- Keep planning local when the controller already has enough repo context.
|
|
58
|
+
- Lock exact include/exclude boundaries, fallback triggers, and verification commands before dispatch.
|
|
59
|
+
- Keep mailbox runtime files transient under `governance/ai/agent-mailbox/runtime/`.
|
|
60
|
+
- Run the default post-issue mailbox retrospective after repo truth is closed and before the next mailbox-driven issue.
|
|
61
|
+
|
|
55
62
|
## Flow Overview
|
|
56
63
|
|
|
57
64
|
```dot
|
|
@@ -93,5 +100,6 @@ If the evidence is incomplete, keep the phase open or mark it blocked instead of
|
|
|
93
100
|
| Hand off a phase based on planned checks instead of executed evidence | Creates false PASS status and weakens downstream gates | Require fresh evidence before marking the phase complete |
|
|
94
101
|
| Mix generation, review, and release decisions in one uncontrolled turn | Makes status tracking ambiguous | Complete one phase handoff at a time and update shared state before moving on |
|
|
95
102
|
| Claim helper-dispatch or skill exposure is universal across every runtime surface | Overstates runtime guarantees and breaks truthful fallback behavior | State the verified surface only and keep the repo-local fallback explicit |
|
|
103
|
+
| Use mailbox dispatch as a generic worker platform or reopen broad planning through it | Wastes controller time and weakens boundary discipline | Keep mailbox delegation bounded, preserve exact boundaries, and prefer local planning when context is already strong |
|
|
96
104
|
| Let a bounded audit issue the final verdict or replace QA/controller review | Breaks authority boundaries and creates ambiguous approval ownership | Keep audits narrow and evidence-cited, then return the findings to QA/controller |
|
|
97
105
|
| Let a rejected batch jump straight to ship or PM closure | Breaks the targeted-fix refresh order and hides unresolved findings | Route rejected batches through the bounded loop `verify -> QA -> controller` before any later phase |
|
|
@@ -24,6 +24,34 @@ description: Product Manager + meta-orchestrator workflow for SDTK-SPEC. Use whe
|
|
|
24
24
|
- After Project Initiation -> `@ba please analyze ...`
|
|
25
25
|
- After PRD/Backlog -> `@arch please design ...`
|
|
26
26
|
|
|
27
|
+
## Optional: Condensed Upstream Input
|
|
28
|
+
|
|
29
|
+
If a basic product brief is provided before PM initiation, a condensed upstream
|
|
30
|
+
input package may be produced first using:
|
|
31
|
+
`toolkit/templates/docs/product/CONDENSED_UPSTREAM_INPUT_TEMPLATE.md`
|
|
32
|
+
|
|
33
|
+
The condensed output must carry the REQUIRES_HUMAN_REVIEW label (Gate H2) and
|
|
34
|
+
must be reviewed before the PM phase proceeds. Do not auto-advance to PM or BA
|
|
35
|
+
without explicit human confirmation. If the brief is outside the bounded domain,
|
|
36
|
+
stop and surface a boundary flag (Gate H1) rather than proceeding.
|
|
37
|
+
|
|
38
|
+
The condensed package is a DRAFT accelerator only. It seeds PM initiation; it
|
|
39
|
+
does not replace PM or BA judgment. Deliver the condensed output as:
|
|
40
|
+
`docs/product/CONDENSED_UPSTREAM_INPUT_[FEATURE_KEY].md`
|
|
41
|
+
|
|
42
|
+
## Optional: Mailbox Delegation
|
|
43
|
+
|
|
44
|
+
Use `sdtk-mailbox-dispatch` when PM needs bounded external-agent help without
|
|
45
|
+
opening a full orchestration platform loop.
|
|
46
|
+
|
|
47
|
+
Rules:
|
|
48
|
+
- keep PM planning local when the controller already has enough context
|
|
49
|
+
- delegate only one bounded phase at a time with exact include/exclude truth
|
|
50
|
+
- prefer Claude for controller-spec, wording-heavy review, and SDTK-SPEC shaping
|
|
51
|
+
- prefer Codex for code, tests, harness, or verification-heavy implementation
|
|
52
|
+
- review the formal artifact on disk before trusting raw console output
|
|
53
|
+
- keep governance/ai/agent-mailbox/runtime/ transient and out of feature commits
|
|
54
|
+
- run the post-issue mailbox retrospective before the next mailbox-driven issue
|
|
27
55
|
## Phase 6 Closure Truth
|
|
28
56
|
- Review the final QA and controller decisions before closing the issue.
|
|
29
57
|
- Treat `SHARED_PLANNING.md`, `QUALITY_CHECKLIST.md`, and `governance/ai/core/IMPROVEMENT_BACKLOG.md` as closure-state surfaces that must stay synchronized.
|
|
@@ -143,6 +143,31 @@ skills:
|
|
|
143
143
|
dependencies: []
|
|
144
144
|
pack: core
|
|
145
145
|
|
|
146
|
+
- name: sdtk-mailbox-dispatch
|
|
147
|
+
phase: orchestration
|
|
148
|
+
role_tag: /mailbox-dispatch
|
|
149
|
+
use_when: Delegate one bounded controller-owned phase to Claude or Codex while preserving exact include/exclude boundaries, formal artifact review, and a default post-issue retrospective.
|
|
150
|
+
primary_inputs:
|
|
151
|
+
- issue spec or plan artifacts
|
|
152
|
+
- toolkit/templates/mailbox/AGENT_TASK_TEMPLATE.md
|
|
153
|
+
- toolkit/templates/mailbox/AGENT_REPORT_TEMPLATE.md
|
|
154
|
+
- current git truth
|
|
155
|
+
primary_outputs:
|
|
156
|
+
- governance/ai/agent-mailbox/runtime/<ISSUE_KEY>/<RUN_ID>/*
|
|
157
|
+
- governance/ai/reviews/shared/*
|
|
158
|
+
hard_gates:
|
|
159
|
+
- Do not use mailbox dispatch for broad exploratory planning when controller context is already strong.
|
|
160
|
+
- Do not mix transient mailbox runtime files into feature commit boundaries.
|
|
161
|
+
- Do not widen boundaries, fallback rules, or verification commands without an explicit controller decision.
|
|
162
|
+
references: []
|
|
163
|
+
prompts: []
|
|
164
|
+
scripts:
|
|
165
|
+
- toolkit/scripts/agents/run-claude-task.ps1
|
|
166
|
+
- toolkit/scripts/agents/run-codex-task.ps1
|
|
167
|
+
runtime_support: [claude, codex]
|
|
168
|
+
dependencies: []
|
|
169
|
+
pack: core
|
|
170
|
+
|
|
146
171
|
- name: sdtk-dev-backend
|
|
147
172
|
phase: dev
|
|
148
173
|
role_tag: /dev-backend
|
|
@@ -33,6 +33,15 @@ If no arguments are provided, read current feature context from SHARED_PLANNING.
|
|
|
33
33
|
## Output
|
|
34
34
|
- `docs/specs/BA_SPEC_[FEATURE_KEY].md`
|
|
35
35
|
|
|
36
|
+
## Optional: Condensed Upstream Input
|
|
37
|
+
|
|
38
|
+
If a condensed upstream input package was produced before PM initiation, read it
|
|
39
|
+
alongside `docs/product/PROJECT_INITIATION_[FEATURE_KEY].md`. The package is at:
|
|
40
|
+
`docs/product/CONDENSED_UPSTREAM_INPUT_[FEATURE_KEY].md`
|
|
41
|
+
|
|
42
|
+
The condensed package is a DRAFT accelerator only. All derived actors, entities,
|
|
43
|
+
rules, and acceptance criteria require human review before adoption.
|
|
44
|
+
|
|
36
45
|
## Process
|
|
37
46
|
1. Read `docs/product/PROJECT_INITIATION_[FEATURE_KEY].md` and any source requirements.
|
|
38
47
|
2. Produce:
|
|
@@ -1,57 +1,58 @@
|
|
|
1
|
-
---
|
|
2
|
-
name: dev
|
|
3
|
-
description: Developer planning workflow for SDTK-SPEC. Use when you need to convert ARCH_DESIGN plus BACKLOG into a scoped implementation plan, readiness decision, and formal SDTK-CODE handoff.
|
|
4
|
-
---
|
|
5
|
-
|
|
6
|
-
## SDTK-SPEC Pipeline Rules (always apply)
|
|
7
|
-
1. Pipeline: PM Initiation -> BA Analysis -> PM Planning -> Architecture Design -> Development Planning + SDTK-CODE Handoff -> QA Validation
|
|
8
|
-
2. After completing phase work: update SHARED_PLANNING.md + QUALITY_CHECKLIST.md
|
|
9
|
-
3. If unclear: log OQ-xx in artifact, escalate to PM (PM asks user if needed)
|
|
10
|
-
4. Traceability: REQ -> BR/UC/AC -> design -> backlog -> FEATURE_IMPL_PLAN -> CODE_HANDOFF -> downstream implementation evidence -> QA
|
|
11
|
-
5. `/dev` stops at planning plus handoff; downstream code execution belongs to SDTK-CODE by default
|
|
12
|
-
6. Do not skip phases. If inputs missing, ask focused questions.
|
|
13
|
-
|
|
14
|
-
## Prerequisites (verify before proceeding)
|
|
15
|
-
Read QUALITY_CHECKLIST.md and verify:
|
|
16
|
-
- Phase 3 ARCH Design gate must show all items [x] Done.
|
|
17
|
-
|
|
18
|
-
If prerequisites are not met: report which gate is missing, suggest user run `/arch` first.
|
|
19
|
-
|
|
20
|
-
## Current Context
|
|
21
|
-
- Config: !`node -e "try{process.stdout.write(require('fs').readFileSync('sdtk-spec.config.json','utf8'))}catch{process.stdout.write('{}')}"`
|
|
22
|
-
- Pipeline: !`node -e "try{process.stdout.write(require('fs').readFileSync('SHARED_PLANNING.md','utf8'))}catch{process.stdout.write('Not initialized')}"`
|
|
23
|
-
- Gates: !`node -e "try{process.stdout.write(require('fs').readFileSync('QUALITY_CHECKLIST.md','utf8'))}catch{process.stdout.write('Not initialized')}"`
|
|
24
|
-
- State: !`node -e "try{process.stdout.write(require('fs').readFileSync('.sdtk/orchestration-state.json','utf8'))}catch{process.stdout.write('{}')}"`
|
|
25
|
-
|
|
26
|
-
## Input
|
|
27
|
-
$ARGUMENTS
|
|
28
|
-
|
|
29
|
-
If no arguments provided, read current feature context from SHARED_PLANNING.md.
|
|
30
|
-
|
|
31
|
-
# SDTK-SPEC DEV (Planning + SDTK-CODE Handoff)
|
|
32
|
-
|
|
33
|
-
## Outputs
|
|
34
|
-
- `docs/dev/FEATURE_IMPL_PLAN_[FEATURE_KEY].md`
|
|
35
|
-
- `docs/dev/CODE_HANDOFF_[FEATURE_KEY].json`
|
|
36
|
-
|
|
37
|
-
## Process
|
|
38
|
-
1. Read `ARCH_DESIGN_*` + backlog.
|
|
39
|
-
2. Read `sdtk-spec.config.json` for project stack + test/lint commands.
|
|
40
|
-
3. Write or refine `FEATURE_IMPL_PLAN_*`:
|
|
41
|
-
- implementation slices
|
|
42
|
-
- required refs
|
|
43
|
-
- optional refs
|
|
44
|
-
- test obligations
|
|
45
|
-
- blockers and OQ items
|
|
46
|
-
4. If anything is unclear: record OQ-xx in `FEATURE_IMPL_PLAN` and escalate to PM (suggest user run `/pm` for a decision if still missing info).
|
|
47
|
-
5. Decide readiness:
|
|
48
|
-
- `READY_FOR_SDTK_CODE`, or
|
|
49
|
-
- `BLOCKED_FOR_SDTK_CODE`
|
|
50
|
-
6. Generate `CODE_HANDOFF_*` with `toolkit/scripts/generate-code-handoff.ps1`.
|
|
51
|
-
- Canonical writer rule: the machine-readable JSON is generator-owned; do not hand-author or patch the JSON shape manually.
|
|
52
|
-
- If an existing `CODE_HANDOFF_*` file is non-canonical, regenerate it with the script and `-Force` instead of editing keys by hand.
|
|
53
|
-
- Use the script-owned snake_case contract only. Do not emit legacy camelCase keys such as `featureKey`, `requiredRefs`, `optionalRefs`, `openBlockers`, `implementationSlices`, `testObligations`, or `suggestedNextCommand`.
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
1
|
+
---
|
|
2
|
+
name: dev
|
|
3
|
+
description: Developer planning workflow for SDTK-SPEC. Use when you need to convert ARCH_DESIGN plus BACKLOG into a scoped implementation plan, readiness decision, and formal SDTK-CODE handoff.
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
## SDTK-SPEC Pipeline Rules (always apply)
|
|
7
|
+
1. Pipeline: PM Initiation -> BA Analysis -> PM Planning -> Architecture Design -> Development Planning + SDTK-CODE Handoff -> QA Validation
|
|
8
|
+
2. After completing phase work: update SHARED_PLANNING.md + QUALITY_CHECKLIST.md
|
|
9
|
+
3. If unclear: log OQ-xx in artifact, escalate to PM (PM asks user if needed)
|
|
10
|
+
4. Traceability: REQ -> BR/UC/AC -> design -> backlog -> FEATURE_IMPL_PLAN -> CODE_HANDOFF -> downstream implementation evidence -> QA
|
|
11
|
+
5. `/dev` stops at planning plus handoff; downstream code execution belongs to SDTK-CODE by default
|
|
12
|
+
6. Do not skip phases. If inputs missing, ask focused questions.
|
|
13
|
+
|
|
14
|
+
## Prerequisites (verify before proceeding)
|
|
15
|
+
Read QUALITY_CHECKLIST.md and verify:
|
|
16
|
+
- Phase 3 ARCH Design gate must show all items [x] Done.
|
|
17
|
+
|
|
18
|
+
If prerequisites are not met: report which gate is missing, suggest user run `/arch` first.
|
|
19
|
+
|
|
20
|
+
## Current Context
|
|
21
|
+
- Config: !`node -e "try{process.stdout.write(require('fs').readFileSync('sdtk-spec.config.json','utf8'))}catch{process.stdout.write('{}')}"`
|
|
22
|
+
- Pipeline: !`node -e "try{process.stdout.write(require('fs').readFileSync('SHARED_PLANNING.md','utf8'))}catch{process.stdout.write('Not initialized')}"`
|
|
23
|
+
- Gates: !`node -e "try{process.stdout.write(require('fs').readFileSync('QUALITY_CHECKLIST.md','utf8'))}catch{process.stdout.write('Not initialized')}"`
|
|
24
|
+
- State: !`node -e "try{process.stdout.write(require('fs').readFileSync('.sdtk/orchestration-state.json','utf8'))}catch{process.stdout.write('{}')}"`
|
|
25
|
+
|
|
26
|
+
## Input
|
|
27
|
+
$ARGUMENTS
|
|
28
|
+
|
|
29
|
+
If no arguments provided, read current feature context from SHARED_PLANNING.md.
|
|
30
|
+
|
|
31
|
+
# SDTK-SPEC DEV (Planning + SDTK-CODE Handoff)
|
|
32
|
+
|
|
33
|
+
## Outputs
|
|
34
|
+
- `docs/dev/FEATURE_IMPL_PLAN_[FEATURE_KEY].md`
|
|
35
|
+
- `docs/dev/CODE_HANDOFF_[FEATURE_KEY].json`
|
|
36
|
+
|
|
37
|
+
## Process
|
|
38
|
+
1. Read `ARCH_DESIGN_*` + backlog.
|
|
39
|
+
2. Read `sdtk-spec.config.json` for project stack + test/lint commands.
|
|
40
|
+
3. Write or refine `FEATURE_IMPL_PLAN_*`:
|
|
41
|
+
- implementation slices in the recommended downstream build order
|
|
42
|
+
- required refs
|
|
43
|
+
- optional refs
|
|
44
|
+
- test obligations written as implementation-ready acceptance mapping statements
|
|
45
|
+
- blockers and OQ items
|
|
46
|
+
4. If anything is unclear: record OQ-xx in `FEATURE_IMPL_PLAN` and escalate to PM (suggest user run `/pm` for a decision if still missing info).
|
|
47
|
+
5. Decide readiness:
|
|
48
|
+
- `READY_FOR_SDTK_CODE`, or
|
|
49
|
+
- `BLOCKED_FOR_SDTK_CODE`
|
|
50
|
+
6. Generate `CODE_HANDOFF_*` with `toolkit/scripts/generate-code-handoff.ps1`.
|
|
51
|
+
- Canonical writer rule: the machine-readable JSON is generator-owned; do not hand-author or patch the JSON shape manually.
|
|
52
|
+
- If an existing `CODE_HANDOFF_*` file is non-canonical, regenerate it with the script and `-Force` instead of editing keys by hand.
|
|
53
|
+
- Use the script-owned snake_case contract only. Do not emit legacy camelCase keys such as `featureKey`, `requiredRefs`, `optionalRefs`, `openBlockers`, `implementationSlices`, `testObligations`, or `suggestedNextCommand`.
|
|
54
|
+
- Current canonical emission is schema `0.2`; the generator auto-derives `impact_map` from the current handoff refs and may include optional `recovery_notes`.
|
|
55
|
+
7. Update `SHARED_PLANNING.md` + `QUALITY_CHECKLIST.md` Phase 4.
|
|
56
|
+
8. If ready, suggest:
|
|
57
|
+
- `sdtk-code start --feature-key <KEY> --lane <feature|bugfix> --project-path .`
|
|
58
|
+
9. Do not claim that `/dev` executed downstream code, build, verify, ship, or QA handoff.
|
|
@@ -0,0 +1,70 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: mailbox-dispatch
|
|
3
|
+
description: Controller-owned mailbox delegation for SDTK-SPEC. Use when PM or Orchestrator needs to assign a bounded phase to Claude or Codex, preserve exact include/exclude boundaries, review raw reports against formal artifacts, and run a mandatory post-issue mailbox retrospective.
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
# SDTK Mailbox Dispatch
|
|
7
|
+
|
|
8
|
+
Use this skill only for controller-owned delegation. It is the shipped SDTK-SPEC mailbox flow for bounded PM or Orchestrator dispatch, not a generic autonomous worker platform.
|
|
9
|
+
|
|
10
|
+
## Critical Constraints
|
|
11
|
+
- I do not use mailbox dispatch for broad exploratory planning when the controller already has enough local context to plan safely.
|
|
12
|
+
- I do not mix transient runtime files under `governance/ai/agent-mailbox/runtime/` into feature commit boundaries.
|
|
13
|
+
- I do not widen include/exclude boundaries, fallback rules, or verification commands without an explicit controller decision.
|
|
14
|
+
- I do not leak internal backlog IDs into runtime-facing docs, templates, samples, or public guidance.
|
|
15
|
+
|
|
16
|
+
## Use When
|
|
17
|
+
- one bounded issue phase should be delegated through the mailbox runtime
|
|
18
|
+
- runtime choice between Claude and Codex matters
|
|
19
|
+
- the task needs exact include/exclude boundaries and a stable review packet
|
|
20
|
+
- the phase is implementation, review, QA, or controller acceptance
|
|
21
|
+
- you want the closeout loop to absorb new mailbox lessons automatically
|
|
22
|
+
|
|
23
|
+
## Do Not Use
|
|
24
|
+
- broad exploratory planning when the controller already has enough local context
|
|
25
|
+
- unbounded multi-issue orchestration or a generic worker platform
|
|
26
|
+
- tasks that require a direct external-CLI-to-chat-session bridge
|
|
27
|
+
|
|
28
|
+
## Required Inputs
|
|
29
|
+
Read these shipped toolkit surfaces before dispatching or reviewing a run:
|
|
30
|
+
- `toolkit/templates/mailbox/AGENT_TASK_TEMPLATE.md`
|
|
31
|
+
- `toolkit/templates/mailbox/AGENT_REPORT_TEMPLATE.md`
|
|
32
|
+
- `toolkit/scripts/agents/run-claude-task.ps1`
|
|
33
|
+
- `toolkit/scripts/agents/run-codex-task.ps1`
|
|
34
|
+
- current issue spec/plan/review artifacts for the bounded phase
|
|
35
|
+
- current git truth for the included surfaces
|
|
36
|
+
|
|
37
|
+
## Workflow
|
|
38
|
+
1. Decide whether the controller should plan locally first. Default to local planning when the codebase context is already strong.
|
|
39
|
+
2. Choose runtime:
|
|
40
|
+
- Claude for controller spec drafting, wording-heavy review, and SDTK-SPEC shaping
|
|
41
|
+
- Codex for code changes, tests, workflow/harness changes, and verification-heavy implementation
|
|
42
|
+
3. Write the task packet with exact boundary truth, boundary mode, carryover findings, formal artifact write expectation, an explicit runtime-stall budget plus fallback trigger, and a clear closeout mode (`full-issue` or `phase-only`).
|
|
43
|
+
4. Dispatch through the mailbox launcher into `governance/ai/agent-mailbox/runtime/...`.
|
|
44
|
+
5. Review the raw report against git truth and the formal artifact on disk. Prefer the formal artifact when console output is lossy.
|
|
45
|
+
6. Promote only approved code/docs/tests/artifacts into tracked paths.
|
|
46
|
+
7. Run a default post-issue retrospective before the next mailbox-driven issue:
|
|
47
|
+
- update the mailbox contract/spec if a real new lesson appeared
|
|
48
|
+
- otherwise record `no new mailbox lessons` in the closeout summary
|
|
49
|
+
|
|
50
|
+
## Boundary Rules
|
|
51
|
+
- Treat runtime files under `governance/ai/agent-mailbox/runtime/` as transient.
|
|
52
|
+
- Do not mix mailbox runtime dirt into feature commit boundaries.
|
|
53
|
+
- State explicitly whether a batch is `canonical-only` or includes packaged distribution parity.
|
|
54
|
+
- Keep internal backlog IDs out of runtime-facing docs, templates, and public guidance.
|
|
55
|
+
|
|
56
|
+
## Fallback Rules
|
|
57
|
+
- If an external runtime stalls, use a bounded fallback path instead of blocking the issue.
|
|
58
|
+
- For long implementation passes, one bounded external attempt is enough before controller-local or native fallback if the trigger defined in the task packet is reached.
|
|
59
|
+
- If quota or permission prevents the agent from writing the formal artifact, the controller may author it directly, but the artifact must state the fallback reason.
|
|
60
|
+
- QA and controller acceptance may inherit fresh controller verification only when the implementation scope is unchanged and the inheritance is declared explicitly.
|
|
61
|
+
- If the controller fixes a bounded hygiene defect between phases, later mailbox tasks must review current repo truth and treat the resolved defect as fixed instead of repeating stale findings from earlier raw reports.
|
|
62
|
+
|
|
63
|
+
## Default Phase Order
|
|
64
|
+
1. `controller-spec` or `plan`
|
|
65
|
+
2. `implementation`
|
|
66
|
+
3. `controller-dev-review`
|
|
67
|
+
4. `qa-review`
|
|
68
|
+
5. `controller-acceptance`
|
|
69
|
+
6. `commit/push`
|
|
70
|
+
7. `post-issue-retrospective`
|
|
@@ -28,6 +28,13 @@ description: Orchestrate the SDTK-SPEC 6-phase workflow in Claude Code using SHA
|
|
|
28
28
|
- Update `SHARED_PLANNING.md` and `QUALITY_CHECKLIST.md`.
|
|
29
29
|
- Hand off only after the current phase has fresh evidence.
|
|
30
30
|
|
|
31
|
+
## Optional: Mailbox Dispatch
|
|
32
|
+
- Use `mailbox-dispatch` when one bounded controller-owned phase should be delegated to Claude or Codex.
|
|
33
|
+
- Keep planning local when the controller already has enough repo context.
|
|
34
|
+
- Lock exact include/exclude boundaries, fallback triggers, and verification commands before dispatch.
|
|
35
|
+
- Keep mailbox runtime files transient under `governance/ai/agent-mailbox/runtime/`.
|
|
36
|
+
- Run the default post-issue mailbox retrospective after repo truth is closed and before the next mailbox-driven issue.
|
|
37
|
+
|
|
31
38
|
## Guardrails
|
|
32
39
|
- Keep traceability: `REQ -> BR/UC/AC -> design -> backlog -> FEATURE_IMPL_PLAN -> CODE_HANDOFF -> downstream implementation evidence -> QA report`.
|
|
33
40
|
- Preserve the repo-local orchestrator contract as the exact fallback when direct built-in exposure or invocation is absent or unvalidated.
|
|
@@ -4,10 +4,10 @@ description: Product Manager + meta-orchestrator workflow for SDTK-SPEC. Use whe
|
|
|
4
4
|
---
|
|
5
5
|
|
|
6
6
|
## SDTK-SPEC Pipeline Rules (always apply)
|
|
7
|
-
1. Pipeline: PM Initiation
|
|
7
|
+
1. Pipeline: PM Initiation 竊・BA Analysis 竊・PM Planning 竊・Architecture Design 竊・Development + Review 竊・QA Validation
|
|
8
8
|
2. After completing phase work: update SHARED_PLANNING.md + QUALITY_CHECKLIST.md
|
|
9
9
|
3. If unclear: log OQ-xx in artifact, escalate to PM (PM asks user if needed)
|
|
10
|
-
4. Traceability: REQ
|
|
10
|
+
4. Traceability: REQ 竊・BR/UC/AC 竊・design 竊・backlog 竊・code/tests 竊・QA
|
|
11
11
|
5. Code review must be COMPLETE before QA phase can start
|
|
12
12
|
6. Do not skip phases. If inputs missing, ask focused questions.
|
|
13
13
|
|
|
@@ -45,6 +45,33 @@ If no arguments provided, read current feature context from SHARED_PLANNING.md.
|
|
|
45
45
|
- After Project Initiation -> suggest user run `/ba` to analyze requirements
|
|
46
46
|
- After PRD/Backlog -> suggest user run `/arch` to design architecture
|
|
47
47
|
|
|
48
|
+
## Optional: Condensed Upstream Input
|
|
49
|
+
|
|
50
|
+
If a basic product brief is provided before PM initiation, a condensed upstream
|
|
51
|
+
input package may be produced first using:
|
|
52
|
+
`toolkit/templates/docs/product/CONDENSED_UPSTREAM_INPUT_TEMPLATE.md`
|
|
53
|
+
|
|
54
|
+
The condensed output must carry the REQUIRES_HUMAN_REVIEW label (Gate H2) and
|
|
55
|
+
must be reviewed before the PM phase proceeds. Do not auto-advance to PM or BA
|
|
56
|
+
without explicit human confirmation. If the brief is outside the bounded domain,
|
|
57
|
+
stop and surface a boundary flag (Gate H1) rather than proceeding.
|
|
58
|
+
|
|
59
|
+
Deliver the condensed output as:
|
|
60
|
+
`docs/product/CONDENSED_UPSTREAM_INPUT_[FEATURE_KEY].md`
|
|
61
|
+
|
|
62
|
+
## Optional: Mailbox Delegation
|
|
63
|
+
|
|
64
|
+
Use `mailbox-dispatch` when PM needs bounded external-agent help without
|
|
65
|
+
opening a full orchestration platform loop.
|
|
66
|
+
|
|
67
|
+
Rules:
|
|
68
|
+
- keep PM planning local when the controller already has enough context
|
|
69
|
+
- delegate only one bounded phase at a time with exact include/exclude truth
|
|
70
|
+
- prefer Claude for controller-spec, wording-heavy review, and SDTK-SPEC shaping
|
|
71
|
+
- prefer Codex for code, tests, harness, or verification-heavy implementation
|
|
72
|
+
- review the formal artifact on disk before trusting raw console output
|
|
73
|
+
- keep governance/ai/agent-mailbox/runtime/ transient and out of feature commits
|
|
74
|
+
- run the post-issue mailbox retrospective before the next mailbox-driven issue
|
|
48
75
|
## Clarification And Decisions (PM responsibility)
|
|
49
76
|
- Collect OQ-xx items raised by BA/ARCH/DEV/QA in their respective artifacts.
|
|
50
77
|
- Try to resolve OQ-xx using existing docs and reasonable product/tech decisions.
|
|
@@ -75,6 +75,7 @@
|
|
|
75
75
|
- Generator-owned artifact: write or refresh it with `toolkit/scripts/generate-code-handoff.ps1`
|
|
76
76
|
- Do not hand-author the JSON shape or copy planning tables directly into the JSON
|
|
77
77
|
- Use canonical snake_case keys only; do not use legacy camelCase keys such as `featureKey`, `requiredRefs`, or `suggestedNextCommand`
|
|
78
|
+
- Current canonical generator emission is schema `0.2`; `SDTK-CODE` still accepts `0.1` for bounded compatibility
|
|
78
79
|
|
|
79
80
|
### 4.1 Handoff Status
|
|
80
81
|
- `READY_FOR_SDTK_CODE` or `BLOCKED_FOR_SDTK_CODE`
|
|
@@ -94,12 +95,22 @@
|
|
|
94
95
|
- TBD
|
|
95
96
|
|
|
96
97
|
### 4.6 Implementation Slices
|
|
98
|
+
- Keep the list in the recommended downstream build order.
|
|
97
99
|
- TBD
|
|
98
100
|
|
|
99
|
-
### 4.7
|
|
101
|
+
### 4.7 Impact Map
|
|
102
|
+
- Auto-derived from the handoff refs when the canonical generator runs.
|
|
103
|
+
- Expected keys: `api_refs`, `database_refs`, `ui_refs`, `flow_refs`
|
|
104
|
+
|
|
105
|
+
### 4.8 Test Obligations
|
|
106
|
+
- Write implementation-ready acceptance mapping statements, not vague labels.
|
|
107
|
+
- TBD
|
|
108
|
+
|
|
109
|
+
### 4.9 Recovery Notes (Optional)
|
|
110
|
+
- Add only when `/dev` already knows a recovery-sensitive constraint or a do-not-guess reminder.
|
|
100
111
|
- TBD
|
|
101
112
|
|
|
102
|
-
### 4.
|
|
113
|
+
### 4.10 Suggested Next Command
|
|
103
114
|
- If ready:
|
|
104
115
|
- `sdtk-code start --feature-key {{FEATURE_KEY}} --lane feature --project-path .`
|
|
105
116
|
- If blocked:
|