mirror of
https://gitee.com/wanwujie/deer-flow
synced 2026-04-22 05:34:45 +08:00
feat: support duckduckgo search engine
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
from .tools import TAVILY_MAX_RESULTS
|
||||
from .tools import SEARCH_MAX_RESULTS, SELECTED_SEARCH_ENGINE, SearchEngine
|
||||
from .loader import load_yaml_config
|
||||
|
||||
from dotenv import load_dotenv
|
||||
@@ -38,5 +38,7 @@ __all__ = [
|
||||
# Other configurations
|
||||
"TEAM_MEMBERS",
|
||||
"TEAM_MEMBER_CONFIGRATIONS",
|
||||
"TAVILY_MAX_RESULTS",
|
||||
"SEARCH_MAX_RESULTS",
|
||||
"SELECTED_SEARCH_ENGINE",
|
||||
"SearchEngine",
|
||||
]
|
||||
|
||||
@@ -1,2 +1,15 @@
|
||||
import os
|
||||
import enum
|
||||
from dotenv import load_dotenv
|
||||
|
||||
load_dotenv()
|
||||
|
||||
|
||||
class SearchEngine(enum.Enum):
|
||||
TAVILY = "tavily"
|
||||
DUCKDUCKGO = "duckduckgo"
|
||||
|
||||
|
||||
# Tool configuration
|
||||
TAVILY_MAX_RESULTS = 3
|
||||
SELECTED_SEARCH_ENGINE = os.getenv("SEARCH_API", SearchEngine.TAVILY.value)
|
||||
SEARCH_MAX_RESULTS = 3
|
||||
|
||||
Reference in New Issue
Block a user