How it works
The harness owns the cycle and runs it in order. It sends the current messages to the model. It reads the reply. If the reply names a tool, it runs that tool and waits. It appends the tool result as a new message the next call can see. It then evaluates the stop condition. When the condition is false it calls the model again with the longer list. The model does not increment a counter and does not decide that the cycle is over unless a message from the harness says so.
On a password reset the first pass calls find_account and appends the account id. The second pass calls send_reset and appends either a message id or an error. The third pass is allowed to answer the person only if the stop check has seen a successful send. If the error is appended, the next model call can choose a different address. If the harness instead stopped after the first tool, or treated the error text as success, the cycle would end before a password mail existed.
A worked example
Payroll portal reset
An employee asks for a password reset on the PayHub account for employee id E19.
Pass 1. The model calls find_account with E19. The tool returns the account, a primary email that bounced last week, and a backup email on file. The harness appends that result.
Pass 2. The model calls send_reset with the primary email. The tool returns a bounce. The harness appends the bounce and the stop check does not fire, because no reset was delivered.
Pass 3. The model calls send_reset with the backup email. The tool returns message id M-19. The stop check sees a delivered reset and ends the loop.
The reply quotes M-19 and the backup address, and it does not say the primary email worked.
Illustrative example, not a production trace and not a measured result.
What goes wrong
- The harness ends the loop after find_account, so the employee is told the account exists, the backup address is never tried, and no reset mail is ever sent.
- send_reset bounces and the harness appends a generic success line, so the next call tells the employee to check an inbox that never received the mail.
- The stop check does not look at message ids, the model calls send_reset a second time on the backup address, and the employee gets two competing reset links.
How to measure it
Count passes per reset: model calls, tool calls and the pass number where the loop stopped. A finished reset has a send_reset result with a message id before the stop, not only a find_account result.
Read loops that contain a bounce. Note whether the bounce was appended in full and whether a later pass used the backup address. A stop on the bounce, with no second send, is a loop that ended on the first error.
Further reading
How Abracadabra helps
The employee says the reset mail never arrived, then says a second mail turned up, or asks which address was used after the assistant named the bounced inbox.
Abracadabra reads each conversation and labels the task, the step where it stopped, and signals such as repeated intents, user corrections and abandonment, pinned to the turn. After you change this part of the harness, compare task success for that task and cohort with the previous period. Experimentation and guarded rollouts are in early access.
Request access to read this on your own agent.