LoRA: Remove unnecessary model type judgments (#388)

* LoRA: Remove unnecessary model type judgments

1. Supported models are already checked in the load_model function in utils, no need to repeat the check in lora
2. The checks in lora are not synchronized with those in utils

* LoRA: add LoRA supported models in mlx_lm utils
This commit is contained in:
Madroid Ma
2024-02-01 03:55:27 +08:00
committed by GitHub
parent 0a49ba0697
commit ba3a9355d1
2 changed files with 6 additions and 7 deletions

View File

@@ -25,6 +25,9 @@ MODEL_MAPPING = {
"qwen": qwen,
"plamo": plamo,
}
LORA_SUPPORTED_MODELS = [
llama.Model, mixtral.Model, phi2.Model, stablelm_epoch.Model
]
MAX_FILE_SIZE_GB = 5
linear_class_predicate = (