sonoisa commited on
Commit
d34166f
1 Parent(s): 921ce7d

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -1
app.py CHANGED
@@ -172,7 +172,7 @@ if search_buttion or prev_query != str(query_input):
172
  query_embedding = model.encode([query]).numpy()
173
 
174
  distances = scipy.spatial.distance.cdist(
175
- query_embedding, sentence_vectors, metric="cosine"
176
  )[0]
177
 
178
  results = zip(range(len(distances)), distances)
 
172
  query_embedding = model.encode([query]).numpy()
173
 
174
  distances = scipy.spatial.distance.cdist(
175
+ query_embedding, sentence_vectors, metric="euclidean"
176
  )[0]
177
 
178
  results = zip(range(len(distances)), distances)