ARahim3/mlx-tune
Fine-tune LLMs on your Mac with Apple Silicon. SFT, DPO, GRPO, Vision, TTS, STT, Embedding, and OCR fine-tuning — natively on MLX. Unsloth-compatible API.
What it solves
mlx-tune provides a way for Mac users to fine-tune a wide variety of AI models locally using Apple Silicon. It specifically addresses the "context switch" problem where developers want to prototype and iterate on training scripts locally on a Mac before scaling up to cloud GPUs using the Unsloth library, without having to rewrite their code.
How it works
It wraps Apple's native MLX framework in an API that is compatible with Unsloth. This allows users to write training code using familiar classes like FastLanguageModel and SFTTrainer on their Mac, and then move that same script to a CUDA-based environment for production training. It supports a broad range of modalities including text, vision, audio, and OCR, and leverages Mac's unified memory for efficient local training.
Who it’s for
Developers and AI researchers using Apple Silicon (M1 through M5) who want to prototype, learn, and iterate on fine-tuning pipelines locally before deploying to cloud NVIDIA GPUs.
Highlights
- Broad Model Support: Fine-tune LLMs, Vision-Language Models (VLMs), Text-to-Speech (TTS), Speech-to-Text (STT), Embeddings, and OCR models.
- Unsloth-Compatible API: Allows for seamless code portability between Mac and CUDA clusters.
- Advanced Training Methods: Supports SFT, DPO, ORPO, GRPO, KTO, and SimPO.
- ** uma Unified Memory**: Can leverage up to 512GB of unified memory on Mac Studio.
- JEPA Integration: Implements Joint-Embedding Predictive Architecture (JEPA) for vision, video, and LLM fine-tuning.
- Flexible Export: Export models in HuggingFace format or GGUF for use with Ollama and llama.cpp.