Penality commited on
Commit
ed47330
·
verified ·
1 Parent(s): e308d30

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -1
app.py CHANGED
@@ -59,7 +59,7 @@ def store_document_data(PDF_FILE):
59
  with open(index_file, "rb") as f:
60
  response = requests.post(API_URL_EMBEDDINGS, files={"file": f})
61
 
62
- response = requests.post(API_URL_METADATA, json={"doc_index": doc_index})
63
 
64
  print("sent")
65
  except requests.exceptions.RequestException as e:
 
59
  with open(index_file, "rb") as f:
60
  response = requests.post(API_URL_EMBEDDINGS, files={"file": f})
61
 
62
+ response = requests.post(API_URL_METADATA, json={"doc_index": max(0, doc_index)})
63
 
64
  print("sent")
65
  except requests.exceptions.RequestException as e: