chenlei1983 commited on
Commit
cdc3a53
1 Parent(s): 8627484

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -3
app.py CHANGED
@@ -4,7 +4,7 @@ from git_commd import GitCommandWrapper
4
  from typing import List, Optional
5
 
6
  HF_TOKEN=os.environ['HF_TOKEN'] if 'HF_TOKEN' in os.environ else ''
7
-
8
 
9
  def get_cache_dir():
10
  from random_word import RandomWords
@@ -103,7 +103,7 @@ This space uploads model from WiseModel to Huggingface.
103
  - Click submit then watch for output in container log for progress.
104
  - Create README.md file (since the metadata is not compatible with HF)
105
  ''')
106
- wisemodel_token= gr.Textbox(label="wisemodel user git token")
107
  wisemodel_link = gr.Textbox(label="Copy the git download link from the model detail page of wisemodel ")
108
  hf_repo_id = gr.Textbox(label="Target HF Model Repo ID (case sensitive). \nPlease make sure that this model has already been created")
109
  with gr.Row():
@@ -112,7 +112,7 @@ This space uploads model from WiseModel to Huggingface.
112
  error = gr.Textbox(label="Error")
113
  output = gr.Textbox(label="Output")
114
 
115
- button.click(handle, [wisemodel_token,wisemodel_link, hf_repo_id], [output, error])
116
 
117
  if __name__ == "__main__":
118
  demo.launch(debug = True)
 
4
  from typing import List, Optional
5
 
6
  HF_TOKEN=os.environ['HF_TOKEN'] if 'HF_TOKEN' in os.environ else ''
7
+ WiseModel_TOKEN=os.environ['WM_TOKEN'] if 'WM_TOKEN' in os.environ else ''
8
 
9
  def get_cache_dir():
10
  from random_word import RandomWords
 
103
  - Click submit then watch for output in container log for progress.
104
  - Create README.md file (since the metadata is not compatible with HF)
105
  ''')
106
+
107
  wisemodel_link = gr.Textbox(label="Copy the git download link from the model detail page of wisemodel ")
108
  hf_repo_id = gr.Textbox(label="Target HF Model Repo ID (case sensitive). \nPlease make sure that this model has already been created")
109
  with gr.Row():
 
112
  error = gr.Textbox(label="Error")
113
  output = gr.Textbox(label="Output")
114
 
115
+ button.click(handle, [WiseModel_TOKEN,wisemodel_link, hf_repo_id], [output, error])
116
 
117
  if __name__ == "__main__":
118
  demo.launch(debug = True)