MLX Export
Use tinygpt export-mlx when a TinyGPT-trained artifact needs to leave the
TinyGPT binary and be loaded from Python MLX, MLX-Swift, or another Mac-local
tool.
Full distilled or trained checkpoints:
tinygpt export-mlx path/to/model.tinygpt --out exported-model
python exported-model/mlx_load.py exported-model
Fine-tuned adapters:
tinygpt export-mlx path/to/adapter.lora --out exported-adapter
python exported-adapter/mlx_load.py exported-adapter
The command writes standard safetensors containers plus sidecars:
model.safetensorsfor full.tinygptcheckpoints.adapters.safetensorsfor.lora/ DoRA adapters.config.json,adapter_config.json, tokenizer sidecars, andtinygpt_mlx_export.jsonmetadata.mlx_load.py, a tiny Python MLX helper that loads the arrays and config.
TinyGPT-native byte-level checkpoints are not marked as mlx-lm compatible.
Their tensors are MLX-loadable, but a caller still needs a TinyGPT-aware module
class to run a forward pass. HF / MLX model directories copied through
export-mlx remain mlx-lm compatible when their original architecture is
supported by mlx-lm.
Specialist packages
For trained modules that should be shared or routed in an app, pair the MLX
export with a specialist package under specialists/<id>/:
model_card.mdfor the human-facing claim and limitations.prompt.mdfor the measured system/developer prompt.eval_report.jsonfor machine-readable scores and regressions.tinygpt.lock.jsonfor artifact files, sizes, checksums, base model, and compatibility.mlx_load.pyfor cheap metadata validation and optional MLX loading.
The first package is specialists/qwen3-4b-file-ops-distilled: a real fused
Qwen3-4B file-ops specialist stored at ~/.cache/tinygpt/models/mt4b_fused.