AdityaTheDev commited on
Commit
c683a86
·
verified ·
1 Parent(s): 8e28d36

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -1
app.py CHANGED
@@ -50,7 +50,9 @@ if query:
50
  temp.text("Searching for memories..!")
51
  query_embedding = model.encode(query).astype('float32').reshape(1, -1) # Encode the query
52
  k = 6 # Number of nearest neighbors to retrieve
53
- distances, indices = index.search(query_embedding, k)
 
 
54
  retrieved_chunks = [chunks[i] for i in indices[0]]
55
  # # Use a prompt to generate a response with your language model
56
  # input_prompt = f"""Given the question and
 
50
  temp.text("Searching for memories..!")
51
  query_embedding = model.encode(query).astype('float32').reshape(1, -1) # Encode the query
52
  k = 6 # Number of nearest neighbors to retrieve
53
+ #distances, indices = index.search(query_embedding, k)
54
+ arr=index.search(query_embedding, k)
55
+ st.write(arr)
56
  retrieved_chunks = [chunks[i] for i in indices[0]]
57
  # # Use a prompt to generate a response with your language model
58
  # input_prompt = f"""Given the question and