Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -27,7 +27,7 @@ title = 'PDF Abstracter'
|
|
27 |
description = 'The model takes a PDF with an abstract as input and summarises it in one sentence that can be read and listened to. Please note that only PDFs with an abstract will work, otherwise there will be an error'
|
28 |
def abstract_summary(file):
|
29 |
# Set file path for uploaded file
|
30 |
-
file_path =
|
31 |
shutil.copyfile(file.name, file_path)
|
32 |
# Extract Abstract from PDF
|
33 |
pdf = readAbstract(file_path)
|
|
|
27 |
description = 'The model takes a PDF with an abstract as input and summarises it in one sentence that can be read and listened to. Please note that only PDFs with an abstract will work, otherwise there will be an error'
|
28 |
def abstract_summary(file):
|
29 |
# Set file path for uploaded file
|
30 |
+
file_path = os.path.basename(file)
|
31 |
shutil.copyfile(file.name, file_path)
|
32 |
# Extract Abstract from PDF
|
33 |
pdf = readAbstract(file_path)
|