Spaces:
Paused
Paused
fix bugs
Browse files
app.py
CHANGED
@@ -97,12 +97,13 @@ def inference(
|
|
97 |
top_p,
|
98 |
repetition_penalty,
|
99 |
temperature,
|
|
|
100 |
):
|
101 |
if args.max_gradio_length > 0 and len(text) > args.max_gradio_length:
|
102 |
return (
|
103 |
None,
|
104 |
None,
|
105 |
-
|
106 |
args.max_gradio_length
|
107 |
),
|
108 |
)
|
|
|
97 |
top_p,
|
98 |
repetition_penalty,
|
99 |
temperature,
|
100 |
+
streaming=False
|
101 |
):
|
102 |
if args.max_gradio_length > 0 and len(text) > args.max_gradio_length:
|
103 |
return (
|
104 |
None,
|
105 |
None,
|
106 |
+
"Text is too long, please keep it under {} characters.".format(
|
107 |
args.max_gradio_length
|
108 |
),
|
109 |
)
|