diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index fdaef39ea..0206b0774 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -59,7 +59,7 @@ layer names, we suggest either: To add LoRA support edit [`mlx_lm/tuner/utils.py`](https://github.com/ml-explore/mlx-lm/blob/main/mlx_lm/tuner/utils.py#L27-L60) -Finally, add a test for the new modle type to the [model +Finally, add a test for the new model type to the [model tests](https://github.com/ml-explore/mlx-lm/blob/main/tests/test_models.py). You can run the tests with: diff --git a/mlx_lm/LEARNED_QUANTS.md b/mlx_lm/LEARNED_QUANTS.md index 8bce3cfba..29585ba1c 100644 --- a/mlx_lm/LEARNED_QUANTS.md +++ b/mlx_lm/LEARNED_QUANTS.md @@ -106,7 +106,7 @@ Use `mlx_lm.awq` to run AWQ on a given model. For example: mlx_lm.awq --model Qwen/Qwen3-0.6B ``` -The script can take anywhere form a few minutes to several hours to run +The script can take anywhere from a few minutes to several hours to run depending on the model size and the number of samples. Some important options, along with their default values, are: diff --git a/mlx_lm/LORA.md b/mlx_lm/LORA.md index 7e5080f32..d9ef6be36 100644 --- a/mlx_lm/LORA.md +++ b/mlx_lm/LORA.md @@ -1,6 +1,6 @@ # Fine-Tuning with LoRA or QLoRA -You can use use the `mlx-lm` package to fine-tune an LLM with low rank +You can use the `mlx-lm` package to fine-tune an LLM with low rank adaptation (LoRA) for a target task.[^lora] The example also supports quantized LoRA (QLoRA).[^qlora] LoRA fine-tuning works with the following model families: @@ -26,7 +26,7 @@ LoRA (QLoRA).[^qlora] LoRA fine-tuning works with the following model families: ## Run -First, make sure you have the training dependenices installed: +First, make sure you have the training dependencies installed: ```shell pip install "mlx-lm[train]" @@ -196,7 +196,7 @@ data formats. Here are examples of these formats: `chat`: ```jsonl -{"messages": [{"role": "system", "content": "You are a helpful assistant."}, {"role": "user", "content": "Hello."}, {"role": "assistant", "content": "How can I assistant you today."}]} +{"messages": [{"role": "system", "content": "You are a helpful assistant."}, {"role": "user", "content": "Hello."}, {"role": "assistant", "content": "How can I assist you today."}]} ``` `tools`: @@ -302,7 +302,7 @@ pip install datasets If the Hugging Face dataset is already in a supported format, you can specify it on the command line. For example, pass `--data mlx-community/wikisql` to -train on the pre-formatted WikiwSQL data. +train on the pre-formatted WikiSQL data. Otherwise, provide a mapping of keys in the dataset to the features MLX LM expects. Use a YAML config to specify the Hugging Face dataset arguments. For @@ -355,7 +355,7 @@ You are a helpful assistant.<|im_end|> <|im_start|>user Hello.<|im_end|> <|im_start|>assistant -How can I assistant you today.<|im_end|> +How can I assist you today.<|im_end|> ``` If you are unsure of the format to use, the `chat` or `completions` are good to