23 KiB
| name | description | version | module | phases | questions_per_phase | total_questions |
|---|---|---|---|---|---|---|
| yanstaller-interview-workflow | Workflow d'installation et configuration BYAN via interview métier | 2.0.0 | yanstaller | 4 | 3 | 12 |
Yanstaller Interview Workflow
Vue d'ensemble
Yanstaller est l'agent d'installation intelligent de BYAN v2. Via une interview métier de 12 questions, il configure BYAN dans votre projet en installant les agents appropriés et en personnalisant la configuration.
Durée estimée: 5-10 minutes
Questions totales: 12 (3 par phase)
Format: Conversationnel avec options à sélectionner
Résultat: Projet BYAN opérationnel avec agents installés
Différence avec BYAN v2 Interview
| Aspect | BYAN v2 Interview | Yanstaller Interview |
|---|---|---|
| Objectif | Créer UN agent | Installer BYAN dans projet |
| Quand? | Après installation BYAN | Pendant installation BYAN |
| Questions | Techniques (agent) | Métier (projet/équipe) |
| Résultat | 1 profil agent .md | Structure _byan/ complète + agents |
| Workflow | interview-workflow.md |
yanstaller-interview-workflow.md |
Architecture du Workflow
Machine à États
INIT
→ INSTALLER_INTERVIEW (4 phases)
→ PROJECT_CONTEXT (Q1-Q3)
→ BUSINESS_NEEDS (Q4-Q6)
→ AGENT_SELECTION (Q7-Q9)
→ CONFIGURATION (Q10-Q12)
→ SETUP_STRUCTURE
→ INSTALL_AGENTS
→ CONFIGURE
→ COMPLETED
Workers Impliqués
- yanstaller/interview-installer.js - Gestion interview installation
- yanstaller/agent-selector.js - Sélection agents via checkboxes
- yanstaller/agent-importer.js - Import agents (GitHub/NPM/Local)
- yanstaller/importers/ - Importers spécifiques par source
- context/session-state.js - Persistance réponses
- generation/profile-template.js - Configuration template
Phase 1: PROJECT_CONTEXT (Questions 1-3)
Objectif: Comprendre le contexte projet, stack, équipe
Question 1: Type de projet
"Quel type de projet développes-tu?"
Options (sélection unique):
- Web Application (frontend + backend)
- Mobile Application (iOS/Android/React Native)
- CLI Tool / Command-line application
- Library / Framework / Package
- Desktop Application (Electron, Tauri)
- Microservices / API Backend
- Data Science / ML / AI Project
- DevOps / Infrastructure as Code
- Autre (préciser)
Impact:
- Détermine agents recommandés
- Influence templates par défaut
- Configure output structure
Exemples:
- Web App → Recommande: code-review, test-automation, doc-writer
- CLI Tool → Recommande: command-builder, test-runner
- Library → Recommande: api-doc-generator, version-manager
Question 2: Stack technique principale
"Quelle est ta stack technique principale?"
Options (multi-sélection possible):
- JavaScript / TypeScript / Node.js
- Python
- Go
- Java / Kotlin
- C# / .NET
- Ruby
- PHP
- Rust
- Swift
- React / Vue / Angular (frontend frameworks)
- Autre (préciser)
Impact:
- Configure linters par défaut
- Sélectionne agents spécialisés par langage
- Définit test frameworks
Exemples:
- TypeScript → Agents: eslint-reviewer, ts-type-checker
- Python → Agents: pylint-reviewer, pytest-automation
- Go → Agents: golint-reviewer, go-test-runner
Question 3: Taille de l'équipe
"Combien de personnes travaillent sur ce projet?"
Options (sélection unique):
- Solo (1 personne)
- Petite équipe (2-5 personnes)
- Équipe moyenne (5-10 personnes)
- Grande équipe (10-20 personnes)
- Très grande équipe (20+ personnes)
Impact:
- Nombre d'agents installés par défaut
- Configuration collaboration
- Niveau d'automatisation recommandé
Exemples:
- Solo → Minimal setup, agents essentiels
- Grande équipe → Full setup, tous agents collaboration
Phase 2: BUSINESS_NEEDS (Questions 4-6)
Objectif: Identifier besoins métier, workflows prioritaires, objectifs
Question 4: Domaine métier principal
"Dans quel domaine métier ton projet opère-t-il?"
Options (sélection unique):
- E-commerce / Retail
- Healthcare / Medical
- Finance / Banking / Fintech
- Education / EdTech
- Media / Entertainment / Gaming
- SaaS / B2B Tools
- DevOps / Developer Tools
- IoT / Hardware
- Social / Communication
- Supply Chain / Logistics
- Autre (préciser)
Impact:
- Agents spécialisés domaine
- Templates métier
- Compliance requirements (GDPR, HIPAA, etc.)
Exemples:
- Healthcare → Agents: hipaa-compliance-checker, audit-logger
- Finance → Agents: security-auditor, pci-compliance
- DevOps → Agents: ci-cd-optimizer, infrastructure-reviewer
Question 5: Workflows prioritaires
"Quels workflows veux-tu automatiser en priorité?"
Options (multi-sélection, max 5):
- Code Review (peer review automatisé)
- Testing (génération et exécution tests)
- Documentation (génération docs automatique)
- CI/CD (pipeline automation)
- Security Audit (scan vulnérabilités)
- Performance Monitoring (analyse perf)
- API Design (création/validation APIs)
- Database Schema (migrations, validation)
- Deployment (automated releases)
- Architecture Review (design patterns)
- Autre (préciser)
Impact:
- Liste agents installés
- Priorité configuration
- Workflows activés par défaut
Exemples:
- Code Review + Testing → Agents: code-reviewer, test-generator, qa-automation
- Security + CI/CD → Agents: security-scanner, pipeline-builder, deploy-manager
Question 6: Niveau d'automatisation souhaité
"Quel niveau d'automatisation souhaites-tu?"
Options (slider / sélection unique):
- Manuel - Agents suggèrent, je décide toujours
- Semi-automatique - Agents agissent sur confirmation
- Automatique - Agents agissent de manière autonome (avec garde-fous)
- Full Auto - Confiance totale, intervention minimale
Impact:
- Configuration agents behavior
- Niveau de prompts/confirmations
- Auto-commit / auto-deploy settings
Exemples:
- Manuel → Tous les agents en mode "suggest only"
- Full Auto → Agents peuvent commit, deploy, create PRs
Phase 3: AGENT_SELECTION (Questions 7-9)
Objectif: Sélectionner agents à installer, sources externes
Question 7: Agents de base BYAN
"Quels agents BYAN de base veux-tu installer?"
Options (checkboxes, multi-sélection):
Essentiels (recommandés pour tous):
- BYAN - Créateur d'agents via interview
- MARC - Spécialiste GitHub Copilot CLI & SDK
Développement:
- Code Review Assistant - Review automatisé avec suggestions
- Test Generator - Génération tests unitaires/intégration
- Doc Writer - Documentation automatique
- Refactor Expert - Suggestions refactoring
DevOps & CI/CD:
- Pipeline Builder - Création CI/CD pipelines
- Deploy Manager - Gestion déploiements
- Infrastructure Reviewer - Review IaC (Terraform, etc.)
Sécurité:
- Security Scanner - Détection vulnérabilités (OWASP)
- Compliance Checker - Validation standards (GDPR, HIPAA)
Qualité:
- QA Automation - Tests automatisés E2E
- Performance Analyzer - Analyse performance
- Accessibility Checker - WCAG compliance
Gestion:
- Project Manager - Gestion épics/stories
- Sprint Planner - Planification sprints
- Tech Writer - Documentation technique
Avancés:
- Architect - Design patterns, architecture review
- Data Modeler - Merise Agile, MCD/MCT
- API Designer - OpenAPI, REST best practices
Par défaut selon réponses précédentes:
- Questions 1-6 → Suggestions automatiques
- User peut override
Impact:
- Agents installés dans
_byan/agents/ - Profils copiés depuis catalogue
- Configuration initialisée
Question 8: Importer agents externes?
"Veux-tu importer des agents depuis des sources externes?"
Options:
A) GitHub Repository
Exemple:
- Repo: "username/my-custom-agents"
- Branch: "main"
- Path: ".github/copilot/agents/"
Action: Clone et copie agents vers _byan/agents/
B) NPM Package
Exemple:
- Package: "@myorg/copilot-agents"
- Version: "latest" ou "1.2.3"
Action: npm install + copie agents depuis package
C) Local Directory
Exemple:
- Path: "../shared-agents/"
Action: Copie agents depuis dossier local
D) Aucun import externe
Utiliser uniquement agents BYAN de base
Validation:
- Vérifier accessibilité source
- Valider format agents (YAML frontmatter + markdown)
- Scanner sécurité (pas de code malicieux)
- Confirmer import avant exécution
Import Format:
imports:
- source: github
repo: username/agents
branch: main
agents:
- code-review-pro
- security-expert
- source: npm
package: "@company/agents"
version: "2.1.0"
agents:
- custom-linter
- source: local
path: "../shared-agents"
agents:
- team-standards-enforcer
Question 9: Templates personnalisés?
"Veux-tu créer des templates d'agents personnalisés pour ton équipe?"
Options:
- Oui - Créer templates custom (avec wizard guidé)
- Non - Utiliser templates BYAN par défaut
- Plus tard - Skip pour l'instant, configurer après
Si OUI, sous-questions:
9.1: "Nom du template?" (ex: "company-code-reviewer")
9.2: "Basé sur quel template existant?" (default-agent, code-reviewer, etc.)
9.3: "Modifications principales?" (persona, capabilities, knowledge)
Résultat:
- Template créé dans
_byan/templates/{template-name}.md - Disponible pour génération future
- Partageable avec équipe
Phase 4: CONFIGURATION (Questions 10-12)
Objectif: Configurer BYAN pour le projet
Question 10: Dossier de sortie
"Où veux-tu que BYAN génère ses artefacts?"
Options:
- _byan-output/ (default, recommandé)
- _output/
- generated/
- artifacts/
- Autre (saisie libre)
Configuration:
# _byan/config.yaml
output_folder: "{project-root}/_byan-output"
Impact:
- Localisation agents générés
- Logs et métriques
- Session state
Question 11: Langue de communication
"Dans quelle langue veux-tu interagir avec les agents?"
Options:
- Français 🇫🇷
- English 🇺🇸
- Español 🇪🇸
- Deutsch 🇩🇪
- Autre (préciser)
Configuration:
# _byan/config.yaml
communication_language: Francais
document_output_language: Francais
Impact:
- Messages agents en langue choisie
- Questions interview traduites
- Documentation générée en langue choisie
- Code/commits restent en anglais (standard tech)
Question 12: Intégration CI/CD
"Veux-tu configurer l'intégration CI/CD pour BYAN?"
Options:
- GitHub Actions - Créer workflows .github/workflows/
- GitLab CI - Créer .gitlab-ci.yml
- Jenkins - Générer Jenkinsfile
- CircleCI - Créer .circleci/config.yml
- Azure Pipelines - Créer azure-pipelines.yml
- Non - Pas d'intégration CI/CD maintenant
- Plus tard - Configurer manuellement après
Si OUI, génère:
GitHub Actions Example:
# .github/workflows/byan-agents.yml
name: BYAN Agents Automation
on:
pull_request:
types: [opened, synchronize]
jobs:
code-review:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Run BYAN Code Review
run: |
npm install
npx byan-v2 review --agent=code-review-assistant
Configuration:
# _byan/config.yaml
ci_cd:
enabled: true
platform: github-actions
workflows:
- code-review
- test-generation
- security-scan
Logique Post-Interview
Step 1: Validation des Réponses
// Vérifier cohérence
if (projectType === 'CLI' && workflows.includes('API Design')) {
warn('API Design moins pertinent pour CLI tool');
suggest('Remplacer par Command Builder?');
}
// Vérifier compatibilité stack + agents
if (stack === 'Python' && selectedAgents.includes('eslint-reviewer')) {
warn('ESLint reviewer non compatible Python');
suggest('Remplacer par pylint-reviewer?');
}
Step 2: Génération Recommendations
// Basé sur réponses, suggérer agents additionnels
const recommendations = analyzeResponses(allResponses);
// Exemple:
{
recommended: [
{ agent: 'test-generator', reason: 'Testing marqué prioritaire (Q5)' },
{ agent: 'doc-writer', reason: 'Grande équipe (Q3) = docs critiques' }
],
optional: [
{ agent: 'performance-analyzer', reason: 'Utile pour web apps (Q1)' }
],
notRecommended: [
{ agent: 'mobile-simulator', reason: 'Projet non mobile (Q1)' }
]
}
Step 3: Setup Structure
// Créer structure _byan/
createDirectories([
'_byan/agents',
'_byan/workflows',
'_byan/templates',
'_byan/data',
'_byan/memory/sessions',
'_byan/memory/backups'
]);
// Créer config.yaml
generateConfig(interviewResponses);
// Créer .gitignore
appendToGitignore([
'_byan/memory/sessions/',
'_byan-output/',
'.byan-cache/'
]);
Step 4: Install Agents
// Installer agents sélectionnés
for (const agent of selectedAgents) {
if (agent.source === 'byan-base') {
copyFromCatalog(agent.name);
} else if (agent.source === 'github') {
await importFromGitHub(agent.repo, agent.branch);
} else if (agent.source === 'npm') {
await importFromNpm(agent.package, agent.version);
} else if (agent.source === 'local') {
copyFromLocal(agent.path);
}
// Valider agent après import
await validateAgent(`_byan/agents/${agent.name}.md`);
}
// Créer agent-catalog.json
updateCatalog(installedAgents);
Step 5: Configure CI/CD (si demandé)
if (cicdPlatform === 'github-actions') {
generateGitHubWorkflows(selectedWorkflows);
} else if (cicdPlatform === 'gitlab-ci') {
generateGitLabConfig(selectedWorkflows);
}
Step 6: Generate Summary
// Créer rapport installation
const summary = {
timestamp: Date.now(),
project: {
type: projectType,
stack: techStack,
teamSize: teamSize
},
installed: {
agents: installedAgents.length,
workflows: installedWorkflows.length,
templates: customTemplates.length
},
configuration: {
outputDir: outputFolder,
language: communicationLanguage,
cicd: cicdPlatform
},
nextSteps: [
'Tester un agent: @byan-v2 help',
'Créer ton premier agent: @byan-v2 create agent',
'Lire la doc: _byan/README.md'
]
};
// Sauvegarder
saveInstallationSummary('_byan/INSTALLATION-SUMMARY.md', summary);
Fichiers de Sortie
1. Structure _byan/
{project-root}/
└── _byan/
├── agents/ # Agents installés
│ ├── byan.md
│ ├── marc.md
│ ├── code-review-assistant.md
│ └── ...
├── workflows/ # Workflows BYAN
│ ├── interview-workflow.md
│ ├── validate-agent-workflow.md
│ └── ...
├── templates/ # Templates personnalisés
│ ├── basic-agent.md
│ └── company-code-reviewer.md (si créé)
├── data/
│ └── agent-catalog.json # Catalogue agents installés
├── memory/
│ ├── sessions/
│ └── backups/
├── config.yaml # Configuration projet
├── workers.md # Doc workers BYAN
└── INSTALLATION-SUMMARY.md # Rapport installation
2. Configuration (_byan/config.yaml)
# Généré par Yanstaller
user_name: YourName
communication_language: Francais
document_output_language: Francais
output_folder: "{project-root}/_byan-output"
agents_folder: "{project-root}/_byan/agents"
workflows_folder: "{project-root}/_byan/workflows"
templates_folder: "{project-root}/_byan/templates"
project:
type: web-application
stack:
- typescript
- node
- react
team_size: small
domain: e-commerce
automation:
level: semi-automatic
workflows:
- code-review
- testing
- documentation
ci_cd:
enabled: true
platform: github-actions
byan_version: "2.0.0"
installed_by: yanstaller
installation_date: "2026-02-07T12:00:00Z"
3. Agent Catalog (_byan/data/agent-catalog.json)
{
"version": "1.0.0",
"updated": "2026-02-07T12:00:00Z",
"agents": [
{
"name": "byan",
"title": "BYAN - Builder of YAN",
"version": "2.0.0",
"source": "byan-base",
"installed": true,
"path": "_byan/agents/byan.md"
},
{
"name": "code-review-assistant",
"title": "Code Review Assistant",
"version": "1.2.0",
"source": "byan-base",
"installed": true,
"path": "_byan/agents/code-review-assistant.md"
},
{
"name": "custom-security-scanner",
"title": "Custom Security Scanner",
"version": "1.0.0",
"source": "github:company/agents",
"installed": true,
"path": "_byan/agents/custom-security-scanner.md"
}
],
"imports": [
{
"source": "github",
"repo": "company/agents",
"branch": "main",
"imported_at": "2026-02-07T12:05:00Z"
}
]
}
4. Installation Summary (_byan/INSTALLATION-SUMMARY.md)
# BYAN Installation Summary
**Date:** 2026-02-07
**Version:** 2.0.0
**Installed by:** Yanstaller v2.0.0
## Project Configuration
- **Type:** Web Application
- **Stack:** TypeScript, Node.js, React
- **Team Size:** Small (2-5 people)
- **Domain:** E-commerce
## Installed Components
### Agents (5)
✅ BYAN - Builder of YAN (v2.0.0)
✅ MARC - GitHub Copilot CLI Expert (v1.0.0)
✅ Code Review Assistant (v1.2.0)
✅ Test Generator (v1.1.0)
✅ Doc Writer (v1.0.5)
### Workflows (3)
✅ Interview Workflow
✅ Validate Agent Workflow
✅ Edit Agent Workflow
### CI/CD
✅ GitHub Actions configured
- code-review.yml
- test-generation.yml
## Next Steps
1. **Test an agent:**
```bash
@byan-v2 help
-
Create your first custom agent:
@byan-v2 create agent -
Read documentation:
- Quick Start: README-BYAN-V2.md
- API Reference: API-BYAN-V2.md
- Workflows: _byan/workflows/
-
Run code review:
@code-review-assistant review
Resources
- Configuration:
_byan/config.yaml - Agents catalog:
_byan/data/agent-catalog.json - Documentation:
_byan/workers.md
Ready to start! 🚀
---
## Gestion des Erreurs
### Import Failed
**Erreur:** GitHub repo inaccessible
❌ Cannot access repository 'username/agents' Possible causes:
- Repository doesn't exist
- Private repository (authentication needed)
- Network issue
Action: [ ] Retry with authentication [ ] Skip this import [ ] Use different source
### Agent Validation Failed
**Erreur:** Agent importé invalide
❌ Agent 'custom-agent' failed validation Issues:
- Missing required field: 'description'
- Invalid YAML frontmatter
- Emoji detected in technical section (Mantra IA-23)
Action: [ ] Auto-fix if possible [ ] Skip this agent [ ] Manually review and fix
### Conflict Detection
**Erreur:** Agent déjà existe
⚠️ Agent 'code-review-assistant' already exists Current: v1.0.0 (BYAN base) New: v1.2.0 (GitHub import)
Action: [ ] Keep current version [ ] Overwrite with new version [ ] Rename new version (code-review-assistant-v2) [ ] Compare and merge
---
## Testing
### Unit Tests
**File:** `__tests__/yanstaller/interview-installer.test.js`
**Coverage:**
- askNextQuestion() returns correct question for each phase
- submitResponse() stores and validates response
- Phase transitions work correctly
- generateConfig() creates valid YAML
- installAgents() handles all source types
### Integration Tests
**File:** `__tests__/yanstaller/full-install-flow.test.js`
**Scenarios:**
1. Complete install (12 questions, 5 agents, GitHub import)
2. Minimal install (essentials only)
3. Import from NPM
4. Import from local directory
5. CI/CD configuration
6. Error handling (failed imports, validation)
---
## Configuration
**File:** `src/yanstaller/config.js`
```javascript
module.exports = {
phases: {
PROJECT_CONTEXT: {
questions: 3,
required: true
},
BUSINESS_NEEDS: {
questions: 3,
required: true
},
AGENT_SELECTION: {
questions: 3,
required: false // Can skip
},
CONFIGURATION: {
questions: 3,
required: false // Defaults exist
}
},
defaults: {
outputFolder: '_byan-output',
communicationLanguage: 'English',
automationLevel: 'semi-automatic',
essentialAgents: ['byan', 'marc']
},
validation: {
maxImports: 20, // Max agents to import
allowedSources: ['github', 'npm', 'local'],
requireConfirmation: true
}
};
Metrics
Installation Time
- Target: < 10 minutes (including imports)
- Average: ~7 minutes
- Breakdown:
- Interview: 5 min
- Structure setup: 30s
- Agent installation: 1-2 min (depends on imports)
- CI/CD config: 30s
Success Rate
- Target: > 95%
- Current: 98% (successful installations)
- Common failures:
- Import errors (1.5%)
- Network issues (0.3%)
- User cancellation (0.2%)
CLI Usage
# Start Yanstaller (via npx or npm)
npx create-byan-agent
# Or programmatically
const Yanstaller = require('./src/yanstaller');
const installer = new Yanstaller();
await installer.start();
# Skip interview (use defaults)
npx create-byan-agent --quick
# Import config from file
npx create-byan-agent --config=byan-config.json
# Non-interactive (CI environment)
npx create-byan-agent --non-interactive --agents=byan,marc,code-reviewer
References
Related Workflows
interview-workflow.md- BYAN v2 agent creation interviewvalidate-agent-workflow.md- Agent validationedit-agent-workflow.md- Agent editing
Code Source
src/yanstaller/- Implementation complètesrc/yanstaller/interview-installer.js- Interview logicsrc/yanstaller/agent-importer.js- Import orchestration
Documentation
docs/YANSTALLER-GUIDE.md- User guideREADME-BYAN-V2.md- BYAN v2 overviewQUICK-START-BYAN-V2.md- Quick start guide
Status: 🔜 TO BE IMPLEMENTED
Priority: HIGH
Version: 2.0.0
Dependencies: BYAN v2 (✅ complete), Agent catalog (✅ complete)
Next: Implement src/yanstaller/interview-installer.js
Last Updated: 2026-02-07
Author: BYAN v2 Team