agent loops — tool_use and the request/tool/respond cycle5 / 9
stop_reason, tool_use, tool_result — the loop every agent runs
Cursor wrote an agent loop and left the exit condition unfilled.
The loop should break when the model is finished — that is, when
the response's stop_reason equals which string?
Stop reason:
⌘↵ runs the editor.
Booting Python…
Output
[promptdojo:~]$ _