Skip to content

Commit 7a78221

Browse files
authored
update peft code snippet (#1048)
this pr fixes #1047
1 parent fa66cb3 commit 7a78221

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

packages/tasks/src/model-libraries-snippets.ts

+1-2
Original file line numberDiff line numberDiff line change
@@ -933,10 +933,9 @@ export const peft = (model: ModelData): string[] => {
933933
}
934934

935935
return [
936-
`from peft import PeftModel, PeftConfig
936+
`from peft import PeftModel
937937
from transformers import AutoModelFor${pefttask}
938938
939-
config = PeftConfig.from_pretrained("${model.id}")
940939
base_model = AutoModelFor${pefttask}.from_pretrained("${peftBaseModel}")
941940
model = PeftModel.from_pretrained(base_model, "${model.id}")`,
942941
];

0 commit comments

Comments
 (0)