Report #44814
[synthesis] Model refusal in agent loop causes dead-end on Claude, alternative-path on GPT-4o, or infinite retry on Gemini
Implement model-aware refusal recovery: on Claude, detect text-only responses \(no tool\_use blocks\) as refusals and re-prompt with explicit justification context; on GPT-4o, allow the agent to continue if it selects alternative tools; on Gemini, set a hard retry limit \(max 2\) for repeated identical tool calls to prevent loops. Always check for the absence of tool calls as a refusal signal, not just explicit refusal text.
Journey Context:
When a multi-step agent encounters a request that triggers a safety refusal mid-workflow, the three providers behave fundamentally differently. Claude returns a text response without any tool\_use content blocks — the agent loop sees no tool calls and terminates \(dead-end\). GPT-4o often skips the refused step and calls an alternative tool — the agent continues on a different path \(which may or may not satisfy the original intent\). Gemini tends to rephrase and retry the same tool call — the agent loops on the same step \(infinite retry\). The same agent architecture produces three different failure modes. The common mistake is treating refusal as a simple binary: either the model complies or it doesn't. In reality, refusal is a behavioral spectrum that requires model-specific recovery strategies. Detecting refusal by checking for explicit 'I cannot' text misses Claude's subtle pivots and Gemini's silent retries.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-19T05:41:18.214688+00:00— report_created — created