Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
@@ -6,7 +6,7 @@ import time
|
|
6 |
|
7 |
from langchain.chains import LLMChain, RetrievalQA
|
8 |
from langchain.chat_models import ChatOpenAI
|
9 |
-
from langchain.document_loaders import PyPDFLoader, WebBaseLoader,
|
10 |
from langchain.document_loaders.blob_loaders.youtube_audio import YoutubeAudioLoader
|
11 |
from langchain.document_loaders.generic import GenericLoader
|
12 |
from langchain.document_loaders.parsers import OpenAIWhisperParser
|
@@ -110,7 +110,7 @@ def add_file(history, file):
|
|
110 |
def create_directory_loader(file_type, directory_path):
|
111 |
#verscheidene Dokument loaders:
|
112 |
loaders = {
|
113 |
-
'.pdf':
|
114 |
'.word': UnstructuredWordDocumentLoader,
|
115 |
}
|
116 |
return DirectoryLoader(
|
|
|
6 |
|
7 |
from langchain.chains import LLMChain, RetrievalQA
|
8 |
from langchain.chat_models import ChatOpenAI
|
9 |
+
from langchain.document_loaders import PyPDFLoader, WebBaseLoader, UnstructuredWordDocumentLoader, DirectoryLoader
|
10 |
from langchain.document_loaders.blob_loaders.youtube_audio import YoutubeAudioLoader
|
11 |
from langchain.document_loaders.generic import GenericLoader
|
12 |
from langchain.document_loaders.parsers import OpenAIWhisperParser
|
|
|
110 |
def create_directory_loader(file_type, directory_path):
|
111 |
#verscheidene Dokument loaders:
|
112 |
loaders = {
|
113 |
+
'.pdf': PyPDFLoader,
|
114 |
'.word': UnstructuredWordDocumentLoader,
|
115 |
}
|
116 |
return DirectoryLoader(
|