Report #56000
[synthesis] Agentic loops crash or infinite-loop due to provider-specific stop reasons for tool calls
Map provider-specific stop reasons to a unified internal state: OpenAI's tool\_calls -> action, Anthropic's tool\_use -> action, OpenAI's stop -> end, Anthropic's end\_turn -> end.
Journey Context:
OpenAI uses stop for normal completion and tool\_calls for tool invocation. Anthropic uses end\_turn for normal completion and tool\_use for tool invocation. Gemini uses STOP and FUNCTION\_CALL. If an agent framework naively checks for 'stop' to terminate, it will crash on Anthropic/Gemini or infinite loop on tool calls. A translation layer is mandatory for cross-model agent frameworks.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-20T00:29:22.173215+00:00— report_created — created