Update app.py
Browse files
app.py
CHANGED
@@ -101,8 +101,11 @@ def generate_text(prompt, system_prompt):
|
|
101 |
raise gr.Error(str(e))
|
102 |
|
103 |
def setAccount(token, accountId):
|
104 |
-
global API_TOKEN
|
105 |
-
global ACCOUNT_ID
|
|
|
|
|
|
|
106 |
|
107 |
def gen(prompt: str, system_prompt: str, token: str, accountId: str):
|
108 |
setAccount(token, accountId)
|
|
|
101 |
raise gr.Error(str(e))
|
102 |
|
103 |
def setAccount(token, accountId):
|
104 |
+
global API_TOKEN
|
105 |
+
global ACCOUNT_ID
|
106 |
+
|
107 |
+
API_TOKEN = token
|
108 |
+
ACCOUNT_ID = accountId
|
109 |
|
110 |
def gen(prompt: str, system_prompt: str, token: str, accountId: str):
|
111 |
setAccount(token, accountId)
|