geekan / MetaGPT

🌟 The Multi-Agent Framework: First AI Software Company, Towards Natural Language Programming
https://deepwisdom.ai/
MIT License
45.24k stars 5.38k forks source link

'type' object is not subscriptable #58

Closed xieyan9-tal closed 1 year ago

xieyan9-tal commented 1 year ago

'type' object is not subscriptable

geekan commented 1 year ago

could you provide more log?

andotorg commented 1 year ago

could you provide more log?

2023-07-20 19:45:04.191 | INFO | metagpt.config:init:43 - Config loading done. Traceback (most recent call last): File "/Users/lucas/tal/github/ai/MetaGPT/startup.py", line 5, in from metagpt.software_company import SoftwareCompany File "/Users/lucas/tal/github/ai/MetaGPT/metagpt/software_company.py", line 11, in from metagpt.actions import BossRequirement File "/Users/lucas/tal/github/ai/MetaGPT/metagpt/actions/init.py", line 10, in from metagpt.actions.action import Action File "/Users/lucas/tal/github/ai/MetaGPT/metagpt/actions/action.py", line 11, in from metagpt.llm import LLM File "/Users/lucas/tal/github/ai/MetaGPT/metagpt/llm.py", line 9, in from metagpt.provider.openai_api import OpenAIGPTAPI as LLM File "/Users/lucas/tal/github/ai/MetaGPT/metagpt/provider/init.py", line 9, in from metagpt.provider.openai_api import OpenAIGPTAPI File "/Users/lucas/tal/github/ai/MetaGPT/metagpt/provider/openai_api.py", line 15, in from metagpt.provider.base_gpt_api import BaseGPTAPI File "/Users/lucas/tal/github/ai/MetaGPT/metagpt/provider/base_gpt_api.py", line 15, in class BaseGPTAPI(BaseChatbot): File "/Users/lucas/tal/github/ai/MetaGPT/metagpt/provider/base_gpt_api.py", line 19, in BaseGPTAPI def _user_msg(self, msg: str) -> dict[str, str]: TypeError: 'type' object is not subscriptable

Process finished with exit code 1

geekan commented 1 year ago

Provide OS, python version, pip freeze result

xieyan9-tal commented 1 year ago

macos python3.8.8

geekan commented 1 year ago

Step 1: Ensure that NPM is installed on your system. Then install mermaid-js.

npm --version sudo npm install -g @mermaid-js/mermaid-cli

Step 2: Ensure that Python 3.9+ is installed on your system. You can check this by using:

python --version

Step 3: Clone the repository to your local machine, and install it.

git clone https://github.com/geekan/metagpt cd metagpt python setup.py install

xieyan9-tal commented 1 year ago

thanks