Why We Replaced PyTorch with ONNX Runtime
AiPBX 1.9.0–1.9.1 originally ran EMA Lightning on PyTorch: ~1.1 GB runtime footprint, up to 1 GB RAM, and 3.6–4.5× real-time speed on a 2-core Intel i7-7700. Porting the exact graph to ONNX Runtime + numpy shrank the runtime to ~150 MB, dropped RAM to ~115–250 MB, and tripled speed to 11–12× real time (6.4 s sentence synthesized in 0.55 s).
Measured Models & Why STT/LLM Moved to Cloud/BYO Server
Measured on 2 CPU cores: EMA Lightning (Turkish, Apache-2.0, 11–12×, ~115–250 MB), Piper (DE/EN, 13–16×, ~122–166 MB), and Kokoro 82M (English, 1.7×, ~460–650 MB shared; quantized Kokoro ONNX builds crashed ONNX Runtime so fp32 is used). We also tested local Whisper, Vosk, and Ollama, and deliberately moved STT & LLMs to Cloud AI or an external OpenAI-compatible server so CPU-only PBXs stay fast and lean.