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