mirror of
https://github.com/infiniflow/ragflow.git
synced 2026-02-02 16:45:08 +08:00
Feat: Add a web search button to the chat box on the chat page. (#12786)
### What problem does this PR solve? Feat: Add a web search button to the chat box on the chat page. ### Type of change - [x] New Feature (non-breaking change which adds functionality)
This commit is contained in:
@ -73,6 +73,7 @@ export const useSendSharedMessage = () => {
|
||||
question: message.content,
|
||||
session_id: get(derivedMessages, '0.session_id'),
|
||||
reasoning: message.reasoning,
|
||||
internet: message.internet,
|
||||
});
|
||||
|
||||
if (isCompletionError(res)) {
|
||||
@ -119,7 +120,11 @@ export const useSendSharedMessage = () => {
|
||||
}, [answer, addNewestAnswer]);
|
||||
|
||||
const handlePressEnter = useCallback(
|
||||
(...[{ enableThinking }]: NextMessageInputOnPressEnterParameter) => {
|
||||
(
|
||||
...[
|
||||
{ enableThinking, enableInternet },
|
||||
]: NextMessageInputOnPressEnterParameter
|
||||
) => {
|
||||
if (trim(value) === '') return;
|
||||
const id = uuid();
|
||||
if (done) {
|
||||
@ -135,6 +140,7 @@ export const useSendSharedMessage = () => {
|
||||
id,
|
||||
role: MessageType.User,
|
||||
reasoning: enableThinking,
|
||||
internet: enableInternet,
|
||||
});
|
||||
}
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user