Spaces:
Build error
Build error
Update app.py
Browse files
app.py
CHANGED
|
@@ -133,7 +133,7 @@ def main():
|
|
| 133 |
# Create a button to generate questions
|
| 134 |
if st.button("Generate Questions"):
|
| 135 |
#Encode the input text using the tokenizer
|
| 136 |
-
input_ids = tokenizer.encode("generate questions: " +
|
| 137 |
# Use the T5 model to generate questions
|
| 138 |
question_ids = model.generate(input_ids)
|
| 139 |
# Decode the questions from the output ids using the tokenizer
|
|
|
|
| 133 |
# Create a button to generate questions
|
| 134 |
if st.button("Generate Questions"):
|
| 135 |
#Encode the input text using the tokenizer
|
| 136 |
+
input_ids = tokenizer.encode("generate questions: " + text_input2, return_tensors="pt")
|
| 137 |
# Use the T5 model to generate questions
|
| 138 |
question_ids = model.generate(input_ids)
|
| 139 |
# Decode the questions from the output ids using the tokenizer
|