Building an Audio Job Queue with GPU Fallback in TypeScript
Building an Audio Job Queue with GPU Fallback in TypeScript Introduction When building AI-powered audio processing — text-to-speech, voice cloning, transcription — you need infrastructure that hand...

Source: DEV Community
Building an Audio Job Queue with GPU Fallback in TypeScript Introduction When building AI-powered audio processing — text-to-speech, voice cloning, transcription — you need infrastructure that handles GPU scarcity gracefully. This post shares how we built a persistent audio job queue with segment-level tracking, priority scheduling, and automatic GPU-to-CPU fallback as part of the ORCHESTRATE platform's Sprint 3 Audio Engine. This is part of our sprint retrospective series: Sprint 0: Foundation & Publishing Pipeline Sprint 1: Building the Memory System Foundation Sprint 2: Content Sourcing & Provenance Sprint 3: Production Validation & Pipeline Hardening The Problem Audio processing for podcasts involves multiple TTS engines: Piper (CPU-only): Fast, lightweight, good for narration XTTS v2 (GPU-preferred): Higher quality, voice cloning, but needs GPU A single podcast episode has dozens of segments. Some need GPU, some don't. GPUs are expensive and scarce. We needed: Persiste