asadmasad commited on
Commit
8d1e072
1 Parent(s): 09e76dc

Update handler.py

Browse files
Files changed (1) hide show
  1. handler.py +2 -2
handler.py CHANGED
@@ -39,9 +39,9 @@ class EndpointHandler:
39
 
40
  # pass inputs with all kwargs in data
41
  if parameters is not None:
42
- outputs = self.model.generate(**inputs, **parameters)
43
  else:
44
- outputs = self.model.generate(**inputs)
45
 
46
  # postprocess the prediction
47
  prediction = self.tokenizer.decode(outputs[0], skip_special_tokens=True)
 
39
 
40
  # pass inputs with all kwargs in data
41
  if parameters is not None:
42
+ outputs = self.model.generate(**inputs, max_new_tokens=880, **parameters)
43
  else:
44
+ outputs = self.model.generate(**inputs, max_new_tokens=880)
45
 
46
  # postprocess the prediction
47
  prediction = self.tokenizer.decode(outputs[0], skip_special_tokens=True)