feat: Update web search providers and enhance knowledge base management

- Added DuckDuckGo as a new web search provider in the configuration.
- Removed deprecated web search providers (Baidu, Bing, Bocha, Exa, Google, Kuaisou, Searxng, Tavily, Zhipu) to streamline the codebase.
- Enhanced knowledge base management by introducing temporary knowledge base handling in the session service.
- Updated the web search service to support RAG-based compression for improved search result processing.
- Refactored session and knowledge service interfaces to accommodate new functionalities.
This commit is contained in:
wizardchen
2025-11-10 22:45:27 +08:00
parent ac8c8e9af2
commit 244aaab328
40 changed files with 968 additions and 1027 deletions
+5 -46
View File
@@ -618,57 +618,16 @@ agent:
web_search:
# 可用搜索引擎列表
providers:
- id: "kuaisou"
name: "快搜"
free: false
requires_api_key: true
description: "高性能实时网页搜索"
api_url: "https://platform.kuaisou.com/api/v1/search"
- id: "google"
name: "Google"
- id: "duckduckgo"
name: "DuckDuckGo"
free: true
requires_api_key: false
description: "Google搜索(免费)"
api_url: "https://www.googleapis.com/customsearch/v1"
- id: "baidu"
name: "百度"
free: true
requires_api_key: false
description: "百度搜索(免费)"
- id: "bing"
name: "Bing"
free: true
requires_api_key: false
description: "Bing搜索(免费)"
- id: "bocha"
name: "博查"
free: false
requires_api_key: true
description: "专为AI应用设计的搜索API"
- id: "zhipu"
name: "智谱"
free: false
requires_api_key: true
description: "智谱搜索API"
- id: "tavily"
name: "Tavily"
free: false
requires_api_key: true
description: "Tavily AI搜索API"
- id: "searxng"
name: "Searxng"
free: true
requires_api_key: false
description: "Searxng开源元搜索引擎"
- id: "exa"
name: "Exa"
free: false
requires_api_key: true
description: "Exa AI搜索API"
description: "DuckDuckGo API"
# 默认配置
default:
provider: "kuaisou"
provider: "duckduckgo"
max_results: 5
include_date: true
compression_method: "none"