Update app.py
Browse files
app.py
CHANGED
@@ -56,9 +56,8 @@ def main():
|
|
56 |
num_results = st.sidebar.slider("Number of search results", 1, 50, 5)
|
57 |
|
58 |
vector = query([user_input])
|
59 |
-
st.write(f"**vector**: {vector}")
|
60 |
# Fetch results
|
61 |
-
if
|
62 |
# Get paper IDs
|
63 |
_, I = faiss_index.search(np.array(vector).astype("float32"), k=num_results)
|
64 |
|
|
|
56 |
num_results = st.sidebar.slider("Number of search results", 1, 50, 5)
|
57 |
|
58 |
vector = query([user_input])
|
|
|
59 |
# Fetch results
|
60 |
+
if user_input:
|
61 |
# Get paper IDs
|
62 |
_, I = faiss_index.search(np.array(vector).astype("float32"), k=num_results)
|
63 |
|