Update app.py
Browse files
app.py
CHANGED
@@ -139,8 +139,7 @@ def create_vector_db(final_items):
|
|
139 |
global db
|
140 |
client = chromadb.Client()
|
141 |
collection_name = "BioModelsRAG"
|
142 |
-
|
143 |
-
db = client.get_collection(name=collection_name, embedding_function="all-MiniLM-L6-v2")
|
144 |
|
145 |
# Initialize Llama model
|
146 |
llm = Llama.from_pretrained(
|
|
|
139 |
global db
|
140 |
client = chromadb.Client()
|
141 |
collection_name = "BioModelsRAG"
|
142 |
+
db = client.get_or_create_collection(name=collection_name, embedding_function = "all-MiniLM-L6-v2")
|
|
|
143 |
|
144 |
# Initialize Llama model
|
145 |
llm = Llama.from_pretrained(
|