@rasensio/aidlc 0.1.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 +251 -0
- package/capabilities/claude-code.yaml +9 -0
- package/capabilities/codex.yaml +8 -0
- package/capabilities/cursor.yaml +8 -0
- package/capabilities/kiro.yaml +9 -0
- package/capabilities/windsurf.yaml +8 -0
- package/ci/aidlc-gate.yml +100 -0
- package/dist/cli.d.ts +11 -0
- package/dist/cli.d.ts.map +1 -0
- package/dist/cli.js +39 -0
- package/dist/cli.js.map +1 -0
- package/dist/commands/add-action.d.ts +83 -0
- package/dist/commands/add-action.d.ts.map +1 -0
- package/dist/commands/add-action.js +437 -0
- package/dist/commands/add-action.js.map +1 -0
- package/dist/commands/continue.d.ts +23 -0
- package/dist/commands/continue.d.ts.map +1 -0
- package/dist/commands/continue.js +238 -0
- package/dist/commands/continue.js.map +1 -0
- package/dist/commands/discover.d.ts +19 -0
- package/dist/commands/discover.d.ts.map +1 -0
- package/dist/commands/discover.js +85 -0
- package/dist/commands/discover.js.map +1 -0
- package/dist/commands/docs.d.ts +25 -0
- package/dist/commands/docs.d.ts.map +1 -0
- package/dist/commands/docs.js +282 -0
- package/dist/commands/docs.js.map +1 -0
- package/dist/commands/gate.d.ts +25 -0
- package/dist/commands/gate.d.ts.map +1 -0
- package/dist/commands/gate.js +168 -0
- package/dist/commands/gate.js.map +1 -0
- package/dist/commands/init.d.ts +24 -0
- package/dist/commands/init.d.ts.map +1 -0
- package/dist/commands/init.js +187 -0
- package/dist/commands/init.js.map +1 -0
- package/dist/commands/review.d.ts +60 -0
- package/dist/commands/review.d.ts.map +1 -0
- package/dist/commands/review.js +264 -0
- package/dist/commands/review.js.map +1 -0
- package/dist/commands/setup.d.ts +24 -0
- package/dist/commands/setup.d.ts.map +1 -0
- package/dist/commands/setup.js +206 -0
- package/dist/commands/setup.js.map +1 -0
- package/dist/commands/start.d.ts +27 -0
- package/dist/commands/start.d.ts.map +1 -0
- package/dist/commands/start.js +243 -0
- package/dist/commands/start.js.map +1 -0
- package/dist/commands/status.d.ts +25 -0
- package/dist/commands/status.d.ts.map +1 -0
- package/dist/commands/status.js +263 -0
- package/dist/commands/status.js.map +1 -0
- package/dist/commands/transition.d.ts +30 -0
- package/dist/commands/transition.d.ts.map +1 -0
- package/dist/commands/transition.js +353 -0
- package/dist/commands/transition.js.map +1 -0
- package/dist/compile/adapters/claude-code.d.ts +24 -0
- package/dist/compile/adapters/claude-code.d.ts.map +1 -0
- package/dist/compile/adapters/claude-code.js +271 -0
- package/dist/compile/adapters/claude-code.js.map +1 -0
- package/dist/compile/adapters/codex.d.ts +19 -0
- package/dist/compile/adapters/codex.d.ts.map +1 -0
- package/dist/compile/adapters/codex.js +157 -0
- package/dist/compile/adapters/codex.js.map +1 -0
- package/dist/compile/adapters/cursor.d.ts +21 -0
- package/dist/compile/adapters/cursor.d.ts.map +1 -0
- package/dist/compile/adapters/cursor.js +181 -0
- package/dist/compile/adapters/cursor.js.map +1 -0
- package/dist/compile/adapters/index.d.ts +16 -0
- package/dist/compile/adapters/index.d.ts.map +1 -0
- package/dist/compile/adapters/index.js +26 -0
- package/dist/compile/adapters/index.js.map +1 -0
- package/dist/compile/adapters/kiro.d.ts +24 -0
- package/dist/compile/adapters/kiro.d.ts.map +1 -0
- package/dist/compile/adapters/kiro.js +222 -0
- package/dist/compile/adapters/kiro.js.map +1 -0
- package/dist/compile/adapters/windsurf.d.ts +25 -0
- package/dist/compile/adapters/windsurf.d.ts.map +1 -0
- package/dist/compile/adapters/windsurf.js +242 -0
- package/dist/compile/adapters/windsurf.js.map +1 -0
- package/dist/compile/install-plan.d.ts +49 -0
- package/dist/compile/install-plan.d.ts.map +1 -0
- package/dist/compile/install-plan.js +112 -0
- package/dist/compile/install-plan.js.map +1 -0
- package/dist/compile/loaders.d.ts +81 -0
- package/dist/compile/loaders.d.ts.map +1 -0
- package/dist/compile/loaders.js +293 -0
- package/dist/compile/loaders.js.map +1 -0
- package/dist/compile/merger.d.ts +32 -0
- package/dist/compile/merger.d.ts.map +1 -0
- package/dist/compile/merger.js +60 -0
- package/dist/compile/merger.js.map +1 -0
- package/dist/core/gate.d.ts +36 -0
- package/dist/core/gate.d.ts.map +1 -0
- package/dist/core/gate.js +97 -0
- package/dist/core/gate.js.map +1 -0
- package/dist/core/index.d.ts +7 -0
- package/dist/core/index.d.ts.map +1 -0
- package/dist/core/index.js +7 -0
- package/dist/core/index.js.map +1 -0
- package/dist/core/lifecycle.d.ts +89 -0
- package/dist/core/lifecycle.d.ts.map +1 -0
- package/dist/core/lifecycle.js +356 -0
- package/dist/core/lifecycle.js.map +1 -0
- package/dist/core/template-resolver.d.ts +56 -0
- package/dist/core/template-resolver.d.ts.map +1 -0
- package/dist/core/template-resolver.js +261 -0
- package/dist/core/template-resolver.js.map +1 -0
- package/dist/core/types.d.ts +527 -0
- package/dist/core/types.d.ts.map +1 -0
- package/dist/core/types.js +8 -0
- package/dist/core/types.js.map +1 -0
- package/dist/discover/scanner.d.ts +58 -0
- package/dist/discover/scanner.d.ts.map +1 -0
- package/dist/discover/scanner.js +772 -0
- package/dist/discover/scanner.js.map +1 -0
- package/dist/events/event-bus.d.ts +53 -0
- package/dist/events/event-bus.d.ts.map +1 -0
- package/dist/events/event-bus.js +263 -0
- package/dist/events/event-bus.js.map +1 -0
- package/dist/events/plugin-hooks.d.ts +44 -0
- package/dist/events/plugin-hooks.d.ts.map +1 -0
- package/dist/events/plugin-hooks.js +225 -0
- package/dist/events/plugin-hooks.js.map +1 -0
- package/dist/orchestrator/budget-packer.d.ts +57 -0
- package/dist/orchestrator/budget-packer.d.ts.map +1 -0
- package/dist/orchestrator/budget-packer.js +70 -0
- package/dist/orchestrator/budget-packer.js.map +1 -0
- package/dist/orchestrator/config.d.ts +43 -0
- package/dist/orchestrator/config.d.ts.map +1 -0
- package/dist/orchestrator/config.js +109 -0
- package/dist/orchestrator/config.js.map +1 -0
- package/dist/orchestrator/endpoint-clients.d.ts +23 -0
- package/dist/orchestrator/endpoint-clients.d.ts.map +1 -0
- package/dist/orchestrator/endpoint-clients.js +129 -0
- package/dist/orchestrator/endpoint-clients.js.map +1 -0
- package/dist/orchestrator/orchestrator-loop.d.ts +93 -0
- package/dist/orchestrator/orchestrator-loop.d.ts.map +1 -0
- package/dist/orchestrator/orchestrator-loop.js +185 -0
- package/dist/orchestrator/orchestrator-loop.js.map +1 -0
- package/dist/security/confirmation.d.ts +90 -0
- package/dist/security/confirmation.d.ts.map +1 -0
- package/dist/security/confirmation.js +140 -0
- package/dist/security/confirmation.js.map +1 -0
- package/dist/setup/setup-compute.d.ts +54 -0
- package/dist/setup/setup-compute.d.ts.map +1 -0
- package/dist/setup/setup-compute.js +66 -0
- package/dist/setup/setup-compute.js.map +1 -0
- package/dist/state/snapshot-store.d.ts +79 -0
- package/dist/state/snapshot-store.d.ts.map +1 -0
- package/dist/state/snapshot-store.js +164 -0
- package/dist/state/snapshot-store.js.map +1 -0
- package/dist/state/state-recovery.d.ts +87 -0
- package/dist/state/state-recovery.d.ts.map +1 -0
- package/dist/state/state-recovery.js +274 -0
- package/dist/state/state-recovery.js.map +1 -0
- package/dist/state/transition-log.d.ts +40 -0
- package/dist/state/transition-log.d.ts.map +1 -0
- package/dist/state/transition-log.js +83 -0
- package/dist/state/transition-log.js.map +1 -0
- package/dist/state/yaml-helpers.d.ts +53 -0
- package/dist/state/yaml-helpers.d.ts.map +1 -0
- package/dist/state/yaml-helpers.js +110 -0
- package/dist/state/yaml-helpers.js.map +1 -0
- package/examples/.gitkeep +0 -0
- package/guidance/accessibility.md +67 -0
- package/guidance/api-conventions.md +124 -0
- package/guidance/index.yaml +7 -0
- package/guidance/secure-defaults.md +71 -0
- package/package.json +52 -0
- package/phases/.gitkeep +0 -0
- package/skills/00-overview.md +74 -0
- package/skills/10-ideation.md +45 -0
- package/skills/20-requirements.md +54 -0
- package/skills/30-design.md +57 -0
- package/skills/40-implementation.md +64 -0
- package/skills/50-testing.md +60 -0
- package/skills/60-deployment.md +63 -0
- package/skills/70-maintenance.md +56 -0
- package/skills/80-review.md +85 -0
- package/skills/81-continue.md +57 -0
- package/skills/82-add-action.md +71 -0
- package/templates/.gitkeep +0 -0
- package/templates/bugfix.yaml +14 -0
- package/templates/full-feature.yaml +44 -0
- package/templates/micro-task.yaml +11 -0
- package/templates/quick-feature.yaml +20 -0
- package/templates/spike.yaml +15 -0
package/README.md
ADDED
|
@@ -0,0 +1,251 @@
|
|
|
1
|
+
# AIDLC — AI Development Lifecycle Framework
|
|
2
|
+
|
|
3
|
+
Structured lifecycle guidance for AI coding agents across platforms. One set of skills, every major AI coding tool.
|
|
4
|
+
|
|
5
|
+
## Prerequisites
|
|
6
|
+
|
|
7
|
+
```bash
|
|
8
|
+
# Verify Node.js >= 18
|
|
9
|
+
node --version
|
|
10
|
+
```
|
|
11
|
+
|
|
12
|
+
```bash
|
|
13
|
+
# Verify npm
|
|
14
|
+
npm --version
|
|
15
|
+
```
|
|
16
|
+
|
|
17
|
+
## Quick Start
|
|
18
|
+
|
|
19
|
+
### Install and initialize
|
|
20
|
+
|
|
21
|
+
```bash
|
|
22
|
+
# Install globally (or use npx without installing)
|
|
23
|
+
npm install -g @rasensio/aidlc
|
|
24
|
+
```
|
|
25
|
+
|
|
26
|
+
```bash
|
|
27
|
+
# platform: claude-code
|
|
28
|
+
npx @rasensio/aidlc init --platform claude-code
|
|
29
|
+
```
|
|
30
|
+
|
|
31
|
+
```bash
|
|
32
|
+
# platform: kiro
|
|
33
|
+
npx @rasensio/aidlc init --platform kiro
|
|
34
|
+
```
|
|
35
|
+
|
|
36
|
+
```bash
|
|
37
|
+
# platform: cursor
|
|
38
|
+
npx @rasensio/aidlc init --platform cursor
|
|
39
|
+
```
|
|
40
|
+
|
|
41
|
+
```bash
|
|
42
|
+
# platform: windsurf
|
|
43
|
+
npx @rasensio/aidlc init --platform windsurf
|
|
44
|
+
```
|
|
45
|
+
|
|
46
|
+
```bash
|
|
47
|
+
# platform: codex
|
|
48
|
+
npx @rasensio/aidlc init --platform codex
|
|
49
|
+
```
|
|
50
|
+
|
|
51
|
+
### Start, check, and continue
|
|
52
|
+
|
|
53
|
+
```bash
|
|
54
|
+
npx @rasensio/aidlc start
|
|
55
|
+
npx @rasensio/aidlc status
|
|
56
|
+
npx @rasensio/aidlc continue
|
|
57
|
+
```
|
|
58
|
+
|
|
59
|
+
### Verification
|
|
60
|
+
|
|
61
|
+
```bash
|
|
62
|
+
npx @rasensio/aidlc status
|
|
63
|
+
```
|
|
64
|
+
|
|
65
|
+
A successful run outputs lifecycle status and exits with code 0.
|
|
66
|
+
|
|
67
|
+
## Non-Interactive Setup
|
|
68
|
+
|
|
69
|
+
The `aidlc setup` command supports fully non-interactive operation for AI agents. All wizard options are available as CLI flags:
|
|
70
|
+
|
|
71
|
+
```bash
|
|
72
|
+
npx @rasensio/aidlc setup \
|
|
73
|
+
--project-type existing \
|
|
74
|
+
--complexity full \
|
|
75
|
+
--actions git-branch \
|
|
76
|
+
--platforms claude-code,kiro \
|
|
77
|
+
--yes
|
|
78
|
+
```
|
|
79
|
+
|
|
80
|
+
| Flag | Accepted Values | Description |
|
|
81
|
+
|------|----------------|-------------|
|
|
82
|
+
| `--project-type` | `new`, `existing` | Whether this is a new or existing project |
|
|
83
|
+
| `--complexity` | `simple`, `full` | Simple = Micro-Task template; Full = Full Feature template |
|
|
84
|
+
| `--actions` | `git-branch`, `github-issue`, `doc-update` (comma-separated) | Built-in lifecycle actions to enable |
|
|
85
|
+
| `--platforms` | `claude-code`, `kiro`, `cursor`, `windsurf`, `codex` (comma-separated) | Target AI platforms to configure |
|
|
86
|
+
| `--guidance` | `secure-defaults`, `accessibility`, `api-conventions` (comma-separated) | Guidance layers to install |
|
|
87
|
+
| `--yes` | (flag, no value) | Skip all confirmation prompts |
|
|
88
|
+
|
|
89
|
+
When `--yes` is provided, setup completes without interactive prompts or manual file editing.
|
|
90
|
+
|
|
91
|
+
## Post-Install: Discovery (Brownfield Projects)
|
|
92
|
+
|
|
93
|
+
For existing codebases, run discovery to generate project context:
|
|
94
|
+
|
|
95
|
+
```bash
|
|
96
|
+
npx @rasensio/aidlc discover
|
|
97
|
+
```
|
|
98
|
+
|
|
99
|
+
This scans the codebase and generates context documents in `.aidlc/context/` covering coding style and architecture. AI agents reference these docs during all lifecycle phases.
|
|
100
|
+
|
|
101
|
+
Non-interactive mode (overwrites existing docs without prompting):
|
|
102
|
+
|
|
103
|
+
```bash
|
|
104
|
+
npx @rasensio/aidlc discover --yes
|
|
105
|
+
```
|
|
106
|
+
|
|
107
|
+
Expected outputs: `.aidlc/context/style-guide.md` and `.aidlc/context/architecture.md`.
|
|
108
|
+
|
|
109
|
+
## Architecture
|
|
110
|
+
|
|
111
|
+
### Directory Layout
|
|
112
|
+
|
|
113
|
+
```
|
|
114
|
+
aidlc/ # npm package
|
|
115
|
+
├── skills/ # Universal skill definitions (platform-agnostic)
|
|
116
|
+
├── capabilities/ # Per-platform capability maps (YAML)
|
|
117
|
+
├── templates/ # Built-in workflow templates
|
|
118
|
+
├── guidance/ # Built-in guidance layers
|
|
119
|
+
├── src/
|
|
120
|
+
│ ├── cli.ts # CLI entry (commander wiring)
|
|
121
|
+
│ ├── commands/ # One module per CLI verb
|
|
122
|
+
│ ├── core/ # Lifecycle engine (pure functions)
|
|
123
|
+
│ ├── state/ # State store, atomic writes, transition log
|
|
124
|
+
│ ├── compile/ # Skill parser, adapters, install plans
|
|
125
|
+
│ ├── discover/ # Codebase scanner
|
|
126
|
+
│ ├── events/ # Event bus, action runner
|
|
127
|
+
│ ├── orchestrator/ # Bare-endpoint orchestration
|
|
128
|
+
│ └── setup/ # Setup wizard
|
|
129
|
+
└── test/ # vitest + fast-check tests
|
|
130
|
+
```
|
|
131
|
+
|
|
132
|
+
### Key Modules
|
|
133
|
+
|
|
134
|
+
| Module | Responsibility |
|
|
135
|
+
|--------|---------------|
|
|
136
|
+
| `core/lifecycle.ts` | Pure functions: `evaluateTransition`, `nextStep`, `completionPercent`, `isStalled` |
|
|
137
|
+
| `core/gate.ts` | Phase gate evaluation with exit-code semantics |
|
|
138
|
+
| `state/snapshot-store.ts` | Atomic state persistence (tmp + rename) |
|
|
139
|
+
| `state/transition-log.ts` | Append-only NDJSON transition log |
|
|
140
|
+
| `compile/adapters/` | Platform-specific install plan generators |
|
|
141
|
+
| `compile/merger.ts` | Managed-block merge (preserves surrounding content) |
|
|
142
|
+
| `events/event-bus.ts` | Lifecycle event dispatch, action/hook runner |
|
|
143
|
+
|
|
144
|
+
### Installed Project Layout
|
|
145
|
+
|
|
146
|
+
After `aidlc init`, the target project gains:
|
|
147
|
+
|
|
148
|
+
```
|
|
149
|
+
project/
|
|
150
|
+
├── .aidlc/
|
|
151
|
+
│ ├── config.yaml # Project configuration (optional)
|
|
152
|
+
│ ├── actions.yaml # Lifecycle event actions (opt-in)
|
|
153
|
+
│ ├── skills/ # Canonical skill bodies
|
|
154
|
+
│ ├── context/ # style-guide.md, architecture.md
|
|
155
|
+
│ ├── guidance/ # Active guidance layers + index.yaml
|
|
156
|
+
│ ├── templates/ # Custom workflow templates
|
|
157
|
+
│ ├── plugins/ # Extensions
|
|
158
|
+
│ └── state/<instance>/ # Per-instance lifecycle state
|
|
159
|
+
└── (platform configs: .claude/ .kiro/ .cursor/ .windsurf/ AGENTS.md)
|
|
160
|
+
```
|
|
161
|
+
|
|
162
|
+
## Supported Platforms
|
|
163
|
+
|
|
164
|
+
| Platform | Config Location | Strategy |
|
|
165
|
+
|----------|----------------|----------|
|
|
166
|
+
| Claude Code | `.claude/skills/aidlc-*/SKILL.md` | Thin activation shims pointing to `.aidlc/skills/` |
|
|
167
|
+
| Kiro | `.kiro/skills/aidlc-*/SKILL.md` + steering | Activation shims + always-included steering file |
|
|
168
|
+
| Cursor | `.cursor/rules/aidlc-*.mdc` | Agent-requested rules with description-based activation |
|
|
169
|
+
| Windsurf | `.windsurf/rules/aidlc-*.md` | Size-constrained pointer shims (under 6K/file) |
|
|
170
|
+
| Codex | `AGENTS.md` (managed block) | Managed delimiter block within existing AGENTS.md |
|
|
171
|
+
|
|
172
|
+
Each adapter installs canonical skill bodies into `.aidlc/skills/` and generates native platform shims that reference them. Existing non-AIDLC configuration is preserved.
|
|
173
|
+
|
|
174
|
+
## Lifecycle Phases
|
|
175
|
+
|
|
176
|
+
| Phase | Purpose |
|
|
177
|
+
|-------|---------|
|
|
178
|
+
| Ideation | Explore and validate ideas, identify alternatives |
|
|
179
|
+
| Requirements | Define acceptance criteria, scope, and constraints |
|
|
180
|
+
| Design | Produce architecture and technical design documents |
|
|
181
|
+
| Implementation | Write code following established conventions |
|
|
182
|
+
| Testing | Validate correctness and coverage |
|
|
183
|
+
| Deployment | Release to target environment |
|
|
184
|
+
| Maintenance | Monitor, patch, and evolve |
|
|
185
|
+
|
|
186
|
+
Phase applicability depends on the cycle scope: Full (all phases), Standard (Requirements through Deployment), Micro (Implementation + Testing only).
|
|
187
|
+
|
|
188
|
+
## CLI Commands
|
|
189
|
+
|
|
190
|
+
| Command | Purpose |
|
|
191
|
+
|---------|---------|
|
|
192
|
+
| `aidlc setup` | Interactive setup or update of project configuration |
|
|
193
|
+
| `aidlc discover` | Scan codebase, generate style and architecture context |
|
|
194
|
+
| `aidlc init --platform <id>` | Install skills for a target AI platform |
|
|
195
|
+
| `aidlc start [template]` | Begin a new lifecycle instance |
|
|
196
|
+
| `aidlc continue [instance]` | Resume the active lifecycle instance |
|
|
197
|
+
| `aidlc status [--json]` | Show progress across active instances |
|
|
198
|
+
| `aidlc review <artifact\|phase>` | Adversarial review of a lifecycle artifact |
|
|
199
|
+
| `aidlc gate <phase>` | CI gate check (exit 0 = complete, exit 1 = incomplete) |
|
|
200
|
+
| `aidlc transition <instance>` | Evaluate gates and advance to the next phase |
|
|
201
|
+
| `aidlc add action "<description>"` | Create a lifecycle action from natural language |
|
|
202
|
+
| `aidlc run [--endpoint <url>]` | Drive a bare LLM endpoint through the lifecycle |
|
|
203
|
+
|
|
204
|
+
### Dry-Run Mode
|
|
205
|
+
|
|
206
|
+
Preview what `init` would write without changing files:
|
|
207
|
+
|
|
208
|
+
```bash
|
|
209
|
+
npx @rasensio/aidlc init --platform claude-code --dry-run
|
|
210
|
+
```
|
|
211
|
+
|
|
212
|
+
## Configuration
|
|
213
|
+
|
|
214
|
+
Project configuration lives in `.aidlc/config.yaml`:
|
|
215
|
+
|
|
216
|
+
```yaml
|
|
217
|
+
version: 1
|
|
218
|
+
defaults: { scope: micro, template: micro-task }
|
|
219
|
+
stalled_threshold_days: 7
|
|
220
|
+
claim_timeout_minutes: 60
|
|
221
|
+
summary_threshold_bytes: 16384
|
|
222
|
+
orchestrator: # optional, only for bare-endpoint mode
|
|
223
|
+
endpoint: http://localhost:11434
|
|
224
|
+
model: qwen2.5-coder
|
|
225
|
+
api_format: ollama # ollama | openai
|
|
226
|
+
auto_advance: false
|
|
227
|
+
context_budget_tokens: 8000
|
|
228
|
+
```
|
|
229
|
+
|
|
230
|
+
Without this file, AIDLC defaults to Micro scope (Implementation + Testing only).
|
|
231
|
+
|
|
232
|
+
## Contributing
|
|
233
|
+
|
|
234
|
+
### Build and Test
|
|
235
|
+
|
|
236
|
+
```bash
|
|
237
|
+
npm install
|
|
238
|
+
npm run build
|
|
239
|
+
npm test
|
|
240
|
+
npm run lint
|
|
241
|
+
```
|
|
242
|
+
|
|
243
|
+
Tests use vitest (unit + integration) and fast-check (property-based, 14 correctness properties, 100+ iterations each).
|
|
244
|
+
|
|
245
|
+
### Project Conventions
|
|
246
|
+
|
|
247
|
+
- TypeScript, ES modules, Node >= 18
|
|
248
|
+
- Pure-function core (no I/O) with I/O pushed to edges
|
|
249
|
+
- Exact-pinned dependencies (no ranges)
|
|
250
|
+
- Property-based tests for core logic, golden-file tests for adapter output
|
|
251
|
+
- Deterministic state serialization (stable key order, block YAML style)
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
platform: claude-code
|
|
2
|
+
capabilities:
|
|
3
|
+
plan-mode:
|
|
4
|
+
phases: [ideation, requirements, design]
|
|
5
|
+
activation: >-
|
|
6
|
+
Before producing this phase's artifact, enter plan mode to reason through
|
|
7
|
+
the problem space, identify constraints, and outline the approach before
|
|
8
|
+
committing to a structure. Exit plan mode only when you begin writing the
|
|
9
|
+
artifact.
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
platform: codex
|
|
2
|
+
capabilities:
|
|
3
|
+
code-generation:
|
|
4
|
+
phases: [implementation, testing]
|
|
5
|
+
activation: >-
|
|
6
|
+
Leverage Codex sandboxed execution for this phase. Write implementation
|
|
7
|
+
code and tests together, using the sandbox to validate that tests pass
|
|
8
|
+
before proposing the final changeset.
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
platform: cursor
|
|
2
|
+
capabilities:
|
|
3
|
+
composer:
|
|
4
|
+
phases: [design, implementation]
|
|
5
|
+
activation: >-
|
|
6
|
+
Use Cursor Composer for this phase to coordinate multi-file edits in a
|
|
7
|
+
single operation. Frame the design or implementation as a Composer prompt
|
|
8
|
+
describing the desired end state across all affected files.
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
platform: kiro
|
|
2
|
+
capabilities:
|
|
3
|
+
spec-driven-development:
|
|
4
|
+
phases: [requirements, design, implementation]
|
|
5
|
+
activation: >-
|
|
6
|
+
Use Kiro spec sessions for this phase. Keep spec documents under
|
|
7
|
+
.kiro/specs/ and let the spec workflow drive requirements, design
|
|
8
|
+
decisions, and task breakdown. Reference the active spec when producing
|
|
9
|
+
artifacts so that traceability is maintained.
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
platform: windsurf
|
|
2
|
+
capabilities:
|
|
3
|
+
cascade:
|
|
4
|
+
phases: [implementation]
|
|
5
|
+
activation: >-
|
|
6
|
+
Use Windsurf Cascade flows for implementation steps that span multiple
|
|
7
|
+
files. Keep individual instructions concise due to context-size
|
|
8
|
+
constraints; reference .aidlc/skills/ for full phase guidance when needed.
|
|
@@ -0,0 +1,100 @@
|
|
|
1
|
+
# =============================================================================
|
|
2
|
+
# AIDLC Gate Check — GitHub Actions Workflow (sample/reference)
|
|
3
|
+
# =============================================================================
|
|
4
|
+
#
|
|
5
|
+
# This is a SAMPLE workflow demonstrating how to integrate `aidlc gate` into a
|
|
6
|
+
# CI/CD pipeline. Customize it for your project's branching strategy, instance
|
|
7
|
+
# naming, and phase requirements.
|
|
8
|
+
#
|
|
9
|
+
# Exit code semantics:
|
|
10
|
+
# 0 = phase is complete (gate passes, deployment may proceed)
|
|
11
|
+
# 1 = phase is incomplete (gate fails, deployment blocked)
|
|
12
|
+
#
|
|
13
|
+
# The --json flag outputs a structured GateCheckResult object:
|
|
14
|
+
# { pass, phase, missingArtifacts, unsatisfiedCriteria }
|
|
15
|
+
#
|
|
16
|
+
# Requirements: 9.5
|
|
17
|
+
# =============================================================================
|
|
18
|
+
|
|
19
|
+
name: AIDLC Gate Check
|
|
20
|
+
|
|
21
|
+
on:
|
|
22
|
+
pull_request:
|
|
23
|
+
branches: [main]
|
|
24
|
+
|
|
25
|
+
# ---------------------------------------------------------------------------
|
|
26
|
+
# Customization points:
|
|
27
|
+
#
|
|
28
|
+
# 1. AIDLC_INSTANCE — how you derive the lifecycle instance name.
|
|
29
|
+
# Below we use the PR title, but you could use branch name, a label, etc.
|
|
30
|
+
#
|
|
31
|
+
# 2. AIDLC_PHASE — which phase must be complete before merging.
|
|
32
|
+
# Common choices: "testing" (pre-merge), "deployment" (pre-deploy).
|
|
33
|
+
#
|
|
34
|
+
# 3. Node version — must be >= 18 (AIDLC prerequisite).
|
|
35
|
+
# ---------------------------------------------------------------------------
|
|
36
|
+
|
|
37
|
+
jobs:
|
|
38
|
+
gate:
|
|
39
|
+
runs-on: ubuntu-latest
|
|
40
|
+
steps:
|
|
41
|
+
- uses: actions/checkout@v4
|
|
42
|
+
|
|
43
|
+
- uses: actions/setup-node@v4
|
|
44
|
+
with:
|
|
45
|
+
node-version: '20'
|
|
46
|
+
|
|
47
|
+
- run: npm ci
|
|
48
|
+
|
|
49
|
+
# -----------------------------------------------------------------------
|
|
50
|
+
# Run the gate check.
|
|
51
|
+
# Exit code 0 means the phase is complete; exit code 1 means it is not.
|
|
52
|
+
# The --json flag produces structured output for downstream steps.
|
|
53
|
+
# -----------------------------------------------------------------------
|
|
54
|
+
- name: Check lifecycle gate
|
|
55
|
+
id: gate
|
|
56
|
+
run: |
|
|
57
|
+
set +e
|
|
58
|
+
OUTPUT=$(npx aidlc gate "$AIDLC_INSTANCE" "$AIDLC_PHASE" --json)
|
|
59
|
+
EXIT_CODE=$?
|
|
60
|
+
echo "$OUTPUT"
|
|
61
|
+
echo "result<<EOF" >> "$GITHUB_OUTPUT"
|
|
62
|
+
echo "$OUTPUT" >> "$GITHUB_OUTPUT"
|
|
63
|
+
echo "EOF" >> "$GITHUB_OUTPUT"
|
|
64
|
+
echo "exit_code=$EXIT_CODE" >> "$GITHUB_OUTPUT"
|
|
65
|
+
exit $EXIT_CODE
|
|
66
|
+
env:
|
|
67
|
+
AIDLC_INSTANCE: ${{ github.event.pull_request.title }}
|
|
68
|
+
AIDLC_PHASE: implementation
|
|
69
|
+
|
|
70
|
+
# -----------------------------------------------------------------------
|
|
71
|
+
# Optional: post gate results as a PR comment.
|
|
72
|
+
# Requires the `pull-requests: write` permission on the workflow.
|
|
73
|
+
# Uncomment and adapt as needed.
|
|
74
|
+
# -----------------------------------------------------------------------
|
|
75
|
+
# - name: Comment gate results on PR
|
|
76
|
+
# if: always()
|
|
77
|
+
# uses: actions/github-script@v7
|
|
78
|
+
# with:
|
|
79
|
+
# script: |
|
|
80
|
+
# const result = JSON.parse(`${{ steps.gate.outputs.result }}`);
|
|
81
|
+
# let body;
|
|
82
|
+
# if (result.pass) {
|
|
83
|
+
# body = `### ✓ AIDLC Gate Passed\n\nPhase **${result.phase}** is complete.`;
|
|
84
|
+
# } else {
|
|
85
|
+
# const missing = result.missingArtifacts.map(a => `- ${a}`).join('\n');
|
|
86
|
+
# const criteria = result.unsatisfiedCriteria.map(c => `- ${c}`).join('\n');
|
|
87
|
+
# body = [
|
|
88
|
+
# `### ✗ AIDLC Gate Failed`,
|
|
89
|
+
# ``,
|
|
90
|
+
# `Phase **${result.phase}** is not complete.`,
|
|
91
|
+
# missing ? `\n**Missing artifacts:**\n${missing}` : '',
|
|
92
|
+
# criteria ? `\n**Unsatisfied criteria:**\n${criteria}` : '',
|
|
93
|
+
# ].filter(Boolean).join('\n');
|
|
94
|
+
# }
|
|
95
|
+
# await github.rest.issues.createComment({
|
|
96
|
+
# owner: context.repo.owner,
|
|
97
|
+
# repo: context.repo.repo,
|
|
98
|
+
# issue_number: context.issue.number,
|
|
99
|
+
# body,
|
|
100
|
+
# });
|
package/dist/cli.d.ts
ADDED
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
/**
|
|
3
|
+
* CLI entry point for the AIDLC Framework.
|
|
4
|
+
*
|
|
5
|
+
* Thin commander wiring — every command delegates to a module under `commands/`.
|
|
6
|
+
* Machine-consumable output goes to stdout, diagnostics to stderr.
|
|
7
|
+
*
|
|
8
|
+
* Requirements: 17.1
|
|
9
|
+
*/
|
|
10
|
+
export {};
|
|
11
|
+
//# sourceMappingURL=cli.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"cli.d.ts","sourceRoot":"","sources":["../src/cli.ts"],"names":[],"mappings":";AAEA;;;;;;;GAOG"}
|
package/dist/cli.js
ADDED
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
/**
|
|
3
|
+
* CLI entry point for the AIDLC Framework.
|
|
4
|
+
*
|
|
5
|
+
* Thin commander wiring — every command delegates to a module under `commands/`.
|
|
6
|
+
* Machine-consumable output goes to stdout, diagnostics to stderr.
|
|
7
|
+
*
|
|
8
|
+
* Requirements: 17.1
|
|
9
|
+
*/
|
|
10
|
+
import { Command } from 'commander';
|
|
11
|
+
import { registerInit } from './commands/init.js';
|
|
12
|
+
import { registerStart } from './commands/start.js';
|
|
13
|
+
import { registerContinue } from './commands/continue.js';
|
|
14
|
+
import { registerStatus } from './commands/status.js';
|
|
15
|
+
import { registerGate } from './commands/gate.js';
|
|
16
|
+
import { registerTransition } from './commands/transition.js';
|
|
17
|
+
import { registerDiscover } from './commands/discover.js';
|
|
18
|
+
import { registerSetup } from './commands/setup.js';
|
|
19
|
+
import { registerAddAction } from './commands/add-action.js';
|
|
20
|
+
import { registerDocs } from './commands/docs.js';
|
|
21
|
+
import { registerReview } from './commands/review.js';
|
|
22
|
+
const program = new Command();
|
|
23
|
+
program
|
|
24
|
+
.name('aidlc')
|
|
25
|
+
.description('AI Development Lifecycle Framework')
|
|
26
|
+
.version('0.1.0');
|
|
27
|
+
registerInit(program);
|
|
28
|
+
registerStart(program);
|
|
29
|
+
registerContinue(program);
|
|
30
|
+
registerStatus(program);
|
|
31
|
+
registerGate(program);
|
|
32
|
+
registerTransition(program);
|
|
33
|
+
registerDiscover(program);
|
|
34
|
+
registerSetup(program);
|
|
35
|
+
registerAddAction(program);
|
|
36
|
+
registerDocs(program);
|
|
37
|
+
registerReview(program);
|
|
38
|
+
program.parse();
|
|
39
|
+
//# sourceMappingURL=cli.js.map
|
package/dist/cli.js.map
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"cli.js","sourceRoot":"","sources":["../src/cli.ts"],"names":[],"mappings":";AAEA;;;;;;;GAOG;AAEH,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AACpC,OAAO,EAAE,YAAY,EAAE,MAAM,oBAAoB,CAAC;AAClD,OAAO,EAAE,aAAa,EAAE,MAAM,qBAAqB,CAAC;AACpD,OAAO,EAAE,gBAAgB,EAAE,MAAM,wBAAwB,CAAC;AAC1D,OAAO,EAAE,cAAc,EAAE,MAAM,sBAAsB,CAAC;AACtD,OAAO,EAAE,YAAY,EAAE,MAAM,oBAAoB,CAAC;AAClD,OAAO,EAAE,kBAAkB,EAAE,MAAM,0BAA0B,CAAC;AAC9D,OAAO,EAAE,gBAAgB,EAAE,MAAM,wBAAwB,CAAC;AAC1D,OAAO,EAAE,aAAa,EAAE,MAAM,qBAAqB,CAAC;AACpD,OAAO,EAAE,iBAAiB,EAAE,MAAM,0BAA0B,CAAC;AAC7D,OAAO,EAAE,YAAY,EAAE,MAAM,oBAAoB,CAAC;AAClD,OAAO,EAAE,cAAc,EAAE,MAAM,sBAAsB,CAAC;AAEtD,MAAM,OAAO,GAAG,IAAI,OAAO,EAAE,CAAC;AAE9B,OAAO;KACJ,IAAI,CAAC,OAAO,CAAC;KACb,WAAW,CAAC,oCAAoC,CAAC;KACjD,OAAO,CAAC,OAAO,CAAC,CAAC;AAEpB,YAAY,CAAC,OAAO,CAAC,CAAC;AACtB,aAAa,CAAC,OAAO,CAAC,CAAC;AACvB,gBAAgB,CAAC,OAAO,CAAC,CAAC;AAC1B,cAAc,CAAC,OAAO,CAAC,CAAC;AACxB,YAAY,CAAC,OAAO,CAAC,CAAC;AACtB,kBAAkB,CAAC,OAAO,CAAC,CAAC;AAC5B,gBAAgB,CAAC,OAAO,CAAC,CAAC;AAC1B,aAAa,CAAC,OAAO,CAAC,CAAC;AACvB,iBAAiB,CAAC,OAAO,CAAC,CAAC;AAC3B,YAAY,CAAC,OAAO,CAAC,CAAC;AACtB,cAAc,CAAC,OAAO,CAAC,CAAC;AAExB,OAAO,CAAC,KAAK,EAAE,CAAC"}
|
|
@@ -0,0 +1,83 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* `aidlc add action` command — AI-assisted action authoring.
|
|
3
|
+
*
|
|
4
|
+
* Translates a natural language description into a Lifecycle_Action entry
|
|
5
|
+
* in `.aidlc/actions.yaml`. Supports interactive confirmation, dry-run,
|
|
6
|
+
* and non-interactive mode.
|
|
7
|
+
*
|
|
8
|
+
* Requirements: 22.1, 22.5, 22.6, 22.7, 22.8, 22.9, 22.10, 22.11, 22.13, 20.2, 20.3
|
|
9
|
+
*
|
|
10
|
+
* @module
|
|
11
|
+
*/
|
|
12
|
+
import { Command } from 'commander';
|
|
13
|
+
import type { LifecycleEvent, PhaseName } from '../core/types.js';
|
|
14
|
+
/** The inferred action declaration from a natural language description. */
|
|
15
|
+
export interface InferredAction {
|
|
16
|
+
id: string;
|
|
17
|
+
event: LifecycleEvent;
|
|
18
|
+
phase?: PhaseName | string;
|
|
19
|
+
use?: string;
|
|
20
|
+
with?: Record<string, unknown>;
|
|
21
|
+
run?: string;
|
|
22
|
+
blocking: boolean;
|
|
23
|
+
description: string;
|
|
24
|
+
}
|
|
25
|
+
/**
|
|
26
|
+
* Infer a lifecycle event from a natural language description.
|
|
27
|
+
*
|
|
28
|
+
* Rules:
|
|
29
|
+
* - "when starting" / "on start" → on-instance-start
|
|
30
|
+
* - "when entering" / "on enter" → on-phase-enter
|
|
31
|
+
* - "when exiting" / "on exit" / "after" → on-phase-exit
|
|
32
|
+
* - "when complete" / "on finish" → on-instance-complete
|
|
33
|
+
* - Otherwise → null (cannot infer)
|
|
34
|
+
*/
|
|
35
|
+
export declare function inferEvent(description: string): LifecycleEvent | null;
|
|
36
|
+
/**
|
|
37
|
+
* Infer a phase filter from the description.
|
|
38
|
+
* Looks for known phase names in the text.
|
|
39
|
+
*/
|
|
40
|
+
export declare function inferPhase(description: string): PhaseName | undefined;
|
|
41
|
+
/**
|
|
42
|
+
* Infer whether the action should use a built-in or a custom command.
|
|
43
|
+
*
|
|
44
|
+
* Rules:
|
|
45
|
+
* - "create branch" / "git branch" → use: git-branch
|
|
46
|
+
* - "issue" / "github" → use: github-issue
|
|
47
|
+
* - Otherwise → run: <description as command>
|
|
48
|
+
*/
|
|
49
|
+
export declare function inferAction(description: string): {
|
|
50
|
+
use?: string;
|
|
51
|
+
with?: Record<string, unknown>;
|
|
52
|
+
run?: string;
|
|
53
|
+
};
|
|
54
|
+
/**
|
|
55
|
+
* Generate a URL-safe action ID from the description.
|
|
56
|
+
*/
|
|
57
|
+
export declare function generateActionId(description: string): string;
|
|
58
|
+
/**
|
|
59
|
+
* Full inference pipeline: take a natural language description and produce
|
|
60
|
+
* an InferredAction. Returns `null` for the event field if it cannot be inferred.
|
|
61
|
+
*/
|
|
62
|
+
export declare function inferActionFromDescription(description: string, eventOverride?: LifecycleEvent, blockingOverride?: boolean): InferredAction | {
|
|
63
|
+
event: null;
|
|
64
|
+
description: string;
|
|
65
|
+
};
|
|
66
|
+
/**
|
|
67
|
+
* Validate a single action entry against the ActionsConfig schema.
|
|
68
|
+
* Returns null if valid, or an error string describing the violation.
|
|
69
|
+
*/
|
|
70
|
+
export declare function validateActionEntry(entry: InferredAction): string | null;
|
|
71
|
+
/**
|
|
72
|
+
* Append an action to the actions.yaml file (create if it doesn't exist).
|
|
73
|
+
*/
|
|
74
|
+
export declare function appendAction(actionsPath: string, action: InferredAction): void;
|
|
75
|
+
/**
|
|
76
|
+
* Render an InferredAction as a YAML preview for user confirmation.
|
|
77
|
+
*/
|
|
78
|
+
export declare function renderActionPreview(action: InferredAction): string;
|
|
79
|
+
/**
|
|
80
|
+
* Register the `aidlc add action` command on the given commander program.
|
|
81
|
+
*/
|
|
82
|
+
export declare function registerAddAction(program: Command): void;
|
|
83
|
+
//# sourceMappingURL=add-action.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"add-action.d.ts","sourceRoot":"","sources":["../../src/commands/add-action.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;AAEH,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AAMpC,OAAO,KAAK,EAGV,cAAc,EACd,SAAS,EAEV,MAAM,kBAAkB,CAAC;AAO1B,2EAA2E;AAC3E,MAAM,WAAW,cAAc;IAC7B,EAAE,EAAE,MAAM,CAAC;IACX,KAAK,EAAE,cAAc,CAAC;IACtB,KAAK,CAAC,EAAE,SAAS,GAAG,MAAM,CAAC;IAC3B,GAAG,CAAC,EAAE,MAAM,CAAC;IACb,IAAI,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;IAC/B,GAAG,CAAC,EAAE,MAAM,CAAC;IACb,QAAQ,EAAE,OAAO,CAAC;IAClB,WAAW,EAAE,MAAM,CAAC;CACrB;AA4BD;;;;;;;;;GASG;AACH,wBAAgB,UAAU,CAAC,WAAW,EAAE,MAAM,GAAG,cAAc,GAAG,IAAI,CA2DrE;AAED;;;GAGG;AACH,wBAAgB,UAAU,CAAC,WAAW,EAAE,MAAM,GAAG,SAAS,GAAG,SAAS,CAQrE;AAED;;;;;;;GAOG;AACH,wBAAgB,WAAW,CAAC,WAAW,EAAE,MAAM,GAAG;IAAE,GAAG,CAAC,EAAE,MAAM,CAAC;IAAC,IAAI,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;IAAC,GAAG,CAAC,EAAE,MAAM,CAAA;CAAE,CAoB/G;AAED;;GAEG;AACH,wBAAgB,gBAAgB,CAAC,WAAW,EAAE,MAAM,GAAG,MAAM,CAO5D;AAED;;;GAGG;AACH,wBAAgB,0BAA0B,CACxC,WAAW,EAAE,MAAM,EACnB,aAAa,CAAC,EAAE,cAAc,EAC9B,gBAAgB,CAAC,EAAE,OAAO,GACzB,cAAc,GAAG;IAAE,KAAK,EAAE,IAAI,CAAC;IAAC,WAAW,EAAE,MAAM,CAAA;CAAE,CAoBvD;AAMD;;;GAGG;AACH,wBAAgB,mBAAmB,CAAC,KAAK,EAAE,cAAc,GAAG,MAAM,GAAG,IAAI,CAsBxE;AAiCD;;GAEG;AACH,wBAAgB,YAAY,CAAC,WAAW,EAAE,MAAM,EAAE,MAAM,EAAE,cAAc,GAAG,IAAI,CAwB9E;AAMD;;GAEG;AACH,wBAAgB,mBAAmB,CAAC,MAAM,EAAE,cAAc,GAAG,MAAM,CAuBlE;AAMD;;GAEG;AACH,wBAAgB,iBAAiB,CAAC,OAAO,EAAE,OAAO,GAAG,IAAI,CAgBxD"}
|