Spaces:
Sleeping
Sleeping
Update src/app.py
Browse files- src/app.py +6 -3
src/app.py
CHANGED
@@ -1,10 +1,13 @@
|
|
1 |
import streamlit as st
|
2 |
-
import os
|
3 |
-
import
|
4 |
-
import requests
|
5 |
|
6 |
# Retrieve your hidden script from the environment variable
|
7 |
app_url = os.environ.get("APP_URL", "")
|
|
|
|
|
|
|
|
|
8 |
|
9 |
def execute_remote_script(url: str): # code_str: str
|
10 |
"""
|
|
|
1 |
import streamlit as st
|
2 |
+
import os,types,requests
|
3 |
+
from huggingface_hub import login
|
|
|
4 |
|
5 |
# Retrieve your hidden script from the environment variable
|
6 |
app_url = os.environ.get("APP_URL", "")
|
7 |
+
token = os.environ.get("HF_TOKEN", "")
|
8 |
+
|
9 |
+
# Pass the token as a string
|
10 |
+
login(token=token)
|
11 |
|
12 |
def execute_remote_script(url: str): # code_str: str
|
13 |
"""
|