Repository navigation
fix: recognize image input for GPT-6.2 models routed through ClawRouter - #200878
Conversation
When neither the selected endpoint nor the model row declares input, ClawRouter's fallback classified gpt-6.2-sol and gpt-6.2-astra as text-only. Add both upstream IDs and cover them in the fallback test.
|
🦞👀 Pull request received. I will update this pull request when review starts. ClawSweeper review completeClawSweeper finished reviewing this revision. The review result is being finalized. |
|
Codex review: needs real behavior proof before merge. What this changesAdds GPT-6.2 Sol and Astra to ClawRouter’s existing image-input fallback and extends its catalog regression test. Example: Send an image to clawrouter/openai/gpt-6.2-sol when neither the catalog model nor its selected endpoint declares input types.
Review scores
ProductKind: Bug fix · Worth it: Yes · Fix scope: Complete Merge readiness⛔ Blocked before merge - 1 item remains Keep open: current main still omits GPT-6.2 image capability when ClawRouter supplies no input metadata, and this PR makes a focused, source-consistent repair with no identified code defects. Priority: P2 Before merge
FindingsNone. Tests
Agent review detailsHow this fits togetherThe bundled ClawRouter provider translates credential-scoped catalog rows into runtime model capabilities; the agent’s prompt-media loader uses those capabilities to decide whether to load images. flowchart LR
A[ClawRouter catalog] --> B[Provider catalog translator]
B --> C[Runtime model capabilities]
C --> D[Prompt image loader]
D --> E[Responses request]
E --> F[ClawRouter inference]
Technical reviewBest possible solution: Retain the two-ID repair in the existing fallback while preserving explicit catalog input declarations. Do we have a high-confidence way to reproduce the issue? Source establishes a deterministic path: an OpenAI GPT-6.2 catalog row without endpoint or row input falls through to text-only classification, and the agent skips image loading; no target code was executed during this read-only review. Is this the best way to solve the issue? This is the smallest complete repair using the existing owner: both omitted identities gain the established fallback without new state, helpers, APIs, or broader family matching. AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning medium; reviewed against d57603b0b331. Provenance checked
TestingProof path: in-process harness. SecurityNone. EvidenceWhat I checked:
Likely related people:
PR surfaceSource +2, Tests +4. Total +6 across 2 files. Added test files: 0. View PR surface stats
Preflight sourceSource unknown. Source comparison at the observed PR snapshot only. Completion is self-reported; body, policy, tests, execution, and report bytes are not verified. LabelsLabel changes:
Label justifications:
Rank-up movesOptional improvements that raise the rating; they are not merge blockers.
Rating scale6/6 🦀 challenger crab · 5/6 🦞 diamond lobster · 4/6 🐚 platinum hermit · 3/6 🦐 gold shrimp · 2/6 🦪 silver shellfish · 1/6 🧂 unranked krab. Overall follows the weaker of proof and patch quality; ✨ marks media proof (a screenshot, video, or linked artifact) that directly shows the changed behavior. WorkflowClawSweeper edits this one comment on every review. Comment Reviewed November 17, 2026, 7:31 PM ET / November 18, 2026, 00:31 UTC. |
When neither the selected endpoint nor the model row declares input, ClawRouter's fallback classified gpt-6.2-sol and gpt-6.2-astra as text-only. Add both upstream IDs and cover them in the fallback test. (cherry picked from commit 3bc20e2) Release adaptation: Cite the original PR’s November 18, 2026 live ClawRouter image proof in the legacy fallback; exact upstream IDs, explicit modality precedence, and text-only behavior for unrecognized models are unchanged. Follow-up audit: #205137’s catalog clock fixture is already equivalent (70a36ea), and #203898 is already integrated (fec6728). #207768 classifies catalog misses and #192450 adds Bedrock routing; neither is required by the exact-ID fallback. #201434 and #201415 mention the donor SHA as an unrelated verification baseline. Original #200878 has no additional follow-up reference at the pinned scan end. Co-authored-by: RomneyDa <[email protected]>
Related: #200766
What Problem This Solves
OpenClaw leaves prompt images out of requests to GPT-6.2 Sol and Astra through ClawRouter when the router catalog omits input types for both the model and its selected endpoint. The fallback already recognizes image input for
gpt-6.1-sol.User Impact
User impact: OpenClaw can include prompt images in requests to GPT-6.2 Sol and Astra through ClawRouter when the catalog leaves input types unspecified. Input declarations on the model row or selected endpoint still take precedence.
Why This Change Was Made
#200766 added both GPT-6.2 models to the OpenAI catalog. ClawRouter's exact-ID fallback already included
gpt-6.1-soland was missing both new IDs. This change adds them and extends the existing fallback test. The ClawRouter test in #200766 suppliesinputin its mock row and bypasses the fallback.Evidence
Checked on macOS 15.7.9 (arm64), Node 24.22.2.
retains known native image inputs without granting unknown OpenAI models) fails because both GPT-6.2 rows come back as["text"].extensions/clawrouter/provider-catalog.test.tsplusextensions/clawrouter/gpt-62-compat.test.tspass together (10 tests, 47 seconds locally).pnpm tsgo:extensionspasses, andoxfmt --checkandoxlintare clean on the two touched files. The extension test typecheck (pnpm tsgo:extensions:test) did not finish locally.src/agents/embedded-agent-runner/run/images.tsskips prompt images when the model lacks image input.Failing output before the fix
Maintainer verification: real GPT-6.2 image inference
On November 18, 2026, an isolated OpenClaw Gateway ran source
f30a86c40da29cd2b4d0b601414820bc597a0d41(macOS arm64, Node 26.12.1). To reproduce, supply a local discovery fixture with GPT-6.2 Sol and Astra model rows and selected Responses endpoints that both omitinput. Disable tools and alternate image understanding. Start a freshchat.sendturn with a synthetic PNG containing a code absent from the prompt text. Record the number ofinput_imageblocks on the serialized Responses request and forward that request body unchanged to ClawRouter production. For the pre-fix control, substitute only the exact baseprovider-catalog.tsblob.openai/gpt-6.2-solinput_imageblocks; did not recover the code6CD29BB9exactlyopenai/gpt-6.2-astrainput_imageblocks; returnedNO_IMAGED4275EA1exactlyEach candidate request contained two byte-identical copies of its single uploaded PNG, verified by SHA-256. The Sol control did not use the literal
NO_IMAGE, so the control harness exited nonzero; its wire capture still established that the image was omitted and the code was not recovered. Only catalog discovery was simulated: image upload, hydration, Responses serialization, and model inference were real. This does not establish rollout of the production discovery catalog.Focused Vitest: 10 passed across
provider-catalog.test.tsandgpt-62-compat.test.ts; formatting, lint, andgit diff --checkpassed. Exact-head CI passed (20 jobs passed, 32 skipped); exact-head security review passed.