Spaces:
Running
Running
Update pdf_processing.py
Browse files- pdf_processing.py +1 -1
pdf_processing.py
CHANGED
|
@@ -12,7 +12,7 @@ def get_existing_pdf(filename="La Confession muette.pdf"):
|
|
| 12 |
|
| 13 |
def load_and_preprocess_pdf(pdf_path):
|
| 14 |
"""Load and preprocess the PDF text."""
|
| 15 |
-
with pdfplumber.open("
|
| 16 |
text = ""
|
| 17 |
for page in pdf.pages:
|
| 18 |
text += page.extract_text() or "" # Extraire le texte de chaque page
|
|
|
|
| 12 |
|
| 13 |
def load_and_preprocess_pdf(pdf_path):
|
| 14 |
"""Load and preprocess the PDF text."""
|
| 15 |
+
with pdfplumber.open("La Confession muette.pdf") as pdf:
|
| 16 |
text = ""
|
| 17 |
for page in pdf.pages:
|
| 18 |
text += page.extract_text() or "" # Extraire le texte de chaque page
|