Interface IGenerativeAIPromptJob

Represents bounded prompt job ready to be run or streamed.

interface IGenerativeAIPromptJob {
    id: string;
    options: IPromptOptions;
    prompt: string;
    run: (() => Promise<IPromptResult>);
    stream: (() => AsyncGenerator<IPromptResult, any, unknown>);
}

Properties

id: string

The job ID.

The options for the prompt.

prompt: string

The prompt to be processed

run: (() => Promise<IPromptResult>)

Run the prompt job.

Type declaration

stream: (() => AsyncGenerator<IPromptResult, any, unknown>)

Stream the prompt job.

Type declaration