Next.js Discord

Discord Forum

Parallel tool calls: some tools' execute() intermittently not invoked (no execution span)

Unanswered
Palomino posted this in #help-forum
Open in Discord
PalominoOP
Environment
- ai: 6.0.154
- Provider: @ai-sdk/openai, model gpt-5.1-chat-latest, system: openai.responses
- Settings: toolChoice: auto, temperature: 0.3, maxRetries: 2
- ~17k-token prompt, ~10 tools registered
- Observability: Langfuse

Behavior
The model returns 4 tool calls in a single response (finishReason: tool-calls), but only 2 of the 4 tools' functions actually run. The other 2 never produce an execution span and no tool result. It's **intermittent** — the same tools sometimes execute and sometimes don't. All 4 tools have a `execute '' function defined. In one captured trace: - Model emitted: `bitrix24-add_lead_attachment`, `bitrix24-update_lead_stage`, `zinq-update_task`, `zinq-update_contact_other_details` - Executed (spans present): `zinq-update_task`, `zinq-update_contact_other_details` - Not executed (no span, no result): both `bitrix24-*` calls - The SDK then looped into a second generation. **What I've checked** - All four tools have `execute 'defined' (not client-side/manual). - The non-executed calls sometimes appear to have incomplete arguments (e.g., only `leadId`, missing other required fields). This makes me suspect input/Zod validation is failing and silently skipping.

Questions
1. When a parallel tool call fails input-schema validation, is execute it skipped silently, with no error surfaced on the result or stream? What's the correct way to detect this per-call? 2. Recommended pattern to make these visible/recoverable —strict: true,experimental_repairToolCall, or diffingtoolCallsvstoolResultsinonStepFinish`?
3. Any known issues with parallel tool calls + the OpenAI Responses API where some calls in a batch get dropped?

0 Replies