Skip to main content

enterprise_ai.multimodal.vision

Source: sdks/python/src/enterprise_ai/multimodal/vision/__init__.py. Back to the Python SDK reference index.

note

This page is generated by tools/docs/gen_sdk_reference.py from the SDK sources and the OpenAPI text folders. Do not edit it by hand: change the source and regenerate.

Class VisionClient​

/v1/multimodal/vision.

Resource

VisionClient.analyze​

analyze(prompt: str, media_id: str | None = None, content_base64: str | None = None, mime_type: str | None = None, model: str | None = None, **extra: Any) -> Any

Understand an image. Starts a vision understanding job on an image media or inline image with a prompt (201, the job). The answer goes through the DLP with dlp_mode. detail answers 422 parameter_unsupported when the configured provider cannot honour it; a non image input answers 422 unsupported_media. Needs tenant_admin, developer or agent.

Route: /v1/multimodal/vision (POST).

NameTypeDefaultRequiredDescription
promptstryesQuestion about the image. Default Describe this image.
media_idstr | NoneNonenoStored image media.
content_base64str | NoneNonenoInline image, base64 encoded (scanned before use).
mime_typestr | NoneNonenoMedia type of the inline image, for example image/jpeg.
modelstr | NoneNonenoModel to use. Default: the configured adapter.
**extraAnynoExtra fields merged into the request body.

Returns: Any. Decoded JSON answer of the operation "Understand an image".

Raises: ValueError, the typed errors of the transport (Errors).