[Bug]: Generate component's Max tokens parameter cannot config with ui
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] Non-english title submitions will be closed directly ( 非英文标题的提交将会被直接关闭 ) (Language Policy).
- [x] Please do not modify this template :) and fill in all the required fields.
Describe your problem
Ragflow Version: v0.17.2 slim
@yanhaiqin518 您好! 我是一个能帮助您解决错误、回答问题并成为贡献者的机器人。我会尽力帮助您,让您在等待人类维护者的过程中感到更轻松。希望能为您效劳!😊
I found a similar closed issue regarding the inability to configure the 'Max tokens' parameter through the UI [1]. Unfortunately, no solution was found in the comments of that issue.
In Ragflow version 0.17.2, the 'Max tokens' parameter is disabled by default. This is configured in the file rag/llm/chat_model.py, where the parameter is removed from the configuration if the model name contains "claude" [2]. To enable the 'Max tokens' parameter, you can use the ChatVariableEnabledField.MaxTokensEnabled setting in the configuration file web/src/constants/chat.ts [3].
Additionally, the UI component responsible for rendering the 'Max tokens' configuration interface is located in the file web/src/components/llm-setting-items/next.tsx [4].
To continue talking to Dosu, mention @dosu.
Help Dosu learn! Give it feedback: Great Response | Irrelevant Answer | Incorrect Sources | Too Verbose | Hallucination | Bug Report | Other
This setting has been removed in v0.17.2. Apologies that this change was only reflected in the dev documentation.