Skip to content

feat(#3996): resolve image output capability from models.dev - #4019

Draft
aheritier wants to merge 2 commits into
gemini-request-diagnosticsfrom
gemini-output-capability
Draft

feat(#3996): resolve image output capability from models.dev#4019
aheritier wants to merge 2 commits into
gemini-request-diagnosticsfrom
gemini-output-capability

Conversation

@aheritier

@aheritier aheritier commented Aug 22, 2026

Copy link
Copy Markdown
Collaborator

What

Resolves Gemini image-output capability from models.dev, wires it into model/config validation, and documents/examples the capability.

Why

Allows image-output configuration to be validated from authoritative model metadata instead of hard-coded assumptions.

Validation

task test; config, schema, modelinfo, capability-resolution, and output-capability tests.

Test instructions

Run:

task test

Use examples/gemini_image_output.yaml with a Gemini model that advertises image output, then repeat with a model that does not. Expected: the capable model configuration is accepted and the incapable model configuration is rejected with a clear validation error.

Add ModelConfig.OutputCapabilities (output_capabilities.image in YAML),
a latest-only tri-state override for a model's generative output
capability. An explicit true or false is authoritative; an omitted flag
is left for the models.dev resolver introduced by the following commit.
No capability is ever inferred from the model name.

Reject output_capabilities on first_available selectors because one
block cannot unambiguously describe every candidate. Update the schema,
model docs, and example, and cover YAML round trips, shorthand behavior,
cloning, schema strictness, and selector validation.
Resolve an omitted output_capabilities.image flag from the model's models.dev
output modalities, matching modality names case-insensitively. Explicit true
or false overrides remain authoritative, while a missing store or catalogue
record conservatively disables image output.

Wire the resolver through provider base configuration, update schema and model
documentation, and cover catalogue hits, misses, nil stores, and override
precedence.
@aheritier aheritier added area/config For configuration parsing, YAML, environment variables area/docs Documentation changes area/providers For features/issues/fixes related to LLM providers (Bedrock, LiteLLM, Qwen, custom, etc.) area/testing Test infrastructure, CI/CD, test runners, evaluation kind/feat PR adds a new feature (maps to feat:). Use on PRs only. labels Aug 22, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area/config For configuration parsing, YAML, environment variables area/docs Documentation changes area/providers For features/issues/fixes related to LLM providers (Bedrock, LiteLLM, Qwen, custom, etc.) area/testing Test infrastructure, CI/CD, test runners, evaluation kind/feat PR adds a new feature (maps to feat:). Use on PRs only.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant