From 5e089b05f2dd686a509f80c067d276c134ac6451 Mon Sep 17 00:00:00 2001 From: jsboige Date: Tue, 15 Sep 2026 10:29:58 +0200 Subject: [PATCH 1/2] fix(symbolicai,#16264): Argument_Analysis -- classpath Tweety repointe sur le referentiel canonique + bootstrap idempotent MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit La cellule [11] de `Argument_Analysis_Agentic-0-init_agent.ipynb` cherchait le JDK portable et les JARs Tweety aux emplacements d'AVANT #1437 (Phase 1, EPIC #1396) : `libs/`, `SymbolicAI/libs`, `../libs`, `Argument_Analysis/jdk-17-portable`. Tous sont vides ou inexistants depuis que les JARs (857 Mo) ont ete de-suivis et deplaces vers le referentiel partage -- d'ou `Aucun JAR Tweety trouve` puis `Classpath Tweety vide` et une JVM non demarree. Trois changements dans CETTE cellule, meme fichier : 1. localisation via la shim du depot (`argumentation_lib._paths.SYMBOLIC_AI_DIR`, resolution __file__-relative donc insensible au cwd du lanceur) -- la convention de la famille, qui interdit le walk manuel ; les anciens chemins restent en repli, donc aucune regression ; 2. bootstrap idempotent des JARs quand le classpath est vide : appel de l'outil canonique de la serie Tweety (`download_tweety_tools.py --jars --lib-dir`) plutot qu'un telechargement reimplemente -- un clone neuf n'a aucun JAR ; 3. conformite C.1 : le `raise Exception("Classpath Tweety vide")` devient un degrade journalise, comme l'exige la note explicite de `-0-init.ipynb` (« aucun guard de path ni raise dans la cellule »). Version alignee sur 1.30, defaut de `--lib-dir/--version` de l'outil canonique : cela tranche le « 1.28 vs 1.30 » laisse ouvert par l'issue, dont la forme concrete sur disque est une duplication 1.29/1.30 dans le referentiel local (77 JARs = les 42 du jeu 1.30 + 35 residus 1.29), signalee et non nettoyee. Preuves (meme machine, memes artefacts, outil du depot) : - controle ROUGE sur la version HEAD : reproduit exactement le symptome de l'issue, JDK introuvable ET classpath vide -> « JVM/Tweety NON OPERATIONNELS » ; - VERRE cas nominal : JDK Zulu 17 trouve, classpath 77 JARs, Java 17.0.11, 4/4 classes critiques, « JVM + Tweety OPERATIONNELS » ; - VERRE cas clone neuf : referentiel deplace hors de son chemin pour forcer la branche de bootstrap -> telechargement des 42 JARs 1.30 en ~60 s, puis classpath construit et « JVM + Tweety OPERATIONNELS » ; les 42 sont un sous-ensemble strict des 77 (verifie nom a nom, 0 absent) ; - execution complete : 11/11 cellules code avec execution_count non nul, 0 erreur, notebook committe AVEC ses sorties (C.2/H.3) -- celles du run post-bootstrap (42 JARs), etat reproductible par un clone neuf. Dans le SOURCE, seule la cellule 11 change ; le diff embarque aussi le rafraichissement des sorties de toutes les cellules, consequence exigee par C.2 d'une re-execution complete. Catalogue, baseline et README non touches. Collision a sequencer (ai-01) : #16247 (F4) et #16269 (titres, lot 1) touchent deja ce meme notebook ; les apports ne se recouvrent pas (code de cellule 11 vs noms de modeles et titres), mais l'ordre de merge n'est pas le mien. Residu assume : les notebooks soeurs (-1..-5) n'ont pas ete re-executes (aucun ne reference les anciens chemins, mais la verification par execution n'a porte que sur le notebook de l'issue) -- d'ou `See` et non `Closes`. La duplication de fond (la cellule embarque son propre amorcage JVM alors que la shim expose `initialize_jvm()`) est un grain separe. Co-Authored-By: Claude Sonnet 5 --- ...gument_Analysis_Agentic-0-init_agent.ipynb | 613 ++++++++++++++---- 1 file changed, 501 insertions(+), 112 deletions(-) diff --git a/MyIA.AI.Notebooks/SymbolicAI/Argument_Analysis/Argument_Analysis_Agentic-0-init_agent.ipynb b/MyIA.AI.Notebooks/SymbolicAI/Argument_Analysis/Argument_Analysis_Agentic-0-init_agent.ipynb index 8f5e2b0c52..29fe26c0aa 100644 --- a/MyIA.AI.Notebooks/SymbolicAI/Argument_Analysis/Argument_Analysis_Agentic-0-init_agent.ipynb +++ b/MyIA.AI.Notebooks/SymbolicAI/Argument_Analysis/Argument_Analysis_Agentic-0-init_agent.ipynb @@ -4,17 +4,39 @@ "cell_type": "code", "execution_count": 1, "id": "34e4559f", + "metadata": { + "execution": { + "iopub.execute_input": "2026-09-15T08:27:28.369252Z", + "iopub.status.busy": "2026-09-15T08:27:28.369063Z", + "iopub.status.idle": "2026-09-15T08:27:28.373310Z", + "shell.execute_reply": "2026-09-15T08:27:28.372381Z" + }, + "papermill": { + "duration": 0.01361, + "end_time": "2026-09-15T08:27:28.374644", + "exception": false, + "start_time": "2026-09-15T08:27:28.361034", + "status": "completed" + }, + "tags": [] + }, "outputs": [], "source": [ "# Parameters\n", "BATCH_MODE = \"true\"\n" - ], - "metadata": {} + ] }, { "cell_type": "markdown", "id": "6196daf0", "metadata": { + "papermill": { + "duration": 0.011329, + "end_time": "2026-09-15T08:27:28.395918", + "exception": false, + "start_time": "2026-09-15T08:27:28.384589", + "status": "completed" + }, "tags": [] }, "source": [ @@ -45,6 +67,13 @@ "cell_type": "markdown", "id": "80571e1e", "metadata": { + "papermill": { + "duration": 0.006652, + "end_time": "2026-09-15T08:27:28.411991", + "exception": false, + "start_time": "2026-09-15T08:27:28.405339", + "status": "completed" + }, "tags": [] }, "source": [ @@ -61,6 +90,22 @@ "cell_type": "code", "execution_count": 2, "id": "a3661e07", + "metadata": { + "execution": { + "iopub.execute_input": "2026-09-15T08:27:28.430300Z", + "iopub.status.busy": "2026-09-15T08:27:28.429966Z", + "iopub.status.idle": "2026-09-15T08:27:30.638389Z", + "shell.execute_reply": "2026-09-15T08:27:30.637851Z" + }, + "papermill": { + "duration": 2.220173, + "end_time": "2026-09-15T08:27:30.639163", + "exception": false, + "start_time": "2026-09-15T08:27:28.418990", + "status": "completed" + }, + "tags": [] + }, "outputs": [ { "name": "stdout", @@ -122,13 +167,19 @@ " print(\"Si les cellules suivantes echouent, redemarrez le noyau et re-executez.\")\n", "\n", "print(\"--- Fin verification compatibilite ---\")\n" - ], - "metadata": {} + ] }, { "cell_type": "markdown", "id": "pmpm31xh56", "metadata": { + "papermill": { + "duration": 0.007204, + "end_time": "2026-09-15T08:27:30.654878", + "exception": false, + "start_time": "2026-09-15T08:27:30.647674", + "status": "completed" + }, "tags": [] }, "source": [ @@ -147,54 +198,70 @@ "cell_type": "code", "execution_count": 3, "id": "dd1eb173", + "metadata": { + "execution": { + "iopub.execute_input": "2026-09-15T08:27:30.670743Z", + "iopub.status.busy": "2026-09-15T08:27:30.670416Z", + "iopub.status.idle": "2026-09-15T08:27:31.031075Z", + "shell.execute_reply": "2026-09-15T08:27:31.030663Z" + }, + "papermill": { + "duration": 0.369778, + "end_time": "2026-09-15T08:27:31.032034", + "exception": false, + "start_time": "2026-09-15T08:27:30.662256", + "status": "completed" + }, + "tags": [] + }, "outputs": [ { "name": "stderr", "output_type": "stream", "text": [ - "11:29:34 [INFO] [Orchestration.Setup] --- Vérification des dépendances ---\n" + "10:27:30 [INFO] [Orchestration.Setup] --- Vérification des dépendances ---\n" ] }, { "name": "stderr", "output_type": "stream", "text": [ - "11:29:34 [INFO] [Orchestration.Setup] ✔️ Dépendance 'jpype' trouvée.\n" + "10:27:30 [INFO] [Orchestration.Setup] ✔️ Dépendance 'jpype' trouvée.\n" ] }, { "name": "stderr", "output_type": "stream", "text": [ - "11:29:34 [INFO] [Orchestration.Setup] ✔️ Dépendance 'semantic_kernel' trouvée.\n" + "10:27:30 [INFO] [Orchestration.Setup] ✔️ Dépendance 'semantic_kernel' trouvée.\n" ] }, { "name": "stderr", "output_type": "stream", "text": [ - "11:29:34 [INFO] [Orchestration.Setup] ✔️ Dépendance 'dotenv' trouvée.\n" + "10:27:30 [INFO] [Orchestration.Setup] ✔️ Dépendance 'dotenv' trouvée.\n" ] }, { "name": "stderr", "output_type": "stream", "text": [ - "11:29:35 [INFO] [Orchestration.Setup] ✔️ Dépendance 'pandas' trouvée.\n" + "10:27:30 [INFO] [Orchestration.Setup] ✔️ Dépendance 'pandas' trouvée.\n" ] }, { "name": "stderr", "output_type": "stream", "text": [ - "11:29:35 [INFO] [Orchestration.Setup] ✔️ Dépendance 'requests' trouvée.\n" + "10:27:31 [INFO] [Orchestration.Setup] ✔️ Dépendance 'requests' trouvée.\n" ] }, { "name": "stderr", "output_type": "stream", "text": [ - "11:29:35 [INFO] [Orchestration.Setup] \n", + "10:27:31 [INFO] [Orchestration.Setup] \n", "✅ Dépendances principales vérifiées.\n" ] }, @@ -202,21 +269,35 @@ "name": "stderr", "output_type": "stream", "text": [ - "11:29:35 [INFO] [Orchestration.Setup] --- Chargement Configuration LLM ---\n" + "10:27:31 [INFO] [Orchestration.Setup] --- Chargement Configuration LLM ---\n" + ] + }, + { + "name": "stderr", + "output_type": "stream", + "text": [ + "10:27:31 [ERROR] [Orchestration.Setup] ❌ Configuration Azure OpenAI incomplète dans .env (OPENAI_API_KEY, OPENAI_CHAT_MODEL_ID, OPENAI_ENDPOINT requis).\n" + ] + }, + { + "name": "stderr", + "output_type": "stream", + "text": [ + "10:27:31 [WARNING] [Orchestration.Setup] Configuration LLM incomplete. Verifiez votre fichier .env (OPENAI_API_KEY, OPENAI_CHAT_MODEL_ID).\n" ] }, { "name": "stderr", "output_type": "stream", "text": [ - "11:29:35 [INFO] [Orchestration.Setup] ✅ Configuration OpenAI standard détectée (Modèle: gpt-5-mini). Org ID: Non fourni.\n" + "10:27:31 [WARNING] [Orchestration.Setup] Les cellules utilisant le service LLM fonctionneront en mode degrade.\n" ] }, { "name": "stderr", "output_type": "stream", "text": [ - "11:29:35 [INFO] [Orchestration.Setup] --- Fin Configuration Initiale ---\n" + "10:27:31 [INFO] [Orchestration.Setup] --- Fin Configuration Initiale ---\n" ] } ], @@ -346,13 +427,19 @@ " logger.warning(\"Variable 'use_azure_openai' non définie (erreur config?), défaut à False.\")\n", "\n", "logger.info(\"--- Fin Configuration Initiale ---\")\n" - ], - "metadata": {} + ] }, { "cell_type": "markdown", "id": "c689b59e", "metadata": { + "papermill": { + "duration": 0.009955, + "end_time": "2026-09-15T08:27:31.051307", + "exception": false, + "start_time": "2026-09-15T08:27:31.041352", + "status": "completed" + }, "tags": [] }, "source": [ @@ -365,19 +452,35 @@ "cell_type": "code", "execution_count": 4, "id": "ab60fc96", + "metadata": { + "execution": { + "iopub.execute_input": "2026-09-15T08:27:31.074180Z", + "iopub.status.busy": "2026-09-15T08:27:31.073758Z", + "iopub.status.idle": "2026-09-15T08:27:31.080298Z", + "shell.execute_reply": "2026-09-15T08:27:31.079251Z" + }, + "papermill": { + "duration": 0.020888, + "end_time": "2026-09-15T08:27:31.081496", + "exception": false, + "start_time": "2026-09-15T08:27:31.060608", + "status": "completed" + }, + "tags": [] + }, "outputs": [ { "name": "stderr", "output_type": "stream", "text": [ - "11:29:35 [INFO] [Orchestration.Config] ✅ Configuration OpenAI standard chargée (Modèle: gpt-5-mini). Org ID: Non fourni.\n" + "10:27:31 [WARNING] [Orchestration.Config] ⚠️ Configuration Azure OpenAI incomplète dans .env (OPENAI_API_KEY, OPENAI_CHAT_MODEL_ID, OPENAI_ENDPOINT requis).\n" ] }, { "name": "stdout", "output_type": "stream", "text": [ - "✅ Configuration OpenAI standard chargée (Modèle: gpt-5-mini). Org ID: Non fourni.\n" + "⚠️ Configuration Azure OpenAI incomplète dans .env (OPENAI_API_KEY, OPENAI_CHAT_MODEL_ID, OPENAI_ENDPOINT requis).\n" ] } ], @@ -427,13 +530,19 @@ "if 'use_azure_openai' not in locals():\n", " use_azure_openai = False # Défaut si erreur précédente\n", " cfg_logger.warning(\"Variable 'use_azure_openai' non définie due à une erreur de config, défaut à False.\")" - ], - "metadata": {} + ] }, { "cell_type": "markdown", "id": "s3yp5wc2bg", "metadata": { + "papermill": { + "duration": 0.010063, + "end_time": "2026-09-15T08:27:31.101433", + "exception": false, + "start_time": "2026-09-15T08:27:31.091370", + "status": "completed" + }, "tags": [] }, "source": [ @@ -461,6 +570,13 @@ "cell_type": "markdown", "id": "478a85e7", "metadata": { + "papermill": { + "duration": 0.009887, + "end_time": "2026-09-15T08:27:31.121651", + "exception": false, + "start_time": "2026-09-15T08:27:31.111764", + "status": "completed" + }, "tags": [] }, "source": [ @@ -485,6 +601,13 @@ "execution_count": null, "id": "a59062ad", "metadata": { + "papermill": { + "duration": 0.009528, + "end_time": "2026-09-15T08:27:31.140894", + "exception": false, + "start_time": "2026-09-15T08:27:31.131366", + "status": "completed" + }, "tags": [] }, "outputs": [], @@ -522,12 +645,28 @@ "cell_type": "code", "execution_count": 5, "id": "cc5a8f2e", + "metadata": { + "execution": { + "iopub.execute_input": "2026-09-15T08:27:31.162453Z", + "iopub.status.busy": "2026-09-15T08:27:31.162110Z", + "iopub.status.idle": "2026-09-15T08:27:31.476728Z", + "shell.execute_reply": "2026-09-15T08:27:31.476164Z" + }, + "papermill": { + "duration": 0.325824, + "end_time": "2026-09-15T08:27:31.477457", + "exception": false, + "start_time": "2026-09-15T08:27:31.151633", + "status": "completed" + }, + "tags": [] + }, "outputs": [ { "name": "stderr", "output_type": "stream", "text": [ - "11:29:35 [INFO] [Orchestration.JPype] \n", + "10:27:31 [INFO] [Orchestration.JPype] \n", "--- Configuration Auto-Suffisante de la JVM (Option B - Embarquée) ---\n" ] }, @@ -535,126 +674,119 @@ "name": "stderr", "output_type": "stream", "text": [ - "11:29:35 [INFO] [Orchestration.JPype] 🔍 Recherche JDK portable dans l'arborescence projet...\n" + "10:27:31 [INFO] [Orchestration.JPype] 🔍 Recherche JDK portable dans l'arborescence projet...\n" ] }, { "name": "stderr", "output_type": "stream", "text": [ - "11:29:35 [INFO] [Orchestration.JPype] ✅ JDK portable trouvé: MyIA.AI.Notebooks\\SymbolicAI\\Argument_Analysis\\jdk-17-portable\\zulu17.50.19-ca-jdk17.0.11-win_x64\n" + "10:27:31 [INFO] [Orchestration.JPype] ✅ JDK portable trouvé: D:\\Dev\\CoursIA-16264\\MyIA.AI.Notebooks\\SymbolicAI\\Tweety\\jdk-17-portable\\zulu17.50.19-ca-jdk17.0.11-win_x64\n" ] }, { "name": "stderr", "output_type": "stream", "text": [ - "11:29:35 [INFO] [Orchestration.JPype] 🏠 JAVA_HOME configuré dynamiquement: MyIA.AI.Notebooks\\SymbolicAI\\Argument_Analysis\\jdk-17-portable\\zulu17.50.19-ca-jdk17.0.11-win_x64\n" + "10:27:31 [INFO] [Orchestration.JPype] 🏠 JAVA_HOME configuré dynamiquement: D:\\Dev\\CoursIA-16264\\MyIA.AI.Notebooks\\SymbolicAI\\Tweety\\jdk-17-portable\\zulu17.50.19-ca-jdk17.0.11-win_x64\n" ] }, { "name": "stderr", "output_type": "stream", "text": [ - "11:29:35 [INFO] [Orchestration.JPype] 📦 Construction du classpath Tweety...\n" + "10:27:31 [INFO] [Orchestration.JPype] 📦 Construction du classpath Tweety...\n" ] }, { "name": "stderr", "output_type": "stream", "text": [ - "11:29:35 [INFO] [Orchestration.JPype] Scan des JARs dans: libs\n" + "10:27:31 [INFO] [Orchestration.JPype] Scan des JARs dans: D:\\Dev\\CoursIA-16264\\MyIA.AI.Notebooks\\SymbolicAI\\Tweety\\libs\n" ] }, { "name": "stderr", "output_type": "stream", "text": [ - "11:29:35 [INFO] [Orchestration.JPype] Scan des JARs dans: ..\\libs\n" + "10:27:31 [INFO] [Orchestration.JPype] ✅ 42 JARs trouvés dans D:\\Dev\\CoursIA-16264\\MyIA.AI.Notebooks\\SymbolicAI\\Tweety\\libs\n" ] }, { "name": "stderr", "output_type": "stream", "text": [ - "11:29:35 [INFO] [Orchestration.JPype] ✅ 41 JARs trouvés dans ..\\libs\n" + "10:27:31 [INFO] [Orchestration.JPype] ✅ Classpath construit: 42 JARs Tweety\n" ] }, { "name": "stderr", "output_type": "stream", "text": [ - "11:29:35 [INFO] [Orchestration.JPype] ✅ Classpath construit: 41 JARs Tweety\n" + "10:27:31 [INFO] [Orchestration.JPype] 🚀 Démarrage JVM avec 42 JARs Tweety...\n" ] }, { "name": "stderr", "output_type": "stream", "text": [ - "11:29:35 [INFO] [Orchestration.JPype] 🚀 Démarrage JVM avec 41 JARs Tweety...\n" + "10:27:31 [INFO] [Orchestration.JPype] ✅ JVM démarrée avec succès et domaines enregistrés\n" ] }, { "name": "stderr", "output_type": "stream", "text": [ - "11:29:37 [INFO] [Orchestration.JPype] ✅ JVM démarrée avec succès et domaines enregistrés\n" + "10:27:31 [INFO] [Orchestration.JPype] ☕ Java 17.0.11 opérationnel\n" ] }, { "name": "stderr", "output_type": "stream", "text": [ - "11:29:37 [INFO] [Orchestration.JPype] ☕ Java 17.0.11 opérationnel\n" + "10:27:31 [INFO] [Orchestration.JPype] 🎯 Test des classes critiques Tweety...\n" ] }, { "name": "stderr", "output_type": "stream", "text": [ - "11:29:37 [INFO] [Orchestration.JPype] 🎯 Test des classes critiques Tweety...\n" + "10:27:31 [INFO] [Orchestration.JPype] ✅ InformationObject: Accessible\n" ] }, { "name": "stderr", "output_type": "stream", "text": [ - "11:29:37 [INFO] [Orchestration.JPype] ✅ InformationObject: Accessible\n" + "10:27:31 [INFO] [Orchestration.JPype] ✅ PlParser: Accessible\n" ] }, { "name": "stderr", "output_type": "stream", "text": [ - "11:29:37 [INFO] [Orchestration.JPype] ✅ PlParser: Accessible\n" + "10:27:31 [INFO] [Orchestration.JPype] ✅ PlFormula: Accessible\n" ] }, { "name": "stderr", "output_type": "stream", "text": [ - "11:29:37 [INFO] [Orchestration.JPype] ✅ PlFormula: Accessible\n" + "10:27:31 [INFO] [Orchestration.JPype] ✅ BaseRevisionOperator: Accessible\n" ] }, { "name": "stderr", "output_type": "stream", "text": [ - "11:29:37 [INFO] [Orchestration.JPype] ✅ BaseRevisionOperator: Accessible\n" + "10:27:31 [INFO] [Orchestration.JPype] 🏆 Test Tweety RÉUSSI: 4/4 classes accessibles\n" ] }, { "name": "stderr", "output_type": "stream", "text": [ - "11:29:37 [INFO] [Orchestration.JPype] 🏆 Test Tweety RÉUSSI: 4/4 classes accessibles\n" - ] - }, - { - "name": "stderr", - "output_type": "stream", - "text": [ - "11:29:37 [INFO] [Orchestration.JPype] \n", + "10:27:31 [INFO] [Orchestration.JPype] \n", "🎉 🏆 SUCCÈS TOTAL - INFRASTRUCTURE TWEETY AUTO-SUFFISANTE! 🏆 🎉\n" ] }, @@ -662,21 +794,21 @@ "name": "stderr", "output_type": "stream", "text": [ - "11:29:37 [INFO] [Orchestration.JPype] ✅ PropositionalLogicAgent prêt pour exécution native\n" + "10:27:31 [INFO] [Orchestration.JPype] ✅ PropositionalLogicAgent prêt pour exécution native\n" ] }, { "name": "stderr", "output_type": "stream", "text": [ - "11:29:37 [INFO] [Orchestration.JPype] ✅ Pipeline argumentatif avec intégration formelle/informelle opérationnel\n" + "10:27:31 [INFO] [Orchestration.JPype] ✅ Pipeline argumentatif avec intégration formelle/informelle opérationnel\n" ] }, { "name": "stderr", "output_type": "stream", "text": [ - "11:29:37 [INFO] [Orchestration.JPype] \n", + "10:27:31 [INFO] [Orchestration.JPype] \n", "🟢 STATUT FINAL: JVM + Tweety OPÉRATIONNELS\n" ] }, @@ -684,21 +816,21 @@ "name": "stderr", "output_type": "stream", "text": [ - "11:29:37 [INFO] [Orchestration.JPype] Pipeline peut atteindre son potentiel maximal (8/10)\n" + "10:27:31 [INFO] [Orchestration.JPype] Pipeline peut atteindre son potentiel maximal (8/10)\n" ] }, { "name": "stderr", "output_type": "stream", "text": [ - "11:29:37 [INFO] [Orchestration.JPype] --- Fin Configuration JPype Auto-Suffisante ---\n" + "10:27:31 [INFO] [Orchestration.JPype] --- Fin Configuration JPype Auto-Suffisante ---\n" ] }, { "name": "stderr", "output_type": "stream", "text": [ - "11:29:37 [INFO] [Orchestration.JPype] ✅ Tweety opérationnel - PropositionalLogicAgent en mode natif\n" + "10:27:31 [INFO] [Orchestration.JPype] ✅ Tweety opérationnel - PropositionalLogicAgent en mode natif\n" ] } ], @@ -711,6 +843,7 @@ "import os\n", "import pathlib\n", "import platform\n", + "import subprocess\n", "import sys\n", "import logging\n", "from typing import Optional\n", @@ -720,6 +853,62 @@ "\n", "# --- Fonctions embarquées (extraites des scripts de réparation validés) ---\n", "\n", + "# --- Reference de localisation commune (#16264) ---\n", + "# La shim #4960 (argumentation_lib/_paths.py) resout les chemins en\n", + "# __file__-relatif, donc insensible au cwd du lanceur (Jupyter, papermill --cwd,\n", + "# outil du depot) : c'est la convention de la famille Argument_Analysis, et elle\n", + "# interdit le walk manuel. Repli explicite si le dossier du notebook n'est pas\n", + "# importable, pour que la cellule reste executable (aucun raise, regle C.1).\n", + "try:\n", + " from argumentation_lib._paths import SYMBOLIC_AI_DIR\n", + " TWEETY_DIR = SYMBOLIC_AI_DIR / \"Tweety\"\n", + "except ImportError:\n", + " logger.warning(\"argumentation_lib non importable -- repli sur un chemin relatif au cwd\")\n", + " TWEETY_DIR = pathlib.Path(\"MyIA.AI.Notebooks/SymbolicAI/Tweety\")\n", + "\n", + "#: Reference partagee avec la serie Tweety : c'est le defaut `--lib-dir` de\n", + "#: download_tweety_tools.py, et le seul repertoire que l'outil canonique\n", + "#: alimente (JARs TweetyProject + JDK Zulu 17 portable). Avant #16264 la cellule\n", + "#: cherchait l'ancien emplacement local Argument_Analysis/libs, vide depuis\n", + "#: #1437 (Phase 1 de l'EPIC #1396) : classpath vide, JVM non demarree, sans que\n", + "#: rien ne le signale a l'etudiant.\n", + "TWEETY_LIBS_DIR = \"libs\"\n", + "TWEETY_JDK_DIR = \"jdk-17-portable\"\n", + "\n", + "\n", + "def ensure_tweety_jars(jars_dir: pathlib.Path) -> bool:\n", + " \"\"\"Installe les JARs Tweety manquants via l'outil canonique (idempotent).\n", + "\n", + " Depuis #1437 les 71 JARs TweetyProject ne sont plus suivis par git : un clone\n", + " neuf n'en contient aucun et la JVM ne peut pas demarrer. On invoque le script\n", + " de la serie Tweety plutot que de reimplementer un telechargement ici.\n", + " Retourne True si le repertoire contient des JARs a l'issue de l'appel.\n", + " \"\"\"\n", + " if jars_dir.is_dir() and any(jars_dir.glob(\"*.jar\")):\n", + " return True\n", + "\n", + " downloader = TWEETY_DIR / \"scripts\" / \"download_tweety_tools.py\"\n", + " if not downloader.exists():\n", + " logger.error(\"Bootstrap JARs impossible: %s introuvable\", downloader)\n", + " return False\n", + "\n", + " logger.info(\"Aucun JAR Tweety dans %s -- bootstrap via %s\", jars_dir, downloader.name)\n", + " try:\n", + " proc = subprocess.run(\n", + " [sys.executable, str(downloader), \"--jars\",\n", + " \"--lib-dir\", str(jars_dir), \"--no-interactive\"],\n", + " capture_output=True, text=True, timeout=1800,\n", + " )\n", + " except Exception as exc:\n", + " logger.error(\"Bootstrap JARs echoue: %s\", exc)\n", + " return False\n", + "\n", + " if proc.returncode != 0:\n", + " logger.error(\"Bootstrap JARs echoue (rc=%s): %s\",\n", + " proc.returncode, (proc.stderr or proc.stdout or \"\")[-800:])\n", + " return jars_dir.is_dir() and any(jars_dir.glob(\"*.jar\"))\n", + "\n", + "\n", "def find_portable_jdk() -> Optional[str]:\n", " \"\"\"\n", " Localise automatiquement le JDK portable dans l'arborescence du projet.\n", @@ -729,10 +918,13 @@ " \n", " # Chemins de recherche prioritaires pour le JDK portable\n", " search_paths = [\n", + " # Reference partagee avec la serie Tweety (defaut --jdk de l'outil).\n", + " TWEETY_DIR / TWEETY_JDK_DIR,\n", + " # Ancien emplacement local a Argument_Analysis : repli, plus alimente.\n", " pathlib.Path(\"MyIA.AI.Notebooks/SymbolicAI/Argument_Analysis/jdk-17-portable\"),\n", " pathlib.Path(\"jdk-17-portable\"),\n", " pathlib.Path(\"../jdk-17-portable\"),\n", - " pathlib.Path(\"../../jdk-17-portable\")\n", + " pathlib.Path(\"../../jdk-17-portable\"),\n", " ]\n", " \n", " for base_path in search_paths:\n", @@ -763,11 +955,16 @@ " logger.info(\"📦 Construction du classpath Tweety...\")\n", " \n", " # Chemins de recherche des JARs\n", - " libs_paths = [\n", - " pathlib.Path(\"libs\"),\n", - " pathlib.Path(\"MyIA.AI.Notebooks/SymbolicAI/libs\"),\n", - " pathlib.Path(\"../libs\")\n", - " ]\n", + " # Reference partagee d'abord (elle seule est alimentee par l'outil\n", + " # canonique) ; les anciens emplacements restent en repli.\n", + " libs_paths = [TWEETY_DIR / TWEETY_LIBS_DIR,\n", + " pathlib.Path(\"libs\"),\n", + " pathlib.Path(\"MyIA.AI.Notebooks/SymbolicAI/libs\"),\n", + " pathlib.Path(\"../libs\")]\n", + "\n", + " # Un clone neuf n'a aucun JAR (gitignores depuis #1437) : bootstrap\n", + " # canonique, declenche uniquement parce que le classpath est vide.\n", + " ensure_tweety_jars(TWEETY_DIR / TWEETY_LIBS_DIR)\n", " \n", " jar_files = []\n", " \n", @@ -851,35 +1048,42 @@ " logger.info(f\"🏠 JAVA_HOME déjà configuré: {current_java_home}\")\n", " else:\n", " logger.error(\"❌ Impossible de localiser un JDK portable - JVM pourrait échouer\")\n", + " logger.error(\" Attendu: %s (download_tweety_tools.py --jdk) -- JAVA_HOME courant: %s\",\n", + " TWEETY_DIR / TWEETY_JDK_DIR, os.getenv('JAVA_HOME'))\n", " \n", " # Étape 3: Construire le classpath Tweety complet\n", " tweety_jars = get_tweety_classpath()\n", " \n", - " if not tweety_jars:\n", - " raise Exception(\"Classpath Tweety vide - JARs manquants\")\n", - " \n", - " # Étape 4: Démarrer la JVM avec configuration optimale\n", - " logger.info(f\"🚀 Démarrage JVM avec {len(tweety_jars)} JARs Tweety...\")\n", - " \n", - " jvm_args = [\n", - " \"-Xmx2g\", # Mémoire suffisante pour Tweety\n", - " \"-Djava.awt.headless=true\", # Mode headless pour notebooks\n", - " ]\n", - " \n", - " jpype.startJVM(\n", - " *jvm_args,\n", - " classpath=tweety_jars,\n", - " convertStrings=False,\n", - " ignoreUnrecognized=True\n", - " )\n", - " \n", - " # Étape 5: Enregistrer les domaines Java\n", - " jpype.imports.registerDomain(\"org\", alias=\"org\")\n", - " jpype.imports.registerDomain(\"java\", alias=\"java\")\n", - " jpype.imports.registerDomain(\"net\", alias=\"net\")\n", - " \n", - " logger.info(\"✅ JVM démarrée avec succès et domaines enregistrés\")\n", - " jvm_ready = True\n", + " # Étape 4: Démarrer la JVM avec configuration optimale.\n", + " # #16264 : aucun raise si le classpath reste vide (regle C.1) -- la\n", + " # cellule degrade proprement et le diagnostic final dit exactement ce\n", + " # qui manque, au lieu de faire echouer le notebook.\n", + " if tweety_jars:\n", + " logger.info(f\"🚀 Démarrage JVM avec {len(tweety_jars)} JARs Tweety...\")\n", + "\n", + " jvm_args = [\n", + " \"-Xmx2g\", # Mémoire suffisante pour Tweety\n", + " \"-Djava.awt.headless=true\", # Mode headless pour notebooks\n", + " ]\n", + "\n", + " jpype.startJVM(\n", + " *jvm_args,\n", + " classpath=tweety_jars,\n", + " convertStrings=False,\n", + " ignoreUnrecognized=True\n", + " )\n", + "\n", + " # Étape 5: Enregistrer les domaines Java\n", + " jpype.imports.registerDomain(\"org\", alias=\"org\")\n", + " jpype.imports.registerDomain(\"java\", alias=\"java\")\n", + " jpype.imports.registerDomain(\"net\", alias=\"net\")\n", + "\n", + " logger.info(\"✅ JVM démarrée avec succès et domaines enregistrés\")\n", + " jvm_ready = True\n", + " else:\n", + " logger.error(\"❌ Classpath Tweety vide après bootstrap -- JVM non démarrée\")\n", + " logger.error(\" Attendu: %s (JARs TweetyProject, outil canonique \"\n", + " \"download_tweety_tools.py --jars)\", TWEETY_DIR / TWEETY_LIBS_DIR)\n", " \n", " # Étape 6: Test de validation Tweety\n", " if jvm_ready:\n", @@ -959,13 +1163,19 @@ "# Diagnostic automatique à l'initialisation\n", "if 'jvm_ready' in locals():\n", " validate_tweety_ready()" - ], - "metadata": {} + ] }, { "cell_type": "markdown", "id": "7hq2u546fkr", "metadata": { + "papermill": { + "duration": 0.009828, + "end_time": "2026-09-15T08:27:31.497484", + "exception": false, + "start_time": "2026-09-15T08:27:31.487656", + "status": "completed" + }, "tags": [] }, "source": [ @@ -999,6 +1209,13 @@ "cell_type": "markdown", "id": "d201514e", "metadata": { + "papermill": { + "duration": 0.009425, + "end_time": "2026-09-15T08:27:31.516508", + "exception": false, + "start_time": "2026-09-15T08:27:31.507083", + "status": "completed" + }, "tags": [] }, "source": [ @@ -1015,6 +1232,13 @@ "cell_type": "markdown", "id": "a13a208e", "metadata": { + "papermill": { + "duration": 0.009719, + "end_time": "2026-09-15T08:27:31.536643", + "exception": false, + "start_time": "2026-09-15T08:27:31.526924", + "status": "completed" + }, "tags": [] }, "source": [ @@ -1061,12 +1285,28 @@ "cell_type": "code", "execution_count": 6, "id": "a303fa9c", + "metadata": { + "execution": { + "iopub.execute_input": "2026-09-15T08:27:31.557291Z", + "iopub.status.busy": "2026-09-15T08:27:31.557099Z", + "iopub.status.idle": "2026-09-15T08:27:31.560397Z", + "shell.execute_reply": "2026-09-15T08:27:31.560032Z" + }, + "papermill": { + "duration": 0.014933, + "end_time": "2026-09-15T08:27:31.561008", + "exception": false, + "start_time": "2026-09-15T08:27:31.546075", + "status": "completed" + }, + "tags": [] + }, "outputs": [ { "name": "stderr", "output_type": "stream", "text": [ - "11:29:37 [INFO] [root] Classe RhetoricalAnalysisState définie (via argumentation_lib shim, Phase 2 #2137).\n" + "10:27:31 [INFO] [root] Classe RhetoricalAnalysisState définie (via argumentation_lib shim, Phase 2 #2137).\n" ] } ], @@ -1091,13 +1331,19 @@ "state_logger = logging.getLogger(\"RhetoricalAnalysisState\")\n", "\n", "logging.info(\"Classe RhetoricalAnalysisState définie (via argumentation_lib shim, Phase 2 #2137).\")" - ], - "metadata": {} + ] }, { "cell_type": "markdown", "id": "0d4166a2", "metadata": { + "papermill": { + "duration": 0.011009, + "end_time": "2026-09-15T08:27:31.581850", + "exception": false, + "start_time": "2026-09-15T08:27:31.570841", + "status": "completed" + }, "tags": [] }, "source": [ @@ -1148,12 +1394,28 @@ "cell_type": "code", "execution_count": 7, "id": "61903410", + "metadata": { + "execution": { + "iopub.execute_input": "2026-09-15T08:27:31.604965Z", + "iopub.status.busy": "2026-09-15T08:27:31.604748Z", + "iopub.status.idle": "2026-09-15T08:27:31.610574Z", + "shell.execute_reply": "2026-09-15T08:27:31.610063Z" + }, + "papermill": { + "duration": 0.01885, + "end_time": "2026-09-15T08:27:31.611468", + "exception": false, + "start_time": "2026-09-15T08:27:31.592618", + "status": "completed" + }, + "tags": [] + }, "outputs": [ { "name": "stderr", "output_type": "stream", "text": [ - "11:29:37 [INFO] [root] Classe StateManagerPlugin définie (via argumentation_lib shim, Phase 2 #2137).\n" + "10:27:31 [INFO] [root] Classe StateManagerPlugin définie (via argumentation_lib shim, Phase 2 #2137).\n" ] } ], @@ -1180,13 +1442,19 @@ "sm_logger = logging.getLogger(\"Orchestration.StateManager\")\n", "\n", "logging.info(\"Classe StateManagerPlugin définie (via argumentation_lib shim, Phase 2 #2137).\")" - ], - "metadata": {} + ] }, { "cell_type": "markdown", "id": "a754dbe1", "metadata": { + "papermill": { + "duration": 0.010489, + "end_time": "2026-09-15T08:27:31.632914", + "exception": false, + "start_time": "2026-09-15T08:27:31.622425", + "status": "completed" + }, "tags": [] }, "source": [ @@ -1226,33 +1494,63 @@ "cell_type": "code", "execution_count": 8, "id": "95c09e20", + "metadata": { + "execution": { + "iopub.execute_input": "2026-09-15T08:27:31.656463Z", + "iopub.status.busy": "2026-09-15T08:27:31.656012Z", + "iopub.status.idle": "2026-09-15T08:27:31.664855Z", + "shell.execute_reply": "2026-09-15T08:27:31.664447Z" + }, + "papermill": { + "duration": 0.020692, + "end_time": "2026-09-15T08:27:31.665509", + "exception": false, + "start_time": "2026-09-15T08:27:31.644817", + "status": "completed" + }, + "tags": [] + }, "outputs": [ { "name": "stderr", "output_type": "stream", "text": [ - "11:29:37 [INFO] [Orchestration.LLM] --- Configuration du Service LLM Global ---\n" + "10:27:31 [INFO] [Orchestration.LLM] --- Configuration du Service LLM Global ---\n" + ] + }, + { + "name": "stderr", + "output_type": "stream", + "text": [ + "10:27:31 [INFO] [Orchestration.LLM] Configuration Service Global: AzureChatCompletion...\n" ] }, { "name": "stderr", "output_type": "stream", "text": [ - "11:29:37 [INFO] [Orchestration.LLM] Configuration Service Global: OpenAIChatCompletion...\n" + "10:27:31 [WARNING] [Orchestration.LLM] Service LLM global non configure: chat_deployment_name is required.\n" ] }, { "name": "stderr", "output_type": "stream", "text": [ - "11:29:38 [INFO] [Orchestration.LLM] Service LLM global OpenAI (gpt-5-mini) créé.\n" + "10:27:31 [WARNING] [Orchestration.LLM] Les fonctionnalites dependent du service LLM seront en mode degrade.\n" ] }, { "name": "stderr", "output_type": "stream", "text": [ - "11:29:38 [INFO] [root] --- Fin Définitions Composants Partagés ---\n" + "10:27:31 [WARNING] [Orchestration.LLM] Service LLM global non disponible (None). Mode degrade active.\n" + ] + }, + { + "name": "stderr", + "output_type": "stream", + "text": [ + "10:27:31 [INFO] [root] --- Fin Définitions Composants Partagés ---\n" ] } ], @@ -1307,13 +1605,19 @@ "logging.info(\"--- Fin Définitions Composants Partagés ---\")\n", "\n", "# Rappel: PAS d'instance de RhetoricalAnalysisState ou StateManagerPlugin ou Kernel ici.\n" - ], - "metadata": {} + ] }, { "cell_type": "markdown", "id": "76c485ec", "metadata": { + "papermill": { + "duration": 0.009624, + "end_time": "2026-09-15T08:27:31.685251", + "exception": false, + "start_time": "2026-09-15T08:27:31.675627", + "status": "completed" + }, "tags": [] }, "source": [ @@ -1339,6 +1643,13 @@ "cell_type": "markdown", "id": "f7a615c6", "metadata": { + "papermill": { + "duration": 0.009559, + "end_time": "2026-09-15T08:27:31.704821", + "exception": false, + "start_time": "2026-09-15T08:27:31.695262", + "status": "completed" + }, "tags": [] }, "source": [ @@ -1386,12 +1697,28 @@ "cell_type": "code", "execution_count": 9, "id": "8bafcee0", + "metadata": { + "execution": { + "iopub.execute_input": "2026-09-15T08:27:31.726523Z", + "iopub.status.busy": "2026-09-15T08:27:31.726137Z", + "iopub.status.idle": "2026-09-15T08:27:31.731544Z", + "shell.execute_reply": "2026-09-15T08:27:31.731096Z" + }, + "papermill": { + "duration": 0.017476, + "end_time": "2026-09-15T08:27:31.732205", + "exception": false, + "start_time": "2026-09-15T08:27:31.714729", + "status": "completed" + }, + "tags": [] + }, "outputs": [ { "name": "stderr", "output_type": "stream", "text": [ - "11:29:38 [INFO] [Orchestration.AgentPM.Defs] Plugin PM (vide) et prompts semantiques (V17 - CODE-ONLY) definis.\n" + "10:27:31 [INFO] [Orchestration.AgentPM.Defs] Plugin PM (vide) et prompts semantiques (V17 - CODE-ONLY) definis.\n" ] } ], @@ -1495,13 +1822,19 @@ "prompt_write_conclusion_v7 = prompt_write_conclusion_v8\n", "\n", "logger.info(\"Plugin PM (vide) et prompts semantiques (V17 - CODE-ONLY) definis.\")" - ], - "metadata": {} + ] }, { "cell_type": "markdown", "id": "036e58ad", "metadata": { + "papermill": { + "duration": 0.010068, + "end_time": "2026-09-15T08:27:31.752594", + "exception": false, + "start_time": "2026-09-15T08:27:31.742526", + "status": "completed" + }, "tags": [] }, "source": [ @@ -1537,6 +1870,22 @@ "cell_type": "code", "execution_count": 10, "id": "7a1a3c2e", + "metadata": { + "execution": { + "iopub.execute_input": "2026-09-15T08:27:31.775946Z", + "iopub.status.busy": "2026-09-15T08:27:31.775623Z", + "iopub.status.idle": "2026-09-15T08:27:31.783129Z", + "shell.execute_reply": "2026-09-15T08:27:31.782536Z" + }, + "papermill": { + "duration": 0.020461, + "end_time": "2026-09-15T08:27:31.783894", + "exception": false, + "start_time": "2026-09-15T08:27:31.763433", + "status": "completed" + }, + "tags": [] + }, "outputs": [ { "name": "stdout", @@ -1694,13 +2043,19 @@ " logger.info(f\"Kernel {plugin_name} configure (V11).\")\n", "\n", "print(\"Fonction setup_pm_kernel definie : configuration kernel ProjectManager avec plugins et fonctions semantiques\")" - ], - "metadata": {} + ] }, { "cell_type": "markdown", "id": "1b9bb59a", "metadata": { + "papermill": { + "duration": 0.012221, + "end_time": "2026-09-15T08:27:31.806626", + "exception": false, + "start_time": "2026-09-15T08:27:31.794405", + "status": "completed" + }, "tags": [] }, "source": [ @@ -1742,12 +2097,28 @@ "cell_type": "code", "execution_count": 11, "id": "f2a524ce", + "metadata": { + "execution": { + "iopub.execute_input": "2026-09-15T08:27:31.828920Z", + "iopub.status.busy": "2026-09-15T08:27:31.827984Z", + "iopub.status.idle": "2026-09-15T08:27:31.832835Z", + "shell.execute_reply": "2026-09-15T08:27:31.832334Z" + }, + "papermill": { + "duration": 0.017139, + "end_time": "2026-09-15T08:27:31.834003", + "exception": false, + "start_time": "2026-09-15T08:27:31.816864", + "status": "completed" + }, + "tags": [] + }, "outputs": [ { "name": "stderr", "output_type": "stream", "text": [ - "11:29:38 [INFO] [Orchestration.AgentPM.Instructions] Instructions Systeme PM_INSTRUCTIONS (V15 - CODE-ONLY) definies.\n" + "10:27:31 [INFO] [Orchestration.AgentPM.Instructions] Instructions Systeme PM_INSTRUCTIONS (V15 - CODE-ONLY) definies.\n" ] } ], @@ -1792,13 +2163,19 @@ "PM_INSTRUCTIONS = PM_INSTRUCTIONS_V15\n", "\n", "logger.info(\"Instructions Systeme PM_INSTRUCTIONS (V15 - CODE-ONLY) definies.\")" - ], - "metadata": {} + ] }, { "cell_type": "markdown", "id": "61dwms8dzi", "metadata": { + "papermill": { + "duration": 0.00967, + "end_time": "2026-09-15T08:27:31.853592", + "exception": false, + "start_time": "2026-09-15T08:27:31.843922", + "status": "completed" + }, "tags": [] }, "source": [ @@ -1850,20 +2227,20 @@ ], "metadata": { "cost": { - "api_usd_est": 0.0, "api_provider": "OpenAI (gpt-5-mini, configuré via .env)", + "api_usd_est": 0.0, "cpu_min": 2, + "external_account": "OpenAI requis (OPENAI_API_KEY + OPENAI_CHAT_MODEL_ID lus via dotenv cell[7]) pour amorcer le pipeline Argument_Analysis ; ce carnet d'init crée le service mais n'effectue aucun appel API dans le run commis", "gpu_min": 0, "gpu_required": false, - "vram_gb": 0, - "vram_tier": "NONE", + "metadata_written": "2026-08-05", "network": true, - "external_account": "OpenAI requis (OPENAI_API_KEY + OPENAI_CHAT_MODEL_ID lus via dotenv cell[7]) pour amorcer le pipeline Argument_Analysis ; ce carnet d'init crée le service mais n'effectue aucun appel API dans le run commis", + "notes": "Carnet d'INIT (cell[0]) de la série Argument_Analysis_Agentic : configure Semantic Kernel + OpenAIChatCompletion (gpt-5-mini lu depuis .env) + JVM JPype/Tweety (42 JARs, Java 17.0.18 opérationnel dans le run commis), crée le service LLM global (cell[19]). Run commis : config chargée + service créé, AUCUNE complétion API (0 token, 0 USD) — l'init ne définit que les composants (état partagé, plugins, prompts PM). Le coût API réel est porté par les carnets aval (1-informal, 3-orchestration, capstone) qui enchaînent les invocations LLM. external_account déclaré car cell[7] lit OPENAI_API_KEY : un compte OpenAI configuré est nécessaire pour que l'init réussisse.", "reduced_pedagogical": "sans clé OpenAI : avertissement 'Configuration OpenAI standard incomplète' (cell[5]/cell[7]), service LLM non créé, pipeline aval bloqué ; les cellules utilisant le LLM basculent en mode dégradé", "reproducibility": "HIGH", - "metadata_written": "2026-08-05", "validator": "manual", - "notes": "Carnet d'INIT (cell[0]) de la série Argument_Analysis_Agentic : configure Semantic Kernel + OpenAIChatCompletion (gpt-5-mini lu depuis .env) + JVM JPype/Tweety (42 JARs, Java 17.0.18 opérationnel dans le run commis), crée le service LLM global (cell[19]). Run commis : config chargée + service créé, AUCUNE complétion API (0 token, 0 USD) — l'init ne définit que les composants (état partagé, plugins, prompts PM). Le coût API réel est porté par les carnets aval (1-informal, 3-orchestration, capstone) qui enchaînent les invocations LLM. external_account déclaré car cell[7] lit OPENAI_API_KEY : un compte OpenAI configuré est nécessaire pour que l'init réussisse." + "vram_gb": 0, + "vram_tier": "NONE" }, "kernelspec": { "display_name": "Python 3", @@ -1880,9 +2257,21 @@ "name": "python", "nbconvert_exporter": "python", "pygments_lexer": "ipython3", - "version": "3.13.12" + "version": "3.13.3" + }, + "papermill": { + "default_parameters": {}, + "duration": 6.350624, + "end_time": "2026-09-15T08:27:32.975728", + "environment_variables": {}, + "exception": null, + "input_path": "D:\\Dev\\CoursIA-16264\\MyIA.AI.Notebooks\\SymbolicAI\\Argument_Analysis\\Argument_Analysis_Agentic-0-init_agent.ipynb", + "output_path": "D:\\Dev\\CoursIA-16264\\MyIA.AI.Notebooks\\SymbolicAI\\Argument_Analysis\\Argument_Analysis_Agentic-0-init_agent_output.ipynb", + "parameters": {}, + "start_time": "2026-09-15T08:27:26.625104", + "version": "2.6.0" } }, "nbformat": 4, "nbformat_minor": 5 -} +} \ No newline at end of file From 505e0e2d5880ed22f72d0ced21241cb71687fee9 Mon Sep 17 00:00:00 2001 From: jsboige Date: Tue, 15 Sep 2026 10:47:52 +0200 Subject: [PATCH 2/2] fix(symbolicai,#16264): chemins relatifs dans les logs de la cellule [11] + re-execution avec l'env LLM attendu MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Deux regressions remontees par la CI sur la premiere revision de cette PR, toutes deux corrigees a la CAUSE puis re-executees (jamais retouchees dans la sortie). 1. `Output-failure ratchet` : MACHINE_PATH 0 -> 4. `find_portable_jdk` et `get_tweety_classpath` journalisent l'absolu depuis toujours (`{jdk_dir.absolute()}`, `{libs_path}`, `{portable_jdk}`). Ces lignes etaient INATTEIGNABLES tant que la cellule ne trouvait ni JDK ni JARs : en les faisant enfin trouver, ce correctif les a activees. La sortie committeas sur main portait `` a cet endroit -- une retouche anterieure du texte de sortie. On ne reproduit pas ce contournement : on arrete l'emission. Un helper `display_path()` rend desormais chaque chemin relatif a la racine du depot, donc il n'y a plus rien a nettoyer apres coup, et la sortie se regenere juste au run suivant (la retouche de sortie, elle, serait a refaire chaque fois -- le treadmill que le hook pre-commit decrit lui-meme). 2. `Output-failure ratchet` : TOOL_FAILURE 0 -> 1 (cellule [19], service LLM `non disponible`). La cellule [7] derive `use_azure_openai = bool(OPENAI_ENDPOINT)`. Le lanceur de verification fabriquait un `OPENAI_ENDPOINT` a partir de `OPENAI_BASE_URL` : la branche Azure s'activait, et comme ce poste n'a pas de `chat_deployment_name`, le service restait `None` -> sortie degradee. Le lanceur ne fabrique plus cet endpoint et fournit le `OPENAI_CHAT_MODEL_ID` par defaut documente (`docs/archive/NOTEBOOK_ENV_COVERAGE.md`). La cellule retrouve la configuration de main : `Service LLM global OpenAI (gpt-5-mini) créé`. Re-execution dans l'etat d'un CLONE NEUF, qui est celui que l'etudiant obtient et celui qui exerce la branche de bootstrap ajoutee : referentiel local mis de cote (77 JARs preserves, restaures et recomptes apres le run), 42 JARs 1.30 telecharges, JVM demarree, 4/4 classes critiques. Preuves : `check_output_failure_text origin/main` -> **0 regressed** (etait 1 notebook / 1 regressed) ; 11/11 cellules code, 0 erreur ; `check_exec_sequence` 0 dans les 4 buckets ; `detect_notebook_plan_loss` findings=0 ; `scan_md_table_syntax --check` 0 defaut ; `cell_order_ci` RC=0. Dans le SOURCE, seule la cellule 11 change toujours (verifie cellule par cellule contre origin/main). Co-Authored-By: Claude Sonnet 5 --- ...gument_Analysis_Agentic-0-init_agent.ipynb | 433 +++++++++--------- 1 file changed, 220 insertions(+), 213 deletions(-) diff --git a/MyIA.AI.Notebooks/SymbolicAI/Argument_Analysis/Argument_Analysis_Agentic-0-init_agent.ipynb b/MyIA.AI.Notebooks/SymbolicAI/Argument_Analysis/Argument_Analysis_Agentic-0-init_agent.ipynb index 29fe26c0aa..ce0c9dbd6e 100644 --- a/MyIA.AI.Notebooks/SymbolicAI/Argument_Analysis/Argument_Analysis_Agentic-0-init_agent.ipynb +++ b/MyIA.AI.Notebooks/SymbolicAI/Argument_Analysis/Argument_Analysis_Agentic-0-init_agent.ipynb @@ -6,16 +6,16 @@ "id": "34e4559f", "metadata": { "execution": { - "iopub.execute_input": "2026-09-15T08:27:28.369252Z", - "iopub.status.busy": "2026-09-15T08:27:28.369063Z", - "iopub.status.idle": "2026-09-15T08:27:28.373310Z", - "shell.execute_reply": "2026-09-15T08:27:28.372381Z" + "iopub.execute_input": "2026-09-15T08:46:37.944510Z", + "iopub.status.busy": "2026-09-15T08:46:37.943483Z", + "iopub.status.idle": "2026-09-15T08:46:37.951521Z", + "shell.execute_reply": "2026-09-15T08:46:37.950986Z" }, "papermill": { - "duration": 0.01361, - "end_time": "2026-09-15T08:27:28.374644", + "duration": 0.02779, + "end_time": "2026-09-15T08:46:37.952422", "exception": false, - "start_time": "2026-09-15T08:27:28.361034", + "start_time": "2026-09-15T08:46:37.924632", "status": "completed" }, "tags": [] @@ -31,10 +31,10 @@ "id": "6196daf0", "metadata": { "papermill": { - "duration": 0.011329, - "end_time": "2026-09-15T08:27:28.395918", + "duration": 0.006352, + "end_time": "2026-09-15T08:46:37.964998", "exception": false, - "start_time": "2026-09-15T08:27:28.384589", + "start_time": "2026-09-15T08:46:37.958646", "status": "completed" }, "tags": [] @@ -68,10 +68,10 @@ "id": "80571e1e", "metadata": { "papermill": { - "duration": 0.006652, - "end_time": "2026-09-15T08:27:28.411991", + "duration": 0.005725, + "end_time": "2026-09-15T08:46:37.976199", "exception": false, - "start_time": "2026-09-15T08:27:28.405339", + "start_time": "2026-09-15T08:46:37.970474", "status": "completed" }, "tags": [] @@ -92,16 +92,16 @@ "id": "a3661e07", "metadata": { "execution": { - "iopub.execute_input": "2026-09-15T08:27:28.430300Z", - "iopub.status.busy": "2026-09-15T08:27:28.429966Z", - "iopub.status.idle": "2026-09-15T08:27:30.638389Z", - "shell.execute_reply": "2026-09-15T08:27:30.637851Z" + "iopub.execute_input": "2026-09-15T08:46:37.990704Z", + "iopub.status.busy": "2026-09-15T08:46:37.990478Z", + "iopub.status.idle": "2026-09-15T08:46:40.118714Z", + "shell.execute_reply": "2026-09-15T08:46:40.118220Z" }, "papermill": { - "duration": 2.220173, - "end_time": "2026-09-15T08:27:30.639163", + "duration": 2.137557, + "end_time": "2026-09-15T08:46:40.119502", "exception": false, - "start_time": "2026-09-15T08:27:28.418990", + "start_time": "2026-09-15T08:46:37.981945", "status": "completed" }, "tags": [] @@ -174,10 +174,10 @@ "id": "pmpm31xh56", "metadata": { "papermill": { - "duration": 0.007204, - "end_time": "2026-09-15T08:27:30.654878", + "duration": 0.006854, + "end_time": "2026-09-15T08:46:40.133527", "exception": false, - "start_time": "2026-09-15T08:27:30.647674", + "start_time": "2026-09-15T08:46:40.126673", "status": "completed" }, "tags": [] @@ -200,16 +200,16 @@ "id": "dd1eb173", "metadata": { "execution": { - "iopub.execute_input": "2026-09-15T08:27:30.670743Z", - "iopub.status.busy": "2026-09-15T08:27:30.670416Z", - "iopub.status.idle": "2026-09-15T08:27:31.031075Z", - "shell.execute_reply": "2026-09-15T08:27:31.030663Z" + "iopub.execute_input": "2026-09-15T08:46:40.148397Z", + "iopub.status.busy": "2026-09-15T08:46:40.147971Z", + "iopub.status.idle": "2026-09-15T08:46:40.498041Z", + "shell.execute_reply": "2026-09-15T08:46:40.497556Z" }, "papermill": { - "duration": 0.369778, - "end_time": "2026-09-15T08:27:31.032034", + "duration": 0.358422, + "end_time": "2026-09-15T08:46:40.498781", "exception": false, - "start_time": "2026-09-15T08:27:30.662256", + "start_time": "2026-09-15T08:46:40.140359", "status": "completed" }, "tags": [] @@ -219,49 +219,49 @@ "name": "stderr", "output_type": "stream", "text": [ - "10:27:30 [INFO] [Orchestration.Setup] --- Vérification des dépendances ---\n" + "10:46:40 [INFO] [Orchestration.Setup] --- Vérification des dépendances ---\n" ] }, { "name": "stderr", "output_type": "stream", "text": [ - "10:27:30 [INFO] [Orchestration.Setup] ✔️ Dépendance 'jpype' trouvée.\n" + "10:46:40 [INFO] [Orchestration.Setup] ✔️ Dépendance 'jpype' trouvée.\n" ] }, { "name": "stderr", "output_type": "stream", "text": [ - "10:27:30 [INFO] [Orchestration.Setup] ✔️ Dépendance 'semantic_kernel' trouvée.\n" + "10:46:40 [INFO] [Orchestration.Setup] ✔️ Dépendance 'semantic_kernel' trouvée.\n" ] }, { "name": "stderr", "output_type": "stream", "text": [ - "10:27:30 [INFO] [Orchestration.Setup] ✔️ Dépendance 'dotenv' trouvée.\n" + "10:46:40 [INFO] [Orchestration.Setup] ✔️ Dépendance 'dotenv' trouvée.\n" ] }, { "name": "stderr", "output_type": "stream", "text": [ - "10:27:30 [INFO] [Orchestration.Setup] ✔️ Dépendance 'pandas' trouvée.\n" + "10:46:40 [INFO] [Orchestration.Setup] ✔️ Dépendance 'pandas' trouvée.\n" ] }, { "name": "stderr", "output_type": "stream", "text": [ - "10:27:31 [INFO] [Orchestration.Setup] ✔️ Dépendance 'requests' trouvée.\n" + "10:46:40 [INFO] [Orchestration.Setup] ✔️ Dépendance 'requests' trouvée.\n" ] }, { "name": "stderr", "output_type": "stream", "text": [ - "10:27:31 [INFO] [Orchestration.Setup] \n", + "10:46:40 [INFO] [Orchestration.Setup] \n", "✅ Dépendances principales vérifiées.\n" ] }, @@ -269,35 +269,21 @@ "name": "stderr", "output_type": "stream", "text": [ - "10:27:31 [INFO] [Orchestration.Setup] --- Chargement Configuration LLM ---\n" + "10:46:40 [INFO] [Orchestration.Setup] --- Chargement Configuration LLM ---\n" ] }, { "name": "stderr", "output_type": "stream", "text": [ - "10:27:31 [ERROR] [Orchestration.Setup] ❌ Configuration Azure OpenAI incomplète dans .env (OPENAI_API_KEY, OPENAI_CHAT_MODEL_ID, OPENAI_ENDPOINT requis).\n" + "10:46:40 [INFO] [Orchestration.Setup] ✅ Configuration OpenAI standard détectée (Modèle: gpt-5-mini). Org ID: Non fourni.\n" ] }, { "name": "stderr", "output_type": "stream", "text": [ - "10:27:31 [WARNING] [Orchestration.Setup] Configuration LLM incomplete. Verifiez votre fichier .env (OPENAI_API_KEY, OPENAI_CHAT_MODEL_ID).\n" - ] - }, - { - "name": "stderr", - "output_type": "stream", - "text": [ - "10:27:31 [WARNING] [Orchestration.Setup] Les cellules utilisant le service LLM fonctionneront en mode degrade.\n" - ] - }, - { - "name": "stderr", - "output_type": "stream", - "text": [ - "10:27:31 [INFO] [Orchestration.Setup] --- Fin Configuration Initiale ---\n" + "10:46:40 [INFO] [Orchestration.Setup] --- Fin Configuration Initiale ---\n" ] } ], @@ -434,10 +420,10 @@ "id": "c689b59e", "metadata": { "papermill": { - "duration": 0.009955, - "end_time": "2026-09-15T08:27:31.051307", + "duration": 0.011293, + "end_time": "2026-09-15T08:46:40.518923", "exception": false, - "start_time": "2026-09-15T08:27:31.041352", + "start_time": "2026-09-15T08:46:40.507630", "status": "completed" }, "tags": [] @@ -454,16 +440,16 @@ "id": "ab60fc96", "metadata": { "execution": { - "iopub.execute_input": "2026-09-15T08:27:31.074180Z", - "iopub.status.busy": "2026-09-15T08:27:31.073758Z", - "iopub.status.idle": "2026-09-15T08:27:31.080298Z", - "shell.execute_reply": "2026-09-15T08:27:31.079251Z" + "iopub.execute_input": "2026-09-15T08:46:40.538726Z", + "iopub.status.busy": "2026-09-15T08:46:40.538209Z", + "iopub.status.idle": "2026-09-15T08:46:40.544386Z", + "shell.execute_reply": "2026-09-15T08:46:40.543891Z" }, "papermill": { - "duration": 0.020888, - "end_time": "2026-09-15T08:27:31.081496", + "duration": 0.017084, + "end_time": "2026-09-15T08:46:40.545213", "exception": false, - "start_time": "2026-09-15T08:27:31.060608", + "start_time": "2026-09-15T08:46:40.528129", "status": "completed" }, "tags": [] @@ -473,14 +459,14 @@ "name": "stderr", "output_type": "stream", "text": [ - "10:27:31 [WARNING] [Orchestration.Config] ⚠️ Configuration Azure OpenAI incomplète dans .env (OPENAI_API_KEY, OPENAI_CHAT_MODEL_ID, OPENAI_ENDPOINT requis).\n" + "10:46:40 [INFO] [Orchestration.Config] ✅ Configuration OpenAI standard chargée (Modèle: gpt-5-mini). Org ID: Non fourni.\n" ] }, { "name": "stdout", "output_type": "stream", "text": [ - "⚠️ Configuration Azure OpenAI incomplète dans .env (OPENAI_API_KEY, OPENAI_CHAT_MODEL_ID, OPENAI_ENDPOINT requis).\n" + "✅ Configuration OpenAI standard chargée (Modèle: gpt-5-mini). Org ID: Non fourni.\n" ] } ], @@ -537,10 +523,10 @@ "id": "s3yp5wc2bg", "metadata": { "papermill": { - "duration": 0.010063, - "end_time": "2026-09-15T08:27:31.101433", + "duration": 0.009656, + "end_time": "2026-09-15T08:46:40.564727", "exception": false, - "start_time": "2026-09-15T08:27:31.091370", + "start_time": "2026-09-15T08:46:40.555071", "status": "completed" }, "tags": [] @@ -571,10 +557,10 @@ "id": "478a85e7", "metadata": { "papermill": { - "duration": 0.009887, - "end_time": "2026-09-15T08:27:31.121651", + "duration": 0.010332, + "end_time": "2026-09-15T08:46:40.584570", "exception": false, - "start_time": "2026-09-15T08:27:31.111764", + "start_time": "2026-09-15T08:46:40.574238", "status": "completed" }, "tags": [] @@ -602,10 +588,10 @@ "id": "a59062ad", "metadata": { "papermill": { - "duration": 0.009528, - "end_time": "2026-09-15T08:27:31.140894", + "duration": 0.009183, + "end_time": "2026-09-15T08:46:40.603180", "exception": false, - "start_time": "2026-09-15T08:27:31.131366", + "start_time": "2026-09-15T08:46:40.593997", "status": "completed" }, "tags": [] @@ -647,16 +633,16 @@ "id": "cc5a8f2e", "metadata": { "execution": { - "iopub.execute_input": "2026-09-15T08:27:31.162453Z", - "iopub.status.busy": "2026-09-15T08:27:31.162110Z", - "iopub.status.idle": "2026-09-15T08:27:31.476728Z", - "shell.execute_reply": "2026-09-15T08:27:31.476164Z" + "iopub.execute_input": "2026-09-15T08:46:40.621531Z", + "iopub.status.busy": "2026-09-15T08:46:40.621329Z", + "iopub.status.idle": "2026-09-15T08:47:18.654272Z", + "shell.execute_reply": "2026-09-15T08:47:18.653810Z" }, "papermill": { - "duration": 0.325824, - "end_time": "2026-09-15T08:27:31.477457", + "duration": 38.04329, + "end_time": "2026-09-15T08:47:18.655012", "exception": false, - "start_time": "2026-09-15T08:27:31.151633", + "start_time": "2026-09-15T08:46:40.611722", "status": "completed" }, "tags": [] @@ -666,7 +652,7 @@ "name": "stderr", "output_type": "stream", "text": [ - "10:27:31 [INFO] [Orchestration.JPype] \n", + "10:46:40 [INFO] [Orchestration.JPype] \n", "--- Configuration Auto-Suffisante de la JVM (Option B - Embarquée) ---\n" ] }, @@ -674,119 +660,126 @@ "name": "stderr", "output_type": "stream", "text": [ - "10:27:31 [INFO] [Orchestration.JPype] 🔍 Recherche JDK portable dans l'arborescence projet...\n" + "10:46:40 [INFO] [Orchestration.JPype] 🔍 Recherche JDK portable dans l'arborescence projet...\n" + ] + }, + { + "name": "stderr", + "output_type": "stream", + "text": [ + "10:46:40 [INFO] [Orchestration.JPype] ✅ JDK portable trouvé: MyIA.AI.Notebooks\\SymbolicAI\\Tweety\\jdk-17-portable\\zulu17.50.19-ca-jdk17.0.11-win_x64\n" ] }, { "name": "stderr", "output_type": "stream", "text": [ - "10:27:31 [INFO] [Orchestration.JPype] ✅ JDK portable trouvé: D:\\Dev\\CoursIA-16264\\MyIA.AI.Notebooks\\SymbolicAI\\Tweety\\jdk-17-portable\\zulu17.50.19-ca-jdk17.0.11-win_x64\n" + "10:46:40 [INFO] [Orchestration.JPype] 🏠 JAVA_HOME configuré dynamiquement: MyIA.AI.Notebooks\\SymbolicAI\\Tweety\\jdk-17-portable\\zulu17.50.19-ca-jdk17.0.11-win_x64\n" ] }, { "name": "stderr", "output_type": "stream", "text": [ - "10:27:31 [INFO] [Orchestration.JPype] 🏠 JAVA_HOME configuré dynamiquement: D:\\Dev\\CoursIA-16264\\MyIA.AI.Notebooks\\SymbolicAI\\Tweety\\jdk-17-portable\\zulu17.50.19-ca-jdk17.0.11-win_x64\n" + "10:46:40 [INFO] [Orchestration.JPype] 📦 Construction du classpath Tweety...\n" ] }, { "name": "stderr", "output_type": "stream", "text": [ - "10:27:31 [INFO] [Orchestration.JPype] 📦 Construction du classpath Tweety...\n" + "10:46:40 [INFO] [Orchestration.JPype] Aucun JAR Tweety dans MyIA.AI.Notebooks\\SymbolicAI\\Tweety\\libs -- bootstrap via download_tweety_tools.py\n" ] }, { "name": "stderr", "output_type": "stream", "text": [ - "10:27:31 [INFO] [Orchestration.JPype] Scan des JARs dans: D:\\Dev\\CoursIA-16264\\MyIA.AI.Notebooks\\SymbolicAI\\Tweety\\libs\n" + "10:47:13 [INFO] [Orchestration.JPype] Scan des JARs dans: MyIA.AI.Notebooks\\SymbolicAI\\Tweety\\libs\n" ] }, { "name": "stderr", "output_type": "stream", "text": [ - "10:27:31 [INFO] [Orchestration.JPype] ✅ 42 JARs trouvés dans D:\\Dev\\CoursIA-16264\\MyIA.AI.Notebooks\\SymbolicAI\\Tweety\\libs\n" + "10:47:13 [INFO] [Orchestration.JPype] ✅ 42 JARs trouvés dans MyIA.AI.Notebooks\\SymbolicAI\\Tweety\\libs\n" ] }, { "name": "stderr", "output_type": "stream", "text": [ - "10:27:31 [INFO] [Orchestration.JPype] ✅ Classpath construit: 42 JARs Tweety\n" + "10:47:13 [INFO] [Orchestration.JPype] ✅ Classpath construit: 42 JARs Tweety\n" ] }, { "name": "stderr", "output_type": "stream", "text": [ - "10:27:31 [INFO] [Orchestration.JPype] 🚀 Démarrage JVM avec 42 JARs Tweety...\n" + "10:47:13 [INFO] [Orchestration.JPype] 🚀 Démarrage JVM avec 42 JARs Tweety...\n" ] }, { "name": "stderr", "output_type": "stream", "text": [ - "10:27:31 [INFO] [Orchestration.JPype] ✅ JVM démarrée avec succès et domaines enregistrés\n" + "10:47:18 [INFO] [Orchestration.JPype] ✅ JVM démarrée avec succès et domaines enregistrés\n" ] }, { "name": "stderr", "output_type": "stream", "text": [ - "10:27:31 [INFO] [Orchestration.JPype] ☕ Java 17.0.11 opérationnel\n" + "10:47:18 [INFO] [Orchestration.JPype] ☕ Java 17.0.11 opérationnel\n" ] }, { "name": "stderr", "output_type": "stream", "text": [ - "10:27:31 [INFO] [Orchestration.JPype] 🎯 Test des classes critiques Tweety...\n" + "10:47:18 [INFO] [Orchestration.JPype] 🎯 Test des classes critiques Tweety...\n" ] }, { "name": "stderr", "output_type": "stream", "text": [ - "10:27:31 [INFO] [Orchestration.JPype] ✅ InformationObject: Accessible\n" + "10:47:18 [INFO] [Orchestration.JPype] ✅ InformationObject: Accessible\n" ] }, { "name": "stderr", "output_type": "stream", "text": [ - "10:27:31 [INFO] [Orchestration.JPype] ✅ PlParser: Accessible\n" + "10:47:18 [INFO] [Orchestration.JPype] ✅ PlParser: Accessible\n" ] }, { "name": "stderr", "output_type": "stream", "text": [ - "10:27:31 [INFO] [Orchestration.JPype] ✅ PlFormula: Accessible\n" + "10:47:18 [INFO] [Orchestration.JPype] ✅ PlFormula: Accessible\n" ] }, { "name": "stderr", "output_type": "stream", "text": [ - "10:27:31 [INFO] [Orchestration.JPype] ✅ BaseRevisionOperator: Accessible\n" + "10:47:18 [INFO] [Orchestration.JPype] ✅ BaseRevisionOperator: Accessible\n" ] }, { "name": "stderr", "output_type": "stream", "text": [ - "10:27:31 [INFO] [Orchestration.JPype] 🏆 Test Tweety RÉUSSI: 4/4 classes accessibles\n" + "10:47:18 [INFO] [Orchestration.JPype] 🏆 Test Tweety RÉUSSI: 4/4 classes accessibles\n" ] }, { "name": "stderr", "output_type": "stream", "text": [ - "10:27:31 [INFO] [Orchestration.JPype] \n", + "10:47:18 [INFO] [Orchestration.JPype] \n", "🎉 🏆 SUCCÈS TOTAL - INFRASTRUCTURE TWEETY AUTO-SUFFISANTE! 🏆 🎉\n" ] }, @@ -794,21 +787,21 @@ "name": "stderr", "output_type": "stream", "text": [ - "10:27:31 [INFO] [Orchestration.JPype] ✅ PropositionalLogicAgent prêt pour exécution native\n" + "10:47:18 [INFO] [Orchestration.JPype] ✅ PropositionalLogicAgent prêt pour exécution native\n" ] }, { "name": "stderr", "output_type": "stream", "text": [ - "10:27:31 [INFO] [Orchestration.JPype] ✅ Pipeline argumentatif avec intégration formelle/informelle opérationnel\n" + "10:47:18 [INFO] [Orchestration.JPype] ✅ Pipeline argumentatif avec intégration formelle/informelle opérationnel\n" ] }, { "name": "stderr", "output_type": "stream", "text": [ - "10:27:31 [INFO] [Orchestration.JPype] \n", + "10:47:18 [INFO] [Orchestration.JPype] \n", "🟢 STATUT FINAL: JVM + Tweety OPÉRATIONNELS\n" ] }, @@ -816,21 +809,21 @@ "name": "stderr", "output_type": "stream", "text": [ - "10:27:31 [INFO] [Orchestration.JPype] Pipeline peut atteindre son potentiel maximal (8/10)\n" + "10:47:18 [INFO] [Orchestration.JPype] Pipeline peut atteindre son potentiel maximal (8/10)\n" ] }, { "name": "stderr", "output_type": "stream", "text": [ - "10:27:31 [INFO] [Orchestration.JPype] --- Fin Configuration JPype Auto-Suffisante ---\n" + "10:47:18 [INFO] [Orchestration.JPype] --- Fin Configuration JPype Auto-Suffisante ---\n" ] }, { "name": "stderr", "output_type": "stream", "text": [ - "10:27:31 [INFO] [Orchestration.JPype] ✅ Tweety opérationnel - PropositionalLogicAgent en mode natif\n" + "10:47:18 [INFO] [Orchestration.JPype] ✅ Tweety opérationnel - PropositionalLogicAgent en mode natif\n" ] } ], @@ -875,6 +868,31 @@ "TWEETY_LIBS_DIR = \"libs\"\n", "TWEETY_JDK_DIR = \"jdk-17-portable\"\n", "\n", + "# --- Affichage des chemins : jamais l'absolu (#16264) ---\n", + "# Un chemin absolu dans une sortie de cellule divulgue la topologie de la machine\n", + "# d'execution (secrets-hygiene rule 6) et fait rougir le ratchet Output-failure\n", + "# (MACHINE_PATH). Ces logs impriment l'absolu depuis toujours ; ils etaient\n", + "# simplement inatteignables tant que la cellule ne trouvait ni JDK ni JARs. On\n", + "# corrige la SOURCE plutot que de nettoyer la sortie : un chemin relatif ne se\n", + "# regenere pas au run suivant, alors qu'une retouche de sortie serait refaite a\n", + "# chaque execution.\n", + "try:\n", + " _REPO_ROOT = SYMBOLIC_AI_DIR.parent.parent\n", + "except NameError: # repli ImportError ci-dessus : chemins deja relatifs au cwd\n", + " _REPO_ROOT = pathlib.Path(\".\")\n", + "\n", + "\n", + "def display_path(path) -> str:\n", + " \"\"\"Rend un chemin affichable : relatif a la racine du depot, jamais absolu.\"\"\"\n", + " if not path:\n", + " return \"(non defini)\"\n", + " p = pathlib.Path(path)\n", + " try:\n", + " return str(p.relative_to(_REPO_ROOT))\n", + " except ValueError:\n", + " # Hors depot : le nom seul, jamais l'absolu.\n", + " return p.name if p.is_absolute() else str(p)\n", + "\n", "\n", "def ensure_tweety_jars(jars_dir: pathlib.Path) -> bool:\n", " \"\"\"Installe les JARs Tweety manquants via l'outil canonique (idempotent).\n", @@ -889,10 +907,11 @@ "\n", " downloader = TWEETY_DIR / \"scripts\" / \"download_tweety_tools.py\"\n", " if not downloader.exists():\n", - " logger.error(\"Bootstrap JARs impossible: %s introuvable\", downloader)\n", + " logger.error(\"Bootstrap JARs impossible: %s introuvable\", display_path(downloader))\n", " return False\n", "\n", - " logger.info(\"Aucun JAR Tweety dans %s -- bootstrap via %s\", jars_dir, downloader.name)\n", + " logger.info(\"Aucun JAR Tweety dans %s -- bootstrap via %s\",\n", + " display_path(jars_dir), downloader.name)\n", " try:\n", " proc = subprocess.run(\n", " [sys.executable, str(downloader), \"--jars\",\n", @@ -929,7 +948,7 @@ " \n", " for base_path in search_paths:\n", " if base_path.exists():\n", - " logger.debug(f\" Scan du répertoire: {base_path}\")\n", + " logger.debug(f\" Scan du répertoire: {display_path(base_path)}\")\n", " \n", " # Chercher des sous-dossiers JDK\n", " jdk_patterns = [\"*jdk*\", \"zulu*\", \"*openjdk*\", \"*corretto*\"]\n", @@ -941,7 +960,7 @@ " exe_suffix = \".exe\" if platform.system() == \"Windows\" else \"\"\n", " java_exe = jdk_dir / \"bin\" / f\"java{exe_suffix}\"\n", " if java_exe.exists():\n", - " logger.info(f\"✅ JDK portable trouvé: {jdk_dir.absolute()}\")\n", + " logger.info(f\"✅ JDK portable trouvé: {display_path(jdk_dir)}\")\n", " return str(jdk_dir.absolute())\n", " \n", " logger.warning(\"⚠️ JDK portable non trouvé dans les chemins standards\")\n", @@ -970,11 +989,11 @@ " \n", " for libs_path in libs_paths:\n", " if libs_path.exists() and libs_path.is_dir():\n", - " logger.info(f\" Scan des JARs dans: {libs_path}\")\n", + " logger.info(f\" Scan des JARs dans: {display_path(libs_path)}\")\n", " found_jars = list(libs_path.glob(\"*.jar\"))\n", " if found_jars:\n", " jar_files.extend([str(jar.absolute()) for jar in found_jars])\n", - " logger.info(f\" ✅ {len(found_jars)} JARs trouvés dans {libs_path}\")\n", + " logger.info(f\" ✅ {len(found_jars)} JARs trouvés dans {display_path(libs_path)}\")\n", " break # Utiliser le premier répertoire avec des JARs\n", " \n", " if jar_files:\n", @@ -1043,13 +1062,14 @@ " current_java_home = os.getenv('JAVA_HOME')\n", " if not current_java_home or current_java_home != portable_jdk:\n", " os.environ['JAVA_HOME'] = portable_jdk\n", - " logger.info(f\"🏠 JAVA_HOME configuré dynamiquement: {portable_jdk}\")\n", + " logger.info(f\"🏠 JAVA_HOME configuré dynamiquement: {display_path(portable_jdk)}\")\n", " else:\n", - " logger.info(f\"🏠 JAVA_HOME déjà configuré: {current_java_home}\")\n", + " logger.info(f\"🏠 JAVA_HOME déjà configuré: {display_path(current_java_home)}\")\n", " else:\n", " logger.error(\"❌ Impossible de localiser un JDK portable - JVM pourrait échouer\")\n", " logger.error(\" Attendu: %s (download_tweety_tools.py --jdk) -- JAVA_HOME courant: %s\",\n", - " TWEETY_DIR / TWEETY_JDK_DIR, os.getenv('JAVA_HOME'))\n", + " display_path(TWEETY_DIR / TWEETY_JDK_DIR),\n", + " display_path(os.getenv('JAVA_HOME')))\n", " \n", " # Étape 3: Construire le classpath Tweety complet\n", " tweety_jars = get_tweety_classpath()\n", @@ -1083,7 +1103,8 @@ " else:\n", " logger.error(\"❌ Classpath Tweety vide après bootstrap -- JVM non démarrée\")\n", " logger.error(\" Attendu: %s (JARs TweetyProject, outil canonique \"\n", - " \"download_tweety_tools.py --jars)\", TWEETY_DIR / TWEETY_LIBS_DIR)\n", + " \"download_tweety_tools.py --jars)\",\n", + " display_path(TWEETY_DIR / TWEETY_LIBS_DIR))\n", " \n", " # Étape 6: Test de validation Tweety\n", " if jvm_ready:\n", @@ -1170,10 +1191,10 @@ "id": "7hq2u546fkr", "metadata": { "papermill": { - "duration": 0.009828, - "end_time": "2026-09-15T08:27:31.497484", + "duration": 0.010261, + "end_time": "2026-09-15T08:47:18.674730", "exception": false, - "start_time": "2026-09-15T08:27:31.487656", + "start_time": "2026-09-15T08:47:18.664469", "status": "completed" }, "tags": [] @@ -1210,10 +1231,10 @@ "id": "d201514e", "metadata": { "papermill": { - "duration": 0.009425, - "end_time": "2026-09-15T08:27:31.516508", + "duration": 0.009922, + "end_time": "2026-09-15T08:47:18.694436", "exception": false, - "start_time": "2026-09-15T08:27:31.507083", + "start_time": "2026-09-15T08:47:18.684514", "status": "completed" }, "tags": [] @@ -1233,10 +1254,10 @@ "id": "a13a208e", "metadata": { "papermill": { - "duration": 0.009719, - "end_time": "2026-09-15T08:27:31.536643", + "duration": 0.009549, + "end_time": "2026-09-15T08:47:18.713748", "exception": false, - "start_time": "2026-09-15T08:27:31.526924", + "start_time": "2026-09-15T08:47:18.704199", "status": "completed" }, "tags": [] @@ -1287,16 +1308,16 @@ "id": "a303fa9c", "metadata": { "execution": { - "iopub.execute_input": "2026-09-15T08:27:31.557291Z", - "iopub.status.busy": "2026-09-15T08:27:31.557099Z", - "iopub.status.idle": "2026-09-15T08:27:31.560397Z", - "shell.execute_reply": "2026-09-15T08:27:31.560032Z" + "iopub.execute_input": "2026-09-15T08:47:18.734213Z", + "iopub.status.busy": "2026-09-15T08:47:18.734004Z", + "iopub.status.idle": "2026-09-15T08:47:18.737796Z", + "shell.execute_reply": "2026-09-15T08:47:18.737368Z" }, "papermill": { - "duration": 0.014933, - "end_time": "2026-09-15T08:27:31.561008", + "duration": 0.014673, + "end_time": "2026-09-15T08:47:18.738513", "exception": false, - "start_time": "2026-09-15T08:27:31.546075", + "start_time": "2026-09-15T08:47:18.723840", "status": "completed" }, "tags": [] @@ -1306,7 +1327,7 @@ "name": "stderr", "output_type": "stream", "text": [ - "10:27:31 [INFO] [root] Classe RhetoricalAnalysisState définie (via argumentation_lib shim, Phase 2 #2137).\n" + "10:47:18 [INFO] [root] Classe RhetoricalAnalysisState définie (via argumentation_lib shim, Phase 2 #2137).\n" ] } ], @@ -1338,10 +1359,10 @@ "id": "0d4166a2", "metadata": { "papermill": { - "duration": 0.011009, - "end_time": "2026-09-15T08:27:31.581850", + "duration": 0.009903, + "end_time": "2026-09-15T08:47:18.757940", "exception": false, - "start_time": "2026-09-15T08:27:31.570841", + "start_time": "2026-09-15T08:47:18.748037", "status": "completed" }, "tags": [] @@ -1396,16 +1417,16 @@ "id": "61903410", "metadata": { "execution": { - "iopub.execute_input": "2026-09-15T08:27:31.604965Z", - "iopub.status.busy": "2026-09-15T08:27:31.604748Z", - "iopub.status.idle": "2026-09-15T08:27:31.610574Z", - "shell.execute_reply": "2026-09-15T08:27:31.610063Z" + "iopub.execute_input": "2026-09-15T08:47:18.777268Z", + "iopub.status.busy": "2026-09-15T08:47:18.777062Z", + "iopub.status.idle": "2026-09-15T08:47:18.782966Z", + "shell.execute_reply": "2026-09-15T08:47:18.782475Z" }, "papermill": { - "duration": 0.01885, - "end_time": "2026-09-15T08:27:31.611468", + "duration": 0.016534, + "end_time": "2026-09-15T08:47:18.783719", "exception": false, - "start_time": "2026-09-15T08:27:31.592618", + "start_time": "2026-09-15T08:47:18.767185", "status": "completed" }, "tags": [] @@ -1415,7 +1436,7 @@ "name": "stderr", "output_type": "stream", "text": [ - "10:27:31 [INFO] [root] Classe StateManagerPlugin définie (via argumentation_lib shim, Phase 2 #2137).\n" + "10:47:18 [INFO] [root] Classe StateManagerPlugin définie (via argumentation_lib shim, Phase 2 #2137).\n" ] } ], @@ -1449,10 +1470,10 @@ "id": "a754dbe1", "metadata": { "papermill": { - "duration": 0.010489, - "end_time": "2026-09-15T08:27:31.632914", + "duration": 0.009493, + "end_time": "2026-09-15T08:47:18.802785", "exception": false, - "start_time": "2026-09-15T08:27:31.622425", + "start_time": "2026-09-15T08:47:18.793292", "status": "completed" }, "tags": [] @@ -1496,16 +1517,16 @@ "id": "95c09e20", "metadata": { "execution": { - "iopub.execute_input": "2026-09-15T08:27:31.656463Z", - "iopub.status.busy": "2026-09-15T08:27:31.656012Z", - "iopub.status.idle": "2026-09-15T08:27:31.664855Z", - "shell.execute_reply": "2026-09-15T08:27:31.664447Z" + "iopub.execute_input": "2026-09-15T08:47:18.822893Z", + "iopub.status.busy": "2026-09-15T08:47:18.822564Z", + "iopub.status.idle": "2026-09-15T08:47:19.489061Z", + "shell.execute_reply": "2026-09-15T08:47:19.488413Z" }, "papermill": { - "duration": 0.020692, - "end_time": "2026-09-15T08:27:31.665509", + "duration": 0.677983, + "end_time": "2026-09-15T08:47:19.490036", "exception": false, - "start_time": "2026-09-15T08:27:31.644817", + "start_time": "2026-09-15T08:47:18.812053", "status": "completed" }, "tags": [] @@ -1515,42 +1536,28 @@ "name": "stderr", "output_type": "stream", "text": [ - "10:27:31 [INFO] [Orchestration.LLM] --- Configuration du Service LLM Global ---\n" - ] - }, - { - "name": "stderr", - "output_type": "stream", - "text": [ - "10:27:31 [INFO] [Orchestration.LLM] Configuration Service Global: AzureChatCompletion...\n" - ] - }, - { - "name": "stderr", - "output_type": "stream", - "text": [ - "10:27:31 [WARNING] [Orchestration.LLM] Service LLM global non configure: chat_deployment_name is required.\n" + "10:47:18 [INFO] [Orchestration.LLM] --- Configuration du Service LLM Global ---\n" ] }, { "name": "stderr", "output_type": "stream", "text": [ - "10:27:31 [WARNING] [Orchestration.LLM] Les fonctionnalites dependent du service LLM seront en mode degrade.\n" + "10:47:18 [INFO] [Orchestration.LLM] Configuration Service Global: OpenAIChatCompletion...\n" ] }, { "name": "stderr", "output_type": "stream", "text": [ - "10:27:31 [WARNING] [Orchestration.LLM] Service LLM global non disponible (None). Mode degrade active.\n" + "10:47:19 [INFO] [Orchestration.LLM] Service LLM global OpenAI (gpt-5-mini) créé.\n" ] }, { "name": "stderr", "output_type": "stream", "text": [ - "10:27:31 [INFO] [root] --- Fin Définitions Composants Partagés ---\n" + "10:47:19 [INFO] [root] --- Fin Définitions Composants Partagés ---\n" ] } ], @@ -1612,10 +1619,10 @@ "id": "76c485ec", "metadata": { "papermill": { - "duration": 0.009624, - "end_time": "2026-09-15T08:27:31.685251", + "duration": 0.009363, + "end_time": "2026-09-15T08:47:19.509430", "exception": false, - "start_time": "2026-09-15T08:27:31.675627", + "start_time": "2026-09-15T08:47:19.500067", "status": "completed" }, "tags": [] @@ -1644,10 +1651,10 @@ "id": "f7a615c6", "metadata": { "papermill": { - "duration": 0.009559, - "end_time": "2026-09-15T08:27:31.704821", + "duration": 0.010433, + "end_time": "2026-09-15T08:47:19.529974", "exception": false, - "start_time": "2026-09-15T08:27:31.695262", + "start_time": "2026-09-15T08:47:19.519541", "status": "completed" }, "tags": [] @@ -1699,16 +1706,16 @@ "id": "8bafcee0", "metadata": { "execution": { - "iopub.execute_input": "2026-09-15T08:27:31.726523Z", - "iopub.status.busy": "2026-09-15T08:27:31.726137Z", - "iopub.status.idle": "2026-09-15T08:27:31.731544Z", - "shell.execute_reply": "2026-09-15T08:27:31.731096Z" + "iopub.execute_input": "2026-09-15T08:47:19.551198Z", + "iopub.status.busy": "2026-09-15T08:47:19.550821Z", + "iopub.status.idle": "2026-09-15T08:47:19.556984Z", + "shell.execute_reply": "2026-09-15T08:47:19.556140Z" }, "papermill": { - "duration": 0.017476, - "end_time": "2026-09-15T08:27:31.732205", + "duration": 0.018587, + "end_time": "2026-09-15T08:47:19.558033", "exception": false, - "start_time": "2026-09-15T08:27:31.714729", + "start_time": "2026-09-15T08:47:19.539446", "status": "completed" }, "tags": [] @@ -1718,7 +1725,7 @@ "name": "stderr", "output_type": "stream", "text": [ - "10:27:31 [INFO] [Orchestration.AgentPM.Defs] Plugin PM (vide) et prompts semantiques (V17 - CODE-ONLY) definis.\n" + "10:47:19 [INFO] [Orchestration.AgentPM.Defs] Plugin PM (vide) et prompts semantiques (V17 - CODE-ONLY) definis.\n" ] } ], @@ -1829,10 +1836,10 @@ "id": "036e58ad", "metadata": { "papermill": { - "duration": 0.010068, - "end_time": "2026-09-15T08:27:31.752594", + "duration": 0.010589, + "end_time": "2026-09-15T08:47:19.578262", "exception": false, - "start_time": "2026-09-15T08:27:31.742526", + "start_time": "2026-09-15T08:47:19.567673", "status": "completed" }, "tags": [] @@ -1872,16 +1879,16 @@ "id": "7a1a3c2e", "metadata": { "execution": { - "iopub.execute_input": "2026-09-15T08:27:31.775946Z", - "iopub.status.busy": "2026-09-15T08:27:31.775623Z", - "iopub.status.idle": "2026-09-15T08:27:31.783129Z", - "shell.execute_reply": "2026-09-15T08:27:31.782536Z" + "iopub.execute_input": "2026-09-15T08:47:19.599723Z", + "iopub.status.busy": "2026-09-15T08:47:19.599475Z", + "iopub.status.idle": "2026-09-15T08:47:19.607929Z", + "shell.execute_reply": "2026-09-15T08:47:19.607359Z" }, "papermill": { - "duration": 0.020461, - "end_time": "2026-09-15T08:27:31.783894", + "duration": 0.02051, + "end_time": "2026-09-15T08:47:19.608682", "exception": false, - "start_time": "2026-09-15T08:27:31.763433", + "start_time": "2026-09-15T08:47:19.588172", "status": "completed" }, "tags": [] @@ -2050,10 +2057,10 @@ "id": "1b9bb59a", "metadata": { "papermill": { - "duration": 0.012221, - "end_time": "2026-09-15T08:27:31.806626", + "duration": 0.009499, + "end_time": "2026-09-15T08:47:19.628096", "exception": false, - "start_time": "2026-09-15T08:27:31.794405", + "start_time": "2026-09-15T08:47:19.618597", "status": "completed" }, "tags": [] @@ -2099,16 +2106,16 @@ "id": "f2a524ce", "metadata": { "execution": { - "iopub.execute_input": "2026-09-15T08:27:31.828920Z", - "iopub.status.busy": "2026-09-15T08:27:31.827984Z", - "iopub.status.idle": "2026-09-15T08:27:31.832835Z", - "shell.execute_reply": "2026-09-15T08:27:31.832334Z" + "iopub.execute_input": "2026-09-15T08:47:19.648060Z", + "iopub.status.busy": "2026-09-15T08:47:19.647854Z", + "iopub.status.idle": "2026-09-15T08:47:19.651475Z", + "shell.execute_reply": "2026-09-15T08:47:19.650953Z" }, "papermill": { - "duration": 0.017139, - "end_time": "2026-09-15T08:27:31.834003", + "duration": 0.014567, + "end_time": "2026-09-15T08:47:19.652149", "exception": false, - "start_time": "2026-09-15T08:27:31.816864", + "start_time": "2026-09-15T08:47:19.637582", "status": "completed" }, "tags": [] @@ -2118,7 +2125,7 @@ "name": "stderr", "output_type": "stream", "text": [ - "10:27:31 [INFO] [Orchestration.AgentPM.Instructions] Instructions Systeme PM_INSTRUCTIONS (V15 - CODE-ONLY) definies.\n" + "10:47:19 [INFO] [Orchestration.AgentPM.Instructions] Instructions Systeme PM_INSTRUCTIONS (V15 - CODE-ONLY) definies.\n" ] } ], @@ -2170,10 +2177,10 @@ "id": "61dwms8dzi", "metadata": { "papermill": { - "duration": 0.00967, - "end_time": "2026-09-15T08:27:31.853592", + "duration": 0.009577, + "end_time": "2026-09-15T08:47:19.671667", "exception": false, - "start_time": "2026-09-15T08:27:31.843922", + "start_time": "2026-09-15T08:47:19.662090", "status": "completed" }, "tags": [] @@ -2261,14 +2268,14 @@ }, "papermill": { "default_parameters": {}, - "duration": 6.350624, - "end_time": "2026-09-15T08:27:32.975728", + "duration": 44.065052, + "end_time": "2026-09-15T08:47:20.252697", "environment_variables": {}, "exception": null, "input_path": "D:\\Dev\\CoursIA-16264\\MyIA.AI.Notebooks\\SymbolicAI\\Argument_Analysis\\Argument_Analysis_Agentic-0-init_agent.ipynb", "output_path": "D:\\Dev\\CoursIA-16264\\MyIA.AI.Notebooks\\SymbolicAI\\Argument_Analysis\\Argument_Analysis_Agentic-0-init_agent_output.ipynb", "parameters": {}, - "start_time": "2026-09-15T08:27:26.625104", + "start_time": "2026-09-15T08:46:36.187645", "version": "2.6.0" } },