pdf
PDF tools.
Functions:
-
extract_text_from_pdf–Extract text from a PDF file using pypdf.
-
is_pdf–Check if a file is a PDF by reading its header.
extract_text_from_pdf
Extract text from a PDF file using pypdf.
The result is the same as the one returned by PyPDFLoader.
Source code in src/rago/retrieval/tools/pdf.py
32 33 34 35 36 37 38 39 40 41 42 43 44 | |
is_pdf
Check if a file is a PDF by reading its header.
Parameters:
-
file_path(str) –Path to the file to be checked.
Returns:
-
bool–True if the file is a PDF, False otherwise.
Source code in src/rago/retrieval/tools/pdf.py
10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 | |