KingZack commited on
Commit
f8b2c59
1 Parent(s): bc3e608

adding slider to max lenght

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -6,10 +6,10 @@ pipe = pipeline("text-generation", model=model_location)
6
 
7
  text = st.text_area('Give me ideas to generate a new Futurama episode...')
8
  value = st.slider("How long of a response do you want. The longer the much more time it takes",
9
- min_value=50, max_value=4444, value=100)
10
 
11
  if text:
12
- generated_response_object = pipe(text, max_length=int(value))
13
  actual_response = generated_response_object[0]['generated_text']
14
  st.text(actual_response)
15
 
 
6
 
7
  text = st.text_area('Give me ideas to generate a new Futurama episode...')
8
  value = st.slider("How long of a response do you want. The longer the much more time it takes",
9
+ min_value=69, max_value=4444, value=100)
10
 
11
  if text:
12
+ generated_response_object = pipe(text, max_length=600)
13
  actual_response = generated_response_object[0]['generated_text']
14
  st.text(actual_response)
15