Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

agentscope #5

Closed
NAMEKDSUN opened this issue Nov 11, 2024 · 11 comments
Closed

agentscope #5

NAMEKDSUN opened this issue Nov 11, 2024 · 11 comments
Labels
good first issue Good for newcomers

Comments

@NAMEKDSUN
Copy link

Traceback (most recent call last):
File "/home/ecs-user/Social_Science/sci_platform/run.py", line 1, in
from sci_platform import Platform
File "/home/ecs-user/Social_Science/sci_platform/sci_platform.py", line 13, in
from agentscope.agents import SciAgent
ImportError: cannot import name 'SciAgent' from 'agentscope.agents' (/home/ecs-user/anaconda3/envs/science/lib/python3.11/site-packages/agentscope/agents/init.py)
运行run.py文件报错,没有办法从项目中的agentscope导入SciAgent

@RenqiChen
Copy link
Owner

RenqiChen commented Nov 11, 2024

这个是SciAgent所在的路径
image

@NAMEKDSUN
Copy link
Author

image
明白,我看代码中存在导入agentscope所在的文件路径,但是依然报ImportError: cannot import name 'SciAgent' from 'agentscope.agents' (/home/ecs-user/anaconda3/envs/science/lib/python3.11/site-packages/agentscope/agents/init.py)

@KuKuKuKuKuKurisu
Copy link
Collaborator

可以print一下sys.path吗

@NAMEKDSUN
Copy link
Author

['/home/ecs-user/Social_Science/sci_platform', '/home/ecs-user/anaconda3/envs/science/lib/python311.zip', '/home/ecs-user/anaconda3/envs/science/lib/python3.11', '/home/ecs-user/anaconda3/envs/science/lib/python3.11/lib-dynload', '/home/ecs-user/anaconda3/envs/science/lib/python3.11/site-packages', '../agentscope-main/src']

@NAMEKDSUN
Copy link
Author

根据报错显示他并没有去项目中的agentscope寻找SciAgent,而是从使用pip install的agentscope寻找SciAgent

@NAMEKDSUN
Copy link
Author

找到了解决办法,不要使用pip install agentscope来进行安装,使用开发者模型进行安装agentscope:pip install -e . ref:https://github.com/modelscope/agentscope/blob/main/README.md
image

@RenqiChen RenqiChen pinned this issue Nov 11, 2024
@RenqiChen RenqiChen added the good first issue Good for newcomers label Nov 11, 2024
@NAMEKDSUN
Copy link
Author

我看您修改文档了,使用pip install -e.安装agentscope,必须要把agentscope的readme文档放在agentscope-main目录下才可以

@RenqiChen
Copy link
Owner

我们把setup.py里面这部分代码改掉了,尝试过可以正常安装

@RenqiChen RenqiChen mentioned this issue Dec 6, 2024
@JUNO523
Copy link

JUNO523 commented Dec 17, 2024

同学您好,想麻烦问下您是怎么安装的呀,是用服务器进行安装的嘛,是用的什么型号的呀

@JUNO523
Copy link

JUNO523 commented Dec 17, 2024

@NAMEKDSUN @KuKuKuKuKuKurisu 同学您好,想麻烦问下您是怎么安装的呀,是用服务器进行安装的嘛,是用的什么型号的呀

@KuKuKuKuKuKurisu
Copy link
Collaborator

KuKuKuKuKuKurisu commented Dec 17, 2024 via email

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
good first issue Good for newcomers
Projects
None yet
Development

No branches or pull requests

4 participants