diff --git a/admin/ia/stt.md b/admin/ia/stt.md index a4df0eb..51c6355 100644 --- a/admin/ia/stt.md +++ b/admin/ia/stt.md @@ -111,7 +111,7 @@ Au démarrage (et périodiquement), `stt` ping s01 (`192.168.1.200`) : |---|---|---| | Commande `stt` | `stt/pyproject.toml` → entrypoint | `stt` (lance), `stt --setup` (install Whisper/Piper/voix), `stt --stop`, `stt --mode ` | | Backend | `stt/stt/` (package Python) | Extension de `tools/hermes-voice.py` : wake word, STT, TTS, routeur cerveau, mémoire, serveur websocket | -| HUD web | `stt/hud/` | Front statique (HTML/JS/canvas) : visualiseur animé, conversation, écran de réglages. Servi localement, ouvert en kiosk | +| HUD web | `stt/stt/hud/` | Front statique (HTML/JS/canvas) embarqué dans le package (livré par pipx) : visualiseur animé, conversation, écran de réglages. Servi localement, ouvert en kiosk | | Config | `stt/config/` | `stt.example.toml` + thèmes, avatars, voix Piper | | Mémoire | `stt/memory/` | `distilled/` versionné + raw local gitignoré | | Auto-start | `stt/install-service.sh` | `systemd --user` : backend + ouverture HUD au login | @@ -148,7 +148,7 @@ Pilotable depuis `stt/config/` + l'écran de réglages du HUD, sans recompiler : | **0 — Cadrage** | Conception validée | doc + squelette `stt/` | ✅ fait | | **1 — Commande + backend** | `stt`/`stt --setup` lancent le moteur vocal + websocket | `pyproject.toml`, `stt/` (cli, config, voice, server) | ✅ fait | | **2 — Routeur cerveau** | 3 modes + auto-détection LAN | module `brain` (hermes/local/claude) | ✅ fait | -| **3 — HUD** | Visualiseur + conversation | `stt/hud/index.html` (MVP) → visualiseur avancé | 🟡 MVP fait | +| **3 — HUD** | Visualiseur + conversation | `stt/stt/hud/index.html` (MVP) → visualiseur avancé | 🟡 MVP fait | | **4 — Mémoire 3 tiers** | local ✅ + GitHub + Qdrant | `memory` : SQLite ✅ ; distillation/sync git + Qdrant | 🟡 local fait | | **5 — Personnalisation** | Thèmes / avatar / voix / wake word | écran réglages + `stt/config/` | ⏳ | | **6 — Auto-start** | Démarre au boot du poste | `install-service.sh` + kiosk | ⏳ | diff --git a/stt/README.md b/stt/README.md index 1b8108b..cad363b 100644 --- a/stt/README.md +++ b/stt/README.md @@ -30,12 +30,14 @@ stt # lance le backend + ouvre le HUD ``` stt/ ├── pyproject.toml # définit la commande `stt` (entrypoint pipx) -├── stt/ # package Python — backend (à implémenter, phases 1-4) +├── stt/ # package Python — backend +│ ├── cli.py # entrypoint `stt` +│ ├── config.py # défauts + ~/.config/stt/stt.toml │ ├── voice/ # wake word, STT (faster-whisper), TTS (Piper) │ ├── brain/ # routeur 3 modes : hermes / local-direct / claude-direct -│ ├── memory/ # gestionnaire mémoire 3 tiers (local/s01/GitHub) -│ └── server/ # serveur websocket vers le HUD -├── hud/ # front web (HTML/JS/canvas) — phase 3 +│ ├── memory/ # mémoire 3 tiers (local SQLite ✅, s01/GitHub phase 4) +│ ├── server/ # HTTP statique (HUD) + websocket (états → HUD) +│ └── hud/ # front web embarqué dans le package (livré par pipx) ├── config/ # stt.example.toml + thèmes / avatars / voix ├── memory/ # distilled/ (versionné) + raw local (gitignoré) └── install-service.sh # systemd --user (démarrage auto) — phase 6 diff --git a/stt/pyproject.toml b/stt/pyproject.toml index ad8644e..98281ac 100644 --- a/stt/pyproject.toml +++ b/stt/pyproject.toml @@ -28,3 +28,7 @@ build-backend = "setuptools.build_meta" [tool.setuptools.packages.find] where = ["."] include = ["stt*"] + +# Le HUD (assets web) est livré comme données du package stt/ +[tool.setuptools.package-data] +stt = ["hud/*", "hud/**/*"] diff --git a/stt/hud/README.md b/stt/stt/hud/README.md similarity index 100% rename from stt/hud/README.md rename to stt/stt/hud/README.md diff --git a/stt/hud/index.html b/stt/stt/hud/index.html similarity index 100% rename from stt/hud/index.html rename to stt/stt/hud/index.html diff --git a/stt/stt/server/app.py b/stt/stt/server/app.py index 616e097..ca25f20 100644 --- a/stt/stt/server/app.py +++ b/stt/stt/server/app.py @@ -14,7 +14,8 @@ from http.server import SimpleHTTPRequestHandler, ThreadingHTTPServer from pathlib import Path from typing import Any -HUD_DIR = Path(__file__).resolve().parent.parent.parent / "hud" +# Le HUD est embarqué DANS le package (stt/hud) pour être livré par pipx. +HUD_DIR = Path(__file__).resolve().parent.parent / "hud" def _start_http(host: str, port: int) -> ThreadingHTTPServer: