Skip to main content

Apple Silicon MLX fine-tuning and OpenAI-compatible serving (SFT stable; preference/RL experimental).

Project description

mlxsmith

Apple Silicon MLX fine-tuning and OpenAI-compatible serving. SFT + serving are stable. Preference/RL/RLM features are experimental.

Status: alpha (2026-02-02).

Stable features

  • Project init, config, data tools, HF auth, model pull/convert.
  • SFT (LoRA/QLoRA) training with run tracking and adapters.
  • Inference and OpenAI-compatible /v1/chat/completions serving.
  • Basic eval/bench and verifier plumbing (regex/jsonschema/pytest).

Experimental features

  • Preference tuning (DPO/ORPO).
  • GRPO-style RFT.
  • RLM self-play loop (research).
  • Distill/OPD and orchestrated RLM.

Install

MLX is only available on Apple Silicon. Other platforms can still use data tools and mock backends, but MLX training and serving require macOS on Apple Silicon.

python -m venv .venv && source .venv/bin/activate
pip install -U pip

# Core CLI
pip install mlxsmith

# Apple Silicon training + serving
pip install "mlxsmith[mlx,llm,serve]"

Quickstart

mlxsmith init myproj
cd myproj
mlxsmith doctor

HF auth (optional)

mlxsmith auth login --token "$HF_TOKEN"
mlxsmith auth status
mlxsmith auth logout

Pull + convert a model (HF -> MLX)

mlxsmith pull Qwen/Qwen3-4B-Instruct-2507
# outputs to cache/mlx/Qwen__Qwen3-4B-Instruct-2507

Optional quantization:

mlxsmith pull Qwen/Qwen3-4B-Instruct-2507 --quantize --q-bits 4

SFT (LoRA/QLoRA)

mlxsmith sft --model cache/mlx/Qwen__Qwen3-4B-Instruct-2507 --data data/sft

Serve (OpenAI-compatible)

mlxsmith serve --model runs/sft_0001/adapter --port 8080

Sample request:

curl http://localhost:8080/v1/chat/completions \
  -H 'Content-Type: application/json' \
  -d '{"messages":[{"role":"user","content":"Hello"}],"max_tokens":64}'

To enable the optional UI/monitor dashboard, set serve.ui: true in mlxsmith.yaml.

Experimental commands

  • mlxsmith pref (DPO/ORPO)
  • mlxsmith rft (GRPO-style)
  • mlxsmith rlm / mlxsmith pipeline (self-play loop)
  • mlxsmith distill (offline/OPD)
  • mlxsmith eval / mlxsmith bench

Docs

  • docs/PROJECT_FORMAT.md for project layout and artifacts.
  • docs/VERIFIERS.md for verifier API and sandbox behavior.
  • docs/COMPATIBILITY.md for tested versions and model families.
  • docs/ENVIRONMENTS.md for the environment plugin system.
  • docs/ROADMAP.md for product direction and milestones.
  • docs/README.md for the full docs index.

License

MIT

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

mlxsmith-0.1.0.tar.gz (131.4 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

mlxsmith-0.1.0-py3-none-any.whl (144.9 kB view details)

Uploaded Python 3

File details

Details for the file mlxsmith-0.1.0.tar.gz.

File metadata

  • Download URL: mlxsmith-0.1.0.tar.gz
  • Upload date:
  • Size: 131.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for mlxsmith-0.1.0.tar.gz
Algorithm Hash digest
SHA256 ca3d2eaee57ffb32e38ccad44c49a5d026c4a8e801e27bc28c4dd4dd89acbed9
MD5 2b68073fd08d60f5c5910a7621b7324b
BLAKE2b-256 1bc8a001a6a6958716c1821820284ffaf935f952c90706e8ff534c1dc0c42226

See more details on using hashes here.

Provenance

The following attestation bundles were made for mlxsmith-0.1.0.tar.gz:

Publisher: publish.yml on Hmbown/MLXSmith

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file mlxsmith-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: mlxsmith-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 144.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for mlxsmith-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 6eb12bb1d14e77be1f21528d704e3a4cf5f1823f1d6625f1c5d87bde92620105
MD5 8690b3d3476aa7736ac43562fd676bda
BLAKE2b-256 d4d1c80ae65633f459edc30413a0b55feaba9c061a5fc3fdf43b731a25ba3b47

See more details on using hashes here.

Provenance

The following attestation bundles were made for mlxsmith-0.1.0-py3-none-any.whl:

Publisher: publish.yml on Hmbown/MLXSmith

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page