feat(atelier): asset authoring pipeline P2–P5 (audio, écran LCD, sync SD, atelier unifié) #128

Merged
electron merged 5 commits from feat/p2-audio-pipeline into main 2026-06-13 20:43:37 +00:00
Owner

Chemin web complet du plan d'authoring d'assets (specs/2026-06-13-atelier-asset-authoring-plan.md).

Phases

  • P2 — Audio : file async TTS dans le gateway (POST /v1/assets/audio/generate + /status + /v1/_staged/{key}), backends f5 (voix Zacus clonée, voice-bridge) et kokoro (voix stock, vllm-mlx). Panneau « Voix » dans l'atelier (lecteur <audio>).
  • P3a — Écran (LCD) : éditeur de scène (title/subtitle/symbol/effect) avec aperçu fidèle du rendu ST7796 480×320 (palette Workbench, fonts Orbitron/IBM Plex Mono, effets pulse/glitch/gyro animés), limites firmware imposées, export scene: YAML round-trip-validé contre _validate_step_scene.
  • P4 — Sync SD : POST /v1/assets/stage pousse les assets stagés sur la SD d'une carte via la route firmware existante POST /game/file?path=sd/... (layout /sdcard/zacus/{board}/). hot = push HTTP, cold = bundle host. Zéro changement firmware. NFS / PULL / partitions restent hardware-gated.
  • P5 — Atelier unifié : panneau « ✦ Assets » à onglets (Texte / Voix / Écran / Déployer) ; l'onglet Déployer appelle /v1/assets/stage.

Validation

  • Gateway audio + stage : testés E2E (generate→done→preview WAV ; cold bundle + hot push au bon chemin SD).
  • Frontend : tsc --noEmit + vite build propres.
  • Export scene : accepté/rejeté correctement par le validateur strict du compilateur.

🤖 Generated with Claude Code

Chemin web complet du plan d'authoring d'assets (`specs/2026-06-13-atelier-asset-authoring-plan.md`). ## Phases - **P2 — Audio** : file async TTS dans le gateway (`POST /v1/assets/audio/generate` + `/status` + `/v1/_staged/{key}`), backends `f5` (voix Zacus clonée, voice-bridge) et `kokoro` (voix stock, vllm-mlx). Panneau « Voix » dans l'atelier (lecteur `<audio>`). - **P3a — Écran (LCD)** : éditeur de scène (title/subtitle/symbol/effect) avec **aperçu fidèle** du rendu ST7796 480×320 (palette Workbench, fonts Orbitron/IBM Plex Mono, effets pulse/glitch/gyro animés), limites firmware imposées, export `scene:` YAML round-trip-validé contre `_validate_step_scene`. - **P4 — Sync SD** : `POST /v1/assets/stage` pousse les assets stagés sur la SD d'une carte via la route firmware existante `POST /game/file?path=sd/...` (layout `/sdcard/zacus/{board}/`). hot = push HTTP, cold = bundle host. **Zéro changement firmware.** NFS / PULL / partitions restent hardware-gated. - **P5 — Atelier unifié** : panneau « ✦ Assets » à onglets (Texte / Voix / Écran / Déployer) ; l'onglet Déployer appelle `/v1/assets/stage`. ## Validation - Gateway audio + stage : testés E2E (generate→done→preview WAV ; cold bundle + hot push au bon chemin SD). - Frontend : `tsc --noEmit` + `vite build` propres. - Export scene : accepté/rejeté correctement par le validateur strict du compilateur. 🤖 Generated with [Claude Code](https://claude.com/claude-code)
electron added 5 commits 2026-06-13 20:33:03 +00:00
Add the audio half of the asset pipeline: an in-process asyncio TTS queue
with POST /v1/assets/audio/generate (backend f5=cloned Zacus voice via the
voice-bridge, or kokoro=stock voices via vllm-mlx /v1/audio/speech), polled
via GET /v1/assets/audio/{id}/status, with generated WAVs staged under
share-store/_staged and previewed read-only via GET /v1/_staged/{key}
(path-traversal guarded). Token-free same-origin, mirroring P1 text-gen.

Validated end-to-end: generate(kokoro, ff_siwis) -> done -> 24 kHz WAV preview.
feat(atelier): P2 — audio (TTS) generation panel
Repo State / repo-state (push) Failing after 52s
df11635b0f
Floating « Générer voix » panel mirroring the P1 text-gen one: pick a backend
(f5 cloned Zacus voice via voice-bridge, or kokoro stock voices via vllm-mlx),
a stock voice, type a line, generate, then audition the staged WAV in an inline
<audio> player + download. Async job polling lives in lib/audiogen.ts.

typecheck + vite build clean.
Floating « Écran (LCD) » panel: edits a step's scene (title/subtitle/symbol/
effect) with a faithful ST7796 480×320 preview (Workbench palette, Orbitron/
IBM Plex Mono fonts, animated pulse/glitch/gyro effects mirrored from
display_ui.cpp), enforces the firmware char limits (47/63/15), drafts screen
text via ailiance (scene_text), and emits the scene: YAML block to paste onto
a step. Output round-trip-validated against the compiler's _validate_step_scene.

typecheck + vite build clean.
POST /v1/assets/stage pushes the staged assets to a board's microSD via the
firmware's existing POST /game/file?path=sd/... route (which already mkdir -p's
and writes under /sdcard) — on-card layout /sdcard/zacus/{board}/<file>. hot
pushes over HTTP to the board IP; cold writes a host bundle + manifest.json for
manual SD copy. No firmware change needed; NFS and a PULL-side /assets/sync stay
hardware-gated.

Validated end-to-end: cold bundles box3; hot pushes to a stub board at the
exact sd/zacus/{board}/ path.
feat(atelier): P5 — unified Assets panel (text/voice/screen/deploy)
Repo State / repo-state (push) Failing after 38s
Repo State / repo-state (pull_request) Failing after 44s
Validate Zacus refactor / validate (pull_request) Successful in 13m20s
4f4fedfda2
Fold the three per-type authoring panels into one tabbed « Assets » workspace:
the floating TextGen/AudioGen/ScreenEditor panels become embeddable *Body
components, and a new Deploy tab stages the generated audio onto a board's SD
via the gateway (POST /v1/assets/stage, P4) with per-asset status. App.tsx now
mounts a single AssetsPanel instead of three floating buttons.

typecheck + vite build clean.
electron merged commit f78d649527 into main 2026-06-13 20:43:37 +00:00
electron deleted branch feat/p2-audio-pipeline 2026-06-13 20:43:45 +00:00
Sign in to join this conversation.