From c1aea68a817fdac32c8e3431a0597aabd8807d60 Mon Sep 17 00:00:00 2001 From: NicolasVD Date: Fri, 25 Sep 2026 11:58:48 +0200 Subject: [PATCH] chore(i18n): translate validation engine, issue templates, and operational scripts - Translate scripts/validate-docs.sh reporting, banners, and budgets to English (L-01) - Translate .github/ISSUE_TEMPLATE bug_report.yml and feature_idea.yml to English (L-03) - Translate scripts/quality-check.sh, deploy-app-distribution.sh, and generate-screenshots.sh (L-05) - Translate scripts/README.md catalog and architecture links to English (L-05) - Translate .agent/hooks/pre-invocation-anchor.sh prompt injection to English (L-06) - Translate README.md Mermaid architectural diagram labels to English (R-01) Closes #8 --- .agent/hooks/pre-invocation-anchor.sh | 2 +- .github/ISSUE_TEMPLATE/bug_report.yml | 62 ++++++------- .github/ISSUE_TEMPLATE/feature_idea.yml | 62 ++++++------- README.md | 18 ++-- scripts/README.md | 37 ++++---- scripts/deploy-app-distribution.sh | 28 +++--- scripts/generate-screenshots.sh | 10 +-- scripts/quality-check.sh | 6 +- scripts/validate-docs.sh | 112 ++++++++++++------------ 9 files changed, 168 insertions(+), 169 deletions(-) diff --git a/.agent/hooks/pre-invocation-anchor.sh b/.agent/hooks/pre-invocation-anchor.sh index eefe851..66a4f1b 100755 --- a/.agent/hooks/pre-invocation-anchor.sh +++ b/.agent/hooks/pre-invocation-anchor.sh @@ -10,7 +10,7 @@ fi if [ -n "$BRANCH" ] && [ "$BRANCH" != "$DEF" ] && [ "$BRANCH" != "main" ] && [ "$BRANCH" != "master" ]; then cat <): " labels: ["type:bug"] body: - type: markdown attributes: value: | - ### 🔍 Signalement d'anomalie Agentic Android Kernel - Merci de détailler le comportement inattendu pour faciliter le diagnostic et la correction. + ### 🔍 Agentic Android Kernel Bug Report + Please detail the unexpected behavior to facilitate diagnosis and resolution. - type: dropdown id: scope attributes: - label: Périmètre / Domaine affecté - description: Choisissez le domaine principal où le bug se produit. + label: Scope / Affected Domain + description: Choose the primary domain where the bug occurs. options: - - tasks (Création, édition, suppression, complétion de charge) - - matrix (Affichage ou interaction matrice Eisenhower) - - duo (Synchronisation en temps réel, association couple) - - analytics (Calcul de jauge, tendances, graphiques) - - auth (Connexion Google, sessions) - - sync (Firestore, Room, hors-ligne) - - ui (Affichage, glitch visuel, animation) - - ai (Classification Gemini, timeout API) + - tasks (Creation, editing, deletion, mental load completion) + - matrix (Eisenhower matrix display or interaction) + - duo (Real-time synchronization, duo pairing) + - analytics (Gauge calculation, trends, charts) + - auth (Google Sign-In, sessions) + - sync (Firestore, Room, offline) + - ui (Display, visual glitch, animation) + - ai (Gemini classification, API timeout) validations: required: true - type: textarea id: bug-description attributes: - label: Description du Bug - description: Description claire et concise de l'anomalie rencontrée. - placeholder: "Exemple : Lors du changement d'onglet vers Duo, l'état de chargement reste figé..." + label: Bug Description + description: Clear and concise description of the issue encountered. + placeholder: "Example: When switching to the Duo tab, the loading state remains stuck..." validations: required: true - type: textarea id: steps-to-reproduce attributes: - label: Étapes pour Reproduire - description: Quelles sont les actions exactes menant au problème ? + label: Steps to Reproduce + description: What are the exact steps leading to the problem? placeholder: | - 1. Ouvrir l'application - 2. Aller sur l'onglet 'Matrice' - 3. Glisser une tâche vers le quadrant 'Déléguer' - 4. Observer l'erreur... + 1. Open the application + 2. Go to the 'Matrix' tab + 3. Drag a task to the 'Delegate' quadrant + 4. Observe the error... validations: required: true - type: textarea id: expected-vs-actual attributes: - label: Comportement Attendu vs Comportement Observé - description: Qu'aurait-il dû se passer et que s'est-il passé ? - placeholder: "Attendu : La tâche change de quadrant avec une animation fluide.\nObservé : Crash ou tâche inchangée." + label: Expected vs. Actual Behavior + description: What should have happened, and what actually occurred? + placeholder: "Expected: Task moves to target quadrant with smooth animation.\nActual: Crash or task remains unchanged." validations: required: true - type: input id: environment attributes: - label: Environnement de Test - description: Appareil, version d'Android, version de l'application. - placeholder: "Pixel 8 Pro - Android 14 / Émulateur API 34 - v0.1.0" + label: Test Environment + description: Device model, Android OS version, application version. + placeholder: "Pixel 8 Pro - Android 14 / Emulator API 34 - v0.1.0" validations: required: false - type: textarea id: logs-and-stacktrace attributes: - label: Logs / Stacktrace (Optionnel) - description: Collez ici les logs Android Studio / Logcat pertinents. + label: Logs / Stacktrace (Optional) + description: Paste relevant Android Studio / Logcat logs here. placeholder: "Logcat / Stacktrace..." validations: required: false diff --git a/.github/ISSUE_TEMPLATE/feature_idea.yml b/.github/ISSUE_TEMPLATE/feature_idea.yml index 285c24a..1a12495 100644 --- a/.github/ISSUE_TEMPLATE/feature_idea.yml +++ b/.github/ISSUE_TEMPLATE/feature_idea.yml @@ -1,71 +1,71 @@ -name: 💡 Feature Proposal / Idée de Fonctionnalité -description: Proposer une nouvelle fonctionnalité ou amélioration pour Agentic Android Kernel +name: 💡 Feature Proposal +description: Propose a new feature or improvement for Agentic Android Kernel title: "feat(): " labels: ["type:feature"] body: - type: markdown attributes: value: | - ### 🧠 Proposition d'évolution Agentic Android Kernel - Merci de contribuer à la réduction de la charge mentale ! Veuillez remplir ce formulaire pour structurer la fonctionnalité selon la démarche Spec-Driven (4 Piliers). + ### 🧠 Feature Proposal for Agentic Android Kernel + Thank you for contributing to mental load reduction! Please fill out this form to structure your feature following the Spec-Driven (4 Pillars) framework. - type: dropdown id: scope attributes: - label: Périmètre / Domaine fonctionnel - description: Choisissez le domaine principal concerné par cette fonctionnalité. + label: Scope / Functional Domain + description: Choose the primary domain affected by this feature. options: - - tasks (Gestion des charges, récurrence, cycles) - - matrix (Matrice Eisenhower, priorisation 4 quadrants) - - duo (Mode Couple, rotation, synchronisation partagée) - - analytics (Graphiques de tendances, équilibre mental, jauges) - - core (Base de données locale Room, synchronisation Firestore, Auth) - - ai (Gemini classification automatique, suggestions intelligentes) - - ui (Composants visuels, animations sereines, Thème) + - tasks (Mental load management, recurrence, cycles) + - matrix (Eisenhower matrix, 4-quadrant prioritization) + - duo (Couple mode, task rotation, shared synchronization) + - analytics (Trend charts, mental balance, gauges) + - core (Local Room database, Firestore synchronization, Auth) + - ai (Gemini automated classification, smart suggestions) + - ui (Visual components, serene animations, Theme) validations: required: true - type: textarea id: problem-context attributes: - label: Contexte & Problématique Charge Mentale - description: Quel est le problème réel ou la friction vécue par l'utilisateur ou le duo ? En quoi cela alourdit-il la charge mentale ? - placeholder: "Exemple : Les tâches ménagères récurrentes sont souvent réassignées manuellement, provoquant des frictions et une asymétrie de charge..." + label: Context & Mental Load Problem Statement + description: What is the real problem or friction experienced by the user or duo? How does it increase mental load? + placeholder: "Example: Recurring household tasks are often manually reassigned, causing friction and asymmetric load..." validations: required: true - type: textarea id: proposed-solution attributes: - label: Solution Proposée & Expérience Utilisateur (UX) - description: Décrivez précisément la solution souhaitée, les interactions utilisateur et le résultat attendu. - placeholder: "Exemple : Introduire une règle de rotation alternée automatique à chaque complétion d'une charge récurrente..." + label: Proposed Solution & User Experience (UX) + description: Describe precisely the desired solution, user interactions, and expected outcome. + placeholder: "Example: Introduce an automatic alternating rotation rule upon completion of each recurring task..." validations: required: true - type: textarea id: impact-analytics attributes: - label: Mesure d'impact & Analytics souhaités - description: Quels événements télémétriques (event_name, paramètres) ou métriques d'usage permettront de mesurer l'adoption et le succès de cette fonctionnalité ? - placeholder: "Exemple :\n- event_name: 'recurring_task_created' (params: frequency, is_duo_rotating, area)\n- event_name: 'duo_rotation_assigned' (params: frequency, rotation_role, cycle_count)" + label: Desired Impact Metrics & Telemetry + description: Which telemetry events (event_name, parameters) or usage metrics will measure adoption and success? + placeholder: "Example:\n- event_name: 'recurring_task_created' (params: frequency, is_duo_rotating, area)\n- event_name: 'duo_rotation_assigned' (params: frequency, rotation_role, cycle_count)" validations: required: false - type: textarea id: technical-architecture attributes: - label: Pistes Techniques & Architecture (Optionnel) - description: Éléments pressentis pour l'implémentation (Room Schema, StateFlow, ViewModel, Jetpack Compose, Gemini, Firestore). - placeholder: "Exemple : Ajout d'un champ `rotationRule` dans MentalLoadItem, mise à jour de SecondBrainRepository..." + label: Technical Architecture & Implementation Notes (Optional) + description: Anticipated implementation details (Room Schema, StateFlow, ViewModel, Jetpack Compose, Gemini, Firestore). + placeholder: "Example: Add 'rotationRule' field to MentalLoadItem, update SecondBrainRepository..." validations: required: false - type: checkboxes id: quality-commitments attributes: - label: Engagements Qualité & Guidelines - description: Critères obligatoires de validation pour l'implémentation future. + label: Quality Commitments & Guidelines + description: Mandatory validation criteria for future implementation. options: - - label: Respect de l'architecture MVI / Clean Kotlin (ViewModel, StateFlow, Room / Firestore) + - label: Adherence to MVI / Clean Kotlin architecture (ViewModel, StateFlow, Room / Firestore) required: true - - label: UI 100% Jetpack Compose conforme aux principes Serene UI (animations douces, zéro friction) + - label: 100% Jetpack Compose UI compliant with Serene UI principles (gentle animations, zero friction) required: true - - label: Contrat d'Analytics & Observabilité formalisé + - label: Formalized Analytics & Observability contract required: true - - label: Tests unitaires & Robolectric (100% passing sur `./scripts/quality-check.sh`) + - label: Unit tests & Robolectric (100% passing on './scripts/quality-check.sh') required: true diff --git a/README.md b/README.md index 3e29aac..632e7f4 100644 --- a/README.md +++ b/README.md @@ -22,24 +22,24 @@ Autonomous AI coding agents often derail when given unbounded write access to pr ```mermaid flowchart TD subgraph Inception["Phase 1 · Inception Consortium"] - P1["P1: Product Planner\nAnti-duplication & User Stories Gherkin"] --> P2["P2: Design Lead\nTokens M3, UI Matrix 4 états"] - P2 --> P3["P3: Privacy & Data\nZero-PII, Taxonomie analytique, RGPD"] - P3 --> P4["P4: System Architect\nClean MVI, Boundaries, Découpage DAG Epics"] + P1["P1: Product Planner\nAnti-duplication & Gherkin User Stories"] --> P2["P2: Design Lead\nM3 Tokens, 4-State UI Matrix"] + P2 --> P3["P3: Privacy & Data\nZero-PII, Analytics Taxonomy, GDPR"] + P3 --> P4["P4: System Architect\nClean MVI, Boundaries, Epic DAG Decomposition"] P4 --> Spec["Dual-Write Spec\nGitHub Issue Comment + implementation_plan.md"] end - Spec --> Gate14{"🛑 GATE 1.4 : Inception Halt\nApprobation explicite écrite\n(Branch Guard actif sur main/master)"} + Spec --> Gate14{"🛑 GATE 1.4 : Inception Halt\nExplicit Written Approval\n(Branch Guard active on default branch)"} subgraph Delivery["Phase 2 · Delivery"] - Gate14 -->|Validation explicite| Branch["Création de branche dédiée\n/issue--"] - Branch --> P5["P5: Software Engineer\nImplémentation TDD & Compose strict\nZéro chaîne en dur (strings.xml)"] + Gate14 -->|Explicit approval| Branch["Dedicated Feature Branch\n/issue--"] + Branch --> P5["P5: Software Engineer\nTDD & Strict Compose Implementation\nZero Hardcoded Strings (strings.xml)"] P5 --> Airbag["🛡️ Quality Airbag\n./scripts/quality-check.sh\n(codeSanityCheck + Lint + Roborazzi)"] end subgraph Release["Phase 3 · Release"] - Airbag -->|Vérifications 100% vertes| P6["P6: Release Manager\nPush git & Ouverture PR Walkthrough"] - P6 --> Gate35{"🔒 GATE 3.5 : Auto-Merge Lock\nAttente formelle du développeur\n('Tu peux merger')"} - Gate35 -->|Confirmation écrite| Merge["Squash Merge & Dual-Sync\nClôture Kanban & Pruning local"] + Airbag -->|100% green checks| P6["P6: Release Manager\nGit Push & Open PR Walkthrough"] + P6 --> Gate35{"🔒 GATE 3.5 : Auto-Merge Lock\nHuman Authorization Required\n('Tu peux merger')"} + Gate35 -->|Written confirmation| Merge["Squash Merge & Dual-Sync\nKanban Closure & Branch Pruning"] end style Gate14 fill:#ff4d4f,stroke:#333,stroke-width:2px,color:#fff diff --git a/scripts/README.md b/scripts/README.md index 896ac23..0cf872a 100644 --- a/scripts/README.md +++ b/scripts/README.md @@ -1,33 +1,32 @@ -# 🛠️ Scripts d'Automatisation — Agentic Android Kernel +# 🛠️ Automation Scripts — Agentic Android Kernel -Ce dossier contient l'ensemble des **scripts atomiques** et des **orchestrateurs** du projet **Agentic Android Kernel**. +This directory contains all **atomic scripts** and **orchestrators** for the **Agentic Android Kernel** project. -> 📖 **Documentation Complète & Architecture Détaillée :** -> Consultez [**`docs/scripts-reference.md`**](../docs/scripts-reference.md) pour les fiches exhaustives, les options CLI, et la matrice de composition. +> 📖 **Comprehensive Documentation & Detailed Architecture:** +> See [**`docs/scripts-reference.md`**](../docs/scripts-reference.md) for exhaustive reference sheets, CLI options, and the composition matrix. --- -## ⚡ Index Rapide des Scripts +## ⚡ Quick Script Index -| Script | Langage | Description Synthétique | Commande | +| Script | Language | Concise Description | Command | |---|---|---|---| -| [`validate-docs.sh`](validate-docs.sh) | Bash | Valide la présence et la conformité des contrats de spécifications (`DESIGN.md`, playbooks, skills, règles) | `./scripts/validate-docs.sh` | -| [`quality-check.sh`](quality-check.sh) | Bash | Exécute la suite complète de compilation Kotlin/Java, Lint Android et tests unitaires/UI | `./scripts/quality-check.sh` | -| [`test-firestore-rules.mjs`](test-firestore-rules.mjs) | Node.js | Exécute 16 assertions de sécurité et de non-régression sur `firestore.rules` | `node scripts/test-firestore-rules.mjs` | -| [`deploy-firestore-rules.mjs`](deploy-firestore-rules.mjs) | Node.js | Déploie et publie `firestore.rules` via l'API REST avec JWT compte de service | `node scripts/deploy-firestore-rules.mjs` | -| [`deploy-app-distribution.sh`](deploy-app-distribution.sh) | Bash | Compile et déploie l'APK sur Firebase App Distribution avec multiplicateur de version (x100) | `./scripts/deploy-app-distribution.sh` | -| [`generate-screenshots.sh`](generate-screenshots.sh) | Bash | Génère les captures d'écran Roborazzi pour le Design System | `./scripts/generate-screenshots.sh` | -| [`upload-screenshots.py`](upload-screenshots.py) | Python | Valide et mappe les captures Roborazzi sur les écrans Google Stitch | `python3 scripts/upload-screenshots.py --check-only` | -| [`cleanup-e2e-firestore.mjs`](cleanup-e2e-firestore.mjs) | Node.js | Purge les documents de sondes de test dans la collection Firestore `/users` | `node scripts/cleanup-e2e-firestore.mjs` | -| [`inspect-ide.sh`](inspect-ide.sh) | Bash | Exécute les inspections Android Studio / IntelliJ en mode headless | `./scripts/inspect-ide.sh` | +| [`validate-docs.sh`](validate-docs.sh) | Bash | Validates presence and contract conformance of specifications (`DESIGN.md`, playbooks, skills, rules) | `./scripts/validate-docs.sh` | +| [`quality-check.sh`](quality-check.sh) | Bash | Executes the complete Kotlin/Java compilation, Android Lint, and unit/UI test suite | `./scripts/quality-check.sh` | +| [`test-runtime-guardrails.mjs`](test-runtime-guardrails.mjs) | Node.js | Runs 18 security assertions on runtime guardrails (`branch-guard.mjs`, `plan-guard.mjs`) | `node scripts/test-runtime-guardrails.mjs` | +| [`install-hooks.sh`](install-hooks.sh) | Bash | Binds local Git hooks to `.agent/hooks/` and enables the pre-commit airbag | `./scripts/install-hooks.sh` | +| [`deploy-app-distribution.sh`](deploy-app-distribution.sh) | Bash | Builds and deploys APK to Firebase App Distribution with monotonic version multiplier (x100) | `./scripts/deploy-app-distribution.sh` | +| [`generate-screenshots.sh`](generate-screenshots.sh) | Bash | Generates Roborazzi screenshots for the Design System | `./scripts/generate-screenshots.sh` | +| [`upload-screenshots.py`](upload-screenshots.py) | Python | Validates and maps Roborazzi screenshots to Google Stitch screens | `python3 scripts/upload-screenshots.py --check-only` | +| [`inspect-ide.sh`](inspect-ide.sh) | Bash | Runs Android Studio / IntelliJ inspections in headless mode | `./scripts/inspect-ide.sh` | --- -## 🎯 Composition par Compétences Sémantiques ([`.agent/skills/`](../.agent/skills/)) +## 🎯 Composition by Semantic Skills ([`.agent/skills/`](../.agent/skills/)) -Chaque script remplit une responsabilité unique. Les enchaînements sont pilotés par les compétences sémantiques natives de l'agent : -- **`quality-airbag`** (`/quality-check`) ➔ `validate-docs.sh` + `quality-check.sh` + `test-firestore-rules.mjs` +Each script fulfills a single responsibility. End-to-end workflows are driven by the agent's native semantic skills: +- **`quality-airbag`** (`/quality-check`) ➔ `validate-docs.sh` + `quality-check.sh` + `test-runtime-guardrails.mjs` - **`sync-stitch`** (`/sync-stitch`) ➔ `validate-docs.sh` + `generate-screenshots.sh` + `upload-screenshots.py` - **`distribute-local`** (`/distribute-local`) ➔ `quality-check.sh` + `deploy-app-distribution.sh` - **`open-pr`** (`/open-pr`) ➔ `quality-check.sh` + Walkthrough & PR creation -- **`triage-feedback`** (`/triage-feedback`) ➔ 100% MCP natif (`GitHubMCP` : `search_issues`, `add_issue_comment`, `create_issue`) +- **`triage-feedback`** (`/triage-feedback`) ➔ 100% native MCP (`GitHubMCP`: `search_issues`, `add_issue_comment`, `create_issue`) diff --git a/scripts/deploy-app-distribution.sh b/scripts/deploy-app-distribution.sh index 374c2b9..df1a3d6 100755 --- a/scripts/deploy-app-distribution.sh +++ b/scripts/deploy-app-distribution.sh @@ -18,21 +18,21 @@ echo "==================================================" # 1. Check for service-account.json if [ ! -f "$SERVICE_ACCOUNT_FILE" ]; then echo "" - echo "❌ Erreur : Fichier '$SERVICE_ACCOUNT_FILE' introuvable !" + echo "❌ Error: File '$SERVICE_ACCOUNT_FILE' not found!" echo "" - echo "ℹ️ Comment obtenir et configurer vos identifiants :" - echo " 1. Rendez-vous sur la console Google Cloud / Firebase :" + echo "ℹ️ How to obtain and configure your credentials:" + echo " 1. Go to the Google Cloud / Firebase Console:" echo " https://console.cloud.google.com/iam-admin/serviceaccounts?project=${FIREBASE_PROJECT_ID}" - echo " 2. Créez ou sélectionnez un compte de service avec le rôle 'Firebase App Distribution Admin'." - echo " 3. Générez et téléchargez une clé privée au format JSON." - echo " 4. Placez le fichier à la racine du projet sous le nom :" + echo " 2. Create or select a service account with the 'Firebase App Distribution Admin' role." + echo " 3. Generate and download a private key in JSON format." + echo " 4. Place the file at the project root named:" echo " service-account.json" - echo " (Note : ce fichier est automatiquement ignoré par .gitignore pour votre sécurité)" + echo " (Note: this file is automatically ignored by .gitignore for security)" echo "" exit 1 fi -echo "✅ Compte de service détecté : $SERVICE_ACCOUNT_FILE" +echo "✅ Service account detected: $SERVICE_ACCOUNT_FILE" # 2. Extract Git version metadata git -C "$ROOT_DIR" fetch --tags 2>/dev/null || true @@ -132,9 +132,9 @@ fi FORMATTED_RELEASE_NOTES="v${VERSION_NAME} (build ${VERSION_CODE}) : ${RAW_MESSAGE}" echo "📦 Version : v${VERSION_NAME} (build ${VERSION_CODE})" -echo "👥 Groupes cibles : $TARGET_GROUPS" -echo "🏗️ Variante build : $BUILD_VARIANT" -echo "📝 Notes de version :" +echo "👥 Target groups : $TARGET_GROUPS" +echo "🏗️ Build variant : $BUILD_VARIANT" +echo "📝 Release notes :" echo "--------------------------------------------------" echo "$FORMATTED_RELEASE_NOTES" echo "--------------------------------------------------" @@ -161,7 +161,7 @@ if [ "$BUILD_VARIANT" = "release" ]; then fi echo "" -echo "📦 Lancement de la compilation ($ASSEMBLE_TASK) et de l'upload Firebase ($GRADLE_TASK)..." +echo "📦 Launching build ($ASSEMBLE_TASK) and Firebase upload ($GRADLE_TASK)..." echo "" cd "$ROOT_DIR" @@ -174,7 +174,7 @@ rm -f "$ROOT_DIR/release-notes.txt" echo "" echo "==================================================" -echo "🎉 Distribution locale terminée avec succès !" -echo "📱 Console Firebase App Distribution :" +echo "🎉 Local distribution completed successfully!" +echo "📱 Firebase App Distribution Console:" echo " $FIREBASE_CONSOLE_URL" echo "==================================================" diff --git a/scripts/generate-screenshots.sh b/scripts/generate-screenshots.sh index b74851c..ec7b9fd 100755 --- a/scripts/generate-screenshots.sh +++ b/scripts/generate-screenshots.sh @@ -2,19 +2,19 @@ # ============================================================================== # Agentic Android Kernel — Generate Roborazzi Screenshots # ============================================================================== -# Exécute les tests d'UI Robolectric/Roborazzi pour générer ou mettre à jour -# les captures d'écran de l'application en local (dans build/outputs/roborazzi). +# Runs Robolectric/Roborazzi UI tests to generate or update +# local application screenshots (in build/outputs/roborazzi). # ============================================================================== set -euo pipefail echo "==================================================" -echo "📸 Agentic Android Kernel — Génération des captures Roborazzi" +echo "📸 Agentic Android Kernel — Generating Roborazzi Screenshots" echo "==================================================" -# On exécute la tâche Gradle standard pour enregistrer les captures Roborazzi. +# Execute the standard Gradle task to record Roborazzi screenshots. ./gradlew recordRoborazziDebug --stacktrace echo "==================================================" -echo "✨ Captures générées avec succès dans build/outputs/roborazzi !" +echo "✨ Screenshots generated successfully in build/outputs/roborazzi!" echo "==================================================" diff --git a/scripts/quality-check.sh b/scripts/quality-check.sh index 6306e8c..5d1aa85 100755 --- a/scripts/quality-check.sh +++ b/scripts/quality-check.sh @@ -53,7 +53,7 @@ fi echo "📂 Project : $ROOT_DIR" echo "" -echo "🚀 Lancement des vérifications complètes :" +echo "🚀 Running full verification suite:" echo " 1. Kotlin Progressive Compiler Checks & Opt-in annotations" echo " 2. Java Compiler Warnings (-Xlint:all)" echo " 3. Android Lint Debug & Release (Kotlin Language & Compose Static Analysis)" @@ -65,8 +65,8 @@ cd "$ROOT_DIR" echo "" echo "==================================================================" -echo "🎉 Toutes les vérifications de code ont été exécutées avec succès !" -echo "📊 Rapports générés :" +echo "🎉 All code sanity checks executed successfully!" +echo "📊 Generated reports:" echo " • Lint Debug : app/build/reports/lint-results-debug.html" echo " • Lint Release : app/build/reports/lint-results-release.html" echo " • Unit Tests : app/build/reports/tests/testDebugUnitTest/index.html" diff --git a/scripts/validate-docs.sh b/scripts/validate-docs.sh index 884b284..033a1c9 100755 --- a/scripts/validate-docs.sh +++ b/scripts/validate-docs.sh @@ -11,7 +11,7 @@ # - Playbooks (.agent/playbooks/) # - Rules (.agent/rules/) # - Hooks (.agent/hooks/ & scripts/install-hooks.sh) -# - Compétences Sémantiques (.agent/skills/) +# - Semantic Skills (.agent/skills/) # - Sidecars (.agent/sidecars/) # - MCP Catalog (.agent/mcp-catalog.md) # ============================================================================== @@ -22,7 +22,7 @@ SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" ROOT_DIR="$(cd "$SCRIPT_DIR/.." && pwd)" echo "==================================================================" -echo "📑 Agentic Android Kernel — Validation Complète de l'Architecture Multi-Agent" +echo "📑 Agentic Android Kernel — Full Multi-Agent Architecture Validation" echo "==================================================================" FAILED=0 @@ -36,13 +36,13 @@ check_file() { local size size=$(wc -c < "$ROOT_DIR/$file" | tr -d ' ') if [ "$max_size" -gt 0 ] && [ "$size" -gt "$max_size" ]; then - echo " ❌ [DÉPASSEMENT] $file ($size octets > budget max $max_size octets)" + echo " ❌ [OVER BUDGET] $file ($size bytes > max budget $max_size bytes)" FAILED=$((FAILED + 1)) else - echo " ✅ [OK] $file ($desc — $size octets)" + echo " ✅ [OK] $file ($desc — $size bytes)" fi else - echo " ❌ [MANQUANT] $file ($desc)" + echo " ❌ [MISSING] $file ($desc)" FAILED=$((FAILED + 1)) fi } @@ -57,40 +57,40 @@ check_executable() { local size size=$(wc -c < "$ROOT_DIR/$file" | tr -d ' ') if [ "$max_size" -gt 0 ] && [ "$size" -gt "$max_size" ]; then - echo " ❌ [DÉPASSEMENT] $file ($size octets > budget max $max_size octets)" + echo " ❌ [OVER BUDGET] $file ($size bytes > max budget $max_size bytes)" FAILED=$((FAILED + 1)) else - echo " ✅ [OK] $file (exécutable — $size octets)" + echo " ✅ [OK] $file (executable — $size bytes)" fi else - echo " ❌ [NON EXÉCUTABLE] $file ($desc — chmod +x requis)" + echo " ❌ [NOT EXECUTABLE] $file ($desc — chmod +x required)" FAILED=$((FAILED + 1)) fi else - echo " ❌ [MANQUANT] $file ($desc)" + echo " ❌ [MISSING] $file ($desc)" FAILED=$((FAILED + 1)) fi } echo "" -echo "📦 1. Contrats Centraux de Design, Architecture & Configuration :" -check_file "DESIGN.md" "Spécification Design Tokens YAML" -check_file "design-system.md" "Référentiel Technique & Contrat Persona P2" -check_file "AGENTS.md" "Micro-Kernel Agent & Gouvernance Racine (< 10 000 octets)" 10000 -check_file "agent.md" "Lien symbolique rétrocompatible agent.md -> AGENTS.md" 10000 -check_file "README.md" "Vitrine Principale d'Ingénierie" -check_file "ARCHITECTURE.md" "Spécification Formelle de l'Architecture" -check_file "kernel.config.json" "Configuration Déclarative du Projet" -check_file "kernel.config.schema.json" "Schéma JSON Formel de Configuration" +echo "📦 1. Core Contracts: Design, Architecture & Configuration:" +check_file "DESIGN.md" "YAML Design Tokens Specification" +check_file "design-system.md" "Technical Reference & Persona P2 Contract" +check_file "AGENTS.md" "Agent Micro-Kernel & Root Governance (< 10,000 bytes)" 10000 +check_file "agent.md" "Backward-compatible symlink agent.md -> AGENTS.md" 10000 +check_file "README.md" "Main Engineering Showcase" +check_file "ARCHITECTURE.md" "Formal Architecture Specification" +check_file "kernel.config.json" "Declarative Project Configuration" +check_file "kernel.config.schema.json" "Formal JSON Schema Configuration" echo "" -echo "📚 2. Documentation Technique de Gouvernance (docs/) :" -check_file "docs/analytics-taxonomy.md" "Contrat P3 : Taxonomie Zero-PII" -check_file "docs/qa-classification-test-guide.md" "Contrat P6 : Guide QA & Classification" -check_file "docs/scripts-reference.md" "Documentation de Référence des Scripts" +echo "📚 2. Governance Technical Documentation (docs/):" +check_file "docs/analytics-taxonomy.md" "P3 Contract: Zero-PII Taxonomy" +check_file "docs/qa-classification-test-guide.md" "P6 Contract: QA & Classification Guide" +check_file "docs/scripts-reference.md" "Scripts Reference Documentation" echo "" -echo "🤖 3. Manifestes Déclaratifs des Personas (.agent/personas/ — max 4 500 octets) :" +echo "🤖 3. Declarative Persona Manifests (.agent/personas/ — max 4,500 bytes):" check_file ".agent/personas/p1-product-planner.md" "Persona 1 (Product Planner)" 4500 check_file ".agent/personas/p2-design-lead.md" "Persona 2 (Design Lead)" 4500 check_file ".agent/personas/p3-privacy-data.md" "Persona 3 (Privacy & Data Lead)" 4500 @@ -99,16 +99,16 @@ check_file ".agent/personas/p5-software-engineer.md" "Persona 5 (Software Engine check_file ".agent/personas/p6-release-manager.md" "Persona 6 (Release Manager)" 4500 echo "" -echo "📝 4. Gabarits Déterministes & Catalogue MCP (.agent/templates/ & .agent/) :" -check_file ".agent/mcp-catalog.md" "Catalogue des Interfaces MCP" 4000 -check_file ".agent/skills.json" "Déclaration Native des Compétences Antigravity" 1000 -check_file ".agent/templates/4-pillar-spec.md" "Template Cadrage 4 Piliers" 4500 -check_file ".agent/templates/epic-spec.md" "Template Cadrage Epic" 4500 -check_file ".agent/templates/pr-walkthrough.md" "Template Walkthrough PR" 4500 -check_file ".agent/templates/crashlytics-triage-issue.md" "Template Triage Crashlytics" 4500 +echo "📝 4. Deterministic Templates & MCP Catalog (.agent/templates/ & .agent/):" +check_file ".agent/mcp-catalog.md" "MCP Interface Catalog" 4000 +check_file ".agent/skills.json" "Native Antigravity Skills Declaration" 1000 +check_file ".agent/templates/4-pillar-spec.md" "4-Pillar Spec Template" 4500 +check_file ".agent/templates/epic-spec.md" "Epic Spec Template" 4500 +check_file ".agent/templates/pr-walkthrough.md" "PR Walkthrough Template" 4500 +check_file ".agent/templates/crashlytics-triage-issue.md" "Crashlytics Triage Template" 4500 echo "" -echo "🐙 5. Alignement des Gabarits GitHub (.github/) :" +echo "🐙 5. GitHub Template Alignment (.github/):" check_file ".github/PULL_REQUEST_TEMPLATE.md" "GitHub PR Template" 4500 check_file ".github/ISSUE_TEMPLATE/bug_report.yml" "GitHub Issue Form Bug Report" 5000 check_file ".github/ISSUE_TEMPLATE/crashlytics_triage.yml" "GitHub Issue Form Crashlytics" 5000 @@ -117,58 +117,58 @@ check_file ".github/ISSUE_TEMPLATE/config.yml" "GitHub Issue Config" 2000 check_file ".github/workflows/delivery-pipeline.yml" "GitHub Actions Workflow Delivery Pipeline & Quality Gate" echo "" -echo "🧠 6. Playbooks Techniques Modulaires (.agent/playbooks/ — max 8 500 octets) :" +echo "🧠 6. Modular Technical Playbooks (.agent/playbooks/ — max 8,500 bytes):" check_file ".agent/playbooks/room-migrations.md" "Playbook Room Migrations" 8500 check_file ".agent/playbooks/roborazzi-export.md" "Playbook Roborazzi Export" 8500 check_file ".agent/playbooks/compose-theming.md" "Playbook Compose Theming" 8500 check_file ".agent/playbooks/android-standards.md" "Playbook Android Standards" 8500 echo "" -echo "🛡️ 7. Règles Maîtresses de Gouvernance (.agent/rules/ — max 9 500 octets) :" -check_file ".agent/rules/agent-lifecycle.md" "Cycle de Vie en 3 Phases" 9500 -check_file ".agent/rules/backlog-planner.md" "Planification Autonome & 4 Piliers" 9500 -check_file ".agent/rules/git-workflow.md" "Stratégie Git & Convention Commits" 9500 -check_file ".agent/rules/firebase-standards.md" "Standards Firebase & Sécurité" 9500 +echo "🛡️ 7. Master Governance Rules (.agent/rules/ — max 9,500 bytes):" +check_file ".agent/rules/agent-lifecycle.md" "3-Phase Lifecycle" 9500 +check_file ".agent/rules/backlog-planner.md" "Autonomous Planning & 4 Pillars" 9500 +check_file ".agent/rules/git-workflow.md" "Git Strategy & Conventional Commits" 9500 +check_file ".agent/rules/firebase-standards.md" "Firebase Standards & Security" 9500 echo "" -echo "⚙️ 8. Hooks Locaux & Scripts d'Installation :" -check_executable "scripts/install-hooks.sh" "Script d'Installation des Hooks" -check_executable ".agent/hooks/pre-commit-airbag.sh" "Hook Pré-Commit Airbag" -check_executable ".agent/hooks/post-merge-dual-sync.sh" "Hook Post-Merge Dual-Sync" -check_file ".agent/hooks.json" "Déclaration Native des Hooks Antigravity" 1000 -check_executable ".agent/hooks/branch-guard.mjs" "Hook Branch-Guard PreToolUse" 3000 -check_executable ".agent/hooks/plan-guard.mjs" "Hook Plan-Guard PreToolUse" 5500 -check_executable ".agent/hooks/pre-invocation-anchor.sh" "Hook Context-Anchor PreInvocation" 1000 -check_executable ".agent/hooks/post-checkout" "Hook Post-Checkout Issue Progress Sync" 2000 +echo "⚙️ 8. Local Hooks & Installation Scripts:" +check_executable "scripts/install-hooks.sh" "Hooks Installation Script" +check_executable ".agent/hooks/pre-commit-airbag.sh" "Pre-Commit Airbag Hook" +check_executable ".agent/hooks/post-merge-dual-sync.sh" "Post-Merge Dual-Sync Hook" +check_file ".agent/hooks.json" "Native Antigravity Hooks Declaration" 1000 +check_executable ".agent/hooks/branch-guard.mjs" "Branch-Guard PreToolUse Hook" 3000 +check_executable ".agent/hooks/plan-guard.mjs" "Plan-Guard PreToolUse Hook" 5500 +check_executable ".agent/hooks/pre-invocation-anchor.sh" "Context-Anchor PreInvocation Hook" 1000 +check_executable ".agent/hooks/post-checkout" "Post-Checkout Issue Progress Sync Hook" 2000 echo "" -echo "🛸 9. Sidecars Déterministes (.agent/sidecars/ — max 4 500 octets) :" +echo "🛸 9. Deterministic Sidecars (.agent/sidecars/ — max 4,500 bytes):" check_executable ".agent/sidecars/sync-issue-progress.mjs" "Sidecar Sync Issue Progress" 4500 echo "" -echo "⚡ 10. Compétences Sémantiques Natives (.agent/skills/ — max 4 500 octets) :" -check_file ".agent/skills/plan-issue/SKILL.md" "Skill plan-issue (Inception & Cadrage)" 4500 +echo "⚡ 10. Native Semantic Skills (.agent/skills/ — max 4,500 bytes):" +check_file ".agent/skills/plan-issue/SKILL.md" "Skill plan-issue (Inception & Scoping)" 4500 check_file ".agent/skills/open-pr/SKILL.md" "Skill open-pr (Release & Walkthrough)" 4500 -check_file ".agent/skills/quality-airbag/SKILL.md" "Skill quality-airbag (Inspection Qualité)" 4500 -check_file ".agent/skills/sync-stitch/SKILL.md" "Skill sync-stitch (Synchro Stitch MCP)" 4500 +check_file ".agent/skills/quality-airbag/SKILL.md" "Skill quality-airbag (Quality Inspection)" 4500 +check_file ".agent/skills/sync-stitch/SKILL.md" "Skill sync-stitch (Stitch MCP Sync)" 4500 echo "" -echo "🔍 11. Vérification du Frontmatter YAML dans DESIGN.md :" +echo "🔍 11. YAML Frontmatter Verification in DESIGN.md:" if grep -q "name:.*Serene Intellectual" "$ROOT_DIR/DESIGN.md"; then - echo " ✅ [OK] YAML Frontmatter 'Serene Intellectual' détecté dans DESIGN.md" + echo " ✅ [OK] YAML Frontmatter 'Serene Intellectual' detected in DESIGN.md" else - echo " ❌ [INVALIDE] Frontmatter YAML invalide ou manquant dans DESIGN.md" + echo " ❌ [INVALID] Invalid or missing YAML Frontmatter in DESIGN.md" FAILED=$((FAILED + 1)) fi echo "" echo "==================================================================" if [ "$FAILED" -eq 0 ]; then - echo "🎉 Tous les contrats documentaires, personas, templates, skills, hooks, sidecars et règles sont validés !" + echo "🎉 All documentation contracts, personas, templates, skills, hooks, sidecars, and rules validated!" echo "==================================================================" exit 0 else - echo "🚨 ÉCHEC : $FAILED anomalie(s) détectée(s) dans l'architecture multi-agent !" + echo "🚨 FAILURE: $FAILED defect(s) detected in multi-agent architecture!" echo "==================================================================" exit 1 fi