SCOTT WORLEY.

Independent work / Systems engineering

Subwave

Operating a distributed AI-powered radio platform

A multi-host integration of music catalog services, language-model inference, acoustic analysis, speech synthesis and continuous audio broadcasting, built around a self-hosted installation of the open-source SUB/WAVE project.

3 Physical hosts in the configured architecture
20/20 Successful direct Liquidsoap connection tests
10/10 Successful queue status tests
Broadcast service dependencies
  1. NavidromeMusic catalog and library access
  2. ControllerProgramming decisions and DJ cues
  3. LiquidsoapAudio scheduling and playout
  4. IcecastContinuous shared broadcast

01 / Project overview

The objective was to operate a continuously programmed personal radio station rather than a conventional on-demand music player. Listeners tune into a shared broadcast, while an AI DJ selects music and prepares spoken segments.

The system combines services with different computational requirements, communication protocols and operational failure modes. My work focuses on integrating those components, distributing workloads across available hardware, investigating failures and validating targeted remediation.

02 / System architecture

The deployment spans three Apple silicon hosts running Linux and macOS. Broadcasting and orchestration are separated from computationally expensive audio analysis and language-model workloads.

Host Workload allocation
M1 Mac mini
16 GB / Asahi Fedora
Docker-based controller, Navidrome, Liquidsoap and Icecast services.
M4 Mac mini
16 GB / macOS
Acoustic analysis sidecar, Chatterbox speech synthesis and a configured Ollama inference backend.
M1 Max MacBook Pro
32 GB / macOS
Additional Ollama inference capacity.

HAProxy provides a shared entry point for the configured Ollama backends. Backend availability can vary as computational resources are reassigned for audio processing and experimentation.

The controller communicates with external inference, speech synthesis and analysis services through network APIs. This separation enables individual components to be investigated without replacing the entire broadcast stack.

03 / Engineering constraints

Continuous broadcasting introduces timing constraints that differ from ordinary request-response applications. Music playback must be coordinated with queue state, track metadata, language-model decisions and generated speech.

Audio analysis and inference also compete for finite unified memory and computational resources. On smaller hosts, model residency, concurrency and workload placement become operational considerations rather than purely application-level settings.

My approach has been to isolate individual service boundaries, measure observed behavior and adjust configuration based on evidence rather than assume that every failure originates in the application reporting it.

04 / Broadcast reconciliation investigation

During troubleshooting, controller logs contained 29 broadcast reconciliation timeouts over a two-hour observation period. The failures suggested that the controller was unable to reliably communicate with the broadcast service.

I tested Liquidsoap independently to distinguish an unavailable audio engine from a controller-side connectivity problem.

Diagnostic test Observed result
Controller log inspection 29 reconciliation timeouts over two hours
Direct Liquidsoap connection 20 of 20 successful tests, 2-11 ms
Queue status requests 10 of 10 completed requests, 1-13 ms
Configured broadcast hostname Original hostname failed container DNS resolution
Corrected broadcast hostname Actual Docker service hostname resolved successfully

The successful direct tests narrowed the investigation away from Liquidsoap availability and toward the controller's configured destination. The original broadcast hostname did not resolve inside the container network, while the actual service hostname did.

Corrected service configuration

LIQUIDSOAP_HOST=subwave-broadcast
BROADCAST_HOST=subwave-broadcast
BROADCAST_PORT=7702

After applying the corrected configuration, a subsequent five-minute log inspection showed no matching reconciliation or Icecast errors. Icecast also reported an active broadcast source.

05 / Application-level DNS troubleshooting

A separate investigation identified stalled Node.js HTTP connections to Navidrome despite successful IPv4 resolution and connectivity through alternative client paths.

I implemented a hostname-specific lookup override using an Undici dispatcher, preserving normal DNS lookup behavior for other destinations. The deployed override subsequently passed ten HTTP connectivity smoke tests.

The implementation, diagnostic reasoning and verification boundaries are documented in the Container DNS and Undici case study.

06 / Distributed acoustic analysis and inference

I integrated a macOS-hosted acoustic analysis sidecar with the Linux-based controller, investigating remote file accessibility, Python dependencies, hardware acceleration and concurrent workload behavior.

Hardware validation confirmed that PyTorch could execute a compute test using Apple's Metal Performance Shaders backend. Individual model compatibility and application-level analysis remained separate validation concerns.

Speech synthesis was hosted separately using Chatterbox, while Ollama inference endpoints were placed behind HAProxy. This enabled experimentation with workload placement, model residency and service availability across the available hosts.

Further details are documented in the Distributed AI inference case study.

07 / My engineering contributions

  • Multi-host Linux and macOS service integration.
  • Docker networking and application-level DNS investigation.
  • Targeted Node.js HTTP client remediation.
  • Broadcast service connectivity and queue-state testing.
  • Distributed inference configuration using HAProxy and Ollama.
  • Acoustic analysis and speech synthesis integration.
  • Failure isolation, configuration changes and post-change verification.

SUB/WAVE and its supporting open-source projects provide the underlying application capabilities. My contributions concern the deployment, integration, configuration, investigation and operation of this independent environment.

SUB/WAVE upstream project