Table of Contents

Class ImageCaptioningRequestExtensions

Namespace
GenerativeAI
Assembly
GenerativeAI.dll

Extension methods for configuring ImageCaptioningRequest objects with image data.

public static class ImageCaptioningRequestExtensions
Inheritance
ImageCaptioningRequestExtensions
Inherited Members

Methods

AddGcsImage(ImageCaptioningRequest, string)

Adds a Google Cloud Storage (GCS) image to the ImageCaptioningRequest using the specified GCS URI.

public static void AddGcsImage(this ImageCaptioningRequest request, string imageUri)

Parameters

request ImageCaptioningRequest

The ImageCaptioningRequest to add the image to.

imageUri string

The GCS URI of the image to add.

AddLocalImage(ImageCaptioningRequest, string)

Adds a local image to the ImageCaptioningRequest by reading the image from the specified file path and encoding it as a base64 string.

public static void AddLocalImage(this ImageCaptioningRequest request, string imagePath)

Parameters

request ImageCaptioningRequest

The ImageCaptioningRequest to add the image to.

imagePath string

The file path of the local image to add.