Update Gradio_UI.py
Browse files- Gradio_UI.py +3 -1
Gradio_UI.py
CHANGED
|
@@ -31,10 +31,12 @@ def pull_messages_from_step(
|
|
| 31 |
"""Extract ChatMessage objects from agent steps with proper nesting"""
|
| 32 |
import gradio as gr
|
| 33 |
|
| 34 |
-
|
| 35 |
if isinstance(step_log, ActionStep):
|
| 36 |
# Output the step number
|
| 37 |
step_number = f"Step {step_log.step_number}" if step_log.step_number is not None else ""
|
|
|
|
|
|
|
| 38 |
yield gr.ChatMessage(role="assistant", content=f"**{step_number}**")
|
| 39 |
|
| 40 |
# First yield the thought/reasoning from the LLM
|
|
|
|
| 31 |
"""Extract ChatMessage objects from agent steps with proper nesting"""
|
| 32 |
import gradio as gr
|
| 33 |
|
| 34 |
+
|
| 35 |
if isinstance(step_log, ActionStep):
|
| 36 |
# Output the step number
|
| 37 |
step_number = f"Step {step_log.step_number}" if step_log.step_number is not None else ""
|
| 38 |
+
if step_log.step_number == 1:
|
| 39 |
+
yield gr.ChatMessage(role="assistant", content=f"***Thinking***")
|
| 40 |
yield gr.ChatMessage(role="assistant", content=f"**{step_number}**")
|
| 41 |
|
| 42 |
# First yield the thought/reasoning from the LLM
|