shahules786 commited on
Commit
c1d0246
1 Parent(s): 21edae8

Update README.md

Browse files
Files changed (1) hide show
  1. README.md +3 -3
README.md CHANGED
@@ -9,15 +9,15 @@
9
 
10
  from peft import PeftModel
11
  from huggingface_hub import hf_hub_download
12
- from transformers import LlamaTokenizer, LlamaForCausalLM
13
  import json
14
 
15
  model_name = "shahules786/Redpajama-3B-orcastyle"
16
  config = hf_hub_download(repo_id=model_name, filename="adapter_config.json", local_dir=".")
17
  config = json.load(open("adapter_config.json"))
18
  base_model = config["base_model_name_or_path"]
19
- tokenizer = LlamaTokenizer.from_pretrained(model_name)
20
- model = LlamaForCausalLM.from_pretrained(base_model)
21
  model.resize_token_embeddings(len(self.tokenizer))
22
  model = PeftModel.from_pretrained(model, model_name).eval()
23
  tokenizer.padding_side = "left"
 
9
 
10
  from peft import PeftModel
11
  from huggingface_hub import hf_hub_download
12
+ from transformers import GPTNeoForCausalLM, AutoTokenizer
13
  import json
14
 
15
  model_name = "shahules786/Redpajama-3B-orcastyle"
16
  config = hf_hub_download(repo_id=model_name, filename="adapter_config.json", local_dir=".")
17
  config = json.load(open("adapter_config.json"))
18
  base_model = config["base_model_name_or_path"]
19
+ tokenizer = AutoTokenizer.from_pretrained(model_name)
20
+ model = GPTNeoForCausalLM.from_pretrained(base_model)
21
  model.resize_token_embeddings(len(self.tokenizer))
22
  model = PeftModel.from_pretrained(model, model_name).eval()
23
  tokenizer.padding_side = "left"