JayZeeDesign / researcher-gpt

448 stars 253 forks source link

Getting AttributeError for agent = AgentType.OPENAI_FUNCTIONS #2

Open AlefAlfa opened 1 year ago

AlefAlfa commented 1 year ago

AttributeError: OPENAI_FUNCTIONS Traceback: File "/Library/Frameworks/Python.framework/Versions/3.11/lib/python3.11/site-packages/streamlit/runtime/scriptrunner/script_runner.py", line 565, in _run_script exec(code, module.dict) File "/Users/lev/Documents/Github/researcher-gpt/app.py", line 169, in agent=AgentType.OPENAI_FUNCTIONS, ^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/Library/Frameworks/Python.framework/Versions/3.11/lib/python3.11/enum.py", line 786, in getattr raise AttributeError(name) from None

MikhailTru commented 1 year ago

Getting the same error: AttributeError: OPENAI_FUNCTIONS. How to fix it?

deter3 commented 1 year ago

using langchain is pain in the ass , hard to debug .

annikenskywalker commented 12 months ago

I get this error when I run the code directly. When I use "Streamlit run app.py", the app works.

hatpick commented 12 months ago

That's cause you are using an older version of langchain, you gotta upgrade it via pip3 install --upgrade langchain