Skip to content

feature: model vision detection and live-result handling for browser tools - #90

Merged
DevMando merged 1 commit into
mainfrom
codex/model-vision-capabilities
Sep 6, 2026
Merged

feature: model vision detection and live-result handling for browser tools#90
DevMando merged 1 commit into
mainfrom
codex/model-vision-capabilities

Conversation

@DevMando

Copy link
Copy Markdown
Owner

What this adds

Two capabilities the desktop browser tools depend on.

Model image-capability detection. The app now detects whether the selected local model can accept images, by reading the capability list the model server reports. The result is shown in the conversation ("Vision supported" / "Text-only model" / "Vision capability unknown") and is written into the agent's instructions. A text-only model is explicitly told not to claim it looked at anything; a vision-capable model is told that a file path is not the same as being handed an image. Detection resets whenever the model or server changes, and a slow response about a previous model cannot overwrite newer information.

Live browser results bypass the result cache. Repeating an identical action is normally deduplicated to save time. That is correct for reading a file and wrong for clicking a button — the second click has to actually happen. Failed browser results are now recognized as failures rather than counted as successful steps, and a fresh page reading counts as real evidence when a plan is checked.

Why this was done

Without capability detection, a text-only model could claim to have visually reviewed a page it never saw. Without the cache exemption, repeated browser actions would silently not occur.

Scope

Detecting that a model accepts images does not give the app any way to send one. No screenshots are captured or attached. This is groundwork plus honest reporting, not a vision feature.

Older model servers that do not report capabilities are handled as "unknown" and still validate successfully. No guessing from model names.

Verification

710 automated tests pass on .NET 8 and .NET 10, including coverage for capability parsing, invalidation when the model or endpoint changes, and out-of-order responses from the model server.

Note for reviewers

MandoCode.Desktop has a companion change that depends on this one. That repository cannot build until this merges and its submodule pointer is updated.

Model validation now reads the capability list Ollama reports and records whether
the selected model accepts image input. The status is shown in the CLI and Desktop
and written into the agent's system instructions, so a text-only model is told not
to claim visual inspection and a vision model is told a file path is not an image.
Detection is keyed to model and endpoint, so it resets when either changes and a
late response about a previous model cannot overwrite newer state.
Detecting image support does not deliver images. No screenshots are captured or
attached; this is capability reporting only.
Live preview tool results are also exempted from the agent result cache. Repeating
an identical call is normally deduplicated, which is right for reading a file and
wrong for clicking a button, where the second click has to actually happen. Failed
preview results now register as failures rather than successful steps, and a fresh
DOM observation counts as browser evidence for plan checks.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
@DevMando
DevMando merged commit 04609ac into mainSep 6, 2026
@DevMando
DevMando deleted the codex/model-vision-capabilities branch September 6, 2026 22:55
Sign up for freeto 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

@DevMando