Update app_agent_config.py
Browse files- app_agent_config.py +5 -6
app_agent_config.py
CHANGED
@@ -1,7 +1,6 @@
|
|
1 |
-
#
|
2 |
-
|
3 |
import streamlit as st
|
4 |
-
from tool_loader import
|
5 |
from tool_config import tool_names
|
6 |
from logger import log_enabled
|
7 |
|
@@ -16,7 +15,7 @@ def app_agent_config():
|
|
16 |
|
17 |
# Add a dropdown for selecting the inference URL
|
18 |
global url_endpoint
|
19 |
-
|
20 |
"https://api-inference.huggingface.co/models/bigcode/starcoder",
|
21 |
"https://api-inference.huggingface.co/models/OpenAssistant/oasst-sft-4-pythia-12b-epoch-3.5",
|
22 |
"https://api-inference.huggingface.co/models/gpt2"
|
@@ -28,8 +27,8 @@ def app_agent_config():
|
|
28 |
|
29 |
# Add a checkbox for enabling logging
|
30 |
global log_enabled
|
31 |
-
|
32 |
|
33 |
global tool_checkboxes
|
34 |
-
|
35 |
|
|
|
1 |
+
# app_agent_config.py
|
|
|
2 |
import streamlit as st
|
3 |
+
from tool_loader import ToolLoade
|
4 |
from tool_config import tool_names
|
5 |
from logger import log_enabled
|
6 |
|
|
|
15 |
|
16 |
# Add a dropdown for selecting the inference URL
|
17 |
global url_endpoint
|
18 |
+
url_endpoint = st.selectbox("Select Inference URL", [
|
19 |
"https://api-inference.huggingface.co/models/bigcode/starcoder",
|
20 |
"https://api-inference.huggingface.co/models/OpenAssistant/oasst-sft-4-pythia-12b-epoch-3.5",
|
21 |
"https://api-inference.huggingface.co/models/gpt2"
|
|
|
27 |
|
28 |
# Add a checkbox for enabling logging
|
29 |
global log_enabled
|
30 |
+
log_enabled = st.checkbox("Enable Logging")
|
31 |
|
32 |
global tool_checkboxes
|
33 |
+
tool_checkboxes = [st.checkbox(f"{tool.name} --- {tool.description} ") for tool in tool_loader.tools]
|
34 |
|