/mlx-vlm-skills:contributingfrom mlx-vlm-skills
Guides contributing to MLX-VLM: PR workflow, model code layout, backward-compatible config, test suite, pre-commit hooks (black, clang-format), and PR expectations.
Ships in mlx-vlm-skills. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
None: SKILL.md is the whole skill.
Use this workflow to shape a contribution so it lands cleanly. It reflects the current mlx_vlm/ layout (note: CONTRIBUTING.md still points at an older src/ layout — the real paths are below).
git clone https://github.com/<you>/mlx-vlm && cd mlx-vlm
uv pip install -e . # editable install (or: pip install -e .)
mlx_vlm/models/<model_type>/, and the file name matches the config.json model_type (e.g. llava). A new kernel or helper goes in its own file in that model directory, not bolted into language.py. To add a whole new model, use Skill("mlx-vlm-skills:add-new-model").ModelConfig (in <model>/config.py) with an inline # comment, and keep them backward-compatible — a default of None/0/False must reproduce the original behavior so existing checkpoints and configs are unaffected. Gate new features so they are opt-in.mlx_vlm/tests/test_models.py as a class per feature (e.g. TestMyFeature). Do not create a standalone test_<feature>.py — repo convention keeps model tests in test_models.py. Prefer cheap synthetic/random-weight tests (tiny configs) and check exactness against the original path in the degenerate limit (feature disabled == baseline).cd mlx_vlm && uv run --with pytest python -m pytest tests/test_models.py -q -k "<ClassName>"
Before opening a PR, install the pre-commit hooks once and run them. The repo uses pre-commit (black for Python, clang-format for C++); PRs are expected to be hook-clean.
pip install pre-commit
pre-commit install # install the git hooks (run once per clone)
# run on the files you changed
pre-commit run --files <file1.py> <file2.py>
# or check everything
pre-commit run --all-files
You can also format a single file directly:
black <file>.py
# clang-format -i <file>.cpp # for C++
Reminder: run pre-commit run --all-files (or at least on your changed files) as the last step before pushing — an unformatted diff will fail CI/review.
main.Skill("mlx-vlm-skills:benchmarking") for the fork-vs-main table format.Skill("mlx-vlm-skills:add-new-model").Skill("mlx-vlm-skills:convert-quantize").Skill("mlx-vlm-skills:benchmarking").Skill("mlx-vlm-skills:reproducible-github-issues").What SKILL.md sets; muted values are Claude Code's defaults
Three short reads, in order
contributing, mlx-vlm, pr-workflow, pre-commit, testing, formatting
npx claudepluginhub internet-projects/inkling2-mlx --plugin mlx-vlm-skills8 skills in this plugin
/add-new-modelUse this skill when the user wants to add or port a new model architecture to MLX-VLM — mapping a Hugging Face model_type to a new file under mlx_vlm/models, writing the ModelConfig, matching layer/weight names, reusing a similar existing model, adding a test class, and validating the port. Covers vision-language, language, audio, and diffusion model ports./benchmarkingUse this skill when the user wants to benchmark an MLX-VLM change and present the numbers in a PR — fork-vs-main A/B comparisons, isolated-module micro-benchmarks, median-of-N timing with warmup, peak-memory reporting, correctness checks, parameter sweeps, and self-contained reproducible bench scripts to paste into a PR description./cli-inferenceUse this skill when the user wants to run or debug MLX-VLM inference from the command line, including uv run mlx_vlm.generate, image/audio/video inputs, local model paths, Hugging Face model IDs, deterministic repro commands, and CLI errors around processors, prompts, model loading, or missing weights./convert-quantizeUse this skill when the user wants to convert a Hugging Face model to MLX or quantize/dequantize one with mlx_vlm.convert, including bits and group size, quant modes (affine, mxfp4, nvfp4, mxfp8), RTN vs AWQ, mixed-bit recipes, dtype casts, calibration (text or multimodal), local vs Hub paths, revisions, uploading to the Hub, and convert/quant errors./hf-cache-modelsUse this skill when the user wants to list, inspect, or report cached, custom, or loaded MLX-VLM models through the server's model discovery endpoint./reproducible-github-issuesUse this skill when the user wants to create, improve, or triage a reproducible GitHub issue for MLX-VLM, including bug reports from CLI inference, server inference, model loading, processors, media inputs, dependency setup, crashes, wrong outputs, or performance regressions.3 plugins ship this exact skill · first indexed Aug 4, 2026
Other plugins' skills for the same job