Class for parsing the output of an LLM into a JSON object and returning a specific attribute. Uses an instance of JsonOutputFunctionsParser to parse the output.

Type Parameters

  • T = object

Hierarchy (view full)

Constructors

Properties

Methods

Constructors

Properties

attrName: string
outputParser: JsonOutputFunctionsParser<object> = ...

Methods

  • Parses the output and returns a specific attribute of the parsed JSON object.

    Parameters

    • generations: Generation[] | ChatGeneration[]

      The output of the LLM to parse.

    Returns Promise<T>

    The value of a specific attribute of the parsed JSON object.

Generated using TypeDoc