fix: include_domain does NOT exist

This commit is contained in:
Timothy Jaeryang Baek 2025-02-17 19:20:49 -08:00
parent 9bd26d6faa
commit ba6cde8a87
2 changed files with 2 additions and 2 deletions

View File

@ -27,8 +27,7 @@ def search_tavily(
"""
url = "https://api.tavily.com/search"
data = {"query": query, "api_key": api_key}
include_domain = filter_list
response = requests.post(url, include_domain, json=data)
response = requests.post(url, json=data)
response.raise_for_status()
json_response = response.json()

View File

@ -1270,6 +1270,7 @@ def search_web(request: Request, engine: str, query: str) -> list[SearchResult]:
request.app.state.config.TAVILY_API_KEY,
query,
request.app.state.config.RAG_WEB_SEARCH_RESULT_COUNT,
request.app.state.config.RAG_WEB_SEARCH_DOMAIN_FILTER_LIST,
)
else:
raise Exception("No TAVILY_API_KEY found in environment variables")