taaha3244 commited on
Commit
9c98b1f
1 Parent(s): ace378a

Update preprocess.py

Browse files
Files changed (1) hide show
  1. preprocess.py +4 -1
preprocess.py CHANGED
@@ -5,7 +5,10 @@ from langchain_community.document_loaders import UnstructuredAPIFileLoader
5
 
6
  def load_documents_OCR(file_path, unstructured_api):
7
  """Load documents that require OCR via unstructured."""
8
- loader = UnstructuredAPIFileLoader(file_path=file_path, api_key=unstructured_api,mode='paged')
 
 
 
9
  documents = loader.load()
10
  return documents
11
 
 
5
 
6
  def load_documents_OCR(file_path, unstructured_api):
7
  """Load documents that require OCR via unstructured."""
8
+ loader = UnstructuredAPIFileLoader(file_path=file_path,
9
+ api_key=unstructured_api,
10
+ url='https://paf-stkjy1b5.api.unstructuredapp.io/',
11
+ mode='paged')
12
  documents = loader.load()
13
  return documents
14