dify icon indicating copy to clipboard operation
dify copied to clipboard

Can you provide the full name of the supplier?

Open 729973389 opened this issue 10 months ago • 1 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 report (我已阅读并同意 Language Policy).
  • [x] [FOR CHINESE USERS] 请务必使用英文提交 Issue,否则会被关闭。谢谢!:)
  • [x] Please do not modify this template :) and fill in all the required fields.

Provide a description of requested docs changes

I can't find the parameter reranking_provider_name according to docs api for retrieving knowledge base. Can you provide the full name of the model supplier in docs?

Here is my sample code:

import requests import json

配置 API 端点和认证信息

url = "http://192.168.1.160/v1/datasets/29d9e1a0-4c62-438d-a5e8-c46607961231/retrieve" api_key = "my-api_key" headers = { "Authorization": f"Bearer {api_key}", "Content-Type": "application/json" }

构造请求数据

payload = { "query": "我想查询关于消防安全相关的试题", "retrieval_model": { "search_method": "hybrid_search", "reranking_enable": True, "reranking_mode": None, "reranking_model": { "reranking_provider_name": "Qwen", #There is a problem with the parameters "reranking_model_name": "gte-rerank" }, "weights": 0.6, "top_k": 1, "score_threshold_enabled": False, "score_threshold": None } }

发送 POST 请求

response = requests.post(url, headers=headers, data=json.dumps(payload))

输出返回结果

print(response.status_code) print(response.json())

The error message is as follows: 400 {'code': 'invalid_param', 'message': 'Provider Qwen does not exist.', 'status': 400}

729973389 avatar Mar 06 '25 07:03 729973389