
One Value to Continue
[Intro] (dark synth swell, slow pulse) (whispered) Send it... read it... run it... send again [Verse 1] Stateless on the wire, no memory kept, the whole conversation is the thing you resend. The model never runs it, it just asks for a tool, your code does the work, that's the agentic rule. So you spin in a loop, but here's where folks fall: how does the loop know there's nothing left at all? [Pre-Chorus] (build) Don't read the vibe, don't count to ten, there's one clean field that tells you when — [Chorus] (drop) One value to continue: it's `tool_use`, hold the line! Every other value is an exit you design. (hold the line!) `stop_reason` is the signal, structured, plain and true — not the words, not the cap, just `tool_use`. (just `tool_use`!) [Verse 2] While it's asking for a tool, you run it and resend, append the `tool_result`, the user message, then — when the value flips, you stop and you sort: a finished, a truncated, a refusal report. Three different outcomes, so you handle them apart, read the field, not the feeling, that's the architect's art. [Verse - Rap] (half-time) Check the field: `while stop_reason == "tool_use"`, resend the call, `end_turn` is natural completion, but it's never the whole wall — `max_tokens` says you're truncated, you hit the output cap, `stop_sequence` fired a marker, `refusal` declined the trap. `pause_turn`? That's a server tool, just resend it as it stands, `model_context_window_exceeded` — truncated, valid, out of hands. Continue on exactly one, treat the rest as their own gate, 'cause a regex on the prose is a guess you can't calibrate. The structured signal's already there, the API hands it free — so read `stop_reason` off the response, don't infer from what you see. [Chorus] (drop) One value to continue: it's `tool_use`, hold the line! Every other value is an exit you design. (hold the line!) `stop_reason` is the signal, structured, plain and true — not the words, not the cap, just `tool_use`. (just `tool_use`!) [Bridge] (half-time, sparse) Don't scan for "task complete" — phrasing isn't a contract, it drifts. Don't crown the iteration cap — that's a fuse, not the switch that lifts; it cuts the work that needed turn eleven, loops when turn three was through. And a tidy closing sentence? Style's no stop reason. Trust the field, not the mood. [Final Chorus] (full drop, gang vocals) One value to continue: it's `tool_use`, hold the line! (hold the line!) Every other value is an exit you design. `stop_reason` is the signal, structured, plain and true — not the words, not the cap, just `tool_use`! (just `tool_use`!) [Outro — call to action] (spoken over the final fade) Want the deep version? Get *The CCA-F Study Guide* on Leanpub — leanpub.com/cca-f (...just `tool_use`)

