unsloth/studio/backend/utils/datasets
DoubleMathew a932294627
MLX training support for Studio on Apple Silicon (#5340)
* mlx fixes

* Fix studio integration, local dataset files, chat templates without the torch gpu imports

* pass grad norm in mlx worker

* fix(studio): pass MLX grad clipping settings

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* mlx: update grad value

* fix(mlx): address ci and clipping review

* fix backward compatibility and CI tests

* unsloth local is mlx function

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* dont reference runtime

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* studio mlx: hardcode value clipping, drop max_grad_value from frontend

Simplifies the MLX grad-clipping plumbing now that we are standardising on
elementwise value clipping at [-5, 5] for the compiled MLX path and norm
clipping disabled. The MLX worker no longer reads max_grad_norm /
max_grad_value from the request; both are pinned in one place. Frontend
stops sending the field at all, and the TypeScript request type drops it
to match. Non-MLX (CUDA/AMD/Intel) is untouched and continues to pick up
HF TrainingArguments' default max_grad_norm = 1.0.

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Daniel Han <danielhanchen@gmail.com>
2026-05-14 05:24:20 -07:00
..
__init__.py Update license headers 2026-03-12 17:23:10 +00:00
chat_templates.py MLX training support for Studio on Apple Silicon (#5340) 2026-05-14 05:24:20 -07:00
data_collators.py fix: install.sh Mac Intel compatibility + Studio no-torch support (#4624) 2026-03-27 02:09:21 -07:00
dataset_utils.py feat(studio): add Continued Pretraining (CPT) as a training method (#4677) 2026-05-06 13:38:35 +04:00
format_conversion.py fix(studio): avoid UnicodeEncodeError on Windows cp1252 consoles (#4699) 2026-03-30 06:40:47 -07:00
format_detection.py Final cleanup 2026-03-12 18:28:04 +00:00
llm_assist.py chore: switch helper and no-cache fallback to Gemma (#5066) 2026-04-16 22:27:30 +04:00
model_mappings.py Add Qwen3.6 support (#5257) 2026-05-02 23:30:57 +04:00
raw_text.py feat(studio): add Continued Pretraining (CPT) as a training method (#4677) 2026-05-06 13:38:35 +04:00
vlm_processing.py Final cleanup 2026-03-12 18:28:04 +00:00