AhsanRazi commited on
Commit
6e1af8a
·
verified ·
1 Parent(s): c4ab232

Update blog_title_generator.py

Browse files
Files changed (1) hide show
  1. blog_title_generator.py +2 -2
blog_title_generator.py CHANGED
@@ -1,6 +1,6 @@
1
  import time
2
  import json
3
- from langchain_community.tools import DuckDuckGoSearchResults
4
  from langgraph.graph import MessagesState
5
  from langchain_core.prompts import PromptTemplate
6
  from langchain_core.messages import HumanMessage, SystemMessage
@@ -24,7 +24,7 @@ def blog_titles_agent(llm, state):
24
  Returns:
25
  str: The result of the search query.
26
  """
27
- search = DuckDuckGoSearchResults()
28
  result = search.invoke(query)
29
  print("Tool Call")
30
  return result
 
1
  import time
2
  import json
3
+ from langchain_community.tools import DuckDuckGoSearchRun
4
  from langgraph.graph import MessagesState
5
  from langchain_core.prompts import PromptTemplate
6
  from langchain_core.messages import HumanMessage, SystemMessage
 
24
  Returns:
25
  str: The result of the search query.
26
  """
27
+ search = DuckDuckGoSearchRun()
28
  result = search.invoke(query)
29
  print("Tool Call")
30
  return result