feat: support duckduckgo search engine

This commit is contained in:
He Tao
2025-04-10 11:45:04 +08:00
parent 03798ded08
commit 1195612c47
13 changed files with 88 additions and 119 deletions

View File

@@ -2,10 +2,9 @@ from langgraph.prebuilt import create_react_agent
from src.prompts import apply_prompt_template
from src.tools import (
bash_tool,
crawl_tool,
python_repl_tool,
tavily_tool,
web_search_tool,
)
from src.llms.llm import get_llm_by_type
@@ -25,6 +24,6 @@ def create_agent(agent_name: str, agent_type: str, tools: list, prompt_template:
# Create agents using the factory function
research_agent = create_agent(
"researcher", "researcher", [tavily_tool, crawl_tool], "researcher"
"researcher", "researcher", [web_search_tool, crawl_tool], "researcher"
)
coder_agent = create_agent("coder", "coder", [python_repl_tool, bash_tool], "coder")
coder_agent = create_agent("coder", "coder", [python_repl_tool], "coder")