Spaces:
Sleeping
Sleeping
Fixing for Chorus
Browse files
app.py
CHANGED
|
@@ -66,6 +66,9 @@ def generate_request_local(authority, kw1, kw2, kw3):
|
|
| 66 |
# Tokenize the input prompt
|
| 67 |
inputs = tokenizer(prompt, return_tensors="pt").to(model.device)
|
| 68 |
|
|
|
|
|
|
|
|
|
|
| 69 |
# Set generation parameters
|
| 70 |
generation_params = {
|
| 71 |
"max_new_tokens": 250,
|
|
|
|
| 66 |
# Tokenize the input prompt
|
| 67 |
inputs = tokenizer(prompt, return_tensors="pt").to(model.device)
|
| 68 |
|
| 69 |
+
if 'token_type_ids' in inputs:
|
| 70 |
+
del inputs['token_type_ids']
|
| 71 |
+
|
| 72 |
# Set generation parameters
|
| 73 |
generation_params = {
|
| 74 |
"max_new_tokens": 250,
|