lagent
lagent copied to clipboard
Update base_llm.py
Increase code flexibility and backward compatibility
We do not want to support **kwargs in BaseModel, for it wont raise error when wrong init parameter
We do not want to support
**kwargsin BaseModel, for it wont raise error when wrong init parameter
In fact, I ran into an issue where if I tried to pass in device_map='auto', it reported an error. But this is a useful parameter in AutoModelForCausalLM.from_pretrained. If there any other solution?
we have model_kwargs for HFTransformer model, which will be passed to AutoModelForCausalLM