poiccard commited on
Commit
344dbbf
1 Parent(s): 734032e

Update handler.py

Browse files
Files changed (1) hide show
  1. handler.py +3 -1
handler.py CHANGED
@@ -18,7 +18,9 @@ class EndpointHandler():
18
 
19
  # get inputs
20
  inputs = data.pop("inputs",data)
21
- text = self.prompt_ar.format_map({'Question':inputs})
 
 
22
 
23
  input_ids = self.tokenizer(text, return_tensors="pt").input_ids
24
  inputs = input_ids.to(self.device)
 
18
 
19
  # get inputs
20
  inputs = data.pop("inputs",data)
21
+ # text = self.prompt_ar.format_map({'Question':inputs})
22
+ # the prompt will be preapred on the backend fully
23
+ text = inputs
24
 
25
  input_ids = self.tokenizer(text, return_tensors="pt").input_ids
26
  inputs = input_ids.to(self.device)