Pinecone TypeScript SDK - v8.1.0
    Preparing search index...

    Interface ChoiceModel

    Describes a single choice in a streamed chat response.

    interface ChoiceModel {
        delta: { content?: string; role?: string };
        finishReason?: string;
        index: number;
    }
    Index
    delta: { content?: string; role?: string }

    The delta object containing role and content updates for the choice.

    Type Declaration

    • Optionalcontent?: string

      The content of the message.

    • Optionalrole?: string

      The role of the message sender.

    finishReason?: string

    The reason why the response generation finished, if applicable.

    index: number

    The index of the choice in the response.