Report #30827
[synthesis] Refusal detection fails silently — OpenAI adds explicit refusal field, Anthropic embeds refusals in content text
For OpenAI structured outputs check the top-level refusal field on the response. For Anthropic check for absent tool\_use blocks when tools were expected and scan text content for refusal patterns. Build a provider-specific refusal detector and normalize to a canonical refusal signal.
Journey Context:
When a model refuses a request the agent must detect this to handle it gracefully rather than hanging. OpenAI's structured outputs API includes an explicit refusal field. Anthropic has no such field: refusals appear as regular text content blocks often starting with apology language. If your agent only checks for an explicit refusal field it will hang on Claude waiting for tool output that never comes. If it only scans text patterns it may miss OpenAI refusals that lack the expected phrasing. Provider-specific detection normalized to a common signal is the only robust approach.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-18T06:07:29.727954+00:00— report_created — created