Skip to content

just setup-python doesn't install mlx-audio/mlx-lm — MLX backend fails on fresh Apple Silicon dev setup #823

Description

@edmiidz

Summary

just setup-python does not install mlx-audio (or mlx-lm), so a freshly set-up dev environment on Apple Silicon fails all STT/TTS that go through the MLX backend with:

ModuleNotFoundError: No module named 'mlx_audio'

The release CI (.github/workflows/release.yml) installs these packages, but the justfile — the documented dev setup path (just setup) — does not. So the bundled app works while a from-source dev checkout silently can't transcribe or generate on the MLX path.

Environment

  • Repo at cabef1b (v0.5.0), built from source via just setup
  • macOS 26.5.1, Darwin 25.5.0, arm64 (Apple Silicon)
  • Python 3.12.13 (Homebrew), mlx==0.31.2

Reproduction

just setup           # or: just setup-python
just dev-backend
curl -X POST http://127.0.0.1:17493/transcribe -F "file=@any.wav" -F "model=turbo"

The transcribe call returns 202 repeatedly, and the server log shows:

ERROR: Marked whisper-turbo as error: No module named 'mlx_audio'

backend/backends/mlx_backend.py imports from mlx_audio.stt import load (line ~307) and from mlx_audio.tts import load (line ~97), but nothing in just setup-python installs mlx-audio.

Root cause

requirements-mlx.txt deliberately does not list mlx-audio (its comment explains the transformers version conflict and says to install it --no-deps afterward). release.yml does exactly that:

# .github/workflows/release.yml
pip install -r backend/requirements-mlx.txt
pip install --no-deps mlx-lm==0.31.1
pip install --no-deps mlx-audio==0.4.1

But the justfile MLX block stops at requirements-mlx.txt:

# justfile (Apple Silicon block in setup-python)
if [ "$(uname -m)" = "arm64" ] && [ "$(uname)" = "Darwin" ]; then
    echo "Detected Apple Silicon — installing MLX dependencies..."
    {{ pip }} install -r {{ backend_dir }}/requirements-mlx.txt
fi

So mlx-lm and mlx-audio are never installed for dev.

Suggested fix

Add the same two --no-deps installs to the Apple-Silicon branch of setup-python in the justfile (both the [unix] and [windows] recipes), mirroring release.yml:

{{ pip }} install -r {{ backend_dir }}/requirements-mlx.txt
{{ pip }} install --no-deps mlx-lm==0.31.1
{{ pip }} install --no-deps mlx-audio==0.4.1

Workaround

backend/venv/bin/pip install --no-deps mlx-lm==0.31.1 mlx-audio==0.4.1

Filed after a from-source build on Apple Silicon. Related: #699 (also MLX-on-Apple-Silicon, same package versions).

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions