Don't transform anthropic->anthropic - #448
Alex Z (CLowbrow) wants to merge 2 commits into
Conversation
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 9a59609743
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "Codex (@codex) review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "Codex (@codex) address that feedback".
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 109980003c
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "Codex (@codex) review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "Codex (@codex) address that feedback".
| if let Some(field) = self | ||
| .messages | ||
| .iter() | ||
| .flatten() | ||
| .find_map(OpenAiMessageShapeView::first_openai_only_field) |
There was a problem hiding this comment.
Detect OpenAI content blocks before Anthropic passthrough
When a Chat Completions request uses multimodal messages[].content—for example an image_url block—the nested-shape scan returns false because OpenAiMessageShapeView::first_openai_only_field only examines roles and message-level keys, never the content blocks. The router therefore forwards image_url unchanged to Anthropic, which expects an image block with source, instead of taking the existing transformation path that performs this conversion. Fresh evidence after the earlier review is that nested checking was added, but content-block discriminators remain uninspected.
AGENTS.md reference: AGENTS.md:L17-L19
Useful? React with 👍 / 👎.
No description provided.