Result expander in Agent log

This commit is contained in:
Irina Rueegg 2026-05-28 11:28:54 +02:00
parent ea05437154
commit 46b9c925dd

View File

@ -194,6 +194,7 @@ def render_agent_mode():
st.caption(f"Thought: {step['thought']}") st.caption(f"Thought: {step['thought']}")
if step.get("arguments"): if step.get("arguments"):
_render_arguments(step["arguments"]) _render_arguments(step["arguments"])
with st.expander("➡️ Result", expanded=False):
result_text = step.get("result", "") result_text = step.get("result", "")
# Colour the result based on whether the tool succeeded or failed. # Colour the result based on whether the tool succeeded or failed.
if result_text.startswith("ERROR") or result_text.startswith("SYNTAX ERROR"): if result_text.startswith("ERROR") or result_text.startswith("SYNTAX ERROR"):