Redmind commited on
Commit
7ed1b94
·
verified ·
1 Parent(s): b0b035b

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -0
app.py CHANGED
@@ -1256,6 +1256,8 @@ def create_pdf(name,id):
1256
 
1257
  repo_id = "Redmind/NewageNXTGPT"
1258
  file_output=f"assets/{output_file_name}"
 
 
1259
  api.upload_file(path_or_fileobj=output_file_name, repo_id=repo_id, repo_type= "space", path_in_repo=file_output)
1260
  return f"{output_file_name} is created successfully."
1261
 
 
1256
 
1257
  repo_id = "Redmind/NewageNXTGPT"
1258
  file_output=f"assets/{output_file_name}"
1259
+ from huggingface_hub import HfApi
1260
+ api = HfApi()
1261
  api.upload_file(path_or_fileobj=output_file_name, repo_id=repo_id, repo_type= "space", path_in_repo=file_output)
1262
  return f"{output_file_name} is created successfully."
1263