tenseleyflow/loader / dff75e0

Browse files

ux: add 0.4s delay between extracted tool executions for smoother experience

Authored by espadonne
SHA
dff75e09ea78356d35b9471004dbaeabd4c0615e
Parents
7466f7b
Tree
e84941d

1 changed file

StatusFile+-
M src/loader/agent/loop.py 4 1
src/loader/agent/loop.pymodified
@@ -1021,7 +1021,10 @@ class Agent:
10211021
                     pass
10221022
                 # This duplicates the tool execution logic above, but that's intentional
10231023
                 # to handle the case where raw JSON tool calls are extracted
1024
-                for tc in tool_calls:
1024
+                for i, tc in enumerate(tool_calls):
1025
+                    # Small delay between tool executions for better UX
1026
+                    if i > 0:
1027
+                        await asyncio.sleep(0.4)
10251028
                     try:
10261029
                         with open("/tmp/loader_debug.log", "a") as f:
10271030
                             f.write(f"[loop] executing extracted tool: {tc.name} args={tc.arguments}\n")