From 2aad612c316459a24dd9e83bea318ccc1c73746a Mon Sep 17 00:00:00 2001 From: THEAVINASHREDDY Date: Tue, 3 Oct 2023 18:10:24 +0530 Subject: [PATCH] made changes in function_agent.py file --- codeinterpreterapi/agents/functions_agent.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/codeinterpreterapi/agents/functions_agent.py b/codeinterpreterapi/agents/functions_agent.py index ad96ccda..9902c4ee 100644 --- a/codeinterpreterapi/agents/functions_agent.py +++ b/codeinterpreterapi/agents/functions_agent.py @@ -128,13 +128,13 @@ def get_allowed_tools(self) -> List[str]: """Get allowed tools.""" return list([t.name for t in self.tools]) - @root_validator + @root_validator(allow_reuse=True) def validate_llm(cls, values: dict) -> dict: if not isinstance(values["llm"], ChatOpenAI): raise ValueError("Only supported with ChatOpenAI models.") return values - @root_validator + @root_validator(allow_reuse=True) def validate_prompt(cls, values: dict) -> dict: prompt: BasePromptTemplate = values["prompt"] if "agent_scratchpad" not in prompt.input_variables: