# MLX-Audio

> Speech generation and recognition running natively on Apple Silicon

- Category: Multimodal Generation / Audio, Music & Voice
- Language: Python
- Licence: MIT
- Repository: https://github.com/Neywa-Labs/mlx-audio
- Website: https://neywa-labs.github.io/mlx-audio/
- Canonical page: https://ai-tldr.dev/tools/mlx-audio/

## In short

MLX-Audio is Speech generation and recognition running natively on Apple Silicon. The repository is maintained under the Neywa Labs organisation on GitHub; Neywa Labs is the local-AI company behind the Nativ app. It sits in the Audio, Music & Voice category of the Multimodal Generation tools and is open-source, written in Python and licensed MIT.

## Overview

MLX-Audio is an audio-processing library built directly on Apple's MLX framework, so speech models run on the unified memory and GPU of an Apple Silicon Mac rather than through a CPU fallback or a remote API. It covers text-to-speech, speech-to-text, speech-to-speech and music generation behind one package. The repository is maintained under the Neywa Labs organisation on GitHub; Neywa Labs is the local-AI company behind the Nativ app.

The model coverage is broad and current. For TTS it supports Kokoro, Qwen3-TTS, OmniVoice, KittenTTS, Voxtral, MeloTTS, Ming Omni and KugelAudio among others; for STT, Whisper, Qwen3-ASR, Parakeet, VibeVoice-ASR and Voxtral Realtime; for speech-to-speech, SAM-Audio, DialogueSidon and the MossFormer2 enhancement model; plus MiniMax Music 3 for music. Models are pulled from Hugging Face by identifier, so trying a different voice or a quantised variant is a one-string change.

It is usable three ways: as a Python library, as a CLI for one-off generation, and as a local HTTP server with an optional web UI — which makes it a practical local backend for a voice app you do not want sending audio off the machine. It requires Python 3.10+, an Apple Silicon Mac (M1 through M4), and ffmpeg for MP3, FLAC, OGG, Opus and Vorbis encoding.

## What it does

- Text-to-speech, speech-to-text, speech-to-speech and music generation in one library
- Runs natively on Apple Silicon through MLX, using the GPU and unified memory
- Wide model support including Kokoro, Qwen3-TTS, Voxtral, Whisper, Parakeet, SAM-Audio and MiniMax Music 3
- Models loaded by Hugging Face identifier, so swapping voices or quantisations is trivial
- Three interfaces: Python API, CLI generation, and a local HTTP server with a web UI
- MIT licensed

## Getting started

Install from PyPI on an Apple Silicon Mac. Install ffmpeg too if you want compressed output formats.

1. Install the package

```bash
pip install mlx-audio
```

2. Generate speech from Python

   load_model takes a Hugging Face model id. generate yields results you read the audio off — swap the voice and speed per call.

```python
from mlx_audio.tts.utils import load_model

model = load_model("mlx-community/Kokoro-82M-bf16")
for result in model.generate(
    text="Welcome to MLX-Audio!",
    voice="af_heart",
    speed=1.0,
):
    audio = result.audio
```

3. Or generate from the CLI

```bash
mlx_audio.tts.generate --model mlx-community/Qwen3-TTS-12Hz-0.6B-CustomVoice-8bit --text 'Hello, world!' --voice Vivian
```

4. Run the local server and web UI

   Start the server, then bring up the UI in a second terminal.

```bash
mlx_audio.server --host 0.0.0.0 --port 8000

# in another terminal
cd mlx_audio/ui
npm install && npm run dev
```

## When to use it

- Reach for it to run text-to-speech locally on a Mac with no per-character API bill and no audio leaving the machine
- Reach for it to transcribe with Whisper or Parakeet on Apple Silicon at GPU speed rather than CPU
- Reach for it as the speech backend for a local voice assistant, using the built-in HTTP server
- Reach for it when comparing several TTS voices or models quickly, since each is a model-id change
