Heroku LangChain.js - v1.0.1
    Preparing search index...

    Interface StructuredOutputMethodParams<RunOutput>

    Parameters for configuring structured output with schema and options.

    StructuredOutputMethodParams

    Whether to include raw response alongside parsed output

    interface StructuredOutputMethodParams<
        RunOutput extends Record<string, any> = Record<string, any>,
    > {
        schema:
            | Record<string, any>
            | ZodType<RunOutput, unknown, $ZodTypeInternals<RunOutput, unknown>>;
        name?: string;
        description?: string;
        method?: string;
        includeRaw?: boolean;
    }

    Type Parameters

    • RunOutput extends Record<string, any> = Record<string, any>

      The expected output type from the structured response

    Index

    Properties

    schema:
        | Record<string, any>
        | ZodType<RunOutput, unknown, $ZodTypeInternals<RunOutput, unknown>>

    The Zod schema or JSON schema object defining the expected output structure

    name?: string

    Optional name for the structured output function

    description?: string

    Optional description for the structured output function

    method?: string

    Method to use for structured output - either function calling or JSON mode

    includeRaw?: boolean

    Whether to include the raw response alongside the parsed output