Class BaseMultiActionAgentAbstract

Abstract base class for multi-action agents in LangChain. Extends the BaseAgent class and provides additional functionality specific to multi-action agents.

Hierarchy

  • BaseAgent
    • BaseMultiActionAgent

Constructors

  • Parameters

    • Optional kwargs: SerializedFields
    • Rest ..._args: never[]

    Returns BaseMultiActionAgent

Properties

ToolType: StructuredToolInterface<ZodObject<any, any, any, any, {}>>

Accessors

Methods

  • Decide what to do, given some input.

    Parameters

    • steps: AgentStep[]

      Steps the LLM has taken so far, along with observations from each.

    • inputs: ChainValues

      User inputs.

    • Optional callbackManager: CallbackManager

      Callback manager.

    • Optional config: RunnableConfig

    Returns Promise<AgentFinish | AgentAction[]>

    Actions specifying what tools to use.

  • Prepare the agent for output, if needed

    Parameters

    • _returnValues: Record<string, any>
    • _steps: AgentStep[]

    Returns Promise<Record<string, any>>

  • Return response when agent has been stopped due to max iterations

    Parameters

    • earlyStoppingMethod: StoppingMethod
    • _steps: AgentStep[]
    • _inputs: ChainValues
    • Optional _callbackManager: CallbackManager

    Returns Promise<AgentFinish>

Generated using TypeDoc