Constructs the agent's scratchpad, which is a string representation of the agent's previous steps.
Array of AgentStep instances representing the agent's previous steps.
Promise resolving to a string representing the agent's scratchpad.
Decide what to do given some input.
Steps the LLM has taken so far, along with observations from each.
User inputs.
OptionalcallbackManager: anyCallback manager to use for this call.
Action specifying what tool to use.
Return response when agent has been stopped due to max iterations
OptionalcallbackManager: anyStaticcreateCreate prompt in the style of the zero shot agent.
List of tools the agent will have access to, used to format the prompt.
Optionalargs: ChatCreatePromptArgsArguments to create the prompt with.
StaticdeserializeLoad an agent from a json-like object describing it.
StaticfromLLMAndCreates a ChatAgent instance using a language model, tools, and optional arguments.
BaseLanguageModelInterface instance to use in the agent.
Array of Tool instances to include in the agent.
Optionalargs: ChatCreatePromptArgs & AgentArgsOptional arguments to customize the agent and prompt.
ChatAgent instance
StaticgetReturns a default output parser for the ChatAgent.
Optional_fields: OutputParserArgsOptional OutputParserArgs to customize the output parser.
ChatAgentOutputParser instance
Staticvalidate
Agent for the MRKL chain.
Deprecated
Use the createStructuredChatAgent method instead.