slowly
Browse files- App/Embedding/utils/Initialize.py +2 -1
- App/app.py +1 -1
App/Embedding/utils/Initialize.py
CHANGED
|
@@ -62,5 +62,6 @@ def search(query: str, task_id: str):
|
|
| 62 |
|
| 63 |
|
| 64 |
def encode(temp: list[Document]):
|
| 65 |
-
|
|
|
|
| 66 |
# return embeddings.embed_documents(texts = [d.page_content for d in temp])
|
|
|
|
| 62 |
|
| 63 |
|
| 64 |
def encode(temp: list[Document]):
|
| 65 |
+
for doc in temp:
|
| 66 |
+
docsearch.add_documents([doc])
|
| 67 |
# return embeddings.embed_documents(texts = [d.page_content for d in temp])
|
App/app.py
CHANGED
|
@@ -48,7 +48,7 @@ def authjwt_exception_handler(request: Request, exc: AuthJWTException):
|
|
| 48 |
|
| 49 |
@app.on_event("startup")
|
| 50 |
async def startup_event():
|
| 51 |
-
|
| 52 |
# await upload_bot.start()
|
| 53 |
# await models.create_all()
|
| 54 |
# models.metadata.create_all()
|
|
|
|
| 48 |
|
| 49 |
@app.on_event("startup")
|
| 50 |
async def startup_event():
|
| 51 |
+
await bot.start()
|
| 52 |
# await upload_bot.start()
|
| 53 |
# await models.create_all()
|
| 54 |
# models.metadata.create_all()
|