alexkueck commited on
Commit
323f593
1 Parent(s): 087c0eb

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +5 -4
app.py CHANGED
@@ -134,9 +134,8 @@ def load_vectorstore_and_mapping():
134
  # Beim Start der Anwendung - Vektorstore laden!!!!
135
  ###########################################
136
  print("Vektorstore laden.........................")
137
- vektordatenbank = None
138
  #die Variablen: vektordatenbank, PREPROCESSED_SPLITS, ORGINAL_SPLITS und das Mapping werden neu gesetzt global!!!!
139
- #load_vectorstore_and_mapping()
140
 
141
 
142
  #################################################
@@ -442,9 +441,11 @@ def upload_pdf(files):
442
  if os.path.exists(upload_path):
443
  os.remove(upload_path)
444
  print("altes File removed.................")
445
-
 
 
446
  # Datei zum Hugging Face Space hochladen
447
- upload_file_to_huggingface(file.name, upload_path)
448
 
449
  except Exception as e:
450
  logging.error(f"Error uploading file {file.name}: {e}")
 
134
  # Beim Start der Anwendung - Vektorstore laden!!!!
135
  ###########################################
136
  print("Vektorstore laden.........................")
 
137
  #die Variablen: vektordatenbank, PREPROCESSED_SPLITS, ORGINAL_SPLITS und das Mapping werden neu gesetzt global!!!!
138
+ load_vectorstore_and_mapping()
139
 
140
 
141
  #################################################
 
441
  if os.path.exists(upload_path):
442
  os.remove(upload_path)
443
  print("altes File removed.................")
444
+
445
+ print("file.name.............."+str(file.name))
446
+ print("upload_path.............."+str(upload_path))
447
  # Datei zum Hugging Face Space hochladen
448
+ #upload_file_to_huggingface(file.name, upload_path)
449
 
450
  except Exception as e:
451
  logging.error(f"Error uploading file {file.name}: {e}")