3v324v23 commited on
Commit
fb5904b
1 Parent(s): 4c0c8f1

update file path

Browse files
Files changed (1) hide show
  1. app.py +4 -1
app.py CHANGED
@@ -9,6 +9,9 @@ import re
9
 
10
  import chinese_converter
11
 
 
 
 
12
  # %%
13
  #Load the LLM model and pipeline directly
14
  llm_model_name="Qwen/Qwen1.5-0.5B-Chat"
@@ -293,7 +296,7 @@ with gr.Blocks() as demo:
293
  # flagging_options=["Inappropriate"],allow_flagging="never",
294
  # title="aaa",description="aaa",article="aaa")
295
  demo.queue(api_open=False)
296
- demo.launch(show_api=False)
297
 
298
 
299
  # %%
 
9
 
10
  import chinese_converter
11
 
12
+ import pathlib
13
+ current_path=str(pathlib.Path(__file__).parent.resolve())
14
+
15
  # %%
16
  #Load the LLM model and pipeline directly
17
  llm_model_name="Qwen/Qwen1.5-0.5B-Chat"
 
296
  # flagging_options=["Inappropriate"],allow_flagging="never",
297
  # title="aaa",description="aaa",article="aaa")
298
  demo.queue(api_open=False)
299
+ demo.launch(show_api=False,allowed_paths=[current_path+"/data/"])
300
 
301
 
302
  # %%