omitakahiro commited on
Commit
38705d5
1 Parent(s): f65c699

Update README.md

Browse files
Files changed (1) hide show
  1. README.md +3 -2
README.md CHANGED
@@ -14,7 +14,8 @@ Stockmark-100b-instruct-v0.1 is an instruction tuned version of [stockmark-100b]
14
 
15
  ```python
16
  import torch
17
- from transformers import AutoModelForCausalLM, AutoTokenizer
 
18
 
19
  prompt_template = """### 指示:
20
  {instruction}
@@ -23,7 +24,7 @@ prompt_template = """### 指示:
23
  """
24
 
25
  tokenizer = AutoTokenizer.from_pretrained("stockmark/stockmark-100b-instruct-v0.1")
26
- model = AutoModelForCausalLM.from_pretrained("stockmark/stockmark-100b-instruct-v0.1", device_map="auto", torch_dtype=torch.bfloat16)
27
 
28
  instruction = "生成AIとは?"
29
  prompt = prompt_template.format(instruction=instruction)
 
14
 
15
  ```python
16
  import torch
17
+ from transformers import AutoTokenizer
18
+ from peft improt AutoPeftModelForCausalLM
19
 
20
  prompt_template = """### 指示:
21
  {instruction}
 
24
  """
25
 
26
  tokenizer = AutoTokenizer.from_pretrained("stockmark/stockmark-100b-instruct-v0.1")
27
+ model = AutoPeftModelForCausalLM.from_pretrained("stockmark/stockmark-100b-instruct-v0.1", device_map="auto", torch_dtype=torch.bfloat16)
28
 
29
  instruction = "生成AIとは?"
30
  prompt = prompt_template.format(instruction=instruction)