fix: remove log from csvAgent component (#3800)
* 🐛 (CSVAgent.py): Fix handle_parsing_errors parameter to use the correct instance variable self.handle_parsing_errors instead of a hardcoded value * 📝 (CSVAgent.py): add newline at the end of the file to follow best practices and improve code readability
This commit is contained in:
parent
cc04a21d9c
commit
612dc7f5ef
1 changed files with 10 additions and 4 deletions
|
|
@ -56,11 +56,13 @@ class CSVAgentComponent(LCAgentComponent):
|
|||
}
|
||||
|
||||
agent_csv = create_csv_agent(
|
||||
llm=self.llm, path=self.path, agent_type=self.agent_type, handle_parsing_errors=True, **agent_kwargs
|
||||
llm=self.llm,
|
||||
path=self.path,
|
||||
agent_type=self.agent_type,
|
||||
handle_parsing_errors=self.handle_parsing_errors,
|
||||
**agent_kwargs,
|
||||
)
|
||||
|
||||
print(f"self.inputs = {agent_csv}")
|
||||
|
||||
result = agent_csv.invoke({"input": self.input_value})
|
||||
return Message(text=str(result["output"]))
|
||||
|
||||
|
|
@ -71,7 +73,11 @@ class CSVAgentComponent(LCAgentComponent):
|
|||
}
|
||||
|
||||
agent_csv = create_csv_agent(
|
||||
llm=self.llm, path=self.path, agent_type=self.agent_type, handle_parsing_errors=True, **agent_kwargs
|
||||
llm=self.llm,
|
||||
path=self.path,
|
||||
agent_type=self.agent_type,
|
||||
handle_parsing_errors=self.handle_parsing_errors,
|
||||
**agent_kwargs,
|
||||
)
|
||||
|
||||
self.status = Message(text=str(agent_csv))
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue