Update app.py
Browse files
app.py
CHANGED
|
@@ -31,13 +31,11 @@ st.divider()
|
|
| 31 |
def search_index(query):
|
| 32 |
index = pinecone.Index("scotus")
|
| 33 |
vector = model.encode([query]).tolist()
|
| 34 |
-
st.write(vector)
|
| 35 |
st.write(index.query(vector=vector,top_k=10,include_values=False,include_metadata=True))
|
| 36 |
|
| 37 |
|
| 38 |
search = st.text_input('Search', placeholder='First Amendment cannot protect libel')
|
| 39 |
-
|
| 40 |
-
search_index(query=search)
|
| 41 |
|
| 42 |
|
| 43 |
|
|
|
|
| 31 |
def search_index(query):
|
| 32 |
index = pinecone.Index("scotus")
|
| 33 |
vector = model.encode([query]).tolist()
|
|
|
|
| 34 |
st.write(index.query(vector=vector,top_k=10,include_values=False,include_metadata=True))
|
| 35 |
|
| 36 |
|
| 37 |
search = st.text_input('Search', placeholder='First Amendment cannot protect libel')
|
| 38 |
+
search_index(query=search)
|
|
|
|
| 39 |
|
| 40 |
|
| 41 |
|