Find answers from the community

Updated 2 years ago

Hi guys I m using the llama chat agent

At a glance
Hi guys, I'm using the llama_chat_agent. However, each time he agent try to access a tool (index) this following error occurs --> AttributeError: 'ChatOpenAI' object has no attribute 'total_tokens_used' Does someone has faced this too ?
j
L
p
3 comments
hey @plouplou , oh weird - do you have an example code snippet?
I'm pretty sure (judging by the code sample posted earlier), you need to wrap the llm with the LLMPredictor class before putting it into the query kwargs

Plain Text
llm_predictor = LLMPredictor(llm=llm_agent_tool)
Yes it was the solution thank you so much πŸ™‚
Add a reply
Sign up and join the conversation on Discord