Vihang28 commited on
Commit
0dc4a78
·
verified ·
1 Parent(s): 52197f8

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -2
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
- # output_text += f"Found '{search_term}' on page {page_num}:\n{text}\n\n"
 
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