Update app.py
Browse files
app.py
CHANGED
@@ -17,9 +17,9 @@ from langchain_community.document_loaders.blob_loaders.youtube_audio import Yout
|
|
17 |
#from langchain.document_loaders import GenericLoader
|
18 |
from langchain.schema import AIMessage, HumanMessage
|
19 |
from langchain_community.llms import HuggingFaceHub
|
20 |
-
|
21 |
from langchain_community.llms import HuggingFaceTextGenInference
|
22 |
-
from langchain_community.embeddings import HuggingFaceInstructEmbeddings, HuggingFaceEmbeddings, HuggingFaceBgeEmbeddings, HuggingFaceInferenceAPIEmbeddings
|
23 |
from langchain.prompts import PromptTemplate
|
24 |
from langchain.text_splitter import RecursiveCharacterTextSplitter
|
25 |
from langchain_community.vectorstores import Chroma
|
@@ -268,7 +268,7 @@ def generate_auswahl(prompt_in, file, file_history, chatbot, history, anzahl_doc
|
|
268 |
print("db neu aufbauen!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!1")
|
269 |
splits = document_loading_splitting()
|
270 |
if splits:
|
271 |
-
print("hier...............................")
|
272 |
vektordatenbank, retriever = document_storage_chroma(splits)
|
273 |
print("db done............................")
|
274 |
|
|
|
17 |
#from langchain.document_loaders import GenericLoader
|
18 |
from langchain.schema import AIMessage, HumanMessage
|
19 |
from langchain_community.llms import HuggingFaceHub
|
20 |
+
from langchain_huggingface import HuggingFaceEmbeddings
|
21 |
from langchain_community.llms import HuggingFaceTextGenInference
|
22 |
+
#from langchain_community.embeddings import HuggingFaceInstructEmbeddings, HuggingFaceEmbeddings, HuggingFaceBgeEmbeddings, HuggingFaceInferenceAPIEmbeddings
|
23 |
from langchain.prompts import PromptTemplate
|
24 |
from langchain.text_splitter import RecursiveCharacterTextSplitter
|
25 |
from langchain_community.vectorstores import Chroma
|
|
|
268 |
print("db neu aufbauen!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!1")
|
269 |
splits = document_loading_splitting()
|
270 |
if splits:
|
271 |
+
print("hier..............................."+str(splits))
|
272 |
vektordatenbank, retriever = document_storage_chroma(splits)
|
273 |
print("db done............................")
|
274 |
|