dify icon indicating copy to clipboard operation
dify copied to clipboard

"BOOL" type is not supported

Open Jalen-Zhong opened this issue 1 year ago • 3 comments

Self Checks

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

1. Is this request related to a challenge you're experiencing? Tell me about your story.

Thanks for you nice works! I got a issuse about input type: I define myself's tools with Schema like:

        content:
          application/json:
            schema:
              type: object
              properties:
                fs:
                  type: integer
                  description: Sample rate of the audio file
                wav:
                  type: array
                  items:
                    type: number
                  description: Audio samples as a list of numbers
                language:
                  type: string
                  description: Language type of the speech
                show_emo:
                  type: boolean
                  description: Whether to display emotion information
                show_event:
                  type: boolean
                  description: Whether to display event information

When I use this self-define tool in my workflow. I found input type of the dify given is not support bool type.

2. Additional context or comments

How can I define bool type as input? or Could you consider this issuse?

3. Can you help us with this feature?

  • [ ] I am interested in contributing to this feature.

Jalen-Zhong avatar Oct 25 '24 08:10 Jalen-Zhong

https://github.com/langgenius/dify/blob/e61752bd3a5b48e2c4b390d78cf7d384d2b8a988/api/core/tools/entities/tool_entities.py#L140-L147

This one?

crazywoola avatar Oct 25 '24 08:10 crazywoola

https://github.com/langgenius/dify/blob/e61752bd3a5b48e2c4b390d78cf7d384d2b8a988/api/core/tools/entities/tool_entities.py#L140-L147

This one?

Thanks for your source code, but may I ask the task is be planning or done? Becourse I find Version: 0.10.1 is not support. image image

Jalen-Zhong avatar Oct 25 '24 09:10 Jalen-Zhong

Hi, @Jalen-Zhong. I'm Dosu, and I'm helping the Dify team manage their backlog. I'm marking this issue as stale.

Issue Summary:

  • You reported a lack of support for the "BOOL" type in your workflow with a self-defined tool.
  • You are seeking guidance on defining a boolean type as input or requesting a fix.
  • User crazywoola provided a code link, leading you to ask if the task is planned or completed.
  • You noted that version 0.10.1 does not support this feature.

Next Steps:

  • Please let us know if this issue is still relevant to the latest version of the Dify repository by commenting on this issue.
  • If there is no further activity, this issue will be automatically closed in 15 days.

Thank you for your understanding and contribution!

dosubot[bot] avatar Nov 25 '24 16:11 dosubot[bot]