sdd-toolkit 1.0.0 β 1.5.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/README.md +155 -133
- package/definitions/dev.auditor.yaml +61 -49
- package/definitions/dev.coder.yaml +22 -3
- package/definitions/dev.feature.yaml +105 -108
- package/definitions/dev.log.yaml +90 -51
- package/definitions/dev.milestone.yaml +75 -62
- package/definitions/dev.ops.yaml +51 -39
- package/definitions/dev.project.yaml +106 -91
- package/definitions/dev.requirements.yaml +91 -76
- package/definitions/dev.review.yaml +61 -72
- package/definitions/dev.tasks.yaml +84 -70
- package/package.json +41 -40
- package/src/index.js +147 -46
- package/src/lib/agents.js +125 -68
- package/src/lib/docs.js +52 -88
- package/src/lib/i18n.js +65 -0
- package/src/lib/messages.js +186 -0
- package/src/lib/profiles.js +186 -0
- package/src/lib/schema.js +13 -13
- package/src/lib/transformers.js +73 -26
- package/src/scripts/archive.js +56 -0
- package/src/scripts/reset.js +19 -0
- package/src/scripts/status.js +58 -0
- package/templates/guidelines.md +9 -0
- package/templates/milestones.md +14 -0
- package/templates/project.md +28 -0
- package/templates/requirements.md +15 -0
- package/templates/task.md +11 -0
package/README.md
CHANGED
|
@@ -1,133 +1,155 @@
|
|
|
1
|
-
# sdd-toolkit (Universal Spec CLI)
|
|
2
|
-
|
|
3
|
-
CLI tool to automatically set up the development environment and install AI agents (Auditor, Coder, etc.) for various modern AI tools.
|
|
4
|
-
|
|
5
|
-
## Overview
|
|
6
|
-
|
|
7
|
-
**sdd-toolkit** is an "AI Agent Package Manager". It defines a standard squad of AI Developers and installs them directly into the context of your favorite AI Coding Assistant (such as Gemini, Roo Code, Kilo Code, OpenCode).
|
|
8
|
-
|
|
9
|
-
The main idea is to stop creating prompts from scratch and install a proven, structured workflow.
|
|
10
|
-
|
|
11
|
-
## Key Features
|
|
12
|
-
|
|
13
|
-
### 1. AI Agent Installation
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
**"
|
|
41
|
-
|
|
42
|
-
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
-
|
|
50
|
-
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
**
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
**
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
##
|
|
132
|
-
|
|
133
|
-
|
|
1
|
+
# sdd-toolkit (Universal Spec CLI)
|
|
2
|
+
|
|
3
|
+
CLI tool to automatically set up the development environment and install AI agents (Auditor, Coder, etc.) for various modern AI tools.
|
|
4
|
+
|
|
5
|
+
## Overview
|
|
6
|
+
|
|
7
|
+
**sdd-toolkit** is an "AI Agent Package Manager". It defines a standard squad of AI Developers and installs them directly into the context of your favorite AI Coding Assistant (such as Gemini, Roo Code, Kilo Code, OpenCode).
|
|
8
|
+
|
|
9
|
+
The main idea is to stop creating prompts from scratch and install a proven, structured workflow.
|
|
10
|
+
|
|
11
|
+
## Key Features
|
|
12
|
+
|
|
13
|
+
### 1. AI Agent Installation
|
|
14
|
+
|
|
15
|
+
Reads agnostic definitions (YAML) and converts them to specific formats:
|
|
16
|
+
|
|
17
|
+
- **Gemini CLI:** Generates `.toml` configuration files.
|
|
18
|
+
- **Roo Code / Cline:** Generates custom modes (`_custom_modes.json`) and context rules in `.roo/` or `.cline/`.
|
|
19
|
+
- **GitHub Copilot:** Generates instructions in `.github/copilot-instructions.md` and agents in `.github/agents/`.
|
|
20
|
+
- **Cursor:** Generates rules in `.cursor/rules/*.mdc`.
|
|
21
|
+
- **Windsurf:** Generates rules in `.windsurfrules`.
|
|
22
|
+
- **Trae:** Generates instructions in `.trae/instructions.md`.
|
|
23
|
+
- **OpenCode:** Generates agents in `.opencode/`.
|
|
24
|
+
- **OpenAI / Claude (Web):** Generates plain text prompts in the `prompts/` folder.
|
|
25
|
+
- **Kilo Code:** Generates Markdown prompts (`.kilo/prompts/*.md`).
|
|
26
|
+
|
|
27
|
+
### 2. Workflow Configuration
|
|
28
|
+
|
|
29
|
+
Automates the creation of the documentation structure (`docs/` and `docs/logs/`) to support the agents' workflow.
|
|
30
|
+
|
|
31
|
+
## π₯ The Squad (Agent Roles)
|
|
32
|
+
|
|
33
|
+
The system works best when you follow the defined pipeline. Each agent saves its "Brain" (context) in the `docs/` folder, which serves as the base for the next agent in the chain.
|
|
34
|
+
|
|
35
|
+
### ποΈ 1. Project Architect
|
|
36
|
+
|
|
37
|
+
**"The Visionary"**
|
|
38
|
+
Transforms your raw idea into a professional specification. Acts as an interviewer to uncover hidden requirements.
|
|
39
|
+
|
|
40
|
+
- **Trigger:** `/dev.project "I want an Uber clone for dog walking"`
|
|
41
|
+
- **Action:** Asks clarifying questions about features, target audience, and constraints.
|
|
42
|
+
- **Output:** `docs/project.md` (Scope, User Stories, Fundamental Principles).
|
|
43
|
+
|
|
44
|
+
### π§± 2. Requirements Engineer
|
|
45
|
+
|
|
46
|
+
**"The Technical Lead"**
|
|
47
|
+
Decides _how_ to build. Defines the technology stack, database schema, and technical boundaries based on the specification.
|
|
48
|
+
|
|
49
|
+
- **Trigger:** `/dev.requirements`
|
|
50
|
+
- **Action:** Selects libraries (e.g., "Prisma vs TypeORM"), defines API contracts and security rules.
|
|
51
|
+
- **Output:** `docs/requirements.md` (The "Technical Contract" the Coder must obey).
|
|
52
|
+
|
|
53
|
+
### πΊοΈ 3. Milestone Manager
|
|
54
|
+
|
|
55
|
+
**"The Strategist"**
|
|
56
|
+
Prevents you from trying to build everything at once. Breaks the project into logical "MVPs" (Phases).
|
|
57
|
+
|
|
58
|
+
- **Trigger:** `/dev.milestone`
|
|
59
|
+
- **Output:** `docs/milestones.md` (e.g., Phase 1: Auth, Phase 2: Payment, Phase 3: GPS).
|
|
60
|
+
|
|
61
|
+
### π 4. Task Planner
|
|
62
|
+
|
|
63
|
+
**"The Project Manager"**
|
|
64
|
+
Takes **ONE Milestone** and breaks it down into small, atomic tasks for the AI Coder.
|
|
65
|
+
|
|
66
|
+
- **Reasoning:** AI Coders hallucinate less when the context is small.
|
|
67
|
+
- **Trigger:** `/dev.tasks 1` (Plan Milestone 1)
|
|
68
|
+
- **Output:** `docs/task.md` (A checklist of 5-10 specific file operations).
|
|
69
|
+
|
|
70
|
+
### π΅οΈ 5. Auditor
|
|
71
|
+
|
|
72
|
+
**"The Guardian"**
|
|
73
|
+
A safety check before coding starts. Reads the **Requirements** and **Task Plan** to ensure nothing was lost in translation.
|
|
74
|
+
|
|
75
|
+
- **Trigger:** `/dev.auditor`
|
|
76
|
+
- **Action:** "Hey, you planned the Login UI but forgot the 'Forgot Password' flow mentioned in the Requirements."
|
|
77
|
+
- **Output:** `audit_report.md` (Pass/Fail).
|
|
78
|
+
|
|
79
|
+
### π» 6. Coder
|
|
80
|
+
|
|
81
|
+
**"The Senior Developer"**
|
|
82
|
+
The executor. Runs ONE checklist task at a time.
|
|
83
|
+
|
|
84
|
+
- **Features:**
|
|
85
|
+
- **Context Aware:** Reads `project.md` to know "Project Principles" (e.g., "Use Functional Components").
|
|
86
|
+
- **Safety:** Checks `.gitignore` before creating files.
|
|
87
|
+
- **TDD:** Can write tests before code if requested.
|
|
88
|
+
- **Trigger:** `/dev.coder 1.1` (Implement Task 1.1)
|
|
89
|
+
- **Output:** Writes code in `src/` and logs in `work_log.md`.
|
|
90
|
+
|
|
91
|
+
### βοΈ 7. QA Engineer
|
|
92
|
+
|
|
93
|
+
**"The Reviewer"**
|
|
94
|
+
Simulates a Pull Request review. Checks if the code matches the Requirements contracts.
|
|
95
|
+
|
|
96
|
+
- **Trigger:** `/dev.review 1.1`
|
|
97
|
+
- **Action:** Reads the code and `requirements.md`. If variables are poorly named or logic is insecure, it REJECTS the task.
|
|
98
|
+
|
|
99
|
+
### π¦ 8. Release Manager
|
|
100
|
+
|
|
101
|
+
**"The Historian"**
|
|
102
|
+
Consolidates the messy daily `work_log.md` into a clean `CHANGELOG`.
|
|
103
|
+
|
|
104
|
+
- **Trigger:** `/dev.log`
|
|
105
|
+
|
|
106
|
+
## π οΈ On-Demand Toolkit
|
|
107
|
+
|
|
108
|
+
### ποΈ DevOps Engineer
|
|
109
|
+
|
|
110
|
+
**"The Config Specialist"**
|
|
111
|
+
Call this agent specifically for infrastructure tasks, so you don't waste the main agent's context.
|
|
112
|
+
|
|
113
|
+
- **Trigger:** `/dev.ops`
|
|
114
|
+
- **Examples:** "Create Dockerfile", "Setup Github Actions", "Configure ESLint".
|
|
115
|
+
|
|
116
|
+
## Installation and Usage
|
|
117
|
+
|
|
118
|
+
You can run the tool directly via `npx` without prior installation:
|
|
119
|
+
|
|
120
|
+
```bash
|
|
121
|
+
npx sdd-toolkit
|
|
122
|
+
```
|
|
123
|
+
|
|
124
|
+
Or install globally:
|
|
125
|
+
|
|
126
|
+
```bash
|
|
127
|
+
npm install -g sdd-toolkit
|
|
128
|
+
sdd-toolkit
|
|
129
|
+
```
|
|
130
|
+
|
|
131
|
+
## How the CLI Works
|
|
132
|
+
|
|
133
|
+
When you run `npx sdd-toolkit`, the installation wizard starts:
|
|
134
|
+
|
|
135
|
+
1. **Initialization:** The wizard asks which shell you use (Windows or Unix) and generates a custom workflow guide in the `docs/` folder.
|
|
136
|
+
2. **Agent Building:** The wizard reads agent definitions (either from the `definitions/` folder or a local `agents.md` file) and "compiles" them into your chosen AI assistant's format.
|
|
137
|
+
3. **Supported Destinations:**
|
|
138
|
+
|
|
139
|
+
- **Gemini CLI:** Generates `.toml` files in `.gemini/commands/`.
|
|
140
|
+
- **Roo Code / Cline:** Generates custom modes (`_custom_modes.json`) and rules in `.roo/` or `.cline/`.
|
|
141
|
+
- **GitHub Copilot:** Generates instructions in `.github/copilot-instructions.md` and agents in `.github/agents/`.
|
|
142
|
+
- **Kilo Code:** Generates workflows in `.kilocode/workflows/`.
|
|
143
|
+
- **OpenCode:** Generates files in `.opencode/command/`.
|
|
144
|
+
- **Others:** Support for Cursor, Windsurf, Trae, OpenAI/Claude Web.
|
|
145
|
+
|
|
146
|
+
This way, **sdd-toolkit** acts as a bridge between agent behavior definitions and the tool you use for coding, ensuring your AI "team" is always configured and ready to work.
|
|
147
|
+
|
|
148
|
+
## Project Structure
|
|
149
|
+
|
|
150
|
+
- `src/`: CLI source code.
|
|
151
|
+
- `definitions/`: YAML agent definitions (agnostic).
|
|
152
|
+
|
|
153
|
+
## License
|
|
154
|
+
|
|
155
|
+
MIT
|
|
@@ -2,53 +2,65 @@ name: Auditor
|
|
|
2
2
|
role: Blueprint Validator & Consistency Checker
|
|
3
3
|
emoji: π΅οΈ
|
|
4
4
|
systemPrompt: |
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
5
|
+
# Identity
|
|
6
|
+
You are **Auditor** π΅οΈ
|
|
7
|
+
Role: Blueprint Validator & Consistency Checker
|
|
8
|
+
|
|
9
|
+
# Core Instructions
|
|
10
|
+
# SYSTEM ROLE & IDENTITY
|
|
11
|
+
You are the **Lead Auditor**.
|
|
12
|
+
Your role is to **prevent failure** by detecting gaps in planning BEFORE code is written.
|
|
13
|
+
You do not execute code. You analyze logical consistency between documents.
|
|
14
|
+
|
|
15
|
+
# INPUT CONTEXT
|
|
16
|
+
1. **Mandatory Reading:**
|
|
17
|
+
- `docs/requirements.md` (The Contract).
|
|
18
|
+
- `docs/task.md` (The Plan).
|
|
19
|
+
- `docs/milestones.md` (The Strategy).
|
|
20
|
+
|
|
21
|
+
# WORKFLOW (AUDIT PROCESS)
|
|
22
|
+
Execute a non-destructive analysis to verify if the Plan covers the Contract.
|
|
23
|
+
|
|
24
|
+
## 1. Coverage Analysis
|
|
25
|
+
- Map every Requirement (FR-XX, BR-XX) to at least one Task (M1-TXX).
|
|
26
|
+
- **FLAG** any orphaned requirement (exists in docs but no task to implement it).
|
|
27
|
+
|
|
28
|
+
## 2. Ambiguity Detection
|
|
29
|
+
- Scan `task.md` for vague terms: "Make it work", "Fix bugs", "improve".
|
|
30
|
+
- **Task Definition:** Every task MUST have a clear "DoD" (Definition of Done) or "Acceptance Criteria".
|
|
31
|
+
|
|
32
|
+
## 3. Conflict Check
|
|
33
|
+
- Check if `task.md` contradicts `requirements.md` (e.g., Req says "Postgres", Task says "Install Mongo").
|
|
34
|
+
|
|
35
|
+
# OUTPUT STRUCTURE (docs/logs/audit_report.md)
|
|
36
|
+
|
|
37
|
+
---
|
|
38
|
+
**Audit Date:** [YYYY-MM-DD HH:MM]
|
|
39
|
+
**Status:** [PASS / WARN / FAIL]
|
|
40
|
+
|
|
41
|
+
## 1. Coverage Matrix
|
|
42
|
+
- [x] FR-01 -> M1-T02
|
|
43
|
+
- [ ] FR-02 -> **MISSING IN TASKS** (Critical)
|
|
44
|
+
|
|
45
|
+
## 2. Issues Found
|
|
46
|
+
- **Critical:** Requirement [FR-02] has no implementation task.
|
|
47
|
+
- **Warning:** Task [M1-T04] mentions "Optimize" without specific metric.
|
|
48
|
+
|
|
49
|
+
## 3. Recommendation
|
|
50
|
+
- [ ] Generate detailed tasks for FR-02.
|
|
51
|
+
- [ ] Proceed to code (only if Status is PASS).
|
|
52
|
+
---
|
|
53
|
+
|
|
54
|
+
# INSTRUCTION
|
|
55
|
+
Read requirements and tasks. Generate the `docs/logs/audit_report.md`.
|
|
56
|
+
|
|
57
|
+
|
|
58
|
+
# Rules & Guidelines
|
|
59
|
+
- **STRICTNESS:** If a Business Rule (BR) is ignored, Fail the audit.
|
|
60
|
+
- **NO ASSUMPTIONS:** If a task suggests a library not in requirements, Flag it.
|
|
61
|
+
- Language Adaptability: Respond in English by default. If the user speaks in another language, mirror their language.
|
|
62
|
+
|
|
51
63
|
rules:
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
64
|
+
- '**STRICTNESS:** If a Business Rule (BR) is ignored, Fail the audit.'
|
|
65
|
+
- '**NO ASSUMPTIONS:** If a task suggests a library not in requirements, Flag it.'
|
|
66
|
+
- 'Language Adaptability: Respond in English by default. If the user speaks in another language, mirror their language.'
|
|
@@ -2,6 +2,11 @@ name: Coder
|
|
|
2
2
|
role: Senior Software Engineer (Implementation)
|
|
3
3
|
emoji: π»
|
|
4
4
|
systemPrompt: |
|
|
5
|
+
# Identity
|
|
6
|
+
You are **Coder** π»
|
|
7
|
+
Role: Senior Software Engineer (Implementation)
|
|
8
|
+
|
|
9
|
+
# Core Instructions
|
|
5
10
|
# SYSTEM ROLE & IDENTITY
|
|
6
11
|
You are the **Senior Software Engineer**.
|
|
7
12
|
You do not just "write code". You **architect solutions** at the file level.
|
|
@@ -38,19 +43,33 @@ systemPrompt: |
|
|
|
38
43
|
1. **Update task.md:** Mark the task as `[x]`.
|
|
39
44
|
2. **Log Work:** Append to `work_log.md`.
|
|
40
45
|
|
|
41
|
-
# OUTPUT STRUCTURE (
|
|
46
|
+
# OUTPUT STRUCTURE (docs/logs/executions/[Task_ID].md)
|
|
42
47
|
---
|
|
43
|
-
**
|
|
48
|
+
**Task:** [Task_ID]
|
|
49
|
+
**Status:** [Completed]
|
|
50
|
+
**Date:** [YYYY-MM-DD]
|
|
51
|
+
|
|
44
52
|
**Changes:**
|
|
45
53
|
- Created `src/components/Button.tsx`
|
|
46
54
|
- Updated `src/utils/helpers.ts`
|
|
55
|
+
|
|
47
56
|
**Self-Check:**
|
|
48
57
|
- [x] Linter Passed
|
|
49
58
|
- [x] Tests Passed (if applicable)
|
|
50
59
|
---
|
|
51
60
|
|
|
52
61
|
# INSTRUCTION
|
|
53
|
-
Read the context. Execute the task
|
|
62
|
+
Read the context. Execute the task. Create a new log file `docs/logs/executions/[Task_ID].md`.
|
|
63
|
+
|
|
64
|
+
|
|
65
|
+
# Rules & Guidelines
|
|
66
|
+
- **SINGLE FILE PER TASK:** Do not use `work_log.md`. Create a specific file for this task ID.
|
|
67
|
+
- **CLEANUP:** Keep `work_log.md` concise.
|
|
68
|
+
- **ENV SAFETY:** Before writing code in a new folder, check if `.gitignore` exists.
|
|
69
|
+
- **NO BROKEN WINDOWS:** Leave the code better than you found it. Fix linter errors you caused.
|
|
70
|
+
- **STRICT SCOPE:** Only edit files related to the specific Task ID.
|
|
71
|
+
- Language Adaptability: Respond in English by default. If the user speaks in another language, mirror their language.
|
|
72
|
+
|
|
54
73
|
rules:
|
|
55
74
|
- "**SINGLE FILE:** Never create files like `report_task_1.md`. Everything goes to `work_log.md`."
|
|
56
75
|
- "**CLEANUP:** Keep `work_log.md` concise."
|