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

can not use qwen-vl-max #1650

Open
yyvhang opened this issue Dec 27, 2024 · 2 comments
Open

can not use qwen-vl-max #1650

yyvhang opened this issue Dec 27, 2024 · 2 comments

Comments

@yyvhang
Copy link

yyvhang commented Dec 27, 2024

Bug description

can not use the qwen-vl-max API
Bug solved method

Environment information

  • LLM type and model name: dashscope, qwen-vl-max-latest
  • System version: ubuntu22.04
  • Python version: 3.10
  • MetaGPT version or branch: 0.8.1
  • packages version:
  • installation method: pip

Screenshots or logs

Exception: Traceback (most recent call last):
File "/cpfs01/user/conda/envs/agent/lib/python3.10/site-packages/metagpt/utils/common.py", line 640, in wrapper
return await func(self, *args, **kwargs)
File "/cpfs01/user/conda/envs/agent/lib/python3.10/site-packages/metagpt/roles/role.py", line 550, in run
rsp = await self.react()
File "/cpfs01/user/conda/envs/agent/lib/python3.10/site-packages/metagpt/roles/role.py", line 519, in react
rsp = await self._act_by_order()
File "/cpfs01/user/conda/envs/agent/lib/python3.10/site-packages/metagpt/roles/role.py", line 473, in _act_by_order
rsp = await self._act()
File "/nas/shared/landmark_3dgen/yangyuhang/Agent/test.py", line 147, in _act
result = await todo.run(msg.content)
File "/nas/shared/landmark_3dgen/yangyuhang/Agent/test.py", line 36, in run
rsp = await self._aask(prompt)
File "/cpfs01/user/conda/envs/agent/lib/python3.10/site-packages/metagpt/actions/action.py", line 93, in _aask
return await self.llm.aask(prompt, system_msgs)
File "/cpfs01/user/conda/envs/agent/lib/python3.10/site-packages/metagpt/provider/base_llm.py", line 150, in aask
rsp = await self.acompletion_text(message, stream=stream, timeout=self.get_timeout(timeout))
File "/cpfs01/user/conda/envs/agent/lib/python3.10/site-packages/tenacity/_asyncio.py", line 88, in async_wrapped
return await fn(*args, **kwargs)
File "/cpfs01/user/conda/envs/agent/lib/python3.10/site-packages/tenacity/_asyncio.py", line 47, in call
do = self.iter(retry_state=retry_state)
File "/cpfs01/user/conda/envs/agent/lib/python3.10/site-packages/tenacity/init.py", line 314, in iter
return fut.result()
File "/cpfs01/user/conda/envs/agent/lib/python3.10/concurrent/futures/_base.py", line 451, in result
return self.__get_result()
File "/cpfs01/user/conda/envs/agent/lib/python3.10/concurrent/futures/_base.py", line 403, in __get_result
raise self._exception
File "/cpfs01/user/conda/envs/agent/lib/python3.10/site-packages/tenacity/_asyncio.py", line 50, in call
result = await fn(*args, **kwargs)
File "/cpfs01/user/conda/envs/agent/lib/python3.10/site-packages/metagpt/provider/base_llm.py", line 200, in acompletion_text
return await self._achat_completion_stream(messages, timeout=self.get_timeout(timeout))
File "/cpfs01/user/conda/envs/agent/lib/python3.10/site-packages/metagpt/provider/dashscope_api.py", line 220, in _achat_completion_stream
self._check_response(chunk)
File "/cpfs01/user/conda/envs/agent/lib/python3.10/site-packages/metagpt/provider/dashscope_api.py", line 194, in _check_response
raise RuntimeError(f"code: {resp.code}, request_id: {resp.request_id}, message: {resp.message}")
RuntimeError: code: InvalidParameter, request_id: bd2b84b8-7989-93d3-b942-5f1af2ff129a, message: url error, please check url!

@iorisa
Copy link
Collaborator

iorisa commented Jan 2, 2025

Ok, I'll follow up on this issue.

@iorisa
Copy link
Collaborator

iorisa commented Jan 3, 2025

The follow config/config2.yaml configuration is working:

llm:
  api_type: "openai"
  model: "qwen-vl-max"
  base_url: "https://dashscope.aliyuncs.com/compatible-mode/v1"
  api_key: "sk-3b9e***"
  max_token: 1500
  temperature: 0.5

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

No branches or pull requests

2 participants