Commit Graph

3 Commits

Author SHA1 Message Date
Jules Neny
be7fc09085 feat: PC7 chatbot V1 onglet centre HAUT + endpoint Astro proxy SSR
- ChatbotV2.vue : Vue island, thread chat (input + messages bot/user),
  persistance sessionStorage, bandeau beta '120 fiches AEP, RAG-PE bientot',
  gestion erreurs 429/502/504 ; pas de streaming ni markdown V1
- /api/chatbot.ts : endpoint Astro server proxy POST vers CHATBOT_UPSTREAM
  (default https://aep.trans-former.fr/api/chatbot), timeout 25s,
  body { question, history } -> upstream classique chatbot AEP Mistral Small
- astro.config.mjs : output 'server' + adapter @astrojs/node standalone
  (Astro 6 a supprime mode hybrid ; on opt-in prerender sur les pages)
- Toutes les pages publiques (index, manifeste, manifeste/commander,
  a-propos, mentions-legales) ont 'export const prerender = true'
- ColCentre.astro : remplace ChatbotPlaceholder par ChatbotV2 dans le tab
- .env.example : ajoute CHATBOT_UPSTREAM (V1.5 = switch LightRAG-PE 1 ligne)

Decision V1 : endpoint AEP /api/chatbot (classique, repond bien) au lieu
de /api/chatbot-v2 qui retourne v2_ready=false ('base vectorielle en cours').
Bandeau beta reste valide ; switch v2 quand ready cote AEP via env var.

Note PC8 deploy : Coolify doit booter avec 'node ./dist/server/entry.mjs'
(SSR Node standalone) au lieu de servir dist/client/ static.

Test end-to-end OK : SSR boot port 4399 + curl POST /api/chatbot ->
reponse_texte 800+ chars de l'AEP backend.
2026-05-09 01:22:01 +02:00
Jules Neny
32bdc9a2e5 feat: PC3 mindmap Carte O (D3 force-directed) + scrape AEP/Articles + tabs centre HAUT
- scripts/build-carte-o.js : scan recursif AEP/Articles/, parse YAML + legacy header, extract wikilinks, infer 5 famille
- src/components/vue/CarteO.vue : D3 v7 force-directed avec drag, zoom + pan, click handler, tooltips, ResizeObserver
- src/components/vue/CarteOModal.vue : modal recap intention avec Teleport, Esc + backdrop close, transitions
- src/components/vue/CarteOWrapper.vue : fetch /data/carte-o.json, etat selectionne, fallback mobile (msg + miniature SVG)
- src/components/astro/ColCentre.astro : tabs Carte O / Chatbot, panneaux ARIA
- package.json : prebuild + predev hooks, build:carte-o script
- public/data/carte-o.json : 84 nodes / 94 edges sur 21 themes, distribution familles equilibree

Drill-down V1 = zoom + pan seul (V2 recursif backlog).
Pattern adapte de nav-carte/components/codev/CodevGraph.vue (sans coupling Nuxt).
Build Astro 6.3.1 OK, bundle CarteOWrapper 69KB.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-09 00:59:23 +02:00
Jules Neny
aeaec6fc06 feat: PC1 scaffolding Astro 6 + Vue islands + Tailwind 4 + Embla swipe
Initial structure for page-cerveau:
- Astro 6.3.1 + @astrojs/vue 6.0.1 + Vue 3.5
- Tailwind 4 via @tailwindcss/vite (vs Tailwind 3.4 in prompt; @astrojs/tailwind incompatible with Astro 6 peer deps)
- Embla Carousel Vue for mobile swipe (3 strict positions)
- src/components/astro/ : 5 placeholder components (Col*, HamburgerMenu, PopupOnboarding)
- src/components/vue/ : SwipeContainer + 3 placeholder islands
- src/layouts/BaseLayout.astro
- src/pages/index.astro (3 cols desktop ; SwipeContainer mobile) + manifeste.astro placeholder
- public/data/ ready for PC3 (carte-o.json) + PC6 (journal.json)

Build OK (0 errors, 0 warnings); dev server tested localhost:4321 with all components rendering.

Note: Astro version is 6.3.1 (latest stable) instead of 5.x specified in prompt; 6.x is current LTS.
2026-05-08 19:44:22 +02:00