Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
@@ -64,7 +64,7 @@ def compute_embeddings(selected_task, input_text):
|
|
64 |
except KeyError:
|
65 |
print(f"Selected task not found: {selected_task}")
|
66 |
return f"Error: Task '{selected_task}' not found. Please select a valid task."
|
67 |
-
max_length =
|
68 |
processed_texts = [f'Instruct: {task_description}\nQuery: {input_text}']
|
69 |
|
70 |
batch_dict = tokenizer(processed_texts, max_length=max_length - 1, return_attention_mask=False, padding=False, truncation=True)
|
|
|
64 |
except KeyError:
|
65 |
print(f"Selected task not found: {selected_task}")
|
66 |
return f"Error: Task '{selected_task}' not found. Please select a valid task."
|
67 |
+
max_length = 2048
|
68 |
processed_texts = [f'Instruct: {task_description}\nQuery: {input_text}']
|
69 |
|
70 |
batch_dict = tokenizer(processed_texts, max_length=max_length - 1, return_attention_mask=False, padding=False, truncation=True)
|