Patrik Stano commited on
Commit
f802847
·
1 Parent(s): d652a9d

fix generation bug

Browse files
Files changed (1) hide show
  1. app.py +1 -1
app.py CHANGED
@@ -14,7 +14,7 @@ def predict(text_input):
14
  "max_length": input_length + 10 # Set your desired maximum length
15
  }
16
  try:
17
- result = model_pipeline(text_input)
18
  # Extract and return the generated text
19
  return result[0]["generated_text"]
20
  except Exception as e:
 
14
  "max_length": input_length + 10 # Set your desired maximum length
15
  }
16
  try:
17
+ result = model_pipeline(text_input, **generation_parameters)
18
  # Extract and return the generated text
19
  return result[0]["generated_text"]
20
  except Exception as e: