Website | Source

Installing

It's a Python package, so use either pip or pipx (depending on how Python is installed on the system--Homebrew doesn't install pip, it installs pipx which is supposed to be tuned slightly differently for global tool installs): pipx install mlx-lm

Download and run a model: python -m mlx_lm.generate --model mlx-community/Llama-3.1-8B-Instruct-4bit --prompt "Write a python script to scrape a website."

Launch a local chat interface: python -m mlx_lm.chat --model mlx-community/Llama-3.1-8B-Instruct-4bit


Tags: ai   llm   inference engine   macOS  

Last modified 11 September 2026