@patricksardinha/agentkit-cli 0.1.0 → 0.2.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/AGENT_WORKFLOW.md +54 -54
- package/CLAUDE.md +44 -44
- package/LICENSE +21 -0
- package/README.md +354 -327
- package/dist/cli.cjs +0 -0
- package/dist/cli.js +0 -0
- package/package.json +1 -1
package/AGENT_WORKFLOW.md
CHANGED
|
@@ -1,55 +1,55 @@
|
|
|
1
|
-
# Agent Workflow — AgentKit CLI
|
|
2
|
-
|
|
3
|
-
## Vue d'ensemble
|
|
4
|
-
Ce projet est construit par 4 agents spécialisés en séquence.
|
|
5
|
-
Chaque agent a un périmètre strict, des inputs définis, et un
|
|
6
|
-
critère de succès vérifiable avant de passer au suivant.
|
|
7
|
-
|
|
8
|
-
## Phase 1 — Foundation
|
|
9
|
-
|
|
10
|
-
### Agent 1 · Infra & Setup
|
|
11
|
-
Périmètre : scaffolding du projet Node.js/TS, configuration build
|
|
12
|
-
Lit : CLAUDE.md section Stack
|
|
13
|
-
Produit :
|
|
14
|
-
- package.json (commander, inquirer, chalk, ora, tsup)
|
|
15
|
-
- tsconfig.json + tsup.config.ts
|
|
16
|
-
- .github/workflows/release.yml (npm publish on v*)
|
|
17
|
-
- vitest.config.ts
|
|
18
|
-
- src/utils/logger.ts
|
|
19
|
-
Critère : npm run build passe, structure src/ conforme à CLAUDE.md
|
|
20
|
-
|
|
21
|
-
### Agent 2 · Detectors
|
|
22
|
-
Dépend de : Agent 1
|
|
23
|
-
Périmètre : détection automatique de la stack d'un projet cible
|
|
24
|
-
Produit :
|
|
25
|
-
- src/detectors/stackDetector.ts
|
|
26
|
-
→ détecte : React, Next.js, Tauri, Python/FastAPI, Node/Express
|
|
27
|
-
→ lit package.json, requirements.txt, src-tauri/
|
|
28
|
-
- src/detectors/gitDetector.ts
|
|
29
|
-
→ vérifie si le dossier est un repo git
|
|
30
|
-
- tests/detectors/stackDetector.test.ts
|
|
31
|
-
Critère : npm test passe sur des fixtures de projets types
|
|
32
|
-
|
|
33
|
-
## Phase 2 — Generators (parallélisables)
|
|
34
|
-
|
|
35
|
-
### Agent 3 · Generators
|
|
36
|
-
Dépend de : Agent 2 (pour stackDetector)
|
|
37
|
-
Périmètre : génération des fichiers CLAUDE.md et AGENT_WORKFLOW.md
|
|
38
|
-
Produit :
|
|
39
|
-
- src/generators/claudeMdGenerator.ts
|
|
40
|
-
→ prend StackInfo, retourne string CLAUDE.md adapté
|
|
41
|
-
- src/generators/workflowGenerator.ts
|
|
42
|
-
→ prend StackInfo, retourne string AGENT_WORKFLOW.md adapté
|
|
43
|
-
- src/templates/ (un template par stack détectée)
|
|
44
|
-
- tests/generators/*.test.ts
|
|
45
|
-
Critère : génère des fichiers valides pour chaque stack supportée
|
|
46
|
-
|
|
47
|
-
### Agent 4 · Commands CLI
|
|
48
|
-
Dépend de : Agent 2 + Agent 3
|
|
49
|
-
Périmètre : wiring des commandes CLI avec commander.js
|
|
50
|
-
Produit :
|
|
51
|
-
- src/commands/init.ts → npx agentkit init
|
|
52
|
-
- src/commands/add.ts → npx agentkit add agent
|
|
53
|
-
- src/commands/status.ts → npx agentkit status
|
|
54
|
-
- src/cli.ts → entry point
|
|
1
|
+
# Agent Workflow — AgentKit CLI
|
|
2
|
+
|
|
3
|
+
## Vue d'ensemble
|
|
4
|
+
Ce projet est construit par 4 agents spécialisés en séquence.
|
|
5
|
+
Chaque agent a un périmètre strict, des inputs définis, et un
|
|
6
|
+
critère de succès vérifiable avant de passer au suivant.
|
|
7
|
+
|
|
8
|
+
## Phase 1 — Foundation
|
|
9
|
+
|
|
10
|
+
### Agent 1 · Infra & Setup
|
|
11
|
+
Périmètre : scaffolding du projet Node.js/TS, configuration build
|
|
12
|
+
Lit : CLAUDE.md section Stack
|
|
13
|
+
Produit :
|
|
14
|
+
- package.json (commander, inquirer, chalk, ora, tsup)
|
|
15
|
+
- tsconfig.json + tsup.config.ts
|
|
16
|
+
- .github/workflows/release.yml (npm publish on v*)
|
|
17
|
+
- vitest.config.ts
|
|
18
|
+
- src/utils/logger.ts
|
|
19
|
+
Critère : npm run build passe, structure src/ conforme à CLAUDE.md
|
|
20
|
+
|
|
21
|
+
### Agent 2 · Detectors
|
|
22
|
+
Dépend de : Agent 1
|
|
23
|
+
Périmètre : détection automatique de la stack d'un projet cible
|
|
24
|
+
Produit :
|
|
25
|
+
- src/detectors/stackDetector.ts
|
|
26
|
+
→ détecte : React, Next.js, Tauri, Python/FastAPI, Node/Express
|
|
27
|
+
→ lit package.json, requirements.txt, src-tauri/
|
|
28
|
+
- src/detectors/gitDetector.ts
|
|
29
|
+
→ vérifie si le dossier est un repo git
|
|
30
|
+
- tests/detectors/stackDetector.test.ts
|
|
31
|
+
Critère : npm test passe sur des fixtures de projets types
|
|
32
|
+
|
|
33
|
+
## Phase 2 — Generators (parallélisables)
|
|
34
|
+
|
|
35
|
+
### Agent 3 · Generators
|
|
36
|
+
Dépend de : Agent 2 (pour stackDetector)
|
|
37
|
+
Périmètre : génération des fichiers CLAUDE.md et AGENT_WORKFLOW.md
|
|
38
|
+
Produit :
|
|
39
|
+
- src/generators/claudeMdGenerator.ts
|
|
40
|
+
→ prend StackInfo, retourne string CLAUDE.md adapté
|
|
41
|
+
- src/generators/workflowGenerator.ts
|
|
42
|
+
→ prend StackInfo, retourne string AGENT_WORKFLOW.md adapté
|
|
43
|
+
- src/templates/ (un template par stack détectée)
|
|
44
|
+
- tests/generators/*.test.ts
|
|
45
|
+
Critère : génère des fichiers valides pour chaque stack supportée
|
|
46
|
+
|
|
47
|
+
### Agent 4 · Commands CLI
|
|
48
|
+
Dépend de : Agent 2 + Agent 3
|
|
49
|
+
Périmètre : wiring des commandes CLI avec commander.js
|
|
50
|
+
Produit :
|
|
51
|
+
- src/commands/init.ts → npx agentkit init
|
|
52
|
+
- src/commands/add.ts → npx agentkit add agent
|
|
53
|
+
- src/commands/status.ts → npx agentkit status
|
|
54
|
+
- src/cli.ts → entry point
|
|
55
55
|
Critère : npx agentkit --help affiche toutes les commandes
|
package/CLAUDE.md
CHANGED
|
@@ -1,45 +1,45 @@
|
|
|
1
|
-
# CLAUDE.md — AgentKit CLI
|
|
2
|
-
|
|
3
|
-
## Rôle de ce fichier
|
|
4
|
-
Ce fichier est lu par tous les agents Claude Code avant toute action.
|
|
5
|
-
Il définit les conventions, la stack, et les règles du projet.
|
|
6
|
-
|
|
7
|
-
## Projet
|
|
8
|
-
Nom : agentkit-cli
|
|
9
|
-
Type : CLI npm open-source (Node.js + TypeScript)
|
|
10
|
-
Objectif : Scaffolder des workflows multi-agents Claude Code
|
|
11
|
-
Public : Développeurs fullstack qui utilisent Claude Code
|
|
12
|
-
Registry : npm (npx agentkit init)
|
|
13
|
-
|
|
14
|
-
## Stack
|
|
15
|
-
- Runtime : Node.js 20+, TypeScript 5
|
|
16
|
-
- CLI : commander.js + inquirer.js + chalk + ora
|
|
17
|
-
- Build : tsup (ESM + CJS dual output)
|
|
18
|
-
- Tests : Vitest
|
|
19
|
-
- CI/CD : GitHub Actions → npm publish on tag v*
|
|
20
|
-
|
|
21
|
-
## Structure des fichiers
|
|
22
|
-
src/
|
|
23
|
-
cli.ts ← entry point (commander setup)
|
|
24
|
-
commands/ ← une commande = un fichier
|
|
25
|
-
generators/ ← logique de génération des fichiers
|
|
26
|
-
detectors/ ← détection de stack (package.json, etc.)
|
|
27
|
-
templates/ ← templates CLAUDE.md, AGENT_WORKFLOW.md
|
|
28
|
-
utils/ ← helpers partagés
|
|
29
|
-
tests/ ← Vitest, miroir de src/
|
|
30
|
-
|
|
31
|
-
## Règles absolues
|
|
32
|
-
1. Chaque commande dans src/commands/ est indépendante
|
|
33
|
-
2. Les templates dans src/templates/ sont des fonctions TS, pas des fichiers .md statiques
|
|
34
|
-
3. Tout output CLI passe par src/utils/logger.ts (jamais console.log direct)
|
|
35
|
-
4. Chaque fichier généré doit avoir un test dans tests/generators/
|
|
36
|
-
5. Zéro dépendance non listée ici sans discussion
|
|
37
|
-
|
|
38
|
-
## Conventions de commit
|
|
39
|
-
feat: / fix: / test: / docs: / chore: / release:
|
|
40
|
-
|
|
41
|
-
## Critères de succès (Definition of Done)
|
|
42
|
-
- npx agentkit init fonctionne sur un repo vide
|
|
43
|
-
- npx agentkit init détecte automatiquement React, Next.js, Tauri, Python
|
|
44
|
-
- npm test passe sans erreur
|
|
1
|
+
# CLAUDE.md — AgentKit CLI
|
|
2
|
+
|
|
3
|
+
## Rôle de ce fichier
|
|
4
|
+
Ce fichier est lu par tous les agents Claude Code avant toute action.
|
|
5
|
+
Il définit les conventions, la stack, et les règles du projet.
|
|
6
|
+
|
|
7
|
+
## Projet
|
|
8
|
+
Nom : agentkit-cli
|
|
9
|
+
Type : CLI npm open-source (Node.js + TypeScript)
|
|
10
|
+
Objectif : Scaffolder des workflows multi-agents Claude Code
|
|
11
|
+
Public : Développeurs fullstack qui utilisent Claude Code
|
|
12
|
+
Registry : npm (npx agentkit init)
|
|
13
|
+
|
|
14
|
+
## Stack
|
|
15
|
+
- Runtime : Node.js 20+, TypeScript 5
|
|
16
|
+
- CLI : commander.js + inquirer.js + chalk + ora
|
|
17
|
+
- Build : tsup (ESM + CJS dual output)
|
|
18
|
+
- Tests : Vitest
|
|
19
|
+
- CI/CD : GitHub Actions → npm publish on tag v*
|
|
20
|
+
|
|
21
|
+
## Structure des fichiers
|
|
22
|
+
src/
|
|
23
|
+
cli.ts ← entry point (commander setup)
|
|
24
|
+
commands/ ← une commande = un fichier
|
|
25
|
+
generators/ ← logique de génération des fichiers
|
|
26
|
+
detectors/ ← détection de stack (package.json, etc.)
|
|
27
|
+
templates/ ← templates CLAUDE.md, AGENT_WORKFLOW.md
|
|
28
|
+
utils/ ← helpers partagés
|
|
29
|
+
tests/ ← Vitest, miroir de src/
|
|
30
|
+
|
|
31
|
+
## Règles absolues
|
|
32
|
+
1. Chaque commande dans src/commands/ est indépendante
|
|
33
|
+
2. Les templates dans src/templates/ sont des fonctions TS, pas des fichiers .md statiques
|
|
34
|
+
3. Tout output CLI passe par src/utils/logger.ts (jamais console.log direct)
|
|
35
|
+
4. Chaque fichier généré doit avoir un test dans tests/generators/
|
|
36
|
+
5. Zéro dépendance non listée ici sans discussion
|
|
37
|
+
|
|
38
|
+
## Conventions de commit
|
|
39
|
+
feat: / fix: / test: / docs: / chore: / release:
|
|
40
|
+
|
|
41
|
+
## Critères de succès (Definition of Done)
|
|
42
|
+
- npx agentkit init fonctionne sur un repo vide
|
|
43
|
+
- npx agentkit init détecte automatiquement React, Next.js, Tauri, Python
|
|
44
|
+
- npm test passe sans erreur
|
|
45
45
|
- npx tsc --noEmit passe sans erreur
|
package/LICENSE
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2026 Patrick Sardinha
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|
package/README.md
CHANGED
|
@@ -1,327 +1,354 @@
|
|
|
1
|
-
#
|
|
2
|
-
|
|
3
|
-
> Bootstrap
|
|
4
|
-
|
|
5
|
-
[](https://www.npmjs.com/package/agentkit-cli)
|
|
6
|
-
[](./LICENSE)
|
|
7
|
-
[](https://claude.ai/code)
|
|
8
|
-
|
|
9
|
-
---
|
|
10
|
-
|
|
11
|
-
## What is AgentKit?
|
|
12
|
-
|
|
13
|
-
When you run `npm create vite@latest`, it scaffolds a complete React
|
|
14
|
-
|
|
15
|
-
**AgentKit does the same thing, but for AI-native development.**
|
|
16
|
-
|
|
17
|
-
It scaffolds the *orchestration layer* that sits on top of any project: the files that tell Claude Code **who** to be, **what** to build,
|
|
18
|
-
|
|
19
|
-
```
|
|
20
|
-
Without AgentKit With AgentKit
|
|
21
|
-
──────────────── ──────────────────────────────
|
|
22
|
-
my-project/ my-project/
|
|
23
|
-
├── src/ ├── src/
|
|
24
|
-
├── package.json ├── package.json
|
|
25
|
-
└── README.md ├── README.md
|
|
26
|
-
├── CLAUDE.md
|
|
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
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
-
|
|
156
|
-
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
##
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
Criteria :
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
Scope :
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
##
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
|
|
278
|
-
|
|
279
|
-
|
|
280
|
-
|
|
281
|
-
|
|
282
|
-
|
|
283
|
-
|
|
284
|
-
|
|
285
|
-
|
|
286
|
-
|
|
287
|
-
|
|
288
|
-
|
|
289
|
-
|
|
290
|
-
|
|
291
|
-
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
|
|
298
|
-
|
|
299
|
-
|
|
300
|
-
|
|
301
|
-
|
|
302
|
-
|
|
303
|
-
|
|
304
|
-
|
|
305
|
-
|
|
306
|
-
|
|
307
|
-
├──
|
|
308
|
-
├──
|
|
309
|
-
|
|
310
|
-
|
|
311
|
-
|
|
312
|
-
|
|
313
|
-
|
|
314
|
-
|
|
315
|
-
|
|
316
|
-
|
|
317
|
-
|
|
318
|
-
|
|
319
|
-
|
|
320
|
-
|
|
321
|
-
|
|
322
|
-
|
|
323
|
-
|
|
324
|
-
|
|
325
|
-
|
|
326
|
-
|
|
327
|
-
|
|
1
|
+
# @patricksardinha/agentkit-cli
|
|
2
|
+
|
|
3
|
+
> Bootstrap any project with an AI-native orchestration layer — like `create vite@latest`, but for agentic development with Claude Code.
|
|
4
|
+
|
|
5
|
+
[](https://www.npmjs.com/package/@patricksardinha/agentkit-cli)
|
|
6
|
+
[](./LICENSE)
|
|
7
|
+
[](https://claude.ai/code)
|
|
8
|
+
|
|
9
|
+
---
|
|
10
|
+
|
|
11
|
+
## What is AgentKit?
|
|
12
|
+
|
|
13
|
+
When you run `npm create vite@latest`, it scaffolds a complete React project in seconds — giving you a working structure you can build on immediately instead of configuring everything from scratch.
|
|
14
|
+
|
|
15
|
+
**AgentKit does the same thing, but for AI-native development.**
|
|
16
|
+
|
|
17
|
+
It scaffolds the *orchestration layer* that sits on top of any project: the files that tell Claude Code **who** to be, **what** to build, **how** to divide the work across specialized agents, and **exactly what to do** — step by step, without you having to prompt each agent manually.
|
|
18
|
+
|
|
19
|
+
```
|
|
20
|
+
Without AgentKit With AgentKit
|
|
21
|
+
──────────────── ──────────────────────────────
|
|
22
|
+
my-project/ my-project/
|
|
23
|
+
├── src/ ├── src/
|
|
24
|
+
├── package.json ├── package.json
|
|
25
|
+
└── README.md ├── README.md
|
|
26
|
+
├── CLAUDE.md ← agent brief
|
|
27
|
+
├── AGENT_WORKFLOW.md ← roadmap
|
|
28
|
+
├── PLAYBOOK.md ← execution guide
|
|
29
|
+
└── agents/ ← per-agent skills
|
|
30
|
+
├── agent-1-infra/
|
|
31
|
+
├── agent-2-auth/
|
|
32
|
+
└── agent-3-features/
|
|
33
|
+
```
|
|
34
|
+
|
|
35
|
+
You open Claude Code, type one instruction, and it runs the entire workflow autonomously.
|
|
36
|
+
|
|
37
|
+
---
|
|
38
|
+
|
|
39
|
+
## The Problem It Solves
|
|
40
|
+
|
|
41
|
+
Most developers using Claude Code today work with a single, long-running conversation. They describe what they want, Claude builds it, they correct, they prompt again. This works — but it has limits:
|
|
42
|
+
|
|
43
|
+
- **Context gets polluted** — one agent accumulates unrelated concerns
|
|
44
|
+
- **No reusability** — you re-explain conventions on every project
|
|
45
|
+
- **No parallelism** — everything is sequential without a coordination layer
|
|
46
|
+
- **No audit trail** — no document captures decisions made
|
|
47
|
+
- **Manual orchestration** — you have to manage agent transitions yourself
|
|
48
|
+
|
|
49
|
+
AgentKit introduces a **structured orchestration layer** that solves all five problems.
|
|
50
|
+
|
|
51
|
+
---
|
|
52
|
+
|
|
53
|
+
## How It Works
|
|
54
|
+
|
|
55
|
+
```
|
|
56
|
+
┌─────────────────────────────────────────────────────────────────┐
|
|
57
|
+
│ Step 1 — You run: npx agentkit init --blueprint BLUEPRINT.md │
|
|
58
|
+
└─────────────────────────┬───────────────────────────────────────┘
|
|
59
|
+
│
|
|
60
|
+
▼
|
|
61
|
+
┌─────────────────────────────────────────────────────────────────┐
|
|
62
|
+
│ AgentKit CLI │
|
|
63
|
+
│ │
|
|
64
|
+
│ 1. Scans the project directory │
|
|
65
|
+
│ → reads package.json, Cargo.toml, requirements.txt… │
|
|
66
|
+
│ │
|
|
67
|
+
│ 2. Detects the stack │
|
|
68
|
+
│ → React · Next.js · Tauri · FastAPI · Express · Node │
|
|
69
|
+
│ → TypeScript? Tailwind? Prisma? Testing setup? │
|
|
70
|
+
│ │
|
|
71
|
+
│ 3. Reads your blueprint (optional) │
|
|
72
|
+
│ → parses features, requirements, architecture notes │
|
|
73
|
+
│ → generates agents tailored to YOUR features │
|
|
74
|
+
│ │
|
|
75
|
+
│ 4. Generates the orchestration layer │
|
|
76
|
+
│ → CLAUDE.md (conventions, stack, rules) │
|
|
77
|
+
│ → AGENT_WORKFLOW.md (agents, scope, dependencies) │
|
|
78
|
+
│ → PLAYBOOK.md (autonomous execution guide) │
|
|
79
|
+
│ → agents/agent-N-*/ (per-agent skills folders) │
|
|
80
|
+
└─────────────────────────┬───────────────────────────────────────┘
|
|
81
|
+
│
|
|
82
|
+
▼
|
|
83
|
+
┌─────────────────────────────────────────────────────────────────┐
|
|
84
|
+
│ Step 2 — You open Claude Code and type ONE instruction: │
|
|
85
|
+
│ │
|
|
86
|
+
│ "Read PLAYBOOK.md and execute the procedure." │
|
|
87
|
+
│ │
|
|
88
|
+
│ Claude Code then runs autonomously: │
|
|
89
|
+
│ │
|
|
90
|
+
│ Agent 1 → Infra & Setup │
|
|
91
|
+
│ runs: npm run build │
|
|
92
|
+
│ ✅ passes → moves to Agent 2 │
|
|
93
|
+
│ ❌ fails → analyzes error, fixes, retries (max 3x) │
|
|
94
|
+
│ ↓ │
|
|
95
|
+
│ Agent 2 → Auth & Data Layer │
|
|
96
|
+
│ runs: npm test │
|
|
97
|
+
│ ✅ passes → moves to Agent 3 │
|
|
98
|
+
│ ↓ │
|
|
99
|
+
│ Agent 3 → Features │
|
|
100
|
+
│ runs: npm test │
|
|
101
|
+
│ ✅ passes → moves to Agent 4 │
|
|
102
|
+
│ ↓ │
|
|
103
|
+
│ Agent 4 → Docs & Deploy │
|
|
104
|
+
│ ✅ 🎉 Workflow complete │
|
|
105
|
+
└─────────────────────────────────────────────────────────────────┘
|
|
106
|
+
```
|
|
107
|
+
|
|
108
|
+
### The generated files
|
|
109
|
+
|
|
110
|
+
**`CLAUDE.md`** — the standing brief for every agent. Covers stack, conventions, forbidden patterns, commands, and definition of done. Read by every agent at the start of their session.
|
|
111
|
+
|
|
112
|
+
**`AGENT_WORKFLOW.md`** — the project roadmap broken into agent-sized tasks. Each entry specifies scope, dependencies, deliverables, and a verifiable success criterion.
|
|
113
|
+
|
|
114
|
+
**`PLAYBOOK.md`** — the key innovation. A single file that Claude Code reads and executes as a complete autonomous workflow. Includes agent prompts, success criteria, retry logic, correction instructions, and human escalation rules. You don't manage agent transitions — Claude Code does.
|
|
115
|
+
|
|
116
|
+
**`agents/agent-N-slug/`** — per-agent skill folders. Drop any `.md` files here (API docs, DB schemas, business conventions) and the relevant agent will read them before starting its work.
|
|
117
|
+
|
|
118
|
+
---
|
|
119
|
+
|
|
120
|
+
## Quickstart
|
|
121
|
+
|
|
122
|
+
```bash
|
|
123
|
+
# In any project directory
|
|
124
|
+
npx @patricksardinha/agentkit-cli init
|
|
125
|
+
|
|
126
|
+
# With a blueprint for feature-specific agents
|
|
127
|
+
npx @patricksardinha/agentkit-cli init --blueprint PROJECT_BLUEPRINT.md
|
|
128
|
+
|
|
129
|
+
# Add a new feature to an existing project
|
|
130
|
+
npx @patricksardinha/agentkit-cli add --feature "add PDF export system"
|
|
131
|
+
|
|
132
|
+
# Check workflow status
|
|
133
|
+
npx @patricksardinha/agentkit-cli status
|
|
134
|
+
```
|
|
135
|
+
|
|
136
|
+
Then open Claude Code and type:
|
|
137
|
+
```
|
|
138
|
+
Read PLAYBOOK.md and execute the procedure.
|
|
139
|
+
```
|
|
140
|
+
|
|
141
|
+
---
|
|
142
|
+
|
|
143
|
+
## The Blueprint File
|
|
144
|
+
|
|
145
|
+
The `--blueprint` flag transforms AgentKit from a generic scaffold tool into a project-specific orchestrator.
|
|
146
|
+
|
|
147
|
+
Without a blueprint, AgentKit generates standard agents based on your stack (Components, Hooks, Pages, Tests for React). With a blueprint, it reads your feature requirements and generates agents tailored to exactly what you want to build.
|
|
148
|
+
|
|
149
|
+
**Example `PROJECT_BLUEPRINT.md`:**
|
|
150
|
+
|
|
151
|
+
```markdown
|
|
152
|
+
# My App — Blueprint
|
|
153
|
+
|
|
154
|
+
## Features
|
|
155
|
+
- Email/password authentication with Supabase
|
|
156
|
+
- Dashboard with D3 charts (revenue, users, conversion)
|
|
157
|
+
- PDF export of reports
|
|
158
|
+
- Dark/light theme
|
|
159
|
+
|
|
160
|
+
## Tech constraints
|
|
161
|
+
- Must work offline (IndexedDB for local data)
|
|
162
|
+
- Tauri desktop build for Windows
|
|
163
|
+
- French and English i18n
|
|
164
|
+
|
|
165
|
+
## Architecture notes
|
|
166
|
+
- Supabase for auth + reference data
|
|
167
|
+
- Dexie for local user data
|
|
168
|
+
- No Redux — Context API only
|
|
169
|
+
```
|
|
170
|
+
|
|
171
|
+
**What AgentKit generates from this blueprint:**
|
|
172
|
+
|
|
173
|
+
```markdown
|
|
174
|
+
## Agent 1 · Infra & Tauri Setup
|
|
175
|
+
Scope : Vite + React + Tauri + Tailwind, i18n config
|
|
176
|
+
Criteria : npm run dev opens without error
|
|
177
|
+
|
|
178
|
+
## Agent 2 · Auth & Supabase
|
|
179
|
+
Scope : Supabase client, email/password auth, bypass mode
|
|
180
|
+
Criteria : login/logout functional, npm test passes
|
|
181
|
+
|
|
182
|
+
## Agent 3 · Local Data Layer
|
|
183
|
+
Scope : Dexie schema, sync service, offline support
|
|
184
|
+
Criteria : useLiveQuery returns data, npm test passes
|
|
185
|
+
|
|
186
|
+
## Agent 4 · Dashboard & D3 Charts
|
|
187
|
+
Scope : chart components, data hooks, mock data
|
|
188
|
+
Criteria : charts render, npm test passes
|
|
189
|
+
|
|
190
|
+
## Agent 5 · PDF Export
|
|
191
|
+
Scope : PDF generation from dashboard data
|
|
192
|
+
Criteria : export produces valid PDF, npm test passes
|
|
193
|
+
|
|
194
|
+
## Agent 6 · Desktop & CI/CD
|
|
195
|
+
Scope : Tauri build, GitHub Actions, release workflow
|
|
196
|
+
Criteria : npm run tauri:build produces installer
|
|
197
|
+
```
|
|
198
|
+
|
|
199
|
+
---
|
|
200
|
+
|
|
201
|
+
## Per-Agent Skills
|
|
202
|
+
|
|
203
|
+
Each agent gets its own folder under `agents/`. Drop any `.md` files there — API documentation, database schemas, business conventions, examples — and the agent reads them before starting.
|
|
204
|
+
|
|
205
|
+
```
|
|
206
|
+
agents/
|
|
207
|
+
├── agent-2-auth/
|
|
208
|
+
│ ├── skills.md ← auto-generated template
|
|
209
|
+
│ └── supabase-schema.md ← you add this: your actual DB schema
|
|
210
|
+
├── agent-4-dashboard/
|
|
211
|
+
│ ├── skills.md
|
|
212
|
+
│ └── chart-specs.md ← you add this: exact chart requirements
|
|
213
|
+
```
|
|
214
|
+
|
|
215
|
+
The `skills.md` template generated by AgentKit:
|
|
216
|
+
|
|
217
|
+
```markdown
|
|
218
|
+
# Skills — Agent 2 · Auth & Supabase
|
|
219
|
+
|
|
220
|
+
> This file is read by Agent 2 before starting its work.
|
|
221
|
+
> Fill in what's relevant for your project.
|
|
222
|
+
|
|
223
|
+
## Technical context (fill in)
|
|
224
|
+
- Supabase URL :
|
|
225
|
+
- Tables involved :
|
|
226
|
+
- Expected RLS :
|
|
227
|
+
|
|
228
|
+
## Reference documentation (optional)
|
|
229
|
+
<!-- paste API docs, schemas, examples here -->
|
|
230
|
+
|
|
231
|
+
## Project-specific conventions (optional)
|
|
232
|
+
<!-- e.g. "always use useSession(), never useUser()" -->
|
|
233
|
+
```
|
|
234
|
+
|
|
235
|
+
---
|
|
236
|
+
|
|
237
|
+
## Handling Future Iterations
|
|
238
|
+
|
|
239
|
+
When you want to add a feature to an already-built project:
|
|
240
|
+
|
|
241
|
+
```bash
|
|
242
|
+
npx @patricksardinha/agentkit-cli add --feature "add CSV export to the dashboard"
|
|
243
|
+
```
|
|
244
|
+
|
|
245
|
+
AgentKit:
|
|
246
|
+
1. Reads your existing `AGENT_WORKFLOW.md` to find the last agent number
|
|
247
|
+
2. Appends a new agent block scoped to the new feature
|
|
248
|
+
3. Creates `agents/agent-N-csv-export/skills.md`
|
|
249
|
+
4. Regenerates `PLAYBOOK.md` with the new agent included
|
|
250
|
+
|
|
251
|
+
Then in Claude Code:
|
|
252
|
+
```
|
|
253
|
+
Read PLAYBOOK.md and execute only the agents that haven't been completed yet.
|
|
254
|
+
```
|
|
255
|
+
|
|
256
|
+
---
|
|
257
|
+
|
|
258
|
+
## Supported Stacks
|
|
259
|
+
|
|
260
|
+
| Stack | Detected by | Template enrichment |
|
|
261
|
+
|---|---|---|
|
|
262
|
+
| **React** | `react` in `package.json` | TypeScript/JS, Vite, testing |
|
|
263
|
+
| **Next.js** | `next` in `package.json` | App Router, Tailwind, Prisma |
|
|
264
|
+
| **Tauri** | `src-tauri/` directory | Rust/JS boundary, IPC, plugins |
|
|
265
|
+
| **FastAPI** | `fastapi` in `requirements.txt` | Python, Pydantic, async |
|
|
266
|
+
| **Express** | `express` in `package.json` | REST, middleware, auth |
|
|
267
|
+
| **Node.js** | `package.json` (generic) | Scripts, modules, CI/CD |
|
|
268
|
+
| **Unknown** | fallback | Generic editable workflow |
|
|
269
|
+
|
|
270
|
+
Stack detection is additive — TypeScript, Tailwind, Prisma, and testing setup are detected on top of the primary framework and enrich all generated files accordingly.
|
|
271
|
+
|
|
272
|
+
---
|
|
273
|
+
|
|
274
|
+
## Design Philosophy
|
|
275
|
+
|
|
276
|
+
### Why a PLAYBOOK.md instead of manual prompting?
|
|
277
|
+
|
|
278
|
+
Without AgentKit, a developer using Claude Code has to write a prompt for Agent 1, wait and validate, write a prompt for Agent 2, handle failures manually, and repeat for every agent. With `PLAYBOOK.md`, you write one instruction. Claude Code handles agent transitions, validates success criteria, retries on failure, and asks for human input only when genuinely blocked.
|
|
279
|
+
|
|
280
|
+
### Why per-agent skills instead of one big context?
|
|
281
|
+
|
|
282
|
+
Each agent should only know what it needs. An infrastructure agent doesn't need your business logic conventions. A features agent doesn't need your CI/CD configuration. Bounded context produces better output and prevents agents from making decisions outside their scope.
|
|
283
|
+
|
|
284
|
+
### Why verifiable success criteria?
|
|
285
|
+
|
|
286
|
+
Every agent ends with a runnable check (`npm test`, `cargo build`, `npm run build`). These aren't goals — they're gates. The PLAYBOOK enforces them. You always know exactly which agents have succeeded and which haven't.
|
|
287
|
+
|
|
288
|
+
---
|
|
289
|
+
|
|
290
|
+
## Meta: AgentKit Was Built With AgentKit
|
|
291
|
+
|
|
292
|
+
This CLI was built using the exact workflow it generates. The `CLAUDE.md`, `AGENT_WORKFLOW.md`, and `PLAYBOOK.md` at the root of this repo drove the entire build process — written first, executed against, not added after the fact.
|
|
293
|
+
|
|
294
|
+
```
|
|
295
|
+
Agent 1 · Infra & Setup → success: npm run build passes
|
|
296
|
+
Agent 2 · Detectors → success: npm test passes on fixtures
|
|
297
|
+
Agent 3 · Generators → success: valid files for each stack
|
|
298
|
+
Agent 4 · Commands CLI → success: npx agentkit --help works
|
|
299
|
+
```
|
|
300
|
+
|
|
301
|
+
---
|
|
302
|
+
|
|
303
|
+
## Project Structure
|
|
304
|
+
|
|
305
|
+
```
|
|
306
|
+
agentkit-cli/
|
|
307
|
+
├── src/
|
|
308
|
+
│ ├── cli.ts
|
|
309
|
+
│ ├── commands/
|
|
310
|
+
│ │ ├── init.ts ← npx agentkit init [--blueprint]
|
|
311
|
+
│ │ ├── add.ts ← npx agentkit add --feature
|
|
312
|
+
│ │ └── status.ts ← npx agentkit status
|
|
313
|
+
│ ├── detectors/
|
|
314
|
+
│ │ ├── stackDetector.ts
|
|
315
|
+
│ │ └── gitDetector.ts
|
|
316
|
+
│ ├── generators/
|
|
317
|
+
│ │ ├── claudeMdGenerator.ts
|
|
318
|
+
│ │ ├── workflowGenerator.ts
|
|
319
|
+
│ │ ├── playbookGenerator.ts ← PLAYBOOK.md with full exec logic
|
|
320
|
+
│ │ └── skillsGenerator.ts ← agents/agent-N-slug/ folders
|
|
321
|
+
│ ├── templates/
|
|
322
|
+
│ │ ├── react.ts
|
|
323
|
+
│ │ ├── nextjs.ts
|
|
324
|
+
│ │ ├── tauri.ts
|
|
325
|
+
│ │ ├── fastapi.ts
|
|
326
|
+
│ │ ├── express.ts
|
|
327
|
+
│ │ ├── node.ts
|
|
328
|
+
│ │ └── unknown.ts
|
|
329
|
+
│ └── utils/
|
|
330
|
+
│ └── logger.ts
|
|
331
|
+
├── tests/
|
|
332
|
+
├── CLAUDE.md
|
|
333
|
+
├── AGENT_WORKFLOW.md
|
|
334
|
+
├── PLAYBOOK.md
|
|
335
|
+
├── package.json
|
|
336
|
+
└── tsup.config.ts
|
|
337
|
+
```
|
|
338
|
+
|
|
339
|
+
---
|
|
340
|
+
|
|
341
|
+
## Contributing
|
|
342
|
+
|
|
343
|
+
To add a new stack template:
|
|
344
|
+
|
|
345
|
+
1. Create `src/templates/your-stack.ts` — export `claudeMd(stack)` and `workflow(stack)`
|
|
346
|
+
2. Add detection in `src/detectors/stackDetector.ts`
|
|
347
|
+
3. Register in both generators
|
|
348
|
+
4. Add fixtures in `tests/detectors/` and tests in `tests/generators/`
|
|
349
|
+
|
|
350
|
+
---
|
|
351
|
+
|
|
352
|
+
## License
|
|
353
|
+
|
|
354
|
+
MIT — © 2026 Patrick Sardinha
|
package/dist/cli.cjs
CHANGED
|
File without changes
|
package/dist/cli.js
CHANGED
|
File without changes
|