Spaces:
Runtime error
Runtime error
Updates
Browse files
app.py
CHANGED
|
@@ -40,7 +40,7 @@ prompt = ChatPromptTemplate.from_template(
|
|
| 40 |
""" Answer the questions based on the provided context only. Please provide the most accurate response based on the question <context> {context} <context> Questions:{input} """
|
| 41 |
)
|
| 42 |
embeddings = HuggingFaceEmbeddings(model_name="sentence-transformers/all-MiniLM-L6-v2")
|
| 43 |
-
loader = PyPDFLoader("
|
| 44 |
docs = loader.load()
|
| 45 |
text_splitter = CharacterTextSplitter(chunk_size=1000, chunk_overlap=0)
|
| 46 |
final_documents = text_splitter.split_documents(docs)
|
|
|
|
| 40 |
""" Answer the questions based on the provided context only. Please provide the most accurate response based on the question <context> {context} <context> Questions:{input} """
|
| 41 |
)
|
| 42 |
embeddings = HuggingFaceEmbeddings(model_name="sentence-transformers/all-MiniLM-L6-v2")
|
| 43 |
+
loader = PyPDFLoader("Document.pdf")
|
| 44 |
docs = loader.load()
|
| 45 |
text_splitter = CharacterTextSplitter(chunk_size=1000, chunk_overlap=0)
|
| 46 |
final_documents = text_splitter.split_documents(docs)
|