sujitb commited on
Commit
05d88f5
1 Parent(s): ed6e9e8

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -1
app.py CHANGED
@@ -29,7 +29,7 @@ def query_from_pinecone(index,namespace, question_embedding, top_k=3):
29
  QUESTION=st.text_area('Ask a question -e.g How to prepare for Verbal section for CAT?') ##' How to prepare for Verbal section ?'
30
  question_embedding = bi_encoder.encode(QUESTION, convert_to_tensor=True)
31
  resp= query_from_pinecone(index,NAMESPACE, question_embedding.tolist(), 3)
32
- docresult= resp[0]['metadata']['text']
33
  #+ '\n*************\n'+ resp[1]['metadata']['text'] + '\n*************\n'+ resp[2]['metadata']['text']
34
 
35
  st.json(out)
 
29
  QUESTION=st.text_area('Ask a question -e.g How to prepare for Verbal section for CAT?') ##' How to prepare for Verbal section ?'
30
  question_embedding = bi_encoder.encode(QUESTION, convert_to_tensor=True)
31
  resp= query_from_pinecone(index,NAMESPACE, question_embedding.tolist(), 3)
32
+ out= resp[0]['metadata']['text']
33
  #+ '\n*************\n'+ resp[1]['metadata']['text'] + '\n*************\n'+ resp[2]['metadata']['text']
34
 
35
  st.json(out)