bstraehle commited on
Commit
a355d52
·
verified ·
1 Parent(s): 37aad4f

Update utils/utils.py

Browse files
Files changed (1) hide show
  1. utils/utils.py +1 -5
utils/utils.py CHANGED
@@ -115,11 +115,7 @@ def read_pptx_text(file_path):
115
  def validate_input(question, openai_api_key, gemini_api_key, anthropic_api_key, file_name):
116
  is_valid = True
117
 
118
- if question.len() > 500 or
119
- openai_api_key.len() > 150 or
120
- gemini_api_key.len() > 150 or
121
- anthropic_api_key.len() > 150 or
122
- file_name > 150:
123
  is_valid = False
124
 
125
  # Allow: letters, numbers, spaces, basic punctuation, common symbols
 
115
  def validate_input(question, openai_api_key, gemini_api_key, anthropic_api_key, file_name):
116
  is_valid = True
117
 
118
+ if question.len() > 500 or openai_api_key.len() > 150 or gemini_api_key.len() > 150 or anthropic_api_key.len() > 150 or file_name > 150:
 
 
 
 
119
  is_valid = False
120
 
121
  # Allow: letters, numbers, spaces, basic punctuation, common symbols