merge web_search and fetch_urls_contents

This commit is contained in:
duanfuxiang
2025-03-20 08:56:18 +08:00
parent 679d7142eb
commit 76ecca0da9
3 changed files with 124 additions and 35 deletions

View File

@@ -535,7 +535,7 @@ const Chat = forwardRef<ChatRef, ChatProps>((props, ref) => {
}
}
} else if (toolArgs.type === 'search_web') {
const results = await webSearch(toolArgs.query, settings.serperApiKey)
const results = await webSearch(toolArgs.query, settings.serperApiKey, settings.jinaApiKey, (await getRAGEngine()))
const formattedContent = `[search_web for '${toolArgs.query}'] Result:\n${results}\n`;
return {
type: 'search_web',