Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
@@ -8,6 +8,9 @@ from langchain.text_splitter import RecursiveCharacterTextSplitter
|
|
8 |
from langchain.vectorstores import FAISS
|
9 |
from langchain.memory import ConversationBufferMemory
|
10 |
|
|
|
|
|
|
|
11 |
# Function to load documents
|
12 |
def load_documents():
|
13 |
loader = DirectoryLoader('data/', glob="*.pdf", loader_cls=PyPDFLoader)
|
|
|
8 |
from langchain.vectorstores import FAISS
|
9 |
from langchain.memory import ConversationBufferMemory
|
10 |
|
11 |
+
from huggingface_hub import login
|
12 |
+
login(token =st.secrets["HF"])
|
13 |
+
|
14 |
# Function to load documents
|
15 |
def load_documents():
|
16 |
loader = DirectoryLoader('data/', glob="*.pdf", loader_cls=PyPDFLoader)
|