自检
- 这仅用于提交错误报告,如果您想提问,请访问 Discussions 。
- 我已在 search for existing issues 中搜索了现有问题,包括已关闭的问题。
- 我确认我使用英语提交此报告(我已阅读并同意 Language Policy )。
- 请不要修改此模板 :) 并填写所有必填字段。
Dify版本
0.6.9
云或自托管
云,自托管(Docker)
重现步骤
- 创建一个聊天流/工作流
- 添加一个知识检索块
- 点击 N-to-1 检索选择
✔️预期行为
我应该在底部看到一个选择框,用于选择 "N-to-1检索选择模型",这是决定查询哪个知识的模型。
❌实际行为
我看到的是一个系统推理模型的选择框。我认为我们忘记了为此视图添加标签和辅助文本。我们正在重用来自工作区系统推理模型设置的这些内容,这令人困惑。
2条答案
按热度按时间jaql4c8m1#
要解决N-to-1检索选择模型显示系统推理模型的标签和辅助文本而不是正确标签和辅助文本的问题,您需要确保为N-to-1检索选择模型设置正确的标签和辅助文本。这涉及到验证并更新与模型配置相关的属性。
retriever_resource_dict
属性:确保在
AppModelConfig
类中正确设置并在应用程序中使用retriever_resource_dict
属性。检查设置标签和辅助文本的UI组件。具体来说,在
web/app/components/datasets/settings/form/index.tsx
文件中,确保RetrievalMethodConfig
和EconomicalRetrievalMethodConfig
组件正确接收并显示适当的标签和辅助文本。确保
RetrievalMethodConfig
和EconomicalRetrievalMethodConfig
组件中的条件渲染逻辑根据value.search_method
中的type
值正确设置标签和辅助文本。通过确保正确设置和使用
retriever_resource_dict
属性,以及正确配置UI组件以显示正确的标签和辅助文本,您应该能够解决N-to-1检索选择模型 1(https://github.com/langgenius/dify/blob/main/api/models/model.py)2(https://github.com/langgenius/dify/blob/main/web/app/components/datasets/settings/form/index.tsx) 的问题。详细信息
关于Dosu
此响应旨在帮助您节省时间并提高效率。它不是精确的解决方案,而是您自己研究的起点。
请帮助我变得更有用!如果这有帮助,请留下一个👍,如果无关紧要,请留下一个👎。
hujrc8aj2#
让我们看看如何优化描述。