jscore2023 commited on
Commit
794244a
1 Parent(s): ab8d3b7

Update handler.py

Browse files
Files changed (1) hide show
  1. handler.py +2 -2
handler.py CHANGED
@@ -13,9 +13,9 @@ device = "cuda" if torch.cuda.is_available() else "cpu"
13
 
14
  class EndpointHandler():
15
  def __init__(self, path=""):
16
- config = PeftConfig.from_pretrained(path)
17
  model = AutoModelForCausalLM.from_pretrained("vilsonrodrigues/falcon-7b-instruct-sharded", device_map={"":0}, trust_remote_code=True, torch_dtype=torch.float16)
18
- self.tokenizer = AutoTokenizer.from_pretrained("vilsonrodrigues/falcon-7b-instruct-sharded")
19
  # Load the Lora model
20
  self.model = PeftModel.from_pretrained(model, "jscore2023/falcon-7b-3")
21
 
 
13
 
14
  class EndpointHandler():
15
  def __init__(self, path=""):
16
+ config = PeftConfig.from_pretrained("jscore2023/falcon-7b-3")
17
  model = AutoModelForCausalLM.from_pretrained("vilsonrodrigues/falcon-7b-instruct-sharded", device_map={"":0}, trust_remote_code=True, torch_dtype=torch.float16)
18
+ self.tokenizer = AutoTokenizer.from_pretrained("jscore2023/falcon-7b-3")
19
  # Load the Lora model
20
  self.model = PeftModel.from_pretrained(model, "jscore2023/falcon-7b-3")
21