You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
AutoLigerKernelForCausalLM.from_pretrained retain only the keyword args present in the model configuration, which do not include hub_kwargs_names -> [
"cache_dir",
"force_download",
"local_files_only",
"proxies",
"resume_download",
"revision",
"subfolder",
"use_auth_token",
"token",
]
therefore cannot replace AutoModelForCausalLM
Reproduce
N/A
Versions
N/A
The text was updated successfully, but these errors were encountered:
+1, I notice that some models don't have attn_implementation in their config even though its a valid keyword arg to AutoModelForCausalLM - so the user-specified attn_implementation gets discarded as well.
Thanks for reporting! Currently we are only keeping kwargs that are present in the model config. I wasn't aware of this other set of valid args--let me look into it
Thanks for looking into it!
I don't know what's the motivation for filtering the kwargs, but I would consider removing this logic completely,
After seeing Tyler's comment, I looked around the transformers code and noticed there are many many kwargs that are not in the config and they vary between from_pretrained implementations,
I also saw that each from_pretrained implementation handles extra kwargs, so just passing on the kwargs seems safe
🙏
🐛 Describe the bug
AutoLigerKernelForCausalLM.from_pretrained retain only the keyword args present in the model configuration, which do not include hub_kwargs_names -> [
"cache_dir",
"force_download",
"local_files_only",
"proxies",
"resume_download",
"revision",
"subfolder",
"use_auth_token",
"token",
]
therefore cannot replace AutoModelForCausalLM
Reproduce
N/A
Versions
N/A
The text was updated successfully, but these errors were encountered: