Facing error while adding multiple adapters to a model
Hi Huggingfacers,I have fine-tuned 4-bit quantized gemma-2b on some task. The finetuned model has‘default’PEFT/LORA adapter. I want to train this model further on some other task by adding one more adapter. I am loading this fine-tuned model as PEFT model usingAutoPeftModelForCausalLMclass. When trying to add adapter to the loaded model [model.add_adapter(peft_config, adapter_name ="t2")] , I am gettingTypeError: PeftModel.add_adapter() got multiple values for argument 'adapter_name'Has anyone tried training a base model for multiple tasks using PEFT?? If yes, please help!
2024-07-08T12:15:54Z
InderV94:I have fine-tuned 4-bit quantized gemma-2b on some task. The finetuned model has‘default’PEFT/LORA adapter. I want to train this model further on some other task by adding one more adapter. I am loading this fine-tuned model as PEFT model usingAutoPeftModelForCausalLMclass. When trying to add adapter to the loaded model [model.add_adapter(peft_config, adapter_name ="t2")] , I am gettingTypeError: PeftModel.add_adapter() got multiple values for argument 'adapter_name'The order of arguments in theadd_adapterfunction is incorrect. You should provideadapter_namefirst and thenpeft_config. Try it:model.add_adapter(peft_config=peft_config, adapter_name="t2")