Spaces:
Running
Running
app.py
CHANGED
|
@@ -21,11 +21,11 @@ def download_prompt_templates():
|
|
| 21 |
prompt = row[1].strip('"')
|
| 22 |
prompt_templates[act] = prompt
|
| 23 |
|
| 24 |
-
# prompt_templates = dict(sorted(prompt_templates.items(), key=lambda item: item[0]))
|
| 25 |
except requests.exceptions.RequestException as e:
|
| 26 |
print(f"An error occurred while downloading prompt templates: {e}")
|
| 27 |
return
|
| 28 |
|
|
|
|
| 29 |
choices = list(prompt_templates.keys())
|
| 30 |
return gr.update(value=choices[0], choices=choices)
|
| 31 |
|
|
|
|
| 21 |
prompt = row[1].strip('"')
|
| 22 |
prompt_templates[act] = prompt
|
| 23 |
|
|
|
|
| 24 |
except requests.exceptions.RequestException as e:
|
| 25 |
print(f"An error occurred while downloading prompt templates: {e}")
|
| 26 |
return
|
| 27 |
|
| 28 |
+
prompt_templates = dict(sorted(prompt_templates.items(), key=lambda item: item[0]))
|
| 29 |
choices = list(prompt_templates.keys())
|
| 30 |
return gr.update(value=choices[0], choices=choices)
|
| 31 |
|