Feat: apply LLM to optimize citations. (#5935)

### What problem does this PR solve?

#5905

### Type of change

- [x] New Feature (non-breaking change which adds functionality)
This commit is contained in:
Kevin Hu
2025-03-11 19:56:21 +08:00
committed by GitHub
parent ed11be23bf
commit caecaa7562
5 changed files with 77 additions and 17 deletions

View File

@ -27,7 +27,8 @@ class Tavily:
try:
response = self.tavily_client.search(
query=query,
search_depth="advanced"
search_depth="advanced",
max_results=6
)
return [{"url": res["url"], "title": res["title"], "content": res["content"], "score": res["score"]} for res in response["results"]]
except Exception as e: