Francesco-A commited on
Commit
698a434
1 Parent(s): fe28740

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -1
app.py CHANGED
@@ -77,7 +77,8 @@ contexts = [
77
  # Function to find similar answers in a list of contexts
78
  def QA_similarity(question, contexts, n_answers=1):
79
 
80
- contexts = contexts.iloc[:,0].to_list()
 
81
 
82
  # to use 'clips/mfaq' questions need to be prepended with <Q>, and answers with <A>.
83
  question = "<Q>"+question
 
77
  # Function to find similar answers in a list of contexts
78
  def QA_similarity(question, contexts, n_answers=1):
79
 
80
+ context_df = pd.DataFrame(contexts,columns=['Context'])
81
+ contexts = context_df.iloc[:,0].to_list()
82
 
83
  # to use 'clips/mfaq' questions need to be prepended with <Q>, and answers with <A>.
84
  question = "<Q>"+question