Skip to content
This repository has been archived by the owner on Sep 12, 2024. It is now read-only.

Commit

Permalink
updated requirements and document reading functionality for progress …
Browse files Browse the repository at this point in the history
…display (#169)
  • Loading branch information
SeeknnDestroy authored Dec 1, 2023
1 parent 117491d commit 5e5a2a6
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion autollm/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
and vector databases, along with various utility functions.
"""

__version__ = '0.1.2'
__version__ = '0.1.3'
__author__ = 'safevideo'
__license__ = 'AGPL-3.0'

Expand Down
3 changes: 2 additions & 1 deletion autollm/utils/document_reading.py
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ def read_files_as_documents(
filename_as_id: bool = True,
recursive: bool = True,
required_exts: Optional[List[str]] = None,
show_progress: bool = True,
**kwargs) -> Sequence[Document]:
"""
Process markdown files to extract documents using SimpleDirectoryReader.
Expand Down Expand Up @@ -58,7 +59,7 @@ def read_files_as_documents(
f"Reading files {input_files}..")

# Read and process the documents
documents = reader.load_data()
documents = reader.load_data(show_progress=show_progress)

logger.info(f"Found {len(documents)} 'document(s)'.")
return documents
Expand Down
1 change: 0 additions & 1 deletion autollm/utils/pdf_reader.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,6 @@ def load_data(self, file_path: str, extra_info: dict = None) -> List[Document]:
# Convert the PosixPath object to a string before passing it to PDFMinerLoader
loader = PDFMinerLoader(str(file_path), extract_images=self.extract_images)

logger.info(f"Parsing pages of the PDF file: {file_path}..")
langchain_documents = loader.load() # This returns a list of langchain Document objects

# Convert langchain documents into llama-index documents
Expand Down
2 changes: 1 addition & 1 deletion requirements.txt
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
llama-index==0.9.4
llama-index==0.9.10
litellm==1.1.1
uvicorn
fastapi
Expand Down

0 comments on commit 5e5a2a6

Please sign in to comment.