Request response from the model

Invokes inference using the model chat parameters. If uploading large images, this POST should be used in conjunction with the NVCF API which allows for the upload of large assets.
You can find details on how to use NVCF Asset APIs here: https://docs.api.nvidia.com/cloud-functions/reference/createasset

Log in to see full request history
Body Params
messages
array of objects
required
length ≥ 1

A list of messages comprising the conversation so far.

Messages*
string
required

The role of the message's author.

required

The contents of the message.

To pass images (only with role=user):

- When content is a string, image can be passed together with the text with img HTML tags that wraps
an image URL (<img src="{url}" />),
base64 encoded image data (<img src="data:image/{format};base64,{base64encodedimage}" />),
or an NVCF asset ID (<img src="data:image/{format};asset_id,{asset_id}" />)
when the container is hosted in NVCF and the payload exceeds 200KB.

- When content is a list of objects, images can be passed as objects with type=image_url.

- In both cases, images can be PNG, JPG or JPEG.

For system and assistant roles, the object list format is not supported.

string
required
Defaults to google/gemma-3-27b-it

The model to use.

Defaults to 512

The maximum number of tokens that can be generated.

Defaults to false

If set, partial message deltas will be sent, like in ChatGPT. Tokens will be sent as data-only server-sent events as they become available, with the stream terminated by a data: [DONE]

Defaults to 0.2

What sampling temperature to use, between 0 and 2. Higher values like 0.8 will make the output more random, while lower values like 0.2 will make it more focused and deterministic.

Defaults to 0.7

An alternative to sampling with temperature, called nucleus sampling, where the model considers the results of the tokens with top_p probability mass. So 0.1 means only the tokens comprising the top 10% probability mass are considered. We generally recommend altering this or temperature but not both.

Headers
uuid
length ≤ 370

String of asset IDs separated by commas. Data is uploaded to AWS S3 using NVCF Asset APIs and associated with these asset IDs.If the size of an image is more than 180KB, it needs to be uploaded to a presigned S3 URL bucket. The presigned URL allows for secure and temporary access to the S3 bucket for uploading the image. Once the asset is requested, an asset ID is generated for it. Please include this asset ID in this header and to use the uploaded image in a prompt, you need to refer to it using the following format: <img src="data:image/png;asset_id,{asset_id}" />.

Responses

Language
Credentials
Click Try It! to start a request and see the response here! Or choose an example:
application/json
text/event-stream