dify icon indicating copy to clipboard operation
dify copied to clipboard

Bing search bug

Open lx1054331851 opened this issue 10 months ago • 3 comments

Self Checks

  • [X] This is only for bug report, if you would like to ask a quesion, please head to Discussions.
  • [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] Pleas do not modify this template :) and fill in all the required fields.

Dify version

0.6.2

Cloud or Self Hosted

Cloud, Self Hosted (Docker), Self Hosted (Source)

Steps to reproduce

I always encounter invoke url error when using bing search.

So I dig into the source code. The search setting is as below:

image

But the real thing is the filters are all setting as true, as below

image

So the backend request url is:

https://api.bing.microsoft.com/v7.0/search?q={query_string}&mkt=en-US&count=5&responseFilter=Computation,Entities,News, RelatedSearches,WebPages

So if all the filters are true, bing will raise a error: 403 forbidden.

✔️ Expected Behavior

No response

❌ Actual Behavior

No response

lx1054331851 avatar Apr 15 '24 18:04 lx1054331851

It looks like the issue with the Bing search in Dify might be due to a misconfiguration or an issue with the Bing Search API itself. Here's a more focused approach to troubleshoot and potentially resolve the issue:

  1. Configuration in Dify: Ensure the bing_web_search.yaml reflects your desired settings, especially that non-webpage search options are set to false. This file dictates the default parameter values and can be found in the Dify codebase.

  2. Docker Setup: Verify your Docker environment is correctly configured to apply changes. This includes ensuring the configuration file is correctly mapped and reloaded.

  3. Clear Caches/Restart: Clear any application-level caches or restart the application within Docker to apply new settings.

  4. Check for Known Bugs: Investigate any known issues with Dify version 0.6.2 that might affect settings, though no specific bugs related to this issue were found at the time of writing.

If the problem persists, consider these steps related to the Bing Search API:

  1. Subscription Key: Confirm the subscription_key is valid and not expired, as a 403 forbidden error often points to permission issues.

  2. API Endpoint and Parameters: Ensure you're using the correct API endpoint and that the market and lang parameters are correctly formatted.

  3. Rate Limits and IP Restrictions: Check if you've exceeded API call rate limits or if there are any IP restrictions in place that might be causing the 403 forbidden error.

  4. Region-Specific Restrictions: Verify there are no restrictions in your region that could affect access to the Bing Search API.

If after these steps the issue is not resolved, reaching out to Microsoft Azure support might be necessary for further assistance.

Sources

About Dosu

This response is meant to be useful and save you time. It is not meant to be a precise solution, but rather a starting point for your own research.

Help me be more useful! Please leave a 👍 if this is helpful and 👎 if it is irrelevant.

If you want to continue the conversation, start your reply with @dosu-bot.

dosubot[bot] avatar Apr 15 '24 18:04 dosubot[bot]

Pls check your Bing Search subscription plan, for different subscription plans, different filters are permitted, I have tested a basic plan, which can only support webpage search.

Yeuoly avatar Apr 17 '24 05:04 Yeuoly

image This is my Bing Search subscription plan. image

There is still bug: image

enties search is not disabled.

lx1054331851 avatar Apr 17 '24 14:04 lx1054331851

+1, I also encountered same problem img_v3_02c1_4b298b0d-1f0d-40f2-ba47-a78499991d9g

kaojistream avatar Jun 20 '24 08:06 kaojistream

The temporary solution was that I switched to a different subscription group

kaojistream avatar Jun 20 '24 08:06 kaojistream