Skip to main content

createModelVisionProvider

@retinue/monorepo


@retinue/monorepo / backend/src / createModelVisionProvider

Function: createModelVisionProvider()

createModelVisionProvider(deps): VisionProvider

Defined in: backend/src/documents/vision.ts:116

A VisionProvider over the model registry.

requiredModalities: ["image"] is AC-3, and it is enforced by resolve throwing rather than by a check here — see models/vision.ts. The refusal surfaces as capability_unavailable, which the pipeline records as a typed failure, so a deployment with no vision model gets "this platform cannot describe images" instead of a description of an image nobody looked at.

Parameters​

deps​

maxOutputTokens?​

number

providers​

ProviderFactory

registry​

ModelRegistry

role?​

"fast" | "smart"

smart by default: a description is read by a person and a cheap model's is not worth the tokens.

Returns​

VisionProvider