binqiangliu commited on
Commit
12d9c02
·
1 Parent(s): 5437781

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -2
app.py CHANGED
@@ -38,7 +38,7 @@ with st.sidebar:
38
  st.subheader("Upload your pdf Documents Here: ")
39
  pdf_files = st.file_uploader("Choose your PDF Files and Press OK", type=['pdf'], accept_multiple_files=True)
40
  if not pdf_files:
41
- st.warning("请上传文档文件")
42
  st.stop()
43
  else:
44
  uploadedfile_path=generate_random_string(20)
@@ -47,7 +47,8 @@ with st.sidebar:
47
  file_path = os.path.join(uploadedfile_path, pdf_file.name)
48
  with open(file_path, 'wb') as f:
49
  f.write(pdf_file.read())
50
- st.success(f"File '{pdf_file.name}' saved successfully.")
 
51
  if st.button('Process for QA'):
52
  try:
53
  start_1 = timeit.default_timer() # Start timer
 
38
  st.subheader("Upload your pdf Documents Here: ")
39
  pdf_files = st.file_uploader("Choose your PDF Files and Press OK", type=['pdf'], accept_multiple_files=True)
40
  if not pdf_files:
41
+ #st.warning("请上传文档文件")
42
  st.stop()
43
  else:
44
  uploadedfile_path=generate_random_string(20)
 
47
  file_path = os.path.join(uploadedfile_path, pdf_file.name)
48
  with open(file_path, 'wb') as f:
49
  f.write(pdf_file.read())
50
+ #st.success(f"File '{pdf_file.name}' saved successfully.")
51
+ print(f'文件已保存到:{file_path}') #NEWLY ADDED
52
  if st.button('Process for QA'):
53
  try:
54
  start_1 = timeit.default_timer() # Start timer