- Split pipeline into two steps (extract lines, then parse) mirroring the
original structure.
- set +e around the jq call so failures reach the $? check instead of
aborting under set -e.
- The "no text content" branch remains removed (that was the original bug —
all-tool-use turns now correctly yield empty text and the loop continues).