Spaces:
Running
Running
Update app.py
Browse files
app.py
CHANGED
@@ -158,9 +158,9 @@ if "messages" not in st.session_state:
|
|
158 |
|
159 |
set_moa_agent()
|
160 |
|
|
|
161 |
# Sidebar for configuration
|
162 |
with st.sidebar:
|
163 |
-
# config_form = st.form("Agent Configuration", border=False)
|
164 |
st.title("MOA Configuration")
|
165 |
with st.form("Agent Configuration", border=False):
|
166 |
if st.form_submit_button("Use Recommended Config"):
|
@@ -177,6 +177,7 @@ with st.sidebar:
|
|
177 |
st.error("Invalid JSON in Layer Agent Configuration. Please check your input.")
|
178 |
except Exception as e:
|
179 |
st.error(f"Error updating configuration: {str(e)}")
|
|
|
180 |
# Main model selection
|
181 |
new_main_model = st.selectbox(
|
182 |
"Select Main Model",
|
@@ -193,16 +194,14 @@ with st.sidebar:
|
|
193 |
)
|
194 |
|
195 |
# Main Model Temperature
|
196 |
-
|
197 |
-
|
198 |
-
|
199 |
-
|
200 |
-
|
201 |
-
|
202 |
-
step=0.05
|
203 |
)
|
204 |
|
205 |
-
|
206 |
# Layer agent configuration
|
207 |
tooltip = "Agents in the layer agent configuration run in parallel _per cycle_. Each layer agent supports all initialization parameters of [Langchain's ChatGroq](https://api.python.langchain.com/en/latest/chat_models/langchain_groq.chat_models.ChatGroq.html) class as valid dictionary fields."
|
208 |
st.markdown("Layer Agent Config", help=tooltip)
|
@@ -215,6 +214,7 @@ with st.sidebar:
|
|
215 |
auto_update=True
|
216 |
)
|
217 |
|
|
|
218 |
if st.form_submit_button("Update Configuration"):
|
219 |
try:
|
220 |
new_layer_config = json.loads(new_layer_agent_config)
|
|
|
158 |
|
159 |
set_moa_agent()
|
160 |
|
161 |
+
# Sidebar for configuration
|
162 |
# Sidebar for configuration
|
163 |
with st.sidebar:
|
|
|
164 |
st.title("MOA Configuration")
|
165 |
with st.form("Agent Configuration", border=False):
|
166 |
if st.form_submit_button("Use Recommended Config"):
|
|
|
177 |
st.error("Invalid JSON in Layer Agent Configuration. Please check your input.")
|
178 |
except Exception as e:
|
179 |
st.error(f"Error updating configuration: {str(e)}")
|
180 |
+
|
181 |
# Main model selection
|
182 |
new_main_model = st.selectbox(
|
183 |
"Select Main Model",
|
|
|
194 |
)
|
195 |
|
196 |
# Main Model Temperature
|
197 |
+
main_temperature = st.slider(
|
198 |
+
"Main Model Temperature",
|
199 |
+
min_value=0.0,
|
200 |
+
max_value=1.0,
|
201 |
+
value=st.session_state.main_temp,
|
202 |
+
step=0.05
|
|
|
203 |
)
|
204 |
|
|
|
205 |
# Layer agent configuration
|
206 |
tooltip = "Agents in the layer agent configuration run in parallel _per cycle_. Each layer agent supports all initialization parameters of [Langchain's ChatGroq](https://api.python.langchain.com/en/latest/chat_models/langchain_groq.chat_models.ChatGroq.html) class as valid dictionary fields."
|
207 |
st.markdown("Layer Agent Config", help=tooltip)
|
|
|
214 |
auto_update=True
|
215 |
)
|
216 |
|
217 |
+
|
218 |
if st.form_submit_button("Update Configuration"):
|
219 |
try:
|
220 |
new_layer_config = json.loads(new_layer_agent_config)
|