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

The image size parameter in the cogvlm tool does not match the parameter provided on the official Zhipu website, which can cause interface errors. #8315

Open
5 tasks done
jiaolongxue opened this issue Sep 12, 2024 · 3 comments · May be fixed by #8382
Labels
💪 enhancement New feature or request

Comments

@jiaolongxue
Copy link

Self Checks

  • This is only for bug report, if you would like to ask a question, please head to Discussions.
  • I have searched for existing issues search for existing issues, including closed ones.
  • I confirm that I am using English to submit this report (我已阅读并同意 Language Policy).
  • [FOR CHINESE USERS] 请务必使用英文提交 Issue,否则会被关闭。谢谢!:)
  • Please do not modify this template :) and fill in all the required fields.

Dify version

0.7.3

Cloud or Self Hosted

Self Hosted (Docker)

Steps to reproduce

The image size parameter in the cogvlm tool does not match the parameter provided on the official Zhipu website, which can cause interface errors.

cogvlm tool

image

zhipu website

image

error

image

✔️ Expected Behavior

success

❌ Actual Behavior

image

Copy link

dosubot bot commented Sep 12, 2024

The image size parameter in the cogvlm tool does not match the parameter provided on the official Zhipu website because the CogView3Tool class in the cogview3.py file uses a predefined size_mapping dictionary to map size options to specific dimensions:

size_mapping = {
    "square": "1024x1024",
    "vertical": "1024x1792",
    "horizontal": "1792x1024",
}

This mapping may differ from the size parameters specified on the official Zhipu website, leading to interface errors. Additionally, the stepfun tool, as described in the image.yaml file, offers a different set of predefined image sizes:

options:
  - value: 256x256
    label:
      en_US: 256x256
  - value: 512x512
    label:
      en_US: 512x512
  - value: 768x768
    label:
      en_US: 768x768
  - value: 1024x1024
    label:
      en_US: 1024x1024
  - value: 1280x800
    label:
      en_US: 1280x800
  - value: 800x1280
    label:
      en_US: 800x1280

The discrepancy between these predefined sizes and the ones used in the cogvlm tool can cause interface errors when the expected parameters do not align [1][2].

To continue talking to Dosu, mention @dosu.

@dosubot dosubot bot added the 🐞 bug Something isn't working label Sep 12, 2024
@crazywoola
Copy link
Member

@ox01024 Hello can you update this tool?

@crazywoola crazywoola added 💪 enhancement New feature or request and removed 🐞 bug Something isn't working labels Sep 12, 2024
@ox01024
Copy link
Contributor

ox01024 commented Sep 12, 2024

Leave it to me. I'll take care of him as soon as possible. Don't worry.

@ox01024 Hello can you update this tool?

Leave it to me. I'll take care of him as soon as possible. Don't worry.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
💪 enhancement New feature or request
Projects
None yet
3 participants