create-byan-agent 1.1.3 โ†’ 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.
Files changed (76) hide show
  1. package/CHANGELOG.md +250 -202
  2. package/LICENSE +21 -21
  3. package/README.md +1245 -421
  4. package/bin/create-byan-agent-backup.js +220 -220
  5. package/bin/create-byan-agent-fixed.js +301 -301
  6. package/bin/create-byan-agent.js +322 -322
  7. package/lib/errors.js +61 -0
  8. package/lib/exit-codes.js +54 -0
  9. package/lib/platforms/claude-code.js +113 -0
  10. package/lib/platforms/codex.js +92 -0
  11. package/lib/platforms/copilot-cli.js +123 -0
  12. package/lib/platforms/index.js +14 -0
  13. package/lib/platforms/vscode.js +51 -0
  14. package/lib/utils/config-loader.js +79 -0
  15. package/lib/utils/file-utils.js +104 -0
  16. package/lib/utils/git-detector.js +35 -0
  17. package/lib/utils/logger.js +64 -0
  18. package/lib/utils/node-detector.js +58 -0
  19. package/lib/utils/os-detector.js +74 -0
  20. package/lib/utils/yaml-utils.js +87 -0
  21. package/lib/yanstaller/backuper.js +308 -0
  22. package/lib/yanstaller/detector.js +141 -0
  23. package/lib/yanstaller/index.js +93 -0
  24. package/lib/yanstaller/installer.js +225 -0
  25. package/lib/yanstaller/interviewer.js +250 -0
  26. package/lib/yanstaller/recommender.js +298 -0
  27. package/lib/yanstaller/troubleshooter.js +498 -0
  28. package/lib/yanstaller/validator.js +578 -0
  29. package/lib/yanstaller/wizard.js +211 -0
  30. package/package.json +61 -55
  31. package/templates/.github/agents/bmad-agent-bmad-master.md +15 -15
  32. package/templates/.github/agents/bmad-agent-bmb-agent-builder.md +15 -15
  33. package/templates/.github/agents/bmad-agent-bmb-module-builder.md +15 -15
  34. package/templates/.github/agents/bmad-agent-bmb-workflow-builder.md +15 -15
  35. package/templates/.github/agents/bmad-agent-bmm-analyst.md +15 -15
  36. package/templates/.github/agents/bmad-agent-bmm-architect.md +15 -15
  37. package/templates/.github/agents/bmad-agent-bmm-dev.md +15 -15
  38. package/templates/.github/agents/bmad-agent-bmm-pm.md +15 -15
  39. package/templates/.github/agents/bmad-agent-bmm-quick-flow-solo-dev.md +15 -15
  40. package/templates/.github/agents/bmad-agent-bmm-quinn.md +15 -15
  41. package/templates/.github/agents/bmad-agent-bmm-sm.md +15 -15
  42. package/templates/.github/agents/bmad-agent-bmm-tech-writer.md +15 -15
  43. package/templates/.github/agents/bmad-agent-bmm-ux-designer.md +15 -15
  44. package/templates/.github/agents/bmad-agent-byan-test.md +32 -0
  45. package/templates/.github/agents/bmad-agent-byan.md +224 -224
  46. package/templates/.github/agents/bmad-agent-carmack.md +18 -0
  47. package/templates/.github/agents/bmad-agent-cis-brainstorming-coach.md +15 -15
  48. package/templates/.github/agents/bmad-agent-cis-creative-problem-solver.md +15 -15
  49. package/templates/.github/agents/bmad-agent-cis-design-thinking-coach.md +15 -15
  50. package/templates/.github/agents/bmad-agent-cis-innovation-strategist.md +15 -15
  51. package/templates/.github/agents/bmad-agent-cis-presentation-master.md +15 -15
  52. package/templates/.github/agents/bmad-agent-cis-storyteller.md +15 -15
  53. package/templates/.github/agents/bmad-agent-marc.md +48 -48
  54. package/templates/.github/agents/bmad-agent-patnote.md +48 -0
  55. package/templates/.github/agents/bmad-agent-rachid.md +47 -47
  56. package/templates/.github/agents/bmad-agent-tea-tea.md +15 -15
  57. package/templates/.github/agents/bmad-agent-test-dynamic.md +21 -0
  58. package/templates/.github/agents/expert-merise-agile.md +1 -0
  59. package/templates/.github/agents/franck.md +379 -0
  60. package/templates/_bmad/bmb/agents/agent-builder.md +59 -59
  61. package/templates/_bmad/bmb/agents/byan-test.md +116 -116
  62. package/templates/_bmad/bmb/agents/byan.md +215 -215
  63. package/templates/_bmad/bmb/agents/marc.md +303 -303
  64. package/templates/_bmad/bmb/agents/module-builder.md +60 -60
  65. package/templates/_bmad/bmb/agents/patnote.md +495 -495
  66. package/templates/_bmad/bmb/agents/rachid.md +184 -184
  67. package/templates/_bmad/bmb/agents/workflow-builder.md +61 -61
  68. package/templates/_bmad/bmb/workflows/byan/data/mantras.yaml +272 -272
  69. package/templates/_bmad/bmb/workflows/byan/data/templates.yaml +59 -59
  70. package/templates/_bmad/bmb/workflows/byan/delete-agent-workflow.md +657 -657
  71. package/templates/_bmad/bmb/workflows/byan/edit-agent-workflow.md +688 -688
  72. package/templates/_bmad/bmb/workflows/byan/interview-workflow.md +753 -753
  73. package/templates/_bmad/bmb/workflows/byan/quick-create-workflow.md +450 -450
  74. package/templates/_bmad/bmb/workflows/byan/templates/base-agent-template.md +79 -79
  75. package/templates/_bmad/bmb/workflows/byan/validate-agent-workflow.md +676 -676
  76. package/templates/_bmad/core/agents/carmack.md +238 -238
package/README.md CHANGED
@@ -1,421 +1,1245 @@
1
- # BYAN - Builder of YAN
2
-
3
- **Version:** 1.1.1
4
- **Methodology:** Merise Agile + TDD + 64 Mantras
5
- **Agents Included:** BYAN, BYAN-Test, RACHID, MARC, PATNOTE, CARMACK
6
-
7
- ---
8
-
9
- ## ๐Ÿ“š Documentation
10
-
11
- ### ๐Ÿ†• **[Installation Guide for Beginners](https://github.com/Yan-Acadenice/BYAN/blob/main/install/GUIDE-INSTALLATION-BYAN-SIMPLE.md)** โญ NEW!
12
- Complete step-by-step installation guide for Windows + Linux users:
13
- - โœ… GitHub Copilot CLI installation (detailed)
14
- - โœ… Claude Code installation (with MCP)
15
- - โœ… 10 troubleshooting scenarios
16
- - โœ… 8 FAQ with solutions
17
- - โœ… Beginner-friendly explanations
18
- - โœ… Copy-paste ready commands
19
-
20
- **Perfect for:** First-time users, Windows users, troubleshooting installation issues
21
-
22
- ### โšก **[Quickstart Guide - 5 Minutes](https://github.com/Yan-Acadenice/BYAN/blob/main/install/QUICKSTART.md)** ๐Ÿš€ NEW!
23
- Ultra-condensed installation for experienced developers:
24
- - โšก Zero explanations, only commands
25
- - โšก 5-minute install promise
26
- - โšก GitHub Copilot CLI + Claude Code
27
- - โšก 1-minute troubleshooting fixes
28
- - โšก Agent reference table
29
-
30
- **Perfect for:** Experienced developers, quick setup, command reference
31
-
32
- ---
33
-
34
- ## ๐Ÿ—๏ธ What is BYAN?
35
-
36
- **BYAN (Builder of YAN)** is an intelligent agent creator that generates specialized AI agents through structured interviews.
37
-
38
- **Key Features:**
39
- - 30-45 min intelligent interview process
40
- - Applies 64 mantras systematically
41
- - Zero Trust philosophy (challenges requirements)
42
- - Multi-platform support (Copilot, VSCode, Claude, Codex)
43
- - TDD-driven validation
44
- - Consequences evaluation before actions
45
- - **Core Team:** BYAN (creator), RACHID (npm), MARC (copilot), PATNOTE (updates), CARMACK (optimizer)
46
- - **Optimized:** BYAN-Test version with 46% token reduction
47
-
48
- ---
49
-
50
- ## ๐Ÿš€ Quick Start
51
-
52
- ### Installation
53
-
54
- **Option 1: NPX (Recommended)**
55
- ```bash
56
- npx create-byan-agent
57
- ```
58
-
59
- **Option 2: Bash Script**
60
- ```bash
61
- curl -fsSL https://raw.githubusercontent.com/yan/byan/main/install/install.sh | bash
62
- ```
63
-
64
- **Option 3: Manual**
65
- ```bash
66
- git clone https://github.com/yan/byan.git
67
- cd byan
68
- ./install/install.sh
69
- ```
70
-
71
- ---
72
-
73
- ## ๐Ÿ“– Usage
74
-
75
- ### Activate Agents
76
-
77
- **GitHub Copilot CLI:**
78
- ```bash
79
- copilot
80
- # In interactive mode:
81
- /agent
82
- # Select one of:
83
- # - byan (create agents - standard version)
84
- # - byan-test (create agents - optimized 46% fewer tokens)
85
- # - rachid (NPM deployment specialist)
86
- # - marc (Copilot CLI integration expert)
87
- # - patnote (Update manager & conflict resolution)
88
- # - carmack (Token optimizer for agents)
89
- ```
90
-
91
- **VSCode:**
92
- 1. Open Command Palette (Ctrl+Shift+P)
93
- 2. Type: "Activate Agent"
94
- 3. Select from: BYAN, BYAN-Test, RACHID, MARC, PATNOTE, CARMACK
95
-
96
- **Claude Code:**
97
- ```bash
98
- # Choose your agent:
99
- claude chat --agent byan # Full-featured creator
100
- claude chat --agent byan-test # Optimized creator (46% fewer tokens)
101
- claude chat --agent rachid # NPM deployment
102
- claude chat --agent marc # Copilot CLI integration
103
- claude chat --agent patnote # Update manager
104
- claude chat --agent carmack # Token optimizer
105
- ```
106
-
107
- ### Create Your First Agent
108
-
109
- **Full Interview (30-45 min):**
110
- ```
111
- [INT] Start Intelligent Interview
112
- ```
113
- Best for: First agent, critical agents, complex requirements
114
-
115
- **Quick Create (10 min):**
116
- ```
117
- [QC] Quick Create
118
- ```
119
- Best for: Additional agents, clear requirements, existing project context
120
-
121
- ---
122
-
123
- ## ๐ŸŽฏ Five Specialized Agents
124
-
125
- ### 1. BYAN & BYAN-Test - Agent Creators
126
-
127
- **BYAN (Standard)** - Full-featured agent creator with rich documentation
128
- **BYAN-Test (Optimized)** - Token-optimized version (-46% tokens, same capabilities)
129
-
130
- **Full Interview (30-45 min):**
131
- ```
132
- [INT] Start Intelligent Interview
133
- ```
134
- Best for: First agent, critical agents, complex requirements
135
-
136
- **Quick Create (10 min):**
137
- ```
138
- [QC] Quick Create
139
- ```
140
- Best for: Additional agents, clear requirements, existing project context
141
-
142
- **Role:** Intelligent agent creation through structured interviews. Applies 64 mantras systematically, Zero Trust philosophy, and consequences evaluation.
143
-
144
- ---
145
-
146
- ### 2. RACHID - NPM/NPX Deployment Specialist ๐Ÿ“ฆ
147
-
148
- **Deploy to NPM:**
149
- ```
150
- [PUBLISH] Publish to npm
151
- [VALIDATE] Validate _bmad structure
152
- [TEST-NPX] Test npx installation
153
- [AUDIT] Security audit
154
- [FIX-DEPS] Fix dependencies
155
- ```
156
-
157
- **Role:** Elite Node.js deployment specialist. Masters npm/npx, package.json, create-* CLI patterns. Ensures dependency integrity and secure installations. Trust But Verify philosophy on all packages.
158
-
159
- **Best for:** Package deployment, dependency management, npm workflows, version bumps, publishing to npm registry.
160
-
161
- ---
162
-
163
- ### 3. MARC - GitHub Copilot CLI Integration Expert ๐Ÿ”ง
164
-
165
- **Copilot Integration:**
166
- ```
167
- [VALIDATE] Validate .github/agents/
168
- [TEST] Test /agent detection
169
- [CREATE-STUB] Create agent stub
170
- [FIX-YAML] Fix YAML frontmatter
171
- [MCP-CONFIG] Configure MCP server
172
- ```
173
-
174
- **Role:** GitHub Copilot CLI integration specialist. Ensures agents are properly detected by `/agent` command. Masters YAML frontmatter, MCP configuration, and Copilot CLI debugging.
175
-
176
- **Best for:** GitHub Copilot CLI integration, agent detection issues, MCP server configuration, YAML validation.
177
-
178
- ---
179
-
180
- ### 4. PATNOTE - Update Manager & Conflict Resolution Specialist ๐Ÿ“
181
-
182
- **Update Management:**
183
- ```
184
- [UPDATE-AGENT] Update existing agent
185
- [MERGE-VERSIONS] Merge agent versions
186
- [DETECT-CONFLICTS] Detect conflicts
187
- [BACKUP-RESTORE] Backup/Restore agents
188
- [CHANGELOG] Generate changelog
189
- ```
190
-
191
- **Role:** Guardian of BYAN updates. Detects conflicts between versions, merges changes intelligently, preserves user customizations. Tracks all modifications in detailed changelogs. Never loses data.
192
-
193
- **Best for:** Updating existing agents, merging BYAN versions, resolving conflicts, maintaining agent history.
194
-
195
- ---
196
-
197
- ### 5. CARMACK - Token Optimizer for BMAD/BYAN Agents โšก
198
-
199
- **Token Optimization:**
200
- ```
201
- [OPTIMIZE] Optimize agent for tokens
202
- [ANALYZE] Analyze token usage
203
- [VALIDATE] Validate optimized agent
204
- [COMPARE] Compare before/after
205
- [BATCH] Batch optimize multiple agents
206
- ```
207
-
208
- **Role:** Token optimization expert inspired by John Carmack's efficiency principles. Reduces token usage by 40-50% while preserving functionality. Surgical precision in removing redundancy, restructuring content, and optimizing prompts.
209
-
210
- **Best for:** Reducing LLM token costs, optimizing agent performance, batch processing large agent sets, maintaining quality while cutting tokens.
211
-
212
- ---
213
-
214
- ## ๐ŸŽฏ BYAN Menu
215
-
216
- | Command | Description | Duration |
217
- |---------|-------------|----------|
218
- | **[INT]** | Intelligent Interview | 30-45 min |
219
- | **[QC]** | Quick Create | 10 min |
220
- | **[LA]** | List all agents | Instant |
221
- | **[EA]** | Edit existing agent | 10-20 min |
222
- | **[VA]** | Validate agent (64 mantras) | 5-10 min |
223
- | **[DA-AGENT]** | Delete agent (with backup) | 5 min |
224
- | **[PC]** | Show project context | Instant |
225
- | **[MAN]** | Display 64 mantras | Instant |
226
-
227
- ---
228
-
229
- ## ๐Ÿ“š Methodology
230
-
231
- BYAN applies **Merise Agile + TDD** with 64 mantras:
232
-
233
- ### 39 Conception Mantras
234
- - Philosophy: Model serves business, not reverse
235
- - Agility: User stories โ†’ Entities (bottom-up)
236
- - Quality: KISS, DRY, YAGNI
237
- - Tests: TDD is not optional
238
- - Merise Rigor: Data Dictionary First, MCD โ‡„ MCT
239
- - Problem Solving: Ockham's Razor, Inversion techniques
240
- - **Consequences: Evaluate 10 dimensions before action**
241
-
242
- ### 25 AI Agent Mantras
243
- - Intelligence: Trust But Verify, Context is King
244
- - **Validation: Challenge Before Confirm**
245
- - Autonomy: Self-Aware Agent
246
- - **Code Quality: No Emoji Pollution, Clean Code**
247
-
248
- Full list: `_bmad/bmb/workflows/byan/data/mantras.yaml`
249
-
250
- ---
251
-
252
- ## ๐Ÿ”ง Project Structure
253
-
254
- ```
255
- your-project/
256
- โ”œโ”€โ”€ _bmad/
257
- โ”‚ โ”œโ”€โ”€ bmb/ # BYAN Module
258
- โ”‚ โ”‚ โ”œโ”€โ”€ agents/
259
- โ”‚ โ”‚ โ”‚ โ””โ”€โ”€ byan.md # BYAN agent definition
260
- โ”‚ โ”‚ โ”œโ”€โ”€ workflows/
261
- โ”‚ โ”‚ โ”‚ โ””โ”€โ”€ byan/
262
- โ”‚ โ”‚ โ”‚ โ”œโ”€โ”€ interview-workflow.md
263
- โ”‚ โ”‚ โ”‚ โ”œโ”€โ”€ quick-create-workflow.md
264
- โ”‚ โ”‚ โ”‚ โ”œโ”€โ”€ edit-agent-workflow.md
265
- โ”‚ โ”‚ โ”‚ โ”œโ”€โ”€ validate-agent-workflow.md
266
- โ”‚ โ”‚ โ”‚ โ”œโ”€โ”€ delete-agent-workflow.md
267
- โ”‚ โ”‚ โ”‚ โ”œโ”€โ”€ templates/
268
- โ”‚ โ”‚ โ”‚ โ”‚ โ””โ”€โ”€ base-agent-template.md
269
- โ”‚ โ”‚ โ”‚ โ””โ”€โ”€ data/
270
- โ”‚ โ”‚ โ”‚ โ”œโ”€โ”€ mantras.yaml
271
- โ”‚ โ”‚ โ”‚ โ””โ”€โ”€ templates.yaml
272
- โ”‚ โ”‚ โ””โ”€โ”€ config.yaml # Module configuration
273
- โ”‚ โ”œโ”€โ”€ core/ # BMAD Core
274
- โ”‚ โ”œโ”€โ”€ _output/ # Generated files
275
- โ”‚ โ””โ”€โ”€ {your-module}/
276
- โ”‚ โ””โ”€โ”€ agents/ # Your generated agents
277
- โ””โ”€โ”€ install/
278
- โ”œโ”€โ”€ install.sh # Bash installer
279
- โ”œโ”€โ”€ package.json # NPX package
280
- โ””โ”€โ”€ bin/
281
- โ””โ”€โ”€ create-byan-agent.js # NPX installer script
282
- ```
283
-
284
- ---
285
-
286
- ## ๐ŸŽ“ Interview Process
287
-
288
- BYAN conducts a 4-phase interview:
289
-
290
- ### Phase 1: Project Context (15-30 min)
291
- - Project name, description, domain
292
- - Technical stack and constraints
293
- - Team size, skills, maturity
294
- - **Pain points (5 Whys on main pain)**
295
- - Goals and success criteria
296
-
297
- ### Phase 2: Business/Domain (15-20 min)
298
- - Business domain deep dive
299
- - **Interactive glossary (minimum 5 concepts)**
300
- - Actors, processes, business rules
301
- - Edge cases and constraints
302
- - Regulatory requirements
303
-
304
- ### Phase 3: Agent Needs (10-15 min)
305
- - Agent role and responsibilities
306
- - Required knowledge (business + technical)
307
- - **Capabilities (minimum 3)**
308
- - **Mantras to prioritize (minimum 5)**
309
- - Communication style
310
- - **Use cases (minimum 3)**
311
-
312
- ### Phase 4: Validation (10 min)
313
- - Complete synthesis
314
- - **Challenge inconsistencies**
315
- - Validate with user
316
- - Create ProjectContext
317
- - Finalize AgentSpec
318
-
319
- ---
320
-
321
- ## โœ… Validation
322
-
323
- BYAN validates agents against:
324
- - Business rules (RG-AGT-001 to RG-DEL-002)
325
- - 64 Mantras compliance
326
- - BMAD format standards
327
- - Best practices
328
-
329
- **Validation Levels:**
330
- - ๐Ÿ”ด CRITICAL: Must pass (deployment blocked)
331
- - ๐ŸŸก IMPORTANT: Should pass (warnings)
332
- - ๐ŸŸข SUGGESTIONS: Nice to have
333
-
334
- **Grading:**
335
- - A+ (95-100): Exemplary
336
- - A (90-94): Excellent
337
- - B (80-89): Good
338
- - C (70-79): Acceptable
339
- - D (60-69): Needs improvement
340
- - F (<60): Failing
341
-
342
- ---
343
-
344
- ## ๐Ÿ›ก๏ธ Zero Trust Philosophy
345
-
346
- BYAN never blindly accepts requirements:
347
-
348
- **Challenge Before Confirm:**
349
- - Detects inconsistencies
350
- - Questions assumptions
351
- - Plays devil's advocate
352
- - Signals problems early
353
-
354
- **Trust But Verify:**
355
- - Validates all inputs
356
- - Cross-checks data
357
- - Ensures coherence
358
-
359
- **Example:**
360
- ```
361
- User: "I need an agent that does everything"
362
- BYAN: "I'm challenging that requirement. Wouldn't a specialized
363
- agent that does ONE thing exceptionally well be more valuable?
364
- What's the ONE most critical capability you need?"
365
- ```
366
-
367
- ---
368
-
369
- ## ๐Ÿ“Š Consequences Evaluation
370
-
371
- Before any important action, BYAN evaluates 10 dimensions:
372
-
373
- 1. **Scope:** Components affected
374
- 2. **Data:** Database impacts
375
- 3. **Code:** Files to modify
376
- 4. **Team:** People affected
377
- 5. **Clients:** User workflows
378
- 6. **Legal:** Compliance
379
- 7. **Operations:** Deployment complexity
380
- 8. **Dependencies:** Systems impacted
381
- 9. **Time:** Duration estimates
382
- 10. **Alternatives:** Other options
383
-
384
- **Risk Levels:**
385
- - ๐ŸŸข LOW: Safe to proceed
386
- - ๐ŸŸก MEDIUM: Caution required
387
- - ๐Ÿ”ด HIGH: Team approval needed
388
- - ๐Ÿ”ฅ CRITICAL: Requires migration plan
389
-
390
- ---
391
-
392
- ## ๐Ÿ“ Configuration
393
-
394
- Edit `_bmad/bmb/config.yaml`:
395
-
396
- ```yaml
397
- user_name: Your Name
398
- communication_language: Francais|English
399
- document_output_language: Francais|English
400
- output_folder: "{project-root}/_bmad-output"
401
- platform: copilot|vscode|claude|codex
402
- ```
403
-
404
- ---
405
-
406
- ## ๐Ÿ“„ License
407
-
408
- MIT License - See LICENSE file
409
-
410
- ---
411
-
412
- ## ๐Ÿ™ Credits
413
-
414
- **Created by:** Yan + Carson (Brainstorming Coach)
415
- **Methodology:** Merise Agile + TDD
416
- **Mantras:** 64 principles from 2-hour brainstorming session
417
- **Date:** 2026-02-02
418
-
419
- ---
420
-
421
- **Happy agent building!** ๐Ÿ—๏ธ
1
+ # ๐Ÿ—๏ธ YANSTALLER - Intelligent BYAN Installer
2
+
3
+ [![Version](https://img.shields.io/badge/version-1.1.3-blue.svg)](https://www.npmjs.com/package/create-byan-agent)
4
+ [![License](https://img.shields.io/badge/license-MIT-green.svg)](LICENSE)
5
+ [![Node](https://img.shields.io/badge/node-%3E%3D18.0.0-brightgreen.svg)](https://nodejs.org)
6
+ [![Tests](https://img.shields.io/badge/tests-168%20passing-success.svg)](#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
+ [![Version](https://img.shields.io/badge/version-1.1.3-blue.svg)](https://www.npmjs.com/package/create-byan-agent)
847
+ [![License](https://img.shields.io/badge/license-MIT-green.svg)](LICENSE)
848
+ [![Node](https://img.shields.io/badge/node-%3E%3D18.0.0-brightgreen.svg)](https://nodejs.org)
849
+ [![Tests](https://img.shields.io/badge/tests-168%20passing-success.svg)](#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**