infra/stacks/portal-tts
Viktor Barzin fe9364b9c9 portal-tts: DRAFT stack — Piper TTS (CPU, always-on) for portal-assistant
Draft (NOT applied) of a new infra stack deploying Piper as an in-cluster
text-to-speech service for the portal-assistant Gateway (portal-assistant
issue #3, ADR-0003). Bulgarian (bg_BG-dimitar-medium) + English
(en_US-lessac-medium), voice chosen per request.

Why this shape:
- CPU-only, always-on (replicas=1, no GPU): Piper runs in real time on CPU, so
  this keeps TTS off the OOM-prone shared T4 that the two GPU siblings
  (tts/chatterbox, portal-stt) already contend for. Bulgarian isn't on
  chatterbox anyway (its langs exclude bg).
- OpenAI-compatible image (openedai-speech-min, /v1/audio/speech) so the Gateway
  gets raw audio bytes per its tts.synthesize(text, lang) -> bytes contract and
  treats Piper + the future edge-tts fallback identically — same shape
  chatterbox already uses.
- Voices on an NFS-SSD PVC, downloaded from rhasspy/piper-voices by an init
  container on first boot; a ConfigMap maps request voice bg/en -> .onnx model.
- ClusterIP only (audio stays on the LAN; the Gateway is the only externally
  exposed component, ADR-0001).

Mirrors the just-written portal-stt sibling stack's conventions. terraform fmt
clean; terraform validate passes (only the codebase-wide kubernetes_namespace
deprecation warnings). HITL: operator reviews + applies via GitOps; do not apply
from a worktree. Open items flagged in main.tf (image choice on a frozen
upstream; resource sizing to confirm with krr).

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-06-17 18:59:42 +00:00
..
main.tf portal-tts: DRAFT stack — Piper TTS (CPU, always-on) for portal-assistant 2026-06-17 18:59:42 +00:00
terragrunt.hcl portal-tts: DRAFT stack — Piper TTS (CPU, always-on) for portal-assistant 2026-06-17 18:59:42 +00:00