@atlashub/smartstack-cli 3.1.0 → 3.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.
@@ -0,0 +1,462 @@
1
+ # Business Analyse E2E Testing Infrastructure
2
+
3
+ ## Vue d'ensemble
4
+
5
+ Infrastructure de tests E2E pour valider le pipeline complet **Business Analyse → Handoff → PRD extraction → Ralph Loop**.
6
+
7
+ **Garanties :**
8
+ - ✅ Validation déterministe du handoff
9
+ - ✅ Extraction programmatique prd.json (zéro hallucination)
10
+ - ✅ Reproductibilité parfaite
11
+ - ✅ Couverture complète des cas d'usage
12
+
13
+ ---
14
+
15
+ ## Architecture
16
+
17
+ ```
18
+ tests/ba/
19
+ ├── fixtures/ # Test data (feature.json examples)
20
+ │ ├── simple-feature.json # Module simple (Orders, 1 entity, 2 UCs, 3 BRs)
21
+ │ ├── medium-feature.json # Module medium (Invoices, lifecycle, 4 entities, 6 UCs)
22
+ │ ├── complex-application.json # Application multi-modules (3 modules, dépendances)
23
+ │ └── complex-app/ # Modules référencés par complex-application.json
24
+ │ ├── Customers/
25
+ │ ├── Products/
26
+ │ └── Orders/
27
+
28
+ └── e2e/ # Test suites E2E
29
+ ├── handoff-validation.test.ts # Validation handoff section
30
+ ├── prd-extraction-simple.test.ts # Extraction module simple
31
+ ├── prd-extraction-medium.test.ts # Extraction module lifecycle
32
+ └── full-pipeline.test.ts # Pipeline complet BA → Ralph Loop
33
+ ```
34
+
35
+ ---
36
+
37
+ ## Fixtures
38
+
39
+ ### simple-feature.json
40
+
41
+ **Module:** Orders
42
+ **Complexité:** Basique CRUD
43
+ **Contenu:**
44
+ - 1 entity (Order)
45
+ - 2 use cases (Create, List)
46
+ - 3 business rules (2 validation, 1 calculation)
47
+ - 2 API endpoints
48
+ - 4 permissions
49
+ - 7 file categories
50
+
51
+ **Use case:** Tester extraction basique sans lifecycle.
52
+
53
+ ### medium-feature.json
54
+
55
+ **Module:** Invoices
56
+ **Complexité:** Workflow avec lifecycle
57
+ **Contenu:**
58
+ - 4 entities (Invoice, InvoiceLine, Customer, Payment)
59
+ - 6 use cases (Create, Issue, Pay, List, View, Cancel)
60
+ - 6 business rules (2 validation, 2 workflow, 2 calculation)
61
+ - 3 API endpoints (dont 2 transitions)
62
+ - 1 lifecycle (4 états: draft → issued → paid, cancelled)
63
+ - 2 seedData business (InvoiceStatus, PaymentMethod)
64
+
65
+ **Use case:** Tester extraction avec lifecycle states et transitions.
66
+
67
+ ### complex-application.json + modules
68
+
69
+ **Application:** SalesManagement
70
+ **Complexité:** Multi-modules avec dépendances
71
+ **Contenu:**
72
+ - 3 modules: Customers, Products, Orders
73
+ - Dependency graph: Orders → Customers + Products
74
+ - 4 application roles (admin, manager, salesperson, viewer)
75
+
76
+ **Use case:** Tester mode `--application` et génération multi-prd.json.
77
+
78
+ ---
79
+
80
+ ## Tests E2E
81
+
82
+ ### 1. handoff-validation.test.ts
83
+
84
+ **Objectif:** Valider la fonction `validateForPrdExtraction()`.
85
+
86
+ **Scénarios:**
87
+ - ✅ Feature complet simple passe validation
88
+ - ✅ Feature complet medium passe validation
89
+ - ❌ Feature sans `metadata.application` échoue
90
+ - ❌ Feature sans `metadata.module` échoue
91
+ - ❌ Feature avec `status !== "handed-off|approved|consolidated"` échoue
92
+ - ❌ Feature sans use cases échoue
93
+ - ❌ Feature sans business rules échoue
94
+ - ❌ Feature sans `filesToCreate` échoue
95
+ - ✅ Feature avec status "approved" passe
96
+ - ✅ Feature avec status "consolidated" passe
97
+ - ✅ Medium feature a lifecycle défini (4 états)
98
+ - ✅ Medium feature a 7 catégories de fichiers
99
+ - ✅ BR to code mappings complets
100
+ - ✅ CORE seedData obligatoire (NavigationModule, Permission)
101
+
102
+ ### 2. prd-extraction-simple.test.ts
103
+
104
+ **Objectif:** Tester extraction prd.json pour module simple.
105
+
106
+ **Scénarios:**
107
+ - Extraction complète sans erreur
108
+ - Metadata projet (application, module, namespace)
109
+ - Use cases (2) avec actor, permission, steps, linkedRules
110
+ - Functional requirements (3) avec priority, linkedUCs
111
+ - Business rules (3) avec category, statement, priority
112
+ - Entities (1) avec attributes, type
113
+ - API endpoints (2) avec method, route, permission, linkedUC
114
+ - Permission matrix (4 permissions) avec scope
115
+ - Sections (1) avec resources
116
+ - FilesToCreate (7 catégories)
117
+ - BrToCodeMapping (2 mappings) avec targetFile, targetMethod, implementationType
118
+ - SeedData (core + business)
119
+ - Implementation strategy ("module-by-module")
120
+ - Source traceability (extractedAt, featureJsonPath)
121
+
122
+ ### 3. prd-extraction-medium.test.ts
123
+
124
+ **Objectif:** Tester extraction prd.json avec lifecycle.
125
+
126
+ **Scénarios:**
127
+ - Extraction complète avec lifecycle
128
+ - Multiple entities (4) avec relationships
129
+ - Lifecycle states (4) avec allowedTransitions
130
+ - Lifecycle transitions (2) avec action, permission, guards
131
+ - Terminal states (2: paid, cancelled)
132
+ - Workflow business rules (2) mappés au code
133
+ - Calculation business rules (2) avec formulas
134
+ - Multiple use cases (6) incluant transitions
135
+ - Transition API endpoints (2: /issue, /pay)
136
+ - Multiple seedData business entities (2)
137
+ - Multiple domain files (4 entities)
138
+ - Integration tests en plus des unit tests
139
+ - BR mappings complets pour critical rules
140
+
141
+ ### 4. full-pipeline.test.ts
142
+
143
+ **Objectif:** Tester pipeline complet BA → Ralph Loop.
144
+
145
+ **Scénarios:**
146
+
147
+ **Simple Module Pipeline:**
148
+ 1. Load feature.json (status = "handed-off")
149
+ 2. Validate handoff section complet
150
+ 3. Extract prd.json déterministe
151
+ 4. Write prd.json to .ralph/
152
+ 5. Read back prd.json (verify integrity)
153
+ 6. Verify all required sections for Ralph Loop
154
+ 7. Verify prd.json meets Ralph Loop requirements (7 categories, BR mappings, CORE seedData)
155
+
156
+ **Medium Module Pipeline with Lifecycle:**
157
+ 1. Load medium feature with lifecycle
158
+ 2. Validate handoff including lifecycle
159
+ 3. Extract prd.json with lifecycle preserved
160
+ 4. Verify lifecycle transitions mapped to BR
161
+ 5. Verify lifecycle states match seedData
162
+ 6. Write prd.json to .ralph/
163
+
164
+ **Reproducibility Test:**
165
+ - Multiple extractions = identical prd.json (sans timestamp)
166
+
167
+ **Error Handling:**
168
+ - Missing optional namespace handled gracefully
169
+ - Empty arrays handled gracefully
170
+
171
+ **Integration with Ralph Loop:**
172
+ - All required information present (entities, UCs, BRs, endpoints, permissions, filesToCreate, BR mappings, CORE seedData)
173
+ - Use cases linked to API endpoints
174
+ - Business rules linked to use cases
175
+
176
+ ---
177
+
178
+ ## Exécution des Tests
179
+
180
+ ### Installation
181
+
182
+ ```bash
183
+ # Les dépendances de test sont déjà installées (vitest, @vitest/coverage-v8)
184
+ npm install
185
+ ```
186
+
187
+ ### Commandes
188
+
189
+ ```bash
190
+ # Exécuter tous les tests BA E2E
191
+ npm run test:ba
192
+
193
+ # Exécuter tests BA E2E en mode watch (développement)
194
+ npm run test:ba:watch
195
+
196
+ # Exécuter tests BA E2E avec couverture
197
+ npm run test:ba:coverage
198
+
199
+ # Exécuter TOUS les tests (MCP + BA)
200
+ npm run test:all
201
+ ```
202
+
203
+ ### Filtrage des Tests
204
+
205
+ ```bash
206
+ # Exécuter un seul fichier de test
207
+ npx vitest run tests/ba/e2e/handoff-validation.test.ts
208
+
209
+ # Exécuter tests contenant "lifecycle" dans le nom
210
+ npx vitest run --grep lifecycle
211
+
212
+ # Exécuter tests en mode watch avec filtrage
213
+ npx vitest --grep extraction
214
+ ```
215
+
216
+ ### Couverture de Code
217
+
218
+ ```bash
219
+ npm run test:ba:coverage
220
+
221
+ # Rapport généré dans: coverage/
222
+ # Ouvrir: coverage/index.html
223
+ ```
224
+
225
+ ---
226
+
227
+ ## Ajouter de Nouveaux Tests
228
+
229
+ ### 1. Créer une Nouvelle Fixture
230
+
231
+ Créer `tests/ba/fixtures/my-feature.json` :
232
+
233
+ ```json
234
+ {
235
+ "id": "FEAT-TEST-XXX",
236
+ "version": "5.0.0",
237
+ "status": "handed-off",
238
+ "metadata": {
239
+ "application": "MyApp",
240
+ "module": "MyModule",
241
+ "context": "business"
242
+ },
243
+ "discovery": { ... },
244
+ "analysis": {
245
+ "businessRules": [...],
246
+ "entities": [...]
247
+ },
248
+ "specification": {
249
+ "useCases": [...],
250
+ "functionalRequirements": [...],
251
+ "apiEndpoints": [...],
252
+ "permissionMatrix": { ... },
253
+ "sections": [...],
254
+ "seedDataCore": [...]
255
+ },
256
+ "handoff": {
257
+ "implementationStrategy": "module-by-module",
258
+ "filesToCreate": {
259
+ "domain": [...],
260
+ "application": [...],
261
+ "infrastructure": [...],
262
+ "api": [...],
263
+ "frontend": [...],
264
+ "seedData": [...],
265
+ "tests": [...]
266
+ },
267
+ "brToCodeMapping": [...]
268
+ }
269
+ }
270
+ ```
271
+
272
+ **Checklist fixture valide:**
273
+ - ✅ `status` = "handed-off" | "approved" | "consolidated"
274
+ - ✅ `metadata.application` et `metadata.module` présents
275
+ - ✅ `specification.useCases[]` non vide
276
+ - ✅ `analysis.businessRules[]` non vide
277
+ - ✅ `handoff.filesToCreate` avec 7 catégories
278
+ - ✅ `specification.seedDataCore` avec NavigationModule + Permission
279
+
280
+ ### 2. Créer un Nouveau Test
281
+
282
+ Créer `tests/ba/e2e/my-test.test.ts` :
283
+
284
+ ```typescript
285
+ import { describe, it, expect } from 'vitest';
286
+ import { extractPrd, validateForPrdExtraction } from '../../../src/utils/prd-extractor.js';
287
+ import type { ModuleFeatureJson } from '../../../src/types/feature-json.js';
288
+ import fs from 'fs-extra';
289
+ import { join } from 'path';
290
+
291
+ describe('My Test Suite', () => {
292
+ const fixturesDir = join(__dirname, '../fixtures');
293
+
294
+ it('should validate my scenario', async () => {
295
+ const feature = await fs.readJson(join(fixturesDir, 'my-feature.json')) as ModuleFeatureJson;
296
+ const errors = validateForPrdExtraction(feature);
297
+
298
+ expect(errors).toEqual([]);
299
+ });
300
+
301
+ it('should extract prd.json correctly', () => {
302
+ const feature = await fs.readJson(join(fixturesDir, 'my-feature.json')) as ModuleFeatureJson;
303
+ const prd = extractPrd(feature, 'my-feature.json', 'MyCompany.MyApp');
304
+
305
+ expect(prd.version).toBe('2.0.0');
306
+ expect(prd.project.module).toBe('MyModule');
307
+ // ... more assertions
308
+ });
309
+ });
310
+ ```
311
+
312
+ ### 3. Exécuter le Nouveau Test
313
+
314
+ ```bash
315
+ npx vitest run tests/ba/e2e/my-test.test.ts
316
+ ```
317
+
318
+ ---
319
+
320
+ ## Intégration CI/CD
321
+
322
+ ### Azure Pipelines
323
+
324
+ Ajouter dans `azure-pipelines.yml` :
325
+
326
+ ```yaml
327
+ - stage: Test
328
+ jobs:
329
+ - job: UnitTests
330
+ steps:
331
+ - task: Npm@1
332
+ inputs:
333
+ command: 'custom'
334
+ customCommand: 'run test:ba'
335
+ displayName: 'Run BA E2E Tests'
336
+
337
+ - task: PublishTestResults@2
338
+ inputs:
339
+ testResultsFormat: 'JUnit'
340
+ testResultsFiles: '**/test-results.xml'
341
+ displayName: 'Publish Test Results'
342
+
343
+ - task: PublishCodeCoverageResults@1
344
+ inputs:
345
+ codeCoverageTool: 'Cobertura'
346
+ summaryFileLocation: '**/coverage/cobertura-coverage.xml'
347
+ displayName: 'Publish Code Coverage'
348
+ ```
349
+
350
+ ### GitHub Actions
351
+
352
+ ```yaml
353
+ name: Tests
354
+ on: [push, pull_request]
355
+
356
+ jobs:
357
+ test:
358
+ runs-on: ubuntu-latest
359
+ steps:
360
+ - uses: actions/checkout@v3
361
+ - uses: actions/setup-node@v3
362
+ with:
363
+ node-version: '18'
364
+ - run: npm install
365
+ - run: npm run test:ba
366
+ - name: Upload coverage
367
+ uses: codecov/codecov-action@v3
368
+ with:
369
+ files: ./coverage/coverage-final.json
370
+ ```
371
+
372
+ ---
373
+
374
+ ## Métriques de Qualité
375
+
376
+ ### Objectifs de Couverture
377
+
378
+ | Fichier | Couverture Cible |
379
+ |---------|-----------------|
380
+ | `src/utils/prd-extractor.ts` | 100% |
381
+ | `src/commands/derive-prd.ts` | 90% |
382
+ | `templates/skills/business-analyse/**/*.md` | N/A (documentation) |
383
+
384
+ ### KPIs Tests
385
+
386
+ - **Total tests:** ~60 scénarios
387
+ - **Temps d'exécution:** < 10s
388
+ - **Fixtures:** 3 (simple/medium/complex)
389
+ - **Couverture code:** > 95% sur extraction pipeline
390
+
391
+ ---
392
+
393
+ ## Dépannage
394
+
395
+ ### Erreur: "Cannot find module '...'"
396
+
397
+ **Cause:** Imports relatifs incorrects ou TypeScript non compilé.
398
+
399
+ **Solution:**
400
+ ```bash
401
+ npm run build
402
+ npm run test:ba
403
+ ```
404
+
405
+ ### Erreur: "Feature status is X"
406
+
407
+ **Cause:** Fixture a `status !== "handed-off"`.
408
+
409
+ **Solution:** Mettre `status: "handed-off"` dans la fixture.
410
+
411
+ ### Erreur: "No use cases found"
412
+
413
+ **Cause:** `specification.useCases[]` est vide dans la fixture.
414
+
415
+ **Solution:** Ajouter au moins 1 use case dans la fixture.
416
+
417
+ ### Tests timeouts
418
+
419
+ **Cause:** Tests E2E dépassent 30s.
420
+
421
+ **Solution:** Augmenter `testTimeout` dans `vitest.ba.config.ts` :
422
+
423
+ ```typescript
424
+ export default defineConfig({
425
+ test: {
426
+ testTimeout: 60000, // 60s
427
+ },
428
+ });
429
+ ```
430
+
431
+ ---
432
+
433
+ ## Roadmap
434
+
435
+ ### Phase 1 ✅ (Implémenté)
436
+ - Infrastructure Vitest
437
+ - 3 fixtures (simple/medium/complex)
438
+ - 4 test suites (handoff-validation, prd-extraction x2, full-pipeline)
439
+ - Scripts npm
440
+ - Documentation
441
+
442
+ ### Phase 2 (Futur)
443
+ - Tests pour mode `--application` (extraction multi-modules)
444
+ - Tests pour mode `--strict`
445
+ - Tests pour cross-module dependencies
446
+ - Performance benchmarks (extraction < 100ms)
447
+ - Tests pour ba-interactive.html extraction
448
+
449
+ ### Phase 3 (Futur)
450
+ - Tests E2E Ralph Loop integration (mock Ralph Loop server)
451
+ - Tests pour step-05-handoff.md (génération handoff)
452
+ - Tests pour derive-prd CLI (end-to-end avec fs.existsSync)
453
+ - Tests pour validation schema (feature-schema.json)
454
+
455
+ ---
456
+
457
+ ## Voir aussi
458
+
459
+ - [prd-json v2.0.0 Reference](./prd-json-v2.0.0.md)
460
+ - [Feature JSON Schema](../templates/skills/business-analyse/schemas/feature-schema.json)
461
+ - [Business Analyse Skill](../templates/skills/business-analyse/SKILL.md)
462
+ - [Ralph Loop Documentation](../templates/skills/ralph-loop/SKILL.md)
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@atlashub/smartstack-cli",
3
- "version": "3.1.0",
3
+ "version": "3.2.0",
4
4
  "description": "SmartStack Claude Code automation toolkit - GitFlow, EF Core migrations, prompts and more",
5
5
  "author": {
6
6
  "name": "SmartStack",
@@ -72,7 +72,11 @@
72
72
  "health": "node dist/index.js doctor --json",
73
73
  "test:mcp": "vitest run --config vitest.mcp.config.ts",
74
74
  "test:mcp:watch": "vitest --config vitest.mcp.config.ts",
75
- "test:mcp:coverage": "vitest run --config vitest.mcp.config.ts --coverage"
75
+ "test:mcp:coverage": "vitest run --config vitest.mcp.config.ts --coverage",
76
+ "test:ba": "vitest run --config vitest.ba.config.ts",
77
+ "test:ba:watch": "vitest --config vitest.ba.config.ts",
78
+ "test:ba:coverage": "vitest run --config vitest.ba.config.ts --coverage",
79
+ "test:all": "npm run test:mcp && npm run test:ba"
76
80
  },
77
81
  "dependencies": {
78
82
  "@modelcontextprotocol/sdk": "^1.0.0",
@@ -1,11 +1,17 @@
1
1
  ---
2
2
  name: business-analyse
3
- description: Business Analysis v5.0 - Iterative multi-module workflow with 5-level navigation hierarchy, client checkpoints, interactive HTML documentation, and extraction pipeline.
3
+ description: Business Analysis v6.1 - Iterative multi-module workflow with optimized performance (schema caching), automatic skill launch transition, and streamlined execution.
4
4
  argument-hint: "[-a] [-e] [-q <FEAT-ID> \"question\"] [-r <FEAT-ID> \"change\"] [-m] [-x <json-path>] <feature description>"
5
5
  ---
6
6
 
7
7
  <objective>
8
8
  Execute VibeCoding-focused business analysis workflows. This skill produces a single feature.json progressively enriched at each step, published to docs/business/ for web app rendering. Supports 5 use cases: new feature analysis, questions about existing features, feature refactoring, one-shot micro-features, and extraction from interactive HTML documentation.
9
+
10
+ **New in v6.1:**
11
+ - ⚡ **Performance:** Schema deployment caching (~75% faster subsequent runs)
12
+ - 🚀 **Seamless transition:** Automatic launch of chosen development approach (Ralph Loop / Feature Full)
13
+ - 🎯 **Simplified:** Removed interactive mode (-i flag), streamlined execution
14
+ - 📂 **Modern only:** Legacy `.business-analyse/` structure no longer supported
9
15
  </objective>
10
16
 
11
17
  <quick_start>
@@ -50,7 +56,6 @@ See `<parameters>` for complete flag list.
50
56
  | `-m` | `--micro` | Micro-feature mode: minimal questions, direct handoff |
51
57
  | `-x` | `--extract` | Extract mode: import from interactive HTML export JSON (requires json-path) |
52
58
  | `-app` | `--application` | Application mode: multi-module analysis with module decomposition |
53
- | `-i` | `--interactive` | Interactive mode: configure flags via AskUserQuestion |
54
59
 
55
60
  **Disable flags (turn OFF):**
56
61
  | Short | Long | Description |
@@ -178,6 +183,10 @@ When provided, step-00 will:
178
183
  - Per-module validation + client confirmation
179
184
  - **Step 04:** Cross-module consolidation (consolidated)
180
185
  - **Step 05:** Handoff with per-module prd.json (handed-off)
186
+ - **NEW v6.1:** User chooses development approach (AskUserQuestion)
187
+ - **If "Ralph Loop":** Automatic launch → `/ralph-loop` (seamless transition)
188
+ - **If "Feature Full":** Automatic launch → `/feature-full` (parallel generation)
189
+ - **If "Terminer":** BA ends, manual development
181
190
 
182
191
  **Single module workflow (same phases, simplified):**
183
192
  - **Step 00:** Parse flags, create master feature.json (draft)
@@ -186,10 +195,12 @@ When provided, step-00 will:
186
195
  - **Step 03:** Specification: single iteration (specified)
187
196
  - **Step 04:** Consolidation: auto-pass (consolidated)
188
197
  - **Step 05:** Handoff (handed-off)
198
+ - **NEW v6.1:** Automatic skill launch based on user choice
189
199
 
190
200
  **Micro workflow:**
191
201
  - **Step 00:** Create minimal feature.json
192
202
  - **Step 05:** Direct handoff (skip 01-04)
203
+ - **NEW v6.1:** Automatic skill launch
193
204
 
194
205
  **Extract workflow (from interactive HTML):**
195
206
  - **Step 00:** Parse `-x` flag, validate JSON file
@@ -244,21 +255,27 @@ Load ONLY relevant categories based on feature type:
244
255
 
245
256
  | Categorie | Fichier | Questions | Quand charger |
246
257
  | --------- | ------------------------------------- | --------- | ------------- |
247
- | 00 | `questionnaire/00-application.md` | 8 | Si mode application |
248
- | 01 | `questionnaire/01-context.md` | 12 | Toujours |
249
- | 02 | `questionnaire/02-stakeholders.md` | 14 | Toujours |
250
- | 03 | `questionnaire/03-scope.md` | 12 | Toujours |
251
- | 04 | `questionnaire/04-data.md` | 8 | Si module oriente donnees |
252
- | 05 | `questionnaire/05-integrations.md` | 8 | Si integrations |
253
- | 06 | `questionnaire/06-security.md` | 8 | Si securite mentionnee |
254
- | 07 | `questionnaire/07-ui.md` | 12 | Si module oriente interface |
255
- | 08 | `questionnaire/08-performance.md` | 4 | Si performance critique |
256
- | 09 | `questionnaire/09-constraints.md` | 4 | Si contraintes |
257
- | 10 | `questionnaire/10-documentation.md` | 4 | Si documentation requise |
258
- | 14 | `questionnaire/14-risk-assumptions.md`| 8 | Toujours |
259
- | 15 | `questionnaire/15-success-metrics.md` | 8 | Toujours |
260
-
261
- **Total noyau : ~86 questions (en profondeur, langage business)**
258
+ | 00 | `questionnaire/00-application.md` | 18 | Si mode application |
259
+ | 01 | `questionnaire/01-context.md` | 32 | Toujours |
260
+ | 02 | `questionnaire/02-stakeholders.md` | 33 | Toujours |
261
+ | 03 | `questionnaire/03-scope.md` | 32 | Toujours |
262
+ | 04 | `questionnaire/04-data.md` | 15 | Si module oriente donnees |
263
+ | 05 | `questionnaire/05-integrations.md` | 14 | Si integrations |
264
+ | 06 | `questionnaire/06-security.md` | 13 | Si securite mentionnee |
265
+ | 07 | `questionnaire/07-ui.md` | 19 | Si module oriente interface |
266
+ | 08 | `questionnaire/08-performance.md` | 8 | Si performance critique |
267
+ | 09 | `questionnaire/09-constraints.md` | 6 | Si contraintes |
268
+ | 10 | `questionnaire/10-documentation.md` | 7 | Si documentation requise |
269
+ | 11 | `questionnaire/11-data-lifecycle.md` | 14 | Si lifecycle requis (retention, archivage, RGPD) |
270
+ | 12 | `questionnaire/12-migration.md` | 14 | Si nouveau module (migration donnees existantes) |
271
+ | 13 | `questionnaire/13-cross-module.md` | 14 | Si nouveau module OU references autres modules |
272
+ | 14 | `questionnaire/14-risk-assumptions.md`| 16 | Toujours |
273
+ | 15 | `questionnaire/15-success-metrics.md` | 17 | Toujours |
274
+
275
+ **Total noyau (toujours chargés) : 130 questions** (contexte, acteurs, périmètre, risques, métriques)
276
+ **Total avec application : 148 questions** (+ identité application si mode multi-module)
277
+ **Total conditionnel : 124 questions** (data, intégrations, sécurité, UI, performance, contraintes, doc, lifecycle, migration, cross-module)
278
+ **Total maximum possible : 272 questions** (noyau + application + tous conditionnels chargés)
262
279
 
263
280
  </questionnaire_files>
264
281