Skip to content

fix(vision): route standalone vision through native providers#957

Closed
huangzesen wants to merge 4 commits into
mainfrom
fix/codex-pool-vision
Closed

fix(vision): route standalone vision through native providers#957
huangzesen wants to merge 4 commits into
mainfrom
fix/codex-pool-vision

Conversation

@huangzesen

@huangzesen huangzesen commented Jul 15, 2026

Copy link
Copy Markdown
Collaborator

Summary

  • register codex-pool and codex_pool as native Codex vision aliases and route the Codex family through the existing Responses input_image service
  • preserve same-provider identity for direct-native OpenAI, Anthropic, and Gemini vision: explicit capability overrides win; otherwise the active model is reused, and OpenAI/Anthropic also reuse the active endpoint
  • keep MiMo on an explicit or known vision-capable model (mimo-v2.5 by default) while preserving its same-provider endpoint; do not forward text-only MiMo chat models
  • map glm to the existing Zhipu MCP vision service; keep MiniMax/Zhipu MCP routing unchanged
  • keep OpenRouter, DeepSeek, Kimi, custom relays, Claude Code aliases, and local vision unavailable by default unless the user explicitly configures the existing compatibility/skill+MCP path
  • add focused routing/isolation/request regressions and update the vision Contract/Anatomy documents

Scope

This PR keeps the existing explicit vision(image_path, question) tool. It does not add canonical main-session image blocks, auto-enable omitted optional capabilities, infer whether a relay/upstream model accepts images, install/download a local model, or introduce any silent cross-provider fallback.

MiniMax and Zhipu remain explicitly configured MCP-backed services. Built-in preset declarations/editor choices are owned by the TUI repository; this kernel PR makes declared vision capabilities route correctly but does not silently turn on vision for a TUI preset that omits it (notably the current Gemini preset source).

Validation

Parent-run validation on exact head d8abcdc772e88228ce5efcf07f6c3526f8f1fd11:

  • /Users/huangzesen/work/GitHub/lingtai-kernel/.venv/bin/python -m pytest tests/test_vision_capability.py tests/test_vision_services.py -q56 passed
  • /Users/huangzesen/work/GitHub/lingtai-kernel/.venv/bin/python -m pytest tests/test_codex_pool*.py -q109 passed
  • /Users/huangzesen/work/GitHub/lingtai-kernel/.venv/bin/python -m pytest tests/test_architecture_documents.py tests/test_anatomy_drift_checker.py -q12 passed
  • /Users/huangzesen/work/GitHub/lingtai-kernel/.venv/bin/python -m lingtai.tools.glossary_validator --check54 resources validated
  • py_compile, lazy-import smoke (lingtai.tools.vision does not import lingtai.services), and git diff --check — passed

Live evidence and safety

After the initial Codex production commit 0a9fdfc66f004068477cc6394812ac8c4e09e598, one explicitly authorized controlled PNG smoke through the active codex-pool / gpt-5.6-sol route returned the exact red/yellow/white/blue geometry. The broader provider expansion was validated only with mocked/local tests: there were no live OpenAI, Anthropic, Gemini, MiMo, MiniMax, or Zhipu calls.

The current live runtime remains on 0a9fdfc6; this expanded PR head was not installed or refreshed. No auth/config mutation, credential-file inspection, fallback-provider call, dependency change, or local model download was performed.

@huangzesen huangzesen changed the title fix(vision): route Codex Pool through native image input fix(vision): route standalone vision through native providers Jul 16, 2026
@huangzesen

Copy link
Copy Markdown
Collaborator Author

Superseded by #964, which carries the latest-main implementation and the complete current provider/preset coverage for Lingtai-AI/lingtai#957. Thank you for establishing the original Codex/Codex-pool vision direction here; that work is preserved and extended in the replacement.

@huangzesen huangzesen closed this Jul 16, 2026
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