Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -157,7 +157,7 @@ def user_input(user_question, api_key):
|
|
157 |
"""
|
158 |
|
159 |
# Tokenize the prompt
|
160 |
-
inputs = tokenizer(prompt_template, return_tensors="pt", truncation=True)
|
161 |
|
162 |
# Generate the transformed response using the Hugging Face model
|
163 |
outputs = model.generate(**inputs)
|
|
|
157 |
"""
|
158 |
|
159 |
# Tokenize the prompt
|
160 |
+
inputs = tokenizer(prompt_template, return_tensors="pt", truncation=True,max_length=512)
|
161 |
|
162 |
# Generate the transformed response using the Hugging Face model
|
163 |
outputs = model.generate(**inputs)
|