unclemusclez commited on
Commit
0a7c76d
·
verified ·
1 Parent(s): 8a70d34

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -18,7 +18,7 @@ from textwrap import dedent
18
 
19
  HF_TOKEN = os.environ.get("HF_TOKEN")
20
  OLLAMA_USERNAME = os.environ.get("OLLAMA_USERNAME")
21
-
22
 
23
  def process_model(model_id, q_method, latest, oauth_token: gr.OAuthToken | None):
24
  if oauth_token.token is None:
@@ -133,7 +133,7 @@ with gr.Blocks(css=css) as demo:
133
  description=f"cat ~/.ollama/id_ed25519.pub",
134
  api_name=False
135
  )
136
-
137
 
138
  def restart_space():
139
  HfApi().restart_space(repo_id="unclemusclez/ollamafy", token=HF_TOKEN, factory_reboot=True)
 
18
 
19
  HF_TOKEN = os.environ.get("HF_TOKEN")
20
  OLLAMA_USERNAME = os.environ.get("OLLAMA_USERNAME")
21
+ username = whoami(oauth_token.token)["name"]
22
 
23
  def process_model(model_id, q_method, latest, oauth_token: gr.OAuthToken | None):
24
  if oauth_token.token is None:
 
133
  description=f"cat ~/.ollama/id_ed25519.pub",
134
  api_name=False
135
  )
136
+
137
 
138
  def restart_space():
139
  HfApi().restart_space(repo_id="unclemusclez/ollamafy", token=HF_TOKEN, factory_reboot=True)