proposit-core
    Preparing search index...

    Type Alias TConversation

    The conversation object. Methods:

    • turn(stage, input, opts?) — run one turn
    • close() — seal the conversation (finalize calls this)

    .turn after .close() throws ConversationClosedError.

    type TConversation = {
        closed: boolean;
        lastResponseId: TResponseId | null;
        tokenUsage: TLlmTokenUsage;
        close(): void;
        turn<TOut>(
            stage: TStage<TOut>,
            input: TTurnInput,
            opts?: { branchFrom?: TResponseId; onComplete?: () => void },
        ): Promise<TTurnResult<TOut>>;
    }
    Index

    Properties

    closed: boolean

    Whether the conversation has been closed.

    lastResponseId: TResponseId | null

    The latest provider response id in the chain.

    tokenUsage: TLlmTokenUsage

    Cumulative token usage across all turns.

    Methods