Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -22,8 +22,9 @@ def final_result(pdf_file, search_term):
|
|
22 |
output_text = ""
|
23 |
if results:
|
24 |
for page_num, text in results:
|
25 |
-
output_text += f"Found \033[1m'{search_term}'\033[0m on page {page_num}:\n{text}\n\n"
|
26 |
-
|
|
|
27 |
else:
|
28 |
output_text = f"No results found for '{search_term}'."
|
29 |
return output_text
|
|
|
22 |
output_text = ""
|
23 |
if results:
|
24 |
for page_num, text in results:
|
25 |
+
# output_text += f"Found \033[1m'{search_term}'\033[0m on page {page_num}:\n{text}\n\n"
|
26 |
+
output_text += f'''
|
27 |
+
Found '{search_term}' on page {page_num}:\n{text}\n\n'''
|
28 |
else:
|
29 |
output_text = f"No results found for '{search_term}'."
|
30 |
return output_text
|