Parameters for the deploymentsTextGenerationStream operation.

interface DeploymentsTextGenerationStreamParams {
    accept?: string;
    headers?: OutgoingHttpHeaders;
    idOrName: string;
    input?: string;
    moderations?: WatsonXAI.Moderations;
    parameters?: WatsonXAI.DeploymentTextGenProperties;
}

Properties

accept?: string

The type of the response: application/json or text/event-stream. A character encoding can be specified by including a charset parameter. For example, 'text/event-stream;charset=utf-8'.

headers?: OutgoingHttpHeaders
idOrName: string

The id_or_name can be either the deployment_id that identifies the deployment or a serving_name that allows a predefined URL to be used to post a prediction.

The project or space for the deployment must have a WML instance that will be used for limits and billing (if a paid plan).

input?: string

The prompt to generate completions. Note: The method tokenizes the input internally. It is recommended not to leave any trailing spaces.

This field is ignored if there is a prompt template.

moderations?: WatsonXAI.Moderations

Properties that control the moderations, for usages such as Hate and profanity (HAP) and Personal identifiable information (PII) filtering. This list can be extended with new types of moderations.

The template properties if this request refers to a prompt template.