prompt2model
prompt2model copied to clipboard
Support models that require trust_remote_code
Some recent models require Hugging Face's trust_remote_code to be set to true. This should be off by default, but we should allow users to set it if they wish. Reference: https://github.com/neulab/prompt2model/issues/356
In order to implement this, trust_remote_code
will probably need to be set when we load the model here:
https://github.com/neulab/prompt2model/blob/72d97cce42e7fa13db95f317fd2717611813bc05/prompt2model/model_trainer/generate.py#L64-L77
This should be set as an argument to GenerationModelTrainer
with a default of false
: https://github.com/neulab/prompt2model/blob/72d97cce42e7fa13db95f317fd2717611813bc05/prompt2model/model_trainer/generate.py#L28