bstraehle commited on
Commit
686ec52
·
verified ·
1 Parent(s): 8eb3a27

Update crew.py

Browse files
Files changed (1) hide show
  1. crew.py +3 -3
crew.py CHANGED
@@ -359,10 +359,10 @@ def run_crew(question, file_path):
359
  if file_path:
360
  df = read_file(file_path)
361
 
362
- if df:
363
- question = f"{question} File data: {df.to_string()}" # load data due to sandbox contraints
364
- else:
365
  question = f"{question} File path: {file_path}."
 
 
366
 
367
  print("###")
368
  print(question)
 
359
  if file_path:
360
  df = read_file(file_path)
361
 
362
+ if df.empty:
 
 
363
  question = f"{question} File path: {file_path}."
364
+ else:
365
+ question = f"{question} File data: {df.to_string()}" # load data due to sandbox contraints
366
 
367
  print("###")
368
  print(question)