YchKhan commited on
Commit
fb218a5
1 Parent(s): 8de8b76

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -1
app.py CHANGED
@@ -439,7 +439,7 @@ def ask_df(df, api_key, model, ui_session_id):
439
  question = row.iloc[-1]
440
  print(f"Question: {question}")
441
  if len(question)<2:
442
- question = df.at[index-1, question_column].split("\n---\n")[0]
443
  db_folder = "/".join([session_folder, row["File name"]])
444
  db = FAISS.load_local(db_folder,embeddings)
445
  docs = db.similarity_search(question)
 
439
  question = row.iloc[-1]
440
  print(f"Question: {question}")
441
  if len(question)<2:
442
+ question = df.at[0, question_column].split("\n---\n")[0]
443
  db_folder = "/".join([session_folder, row["File name"]])
444
  db = FAISS.load_local(db_folder,embeddings)
445
  docs = db.similarity_search(question)