Skip to content

fix(translate): accept structured custom tool outputs - #512

Open
M1k0t0 wants to merge 1 commit into
Menci:mainfrom
M1k0t0:floway/responses-structured-custom-tool-outputs
Open

M1k0t0 wants to merge 1 commit into
Menci:mainfrom
M1k0t0:floway/responses-structured-custom-tool-outputs

Conversation

@M1k0t0

@M1k0t0 M1k0t0 commented Sep 13, 2026

Copy link
Copy Markdown
Contributor

Summary

Responses custom tool results were rejected whenever output was an array, even when it contained only text. This could interrupt Codex after a successful tool call with Cannot translate multimodal custom_tool_call_output.

Handle custom_tool_call_output through the same output conversion as function_call_output in both the Chat Completions and Anthropic Messages translators. This supports text arrays, empty results, and images while preserving tool-call IDs and result ordering. Chat Completions places images after the complete tool-result group; Anthropic Messages keeps them inside tool_result and preserves incomplete status.

Regression coverage includes structured output conversion, image handling, unsupported file outputs, and two-turn HTTP continuations using previous_response_id through both target protocols.

Validation

All 125 tests across the two request translator suites and the Responses HTTP suite passed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant