mirror of
https://github.com/ml-explore/mlx-examples.git
synced 2025-09-01 04:14:38 +08:00
support internlm2 (#797)
* support internlm2 * only attention projections --------- Co-authored-by: Awni Hannun <awni@apple.com>
This commit is contained in:
@@ -119,6 +119,8 @@ def linear_to_lora_layers(
|
||||
keys = set(["mixer.Wqkv", "moe.gate"])
|
||||
elif model.model_type == "dbrx":
|
||||
keys = set(["norm_attn_norm.attn.Wqkv", "ffn.router.layer"])
|
||||
elif model.model_type == "internlm2":
|
||||
keys = set(["attention.wqkv", "attention.wo"])
|
||||
else:
|
||||
raise ValueError(f"Lora does not support {model.model_type}")
|
||||
|
||||
|
Reference in New Issue
Block a user