Kendamarron commited on
Commit
a86a677
·
verified ·
1 Parent(s): dd737ed

Update README.md

Browse files
Files changed (1) hide show
  1. README.md +3 -3
README.md CHANGED
@@ -17,13 +17,13 @@ language:
17
 
18
  ```python
19
  from transformers import AutoModelForCausalLM, AutoTokenizer
 
20
  model_path = "Rakuten/RakutenAI-7B-instruct"
21
  tokenizer = AutoTokenizer.from_pretrained(model_path)
22
- model = AutoModelForCausalLM.from_pretrained(model_path, torch_dtype="auto", device_map="auto")
23
  model = PeftModel.from_pretrained(
24
  model,
25
- "Kendamarron/math-problem-generator_RakutenAI-7B-instruct_lora",
26
- torch_dtype=torch.bfloat16
27
  )
28
  model.eval()
29
 
 
17
 
18
  ```python
19
  from transformers import AutoModelForCausalLM, AutoTokenizer
20
+ from peft import PeftModel
21
  model_path = "Rakuten/RakutenAI-7B-instruct"
22
  tokenizer = AutoTokenizer.from_pretrained(model_path)
23
+ model = AutoModelForCausalLM.from_pretrained(model_path, torch_dtype=torch.bfloat16, device_map="auto")
24
  model = PeftModel.from_pretrained(
25
  model,
26
+ "Kendamarron/math-problem-generator_RakutenAI-7B-instruct_lora"
 
27
  )
28
  model.eval()
29