umarigan commited on
Commit
3f2b399
1 Parent(s): 0164e97

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -3
app.py CHANGED
@@ -22,14 +22,14 @@ def process_pdf(pdf_path):
22
  # Open the PDF
23
  doc = fitz.open(pdf_path)
24
  texts = [page.get_text() for page in doc]
25
- logging.info("PDF processed successfully.")
26
  return " ".join(texts)
27
 
28
  def create_embeddings(text):
29
- logging.info("Creating embeddings.")
30
  sentences = text.split(". ") # A simple split; consider a more robust sentence splitter
31
  embeddings = model.encode(sentences)
32
- logging.info("Embeddings created successfully.")
33
  return embeddings, sentences
34
 
35
  def generate_plot(query, pdf_file):
 
22
  # Open the PDF
23
  doc = fitz.open(pdf_path)
24
  texts = [page.get_text() for page in doc]
25
+ print("PDF processed successfully.")
26
  return " ".join(texts)
27
 
28
  def create_embeddings(text):
29
+ print("Creating embeddings.")
30
  sentences = text.split(". ") # A simple split; consider a more robust sentence splitter
31
  embeddings = model.encode(sentences)
32
+ print("Embeddings created successfully.")
33
  return embeddings, sentences
34
 
35
  def generate_plot(query, pdf_file):