create-byan-agent 1.1.2 โ 1.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/CHANGELOG.md +250 -177
- package/LICENSE +21 -21
- package/README.md +1245 -421
- package/bin/create-byan-agent-backup.js +220 -220
- package/bin/create-byan-agent-fixed.js +301 -301
- package/bin/create-byan-agent.js +322 -301
- package/lib/errors.js +61 -0
- package/lib/exit-codes.js +54 -0
- package/lib/platforms/claude-code.js +113 -0
- package/lib/platforms/codex.js +92 -0
- package/lib/platforms/copilot-cli.js +123 -0
- package/lib/platforms/index.js +14 -0
- package/lib/platforms/vscode.js +51 -0
- package/lib/utils/config-loader.js +79 -0
- package/lib/utils/file-utils.js +104 -0
- package/lib/utils/git-detector.js +35 -0
- package/lib/utils/logger.js +64 -0
- package/lib/utils/node-detector.js +58 -0
- package/lib/utils/os-detector.js +74 -0
- package/lib/utils/yaml-utils.js +87 -0
- package/lib/yanstaller/backuper.js +308 -0
- package/lib/yanstaller/detector.js +141 -0
- package/lib/yanstaller/index.js +93 -0
- package/lib/yanstaller/installer.js +225 -0
- package/lib/yanstaller/interviewer.js +250 -0
- package/lib/yanstaller/recommender.js +298 -0
- package/lib/yanstaller/troubleshooter.js +498 -0
- package/lib/yanstaller/validator.js +578 -0
- package/lib/yanstaller/wizard.js +211 -0
- package/package.json +61 -55
- package/templates/.github/agents/bmad-agent-bmad-master.md +15 -15
- package/templates/.github/agents/bmad-agent-bmb-agent-builder.md +15 -15
- package/templates/.github/agents/bmad-agent-bmb-module-builder.md +15 -15
- package/templates/.github/agents/bmad-agent-bmb-workflow-builder.md +15 -15
- package/templates/.github/agents/bmad-agent-bmm-analyst.md +15 -15
- package/templates/.github/agents/bmad-agent-bmm-architect.md +15 -15
- package/templates/.github/agents/bmad-agent-bmm-dev.md +15 -15
- package/templates/.github/agents/bmad-agent-bmm-pm.md +15 -15
- package/templates/.github/agents/bmad-agent-bmm-quick-flow-solo-dev.md +15 -15
- package/templates/.github/agents/bmad-agent-bmm-quinn.md +15 -15
- package/templates/.github/agents/bmad-agent-bmm-sm.md +15 -15
- package/templates/.github/agents/bmad-agent-bmm-tech-writer.md +15 -15
- package/templates/.github/agents/bmad-agent-bmm-ux-designer.md +15 -15
- package/templates/.github/agents/bmad-agent-byan-test.md +32 -0
- package/templates/.github/agents/bmad-agent-byan.md +224 -224
- package/templates/.github/agents/bmad-agent-carmack.md +18 -0
- package/templates/.github/agents/bmad-agent-cis-brainstorming-coach.md +15 -15
- package/templates/.github/agents/bmad-agent-cis-creative-problem-solver.md +15 -15
- package/templates/.github/agents/bmad-agent-cis-design-thinking-coach.md +15 -15
- package/templates/.github/agents/bmad-agent-cis-innovation-strategist.md +15 -15
- package/templates/.github/agents/bmad-agent-cis-presentation-master.md +15 -15
- package/templates/.github/agents/bmad-agent-cis-storyteller.md +15 -15
- package/templates/.github/agents/bmad-agent-marc.md +48 -48
- package/templates/.github/agents/bmad-agent-patnote.md +48 -0
- package/templates/.github/agents/bmad-agent-rachid.md +47 -47
- package/templates/.github/agents/bmad-agent-tea-tea.md +15 -15
- package/templates/.github/agents/bmad-agent-test-dynamic.md +21 -0
- package/templates/.github/agents/expert-merise-agile.md +1 -0
- package/templates/.github/agents/franck.md +379 -0
- package/templates/_bmad/bmb/agents/agent-builder.md +59 -59
- package/templates/_bmad/bmb/agents/byan-test.md +116 -116
- package/templates/_bmad/bmb/agents/byan.md +215 -215
- package/templates/_bmad/bmb/agents/marc.md +303 -303
- package/templates/_bmad/bmb/agents/module-builder.md +60 -60
- package/templates/_bmad/bmb/agents/patnote.md +495 -495
- package/templates/_bmad/bmb/agents/rachid.md +184 -184
- package/templates/_bmad/bmb/agents/workflow-builder.md +61 -61
- package/templates/_bmad/bmb/workflows/byan/data/mantras.yaml +272 -272
- package/templates/_bmad/bmb/workflows/byan/data/templates.yaml +59 -59
- package/templates/_bmad/bmb/workflows/byan/delete-agent-workflow.md +657 -657
- package/templates/_bmad/bmb/workflows/byan/edit-agent-workflow.md +688 -688
- package/templates/_bmad/bmb/workflows/byan/interview-workflow.md +753 -753
- package/templates/_bmad/bmb/workflows/byan/quick-create-workflow.md +450 -450
- package/templates/_bmad/bmb/workflows/byan/templates/base-agent-template.md +79 -79
- package/templates/_bmad/bmb/workflows/byan/validate-agent-workflow.md +676 -676
- package/templates/_bmad/core/agents/carmack.md +238 -238
package/README.md
CHANGED
|
@@ -1,421 +1,1245 @@
|
|
|
1
|
-
#
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
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
|
-
|
|
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
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
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
|
-
|
|
328
|
-
|
|
329
|
-
|
|
330
|
-
-
|
|
331
|
-
-
|
|
332
|
-
|
|
333
|
-
|
|
334
|
-
|
|
335
|
-
|
|
336
|
-
|
|
337
|
-
|
|
338
|
-
|
|
339
|
-
|
|
340
|
-
|
|
341
|
-
|
|
342
|
-
|
|
343
|
-
|
|
344
|
-
|
|
345
|
-
|
|
346
|
-
|
|
347
|
-
|
|
348
|
-
|
|
349
|
-
|
|
350
|
-
|
|
351
|
-
|
|
352
|
-
|
|
353
|
-
|
|
354
|
-
|
|
355
|
-
|
|
356
|
-
|
|
357
|
-
|
|
358
|
-
|
|
359
|
-
|
|
360
|
-
|
|
361
|
-
|
|
362
|
-
|
|
363
|
-
|
|
364
|
-
|
|
365
|
-
|
|
366
|
-
|
|
367
|
-
|
|
368
|
-
|
|
369
|
-
|
|
370
|
-
|
|
371
|
-
|
|
372
|
-
|
|
373
|
-
|
|
374
|
-
|
|
375
|
-
|
|
376
|
-
|
|
377
|
-
|
|
378
|
-
|
|
379
|
-
|
|
380
|
-
|
|
381
|
-
|
|
382
|
-
|
|
383
|
-
|
|
384
|
-
|
|
385
|
-
|
|
386
|
-
|
|
387
|
-
|
|
388
|
-
|
|
389
|
-
|
|
390
|
-
|
|
391
|
-
|
|
392
|
-
|
|
393
|
-
|
|
394
|
-
|
|
395
|
-
|
|
396
|
-
|
|
397
|
-
|
|
398
|
-
|
|
399
|
-
|
|
400
|
-
|
|
401
|
-
|
|
402
|
-
|
|
403
|
-
|
|
404
|
-
|
|
405
|
-
|
|
406
|
-
|
|
407
|
-
|
|
408
|
-
|
|
409
|
-
|
|
410
|
-
|
|
411
|
-
|
|
412
|
-
|
|
413
|
-
|
|
414
|
-
|
|
415
|
-
|
|
416
|
-
|
|
417
|
-
|
|
418
|
-
|
|
419
|
-
|
|
420
|
-
|
|
421
|
-
|
|
1
|
+
# ๐๏ธ YANSTALLER - Intelligent BYAN Installer
|
|
2
|
+
|
|
3
|
+
[](https://www.npmjs.com/package/create-byan-agent)
|
|
4
|
+
[](LICENSE)
|
|
5
|
+
[](https://nodejs.org)
|
|
6
|
+
[](#tests)
|
|
7
|
+
|
|
8
|
+
**YANSTALLER** est l'installateur intelligent pour l'รฉcosystรจme **BYAN** (Builder of YAN). Il dรฉtecte automatiquement votre environnement de dรฉveloppement, recommande les agents appropriรฉs, et les installe avec support multi-plateforme.
|
|
9
|
+
|
|
10
|
+
**Mรฉthodologie :** Merise Agile + TDD + 64 Mantras
|
|
11
|
+
**Langues :** ๐ซ๐ท Franรงais | ๐ฌ๐ง English ([See below](#english-version))
|
|
12
|
+
|
|
13
|
+
---
|
|
14
|
+
|
|
15
|
+
## ๐ Table des matiรจres
|
|
16
|
+
|
|
17
|
+
1. [Fonctionnalitรฉs](#-fonctionnalitรฉs)
|
|
18
|
+
2. [Installation](#-installation-rapide)
|
|
19
|
+
3. [Utilisation](#-utilisation)
|
|
20
|
+
4. [Architecture](#-architecture)
|
|
21
|
+
5. [Modules](#-modules)
|
|
22
|
+
6. [API](#-api-reference)
|
|
23
|
+
7. [Tests](#-tests)
|
|
24
|
+
8. [Dรฉveloppement](#-dรฉveloppement)
|
|
25
|
+
9. [Contributing](#-contributing)
|
|
26
|
+
10. [License](#-license)
|
|
27
|
+
|
|
28
|
+
---
|
|
29
|
+
|
|
30
|
+
## โจ Fonctionnalitรฉs
|
|
31
|
+
|
|
32
|
+
### ๐ฏ Intelligence de Dรฉtection
|
|
33
|
+
- โ
**Dรฉtection automatique** des plateformes (GitHub Copilot CLI, VSCode, Claude Code, Codex)
|
|
34
|
+
- โ
**Analyse du projet** via `package.json` (20+ frameworks reconnus)
|
|
35
|
+
- โ
**Recommandations contextuelles** d'agents basรฉes sur votre stack
|
|
36
|
+
|
|
37
|
+
### ๐ค Agents Disponibles (29 agents)
|
|
38
|
+
- **BMB (Meta):** BYAN, BYAN-Test, RACHID, MARC, PATNOTE, CARMACK, Agent-Builder, Module-Builder, Workflow-Builder
|
|
39
|
+
- **BMM (SDLC):** Analyst, PM, Architect, Dev, SM, Quinn, UX-Designer, Tech-Writer, Quick-Flow-Solo-Dev
|
|
40
|
+
- **TEA (Tests):** TEA (Test Architecture Expert)
|
|
41
|
+
- **CIS (Innovation):** Brainstorming-Coach, Design-Thinking-Coach, Creative-Problem-Solver, Innovation-Strategist, Presentation-Master, Storyteller
|
|
42
|
+
- **Core:** Party-Mode, BMAD-Master
|
|
43
|
+
|
|
44
|
+
### ๐ Installation Intelligente
|
|
45
|
+
- โ
**Structure BMAD complรจte** (19 rรฉpertoires crรฉรฉs automatiquement)
|
|
46
|
+
- โ
**Configuration YAML** gรฉnรฉrรฉe avec mรฉtadonnรฉes
|
|
47
|
+
- โ
**Stubs multi-plateformes** (Copilot CLI, VSCode, Claude Code, Codex)
|
|
48
|
+
- โ
**MCP Server setup** pour Claude Code
|
|
49
|
+
- โ
**Manifests CSV** pour tracking des agents
|
|
50
|
+
|
|
51
|
+
### ๐ Validation Automatique (10 checks)
|
|
52
|
+
- Vรฉrification structure `_bmad/`
|
|
53
|
+
- Validation fichiers agents
|
|
54
|
+
- Check YAML frontmatter
|
|
55
|
+
- Validation permissions
|
|
56
|
+
- Vรฉrification dรฉpendances npm
|
|
57
|
+
- Tests manifests, workflows, templates
|
|
58
|
+
|
|
59
|
+
### ๐ ๏ธ Troubleshooting Intelligent
|
|
60
|
+
- โ
**8 patterns d'erreurs** reconnus automatiquement
|
|
61
|
+
- โ
**Auto-fix** pour permissions, structure corrompue, dรฉpendances
|
|
62
|
+
- โ
**Diagnostics contextuels** (Node version, Git, espace disque)
|
|
63
|
+
- โ
**Suggestions d'upgrade** OS-spรฉcifiques
|
|
64
|
+
|
|
65
|
+
### ๐พ Backup & Rollback
|
|
66
|
+
- โ
**Sauvegarde automatique** avant installation
|
|
67
|
+
- โ
**Mรฉtadonnรฉes** (timestamp, taille, fichiers)
|
|
68
|
+
- โ
**Restore sรฉcurisรฉ** avec pre-restore backup
|
|
69
|
+
- โ
**Nettoyage automatique** des anciens backups
|
|
70
|
+
|
|
71
|
+
### ๐ง Wizard Post-Installation
|
|
72
|
+
- โ
**Interview en 7 questions** (<5 min)
|
|
73
|
+
- โ
**Mode conversationnel** avec inquirer
|
|
74
|
+
- โ
**4 options post-install** : crรฉer agent, tester, docs, exit
|
|
75
|
+
- โ
**Guide quick-start** interactif
|
|
76
|
+
|
|
77
|
+
---
|
|
78
|
+
|
|
79
|
+
## ๐ Installation Rapide
|
|
80
|
+
|
|
81
|
+
### Prรฉrequis
|
|
82
|
+
- **Node.js** โฅ 18.0.0
|
|
83
|
+
- **Git** installรฉ
|
|
84
|
+
- Au moins **1 plateforme** : GitHub Copilot CLI, VSCode, Claude Code, ou Codex
|
|
85
|
+
|
|
86
|
+
### Via NPX (recommandรฉ)
|
|
87
|
+
```bash
|
|
88
|
+
# Installation interactive
|
|
89
|
+
npx create-byan-agent
|
|
90
|
+
|
|
91
|
+
# Suivre l'interview en 7 questions (5 min)
|
|
92
|
+
```
|
|
93
|
+
|
|
94
|
+
### Via NPM Global
|
|
95
|
+
```bash
|
|
96
|
+
# Installer globalement
|
|
97
|
+
npm install -g create-byan-agent
|
|
98
|
+
|
|
99
|
+
# Exรฉcuter
|
|
100
|
+
create-byan-agent
|
|
101
|
+
```
|
|
102
|
+
|
|
103
|
+
### Installation Manuelle
|
|
104
|
+
```bash
|
|
105
|
+
# Cloner le dรฉpรดt
|
|
106
|
+
git clone https://github.com/Yan-Acadenice/BYAN.git
|
|
107
|
+
cd BYAN/install
|
|
108
|
+
|
|
109
|
+
# Installer les dรฉpendances
|
|
110
|
+
npm install
|
|
111
|
+
|
|
112
|
+
# Lancer l'installateur
|
|
113
|
+
npm start
|
|
114
|
+
```
|
|
115
|
+
|
|
116
|
+
---
|
|
117
|
+
|
|
118
|
+
## ๐ฎ Utilisation
|
|
119
|
+
|
|
120
|
+
### Mode Interview (Recommandรฉ)
|
|
121
|
+
```bash
|
|
122
|
+
npx create-byan-agent
|
|
123
|
+
```
|
|
124
|
+
|
|
125
|
+
**7 questions interactives :**
|
|
126
|
+
1. Votre nom (pour configuration personnalisรฉe)
|
|
127
|
+
2. Langue de communication (Franรงais/English)
|
|
128
|
+
3. Mode d'installation (Recommandรฉ/Custom/Minimal/Full)
|
|
129
|
+
4. Sรฉlection agents (si Custom)
|
|
130
|
+
5. Plateformes cibles (Copilot/VSCode/Claude/Codex)
|
|
131
|
+
6. Installation agent exemple (oui/non)
|
|
132
|
+
7. Crรฉer backup (oui/non)
|
|
133
|
+
|
|
134
|
+
### Mode Programmatique
|
|
135
|
+
|
|
136
|
+
#### API JavaScript
|
|
137
|
+
```javascript
|
|
138
|
+
const yanstaller = require('create-byan-agent');
|
|
139
|
+
|
|
140
|
+
// Dรฉtection
|
|
141
|
+
const detection = await yanstaller.detect({
|
|
142
|
+
projectRoot: process.cwd()
|
|
143
|
+
});
|
|
144
|
+
console.log(detection.platforms); // ['copilot-cli', 'vscode']
|
|
145
|
+
|
|
146
|
+
// Recommandation
|
|
147
|
+
const recommendations = await yanstaller.recommend({
|
|
148
|
+
projectRoot: process.cwd(),
|
|
149
|
+
detection
|
|
150
|
+
});
|
|
151
|
+
console.log(recommendations.agents); // ['dev', 'architect', 'quinn']
|
|
152
|
+
|
|
153
|
+
// Installation
|
|
154
|
+
const result = await yanstaller.install({
|
|
155
|
+
projectRoot: process.cwd(),
|
|
156
|
+
agents: ['byan', 'dev', 'quinn'],
|
|
157
|
+
platforms: ['copilot-cli', 'vscode'],
|
|
158
|
+
userName: 'Yan',
|
|
159
|
+
language: 'Francais'
|
|
160
|
+
});
|
|
161
|
+
|
|
162
|
+
// Validation
|
|
163
|
+
const validation = await yanstaller.validate({
|
|
164
|
+
projectRoot: process.cwd()
|
|
165
|
+
});
|
|
166
|
+
console.log(validation.errors); // []
|
|
167
|
+
```
|
|
168
|
+
|
|
169
|
+
#### CLI Options
|
|
170
|
+
```bash
|
|
171
|
+
# Installation silencieuse avec agents spรฉcifiques
|
|
172
|
+
create-byan-agent --silent --agents=byan,dev,quinn
|
|
173
|
+
|
|
174
|
+
# Mode custom avec plateforme spรฉcifique
|
|
175
|
+
create-byan-agent --mode=custom --platforms=copilot-cli
|
|
176
|
+
|
|
177
|
+
# Installation complรจte sans backup
|
|
178
|
+
create-byan-agent --mode=full --no-backup
|
|
179
|
+
|
|
180
|
+
# Dry-run (simulation)
|
|
181
|
+
create-byan-agent --dry-run
|
|
182
|
+
|
|
183
|
+
# Verbose logging
|
|
184
|
+
create-byan-agent --verbose
|
|
185
|
+
```
|
|
186
|
+
|
|
187
|
+
---
|
|
188
|
+
|
|
189
|
+
## ๐๏ธ Architecture
|
|
190
|
+
|
|
191
|
+
### Structure du Projet
|
|
192
|
+
```
|
|
193
|
+
install/
|
|
194
|
+
โโโ bin/
|
|
195
|
+
โ โโโ create-byan-agent.js # CLI entry point
|
|
196
|
+
โโโ lib/
|
|
197
|
+
โ โโโ yanstaller/ # Core modules
|
|
198
|
+
โ โ โโโ detector.js # Platform & project detection
|
|
199
|
+
โ โ โโโ recommender.js # Agent recommendations
|
|
200
|
+
โ โ โโโ installer.js # Installation orchestration
|
|
201
|
+
โ โ โโโ validator.js # Post-install validation
|
|
202
|
+
โ โ โโโ troubleshooter.js # Error diagnosis & auto-fix
|
|
203
|
+
โ โ โโโ backuper.js # Backup & restore
|
|
204
|
+
โ โ โโโ interviewer.js # Interactive interview
|
|
205
|
+
โ โ โโโ wizard.js # Post-install wizard
|
|
206
|
+
โ โโโ platforms/ # Platform adapters
|
|
207
|
+
โ โ โโโ copilot-cli.js # GitHub Copilot CLI
|
|
208
|
+
โ โ โโโ vscode.js # VSCode extension
|
|
209
|
+
โ โ โโโ claude-code.js # Claude Code MCP
|
|
210
|
+
โ โ โโโ codex.js # Codex platform
|
|
211
|
+
โ โโโ utils/ # Utilities
|
|
212
|
+
โ โ โโโ file-utils.js # File operations
|
|
213
|
+
โ โ โโโ logger.js # Logging system
|
|
214
|
+
โ โ โโโ yaml-utils.js # YAML parsing
|
|
215
|
+
โ โโโ errors.js # Error definitions
|
|
216
|
+
โ โโโ exit-codes.js # Exit code constants
|
|
217
|
+
โโโ templates/ # Agent templates
|
|
218
|
+
โ โโโ _bmad/
|
|
219
|
+
โ โโโ core/agents/
|
|
220
|
+
โ โโโ bmm/agents/
|
|
221
|
+
โ โโโ bmb/agents/
|
|
222
|
+
โ โโโ tea/agents/
|
|
223
|
+
โ โโโ cis/agents/
|
|
224
|
+
โโโ __tests__/ # Test suite (168 tests)
|
|
225
|
+
โ โโโ recommender.test.js
|
|
226
|
+
โ โโโ installer.test.js
|
|
227
|
+
โ โโโ validator.test.js
|
|
228
|
+
โ โโโ troubleshooter.test.js
|
|
229
|
+
โ โโโ backuper.test.js
|
|
230
|
+
โ โโโ integration.test.js
|
|
231
|
+
โ โโโ e2e.test.js
|
|
232
|
+
โ โโโ ...
|
|
233
|
+
โโโ package.json
|
|
234
|
+
```
|
|
235
|
+
|
|
236
|
+
### Flux d'Installation
|
|
237
|
+
|
|
238
|
+
```
|
|
239
|
+
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
|
|
240
|
+
โ 1. DETECT - Platform & Project Analysis โ
|
|
241
|
+
โ โข Scan for Copilot CLI, VSCode, Claude, Codex โ
|
|
242
|
+
โ โข Analyze package.json dependencies โ
|
|
243
|
+
โ โข Detect project type & framework โ
|
|
244
|
+
โโโโโโโโโโโโโโโโโโโโโโฌโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
|
|
245
|
+
โ
|
|
246
|
+
โผ
|
|
247
|
+
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
|
|
248
|
+
โ 2. RECOMMEND - Intelligent Agent Selection โ
|
|
249
|
+
โ โข Match agents to project type โ
|
|
250
|
+
โ โข Consider detected platforms โ
|
|
251
|
+
โ โข Generate rationale for each recommendation โ
|
|
252
|
+
โโโโโโโโโโโโโโโโโโโโโโฌโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
|
|
253
|
+
โ
|
|
254
|
+
โผ
|
|
255
|
+
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
|
|
256
|
+
โ 3. INTERVIEW - User Preferences (7 questions) โ
|
|
257
|
+
โ โข Name, language, mode โ
|
|
258
|
+
โ โข Agent selection (if custom) โ
|
|
259
|
+
โ โข Platform targets, backup option โ
|
|
260
|
+
โโโโโโโโโโโโโโโโโโโโโโฌโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
|
|
261
|
+
โ
|
|
262
|
+
โผ
|
|
263
|
+
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
|
|
264
|
+
โ 4. BACKUP - Pre-install Safety (optional) โ
|
|
265
|
+
โ โข Create timestamped backup of _bmad/ โ
|
|
266
|
+
โ โข Save metadata (files, size, version) โ
|
|
267
|
+
โโโโโโโโโโโโโโโโโโโโโโฌโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
|
|
268
|
+
โ
|
|
269
|
+
โผ
|
|
270
|
+
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
|
|
271
|
+
โ 5. INSTALL - Core Installation โ
|
|
272
|
+
โ โข Create _bmad/ structure (19 directories) โ
|
|
273
|
+
โ โข Copy agent templates from 5 modules โ
|
|
274
|
+
โ โข Generate platform stubs (Copilot/VSCode/etc.) โ
|
|
275
|
+
โ โข Create module configs (YAML with metadata) โ
|
|
276
|
+
โ โข Update manifests (agent-manifest.csv) โ
|
|
277
|
+
โโโโโโโโโโโโโโโโโโโโโโฌโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
|
|
278
|
+
โ
|
|
279
|
+
โผ
|
|
280
|
+
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
|
|
281
|
+
โ 6. VALIDATE - 10 Automated Checks โ
|
|
282
|
+
โ โข Structure, agents, stubs, configs โ
|
|
283
|
+
โ โข Permissions, manifests, workflows โ
|
|
284
|
+
โ โข Templates, dependencies โ
|
|
285
|
+
โโโโโโโโโโโโโโโโโโโโโโฌโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
|
|
286
|
+
โ
|
|
287
|
+
โผ
|
|
288
|
+
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
|
|
289
|
+
โ 7. WIZARD - Post-Install Actions โ
|
|
290
|
+
โ โข Summary of installed agents โ
|
|
291
|
+
โ โข Option: Create new agent (launch BYAN) โ
|
|
292
|
+
โ โข Option: Test agent โ
|
|
293
|
+
โ โข Option: View documentation โ
|
|
294
|
+
โ โข Quick start guide โ
|
|
295
|
+
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
|
|
296
|
+
```
|
|
297
|
+
|
|
298
|
+
---
|
|
299
|
+
|
|
300
|
+
## ๐ฆ Modules
|
|
301
|
+
|
|
302
|
+
### 1. Detector
|
|
303
|
+
**Fichier :** `lib/yanstaller/detector.js`
|
|
304
|
+
|
|
305
|
+
**Fonction :** Dรฉtecte les plateformes installรฉes et analyse le projet.
|
|
306
|
+
|
|
307
|
+
**API :**
|
|
308
|
+
```javascript
|
|
309
|
+
const detector = require('./lib/yanstaller/detector');
|
|
310
|
+
|
|
311
|
+
// Dรฉtection complรจte
|
|
312
|
+
const detection = await detector.detect({
|
|
313
|
+
projectRoot: '/path/to/project'
|
|
314
|
+
});
|
|
315
|
+
|
|
316
|
+
/* Retour :
|
|
317
|
+
{
|
|
318
|
+
platforms: ['copilot-cli', 'vscode'],
|
|
319
|
+
projectType: 'frontend',
|
|
320
|
+
framework: 'react',
|
|
321
|
+
dependencies: { react: '^18.2.0', ... },
|
|
322
|
+
hasGit: true,
|
|
323
|
+
hasNpm: true
|
|
324
|
+
}
|
|
325
|
+
*/
|
|
326
|
+
```
|
|
327
|
+
|
|
328
|
+
**Mรฉthodes :**
|
|
329
|
+
- `detect(options)` - Dรฉtection complรจte
|
|
330
|
+
- `detectPlatforms()` - Scan plateformes disponibles
|
|
331
|
+
- `analyzeProject(projectRoot)` - Analyse `package.json`
|
|
332
|
+
|
|
333
|
+
---
|
|
334
|
+
|
|
335
|
+
### 2. Recommender
|
|
336
|
+
**Fichier :** `lib/yanstaller/recommender.js`
|
|
337
|
+
|
|
338
|
+
**Fonction :** Recommande des agents basรฉs sur le contexte du projet.
|
|
339
|
+
|
|
340
|
+
**API :**
|
|
341
|
+
```javascript
|
|
342
|
+
const recommender = require('./lib/yanstaller/recommender');
|
|
343
|
+
|
|
344
|
+
const recommendations = await recommender.recommend({
|
|
345
|
+
projectRoot: '/path/to/project',
|
|
346
|
+
detection: { projectType: 'frontend', framework: 'react' }
|
|
347
|
+
});
|
|
348
|
+
|
|
349
|
+
/* Retour :
|
|
350
|
+
{
|
|
351
|
+
agents: ['dev', 'ux-designer', 'quinn'],
|
|
352
|
+
rationale: {
|
|
353
|
+
dev: 'Essential for React component development',
|
|
354
|
+
'ux-designer': 'UI/UX workflow for frontend projects',
|
|
355
|
+
quinn: 'QA automation for testing React components'
|
|
356
|
+
}
|
|
357
|
+
}
|
|
358
|
+
*/
|
|
359
|
+
```
|
|
360
|
+
|
|
361
|
+
**Reconnaissance :**
|
|
362
|
+
- **Frameworks :** React, Vue, Angular, Svelte, Next.js, Nuxt, Express, NestJS, Fastify, Koa, Django, Flask, Rails, Spring Boot, Laravel
|
|
363
|
+
- **Types de projet :** Frontend, Backend, Fullstack, Library
|
|
364
|
+
- **Outils :** Jest, Vitest, Playwright, Cypress, Webpack, Vite, Rollup
|
|
365
|
+
|
|
366
|
+
---
|
|
367
|
+
|
|
368
|
+
### 3. Installer
|
|
369
|
+
**Fichier :** `lib/yanstaller/installer.js`
|
|
370
|
+
|
|
371
|
+
**Fonction :** Installe les agents et configure l'environnement.
|
|
372
|
+
|
|
373
|
+
**API :**
|
|
374
|
+
```javascript
|
|
375
|
+
const installer = require('./lib/yanstaller/installer');
|
|
376
|
+
|
|
377
|
+
const result = await installer.install({
|
|
378
|
+
projectRoot: '/path/to/project',
|
|
379
|
+
agents: ['byan', 'dev', 'quinn'],
|
|
380
|
+
platforms: ['copilot-cli', 'vscode'],
|
|
381
|
+
userName: 'Yan',
|
|
382
|
+
language: 'Francais'
|
|
383
|
+
});
|
|
384
|
+
|
|
385
|
+
/* Retour :
|
|
386
|
+
{
|
|
387
|
+
success: true,
|
|
388
|
+
installedAgents: ['byan', 'dev', 'quinn'],
|
|
389
|
+
createdDirectories: 19,
|
|
390
|
+
generatedStubs: 6,
|
|
391
|
+
configPath: '_bmad/bmb/config.yaml'
|
|
392
|
+
}
|
|
393
|
+
*/
|
|
394
|
+
```
|
|
395
|
+
|
|
396
|
+
**รtapes :**
|
|
397
|
+
1. `createBmadStructure()` - Crรฉe 19 rรฉpertoires
|
|
398
|
+
2. `copyAgentFile()` - Copie les templates
|
|
399
|
+
3. `generatePlatformStubs()` - Gรฉnรจre les stubs
|
|
400
|
+
4. `createModuleConfig()` - Config YAML
|
|
401
|
+
|
|
402
|
+
---
|
|
403
|
+
|
|
404
|
+
### 4. Validator
|
|
405
|
+
**Fichier :** `lib/yanstaller/validator.js`
|
|
406
|
+
|
|
407
|
+
**Fonction :** Valide l'installation avec 10 checks automatisรฉs.
|
|
408
|
+
|
|
409
|
+
**API :**
|
|
410
|
+
```javascript
|
|
411
|
+
const validator = require('./lib/yanstaller/validator');
|
|
412
|
+
|
|
413
|
+
const validation = await validator.validate({
|
|
414
|
+
projectRoot: '/path/to/project'
|
|
415
|
+
});
|
|
416
|
+
|
|
417
|
+
/* Retour :
|
|
418
|
+
{
|
|
419
|
+
valid: true,
|
|
420
|
+
errors: [],
|
|
421
|
+
warnings: ['Config file missing optional field: document_output_language'],
|
|
422
|
+
checks: {
|
|
423
|
+
structure: 'pass',
|
|
424
|
+
agents: 'pass',
|
|
425
|
+
stubs: 'pass',
|
|
426
|
+
configs: 'pass',
|
|
427
|
+
platforms: 'pass',
|
|
428
|
+
permissions: 'pass',
|
|
429
|
+
manifests: 'pass',
|
|
430
|
+
workflows: 'pass',
|
|
431
|
+
templates: 'pass',
|
|
432
|
+
dependencies: 'pass'
|
|
433
|
+
}
|
|
434
|
+
}
|
|
435
|
+
*/
|
|
436
|
+
```
|
|
437
|
+
|
|
438
|
+
**10 Checks :**
|
|
439
|
+
1. `checkBmadStructure()` - 9 rรฉpertoires requis
|
|
440
|
+
2. `checkAgentFiles()` - Agents copiรฉs
|
|
441
|
+
3. `checkStubsYamlFrontmatter()` - Format YAML/XML
|
|
442
|
+
4. `checkConfigFiles()` - YAML valide
|
|
443
|
+
5. `checkPlatformDetection()` - Plateformes actives
|
|
444
|
+
6. `checkFilePermissions()` - Permissions R/W
|
|
445
|
+
7. `checkManifests()` - CSV valides
|
|
446
|
+
8. `checkWorkflows()` - Workflows accessibles
|
|
447
|
+
9. `checkTemplates()` - Structure templates
|
|
448
|
+
10. `checkDependencies()` - Dรฉpendances npm
|
|
449
|
+
|
|
450
|
+
---
|
|
451
|
+
|
|
452
|
+
### 5. Troubleshooter
|
|
453
|
+
**Fichier :** `lib/yanstaller/troubleshooter.js`
|
|
454
|
+
|
|
455
|
+
**Fonction :** Diagnostique et corrige automatiquement les erreurs.
|
|
456
|
+
|
|
457
|
+
**API :**
|
|
458
|
+
```javascript
|
|
459
|
+
const troubleshooter = require('./lib/yanstaller/troubleshooter');
|
|
460
|
+
|
|
461
|
+
// Diagnostic seul
|
|
462
|
+
const diagnosis = await troubleshooter.diagnose(error);
|
|
463
|
+
/* Retour :
|
|
464
|
+
{
|
|
465
|
+
pattern: 'PERMISSION',
|
|
466
|
+
message: 'Permission denied: /path/to/_bmad',
|
|
467
|
+
autoFixAvailable: true,
|
|
468
|
+
fixFunction: 'fixPermissions'
|
|
469
|
+
}
|
|
470
|
+
*/
|
|
471
|
+
|
|
472
|
+
// Troubleshooting complet
|
|
473
|
+
const result = await troubleshooter.troubleshoot({
|
|
474
|
+
projectRoot: '/path/to/project'
|
|
475
|
+
});
|
|
476
|
+
/* Retour :
|
|
477
|
+
{
|
|
478
|
+
issues: [
|
|
479
|
+
{ type: 'permission', path: '_bmad/core', fixed: true }
|
|
480
|
+
],
|
|
481
|
+
autofixed: 1,
|
|
482
|
+
manualActionRequired: 0
|
|
483
|
+
}
|
|
484
|
+
*/
|
|
485
|
+
```
|
|
486
|
+
|
|
487
|
+
**8 Patterns d'Erreur :**
|
|
488
|
+
1. `NODE_VERSION` - Node.js obsolรจte
|
|
489
|
+
2. `PERMISSION` - Permissions insuffisantes
|
|
490
|
+
3. `NOT_FOUND` - Fichier/rรฉpertoire manquant
|
|
491
|
+
4. `GIT_MISSING` - Git non installรฉ
|
|
492
|
+
5. `DISK_SPACE` - Espace disque insuffisant
|
|
493
|
+
6. `NETWORK` - Problรจme rรฉseau
|
|
494
|
+
7. `CORRUPTED` - Structure corrompue
|
|
495
|
+
8. `MISSING_DEP` - Dรฉpendance manquante
|
|
496
|
+
|
|
497
|
+
**5 Auto-Fix :**
|
|
498
|
+
- `fixPermissions()` - icacls (Windows) / chmod (Unix)
|
|
499
|
+
- `repairStructure()` - Recrรฉe `_bmad/`
|
|
500
|
+
- `resetConfig()` - Config YAML par dรฉfaut
|
|
501
|
+
- `reinstallDependencies()` - npm install
|
|
502
|
+
- `reinstallAgents()` - Re-copie templates
|
|
503
|
+
|
|
504
|
+
---
|
|
505
|
+
|
|
506
|
+
### 6. Backuper
|
|
507
|
+
**Fichier :** `lib/yanstaller/backuper.js`
|
|
508
|
+
|
|
509
|
+
**Fonction :** Sauvegarde et restaure le rรฉpertoire `_bmad/`.
|
|
510
|
+
|
|
511
|
+
**API :**
|
|
512
|
+
```javascript
|
|
513
|
+
const backuper = require('./lib/yanstaller/backuper');
|
|
514
|
+
|
|
515
|
+
// Backup
|
|
516
|
+
const backup = await backuper.backup({
|
|
517
|
+
projectRoot: '/path/to/project'
|
|
518
|
+
});
|
|
519
|
+
/* Retour :
|
|
520
|
+
{
|
|
521
|
+
backupPath: '_bmad-backup/backup-1706918400000',
|
|
522
|
+
metadata: {
|
|
523
|
+
timestamp: 1706918400000,
|
|
524
|
+
created: '2026-02-03T10:00:00.000Z',
|
|
525
|
+
source: '/path/to/project/_bmad',
|
|
526
|
+
files: 42,
|
|
527
|
+
size: 1048576,
|
|
528
|
+
version: '1.1.3'
|
|
529
|
+
}
|
|
530
|
+
}
|
|
531
|
+
*/
|
|
532
|
+
|
|
533
|
+
// Restore
|
|
534
|
+
const restore = await backuper.restore({
|
|
535
|
+
projectRoot: '/path/to/project',
|
|
536
|
+
backupPath: '_bmad-backup/backup-1706918400000'
|
|
537
|
+
});
|
|
538
|
+
/* Retour :
|
|
539
|
+
{
|
|
540
|
+
success: true,
|
|
541
|
+
restoredFiles: 42,
|
|
542
|
+
preRestoreBackup: '_bmad-backup/backup-1706918500000'
|
|
543
|
+
}
|
|
544
|
+
*/
|
|
545
|
+
|
|
546
|
+
// List backups
|
|
547
|
+
const backups = await backuper.listBackups({
|
|
548
|
+
projectRoot: '/path/to/project'
|
|
549
|
+
});
|
|
550
|
+
/* Retour : [
|
|
551
|
+
{
|
|
552
|
+
path: '_bmad-backup/backup-1706918400000',
|
|
553
|
+
timestamp: 1706918400000,
|
|
554
|
+
size: 1048576,
|
|
555
|
+
files: 42
|
|
556
|
+
}
|
|
557
|
+
]
|
|
558
|
+
*/
|
|
559
|
+
```
|
|
560
|
+
|
|
561
|
+
**Format Metadata :**
|
|
562
|
+
```json
|
|
563
|
+
{
|
|
564
|
+
"timestamp": 1706918400000,
|
|
565
|
+
"created": "2026-02-03T10:00:00.000Z",
|
|
566
|
+
"source": "/path/to/project/_bmad",
|
|
567
|
+
"files": 42,
|
|
568
|
+
"size": 1048576,
|
|
569
|
+
"version": "1.1.3"
|
|
570
|
+
}
|
|
571
|
+
```
|
|
572
|
+
|
|
573
|
+
---
|
|
574
|
+
|
|
575
|
+
### 7. Interviewer
|
|
576
|
+
**Fichier :** `lib/yanstaller/interviewer.js`
|
|
577
|
+
|
|
578
|
+
**Fonction :** Interview en 7 questions pour personnaliser l'installation.
|
|
579
|
+
|
|
580
|
+
**API :**
|
|
581
|
+
```javascript
|
|
582
|
+
const interviewer = require('./lib/yanstaller/interviewer');
|
|
583
|
+
|
|
584
|
+
const answers = await interviewer.ask();
|
|
585
|
+
/* Retour :
|
|
586
|
+
{
|
|
587
|
+
userName: 'Yan',
|
|
588
|
+
language: 'Francais',
|
|
589
|
+
mode: 'recommended',
|
|
590
|
+
agents: ['byan', 'dev', 'quinn'],
|
|
591
|
+
platforms: ['copilot-cli', 'vscode'],
|
|
592
|
+
installSampleAgent: true,
|
|
593
|
+
createBackup: true
|
|
594
|
+
}
|
|
595
|
+
*/
|
|
596
|
+
```
|
|
597
|
+
|
|
598
|
+
**7 Questions :**
|
|
599
|
+
1. **Nom** - Personnalisation
|
|
600
|
+
2. **Langue** - Franรงais ou English
|
|
601
|
+
3. **Mode** - Recommended/Custom/Minimal/Full
|
|
602
|
+
4. **Agents** - Sรฉlection manuelle (si Custom)
|
|
603
|
+
5. **Plateformes** - Copilot/VSCode/Claude/Codex
|
|
604
|
+
6. **Agent exemple** - Installer BYAN-Test ?
|
|
605
|
+
7. **Backup** - Crรฉer sauvegarde ?
|
|
606
|
+
|
|
607
|
+
---
|
|
608
|
+
|
|
609
|
+
### 8. Wizard
|
|
610
|
+
**Fichier :** `lib/yanstaller/wizard.js`
|
|
611
|
+
|
|
612
|
+
**Fonction :** Wizard post-installation avec 4 options.
|
|
613
|
+
|
|
614
|
+
**API :**
|
|
615
|
+
```javascript
|
|
616
|
+
const wizard = require('./lib/yanstaller/wizard');
|
|
617
|
+
|
|
618
|
+
await wizard.show({
|
|
619
|
+
installedAgents: ['byan', 'dev', 'quinn'],
|
|
620
|
+
platforms: ['copilot-cli', 'vscode']
|
|
621
|
+
});
|
|
622
|
+
|
|
623
|
+
// Options interactives :
|
|
624
|
+
// 1. Create new agent (launch BYAN)
|
|
625
|
+
// 2. Test an agent
|
|
626
|
+
// 3. View documentation
|
|
627
|
+
// 4. Exit
|
|
628
|
+
```
|
|
629
|
+
|
|
630
|
+
**Fonctionnalitรฉs :**
|
|
631
|
+
- `launchByanInterview()` - Instructions pour activer BYAN
|
|
632
|
+
- `testAgent()` - Guide de test d'agent
|
|
633
|
+
- `showDocumentation()` - Chemins de documentation
|
|
634
|
+
- `showExitMessage()` - Guide quick-start
|
|
635
|
+
|
|
636
|
+
---
|
|
637
|
+
|
|
638
|
+
## ๐งช Tests
|
|
639
|
+
|
|
640
|
+
### Suite de Tests (168 tests)
|
|
641
|
+
|
|
642
|
+
**Coverage :**
|
|
643
|
+
```bash
|
|
644
|
+
npm test
|
|
645
|
+
```
|
|
646
|
+
|
|
647
|
+
**Fichiers de test :**
|
|
648
|
+
```
|
|
649
|
+
__tests__/
|
|
650
|
+
โโโ recommender.test.js (18 tests) - Recommandations d'agents
|
|
651
|
+
โโโ installer.test.js (13 tests) - Installation core
|
|
652
|
+
โโโ platforms.test.js (20 tests) - Adapters plateformes
|
|
653
|
+
โโโ validator.test.js (24 tests) - Validation 10 checks
|
|
654
|
+
โโโ integration.test.js (27 tests) - Tests d'intรฉgration
|
|
655
|
+
โโโ e2e.test.js (16 tests) - Scรฉnarios end-to-end
|
|
656
|
+
โโโ troubleshooter.test.js (20 tests) - Diagnostic & auto-fix
|
|
657
|
+
โโโ backuper.test.js (20 tests) - Backup & restore
|
|
658
|
+
โโโ interviewer-wizard.test.js (10 tests) - Interview & wizard
|
|
659
|
+
```
|
|
660
|
+
|
|
661
|
+
### Tests E2E Scรฉnarios
|
|
662
|
+
|
|
663
|
+
**Scรฉnario 1 : Projet React Frontend**
|
|
664
|
+
```javascript
|
|
665
|
+
// Dรฉtection โ Recommend โ Install โ Validate
|
|
666
|
+
const project = { dependencies: { react: '^18.2.0' } };
|
|
667
|
+
// Agents recommandรฉs : dev, ux-designer, quinn
|
|
668
|
+
```
|
|
669
|
+
|
|
670
|
+
**Scรฉnario 2 : API Backend Express**
|
|
671
|
+
```javascript
|
|
672
|
+
const project = { dependencies: { express: '^4.18.2' } };
|
|
673
|
+
// Agents recommandรฉs : dev, architect, quinn
|
|
674
|
+
```
|
|
675
|
+
|
|
676
|
+
**Scรฉnario 3 : Next.js Fullstack**
|
|
677
|
+
```javascript
|
|
678
|
+
const project = { dependencies: { next: '^14.0.0' } };
|
|
679
|
+
// Agents recommandรฉs : dev, architect, ux-designer, quinn
|
|
680
|
+
```
|
|
681
|
+
|
|
682
|
+
### Tests d'Intรฉgration
|
|
683
|
+
|
|
684
|
+
**Performance Benchmarks :**
|
|
685
|
+
- Dรฉtection complรจte : < 2s
|
|
686
|
+
- Installation 5 agents : < 10s
|
|
687
|
+
- Validation 10 checks : < 5s
|
|
688
|
+
- Backup 50 fichiers : < 3s
|
|
689
|
+
|
|
690
|
+
### Exรฉcution des Tests
|
|
691
|
+
|
|
692
|
+
```bash
|
|
693
|
+
# Tous les tests
|
|
694
|
+
npm test
|
|
695
|
+
|
|
696
|
+
# Watch mode
|
|
697
|
+
npm run test:watch
|
|
698
|
+
|
|
699
|
+
# Coverage
|
|
700
|
+
npm run test:coverage
|
|
701
|
+
|
|
702
|
+
# Test spรฉcifique
|
|
703
|
+
npm test -- recommender.test.js
|
|
704
|
+
```
|
|
705
|
+
|
|
706
|
+
---
|
|
707
|
+
|
|
708
|
+
## ๐ ๏ธ Dรฉveloppement
|
|
709
|
+
|
|
710
|
+
### Setup Local
|
|
711
|
+
|
|
712
|
+
```bash
|
|
713
|
+
# Cloner le dรฉpรดt
|
|
714
|
+
git clone https://github.com/Yan-Acadenice/BYAN.git
|
|
715
|
+
cd BYAN/install
|
|
716
|
+
|
|
717
|
+
# Installer les dรฉpendances
|
|
718
|
+
npm install
|
|
719
|
+
|
|
720
|
+
# Lancer en mode dev
|
|
721
|
+
npm start
|
|
722
|
+
|
|
723
|
+
# Tests
|
|
724
|
+
npm test
|
|
725
|
+
|
|
726
|
+
# Linter
|
|
727
|
+
npm run lint
|
|
728
|
+
```
|
|
729
|
+
|
|
730
|
+
### Structure de Dรฉveloppement
|
|
731
|
+
|
|
732
|
+
**Conventions :**
|
|
733
|
+
- **Mรฉthodologie :** Merise Agile + TDD + 64 Mantras
|
|
734
|
+
- **Commits :** `feat:`, `fix:`, `docs:`, `refactor:`, `test:`, `chore:`
|
|
735
|
+
- **NO EMOJIS** dans commits/code/specs (Mantra IA-23)
|
|
736
|
+
- **Clean Code** - Code auto-documentรฉ (Mantra IA-24)
|
|
737
|
+
- **Test-Driven** - Tests avant implรฉmentation
|
|
738
|
+
|
|
739
|
+
**Ajouter un Nouveau Module :**
|
|
740
|
+
|
|
741
|
+
1. Crรฉer `lib/yanstaller/my-module.js`
|
|
742
|
+
2. Crรฉer `__tests__/my-module.test.js`
|
|
743
|
+
3. รcrire les tests (TDD)
|
|
744
|
+
4. Implรฉmenter le module
|
|
745
|
+
5. Exรฉcuter les tests : `npm test`
|
|
746
|
+
6. Commit : `feat: add my-module with X functionality`
|
|
747
|
+
|
|
748
|
+
**Ajouter une Nouvelle Plateforme :**
|
|
749
|
+
|
|
750
|
+
1. Crรฉer `lib/platforms/my-platform.js`
|
|
751
|
+
2. Implรฉmenter 3 mรฉthodes :
|
|
752
|
+
- `detect()` - Dรฉtecter la plateforme
|
|
753
|
+
- `install(agentName)` - Crรฉer l'agent
|
|
754
|
+
- `generateStub(agentName, config)` - Gรฉnรฉrer le stub
|
|
755
|
+
3. Ajouter les tests dans `__tests__/platforms.test.js`
|
|
756
|
+
4. Mettre ร jour `lib/yanstaller/detector.js`
|
|
757
|
+
|
|
758
|
+
---
|
|
759
|
+
|
|
760
|
+
## ๐ค Contributing
|
|
761
|
+
|
|
762
|
+
Les contributions sont les bienvenues ! Merci de suivre ces guidelines :
|
|
763
|
+
|
|
764
|
+
### Processus de Contribution
|
|
765
|
+
|
|
766
|
+
1. **Fork** le dรฉpรดt
|
|
767
|
+
2. **Crรฉer une branche** : `git checkout -b feature/ma-fonctionnalite`
|
|
768
|
+
3. **รcrire les tests** (TDD obligatoire)
|
|
769
|
+
4. **Implรฉmenter** la fonctionnalitรฉ
|
|
770
|
+
5. **Tests verts** : `npm test`
|
|
771
|
+
6. **Commit** : `git commit -m "feat: add ma-fonctionnalite"`
|
|
772
|
+
7. **Push** : `git push origin feature/ma-fonctionnalite`
|
|
773
|
+
8. **Pull Request** avec description dรฉtaillรฉe
|
|
774
|
+
|
|
775
|
+
### Standards de Code
|
|
776
|
+
|
|
777
|
+
- โ
**TDD** - Tests avant implรฉmentation
|
|
778
|
+
- โ
**Clean Code** - Fonctions courtes, noms explicites
|
|
779
|
+
- โ
**No Emojis** - Code/commits/specs techniques
|
|
780
|
+
- โ
**Comments** - Uniquement pour le "pourquoi", pas le "quoi"
|
|
781
|
+
- โ
**Async/Await** - Pas de callbacks
|
|
782
|
+
- โ
**Error Handling** - Try/catch systรฉmatique
|
|
783
|
+
|
|
784
|
+
### Checklist PR
|
|
785
|
+
|
|
786
|
+
- [ ] Tests รฉcrits et passants (coverage โฅ 80%)
|
|
787
|
+
- [ ] Documentation mise ร jour
|
|
788
|
+
- [ ] Commit messages suivent convention
|
|
789
|
+
- [ ] Code lint sans erreurs
|
|
790
|
+
- [ ] Pas de breaking changes (ou documentรฉes)
|
|
791
|
+
- [ ] PR description complรจte
|
|
792
|
+
|
|
793
|
+
---
|
|
794
|
+
|
|
795
|
+
## ๐ License
|
|
796
|
+
|
|
797
|
+
**MIT License**
|
|
798
|
+
|
|
799
|
+
Copyright (c) 2026 Yan
|
|
800
|
+
|
|
801
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
802
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
803
|
+
in the Software without restriction, including without limitation the rights
|
|
804
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
805
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
806
|
+
furnished to do so, subject to the following conditions:
|
|
807
|
+
|
|
808
|
+
The above copyright notice and this permission notice shall be included in all
|
|
809
|
+
copies or substantial portions of the Software.
|
|
810
|
+
|
|
811
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
812
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
813
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
814
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
815
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
816
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
817
|
+
SOFTWARE.
|
|
818
|
+
|
|
819
|
+
---
|
|
820
|
+
|
|
821
|
+
## ๐ Ressources
|
|
822
|
+
|
|
823
|
+
- **Documentation BMAD :** [GitHub Wiki](https://github.com/Yan-Acadenice/BYAN/wiki)
|
|
824
|
+
- **BYAN Agent :** Crรฉateur d'agents intelligent
|
|
825
|
+
- **RACHID Agent :** Dรฉploiement NPM
|
|
826
|
+
- **MARC Agent :** Intรฉgration GitHub Copilot CLI
|
|
827
|
+
- **PATNOTE Agent :** Gestion des mises ร jour
|
|
828
|
+
- **CARMACK Agent :** Optimisation tokens (-46%)
|
|
829
|
+
|
|
830
|
+
---
|
|
831
|
+
|
|
832
|
+
## ๐ง Support
|
|
833
|
+
|
|
834
|
+
- **Issues :** [GitHub Issues](https://github.com/Yan-Acadenice/BYAN/issues)
|
|
835
|
+
- **Discussions :** [GitHub Discussions](https://github.com/Yan-Acadenice/BYAN/discussions)
|
|
836
|
+
- **Email :** yan@example.com
|
|
837
|
+
|
|
838
|
+
---
|
|
839
|
+
|
|
840
|
+
# ๐ฌ๐ง ENGLISH VERSION
|
|
841
|
+
|
|
842
|
+
---
|
|
843
|
+
|
|
844
|
+
# ๐๏ธ YANSTALLER - Intelligent BYAN Installer
|
|
845
|
+
|
|
846
|
+
[](https://www.npmjs.com/package/create-byan-agent)
|
|
847
|
+
[](LICENSE)
|
|
848
|
+
[](https://nodejs.org)
|
|
849
|
+
[](#tests)
|
|
850
|
+
|
|
851
|
+
**YANSTALLER** is the intelligent installer for the **BYAN** (Builder of YAN) ecosystem. It automatically detects your development environment, recommends appropriate agents, and installs them with multi-platform support.
|
|
852
|
+
|
|
853
|
+
**Methodology:** Merise Agile + TDD + 64 Mantras
|
|
854
|
+
**Languages:** ๐ฌ๐ง English | ๐ซ๐ท Franรงais
|
|
855
|
+
|
|
856
|
+
---
|
|
857
|
+
|
|
858
|
+
## ๐ Table of Contents
|
|
859
|
+
|
|
860
|
+
1. [Features](#-features)
|
|
861
|
+
2. [Installation](#-quick-installation)
|
|
862
|
+
3. [Usage](#-usage)
|
|
863
|
+
4. [Architecture](#-architecture)
|
|
864
|
+
5. [Modules](#-modules)
|
|
865
|
+
6. [API Reference](#-api-reference)
|
|
866
|
+
7. [Tests](#-tests)
|
|
867
|
+
8. [Development](#-development)
|
|
868
|
+
9. [Contributing](#-contributing)
|
|
869
|
+
10. [License](#-license)
|
|
870
|
+
|
|
871
|
+
---
|
|
872
|
+
|
|
873
|
+
## โจ Features
|
|
874
|
+
|
|
875
|
+
### ๐ฏ Intelligent Detection
|
|
876
|
+
- โ
**Automatic detection** of platforms (GitHub Copilot CLI, VSCode, Claude Code, Codex)
|
|
877
|
+
- โ
**Project analysis** via `package.json` (20+ recognized frameworks)
|
|
878
|
+
- โ
**Contextual recommendations** of agents based on your stack
|
|
879
|
+
|
|
880
|
+
### ๐ค Available Agents (29 agents)
|
|
881
|
+
- **BMB (Meta):** BYAN, BYAN-Test, RACHID, MARC, PATNOTE, CARMACK, Agent-Builder, Module-Builder, Workflow-Builder
|
|
882
|
+
- **BMM (SDLC):** Analyst, PM, Architect, Dev, SM, Quinn, UX-Designer, Tech-Writer, Quick-Flow-Solo-Dev
|
|
883
|
+
- **TEA (Testing):** TEA (Test Architecture Expert)
|
|
884
|
+
- **CIS (Innovation):** Brainstorming-Coach, Design-Thinking-Coach, Creative-Problem-Solver, Innovation-Strategist, Presentation-Master, Storyteller
|
|
885
|
+
- **Core:** Party-Mode, BMAD-Master
|
|
886
|
+
|
|
887
|
+
### ๐ Intelligent Installation
|
|
888
|
+
- โ
**Complete BMAD structure** (19 directories created automatically)
|
|
889
|
+
- โ
**Generated YAML configuration** with metadata
|
|
890
|
+
- โ
**Multi-platform stubs** (Copilot CLI, VSCode, Claude Code, Codex)
|
|
891
|
+
- โ
**MCP Server setup** for Claude Code
|
|
892
|
+
- โ
**CSV manifests** for agent tracking
|
|
893
|
+
|
|
894
|
+
### ๐ Automated Validation (10 checks)
|
|
895
|
+
- Verify `_bmad/` structure
|
|
896
|
+
- Validate agent files
|
|
897
|
+
- Check YAML frontmatter
|
|
898
|
+
- Validate permissions
|
|
899
|
+
- Verify npm dependencies
|
|
900
|
+
- Test manifests, workflows, templates
|
|
901
|
+
|
|
902
|
+
### ๐ ๏ธ Intelligent Troubleshooting
|
|
903
|
+
- โ
**8 error patterns** automatically recognized
|
|
904
|
+
- โ
**Auto-fix** for permissions, corrupted structure, dependencies
|
|
905
|
+
- โ
**Contextual diagnostics** (Node version, Git, disk space)
|
|
906
|
+
- โ
**OS-specific upgrade suggestions**
|
|
907
|
+
|
|
908
|
+
### ๐พ Backup & Rollback
|
|
909
|
+
- โ
**Automatic backup** before installation
|
|
910
|
+
- โ
**Metadata** (timestamp, size, files)
|
|
911
|
+
- โ
**Secure restore** with pre-restore backup
|
|
912
|
+
- โ
**Automatic cleanup** of old backups
|
|
913
|
+
|
|
914
|
+
### ๐ง Post-Installation Wizard
|
|
915
|
+
- โ
**7-question interview** (<5 min)
|
|
916
|
+
- โ
**Conversational mode** with inquirer
|
|
917
|
+
- โ
**4 post-install options**: create agent, test, docs, exit
|
|
918
|
+
- โ
**Interactive quick-start guide**
|
|
919
|
+
|
|
920
|
+
---
|
|
921
|
+
|
|
922
|
+
## ๐ Quick Installation
|
|
923
|
+
|
|
924
|
+
### Prerequisites
|
|
925
|
+
- **Node.js** โฅ 18.0.0
|
|
926
|
+
- **Git** installed
|
|
927
|
+
- At least **1 platform**: GitHub Copilot CLI, VSCode, Claude Code, or Codex
|
|
928
|
+
|
|
929
|
+
### Via NPX (recommended)
|
|
930
|
+
```bash
|
|
931
|
+
# Interactive installation
|
|
932
|
+
npx create-byan-agent
|
|
933
|
+
|
|
934
|
+
# Follow the 7-question interview (5 min)
|
|
935
|
+
```
|
|
936
|
+
|
|
937
|
+
### Via NPM Global
|
|
938
|
+
```bash
|
|
939
|
+
# Install globally
|
|
940
|
+
npm install -g create-byan-agent
|
|
941
|
+
|
|
942
|
+
# Run
|
|
943
|
+
create-byan-agent
|
|
944
|
+
```
|
|
945
|
+
|
|
946
|
+
### Manual Installation
|
|
947
|
+
```bash
|
|
948
|
+
# Clone the repository
|
|
949
|
+
git clone https://github.com/Yan-Acadenice/BYAN.git
|
|
950
|
+
cd BYAN/install
|
|
951
|
+
|
|
952
|
+
# Install dependencies
|
|
953
|
+
npm install
|
|
954
|
+
|
|
955
|
+
# Launch installer
|
|
956
|
+
npm start
|
|
957
|
+
```
|
|
958
|
+
|
|
959
|
+
---
|
|
960
|
+
|
|
961
|
+
## ๐ฎ Usage
|
|
962
|
+
|
|
963
|
+
### Interview Mode (Recommended)
|
|
964
|
+
```bash
|
|
965
|
+
npx create-byan-agent
|
|
966
|
+
```
|
|
967
|
+
|
|
968
|
+
**7 interactive questions:**
|
|
969
|
+
1. Your name (for personalized configuration)
|
|
970
|
+
2. Communication language (Franรงais/English)
|
|
971
|
+
3. Installation mode (Recommended/Custom/Minimal/Full)
|
|
972
|
+
4. Agent selection (if Custom)
|
|
973
|
+
5. Target platforms (Copilot/VSCode/Claude/Codex)
|
|
974
|
+
6. Install sample agent (yes/no)
|
|
975
|
+
7. Create backup (yes/no)
|
|
976
|
+
|
|
977
|
+
### Programmatic Mode
|
|
978
|
+
|
|
979
|
+
#### JavaScript API
|
|
980
|
+
```javascript
|
|
981
|
+
const yanstaller = require('create-byan-agent');
|
|
982
|
+
|
|
983
|
+
// Detection
|
|
984
|
+
const detection = await yanstaller.detect({
|
|
985
|
+
projectRoot: process.cwd()
|
|
986
|
+
});
|
|
987
|
+
console.log(detection.platforms); // ['copilot-cli', 'vscode']
|
|
988
|
+
|
|
989
|
+
// Recommendation
|
|
990
|
+
const recommendations = await yanstaller.recommend({
|
|
991
|
+
projectRoot: process.cwd(),
|
|
992
|
+
detection
|
|
993
|
+
});
|
|
994
|
+
console.log(recommendations.agents); // ['dev', 'architect', 'quinn']
|
|
995
|
+
|
|
996
|
+
// Installation
|
|
997
|
+
const result = await yanstaller.install({
|
|
998
|
+
projectRoot: process.cwd(),
|
|
999
|
+
agents: ['byan', 'dev', 'quinn'],
|
|
1000
|
+
platforms: ['copilot-cli', 'vscode'],
|
|
1001
|
+
userName: 'Yan',
|
|
1002
|
+
language: 'English'
|
|
1003
|
+
});
|
|
1004
|
+
|
|
1005
|
+
// Validation
|
|
1006
|
+
const validation = await yanstaller.validate({
|
|
1007
|
+
projectRoot: process.cwd()
|
|
1008
|
+
});
|
|
1009
|
+
console.log(validation.errors); // []
|
|
1010
|
+
```
|
|
1011
|
+
|
|
1012
|
+
#### CLI Options
|
|
1013
|
+
```bash
|
|
1014
|
+
# Silent installation with specific agents
|
|
1015
|
+
create-byan-agent --silent --agents=byan,dev,quinn
|
|
1016
|
+
|
|
1017
|
+
# Custom mode with specific platform
|
|
1018
|
+
create-byan-agent --mode=custom --platforms=copilot-cli
|
|
1019
|
+
|
|
1020
|
+
# Full installation without backup
|
|
1021
|
+
create-byan-agent --mode=full --no-backup
|
|
1022
|
+
|
|
1023
|
+
# Dry-run (simulation)
|
|
1024
|
+
create-byan-agent --dry-run
|
|
1025
|
+
|
|
1026
|
+
# Verbose logging
|
|
1027
|
+
create-byan-agent --verbose
|
|
1028
|
+
```
|
|
1029
|
+
|
|
1030
|
+
---
|
|
1031
|
+
|
|
1032
|
+
## ๐๏ธ Architecture
|
|
1033
|
+
|
|
1034
|
+
### Project Structure
|
|
1035
|
+
```
|
|
1036
|
+
install/
|
|
1037
|
+
โโโ bin/
|
|
1038
|
+
โ โโโ create-byan-agent.js # CLI entry point
|
|
1039
|
+
โโโ lib/
|
|
1040
|
+
โ โโโ yanstaller/ # Core modules
|
|
1041
|
+
โ โ โโโ detector.js # Platform & project detection
|
|
1042
|
+
โ โ โโโ recommender.js # Agent recommendations
|
|
1043
|
+
โ โ โโโ installer.js # Installation orchestration
|
|
1044
|
+
โ โ โโโ validator.js # Post-install validation
|
|
1045
|
+
โ โ โโโ troubleshooter.js # Error diagnosis & auto-fix
|
|
1046
|
+
โ โ โโโ backuper.js # Backup & restore
|
|
1047
|
+
โ โ โโโ interviewer.js # Interactive interview
|
|
1048
|
+
โ โ โโโ wizard.js # Post-install wizard
|
|
1049
|
+
โ โโโ platforms/ # Platform adapters
|
|
1050
|
+
โ โ โโโ copilot-cli.js # GitHub Copilot CLI
|
|
1051
|
+
โ โ โโโ vscode.js # VSCode extension
|
|
1052
|
+
โ โ โโโ claude-code.js # Claude Code MCP
|
|
1053
|
+
โ โ โโโ codex.js # Codex platform
|
|
1054
|
+
โ โโโ utils/ # Utilities
|
|
1055
|
+
โ โ โโโ file-utils.js # File operations
|
|
1056
|
+
โ โ โโโ logger.js # Logging system
|
|
1057
|
+
โ โ โโโ yaml-utils.js # YAML parsing
|
|
1058
|
+
โ โโโ errors.js # Error definitions
|
|
1059
|
+
โ โโโ exit-codes.js # Exit code constants
|
|
1060
|
+
โโโ templates/ # Agent templates
|
|
1061
|
+
โ โโโ _bmad/
|
|
1062
|
+
โ โโโ core/agents/
|
|
1063
|
+
โ โโโ bmm/agents/
|
|
1064
|
+
โ โโโ bmb/agents/
|
|
1065
|
+
โ โโโ tea/agents/
|
|
1066
|
+
โ โโโ cis/agents/
|
|
1067
|
+
โโโ __tests__/ # Test suite (168 tests)
|
|
1068
|
+
โโโ package.json
|
|
1069
|
+
```
|
|
1070
|
+
|
|
1071
|
+
### Installation Flow
|
|
1072
|
+
|
|
1073
|
+
```
|
|
1074
|
+
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
|
|
1075
|
+
โ 1. DETECT - Platform & Project Analysis โ
|
|
1076
|
+
โ โข Scan for Copilot CLI, VSCode, Claude, Codex โ
|
|
1077
|
+
โ โข Analyze package.json dependencies โ
|
|
1078
|
+
โ โข Detect project type & framework โ
|
|
1079
|
+
โโโโโโโโโโโโโโโโโโโโโโฌโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
|
|
1080
|
+
โ
|
|
1081
|
+
โผ
|
|
1082
|
+
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
|
|
1083
|
+
โ 2. RECOMMEND - Intelligent Agent Selection โ
|
|
1084
|
+
โ โข Match agents to project type โ
|
|
1085
|
+
โ โข Consider detected platforms โ
|
|
1086
|
+
โ โข Generate rationale for each recommendation โ
|
|
1087
|
+
โโโโโโโโโโโโโโโโโโโโโโฌโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
|
|
1088
|
+
โ
|
|
1089
|
+
โผ
|
|
1090
|
+
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
|
|
1091
|
+
โ 3. INTERVIEW - User Preferences (7 questions) โ
|
|
1092
|
+
โ โข Name, language, mode โ
|
|
1093
|
+
โ โข Agent selection (if custom) โ
|
|
1094
|
+
โ โข Platform targets, backup option โ
|
|
1095
|
+
โโโโโโโโโโโโโโโโโโโโโโฌโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
|
|
1096
|
+
โ
|
|
1097
|
+
โผ
|
|
1098
|
+
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
|
|
1099
|
+
โ 4. BACKUP - Pre-install Safety (optional) โ
|
|
1100
|
+
โ โข Create timestamped backup of _bmad/ โ
|
|
1101
|
+
โ โข Save metadata (files, size, version) โ
|
|
1102
|
+
โโโโโโโโโโโโโโโโโโโโโโฌโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
|
|
1103
|
+
โ
|
|
1104
|
+
โผ
|
|
1105
|
+
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
|
|
1106
|
+
โ 5. INSTALL - Core Installation โ
|
|
1107
|
+
โ โข Create _bmad/ structure (19 directories) โ
|
|
1108
|
+
โ โข Copy agent templates from 5 modules โ
|
|
1109
|
+
โ โข Generate platform stubs (Copilot/VSCode/etc.) โ
|
|
1110
|
+
โ โข Create module configs (YAML with metadata) โ
|
|
1111
|
+
โ โข Update manifests (agent-manifest.csv) โ
|
|
1112
|
+
โโโโโโโโโโโโโโโโโโโโโโฌโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
|
|
1113
|
+
โ
|
|
1114
|
+
โผ
|
|
1115
|
+
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
|
|
1116
|
+
โ 6. VALIDATE - 10 Automated Checks โ
|
|
1117
|
+
โ โข Structure, agents, stubs, configs โ
|
|
1118
|
+
โ โข Permissions, manifests, workflows โ
|
|
1119
|
+
โ โข Templates, dependencies โ
|
|
1120
|
+
โโโโโโโโโโโโโโโโโโโโโโฌโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
|
|
1121
|
+
โ
|
|
1122
|
+
โผ
|
|
1123
|
+
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
|
|
1124
|
+
โ 7. WIZARD - Post-Install Actions โ
|
|
1125
|
+
โ โข Summary of installed agents โ
|
|
1126
|
+
โ โข Option: Create new agent (launch BYAN) โ
|
|
1127
|
+
โ โข Option: Test agent โ
|
|
1128
|
+
โ โข Option: View documentation โ
|
|
1129
|
+
โ โข Quick start guide โ
|
|
1130
|
+
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
|
|
1131
|
+
```
|
|
1132
|
+
|
|
1133
|
+
---
|
|
1134
|
+
|
|
1135
|
+
## ๐ฆ Modules
|
|
1136
|
+
|
|
1137
|
+
_(Same detailed module documentation as French version, translated to English)_
|
|
1138
|
+
|
|
1139
|
+
### 1. Detector
|
|
1140
|
+
**File:** `lib/yanstaller/detector.js`
|
|
1141
|
+
|
|
1142
|
+
**Purpose:** Detects installed platforms and analyzes the project.
|
|
1143
|
+
|
|
1144
|
+
**API:** _(Same as French version)_
|
|
1145
|
+
|
|
1146
|
+
### 2-8. _(Other modules follow same structure as French version)_
|
|
1147
|
+
|
|
1148
|
+
---
|
|
1149
|
+
|
|
1150
|
+
## ๐งช Tests
|
|
1151
|
+
|
|
1152
|
+
### Test Suite (168 tests)
|
|
1153
|
+
|
|
1154
|
+
**Coverage:**
|
|
1155
|
+
```bash
|
|
1156
|
+
npm test
|
|
1157
|
+
```
|
|
1158
|
+
|
|
1159
|
+
**Test files:**
|
|
1160
|
+
```
|
|
1161
|
+
__tests__/
|
|
1162
|
+
โโโ recommender.test.js (18 tests) - Agent recommendations
|
|
1163
|
+
โโโ installer.test.js (13 tests) - Core installation
|
|
1164
|
+
โโโ platforms.test.js (20 tests) - Platform adapters
|
|
1165
|
+
โโโ validator.test.js (24 tests) - 10-check validation
|
|
1166
|
+
โโโ integration.test.js (27 tests) - Integration tests
|
|
1167
|
+
โโโ e2e.test.js (16 tests) - End-to-end scenarios
|
|
1168
|
+
โโโ troubleshooter.test.js (20 tests) - Diagnostic & auto-fix
|
|
1169
|
+
โโโ backuper.test.js (20 tests) - Backup & restore
|
|
1170
|
+
โโโ interviewer-wizard.test.js (10 tests) - Interview & wizard
|
|
1171
|
+
```
|
|
1172
|
+
|
|
1173
|
+
---
|
|
1174
|
+
|
|
1175
|
+
## ๐ ๏ธ Development
|
|
1176
|
+
|
|
1177
|
+
### Local Setup
|
|
1178
|
+
|
|
1179
|
+
```bash
|
|
1180
|
+
# Clone repository
|
|
1181
|
+
git clone https://github.com/Yan-Acadenice/BYAN.git
|
|
1182
|
+
cd BYAN/install
|
|
1183
|
+
|
|
1184
|
+
# Install dependencies
|
|
1185
|
+
npm install
|
|
1186
|
+
|
|
1187
|
+
# Run in dev mode
|
|
1188
|
+
npm start
|
|
1189
|
+
|
|
1190
|
+
# Tests
|
|
1191
|
+
npm test
|
|
1192
|
+
|
|
1193
|
+
# Linter
|
|
1194
|
+
npm run lint
|
|
1195
|
+
```
|
|
1196
|
+
|
|
1197
|
+
---
|
|
1198
|
+
|
|
1199
|
+
## ๐ค Contributing
|
|
1200
|
+
|
|
1201
|
+
Contributions are welcome! Please follow these guidelines:
|
|
1202
|
+
|
|
1203
|
+
### Contribution Process
|
|
1204
|
+
|
|
1205
|
+
1. **Fork** the repository
|
|
1206
|
+
2. **Create a branch**: `git checkout -b feature/my-feature`
|
|
1207
|
+
3. **Write tests** (TDD mandatory)
|
|
1208
|
+
4. **Implement** the feature
|
|
1209
|
+
5. **Tests pass**: `npm test`
|
|
1210
|
+
6. **Commit**: `git commit -m "feat: add my-feature"`
|
|
1211
|
+
7. **Push**: `git push origin feature/my-feature`
|
|
1212
|
+
8. **Pull Request** with detailed description
|
|
1213
|
+
|
|
1214
|
+
---
|
|
1215
|
+
|
|
1216
|
+
## ๐ License
|
|
1217
|
+
|
|
1218
|
+
**MIT License**
|
|
1219
|
+
|
|
1220
|
+
Copyright (c) 2026 Yan
|
|
1221
|
+
|
|
1222
|
+
_(Full MIT license text as in French version)_
|
|
1223
|
+
|
|
1224
|
+
---
|
|
1225
|
+
|
|
1226
|
+
## ๐ Resources
|
|
1227
|
+
|
|
1228
|
+
- **BMAD Documentation:** [GitHub Wiki](https://github.com/Yan-Acadenice/BYAN/wiki)
|
|
1229
|
+
- **BYAN Agent:** Intelligent agent creator
|
|
1230
|
+
- **RACHID Agent:** NPM deployment
|
|
1231
|
+
- **MARC Agent:** GitHub Copilot CLI integration
|
|
1232
|
+
- **PATNOTE Agent:** Update management
|
|
1233
|
+
- **CARMACK Agent:** Token optimization (-46%)
|
|
1234
|
+
|
|
1235
|
+
---
|
|
1236
|
+
|
|
1237
|
+
## ๐ง Support
|
|
1238
|
+
|
|
1239
|
+
- **Issues:** [GitHub Issues](https://github.com/Yan-Acadenice/BYAN/issues)
|
|
1240
|
+
- **Discussions:** [GitHub Discussions](https://github.com/Yan-Acadenice/BYAN/discussions)
|
|
1241
|
+
- **Email:** yan@example.com
|
|
1242
|
+
|
|
1243
|
+
---
|
|
1244
|
+
|
|
1245
|
+
**Made with โค๏ธ by Yan | Merise Agile + TDD + 64 Mantras**
|