def fix_action_input(
        self, tool: Tool, action: AgentAction, error: str
    ) -> AgentAction:
        """If the tool failed due to error, what should be the fix for inputs"""
        prompt = FIX_TOOL_INPUT_PROMPT_TEMPLATE.format(
            tool_description=tool.description, inputs=action.tool_input, error=error
        )

        logger.info(f"\nFixing tool input prompt: {prompt}")
        messages = UserMessage(content=prompt)
        output = self.llm.generate([messages]).generations[0]
        new_tool_inputs = self.output_parser.load_json_output(output.message)

        logger.info(f"\nFixed tool output: {new_tool_inputs}")
        new_action = AgentAction(tool=action.tool, tool_input=new_tool_inputs)
        return new_action
If the tool failed due to error, what should be the fix for inputs
autochain/agent/conversational_agent/conversational_agent.py